Skip to content

Change of basis

Keep a point still while the grid behind it changes, convert its coordinates between bases, and write a map in a basis where it is simple.

Helps to know first
This topic

First, the picture

A point stays exactly where it is while the grid behind it changes. Watch its coordinates change, though it never moves.

Same point, new coordinates

One point, two grids: the point stays, its coordinates change.

The point x = (5, 1) on the usual grid: 5 steps along e_{1} and 1 along e_{2}.

usual grid
(5, 1)
slanted grid
(5, 1)
A x, slanted grid
–
0.00 / 11.40 s
Describe this picture

One panel with a dot at x=(5,1)\mathbf{x}=(5,1) on the usual square grid. Over 4 s the grid slides into the slanted grid of the two arrows v1=(1,−1)\mathbf{v}_1=(1,-1) and v2=(2,1)\mathbf{v}_2=(2,1), while the dot stays where it is. Readouts give the dot’s coordinates on the usual grid and on the current grid; the second runs from (5,1)(5,1) to (1,2)(1,2). Then the matrix A=[1.510.51]\mathbf{A}=\begin{bmatrix}1.5&1\\0.5&1\end{bmatrix} of the eigenvectors page acts, and its card appears in the corner. The arrow v1\mathbf{v}_1 shrinks to half and v2\mathbf{v}_2 grows to double, and a second dot travels along a dashed path from x\mathbf{x} to Ax=(8.5,3.5)\mathbf{A}\mathbf{x}=(8.5,3.5). A third readout gives its slanted coordinates, (0.5,4)(0.5,4): on this grid A\mathbf{A} halves the first coordinate and doubles the second. The clip runs for about 11 s. One control after the clip: drag the dot, or move it with the arrow keys; all three readouts and the image dot follow.

Coordinates belong to a basis

The point in the picture is one place. Described on the usual grid, it is (5,1)(5,1): 5 steps of e1\mathbf{e}_1 and 1 of e2\mathbf{e}_2. Described on the grid of v1=(1,−1)\mathbf{v}_1=(1,-1) and v2=(2,1)\mathbf{v}_2=(2,1), it is 1 step of v1\mathbf{v}_1 and 2 of v2\mathbf{v}_2:

1 (1,−1)+2 (2,1)=(5,1).1\,(1,-1)+2\,(2,1)=(5,1).

So its coordinates in that basis are (1,2)(1,2). The point did not move; only the description changed. That is the lesson of Independence, basis and dimension, now turned into a method.

Going in and coming out

Put the basis vectors as the columns of V=[12−11]\mathbf{V}=\begin{bmatrix}1&2\\-1&1\end{bmatrix}. Coordinates c\mathbf{c} in that basis rebuild the point:

x=Vc.\mathbf{x}=\mathbf{V}\mathbf{c}.

To go the other way, from the point to its coordinates, undo V\mathbf{V} with its inverse from The inverse matrix:

c=V−1x.\mathbf{c}=\mathbf{V}^{-1}\mathbf{x}.

Here det⁡V=1+2=3\det\mathbf{V}=1+2=3 and V−1=13[1−211]\mathbf{V}^{-1}=\tfrac13\begin{bmatrix}1&-2\\1&1\end{bmatrix}, so c=13(5−2,  5+1)=(1,2)\mathbf{c}=\tfrac13(5-2,\;5+1)=(1,2), as the picture read.

Between two bases. To move from coordinates in the basis of V\mathbf{V} to coordinates in the basis of another matrix W\mathbf{W}, go out through V\mathbf{V} and back in through W−1\mathbf{W}^{-1}. Write the two coordinate vectors as c\mathbf{c} and c′\mathbf{c}':

c′=W−1V c.\mathbf{c}'=\mathbf{W}^{-1}\mathbf{V}\,\mathbf{c}.

With W=[1011]\mathbf{W}=\begin{bmatrix}1&0\\1&1\end{bmatrix}, W−1V=[12−2−1]\mathbf{W}^{-1}\mathbf{V}=\begin{bmatrix}1&2\\-2&-1\end{bmatrix} sends (1,2)(1,2) to (5,−4)(5,-4). Check: 5 (1,1)−4 (0,1)=(5,1)5\,(1,1)-4\,(0,1)=(5,1), the same point again.

A map in a new basis

