Lesson 8: Matrices, Vectors & Transformations

Cambridge O Level Mathematics 4024 / IGCSE Mathematics 0580 — Syllabus Reference: Matrices, Vectors & Transformations

Lesson 8 of 10
80% complete

1. Matrices

A matrix is a rectangular array of numbers arranged in rows and columns. The order of a matrix is written as rows × columns (m × n).

Matrix Order: A matrix with m rows and n columns has order m × n.
A (2×3) matrix has 2 rows and 3 columns — it has 6 elements total.
A square matrix has equal numbers of rows and columns (2×2, 3×3, etc.)

Matrix Addition and Subtraction

Rule: Matrices can only be added or subtracted if they have the same order. Add or subtract corresponding elements.

📐 Worked Example 1 — Addition and Subtraction

A = [[3, 1], [−2, 4]] and B = [[5, −3], [1, 2]]. Find A + B and A − B.

1
A + B: Add corresponding elements:
[[3+5, 1+(−3)], [−2+1, 4+2]] = [[8, −2], [−1, 6]]
2
A − B: Subtract corresponding elements:
[[3−5, 1−(−3)], [−2−1, 4−2]] = [[−2, 4], [−3, 2]]

Scalar Multiplication

Rule: Multiply every element of the matrix by the scalar (number).
k × [[a, b], [c, d]] = [[ka, kb], [kc, kd]]

Matrix Multiplication

Condition: Matrix A (m×n) can be multiplied by Matrix B (n×p) only if the number of columns of A = rows of B. The result has order m×p.
AB ≠ BA in general — matrix multiplication is NOT commutative.
Method — Row × Column:
Each element of the product is found by multiplying a ROW of the first matrix by a COLUMN of the second matrix and summing.
(AB)ᵢⱼ = row i of A · column j of B = Σ aᵢₖ × bₖⱼ

📐 Worked Example 2 — Matrix Multiplication

A = [[2, 3], [1, −1]] and B = [[4, 0], [2, 5]]. Find AB and BA.

1
AB: Both 2×2, result is 2×2.
Position (1,1): Row 1 of A × Col 1 of B = (2×4)+(3×2) = 8+6 = 14
Position (1,2): Row 1 of A × Col 2 of B = (2×0)+(3×5) = 0+15 = 15
Position (2,1): Row 2 of A × Col 1 of B = (1×4)+(−1×2) = 4−2 = 2
Position (2,2): Row 2 of A × Col 2 of B = (1×0)+(−1×5) = 0−5 = −5
AB = [[14, 15], [2, −5]]
2
BA:
(1,1): (4×2)+(0×1)=8   (1,2): (4×3)+(0×−1)=12
(2,1): (2×2)+(5×1)=9   (2,2): (2×3)+(5×−1)=1
BA = [[8, 12], [9, 1]]
AB ≠ BA ✓ (confirms non-commutativity)

Determinant and Inverse of a 2×2 Matrix

For matrix M = [[a, b], [c, d]]:

Determinant: det(M) = |M| = ad − bc
Inverse: M⁻¹ = (1/det(M)) × [[d, −b], [−c, a]]

The inverse exists only when det(M) ≠ 0. If det(M) = 0, the matrix is singular and has no inverse.

Finding M⁻¹ — Three Steps:
1. Calculate det(M) = ad − bc. If zero → no inverse.
2. Swap a and d (the main diagonal elements).
3. Change signs of b and c (the off-diagonal elements).
4. Multiply the resulting matrix by 1/det(M).

📐 Worked Example 3 — Determinant and Inverse

Find the inverse of M = [[5, 2], [3, 1]].

1
Calculate determinant:
det(M) = (5×1) − (2×3) = 5 − 6 = −1
2
Swap main diagonal (5 and 1), change signs of off-diagonal (2→−2, 3→−3):
Adjugate = [[1, −2], [−3, 5]]
3
Multiply by 1/det = 1/(−1) = −1:
M⁻¹ = −1 × [[1, −2], [−3, 5]] = [[−1, 2], [3, −5]]
4
Check: M × M⁻¹ should = Identity matrix I = [[1,0],[0,1]]
[[5,2],[3,1]] × [[−1,2],[3,−5]] = [[−5+6, 10−10],[−3+3, 6−5]] = [[1,0],[0,1]] ✓

Using Matrices to Solve Simultaneous Equations

📐 Worked Example 4 — Matrix Method for Simultaneous Equations

Solve using matrices: 3x + 2y = 8 and 5x + 4y = 14.

1
Write as matrix equation MX = B:
[[3, 2], [5, 4]] [[x], [y]] = [[8], [14]]
2
Find M⁻¹: det = 3×4 − 2×5 = 12−10 = 2
M⁻¹ = (½) [[4, −2], [−5, 3]]
3
X = M⁻¹B:
[[x],[y]] = (½) [[4,−2],[−5,3]] [[8],[14]]
= (½) [[32−28],[−40+42]] = (½) [[4],[2]] = [[2],[1]]
x = 2, y = 1

2. Vectors

Vector: A quantity with both magnitude (size) and direction. Represented as an arrow, a column vector, or bold/underlined letters.
A scalar has magnitude only (no direction) — e.g. speed, mass, temperature.

Vector Notation

Ways to Write Vectors

  • Column vector: (x over y) — x is horizontal, y is vertical
  • Bold letter: a or b
  • Arrow notation: AB⃗ (from A to B)
  • Underline: a (used in handwriting)

Magnitude (Length) of a Vector

For vector v = (x over y):

|v| = √(x² + y²)

Example: v = (3 over 4) → |v| = √(9+16) = √25 = 5

Vector Operations

OperationRuleExample
Addition Add corresponding components. Geometrically: place tail of second at head of first. (3 over 2) + (−1 over 4) = (2 over 6)
Subtraction Subtract corresponding components. AB = b − a (position vectors). (5 over 3) − (2 over 1) = (3 over 2)
Scalar multiplication Multiply each component by the scalar. Changes magnitude; direction same (or reversed if negative). 3 × (2 over −1) = (6 over −3)
Negative vector −a has same magnitude as a but opposite direction. If AB⃗ = (3 over 4), then BA⃗ = (−3 over −4)

Position Vectors

Position Vector: The vector from the origin O to a point P, written OP⃗ or p. If A has position vector a and B has position vector b, then:
AB⃗ = b − a (vector from A to B = position vector of B minus position vector of A)

📐 Worked Example 5 — Position Vectors

O is the origin. A has position vector a = (2 over 5) and B has position vector b = (8 over 1). Find (a) AB⃗ (b) the midpoint M of AB (c) |AB|.

1
(a) AB⃗ = b − a:
AB⃗ = (8 over 1) − (2 over 5) = (6 over −4)
2
(b) Midpoint M: Position vector of M = ½(a + b)
OM⃗ = ½[(2 over 5) + (8 over 1)] = ½(10 over 6) = (5 over 3)
3
(c) |AB|:
|AB| = √(6² + (−4)²) = √(36+16) = √52 = 2√13 ≈ 7.21

Parallel Vectors and Collinear Points

Parallel Vectors: Two vectors are parallel if one is a scalar multiple of the other.
If AB⃗ = k × AC⃗, then A, B, C are collinear (lie on the same straight line) AND B divides AC in ratio k:(1−k)... more precisely in ratio |k|:1.

To prove collinearity: Show that AB⃗ = k × AC⃗ for some scalar k. Since they share point A, they must be on the same line.

📐 Worked Example 6 — Vector Proof (Collinearity)

OA⃗ = a, OB⃗ = b. M is the midpoint of AB. N is the point on OB such that ON = ⅓OB. Prove that O, N, M are NOT collinear by finding ON⃗ and OM⃗.

1
ON⃗ = ⅓b (given ON = ⅓OB)
2
OM⃗ = OA⃗ + AM⃗ = a + ½AB⃗ = a + ½(b−a) = ½a + ½b
3
Is OM⃗ a scalar multiple of ON⃗?
ON⃗ = ⅓b. OM⃗ = ½a + ½b.
For OM⃗ = k(⅓b), we need ½a + ½b = (k/3)b, which requires ½a = 0, impossible (a ≠ 0).
Therefore O, N, M are not collinear.

