# 4.20 Change of basis

Suppose we have a linear map $T$ from $V$ to $W$ and two different bases for $V$ and two different bases for $W$. We can form the matrix of $T$ with respect to the first initial and final bases, and the second. These record the same information (the linear map $T$) in different ways, so they should be related in some way.

## 4.20.1 The change of basis formula

Let

• $T:V\to W$ be a linear map,

• $\mathcal{B}$ and $\mathcal{B}^{\prime}$ be bases of $V$, and

• $\mathcal{C}$ and $\mathcal{C}^{\prime}$ be bases of $W$.

Now make the following observation:

 $T=\operatorname{id}_{W}\circ T\circ\operatorname{id}_{V}$

which holds purely because composing with an identity map doesn’t change anything.

Now apply Theorem 4.19.1 from the previous section twice: you get the change of basis formula:

 $[T]^{\mathcal{B}^{\prime}}_{\mathcal{C}^{\prime}}=[\operatorname{id}_{W}]^{% \mathcal{C}}_{\mathcal{C}^{\prime}}[T]^{\mathcal{B}}_{\mathcal{C}}[% \operatorname{id}_{V}]^{\mathcal{B}^{\prime}}_{\mathcal{B}}$ (4.7)

## 4.20.2 The matrix of the identity map with respect to different bases

In this subsection we’re going to work an example of computing matrices of linear maps using the change of basis formula. On the way we’ll see the significance of the matrix of the identity map with respect to different bases.

Let $T:\mathbb{R}^{2}\to\mathbb{R}^{2}$ be the linear map

 $T\begin{pmatrix}x\\ y\end{pmatrix}=\begin{pmatrix}-16x+6y\\ -45x+17y\end{pmatrix}$

Let $\mathcal{E}$ be the standard basis $\mathbf{e}_{1},\mathbf{e}_{2}$ of $\mathbb{R}^{2}$ and let $\mathcal{F}$ be the basis $\mathbf{f}_{1}=\begin{pmatrix}2\\ 5\end{pmatrix},\mathbf{f}_{2}=\begin{pmatrix}1\\ 3\end{pmatrix}$. The matrix of $T$ with respect to $\mathcal{E}$ is easy to find:

 $\displaystyle T(\mathbf{e}_{1})$ $\displaystyle=T\begin{pmatrix}1\\ 0\end{pmatrix}$ $\displaystyle=\begin{pmatrix}-16\\ -45\end{pmatrix}$ $\displaystyle=-16\mathbf{e}_{1}-45\mathbf{e}_{2}$ $\displaystyle T(\mathbf{e}_{2})$ $\displaystyle=T\begin{pmatrix}0\\ 1\end{pmatrix}$ $\displaystyle=\begin{pmatrix}6\\ 17\end{pmatrix}$ $\displaystyle=6\mathbf{e}_{1}+17\mathbf{e}_{2}$

so $[T]^{\mathcal{E}}_{\mathcal{E}}=\begin{pmatrix}-16&6\\ -45&17\end{pmatrix}$.

$[\operatorname{id}]^{\mathcal{F}}_{\mathcal{E}}$ is also easy: it’s the matrix which tells us how to express the elements of $\mathcal{F}$ in terms of the standard basis.

 $\displaystyle\operatorname{id}(\mathbf{f}_{1})$ $\displaystyle=\mathbf{f}_{1}=2\mathbf{e}_{1}+5\mathbf{e}_{2}$ $\displaystyle\operatorname{id}(\mathbf{f}_{2})$ $\displaystyle=\mathbf{f}_{2}=1\mathbf{e}_{1}+3\mathbf{e}_{2}$

and so $[\operatorname{id}]^{\mathcal{F}}_{\mathcal{E}}=\begin{pmatrix}2&1\\ 5&3\end{pmatrix}$.

How to express the $\mathbf{e}_{i}$ in terms of the $\mathbf{f}_{i}$ isn’t so obvious, so on the face of it computing $[\operatorname{id}]^{\mathcal{E}}_{\mathcal{F}}$ is harder. But we can avoid that, because we know about the matrix of a composition.

 $\displaystyle[\operatorname{id}]^{\mathcal{E}}_{\mathcal{F}}[\operatorname{id}% ]^{\mathcal{F}}_{\mathcal{E}}$ $\displaystyle=[\operatorname{id}\circ\operatorname{id}]^{\mathcal{F}}_{% \mathcal{F}}$ Theorem 4.19.1 $\displaystyle=[\operatorname{id}]^{\mathcal{F}}_{\mathcal{F}}$ $\displaystyle\text{as }\operatorname{id}\circ\operatorname{id}=\operatorname{id}$ $\displaystyle=I_{2}$