A matrix A\mathbf{A} describes a map in the usual coordinates. To describe the same map in the basis of V\mathbf{V}, take three steps: come out of the new coordinates (V\mathbf{V}), apply the map (A\mathbf{A}), and go back in (V−1\mathbf{V}^{-1}):

B=V−1AV.\mathbf{B}=\mathbf{V}^{-1}\mathbf{A}\mathbf{V}.

That is the similar matrix of Similar matrices and the Jordan form. The point of choosing a basis is to make B\mathbf{B} simple. The basis in the picture was not chosen at random: (1,−1)(1,-1) and (2,1)(2,1) are the eigenvectors of A=[1.510.51]\mathbf{A}=\begin{bmatrix}1.5&1\\0.5&1\end{bmatrix}, with eigenvalues 0.5 and 2. So

AV=[0.54−0.52],B=V−1AV=[0.5002].\begin{aligned} \mathbf{A}\mathbf{V}&=\begin{bmatrix}0.5&4\\-0.5&2\end{bmatrix},\\ \mathbf{B}=\mathbf{V}^{-1}\mathbf{A}\mathbf{V}&=\begin{bmatrix}0.5&0\\0&2\end{bmatrix}. \end{aligned}

In the eigenvector basis the map is two separate stretches, which is what the end of the clip shows. That is diagonalisation, from Diagonalisation and matrix powers, seen as a change of basis.

Follow the point through. In coordinates, (1,2)→B(1,2)=(0.5, 4)(1,2)\to\mathbf{B}(1,2)=(0.5,\,4). Back out: V(0.5,4)=(0.5+8,  −0.5+4)=(8.5, 3.5)\mathbf{V}(0.5,4)=(0.5+8,\;-0.5+4)=(8.5,\,3.5). Directly, A(5,1)=(8.5, 3.5)\mathbf{A}(5,1)=(8.5,\,3.5). The same answer, by the long road and the short one.

Whatever basis you choose, some things never change: the trace, the determinant and the eigenvalues of B\mathbf{B} are those of A\mathbf{A}.

Orthonormal bases are the easy case

When the basis vectors are perpendicular and of length 1, V−1=V⊤\mathbf{V}^{-1}=\mathbf{V}^\top, as in Orthonormal bases and Gram–Schmidt. Then each coordinate is a dot product: ck=vk⋅xc_k=\mathbf{v}_k\cdot\mathbf{x}. For a frame turned by 53.13° (0.9273 rad), the angle whose cosine is 3/5, V=15[3−443]\mathbf{V}=\tfrac15\begin{bmatrix}3&-4\\4&3\end{bmatrix}, the point (5,10)(5,10) has coordinates

c=V⊤x=15 (15+40,  −20+30)=(11, 2),\begin{aligned} \mathbf{c}=\mathbf{V}^\top\mathbf{x}&=\tfrac15\,(15+40,\;-20+30)\\ &=(11,\,2), \end{aligned}

and V(11,2)=15(33−8,  44+6)=(5,10)\mathbf{V}(11,2)=\tfrac15(33-8,\;44+6)=(5,10) brings it back. No inverse to compute.

A transform is a change of basis

Four samples can be written in the basis of waves from Independence, basis and dimension. The impulse (4,0,0,0)(4,0,0,0) has coordinates (1,2,0,1)(1,2,0,1) there:

(1,1,1,1)+2 (1,0,−1,0)+(1,−1,1,−1)=(4,0,0,0).\begin{aligned} &(1,1,1,1)+2\,(1,0,-1,0)\\ &\quad+(1,-1,1,-1)=(4,0,0,0). \end{aligned}

Which coordinates?

One signal, an impulse, in two bases.

The impulse (4, 0, 0, 0) in the standard basis: one tall bar.

0.00 / 5.40 s
Describe this picture

Two rows of bars for the same four-sample signal, an impulse, appearing one after the other. The top row shows its coordinates in the standard basis, (4,0,0,0)(4,0,0,0): one tall bar. The bottom row shows its coordinates in the basis of waves (1,1,1,1)(1,1,1,1), (1,0,−1,0)(1,0,-1,0), (0,1,0,−1)(0,1,0,-1) and (1,−1,1,−1)(1,-1,1,-1): (1,2,0,1)(1,2,0,1). The caption ends: a transform is a change of basis. There is no control.

The signal is the same in both rows. A transform like the DFT does not change the signal; it changes the basis you describe it in, from single samples to waves.

