Advertisement
Guest User

macierze

a guest
Mar 18th, 2018
79
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.77 KB | None | 0 0
  1. from numpy import matrix
  2. import numpy as np
  3.  
  4.  
  5. K = np.array([[1.0,0.0,0.0,0.0,0.0,0.0,0.0],
  6.               [0.00, 8035555.56, -4017777.78, 0.00, 0.00, 0.00, 0.00],
  7.               [0.00, -4017777.78, 6152222.22, -3013333.33, 0.00],
  8.               [0.00, 0.00, -3013333.33, 6026666.67, 0.00, 0.00, 0.00],
  9.               [0.00, 0.00, 0.00, 0.00, 1.00, 0.00, 0.00, 0.00, 0.00],
  10.               [0.00, 0.00, 0.00, 0.00, 0.00, 4821333.33, -2410666.67],
  11.               [0.00, 0.00, 0.00, 0.00, 0.00, -2410666.67, 2109333.33]])
  12. print("teraz K")
  13. print (K)
  14. #U przed uwzglednieniem warunkow brzegowych
  15.  
  16. U = np.array([[1],
  17.             [1],
  18.             [1],
  19.            [1],
  20.            [1],
  21.            [1],
  22.            [1]])
  23. print("teraz U")
  24. print(U)
  25. print("teraz K+U")
  26. F = K + U
  27. print(F)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement