Hexa Scholar

Diagonalization: what happens when you apply A again and again

How do you work out \(A^{20}\) without multiplying \(A\) by itself twenty times?

When a 2×2 matrix \(A\) has two linearly independent eigenvectors (neither is a multiple of the other), it can be written as \(A = PDP^{-1}\), with the eigenvectors as the columns of \(P\) and their eigenvalues on the diagonal of \(D\). Then \(A^k = PD^kP^{-1}\), and the only powers left to work out are the powers of the two eigenvalues.

Before you start · 3 quick checks on eigenvectors, combinations of two vectors and the 2×2 inverse, about 3 min
Setup: diagonal matrices, P and eigen-coordinates

As on the eigenvectors page, this page works in the real plane: \(A\) is a real 2×2 matrix, vectors are in \(\mathbb{R}^2\), and eigenvalues are real numbers.

A diagonal matrix has zeros off the diagonal; write \(\operatorname{diag}(a, b) = \begin{pmatrix} a & 0 \\ 0 & b \end{pmatrix}\). For two vectors \(v_1, v_2\), the matrix \(P = \begin{pmatrix} v_1 & v_2 \end{pmatrix}\) has \(v_1\) as its first column and \(v_2\) as its second.

Definition. \(A\) is diagonalizable if \(A = PDP^{-1}\) for some invertible matrix \(P\) and some diagonal matrix \(D\).

Two vectors \(v_1, v_2\) are linearly independent when neither is a multiple of the other. In the plane this means both are nonzero and they do not lie on one line through 0. Then every vector \(v\) can be written as \(v = c_1v_1 + c_2v_2\) for exactly one pair of numbers \(c_1, c_2\). When \(v_1\) and \(v_2\) are eigenvectors of \(A\), call \(c_1\) and \(c_2\) the eigen-coordinates of \(v\). Since \(P\begin{pmatrix} c_1 \\ c_2 \end{pmatrix} = c_1v_1 + c_2v_2\), they are the entries of \(P^{-1}v\).

Powers: \(A^0 = I\) and \(A^{k} = A^{k-1}A\), so \(A^k v\) is \(v\) with \(A\) applied \(k\) times. Also \(\lambda^0 = 1\) for every number \(\lambda\), including 0.

Why the pair \(c_1, c_2\) exists and is unique

\(v_1\) and \(v_2\) are linearly independent exactly when \(\det P \ne 0\), that is, when \(P\) has an inverse. Then \(P\begin{pmatrix} c_1 \\ c_2 \end{pmatrix} = v\) has the one solution \(\begin{pmatrix} c_1 \\ c_2 \end{pmatrix} = P^{-1}v\).

1 See

Predict where A20v points, then apply A

Each goal gives a matrix \(A\) and a starting vector \(v\). Turn the dashed line to the direction you expect for \(A^{20}v\): drag the dot, focus it and use the arrow keys, or type an angle. Press Commit prediction; only then can you apply \(A\), one step at a time or with Play. The vectors grow quickly, so the figure rescales each one to length 1, and the tiles give the exact vector and its true length.

How the prediction is scored and how the steps are computed
2 Try

Which matrices can be written as PDP−1?

Two questions first. The builder below opens when you have answered both.

The builder opens when you have answered the two questions above.

3 Prove

Why Ak = PDkP−1

Theorem

Let \(A\) be a real 2×2 matrix. Suppose \(v_1\) and \(v_2\) are linearly independent eigenvectors of \(A\), with \(Av_1 = \lambda_1v_1\) and \(Av_2 = \lambda_2v_2\). Let \(P = \begin{pmatrix} v_1 & v_2 \end{pmatrix}\) and \(D = \operatorname{diag}(\lambda_1, \lambda_2)\). Then \(P\) is invertible and \(A = PDP^{-1}\). Moreover, for every whole number \(k \ge 0\),

\[ A^k = PD^kP^{-1} = P\operatorname{diag}(\lambda_1^k, \lambda_2^k)P^{-1}. \]

