Concept

Multiplication of Matrices

Matrices can be multiplied if the number of columns in the first matrix is the same as the number of rows in the second matrix. The resulting product will have the number of rows of the first matrix and the number of columns of the second matrix.

  • The product of an m* n and an n* p matrix is an m* p matrix.

a_(11)&⋯&a_(1n) ...&⋱&... a_(m1)&⋯&a_(mn) * b_(11)&⋯&b_(1p) ...&⋱&... b_(n1)&⋯&b_(np) = c_(11)&⋯&c_(1p) ...&⋱&... c_(m1)&⋯&c_(mp)

  • The element in the ith row and jth column of the product matrix is calculated using all the elements in the ith row of the first matrix and jth column of the second matrix using the following formula.

c_(ij)=a_(i1)b_(1j)+a_(i2)b_(2j)+...+a_(in)b_(nj) Click on the elements of the product matrix below to see the illustration of how to find the product of a 4* 2 and a 2* 3 matrix.

A trick to help remember matrix multiplication is to rearrange the position of the matrices.
It is important to keep in mind that two matrices A and B can be multiplied if and only if the number of columns of A is the same as the number of rows of B. As an example, consider two matrices A and B, whose numbers of columns and rows are different.
Matrix multiplication procedure

To multiply A by B, each element of the first row of A should be multiplied by the corresponding element of the first column of B. However, the element c of A does not have a corresponding element in B, because B has only 2 rows, whereas A has 3 columns. Therefore, the multiplication cannot be performed.

Exercises