In this section we learn to understand matrices geometrically as functions, or transformations. We briefly discuss transformations in general, then specialize to matrix transformations, which are transformations that come from matrices.
Informally, a function is a rule that accepts inputs and produces outputs. For instance, is a function that accepts one number as its input, and outputs the square of that number: In this subsection, we interpret matrices as functions.
Let be a matrix with rows and columns. Consider the matrix equation (we write it this way instead of to remind the reader of the notation ). If we vary then will also vary; in this way, we think of as a function with independent variable and dependent variable
The independent variable (the input) is which is a vector in
The dependent variable (the output) is which is a vector in
The set of all possible output vectors are the vectors such that has some solution; this is the same as the column space of by this note in Section 2.3.
At this point it is convenient to fix our ideas and terminology regarding functions, which we will call transformations in this book. This allows us to systematize our discussion of matrices as functions.
Definition
A transformation from to is a rule that assigns to each vector in a vector in
is called the domain of
is called the codomain of
For in the vector in is the image of under
The set of all images is the range of
The notation means “ is a transformation from to ”
It may help to think of as a “machine” that takes as an input, and gives you as the output.
The points of the domain are the inputs of this simply means that it makes sense to evaluate on vectors with entries, i.e., lists of numbers. Likewise, the points of the codomain are the outputs of this means that the result of evaluating is always a vector with entries.
The range of is the set of all vectors in the codomain that actually arise as outputs of the function for some input. In other words, the range is all vectors in the codomain such that has a solution in the domain.
The identity transformation is the transformation defined by the rule
In other words, the identity transformation does not move its input vector: the output is the same as the input. Its domain and codomain are both and its range is as well, since every vector in is the output of itself.
Now we specialize the general notions and vocabulary from the previous subsection to the functions defined by matrices that we considered in the first subsection.
Definition
Let be an matrix. The matrix transformation associated to is the transformation
This is the transformation that takes a vector in to the vector in
If has columns, then it only makes sense to multiply by vectors with entries. This is why the domain of is If has rows, then has entries for any vector in this is why the codomain of is
The definition of a matrix transformation tells us how to evaluate on any given vector: we multiply the input vector by a matrix. For instance, let
and let be the associated matrix transformation. Then
Suppose that has columns If we multiply by a general vector we get
This is just a general linear combination of Therefore, the outputs of are exactly the linear combinations of the columns of the range of is the column space of See this note in Section 2.3.
Let be an matrix, and let be the associated matrix transformation.
The domain of is where is the number of columns of
In the case of an square matrix, the domain and codomain of are both In this situation, one can regard as operating on it moves the vectors around in the same space.