Resources For Teachers For Tutors For Students & Parents Pricing
Year 11 General Matrices And Matrix Arithmetic

Matrix Multiplication And Power Of A Matrix

20 practice questions 2 video lessons Theory + worked examples

Theory

Matrix multiplication uses the row-by-column rule: to find entry (AB)ij, take row i of A, column j of B, multiply corresponding entries, and add. The product is defined only when A's columns equal B's rows. Powers like A2 only make sense for square matrices. Matrix multiplication is not commutative.

Matrix multiplication uses a row-by-column rule, and only works when the dimensions "match up".

If A is m×n and B is n×p, then AB is defined and has order m×p. The "inner" dimensions (the two ns) must match; the "outer" dimensions give the order of the result.

Each entry of the product is found by taking the corresponding row of the left matrix and column of the right matrix, multiplying entries pairwise, and adding:

(AB)ij=kAikBkj

For a square matrix A, the power A2=A×A, and A3=A×A×A. Powers only make sense for square matrices, since AA needs A's columns to equal A's rows.

The first diagram shows the dimension rule: inner dimensions must match. The second visualises the row-by-column rule using a single entry of the product.

Inner dimensions must match for a matrix product A diagram showing that for AB to be defined, the columns of A must equal the rows of B. The inner dimensions are highlighted; the outer dimensions give the order of the result. Inner dimensions must match A m × n · B n × p = AB m × p must match outer = result order inner = must match Worked dimension checks 2 × 3 · 3 × 4 defined result: 2 × 4 3 × 2 · 3 × 2 undefined 2 ≠ 3 3 × 2 · 2 × 4 defined result: 3 × 4
For AB to be defined, columns of A must equal rows of B; outer dimensions give the result.
Row by column rule for matrix multiplication The row by column rule shown by highlighting row 1 of a 2 by 2 matrix A and column 1 of a 2 by 2 matrix B, and showing how their products are paired and summed to give the top-left entry of AB. Row × column — entry by entry 1 2 3 4 A — row 1 · 5 6 7 8 B — col 1 = 19 22 43 50 AB — top-left Top-left entry of AB 1 × 5 = 5 + 2 × 7 = 14 = 19 Pair entries left-to-right and top-to-bottom, multiply, then add
Top-left entry: pair row 1 of A with column 1 of B, multiply, add: 15+27=19.

The key idea is a single rule plus a dimension check.

The row-by-column rule

If A is m×n and B is n×p, then AB is m×p, with

(AB)ij=Ai1B1j+Ai2B2j++AinBnj

(AB)ij=kAikBkj

Powers of a square matrix

A2=A×A,A3=A×A×A

Powers are only defined when A is square — i.e. n×n.

Key properties

PropertyStatement
Associative(AB)C=A(BC)
DistributiveA(B+C)=AB+AC
IdentityAI=IA=A
ZeroA0=0A=0
Not commutativeABBA in general
A2 is not entry-squaring. A2 means A×A using the row-by-column rule. Squaring each individual entry of A gives a different (usually wrong) matrix.

How to compute AB

  1. Check the dimensions. If A is m×n and B is n×p, the product is defined. The result has order m×p.
  2. Set up a blank result matrix of order m×p.
  3. For each entry (AB)ij, take row i of A and column j of B, multiply matching entries, and add.
  4. Fill in every entry of the result.

How to compute A2 for a square matrix

  1. Write A2=A×A.
  2. Apply the row-by-column rule on the two copies of A.
  3. The result has the same order as A.

How to find a missing entry in a product equation

  1. Locate the entry of the product that depends on the unknown.
  2. Write the row-by-column equation for that entry and substitute known values.
  3. Solve the resulting linear equation for the unknown.
EXAMPLE 1 — STANDARD 2×2 PRODUCT
Find AB where A=[2134] and B=[1253].
SOLUTION

Both matrices are 2×2, so AB is also 2×2. Apply the row-by-column rule four times.

Top-left=(2)(1)+(1)(5)=7
Top-right=(2)(2)+(1)(3)=7
Bottom-left=(3)(1)+(4)(5)=17
Bottom-right=(3)(2)+(4)(3)=6

AB=[77176]

AB=-7717-6
EXAMPLE 2 — ROW × COLUMN
Find AB where A=[231] and B=[456].
SOLUTION

A is 1×3 and B is 3×1, so AB is 1×1 — a single entry.

AB=(2)(4)+(3)(5)+(1)(6)
=8+15+6
=[29]

Answer: AB=[29].

AB=29
EXAMPLE 3 — POWER A²
Find A2 where A=[3102].
SOLUTION

A2=A×A. A is square (2×2), so the product is defined.

Top-left=(3)(3)+(1)(0)=9
Top-right=(3)(1)+(1)(2)=5
Bottom-left=(0)(3)+(2)(0)=0
Bottom-right=(0)(1)+(2)(2)=4

A2=[9504]

A2=9504
EXAMPLE 4 — FIND A MISSING ENTRY
Find x such that [2x13][4125]=[14?1016].
SOLUTION

The top-left entry of the product comes from row 1 of the left matrix and column 1 of the right matrix.

(2)(4)+(x)(2)=14
8+2x=14
2x=6
x=3

Answer: x=3.

x=3

Common pitfalls

Matrix multiplication is not commutative. In general ABBA. Even when both products are defined, they usually give different results — and often only one of them is defined.
Check the orders before starting. A 3×2 matrix cannot multiply another 3×2 (since 23). A 3×2 can multiply a 2×4 to give a 3×4 result.
A2 is not entry-by-entry squaring. A2=A×A using the row-by-column rule. The matrix you get this way is very different from the one you'd get by squaring each entry separately.
Powers are square-only. A2 only makes sense when A is a square matrix. If A is 2×3, then A×A is undefined (inner dimensions 32).
Row × column, not column × row. The rule pairs the i-th row of the LEFT matrix with the j-th column of the RIGHT matrix. Mixing up which side is which gives the wrong answer.

Frequently asked questions

When is the product AB defined?

Only when the number of columns of A equals the number of rows of B. If A is m by n and B is n by p, then AB is defined and has order m by p. If the inner dimensions do not match, the product does not exist.

How do I compute each entry of AB?

Each entry (AB) subscript ij is found by taking the i-th row of A and the j-th column of B, multiplying matching entries together, and adding the results. This is called the row-by-column rule.

Is matrix multiplication commutative?

No. In general AB does not equal BA. Sometimes only one of the two is even defined. Always do the multiplication in the order asked.

What is A squared?

A squared means A times A using the row-by-column rule. It is only defined for square matrices, because you need A's columns to match A's rows. A squared is NOT the same as squaring each entry.

What is the identity matrix's role in multiplication?

Multiplying any matrix A by the identity matrix I of the right size leaves A unchanged. That is, AI equals IA equals A. The identity plays the role of the number 1 in ordinary multiplication.

How do I find a missing entry in a matrix product?

Use the row-by-column rule to write the equation for the entry that contains the unknown. That gives one linear equation in one variable, which you can solve directly.

Video Lessons

Practice Questions

20 questions available.

Practice Questions