The eigenvalues may be equal, negative or 0. As in the setup, \(A^0 = D^0 = I\) and \(\lambda^0 = 1\), also for \(\lambda = 0\).

Build the proof one line at a time; each line has one correct choice. A wrong choice is a statement that is false for this \(A\), \(P\) and \(D\), or a claimed general rule that fails for some matrices.

What follows

Diagonalizable means two linearly independent eigenvectors

The theorem gives one direction. Conversely, if \(A = PDP^{-1}\) with \(P\) invertible and \(D = \operatorname{diag}(d_1, d_2)\), then \(AP = PD\), so \(A\) sends column \(j\) of \(P\) to \(d_j\) times that column. The columns are linearly independent, because \(\det P \ne 0\). So they are two linearly independent eigenvectors, and the diagonal of \(D\) holds their eigenvalues.

Two different eigenvalues are enough

If \(A\) has two different real eigenvalues \(\lambda_1 \ne \lambda_2\), then eigenvectors \(v_1\) and \(v_2\) for them are always linearly independent, so \(A\) is diagonalizable.

Why (optional)

Suppose one is a multiple of the other, say \(v_2 = tv_1\) for a number \(t\) (the other case is the same with the roles swapped); then \(t \ne 0\), since \(v_2 \ne 0\). Applying \(A\) gives \(\lambda_2v_2 = Av_2 = tAv_1 = t\lambda_1v_1 = \lambda_1v_2\), so \((\lambda_2 - \lambda_1)v_2 = 0\). As \(v_2 \ne 0\), this forces \(\lambda_1 = \lambda_2\), which is false.

The shear is not diagonalizable

So every eigenvector of the shear lies on the \(x_1\)-axis, any two of them are multiples of each other, and by the box above it has no diagonalization. A single eigenvalue alone does not decide it: \(2I = \operatorname{diag}(2, 2)\) is already diagonal.

Powers and the eigenvalue of largest size

With \(v = c_1v_1 + c_2v_2\), applying \(A\) multiplies each part by its eigenvalue, so for every \(k \ge 0\)

\[ \begin{aligned} A^kv &= c_1\lambda_1^kv_1 + c_2\lambda_2^kv_2 \\ &= \lambda_1^k\Big(c_1v_1 + c_2\big(\tfrac{\lambda_2}{\lambda_1}\big)^kv_2\Big), \end{aligned} \]

where the second form needs \(\lambda_1 \ne 0\). If \(|\lambda_1| \gt |\lambda_2|\) and \(c_1 \ne 0\), the bracket tends to \(c_1v_1\), so the line through \(A^kv\) tends to the line through \(v_1\). The size of the part along \(v_2\), measured against the part along \(v_1\), is \(|\lambda_2/\lambda_1|^k\) times its starting value. If \(c_1 = 0\), then \(A^kv = c_2\lambda_2^kv_2\) stays on the line through \(v_2\) instead, unless \(\lambda_2 = 0\): then \(A\) sends \(v\) to 0, and \(A^kv\) has no direction (none of the four stage 1 matrices has the eigenvalue 0). Repeating \(v \mapsto Av/|Av|\) from a starting vector is power iteration, a basic numerical method for the eigenvector of the eigenvalue of largest absolute value.

4 Apply

Problems

Each problem has hints and a full solution. Exact answers are graded exactly: type whole numbers, exact decimals such as 0.5 or fractions such as 1/2, without thousands separators, and separate the numbers with commas where a problem asks for several. A value that is only close to an exact answer is not accepted. Where an answer is rounded (P4), the accepted error is stated.

Key point To raise a diagonalizable matrix to a power, find its eigenvalues and eigenvectors, then use \(A^k = P\operatorname{diag}(\lambda_1^k, \lambda_2^k)P^{-1}\). For a long-run question, look at the eigenvalue of largest absolute value: when it is the only one of that size and the start has a part along its eigenvector, the direction approaches that eigenvector's line, and \(|\lambda_2/\lambda_1|^k\) tells how fast.

Related: A matrix is a function that moves the plane. Also new: What degree does a Taylor polynomial need? and The exponential distribution and memorylessness.

Further reading