In the previous blog ,we have seen what is an array and we have seen why Numpy is used. Let us now perform some matrix operations using numpy.
Let us see arrays first.
Remember that matrices are strictly 2 dimensional but arrays are N dimensional. Also remember that when you perform operations on numpy arrays, operations are applied element wise. We can see this below.
We see that a*b is array multiplication and not matrix multiplication. Array multiplication is a element wise multiplication of each element.
Let us now play with some matrices.
Check the picture below. We can see that multiplication of array is not matrix multiplication but individual element multiplication.
We can also find the transpose in the following way.