3. Transformations

A transformation maps every point of a shape (object) to a new position (image). The four transformations required are: reflection, rotation, translation, and enlargement.

Key Terms:
Object — the original shape before transformation
Image — the shape after transformation
Invariant points — points that do not move under the transformation
Congruent — same shape and size (reflections, rotations, translations)
Similar — same shape but different size (enlargements)

Transformation 1 — Reflection

Reflection

Every point is mapped to its mirror image in a mirror line. Distance from object to mirror line = distance from image to mirror line (perpendicular).

Mirror LineEffect on (x, y)
x-axis (y = 0)(x, y) → (x, −y)
y-axis (x = 0)(x, y) → (−x, y)
y = x(x, y) → (y, x)
y = −x(x, y) → (−y, −x)
x = a (vertical line)(x, y) → (2a−x, y)
y = b (horizontal line)(x, y) → (x, 2b−y)

To describe: State "Reflection in the line y = ..."

Transformation 2 — Rotation

Rotation

Every point turns through a given angle about a fixed point called the centre of rotation. Anticlockwise is positive; clockwise is negative.

Rotation about OriginEffect on (x, y)
90° anticlockwise(x, y) → (−y, x)
90° clockwise (= 270° anticlockwise)(x, y) → (y, −x)
180° (either direction)(x, y) → (−x, −y)

To describe: State "Rotation, [angle and direction], about [centre]"
To find centre: Perpendicular bisectors of any two corresponding sides meet at the centre.

Transformation 3 — Translation

Translation

Every point moves by the same vector — the translation vector (a over b) moves every point a units right and b units up (negative = left/down).

Effect: (x, y) → (x + a, y + b)

Properties: Shape, size, and orientation are all preserved. No invariant points (unless vector is zero).

To describe: State "Translation by vector (a over b)".

Transformation 4 — Enlargement

Enlargement

Every point is mapped from a fixed point called the centre of enlargement by a scale factor k.

Scale factor k > 1: Enlargement (image bigger than object)
0 < k < 1: Reduction (image smaller than object)
k negative: Enlargement on opposite side of centre

PropertyObjectImage
Lengthlk × l
AreaAk² × A
Anglesθθ (unchanged)

To describe: State "Enlargement, scale factor k, centre (a, b)"

📐 Worked Example 7 — Applying Transformations

Triangle T has vertices A(1,1), B(3,1), C(3,4). Find the image under: (a) Reflection in y=x (b) Rotation 90° anticlockwise about origin (c) Translation by (−2 over 3) (d) Enlargement scale factor 2, centre origin.

1
(a) Reflection in y=x: (x,y)→(y,x)
A(1,1)→(1,1), B(3,1)→(1,3), C(3,4)→(4,3)
2
(b) Rotation 90° anticlockwise: (x,y)→(−y,x)
A(1,1)→(−1,1), B(3,1)→(−1,3), C(3,4)→(−4,3)
3
(c) Translation (−2 over 3): (x,y)→(x−2, y+3)
A→(−1,4), B→(1,4), C→(1,7)
4
(d) Enlargement SF=2, centre O: (x,y)→(2x,2y)
A→(2,2), B→(6,2), C→(6,8)

Describing a Transformation from a Diagram

How to Fully Describe Each Transformation:
Reflection: "Reflection in the line y = ..." (must give the mirror line equation)
Rotation: "Rotation of [angle]° [anticlockwise/clockwise] about the point ([x],[y])"
Translation: "Translation by the vector ([a] over [b])"
Enlargement: "Enlargement with scale factor [k] and centre ([x],[y])"

One mark is lost for every missing detail. In Cambridge, all four pieces of information are required for full marks.

4. Transformations Using Matrices

Every linear transformation can be represented by a 2×2 matrix. To find the image of a point (x, y), multiply the transformation matrix by the column vector of the point.

Applying a Transformation Matrix

Image = M × [[x], [y]]

For a shape, apply to each vertex separately.

