Resources For Teachers For Tutors For Students & Parents AI New Books Pricing
Year 12 Maths - General (Unit 3 & Unit 4) Matrices and their applications

Matrix products and powers

20 practice questions 0 video lessons Theory + worked examples

Discover how matrices multiply in Year 12 VCE General Mathematics. Multiplying is not done element by element: each entry comes from a row times a column. That one rule lets a market stall in Daylesford turn a matrix of jars sold and a matrix of prices into its daily takings in a single step, and it drives everything from networks to population models.

You will practise deciding whether a product such as \(AB\) is defined, finding its order from the inner and outer numbers, and multiplying matrices with negatives. You will see why \(AB\) and \(BA\) usually differ, find powers like \(A^2\) and \(A^3\), and use summing matrices, ready for determinants and inverses next.

Create a free accountTrack your progress and save your work as you go.
Create free account

Theory

Multiplying matrices is the key to most matrix applications. This Year 12 General Mathematics guide for students in Victoria shows when a matrix product is defined, how to find its order, how to multiply row by column, how to find powers of a square matrix, and how products turn quantities and prices into totals.

The product \(AB\) is only defined when the number of columns of \(A\) equals the number of rows of \(B\). Write the orders side by side: for \((m \times n)(n \times p)\) the inner numbers match, and the outer numbers give the order of the product, \(m \times p\).

Each element of \(AB\) is found by multiplying a row of \(A\) by a column of \(B\): multiply the first elements, the second elements, and so on, then add. The element in row \(i\), column \(j\) of \(AB\) uses row \(i\) of \(A\) and column \(j\) of \(B\).

The order of multiplication matters: \(AB\) and \(BA\) are usually different, and one may be defined when the other is not. The identity matrix \(I\) acts like the number \(1\): \(AI = IA = A\). A power of a matrix is repeated multiplication, \(A^2 = AA\), \(A^3 = A^2A\), so only a square matrix has powers. For a diagonal matrix, each diagonal element is simply raised to the power.

Products are useful in practice. A quantity matrix times a price matrix (\(QP\)) gives totals in dollars, and a summing matrix such as \(\begin{bmatrix}1 & 1 & 1\end{bmatrix}\) adds up the elements of a column.

Key idea. Check the inner numbers before you multiply. Then every element is "row times column": multiply matching pairs and add. Never multiply matrices element by element.
Row by column multiplicationA 2 by 3 matrix times a 3 by 2 matrix. Row 1 of the first matrix and column 2 of the second are shaded; they give the element in row 1, column 2 of the product, 16. 2 1 3 0 4 −1 1 5 2 0 −1 2 = 1 16 9 −2 row 1 × column 2: 2 × 5 + 1 × 0 + 3 × 2 = 16
Row 1 of the first matrix times column 2 of the second gives the element in row 1, column 2 of the product.
When is a matrix product definedA is 2 by 3 and B is 3 by 4. The inner numbers 3 and 3 match, so AB is defined and is 2 by 4. For BA the inner numbers 4 and 2 differ, so BA is not defined. A (2 × 3 ) B ( 3 × 4) → AB (2 × 4) inner numbers equal: AB is defined outer numbers give the order of AB B (3 × 4 ) A ( 2 × 3) → BA not defined
Inner numbers must match for the product to exist; the outer numbers give its order. Here \(AB\) exists but \(BA\) does not.

Condition and order:

\[(m \times n)(n \times p) \;\to\; m \times p\]
(m×n)(n×p)→m×p

Element in row \(i\), column \(j\) of \(C = AB\):

\[c_{ij} = a_{i1}b_{1j} + a_{i2}b_{2j} + \cdots + a_{in}b_{nj}\]
cij=ai1b1j+⋯

For \(2 \times 2\) matrices:

\[\begin{bmatrix}a & b\\ c & d\end{bmatrix}\begin{bmatrix}e & f\\ g & h\end{bmatrix} = \begin{bmatrix}ae + bg & af + bh\\ ce + dg & cf + dh\end{bmatrix}\]
row times column

Identity and powers (square matrices):

\[AI = IA = A, \qquad A^2 = AA, \qquad A^3 = A^2A, \qquad \begin{bmatrix}p & 0\\ 0 & q\end{bmatrix}^n = \begin{bmatrix}p^n & 0\\ 0 & q^n\end{bmatrix}\]
A2=AA
Order of three. For \(ABC\), check each neighbouring pair: \((4 \times 2)(2 \times 5)(5 \times 1)\) gives \(4 \times 1\).

