Matrices are 2D array with some additional properties that make them more handy 
for linear algebra. For instance 
  mat1*mat2
is a matrix multiplication, while
  arr1*arr2
is an element by element multiplication. However

np.dot(arr1, arr2)

is a matrix multiplication between two arrays.

As a rule, you can replicate any matrix operation with arrays. If you do not do 
linear-algebra only calculation, you better use arrays.

  Nadav

-----הודעה מקורית-----
מאת: [email protected] בשם Nanime Puloski
נשלח: ה 30-יולי-09 20:14
אל: [email protected]
נושא: [Numpy-discussion] Differences Between Arrays and Matrices in Numpy
 
What are some differences between arrays and matrices using the Numpy
library? When would one want to use arrays instead of matrices and vice
versa?










_______________________________________________
NumPy-Discussion mailing list
[email protected]
http://mail.scipy.org/mailman/listinfo/numpy-discussion

Reply via email to