Lesson 9 · Transformation Using Matrix

Transformation Using Matrix

Optional MathematicsSubject
8 minEstimated read

Writing a Point as a Matrix

A transformation moves every point of a figure to a new position by one fixed rule. Reflection, rotation, enlargement and translation are all rules of this kind. Until now each rule has been written in words or as a rule on coordinates. Here the same rules are written as matrices, so that finding an image becomes a matrix calculation.

To use a matrix at all, the point itself must first be written as a matrix. A point \( A(x, y) \) is written as a column matrix of order \( 2 \times 1 \). The x-coordinate goes on top and the y-coordinate goes below it:

\[ A(x, y) = \begin{pmatrix} x \\ y \end{pmatrix} \]

So the point \( (4, -3) \) is written \( \begin{pmatrix} 4 \\ -3 \end{pmatrix} \). A figure with several vertices is written by standing the columns of its vertices side by side, in order. A triangle with vertices \( (1, 2) \), \( (4, 1) \) and \( (2, 5) \) becomes one matrix:

\[ \begin{pmatrix} 1 & 4 & 2 \\ 2 & 1 & 5 \end{pmatrix} \]

The top row holds every x-coordinate and the bottom row holds every y-coordinate. The number of columns is the number of vertices. A line segment gives a matrix of order \( 2 \times 2 \), a triangle gives \( 2 \times 3 \) and a quadrilateral gives \( 2 \times 4 \). This matrix of the figure is called the object matrix, and the matrix of its image is called the image matrix.

Definition

Matrix transformation: when the coordinates of a point or of a geometric figure are transformed by using a matrix, in a fixed direction and through a fixed distance or by a fixed rule, the transformation is called a matrix transformation.

Translation Using a 2 × 1 Matrix

When a point \( A(x, y) \) is transformed by a \( 2 \times 1 \) matrix \( \begin{pmatrix} a \\ b \end{pmatrix} \), the point is simply displaced. It moves \( a \) units along the X-axis and \( b \) units along the Y-axis. This is a translation, and the \( 2 \times 1 \) matrix is the translation vector:

\[ A(x, y) \xrightarrow{\begin{pmatrix} a \\ b \end{pmatrix}} A'(x + a,\ y + b) \]

Written with matrices, the image is found by adding the translation vector to the object:

\[ \begin{pmatrix} x \\ y \end{pmatrix} + \begin{pmatrix} a \\ b \end{pmatrix} = \begin{pmatrix} x + a \\ y + b \end{pmatrix} \]

Definition

Translation by a 2 × 1 matrix: Image (I) = Object (O) + Translation vector (T).

Worked example. The point \( A(-2, 1) \) is translated by the vector \( T = \begin{pmatrix} 5 \\ 2 \end{pmatrix} \). Find its image.

Step 1: Writing the object as a column matrix:

\[ O = \begin{pmatrix} -2 \\ 1 \end{pmatrix} \]

Step 2: Adding the translation vector to the object, since a translation always adds:

\[ I = \begin{pmatrix} -2 \\ 1 \end{pmatrix} + \begin{pmatrix} 5 \\ 2 \end{pmatrix} = \begin{pmatrix} 3 \\ 3 \end{pmatrix} \]

So the image is \( A'(3, 3) \). On a graph, A moves 5 units to the right and then 2 units up.

The point A(-2, 1) moves 5 units to the right and 2 units up, reaching its image A'(3, 3) under the translation vector with components 5 and 2.
The point A(-2, 1) moves 5 units to the right and 2 units up, reaching its image A'(3, 3) under the translation vector with components 5 and 2.
Key idea

A translation is the only transformation here that uses a 2 × 1 matrix, and it is ADDED to the point. Every other transformation in this topic uses a 2 × 2 matrix that MULTIPLIES the point.

Transformation Using a 2 × 2 Matrix

Let \( M = \begin{pmatrix} a & b \\ c & d \end{pmatrix} \) be a \( 2 \times 2 \) matrix, and let a point \( P(x, y) \) be written as \( \begin{pmatrix} x \\ y \end{pmatrix} \). When M multiplies this column matrix from the left, the answer is another column matrix \( \begin{pmatrix} x_1 \\ y_1 \end{pmatrix} \):

\[ \begin{pmatrix} a & b \\ c & d \end{pmatrix} \begin{pmatrix} x \\ y \end{pmatrix} = \begin{pmatrix} ax + by \\ cx + dy \end{pmatrix} \]

Here \( x_1 = ax + by \) and \( y_1 = cx + dy \). So the matrix M sends \( P(x, y) \) to the image \( P'(ax + by,\ cx + dy) \). Each new coordinate is built from BOTH old coordinates. That is exactly what a reflection or a rotation needs: in a reflection in the line \( y = x \), for example, the new x-coordinate is the old y-coordinate. A \( 2 \times 1 \) matrix can only add fixed numbers, so it can never swap or mix the coordinates. This is why reflections, rotations and enlargements need a \( 2 \times 2 \) matrix.

Definition

For a 2 × 2 transformation: Image matrix (I) = Transformation matrix (M) × Object matrix (O). The transformation matrix is also written TM.

\[ I_{2 \times n} = M_{2 \times 2} \times O_{2 \times n} \]

Here n is the number of vertices of the object: 2 for a line segment, 3 for a triangle and 4 for a quadrilateral. The image always has the same number of vertices as the object.

Common mistake

The transformation matrix is always written on the LEFT: M × O, never O × M. Matrix multiplication does not allow the order to be swapped. For a triangle, O × M would be a 2 × 3 matrix times a 2 × 2 matrix, which cannot even be multiplied.

Matrix for Reflection in the X-axis

Every standard matrix can be found by one method. Write down the image the transformation gives, write each new coordinate as a number times x plus a number times y, and then read those numbers into the rows of the matrix. Reflection in the X-axis shows the method first.

When \( P(x, y) \) is reflected in the X-axis (the line \( y = 0 \)), its image is \( P'(x, -y) \). Let the image be written \( P'(x', y') \). Comparing the two forms of the image:

\[ P'(x', y') = P'(x, -y) \]

Step 1: Writing the new x-coordinate using both x and y:

\[ x' = x = 1 \times x + 0 \times y \quad \text{(i)} \]

Step 2: Writing the new y-coordinate in the same way:

\[ y' = -y = 0 \times x + (-1) \times y \quad \text{(ii)} \]

Step 3: Writing equations (i) and (ii) in matrix form. The numbers in front of x and y in (i) make the top row, and those in (ii) make the bottom row:

\[ \begin{pmatrix} x' \\ y' \end{pmatrix} = \begin{pmatrix} 1 & 0 \\ 0 & -1 \end{pmatrix} \begin{pmatrix} x \\ y \end{pmatrix} \]

So the \( 2 \times 2 \) matrix for reflection in the X-axis is \( \begin{pmatrix} 1 & 0 \\ 0 & -1 \end{pmatrix} \). In this equation, \( \begin{pmatrix} x' \\ y' \end{pmatrix} \) is the image matrix, \( \begin{pmatrix} 1 & 0 \\ 0 & -1 \end{pmatrix} \) is the transformation matrix and \( \begin{pmatrix} x \\ y \end{pmatrix} \) is the object matrix.

Matrix for Rotation of +90° About the Origin

A positive angle of rotation means anticlockwise. When \( P(x, y) \) is rotated through \( +90^\circ \) about the origin, written \( R[(0, 0), +90^\circ] \), its image is \( P'(-y, x) \). Let the image be \( P'(x', y') \), so \( P'(x', y') = P'(-y, x) \).

Step 1: Writing the new x-coordinate using both x and y:

\[ x' = -y = 0 \times x + (-1) \times y \quad \text{(i)} \]

Step 2: Writing the new y-coordinate in the same way:

\[ y' = x = 1 \times x + 0 \times y \quad \text{(ii)} \]

Step 3: Writing (i) and (ii) in matrix form:

\[ \begin{pmatrix} x' \\ y' \end{pmatrix} = \begin{pmatrix} 0 & -1 \\ 1 & 0 \end{pmatrix} \begin{pmatrix} x \\ y \end{pmatrix} \]

So the \( 2 \times 2 \) matrix for a rotation of \( +90^\circ \) about the origin is \( \begin{pmatrix} 0 & -1 \\ 1 & 0 \end{pmatrix} \).

Matrix for Enlargement About the Origin

When \( P(x, y) \) is enlarged with centre \( (0, 0) \) and scale factor k, written \( E[(0, 0), k] \), its image is \( P'(kx, ky) \). Let the image be \( P'(x', y') \), so \( P'(x', y') = P'(kx, ky) \).

Step 1: Writing the new x-coordinate using both x and y:

\[ x' = kx = k \times x + 0 \times y \quad \text{(i)} \]

Step 2: Writing the new y-coordinate in the same way:

\[ y' = ky = 0 \times x + k \times y \quad \text{(ii)} \]

Step 3: Writing (i) and (ii) in matrix form:

\[ \begin{pmatrix} x' \\ y' \end{pmatrix} = \begin{pmatrix} k & 0 \\ 0 & k \end{pmatrix} \begin{pmatrix} x \\ y \end{pmatrix} \]

So the \( 2 \times 2 \) matrix for enlargement with centre \( (0, 0) \) and scale factor k is \( \begin{pmatrix} k & 0 \\ 0 & k \end{pmatrix} \). For example, \( E[(0, 0), 3] \) has the matrix \( \begin{pmatrix} 3 & 0 \\ 0 & 3 \end{pmatrix} \), and it sends \( (2, -1) \) to \( (6, -3) \).

Careful with the centre

These 2 × 2 matrices work only for reflections in lines through the origin, rotations about the origin and enlargements with centre (0, 0). A reflection in x = h or y = k, a rotation about another point, or an enlargement about another centre also shifts the figure, and a 2 × 2 matrix alone cannot do that.

Table of Standard Transformation Matrices

Using the same method for every transformation gives the table below. In each row the object is the point \( P(x, y) \).

TransformationImage of P(x, y)2 × 2 matrix
Reflection in the X-axis\( P'(x, -y) \)\( \begin{pmatrix} 1 & 0 \\ 0 & -1 \end{pmatrix} \)
Reflection in the Y-axis\( P'(-x, y) \)\( \begin{pmatrix} -1 & 0 \\ 0 & 1 \end{pmatrix} \)
Reflection in \( y = x \) or \( y - x = 0 \)\( P'(y, x) \)\( \begin{pmatrix} 0 & 1 \\ 1 & 0 \end{pmatrix} \)
Reflection in \( y = -x \) or \( y + x = 0 \)\( P'(-y, -x) \)\( \begin{pmatrix} 0 & -1 \\ -1 & 0 \end{pmatrix} \)
\( R[(0, 0), +90^\circ] \) or \( R[(0, 0), -270^\circ] \)\( P'(-y, x) \)\( \begin{pmatrix} 0 & -1 \\ 1 & 0 \end{pmatrix} \)
\( R[(0, 0), -90^\circ] \) or \( R[(0, 0), +270^\circ] \)\( P'(y, -x) \)\( \begin{pmatrix} 0 & 1 \\ -1 & 0 \end{pmatrix} \)
\( R[(0, 0), \pm 180^\circ] \)\( P'(-x, -y) \)\( \begin{pmatrix} -1 & 0 \\ 0 & -1 \end{pmatrix} \)
\( R[(0, 0), \pm 360^\circ] \)\( P'(x, y) \)\( \begin{pmatrix} 1 & 0 \\ 0 & 1 \end{pmatrix} \)
Enlargement \( E[(0, 0), k] \)\( P'(kx, ky) \)\( \begin{pmatrix} k & 0 \\ 0 & k \end{pmatrix} \)
Key idea

A quick way to rebuild any row: the FIRST column of the matrix is where the point (1, 0) goes, and the SECOND column is where the point (0, 1) goes. Reflection in y = x sends (1, 0) to (0, 1) and (0, 1) to (1, 0), so its columns are (0, 1) and (1, 0).

Notice the last rotation. A rotation through a full \( 360^\circ \) brings every point back to where it started, so its matrix \( \begin{pmatrix} 1 & 0 \\ 0 & 1 \end{pmatrix} \) changes nothing. This matrix is the identity matrix.

The Unit Square

Definition

Unit square: a square each of whose sides is 1 unit long. The unit square OABC has vertices O(0, 0), A(1, 0), B(1, 1) and C(0, 1).

The unit square OABC, with vertices O(0, 0), A(1, 0), B(1, 1) and C(0, 1), sits in the first quadrant with one corner at the origin.
The unit square OABC, with vertices O(0, 0), A(1, 0), B(1, 1) and C(0, 1), sits in the first quadrant with one corner at the origin.

Written as a matrix, with its vertices in the order O, A, B, C, the unit square is:

\[ \begin{pmatrix} 0 & 1 & 1 & 0 \\ 0 & 0 & 1 & 1 \end{pmatrix} \]

The unit square is useful because of what happens when any \( 2 \times 2 \) matrix multiplies it. Take \( M = \begin{pmatrix} a & b \\ c & d \end{pmatrix} \):

\[ \begin{pmatrix} a & b \\ c & d \end{pmatrix} \begin{pmatrix} 0 & 1 & 1 & 0 \\ 0 & 0 & 1 & 1 \end{pmatrix} \]

\[ = \begin{pmatrix} 0 & a & a + b & b \\ 0 & c & c + d & d \end{pmatrix} \]

The origin stays where it is. The image of \( A(1, 0) \) is \( (a, c) \), which is the first column of M. The image of \( C(0, 1) \) is \( (b, d) \), which is the second column of M. The image of B is the sum of these two. So the unit square is changed into a parallelogram, and the matrix can be read straight off the images of A and C.

Worked example. A \( 2 \times 2 \) matrix changes the unit square OABC into the parallelogram with vertices \( O'(0, 0) \), \( A'(2, 1) \), \( B'(3, 4) \) and \( C'(1, 3) \). Find the matrix.

Step 1: The image of \( A(1, 0) \) is \( A'(2, 1) \), so the first column of M is:

\[ \begin{pmatrix} a \\ c \end{pmatrix} = \begin{pmatrix} 2 \\ 1 \end{pmatrix} \]

Step 2: The image of \( C(0, 1) \) is \( C'(1, 3) \), so the second column of M is:

\[ \begin{pmatrix} b \\ d \end{pmatrix} = \begin{pmatrix} 1 \\ 3 \end{pmatrix} \]

Step 3: Putting the two columns together:

\[ M = \begin{pmatrix} 2 & 1 \\ 1 & 3 \end{pmatrix} \]

Step 4: Checking with the fourth vertex. M should send \( B(1, 1) \) to \( B'(3, 4) \):

\[ \begin{pmatrix} 2 & 1 \\ 1 & 3 \end{pmatrix} \begin{pmatrix} 1 \\ 1 \end{pmatrix} = \begin{pmatrix} 3 \\ 4 \end{pmatrix} \]

The check works, so \( M = \begin{pmatrix} 2 & 1 \\ 1 & 3 \end{pmatrix} \).

Example: Finding and Using a Translation Matrix

Find the \( 2 \times 1 \) matrix that moves the point \( A(a, b) \) to \( A'(a + 2, b - 3) \). Then use it to find the image of the point \( (5, 7) \).

Step 1: Let the translation matrix be \( M = \begin{pmatrix} p \\ q \end{pmatrix} \). A translation adds p and q to the coordinates, so:

\[ A(a, b) \xrightarrow{\begin{pmatrix} p \\ q \end{pmatrix}} A'(a + p,\ b + q) \]

Step 2: The image is given as \( A'(a + 2, b - 3) \). Equating the x-coordinates of the two forms of the image:

\[ a + p = a + 2, \text{ so } p = 2 \]

Step 3: Equating the y-coordinates:

\[ b + q = b - 3, \text{ so } q = -3 \]

Step 4: So the translation matrix is:

\[ M = \begin{pmatrix} 2 \\ -3 \end{pmatrix} \]

Step 5: Adding this matrix to the object \( (5, 7) \), because Image = Object + Translation vector:

\[ I = \begin{pmatrix} 5 \\ 7 \end{pmatrix} + \begin{pmatrix} 2 \\ -3 \end{pmatrix} = \begin{pmatrix} 7 \\ 4 \end{pmatrix} \]

So the image of \( (5, 7) \) is \( (7, 4) \).

Identifying a Transformation from Its Matrix

To name the transformation a matrix stands for, multiply the matrix by a general point \( \begin{pmatrix} x \\ y \end{pmatrix} \). The image you get tells you the transformation, because each transformation has its own image of \( P(x, y) \).

Worked example 1. Which transformation does the matrix \( \begin{pmatrix} 0 & -1 \\ -1 & 0 \end{pmatrix} \) represent?

Step 1: Let the object be \( O = \begin{pmatrix} x \\ y \end{pmatrix} \). Multiplying, because Image = TM × Object:

\[ \begin{pmatrix} 0 & -1 \\ -1 & 0 \end{pmatrix} \begin{pmatrix} x \\ y \end{pmatrix} = \begin{pmatrix} 0x + (-1)y \\ (-1)x + 0y \end{pmatrix} \]

Step 2: Simplifying the image:

\[ = \begin{pmatrix} -y \\ -x \end{pmatrix} \]

So \( P(x, y) \) goes to \( P'(-y, -x) \). Both coordinates swap places and change sign, which is reflection in the line \( y = -x \).

Worked example 2. Which transformation does \( \begin{pmatrix} 0 & -1 \\ 1 & 0 \end{pmatrix} \) represent? Use the matrix to find the image of \( A(6, -2) \).

Step 1: Multiplying the matrix by a general point:

\[ \begin{pmatrix} 0 & -1 \\ 1 & 0 \end{pmatrix} \begin{pmatrix} x \\ y \end{pmatrix} = \begin{pmatrix} 0 \times x + (-1)y \\ 1 \times x + 0 \times y \end{pmatrix} \]

Step 2: Simplifying:

\[ = \begin{pmatrix} -y \\ x \end{pmatrix} \]

So \( P(x, y) \) goes to \( P'(-y, x) \). This is rotation through \( +90^\circ \) about the origin.

Step 3: Writing \( A(6, -2) \) as a matrix and multiplying:

\[ I = \begin{pmatrix} 0 & -1 \\ 1 & 0 \end{pmatrix} \begin{pmatrix} 6 \\ -2 \end{pmatrix} \]

Step 4: Multiplying each row by the column:

\[ I = \begin{pmatrix} 0 \times 6 + (-1)(-2) \\ 1 \times 6 + 0 \times (-2) \end{pmatrix} \]

Step 5: Working out each entry:

\[ I = \begin{pmatrix} 0 + 2 \\ 6 + 0 \end{pmatrix} = \begin{pmatrix} 2 \\ 6 \end{pmatrix} \]

So the image of \( A(6, -2) \) is \( A'(2, 6) \). The rule \( (-y, x) \) gives the same answer: \( (-(-2), 6) = (2, 6) \).

Deriving the Matrix for Reflection in the Line y = -x

Find the \( 2 \times 2 \) matrix for reflection in the line \( y = -x \). When \( P(x, y) \) is reflected in \( y = -x \), its image is \( P'(-y, -x) \). Let the image be \( P'(x', y') \), so \( P'(x', y') = P'(-y, -x) \).

Step 1: Writing the new x-coordinate using both x and y:

\[ x' = -y = 0 \times x + (-1) \times y \quad \text{(i)} \]

Step 2: Writing the new y-coordinate in the same way:

\[ y' = -x = (-1) \times x + 0 \times y \quad \text{(ii)} \]

Step 3: Writing (i) and (ii) in matrix form:

\[ \begin{pmatrix} x' \\ y' \end{pmatrix} = \begin{pmatrix} 0 & -1 \\ -1 & 0 \end{pmatrix} \begin{pmatrix} x \\ y \end{pmatrix} \]

So the matrix for reflection in \( y = -x \) is \( \begin{pmatrix} 0 & -1 \\ -1 & 0 \end{pmatrix} \), which agrees with the table.

Finding an Unknown Point

When the image and the matrix are known, the object can be found by writing the object with letters and equating the matrices. If the point \( P(a, b) \) is transformed by \( \begin{pmatrix} 0 & -2 \\ -2 & 0 \end{pmatrix} \) to \( P'(-10, -8) \), find a and b.

Step 1: Using Image = TM × Point, with the point written \( \begin{pmatrix} a \\ b \end{pmatrix} \):

\[ \begin{pmatrix} -10 \\ -8 \end{pmatrix} = \begin{pmatrix} 0 & -2 \\ -2 & 0 \end{pmatrix} \begin{pmatrix} a \\ b \end{pmatrix} \]

Step 2: Multiplying out the right-hand side:

\[ \begin{pmatrix} -10 \\ -8 \end{pmatrix} = \begin{pmatrix} -2b \\ -2a \end{pmatrix} \]

Step 3: Equating the top entries of the two equal matrices:

\[ -10 = -2b, \text{ so } b = 5 \]

Step 4: Equating the bottom entries:

\[ -8 = -2a, \text{ so } a = 4 \]

So \( a = 4 \) and \( b = 5 \), and the object is \( P(4, 5) \). Check: \( 0 \times 4 + (-2) \times 5 = -10 \) and \( (-2) \times 4 + 0 \times 5 = -8 \).

Transforming a Whole Figure

A whole figure is transformed in one multiplication by writing all its vertices in one object matrix. Find the image of triangle PQR with vertices \( P(4, 3) \), \( Q(6, 4) \) and \( R(8, 1) \) under the matrix \( \begin{pmatrix} 1 & 3 \\ 0 & 2 \end{pmatrix} \).

Step 1: Writing the vertices of the triangle as the object matrix, one column per vertex:

\[ O = \begin{pmatrix} 4 & 6 & 8 \\ 3 & 4 & 1 \end{pmatrix} \]

Step 2: Setting up Image = TM × Object:

\[ I = \begin{pmatrix} 1 & 3 \\ 0 & 2 \end{pmatrix} \begin{pmatrix} 4 & 6 & 8 \\ 3 & 4 & 1 \end{pmatrix} \]

Step 3: Multiplying the rows of TM by the first column, which is the image of P:

\[ \begin{pmatrix} 1 \times 4 + 3 \times 3 \\ 0 \times 4 + 2 \times 3 \end{pmatrix} = \begin{pmatrix} 13 \\ 6 \end{pmatrix} \]

Step 4: Multiplying by the second column, which is the image of Q:

\[ \begin{pmatrix} 1 \times 6 + 3 \times 4 \\ 0 \times 6 + 2 \times 4 \end{pmatrix} = \begin{pmatrix} 18 \\ 8 \end{pmatrix} \]

Step 5: Multiplying by the third column, which is the image of R:

\[ \begin{pmatrix} 1 \times 8 + 3 \times 1 \\ 0 \times 8 + 2 \times 1 \end{pmatrix} = \begin{pmatrix} 11 \\ 2 \end{pmatrix} \]

Step 6: Putting the three columns together as the image matrix:

\[ I = \begin{pmatrix} 13 & 18 & 11 \\ 6 & 8 & 2 \end{pmatrix} \]

So the vertices of the image triangle P'Q'R' are \( P'(13, 6) \), \( Q'(18, 8) \) and \( R'(11, 2) \).

Finding the Matrix from an Object and Its Image

When both the object and its image are known, the transformation matrix is found by letting it be \( \begin{pmatrix} a & b \\ c & d \end{pmatrix} \) and solving for the four letters. Each vertex of the object must go to the matching vertex of the image, so each column gives two equations.

Worked example 1. Find the \( 2 \times 2 \) matrix that changes triangle ABC with \( A(1, 2) \), \( B(4, 1) \), \( C(2, 5) \) into triangle A'B'C' with \( A'(5, 2) \), \( B'(6, 1) \), \( C'(12, 5) \).

Step 1: Let the matrix be \( M = \begin{pmatrix} a & b \\ c & d \end{pmatrix} \). M must send \( A(1, 2) \) to \( A'(5, 2) \):

\[ \begin{pmatrix} a & b \\ c & d \end{pmatrix} \begin{pmatrix} 1 \\ 2 \end{pmatrix} = \begin{pmatrix} a + 2b \\ c + 2d \end{pmatrix} = \begin{pmatrix} 5 \\ 2 \end{pmatrix} \]

Step 2: M must also send \( B(4, 1) \) to \( B'(6, 1) \):

\[ \begin{pmatrix} a & b \\ c & d \end{pmatrix} \begin{pmatrix} 4 \\ 1 \end{pmatrix} = \begin{pmatrix} 4a + b \\ 4c + d \end{pmatrix} = \begin{pmatrix} 6 \\ 1 \end{pmatrix} \]

Step 3: The top entries give \( a + 2b = 5 \) and \( 4a + b = 6 \). From the first equation:

\[ a = 5 - 2b \quad \text{(i)} \]

Step 4: Substituting (i) into \( 4a + b = 6 \):

\[ 4(5 - 2b) + b = 6 \]

\[ 20 - 7b = 6, \text{ so } b = 2 \]

Step 5: Putting \( b = 2 \) in (i):

\[ a = 5 - 2 \times 2 = 1 \]

Step 6: The bottom entries give \( c + 2d = 2 \) and \( 4c + d = 1 \). From the first:

\[ c = 2 - 2d \quad \text{(ii)} \]

Step 7: Substituting (ii) into \( 4c + d = 1 \):

\[ 4(2 - 2d) + d = 1 \]

\[ 8 - 7d = 1, \text{ so } d = 1 \]

Step 8: Putting \( d = 1 \) in (ii):

\[ c = 2 - 2 \times 1 = 0 \]

Step 9: Writing the matrix:

\[ M = \begin{pmatrix} 1 & 2 \\ 0 & 1 \end{pmatrix} \]

Step 10: Checking with the third vertex. M should send \( C(2, 5) \) to \( C'(12, 5) \):

\[ \begin{pmatrix} 1 & 2 \\ 0 & 1 \end{pmatrix} \begin{pmatrix} 2 \\ 5 \end{pmatrix} = \begin{pmatrix} 12 \\ 5 \end{pmatrix} \]

Always check

Two vertices are enough to find the four letters, so the remaining vertex is a free check. If the matrix does not send it to its image, there is a slip in the working. Go back before writing the answer.

Worked example 2. The square ABCD with \( A(2, 3) \), \( B(4, 3) \), \( C(4, 5) \), \( D(2, 5) \) is transformed by a \( 2 \times 2 \) matrix into A'B'C'D' with \( A'(3, 2) \), \( B'(3, 4) \), \( C'(5, 4) \), \( D'(5, 2) \). Find the matrix.

Step 1: Let \( M = \begin{pmatrix} a & b \\ c & d \end{pmatrix} \). Sending \( A(2, 3) \) to \( A'(3, 2) \) gives:

\[ \begin{pmatrix} 2a + 3b \\ 2c + 3d \end{pmatrix} = \begin{pmatrix} 3 \\ 2 \end{pmatrix} \]

Step 2: Sending \( B(4, 3) \) to \( B'(3, 4) \) gives:

\[ \begin{pmatrix} 4a + 3b \\ 4c + 3d \end{pmatrix} = \begin{pmatrix} 3 \\ 4 \end{pmatrix} \]

Step 3: Subtracting \( 2a + 3b = 3 \) from \( 4a + 3b = 3 \), since the b terms are equal and cancel:

\[ 2a = 0, \text{ so } a = 0 \]

Step 4: Putting \( a = 0 \) in \( 2a + 3b = 3 \):

\[ 3b = 3, \text{ so } b = 1 \]

Step 5: Subtracting \( 2c + 3d = 2 \) from \( 4c + 3d = 4 \):

\[ 2c = 2, \text{ so } c = 1 \]

Step 6: Putting \( c = 1 \) in \( 2c + 3d = 2 \):

\[ 3d = 0, \text{ so } d = 0 \]

Step 7: Writing the matrix:

\[ M = \begin{pmatrix} 0 & 1 \\ 1 & 0 \end{pmatrix} \]

Checking with C: \( 0 \times 4 + 1 \times 5 = 5 \) and \( 1 \times 4 + 0 \times 5 = 4 \), giving \( C'(5, 4) \) as required. Every vertex has had its coordinates swapped, so this matrix is reflection in the line \( y = x \).

Combined Transformations Using Matrices

Suppose a figure is transformed first by a matrix A and then its image is transformed by a matrix B. The first image is \( A \times O \). The second transformation multiplies this from the left:

\[ I = B \times (A \times O) = (BA) \times O \]

So the single matrix that does both jobs is the product BA. The matrix of the transformation done FIRST stands on the RIGHT, next to the object.

Worked example. Show that reflection in the line \( y = x \) followed by rotation through \( +90^\circ \) about the origin is equivalent to reflection in the Y-axis.

Step 1: Writing the matrix of the first transformation, reflection in \( y = x \):

\[ A = \begin{pmatrix} 0 & 1 \\ 1 & 0 \end{pmatrix} \]

Step 2: Writing the matrix of the second transformation, rotation through \( +90^\circ \) about the origin:

\[ B = \begin{pmatrix} 0 & -1 \\ 1 & 0 \end{pmatrix} \]

Step 3: Multiplying in the order BA, because A is done first:

\[ BA = \begin{pmatrix} 0 & -1 \\ 1 & 0 \end{pmatrix} \begin{pmatrix} 0 & 1 \\ 1 & 0 \end{pmatrix} \]

Step 4: Multiplying each row of B by each column of A:

\[ = \begin{pmatrix} 0 \times 0 + (-1) \times 1 & 0 \times 1 + (-1) \times 0 \\ 1 \times 0 + 0 \times 1 & 1 \times 1 + 0 \times 0 \end{pmatrix} \]

Step 5: Simplifying:

\[ BA = \begin{pmatrix} -1 & 0 \\ 0 & 1 \end{pmatrix} \]

This is exactly the matrix for reflection in the Y-axis, so the combined transformation is equivalent to reflection in the Y-axis. A check with one point agrees: \( (2, 5) \) reflected in \( y = x \) becomes \( (5, 2) \), and rotating \( (5, 2) \) through \( +90^\circ \) gives \( (-2, 5) \), which is the reflection of \( (2, 5) \) in the Y-axis.

Order matters

Matrix multiplication is not commutative, so AB and BA are usually different. Here AB works out to the matrix with rows (1, 0) and (0, -1), which is reflection in the X-axis. That is the wrong answer, obtained only by multiplying in the wrong order. Put the matrix of the first transformation on the right.

🔐

The full lesson is waiting for you

The notes are free to read in full. A free account opens the rest of the practice, and tracks your progress and confidence score for every subject. Presentations and videos need approval from Learn Yeti.