so

 $\displaystyle[\operatorname{id}]_{\mathcal{F}}^{\mathcal{E}}$ $\displaystyle=([\operatorname{id}]^{\mathcal{F}}_{\mathcal{E}})^{-1}$ $\displaystyle=\begin{pmatrix}2&1\\ 5&3\end{pmatrix}^{-1}$ $\displaystyle=\begin{pmatrix}3&-1\\ -5&2\end{pmatrix}$

We could work out $[T]^{\mathcal{F}}_{\mathcal{F}}$ directly using the definition, but instead we are going to practise using the change of basis formula (4.7). It says

 $\displaystyle[T]^{\mathcal{F}}_{\mathcal{F}}$ $\displaystyle=[\operatorname{id}]^{\mathcal{E}}_{\mathcal{F}}[T]^{\mathcal{E}}% _{\mathcal{E}}[\operatorname{id}]^{\mathcal{F}}_{\mathcal{E}}$ $\displaystyle=\begin{pmatrix}3&-1\\ -5&2\end{pmatrix}\begin{pmatrix}-16&6\\ -45&17\end{pmatrix}\begin{pmatrix}2&1\\ 5&3\end{pmatrix}$ $\displaystyle=\begin{pmatrix}-1&0\\ 0&2\end{pmatrix}$

Now consider $[T]^{\mathcal{E}}_{\mathcal{F}}$. Again we could find it directly from the definition by computing $T(\mathbf{e}_{1})$ and $T(\mathbf{e}_{2})$ and expressing them in terms of the $\mathbf{f}_{i}$s. But we already have the information we need: by Theorem 4.19.1,

 $\displaystyle[T]^{\mathcal{E}}_{\mathcal{F}}$ $\displaystyle=[T\circ\operatorname{id}]^{\mathcal{E}}_{\mathcal{F}}$ $\displaystyle=[T]^{\mathcal{F}}_{\mathcal{F}}[\operatorname{id}]^{\mathcal{E}}% _{\mathcal{F}}$ $\displaystyle=\begin{pmatrix}-1&0\\ 0&2\end{pmatrix}\begin{pmatrix}3&-1\\ -5&2\end{pmatrix}$ $\displaystyle=\begin{pmatrix}-3&1\\ -10&4\end{pmatrix}$

To check our answer we compute $T(\mathbf{e}_{1})$, which is $\begin{pmatrix}-16\\ -45\end{pmatrix}$. If the matrix is correct this should be the same as $-3\mathbf{f}_{1}-10\mathbf{f}_{2}$, and you can check that it really is.

## 4.20.3 Why would we use different bases to represent a linear map?

We already saw, when we first met bases of vector spaces, that different bases of vector spaces give us a different perspective on their elements — recall the example about two-pixel images. The same idea applies to linear maps.

A linear transformation which looks complex with respect to one basis can become much easier to understand when you choose the correct basis.

###### Example 4.20.1.

$A=\begin{pmatrix}4&-3&-3\\ 3&-2&-3\\ -1&1&2\end{pmatrix}$. Consider $T_{A}:\mathbb{R}^{3}\to\mathbb{R}^{3}$, so the matrix of $T_{A}$ with respect to the standard basis of $\mathbb{R}^{3}$ is $A$. There is no obvious structure to $T_{A}$.

Now consider a new basis $\mathcal{B}$ of $\mathbb{R}^{3}$: $\mathbf{b}_{1}=\begin{pmatrix}1\\ 1\\ 0\end{pmatrix},\mathbf{b}_{2}=\begin{pmatrix}1\\ 0\\ 1\end{pmatrix},\mathbf{b}_{3}=\begin{pmatrix}-3\\ -3\\ 1\end{pmatrix}$. (You should check it really is a basis.) Let’s find the matrix of $T_{A}$ with respect to $\mathcal{B}$, that is, $[T_{A}]^{\mathcal{B}}_{\mathcal{B}}$.

You can check that $T_{A}(\mathbf{b}_{1})=\mathbf{b}_{1},T_{A}(\mathbf{b}_{2})=\mathbf{b}_{2},T_{A% }(\mathbf{b}_{3})=2\mathbf{b}_{3}$. Thus $[T_{A}]^{\mathcal{B}}_{\mathcal{B}}=\begin{pmatrix}1&0&0\\ 0&1&0\\ 0&0&2\end{pmatrix}$

Suddenly the behaviour of $T_{A}$ is clear. Vectors in the direction $\begin{pmatrix}1\\ 1\\ 0\end{pmatrix}$ and $\begin{pmatrix}1\\ 0\\ 1\end{pmatrix}$ are unchanged by $T_{A}$, vectors in the direction $\mathbf{b}_{3}$ are scaled by a factor of 2.

This technique is called diagonalisation, you will learn more about it when you study eigenvectors and eigenvectors in Algebra 2.