Standard Transformation Matrices

TransformationMatrix MCheck: maps (1,0) to...
Reflection in x-axis[[1, 0], [0, −1]](1, 0) ✓
Reflection in y-axis[[−1, 0], [0, 1]](−1, 0) ✓
Reflection in y = x[[0, 1], [1, 0]](0, 1) ✓
Reflection in y = −x[[0, −1], [−1, 0]](0, −1) ✓
Rotation 90° anticlockwise[[0, −1], [1, 0]](0, 1) ✓
Rotation 90° clockwise[[0, 1], [−1, 0]](0, −1) ✓
Rotation 180°[[−1, 0], [0, −1]](−1, 0) ✓
Enlargement SF k (centre O)[[k, 0], [0, k]](k, 0) ✓

📐 Worked Example 8 — Transformation Matrix

Matrix M = [[0, −1], [1, 0]]. (a) Describe the transformation represented by M. (b) Find the image of triangle with vertices P(2,0), Q(4,0), R(4,3) under M. (c) Find M².

1
(a) M = [[0,−1],[1,0]] is the matrix for Rotation 90° anticlockwise about the origin.
2
(b) Apply M to each vertex:
P(2,0): [[0,−1],[1,0]]×(2 over 0) = (0 over 2) → P'(0,2)
Q(4,0): → Q'(0,4)
R(4,3): [[0,−1],[1,0]]×(4 over 3) = (−3 over 4) → R'(−3,4)
3
(c) M² = M × M = [[0,−1],[1,0]] × [[0,−1],[1,0]]
(1,1): 0×0+(−1)×1=−1   (1,2): 0×(−1)+(−1)×0=0
(2,1): 1×0+0×1=0      (2,2): 1×(−1)+0×0=−1
M² = [[−1, 0], [0, −1]] = Rotation 180° ✓ (two 90° turns = 180°)

Finding the Matrix from a Transformation

Method — Using Base Vectors:
The columns of the transformation matrix M are the images of the standard unit vectors:
• Column 1 of M = image of (1 over 0)
• Column 2 of M = image of (0 over 1)

Example: If a transformation maps (1,0)→(0,1) and (0,1)→(−1,0), then M = [[0,−1],[1,0]] (which is rotation 90° anticlockwise).

📐 Worked Example 9 — Finding a Transformation Matrix

A transformation maps A(3,0) to A'(0,3) and B(0,2) to B'(−2,0). Find the transformation matrix and describe the transformation.

1
Find image of (1,0): Since (3,0)→(0,3), dividing by 3: (1,0)→(0,1)
Column 1 of M = (0 over 1)
2
Find image of (0,1): Since (0,2)→(−2,0), dividing by 2: (0,1)→(−1,0)
Column 2 of M = (−1 over 0)
3
M = [[0, −1], [1, 0]]
This is a Rotation of 90° anticlockwise about the origin.

Combined Transformations

Combined Transformation Matrix: If transformation A is followed by transformation B, the combined matrix is BA (note: B first written, A applied first).
To apply: Image = B(A(X)) = (BA)X
The order matters — BA ≠ AB in general.

📝 Exam Practice Questions

Q1 [4 marks] — A = [[3, 1], [2, −1]] and B = [[−1, 2], [3, 0]]. Find (a) 2A − B (b) AB (c) det(A) (d) A⁻¹.

(a) 2A = [[6,2],[4,−2]]. 2A−B = [[6−(−1), 2−2],[4−3, −2−0]] = [[7,0],[1,−2]]

(b) AB: (1,1)=3(−1)+1(3)=0; (1,2)=3(2)+1(0)=6; (2,1)=2(−1)+(−1)(3)=−5; (2,2)=2(2)+(−1)(0)=4
AB = [[0,6],[−5,4]]

(c) det(A) = 3×(−1)−1×2 = −3−2 = −5

(d) A⁻¹ = (1/−5)×[[−1,−1],[−2,3]] = [[1/5, 1/5],[2/5, −3/5]]

Q2 [3 marks] — OA⃗ = (4 over −1) and OB⃗ = (−2 over 5). Find (a) AB⃗ (b) |AB| (c) the midpoint M of AB.