Multiplying two matrices

  1. Write the orders side by side. If the inner numbers differ, the product is not defined.
  2. The outer numbers give the order of the answer: draw an empty matrix of that size.
  3. For each position (row \(i\), column \(j\)), multiply row \(i\) of the first matrix by column \(j\) of the second: pair up, multiply, add.
  4. Put negatives in brackets and check one or two elements again.

Powers and applications

  1. For \(A^3\), find \(A^2 = AA\) first, then \(A^3 = A^2A\). For a diagonal matrix, power each diagonal element.
  2. In a context, match the labels: the columns of the first matrix must describe the same things as the rows of the second (for example items, in both \(Q\) and \(P\)).
  3. Say what each element of the product means, with units.
Example 1 — Is the product defined?
Matrix \(A\) is \(3 \times 2\), \(B\) is \(2 \times 2\) and \(C\) is \(2 \times 3\). Which of \(AB\), \(BA\), \(AC\), \(CA\) and \(CB\) are defined? Give the order of each one that is.
Solution

Write the orders side by side. The inner numbers must match; the outer numbers give the order of the product.

\(AB\)\(:\)\((3 \times 2)(2 \times 2)\;\to\; 3 \times 2\)
\(BA\)\(:\)\((2 \times 2)(3 \times 2)\;\; 2 \ne 3 \text{, not defined}\)
\(AC\)\(:\)\((3 \times 2)(2 \times 3)\;\to\; 3 \times 3\)
\(CA\)\(:\)\((2 \times 3)(3 \times 2)\;\to\; 2 \times 2\)
\(CB\)\(:\)\((2 \times 3)(2 \times 2)\;\; 3 \ne 2 \text{, not defined}\)
(m×n)(n×p)→m×p

\(AB\) is \(3 \times 2\), \(AC\) is \(3 \times 3\) and \(CA\) is \(2 \times 2\). \(BA\) and \(CB\) are not defined. Notice that \(AC\) and \(CA\) are both defined but have different orders.

Example 2 — Multiplying two matrices
Let \(A = \begin{bmatrix}2 & -1\\ 3 & 4\end{bmatrix}\) and \(B = \begin{bmatrix}5 & 0\\ -2 & 1\end{bmatrix}\). (i) Find \(AB\). (ii) Find \(BA\) and compare.
Solution

Each element of \(AB\) is a row of \(A\) times a column of \(B\): multiply matching pairs and add.

\(c_{11}\)\(=\)\(2 \times 5 + (-1) \times (-2) = 12\)
\(c_{12}\)\(=\)\(2 \times 0 + (-1) \times 1 = -1\)
\(c_{21}\)\(=\)\(3 \times 5 + 4 \times (-2) = 7\)
\(c_{22}\)\(=\)\(3 \times 0 + 4 \times 1 = 4\)
\(AB\)\(=\)\(\begin{bmatrix}12 & -1\\ 7 & 4\end{bmatrix}\)
\(BA\)\(=\)\(\begin{bmatrix}10 & -5\\ -1 & 6\end{bmatrix}\)
AB≠BA

(i) \(AB = \begin{bmatrix}12 & -1\\ 7 & 4\end{bmatrix}\). (ii) \(BA = \begin{bmatrix}10 & -5\\ -1 & 6\end{bmatrix}\), which is different: the order of multiplication matters, so \(AB \ne BA\) in general.

Example 3 — Powers of a matrix
(i) For \(A = \begin{bmatrix}1 & 2\\ 0 & 3\end{bmatrix}\), find \(A^2\) and \(A^3\). (ii) For the diagonal matrix \(D = \begin{bmatrix}2 & 0\\ 0 & -3\end{bmatrix}\), find \(D^4\).
Solution

\(A^2 = AA\) and \(A^3 = A^2A\). For a diagonal matrix, raise each diagonal element to the power.

