Exercise 1: Matrix/vector representations of linear functions
Consider the linear function \(f: \mathbb{R}^2 \to \mathbb{R}^2\) given by
\[
f(x,y) = (2x - y + 4, x + 3y - 1).
\]
As I mentioned in class, this is called a linear function because it only contains terms of degrees \(0\) and \(1\).
If we blur the distinction between a point \((x,y)\) and its position vector
\[
\begin{bmatrix}
x \\
y
\end{bmatrix},
\]
then we can rewrite the formula for \(f\) as
\[
f\left( \begin{bmatrix}
x \\
y
\end{bmatrix} \right) =
\begin{bmatrix}
2 & -1 \\
1 & 3
\end{bmatrix} \begin{bmatrix}
x \\
y
\end{bmatrix} + \begin{bmatrix} 4 \\ -1 \end{bmatrix}.
\]
Check for yourself that if you multiply out the right-hand side, you will get
\[
f\left( \begin{bmatrix}
x \\
y
\end{bmatrix} \right) = \begin{bmatrix}2x - y + 4 \\
x + 3y - 1
\end{bmatrix},
\]
which is the same as the original formula for \(f\), but written in a different way.
The same procedure works in higher dimensions, as you will discover in the following exercises:
In each of the following, convert the given formula for a linear function into a matrix/vector representation as shown above.
- \(f: \mathbb{R}^2 \to \mathbb{R}^2\), \(f(x,y) = (x + 2y - 3, 4x - y + 5)\)
- \(g: \mathbb{R}^2 \to \mathbb{R}^2\), \(g(x,y) = (3x - 2y , -x + 5y - 4)\)
- \(h: \mathbb{R}^3 \to \mathbb{R}^3\), \(h(x, y, z) = (x + 2y - z + 1, 3x - y + 4z - 2, -2x + 5y + z + 3)\)
- \(k: \mathbb{R}^2 \to \mathbb{R}^3\), \(k(x, y) = (x - 4y + 2, -2x + 3y - 1, 3x - y)\)
Now go backwards. For each of the following, convert the given matrix/vector representation into a formula for a linear function.
\(r: \mathbb{R}^2 \to \mathbb{R}^2\), \(r\left( \begin{bmatrix}x \\
y
\end{bmatrix} \right) =
\begin{bmatrix}1 & 4 \\
-2 & 3
\end{bmatrix} \begin{bmatrix}x \\
y
\end{bmatrix} + \begin{bmatrix} -3 \\ 2 \end{bmatrix}\)
\(s: \mathbb{R}^2 \to \mathbb{R}^2\), \(s\left( \begin{bmatrix}x \\
y
\end{bmatrix} \right) =
\begin{bmatrix}0 & 5 \\
-1 & 2
\end{bmatrix} \begin{bmatrix}x \\
y
\end{bmatrix} + \begin{bmatrix} 1 \\ -4 \end{bmatrix}\)
\(t: \mathbb{R}^3 \to \mathbb{R}^3\), \(t\left( \begin{bmatrix}x \\
y \\
z
\end{bmatrix} \right) =
\begin{bmatrix}2 & -1 & 3 \\
-4 & 5 & 0 \\
1 & 2 & -2
\end{bmatrix} \begin{bmatrix}x \\
y \\
z
\end{bmatrix} + \begin{bmatrix} 0 \\ 1 \\ -1 \end{bmatrix}\)
\(u: \mathbb{R}^2 \to \mathbb{R}^3\), \(u\left( \begin{bmatrix}x \\ y\end{bmatrix} \right) =
\begin{bmatrix}1 & -2 \\
3 & 0 \\
-1 & 4
\end{bmatrix} \begin{bmatrix}x \\ y\end{bmatrix} + \begin{bmatrix} 2 \\ -1 \\ 3 \end{bmatrix}\)
\(f\left( \begin{bmatrix}x \\ y\end{bmatrix} \right) =
\begin{bmatrix}1 & 2 \\
4 & -1
\end{bmatrix} \begin{bmatrix}x \\ y\end{bmatrix} + \begin{bmatrix} -3 \\ 5 \end{bmatrix}\)
\(g\left( \begin{bmatrix}x \\ y\end{bmatrix} \right) =
\begin{bmatrix}3 & -2 \\ -1 & 5
\end{bmatrix} \begin{bmatrix}x \\ y\end{bmatrix} + \begin{bmatrix} 0 \\ -4 \end{bmatrix}\)
\(h\left( \begin{bmatrix}x \\ y \\ z\end{bmatrix} \right) =
\begin{bmatrix}1 & 2 & -1 \\ 3 & -1 & 4 \\ -2 & 5 & 1
\end{bmatrix} \begin{bmatrix}x \\ y \\ z\end{bmatrix} + \begin{bmatrix} 1 \\ -2 \\ 3 \end{bmatrix}\)
\(k\left( \begin{bmatrix}x \\ y\end{bmatrix} \right) =
\begin{bmatrix}1 & -4 \\ -2 & 3 \\ 3 & -1
\end{bmatrix} \begin{bmatrix}x \\ y\end{bmatrix} + \begin{bmatrix} 2 \\ -1 \\ 0 \end{bmatrix}\)
\(r(x,y) = (x + 4y - 3, -2x + 3y + 2)\)
\(s(x,y) = (5y + 1, -x + 2y - 4)\)
\(t(x,y,z) = (2x - y + 3z, -4x + 5y +1, x + 2y - 2z - 1)\)
\(u(x,y) = (x - 2y + 2, 3x - 1, -x + 4y + 3)\)