In signal processing · transforms as a change of basis

From series to transform, in the signal processing course, describes a signal by how much of each frequency it contains instead of by its value at each moment. In this page’s words, that is a change of basis, and filtering becomes simple in the new basis, as the map above became two stretches. Signal samples count from n=0n=0, while vector entries count from 1.

Worked example

1. Coordinates. V=[12−11]\mathbf{V}=\begin{bmatrix}1&2\\-1&1\end{bmatrix}, V−1=13[1−211]\mathbf{V}^{-1}=\tfrac13\begin{bmatrix}1&-2\\1&1\end{bmatrix}, and x=(5,1)\mathbf{x}=(5,1) has c=(1,2)\mathbf{c}=(1,2). Check: 1(1,−1)+2(2,1)=(5,1)1(1,-1)+2(2,1)=(5,1).

2. The map in the eigenbasis. B=V−1AV=diag(0.5, 2)\mathbf{B}=\mathbf{V}^{-1}\mathbf{A}\mathbf{V}=\mathrm{diag}(0.5,\,2), and the long road gives Ax=(8.5,3.5)\mathbf{A}\mathbf{x}=(8.5,3.5).

3. A basis that is not made of eigenvectors. With columns (1,0)(1,0) and (1,1)(1,1), B=[110.51.5]\mathbf{B}=\begin{bmatrix}1&1\\0.5&1.5\end{bmatrix}. It is not diagonal, but its trace is 2.5 and its determinant 1.5−0.5=11.5-0.5=1, the same as for A\mathbf{A}: the eigenvalues are still 2 and 0.5.

4. Two bases. W−1V(1,2)=(5,−4)\mathbf{W}^{-1}\mathbf{V}(1,2)=(5,-4) in the basis (1,1)(1,1), (0,1)(0,1).

5. A turned frame. (5,10)(5,10) has coordinates (11,2)(11,2) in the frame turned by 53.13°.

Try these before you read the answers.

  • Coordinates of (3,3)(3,3) in the basis (1,1)(1,1), (1,−1)(1,-1)? (3,0)(3,0).
  • If V=I\mathbf{V}=\mathbf{I}, what changes? Nothing: the coordinates are the entries.
  • V\mathbf{V} has orthonormal columns. What is V−1\mathbf{V}^{-1}? V⊤\mathbf{V}^\top.
  • In the eigenbasis, what does A2\mathbf{A}^2 look like? diag(0.25, 4)\mathrm{diag}(0.25,\,4).

Where you’ll meet this

Waves instead of samples. The Fourier transform and the cosine transform of a JPEG block describe the same data in a basis of waves, where smoothing and compression are simple.

Turning a phone. A phone reads its motion sensor in the sensor’s own axes and changes basis into the screen’s axes, as in the turned frame above.

Robot arms. Each joint of a robot arm has its own frame, and the position of the hand is found by changing basis from frame to frame.

Reference card

QuantityFormulaNotes
Basis matrixV=[ v1 ⋯ vn ]\mathbf{V}=[\,\mathbf{v}_1\ \cdots\ \mathbf{v}_n\,]the new grid’s arrows as columns
Point from coordinatesx=Vc\mathbf{x}=\mathbf{V}\mathbf{c}come out of the basis
Coordinates from pointc=V−1x\mathbf{c}=\mathbf{V}^{-1}\mathbf{x}go into the basis
Between basesc′=W−1Vc\mathbf{c}'=\mathbf{W}^{-1}\mathbf{V}\mathbf{c}out through V\mathbf{V}, in through W−1\mathbf{W}^{-1}
A mapB=V−1AV\mathbf{B}=\mathbf{V}^{-1}\mathbf{A}\mathbf{V}diagonal in an eigenvector basis
Unchangedtrace, determinant, eigenvaluessame map, new description
Orthonormal basisc=V⊤x\mathbf{c}=\mathbf{V}^\top\mathbf{x}each coordinate is a dot product

Keep reading with a free account.

By creating an account you accept the terms of use.

Sign in

Already have an account? Use the service you signed up with.

Or keep reading: get new lessons by email

Are you 13 or over?

Accounts and email updates are for people aged 13 or over. We keep only your answer, never your date of birth.

End of the lesson

Where to go next.

Phasorium

Account

Sign inKeep your place on any device

Subjects

Site

Look