\(A^2\)\(=\)\(\begin{bmatrix}1 & 2\\ 0 & 3\end{bmatrix}\begin{bmatrix}1 & 2\\ 0 & 3\end{bmatrix}\)
\(\)\(=\)\(\begin{bmatrix}1 + 0 & 2 + 6\\ 0 + 0 & 0 + 9\end{bmatrix}\)
\(\)\(=\)\(\begin{bmatrix}1 & 8\\ 0 & 9\end{bmatrix}\)
\(A^3\)\(=\)\(\begin{bmatrix}1 & 8\\ 0 & 9\end{bmatrix}\begin{bmatrix}1 & 2\\ 0 & 3\end{bmatrix}\)
\(\)\(=\)\(\begin{bmatrix}1 + 0 & 2 + 24\\ 0 + 0 & 0 + 27\end{bmatrix}\)
\(\)\(=\)\(\begin{bmatrix}1 & 26\\ 0 & 27\end{bmatrix}\)
\(D^4\)\(=\)\(\begin{bmatrix}2^4 & 0\\ 0 & (-3)^4\end{bmatrix}\)
\(\)\(=\)\(\begin{bmatrix}16 & 0\\ 0 & 81\end{bmatrix}\)
A3=A2A

(i) \(A^2 = \begin{bmatrix}1 & 8\\ 0 & 9\end{bmatrix}\) and \(A^3 = \begin{bmatrix}1 & 26\\ 0 & 27\end{bmatrix}\). Squaring each element would give the wrong answer. (ii) \(D^4 = \begin{bmatrix}16 & 0\\ 0 & 81\end{bmatrix}\).

Example 4 — Takings at a market stall
A Daylesford market stall sells jars of jam, honey and relish. Matrix \(Q = \begin{bmatrix}12 & 8 & 15\\ 20 & 14 & 9\end{bmatrix}\) shows the jars sold on Saturday (row 1) and Sunday (row 2). The prices, in dollars, are \(P = \begin{bmatrix}7\\ 9\\ 6\end{bmatrix}\). (i) Explain why \(QP\) is defined and give its order. (ii) Find \(QP\) and explain what it shows. (iii) Find \(\begin{bmatrix}1 & 1\end{bmatrix}QP\).
Solution

\(Q\) is \(2 \times 3\) and \(P\) is \(3 \times 1\): the inner numbers match.

Quantity matrix times price matrixRow Saturday of Q times the price column gives Saturday's takings, 246 dollars. QP = 12 8 15 20 14 9 Sat Sun jam honey relish 7 9 6 = 246 320
\((2 \times 3)(3 \times 1)\)\(\to\)\(2 \times 1\)
\(t_{11}\)\(=\)\(12 \times 7 + 8 \times 9 + 15 \times 6 = 246\)
\(t_{21}\)\(=\)\(20 \times 7 + 14 \times 9 + 9 \times 6 = 320\)
\(QP\)\(=\)\(\begin{bmatrix}246\\ 320\end{bmatrix}\)
\(\begin{bmatrix}1 & 1\end{bmatrix}QP\)\(=\)\(1 \times 246 + 1 \times 320\)
\(\)\(=\)\(\begin{bmatrix}566\end{bmatrix}\)
QP

(i) \(Q\) has \(3\) columns and \(P\) has \(3\) rows, so \(QP\) is defined and is \(2 \times 1\). (ii) \(QP = \begin{bmatrix}246\\ 320\end{bmatrix}\): the stall took \(\$246\) on Saturday and \(\$320\) on Sunday. (iii) The summing matrix adds the two days: \(\begin{bmatrix}566\end{bmatrix}\), so the weekend takings were \(\$566\).

Common pitfalls

Multiplying element by element. \(AB\) is not found by multiplying matching elements, and \(A^2\) is not found by squaring each element (except for a diagonal matrix). Use row times column.
Assuming \(AB = BA\). The order of multiplication matters. Watch out for swapping the matrices in a question: \(QP\) may be defined when \(PQ\) is not, or mean something different.
Getting the order backwards. A \(2 \times 3\) matrix times a \(3 \times 1\) matrix gives a \(2 \times 1\) matrix, not \(3 \times 3\). Keep the outer numbers.

Frequently asked questions

When can two matrices be multiplied?

The product AB is defined only when the number of columns of A equals the number of rows of B. Write the orders side by side and check that the inner numbers match.

How do you find the order of a matrix product?

Use the outer numbers. A 4 x 2 matrix times a 2 x 3 matrix gives a 4 x 3 matrix.

How do you multiply two matrices?

Each element of the answer is a row of the first matrix times a column of the second. Multiply the matching pairs of numbers and add the results.

Is AB equal to BA for matrices?

Usually not. The two products often have different values, different orders, or one may not be defined at all.

How do you square a matrix?

Multiply the matrix by itself, row by column: A squared means A times A. Only square matrices can be squared. Do not square each element, unless the matrix is diagonal.