(a) AB⃗ = OB⃗ − OA⃗ = (−2−4 over 5−(−1)) = (−6 over 6)

(b) |AB| = √(36+36) = √72 = 6√2 ≈ 8.49

(c) M = ½(OA⃗+OB⃗) = ½(2 over 4) = (1 over 2)

Q3 [4 marks] — OA⃗ = 2a, OB⃗ = 3b. C divides AB in ratio 1:2. D is the midpoint of OB. Find OC⃗ and OD⃗. Hence show that C, D and the origin O are NOT collinear.

AB⃗ = OB⃗ − OA⃗ = 3b − 2a
OC⃗ = OA⃗ + (1/3)AB⃗ = 2a + (1/3)(3b−2a) = 2a + b − (2/3)a = (4/3)a + b
OD⃗ = (1/2)OB⃗ = (3/2)b

For collinearity with O: OC⃗ must be a scalar multiple of OD⃗.
OD⃗ = (3/2)b, but OC⃗ = (4/3)a + b contains a component in direction a.
Since a and b are not parallel, OC⃗ cannot be a scalar multiple of OD⃗ → O, C, D are not collinear. ✓

Q4 [4 marks] — Describe fully each transformation that maps shape P to shape Q, given: (a) P has vertices (1,1),(3,1),(3,2) and Q has vertices (−1,1),(−3,1),(−3,2) (b) P maps to Q' with vertices (1,−1),(3,−1),(3,−2) (c) P maps to Q'' with vertices (3,3),(9,3),(9,6).

(a) (1,1)→(−1,1): x-coordinate negated, y unchanged.
Reflection in the y-axis (x = 0)

(b) (1,1)→(1,−1): y-coordinate negated, x unchanged.
Reflection in the x-axis (y = 0)

(c) (1,1)→(3,3): each coordinate multiplied by 3. Centre must be origin (O maps to O).
Enlargement, scale factor 3, centre the origin (0,0)
Exam Tip: For each transformation, check: Are lengths preserved? (No → enlargement). Are orientations preserved? (No → reflection possible). Is there a fixed centre? Test (0,0) in enlargement. Always give ALL required details.

Q5 [4 marks] — M = [[0, 1], [−1, 0]]. (a) Describe the transformation M represents. (b) Find M³. (c) Describe the transformation M³ represents. (d) Find M⁴ and explain your answer.

(a) M maps (1,0)→(0,−1) and (0,1)→(1,0). Rotation 90° clockwise about origin.

(b) M² = M×M: (1,1)=0×0+1×(−1)=−1; (1,2)=0×1+1×0=0; (2,1)=(−1)×0+0×(−1)=0; (2,2)=(−1)×1+0×0=−1
M² = [[−1,0],[0,−1]] (rotation 180°)
M³ = M²×M = [[−1,0],[0,−1]]×[[0,1],[−1,0]]: (1,1)=0; (1,2)=−1; (2,1)=1; (2,2)=0
M³ = [[0,−1],[1,0]]

(c) M³ = Rotation 90° anticlockwise about origin. (Three 90° clockwise = 270° clockwise = 90° anticlockwise ✓)

(d) M⁴ = M³×M = [[0,−1],[1,0]]×[[0,1],[−1,0]] = [[1,0],[0,1]] = Identity matrix.
Four 90° clockwise rotations = 360° = back to original position.

Q6 [3 marks] — Use matrices to solve: 2x − y = 7 and x + 3y = 0.

Matrix form: [[2,−1],[1,3]][[x],[y]] = [[7],[0]]
det = 2×3−(−1)×1 = 6+1 = 7
Inverse = (1/7)[[3,1],[−1,2]]
Solution: [[x],[y]] = (1/7)[[3,1],[−1,2]][[7],[0]] = (1/7)[[21],[−7]] = [[3],[−1]]
x = 3, y = −1. Check: 2(3)−(−1)=7 ✓, 3+(3×−1)=0 ✓
← Lesson 7: Trigonometry Lesson 9: Statistics & Probability →