AP Precalculus · Unit 4 · Topic 4.13

    4.13 Matrices as Functions

    Reviewed by P V Satish, Senior Faculty of Science and Academic Consultant · PG Life Sciences, PGD Biotechnology · 20+ years teaching NEET and AP · Special interest in biotechnology, biochemistry and the basics of physics
    Updated

    Not on the AP Exam. Unit 4 is part of the AP Precalculus course, but College Board does not test it on the AP Exam. Learn it for your school tests and as preparation for calculus; for the exam itself, Units 1–3 are what count.

    In short

    A 2×22 \times 2 matrix AA is a function of the plane: LA(v)=AvL_A(\mathbf{v}) = A\mathbf{v}. Applying BB first and then AA is the composition LA(LB(v))=(AB)vL_A(L_B(\mathbf{v})) = (AB)\mathbf{v}, so the matrix of "B then A" is ABAB: the transformation applied first is written on the right. A transformation can be undone exactly when its matrix is invertible, and the inverse transformation has matrix A−1A^{-1}. This unit is not tested on the AP Exam.

    What you need to know

    • Treat a matrix as a function that maps vectors to vectors.
    • Find the matrix of a composition of two transformations.
    • Explain why the order of transformations matters.
    • Use an inverse matrix to undo a transformation and find a pre-image.

    Composition is multiplication

    In Topic 2.7, f(g(x))f(g(x)) means "do gg first, then ff". The same is true for matrices. Let B=[100−1]B = \begin{bmatrix} 1 & 0 \\ 0 & -1\end{bmatrix} reflect in the xx-axis and A=[0−110]A = \begin{bmatrix} 0 & -1 \\ 1 & 0\end{bmatrix} rotate a quarter turn counterclockwise. Follow the point (2,5)(2, 5):

    • Reflect first: B[25]=[2−5]B\begin{bmatrix} 2 \\ 5\end{bmatrix} = \begin{bmatrix} 2 \\ -5\end{bmatrix}.
    • Then rotate: A[2−5]=[52]A\begin{bmatrix} 2 \\ -5\end{bmatrix} = \begin{bmatrix} 5 \\ 2\end{bmatrix}.
    AB=[0−110][100−1]=[0110]AB = \begin{bmatrix} 0 & -1 \\ 1 & 0 \end{bmatrix}\begin{bmatrix} 1 & 0 \\ 0 & -1 \end{bmatrix} = \begin{bmatrix} 0 & 1 \\ 1 & 0 \end{bmatrix}

    The single matrix ABAB sends (2,5)(2, 5) straight to (5,2)(5, 2). It is the reflection in the line y=xy = x: reflecting in the xx-axis and then rotating a quarter turn is the same as one reflection in y=xy = x.

    Reflect in the x-axis, then rotate π/2: the net effect is a reflection in y = x.

    Why the order matters

    Do it the other way round, rotating first and reflecting second: BA=[0−1−10]BA = \begin{bmatrix} 0 & -1 \\ -1 & 0\end{bmatrix}, which sends (2,5)(2, 5) to (−5,−2)(-5, -2). That is the reflection in y=−xy = -x, a different transformation. This is the geometric reason AB≠BAAB \ne BA in Topic 4.10: putting on socks then shoes is not the same as shoes then socks.

    Undoing a transformation

    The inverse function LA−1L_A^{-1} must send each image back to where it came from, and its matrix is A−1A^{-1}. For the shear A=[1201]A = \begin{bmatrix} 1 & 2 \\ 0 & 1\end{bmatrix} (det⁡A=1\det A = 1), A−1=[1−201]A^{-1} = \begin{bmatrix} 1 & -2 \\ 0 & 1\end{bmatrix}. Which point is sent to (7,3)(7, 3)? Apply the inverse: A−1[73]=[13]A^{-1}\begin{bmatrix} 7 \\ 3\end{bmatrix} = \begin{bmatrix} 1 \\ 3\end{bmatrix}. Check: A[13]=[73]A\begin{bmatrix} 1 \\ 3\end{bmatrix} = \begin{bmatrix} 7 \\ 3\end{bmatrix}.

    To undo "B then A", undo A first and then B: (AB)−1=B−1A−1(AB)^{-1} = B^{-1}A^{-1}. If a matrix has determinant 0 it squashes different points onto the same image, so no function can send them back: the transformation has no inverse.

    Key terms

    Matrix as a function
    L_A(v) = Av, mapping each vector in the plane to a vector.
    Composition
    Applying one transformation after another; 'B then A' has matrix AB.
    Inverse transformation
    The transformation with matrix A⁻¹, which undoes A.
    Pre-image
    The point that a transformation sends to a given image; found with A⁻¹.

    Common mistakes

    • Writing the first transformation on the left: BA for 'B then A'.

      The first one goes on the right, next to the vector: AB.

    • Undoing AB with A⁻¹B⁻¹.

      (AB)⁻¹ = B⁻¹A⁻¹: undo the last step first.

    • Expecting every transformation to have an inverse.

      Only matrices with nonzero determinant are invertible.

    How this topic is tested

    • Test any composition on one easy point.
    • Say 'first on the right' when writing a product.
    • Unit 4 is not on the AP Exam; this is how computer graphics combine moves.

    Practice questions

    Original AP-style multiple-choice questions. Pick an answer to see the explanation.

    1. Question 1 · MP 3 · Communication and Reasoning

      BB is applied first and AA second. Which matrix represents the combined transformation?

    2. Question 2 · MP 1 · Procedural and Symbolic Fluency

      Let D=[2002]D = \begin{bmatrix} 2 & 0 \\ 0 & 2 \end{bmatrix} and R=[0−110]R = \begin{bmatrix} 0 & -1 \\ 1 & 0 \end{bmatrix}. Where does (1,3)(1, 3) go if you rotate with RR and then dilate with DD?

    3. Question 3 · MP 1 · Procedural and Symbolic Fluency

      A=[3121]A = \begin{bmatrix} 3 & 1 \\ 2 & 1 \end{bmatrix}. Which point is sent to (5,4)(5, 4)?

    4. Question 4 · MP 3 · Communication and Reasoning

      Why does [2412]\begin{bmatrix} 2 & 4 \\ 1 & 2 \end{bmatrix} not have an inverse transformation?

    5. Question 5 · MP 2 · Multiple Representations

      Reflecting in the xx-axis twice is the same as which transformation?

    Free-response practice

    Write your answer first, then mark it against the scoring guide.

    Class-test practice (Unit 4 is not on the AP Exam) · 4 points

    Let P=[100−1]P = \begin{bmatrix} 1 & 0 \\ 0 & -1 \end{bmatrix} (reflection in the xx-axis) and Q=[3001]Q = \begin{bmatrix} 3 & 0 \\ 0 & 1 \end{bmatrix} (horizontal stretch by 3).

    1. (a) Find the matrix of 'stretch with Q, then reflect with P', and the image of (2, 1).
    2. (b) Find the matrix that undoes this combined transformation and use it to find the point sent to (9, 4).

    Connected topics

    Frequently asked questions

    Is this on the AP Precalculus Exam?

    No. Unit 4 is taught but not assessed on the AP Exam.

    Do some pairs of transformations commute?

    Yes. Two rotations about the origin commute, and a uniform dilation commutes with every linear transformation. Most other pairs do not.

    How is this like inverse functions in Unit 2?

    Exactly the same idea: the inverse sends each output back to its input, and it exists only if no two inputs share an output.

    How this shows up on the exam42 multiple-choice questions (29 without a calculator) and 4 free-response questions of 6 points. See what each one asks you to do.Full-length AP Precalculus practice examsTwo timed exams in the 2027 format (42 MCQ + 4 FRQ, calculator and no-calculator parts), with explanations, scoring guides and an estimated 1–5 score. $14.99 · try 5 questions free.

    All topics in Unit 4: Functions Involving Parameters, Vectors, and Matrices

    1. 4.1 Parametric Functions
    2. 4.2 Parametric Functions Modeling Planar Motion
    3. 4.3 Parametric Functions and Rates of Change
    4. 4.4 Parametrically Defined Circles and Lines
    5. 4.5 Implicitly Defined Functions
    6. 4.6 Conic Sections
    7. 4.7 Parametrization of Implicitly Defined Functions
    8. 4.8 Vectors
    9. 4.9 Vector-Valued Functions
    10. 4.10 Matrices
    11. 4.11 The Inverse and Determinant of a Matrix
    12. 4.12 Linear Transformations and Matrices
    13. 4.13 Matrices as Functions
    14. 4.14 Matrices Modeling Contexts

    Other units in AP Precalculus

    AP® is a trademark registered by College Board, which is not affiliated with, and does not endorse, this website.