Skip to content

11.25 Representing linear maps by matrices

Let \(T:V\rightarrow W\) a linear map, and let \(v_1,...,v_n\) be a basis of \(V\) and \(w_1,...,w_{m}\) a basis of \(W\)

\(T\) is determined by \(Tv_1,...,Tv_n\) (theorem of linear maps) The idea is "we can define \(T\) by defining \(Tv_i\)"

(#)\(\begin{cases}Tv_1=a_{11}w_1+a_{21}w_2+\dots+a_{m1}w_{m}\\ Tv_2=a_{12}w_1+a_{22}w_2+\dots+a_{m2}w_{m}\\ \vdots\\ Tv_{i}=a_{1i}w_1+a_{2i}w_2+\dots+a_{mi}w_{m}\\ \vdots\\ Tv_{n}=a_{1n}w_1+a_{2n}w_2+\dots+a_{mn}w_{m}\end{cases}\)

Note: the column of the matrix is the coordinates of \(Tv_1\) we change the index order here to ensure we can do the matrix multiplication of \(v\) because \(v\) is a linear combination

Definition

The matrix \(A\in M_{m\times n}(\mathbb{F})\) defined by \((\#)\) is the matrix of \(T\) with respect to the bases \(\mathcal{B}: v_1, v_2, \dots, v_n\) of \(V\) and \(\mathcal{B}': w_1, w_2, \dots, w_m\) of \(W\).

We denote it by \((A=)[T]_{\mathcal{B} \mathcal{B}'}\). We can imagine the matrix by \(T(v_{i}\in B)=\sum\lambda_{i}w_{i}\in B^{\prime}\)

Remark: What the meaning of \([T]_{\mathcal{B}}\)? That is the matrix of \(\begin{cases}Tv_1=a_{11}v_1+a_{21}v_2+\dots+a_{n1}v_{n}\\ Tv_2=a_{12}v_1+a_{22}v_2+\dots+a_{n2}v_{n}\\ \vdots\\ Tv_{i}=a_{1i}v_1+a_{2i}v_2+\dots+a_{ni}v_{n}\\ \vdots\\ Tv_{n}=a_{1n}v_1+a_{2n}v_2+\dots+a_{nn}v_{n}\end{cases}\)

Examples

  1. \(T: \mathbb{C}^3 \to \mathbb{C}^2\), \(T(a,b,c)=(a+b,2a-b+ic)\).

    Let \(\mathcal{B} = \{(1, 0, 0), (0, 1, 0), (0, 0, 1)\}\) and \(\mathcal{B}' = \{(1, 0), (0, 1)\}\).

    \(T(e_1)=T(1,0,0)=(1,2)=1\cdot e_1+2\cdot e_2\)

    \(T(e_2)=T(0,1,0)=(1,-1)=1\cdot e_1+(-1)\cdot e_2\)

    \(T(e_3)=T(0,0,1)=(0,i)=0\cdot e_1+i\cdot e_2\)

    \([T]_{\mathcal{BB}^{\prime}}=\begin{pmatrix}1 & 1 & 0\\ 2 & -1 & i\end{pmatrix}\)

    Now let \(\mathcal{B} = \{(1, 1, 1), (i, i, 0), (i, 0, 0)\}\) and \(\mathcal{B}' = \{(1, i), (i, -i)\}\).

    \([T]_{\mathcal{BB}^{\prime}}=\begin{pmatrix}2-i & \frac{3+3i}{2} & \frac{3+3i}{2}\\ 1 & \frac{1+3i}{2} & \frac{3i-1}{2}\end{pmatrix}\)

    • \(T(1,1,1)=(2,1+i)=\left.(2-i\right)(1,i)+1\cdot(i,-i)\)
    • \(T(i, i, 0) =(2i,i)= \frac{3 + 3i}{2}(1, i) + \frac{1 + 3i}{2}(i, -i)\)
    • \(T(i, 0, 0) =(i,2i)= \frac{3 + 3i}{2}(1, i) + \frac{3i - 1}{2}(i, -i)\)

Notation:

Given a basis \(\mathcal{B}\) of \(V\) and \(v \in V\), \(v_{\mathcal{B}} = [v]_{\mathcal{B}}\) is the coordinates vector of \(v\) with respect to \(\mathcal{B}\).

That is: if \(\mathcal{B} = \{v_1, v_2, \dots, v_n\}\) and \(v = a_1v_1 + a_2v_2 + \dots + a_nv_n\), then \([v]_{\mathcal{B}} = (a_1, a_2, \dots, a_n) \in \mathbb{F}^n\).

Remark:

The map \(V \to \mathbb{F}^n\), \(v \mapsto v_{\mathcal{B}}\) is linear

Proposition

\((T(v))_{\mathcal{B}^{\prime}}=[T]_{\mathcal{BB}^{\prime}}\cdot v_{\mathcal{B}}\) where

  • \([T]_{\mathcal{B}\mathcal{B}'} \in M_{m \times n}(\mathbb{F})\),
  • \(v_{\mathcal{B}} \in \mathbb{F}^n\),
  • \((T(v))_{\mathcal{B}'} \in \mathbb{F}^m\).

Remark: Actually, this proposition is natural since we have know the linear map can be written as a matrix, thus the process of linear map can be replaced by matrix multiplication.

\(T(v)=w\;\iff\;[T]_{\mathcal{BB}^{\prime}}\cdot v_{\mathcal{B}}=(T(v))_{\mathcal{B}^{\prime}}\)

Proof1:

\((T(v))_{\mathcal{B}'}\) is the image of: \(v \xrightarrow{T} T(v) \xrightarrow{()_{\mathcal{B}'}} (T(v))_{\mathcal{B}'}\), which is linear.

\([T]_{\mathcal{B}\mathcal{B}'} v_{\mathcal{B}}\) is the image of: \(v\xrightarrow{()_{\mathcal{B}}}v_{\mathcal{B}}\xrightarrow{T_{A}}A\cdot v_{\mathcal{B}}\), which is linear. Here, \([T]_{\mathcal{B}\mathcal{B}'} = A\).

Claim: These two linear maps coincide.

It suffices to check it on \(\mathcal{B}\) (basis):

\(v = v_i\): \(v_i \xrightarrow{T} T(v_i) \xrightarrow{(\cdot)_{\mathcal{B}'}} (T(v_i))_{\mathcal{B}'} = \text{the i-th column of } A\)

\(v_{i}\xrightarrow{(\cdot)_{\mathcal{B}}}(0,\dots,1\left(第i位),\dots,0\right)\xrightarrow{A}A\cdot\begin{pmatrix}0\\ \vdots\\ 1\\ \vdots\\ 0\end{pmatrix}=\text{the }i\text{th column of }A.\)

Proof2: (Direct Computation)

Let \(v = \alpha_1v_1 + \dots + \alpha_nv_n\), and \(v_{\mathcal{B}} = (\alpha_1, \dots, \alpha_n)\). Then \(Tv = \alpha_1Tv_1 + \dots + \alpha_nTv_n\).

For \(Tv_i\): \(Tv_i = \sum_{j=1}^m a_{ji}w_j\)\(\implies Tv=\sum_{k=1}^{n}\alpha_{k}\left(\sum_{j=1}^{m}a_{jk}w_{j}\right)=\sum_{k=1}^{n}\sum_{j=1}^{m}\alpha_{k}a_{jk}w_{j}=\sum_{j=1}^{m}\left(\sum_{k=1}^{n}\alpha_{k}a_{jk}\right)w_{j}\)

Thus, \((T(v))_{\mathcal{B}^{\prime}}=\begin{pmatrix}\sum_{k=1}^{n}\alpha_{k}a_{1k}, \sum_{k=1}^{n}\alpha_{k}a_{2k}, \cdots, \sum_{k=1}^{n}\alpha_{k}a_{mk}\end{pmatrix}.\)

\([T]_{\mathcal{BB}^{\prime}}v_{\mathcal{B}}=\begin{pmatrix}a_{11} & a_{12} & \cdots & a_{1n}\\ a_{21} & a_{22} & \cdots & a_{2n}\\ \vdots & \vdots & \ddots & \vdots\\ a_{m1} & a_{m2} & \cdots & a_{mn}\end{pmatrix}\begin{pmatrix}\alpha_1\\ \alpha_2\\ \vdots\\ \alpha_{n}\end{pmatrix}=\begin{pmatrix}\sum_{k=1}^{n}a_{1k}\alpha_{k}\\ \sum_{k=1}^{n}a_{2k}\alpha_{k}\\ \vdots\\ \sum_{k=1}^{n}a_{mk}\alpha_{k}\end{pmatrix}.\)

Example:

\(T: \mathbb{F}_2[x] \to \mathbb{F}_3[x]\), \(p(x) \mapsto (x+1)p(x)\) where \(\dim(\mathbb{F}_2[x]) = 3\), \(\dim(\mathbb{F}_3[x]) = 4\)

\(\mathcal{B} = \{1, x, x^2\}\) \(\mathcal{B}' = \{1, x, x^2, x^3\}\)

  • \(T(1) = (x+1) \cdot 1 = 1 + x\)
  • \(T(x) = (x+1) \cdot x = x + x^2\)
  • \(T(x^2) = (x+1) \cdot x^2 = x^2 + x^3\)

\([T]_{\mathcal{BB}^{\prime}}=\begin{pmatrix}1 & 0 & 0\\ 1 & 1 & 0\\ 0 & 1 & 1\\ 0 & 0 & 1\end{pmatrix}\)

\(T(-1 + x - \sqrt{2}x^2) = -1 \cdot 1 + 0 \cdot x + (1 - \sqrt{2})x^2 - \sqrt{2}x^3\)

Since \([T]_{\mathcal{BB}^{\prime}}\begin{pmatrix}-1\\ 1\\ -\sqrt2\end{pmatrix}=\begin{pmatrix}1 & 0 & 0\\ 1 & 1 & 0\\ 0 & 1 & 1\\ 0 & 0 & 1\end{pmatrix}\begin{pmatrix}-1\\ 1\\ -\sqrt2\end{pmatrix}=\begin{pmatrix}-1\\ 0\\ 1-\sqrt2\\ -\sqrt2\end{pmatrix}\)

Proposition

\([T + \lambda S]_{\mathcal{B}\mathcal{B}'} = [T]_{\mathcal{B}\mathcal{B}'} + \lambda [S]_{\mathcal{B}\mathcal{B}'}\)

Remark: That is, the map \(\mathcal{L}(V, W) \to M_{m \times n}(\mathbb{F})\), \(T \mapsto [T]_{\mathcal{B}\mathcal{B}'}\) is linear.

Because let \(G:\mathcal{L}(V, W) \to M_{m \times n}(\mathbb{F})\), then this proposition is equivalent to \(G(T+\lambda S)=G(T)+\lambda G(S)\)

Proof

Straightforward. \((T + \lambda S)(v_i) = Tv_i + \lambda Sv_i\)

Hence the \(i\)-th column of \([T + \lambda S]_{\mathcal{B}\mathcal{B}'}\) is the \(i\)-th column of \([T]_{\mathcal{B}\mathcal{B}'}\) plus \(\lambda \cdot (\text{the i-th column of } [S]_{\mathcal{B}\mathcal{B}'})\)

Remark

We have also a linear map \(\Phi:M_{m\times n}(\mathbb{F})\to\mathcal{L}(V,W)\), defined by \(\Phi(A)=T_A\)

Given \(A\) and \(v \in V\), let \(T_{A}(v)=w\in W\) such that \(w_{\mathcal{B}'} = A \cdot v_{\mathcal{B}}\).

Moreover, these two maps satisfy

  1. \(\mathcal{L}(V, W) \to M_{m \times n}(\mathbb{F}) \to \mathcal{L}(V, W)\) (|--------------\(\text{Id}\)------------------|)

  2. \(M_{m \times n}(\mathbb{F}) \to \mathcal{L}(V, W) \to M_{m \times n}(\mathbb{F})\) (|--------------\(\text{Id}\)------------------|)

Example:

Let \(V = \mathbb{R}^2\), \(W = \mathbb{R}^2\), and \(\mathcal{B} = \{(1, 1), (1, -1)\}\) and \(\mathcal{B}' = \{(1, 2), (2, 1)\}\)

\(T: V \to W\), defined by \(T(a, b) = (a + b, a - b)\).

  1. We compute the matrix first \(\mathcal{L}(V,W)\to M_{m\times n}(\mathbb{F})\)

    Since \(T(1, 1) = (2, 0) = -\frac{2}{3}(1, 2) + \frac{4}{3}(2, 1)\)

    \(T(1,-1)=(0,2)=\frac43(1,2)-\frac23(2,1)\), then \([T]_{\mathcal{BB}^{\prime}}=A=\begin{pmatrix}-\frac23 & \frac43\\ \frac43 & -\frac23\end{pmatrix}\)

    Then we need to compute the linear map \(M_{m\times n}(\mathbb{F})\to\mathcal{L}(V,W)\)

    The idea is : We know \(\Phi(A)=T_A\), then we need \(T_A\)

    Since \(T_{A}(v)=w\in W\), then we need \(w\)

    Since \(w_{\mathcal{B}'} = A \cdot v_{\mathcal{B}}\), then we need to compute it and restore the coordinate

    Consider any \(v=x(1,1)+y(1,-1)=\left(x+y,x-y\right)\):

    \(\begin{pmatrix}-\frac23 & \frac43\\ \frac43 & -\frac23\end{pmatrix}\begin{pmatrix}x\\ y\end{pmatrix}=\begin{pmatrix}-\frac23x+\frac43y\\ \frac43x-\frac23y\end{pmatrix}\), then \(T_{A}\cdot v=(-\frac23x+\frac43y)(1,2)+(\frac43x-\frac23y)(2,1)=\left(2x,2y\right)=w\)

    Finally, \(T_A(x+y,x-y)=(2x,2y)\), let \(a=x+y,b=x-y\), then \(x=\frac{a+b}{2}\) and \(y=\frac{a-b}{2}\)

    \(T(a,b)=T_{A}(v)=(2\cdot\frac{a+b}{2},2\cdot\frac{a-b}{2})=(a+b,a-b)\)

  2. \(A=\begin{pmatrix}1 & 1\\ 0 & -1\end{pmatrix}\)\(\rightarrow\) \(T_{A}\begin{pmatrix}x\\ y\end{pmatrix}=\begin{pmatrix}x+y\\ -y\end{pmatrix}\) (where \(v=x(1,1)+y(1,-1)=(x+y,x-y)\))

    \(\begin{pmatrix}x+y\\ -y\end{pmatrix}\) are coordinates of \(w=(x+y)(1,2)+\left(-y\right)\left(2,1\right)=\left(x-y,2x+y\right)\)

    So that \(T: (x + y, x - y) \mapsto (x - y, 2x + y)\) or \(T(1, 0) = (0, \frac{3}{2})\),\(T(0, 1) = (1, \frac{3}{2})\).

    or \(T(a, b) = (b, \frac{3}{2}a + \frac{1}{2}b)\).

    \([T]_{\mathcal{BB}^{\prime}}=\begin{pmatrix}1 & 1\\ 0 & -1\end{pmatrix}\)

    • \(T(1, 1) = (1, 2) = 1 \cdot (1, 2) + 0 \cdot (2, 1)\).
    • \(T(1, -1) = (1, 1) = 1 \cdot (1, 2) + (-1) \cdot (2, 1)\).