Games
Problems
Go Pro!

# Matrix Multiplication

Reference > Mathematics > Algebra > Matrices

After seeing how simple matrix addition and matrix subtraction are, and after seeing how simple it is to multiply a matrix times a scalar, you might be thinking, "Matrix multiplication is going to be simple too, and I bet I know exactly how to do it!"

If you're thinking that, you're probably wrong. Matrix multiplication is not a simple process, and it is probably not what you were expecting. Most texts give you nasty looking formulas to explain how matrix multiplication works, but those formulas tend to confuse more than help, so I'm going to try to explain by giving an example. Here's my example:

1
2
3
4
5
6
10
11
12
13

"Wait a minute!" you might be thinking, "the dimensions of those two matrices don't match! We can't multiply them!"

Actually, we can. Here's the first thing you need to know about matrix multiplication: you can multiply two matrices if the number of columns in the first one matches the number of rows in the second one. The dimensions of our first matrix are 3 x 2, and the dimensions of the second are 2 x 2. If we write this as (3 x 2)(2 x 2) we check the "inner" dimensions to make sure they match.

Interestingly, this means that we can't multiply them in the other order becuase then we have (2 x 2)(3 x 2), and the inner dimensions don't match. This means that multiplication of matrices is not commutative!

The next thing you should know is that the product of the two matrices may not have the same dimensions as either of the matrices being multiplied. In fact, the product's dimensions will be the outer dimensions. In this case, since our dimensions are (3 x 2)(2 x 2), the product's dimensions will be 3 x 2 - not because the first matrix's dimensions are 3 x 2, but because the first matrix has 3 rows, and the second matrix has 2 columns. Confusing? Hopefully we can clear up the confusion a bit.

Now that we've covered that little detail, let's look at our original multiplication problem again. I've deliberately made sure that all the entries in the two matrices are distinct, so you can tell which number comes from where (also note that the second matrix has two-digit entries, to make it easier to see which number comes from which matrix).

1
2
3
4
5
6
10
11
12
13
=
?
?
?
?
?
?

In order to calculate the product, we're going to multiply every row of the first matrix by every column of the second one. The result will go in the corresponding position of the product.

STEP ONE
We multiply the FIRST row by the FIRST column like this:

1(10) + 2(12) = 10 + 24 = 34.

This will go in the FIRST row, FIRST column of the answer:
34
?
?
?
?
?
.

STEP TWO
Now we will multiply the FIRST row by the SECOND column like this:

1(11) + 2(13) = 11 + 26 = 37.

THis will go in the FIRST row, SECOND column of the answer:
34
37
?
?
?
?
.

STEP THREE
Now we will multiply the SECOND row by the FIRST column like this:

3(10) + 4(12) = 30 + 48 = 78.

This will go in the SECOND row, FIRST column of the answer:
34
37
78
?
?
?
.

FINISH THE PROBLEM
Can you finish it from here?

You need to do 2nd row times 2nd column, 3rd row times 1st column, and 3rd row times 2nd column.

Give those a try, and then check the answer below, to make sure you've done it right.

1
2
3
4
5
6
10
11
12
13
=
34
37
78
85
122
133

## Questions

1.
Is it possible to multiply a 3 x 4 matrix by a 4 x 2 matrix? Why or why not?
2.
Is it possible to multiply a 4 x 2 matrix by a 3 x 4 matrix? Why or why not?
3.
If you multiply a 4 x 2 matrix by a 2 x 8 matrix, what will the dimensions of the result be?
4.
If
1
2
3
3
2
1
is multiplied by another matrix, how many rows does that matrix have?
5.
If you multiply
1
3
4
2
by
2
4
1
1
, what will be the entry in the first row, first column?
6.
In the previous question, what will be the entry in the first row, second column?
7.
What is the result when
5
6
7
is multiplied by
1
2
3
?
8.
How many entries are in the product of a 3 x 8 matrix with an 8 x 2 matrix? Assign this reference page Scalar Multiplication of Matrices The Identity Matrix and Inverses    Like us on Facebook to get updates about new resources