Lab 7 Interactive: Eigenvalues, Eigenvectors, and Diagonalization

Explore eigenvectors as preserved directions, diagonalization as a change to an eigenbasis, matrix powers, non-diagonalizable examples, and Markov-chain steady states.

1. A $2\times2$ matrix

Enter $A=\begin{bmatrix}a&b\\c&d\end{bmatrix}$. The tool computes the characteristic polynomial, eigenvalues, and a diagonalization test.

2. Geometry: preserved directions

Blue arrows are input directions. Orange arrows show where $A$ sends them. Eigenvectors are directions whose orange images stay on the same line.

3. Check a proposed eigenvector

A nonzero vector $v$ is an eigenvector if $Av=\lambda v$ for some scalar $\lambda$.

4. Diagonalization and powers

When $A=PDP^{-1}$, we get $A^k=PD^kP^{-1}$.

5. Markov chain steady state

Use a column-stochastic matrix $M=\begin{bmatrix}p&q\\1-p&1-q\end{bmatrix}$. The steady state satisfies $Mp=p$ and $p_1+p_2=1$.

6. Power iteration

The power method repeatedly applies $A$ and rescales. It often finds a dominant eigenvector.

7. Independent-study practice tasks with answers

Task A. For $A=\begin{bmatrix}4&1\\2&3\end{bmatrix}$, find the eigenvalues.
Answer: $\det(A-\lambda I)=\lambda^2-7\lambda+10=(\lambda-5)(\lambda-2)$, so $\lambda=5,2$.
Task B. Find an eigenvector for $\lambda=5$ for the same matrix.
Answer: Solve $(A-5I)x=0$. One eigenvector is $(1,1)^T$.
Task C. Diagonalize $A=\begin{bmatrix}4&1\\2&3\end{bmatrix}$.
Answer: One choice is $P=\begin{bmatrix}1&1\\1&-2\end{bmatrix}$ and $D=\begin{bmatrix}5&0\\0&2\end{bmatrix}$.
Similar practice. Diagonalize $B=\begin{bmatrix}3&1\\0&2\end{bmatrix}$.
Answer: $P=\begin{bmatrix}1&-1\\0&1\end{bmatrix}$, $D=\operatorname{diag}(3,2)$.
Task D. Explain why $J=\begin{bmatrix}2&1\\0&2\end{bmatrix}$ is not diagonalizable.
Answer: It has only one eigenvalue, $2$, and only one line of eigenvectors, $\operatorname{span}\{(1,0)^T\}$.
Task E. If $A=PDP^{-1}$, what is $A^{20}$?
Answer: $A^{20}=PD^{20}P^{-1}$.

8. Workspace