Welcome to Topic 4.13: Matrices as Functions!
By now, you’ve learned that matrices are great for organizing data and solving systems of equations. But did you know that a matrix can act just like a function? In this chapter, we are going to look at matrices through a different lens. Instead of just a box of numbers, we will treat a matrix as a "rule" that takes an input (a vector) and transforms it into an output (another vector).
Note: Unit 4 is not assessed on the official AP Precalculus Exam, but understanding this topic is a fantastic bridge to College Linear Algebra and Physics!
1. The Matrix as a Function Machine
In algebra, you are used to functions like \(f(x) = 2x\). You put in a number \(x\), and the rule tells you to multiply it by \(2\) to get your output. In Topic 4.13, we do the exact same thing, but our "numbers" are vectors and our "rule" is a matrix.
If we have a matrix \(A\) and a vector \(\vec{v}\), we can define a function \(f\) such that:
\(f(\vec{v}) = A\vec{v}\)
In this scenario:
• The input is the vector \(\vec{v}\).
• The function rule is matrix multiplication by \(A\).
• The output is the resulting vector after multiplication.
Wait, does this count as a function?
Yes! Just like a standard function, for every input vector \(\vec{v}\), the matrix multiplication gives you exactly one specific output vector. That satisfies the definition of a function!
Key Terms to Remember:
• Domain: The set of all possible input vectors. For a \(2 \times 2\) matrix, the domain is usually all 2D vectors.
• Codomain/Range: The set of all possible output vectors produced by the matrix.
2. Dimensions and Compatibility
Don't worry if the dimensions feel confusing; just remember the "Inside Numbers" rule from Topic 4.10. For a matrix function to work, the dimensions must match.
If your matrix \(A\) is an \(m \times n\) matrix:
• Your input vector \(\vec{v}\) must have \(n\) components (to match the columns).
• Your output vector will have \(m\) components (matching the rows).
Example: If \(A\) is a \(2 \times 2\) matrix, it takes a 2D vector as an input and "spits out" a 2D vector as an output. This is often called a mapping from \(\mathbb{R}^2\) to \(\mathbb{R}^2\).
3. Composition of Matrix Functions
In previous units, you learned about function composition: \((f \circ g)(x) = f(g(x))\). You do the inner function first, then the outer function.
Matrices work the same way! If you have two functions defined by matrices:
\(g(\vec{v}) = B\vec{v}\)
\(f(\vec{v}) = A\vec{v}\)
The composition \(f(g(\vec{v}))\) is:
\(f(B\vec{v}) = A(B\vec{v}) = (AB)\vec{v}\)
The Big "Aha!" Moment:
Multiplying two matrices \(A\) and \(B\) together is actually the same thing as composing two functions! If you want to apply transformation \(B\) and then transformation \(A\), you just find the product matrix \(AB\) and use that as your new function rule.
Common Mistake: Remember that order matters! In matrix multiplication, \(AB\) is usually NOT the same as \(BA\). Just like with functions, \(f(g(x))\) is usually different from \(g(f(x))\).
4. The Inverse Function
In Topic 2.8, you learned that an inverse function \(f^{-1}(x)\) "undoes" what \(f(x)\) did. The same logic applies here.
If a matrix \(A\) is invertible (meaning its determinant is not zero, as seen in Topic 4.11), then the function \(f(\vec{v}) = A\vec{v}\) has an inverse function:
\(f^{-1}(\vec{v}) = A^{-1}\vec{v}\)
If you apply the matrix function \(A\) to a vector and then apply the inverse matrix \(A^{-1}\), you end up exactly where you started with the original vector \(\vec{v}\).
Quick Review:
• Function: \(f(\vec{v}) = A\vec{v}\)
• Inverse: \(f^{-1}(\vec{v}) = A^{-1}\vec{v}\)
• Result: \(A^{-1}(A\vec{v}) = I\vec{v} = \vec{v}\) (where \(I\) is the Identity Matrix).
5. Visualizing the Transformation
Think of a matrix function as a "morphing" tool.
• Some matrices stretch or shrink vectors (dilation).
• Some matrices rotate vectors around the origin.
• Some matrices flip vectors across an axis (reflection).
Whenever you see a matrix \(A\) multiplying a vector, imagine the vector moving or changing shape on a coordinate plane. This "movement" is the physical manifestation of the function's output.
Key Takeaways:
• A matrix acts as a function where the input and output are vectors.
• Matrix Multiplication is equivalent to Function Composition.
• The Inverse Matrix represents the Inverse Function, which reverses the transformation.
• Always check your dimensions to ensure the input vector fits the matrix "machine."
Don't worry if this feels abstract! Just remember: Matrices aren't just tables of numbers—they are active rules that move and change vectors in space.