---
title: Eigenvalues and eigenvectors
heading: The directions a matrix only stretches
eyebrow: A7 · Lesson 33 · Eigenvalues and eigenvectors
xp: 40
---

::: hook
Most vectors get knocked off their line by a matrix: they come out pointing somewhere new. But almost every matrix has a few special directions that it only stretches or shrinks, without turning. Those directions, and their stretch factors, explain how a circuit rings, how fast it settles, and why a system blows up or calms down.

::: play
- The yellow arrow is a unit vector $\mathbf{v}$ at angle θ; the blue arrow is $A\mathbf{v}$. The dashed curve is the image of the unit circle.
- Turn θ slowly. At most angles $A\mathbf{v}$ points away from $\mathbf{v}$. Find the angles where they line up. How many are there in a half turn?
- At those angles, compare the length of $A\mathbf{v}$ with the eigenvalues in the strip.
:::
:::

```sim plot
view: complex
range: 4
slider: a = -2..3 step 0.25 = 2
slider: b = -2..2 step 0.25 = 1
slider: d = -2..3 step 0.25 = 1
slider: th = 0..180 step 1 = 20 °
curve: (a*cos(u) + b*sin(u)) + j*(b*cos(u) + d*sin(u)) | over: u = 0..2*pi | dashed | color: ch4
arrow: 1∠th | label: v
arrow: (a*cos(th°) + b*sin(th°)) + j*(b*cos(th°) + d*sin(th°)) | color: ch2 | label: Av
readout: angle from v to Av = arg(((a*cos(th°) + b*sin(th°)) + j*(b*cos(th°) + d*sin(th°)))/(1∠th))*180/pi °
readout: λ₁ = (a + d)/2 + sqrt(((a - d)/2)^2 + b^2)
readout: λ₂ = (a + d)/2 - sqrt(((a - d)/2)^2 + b^2)
```

::: predict
## The matrix in the sim is symmetric: its top-right and bottom-left entries are both $b$. At the two angles where $A\mathbf{v}$ lines up with $\mathbf{v}$, how are those two directions related?

- [ ] They're the same direction
- [ ] They're 45° apart
- [x] They're perpendicular
- [ ] It depends on b

::: reveal
Perpendicular. A symmetric matrix always has real eigenvalues and perpendicular eigenvectors: they are the long and short axes of the ellipse the unit circle becomes. Conductance matrices are symmetric, so this tidy picture is exactly what circuits give.
:::
:::

::: nameit
## $A\mathbf{v} = \lambda\mathbf{v}$

A nonzero vector $\mathbf{v}$ is an **eigenvector** of $A$ if $A\mathbf{v} = \lambda\mathbf{v}$ for some number λ, its **eigenvalue**. Along an eigenvector, the matrix acts like plain multiplication by λ.

**Finding them.** $A\mathbf{v} = \lambda\mathbf{v}$ means $(A - \lambda I)\mathbf{v} = 0$ with $\mathbf{v} \ne 0$, which needs $A - \lambda I$ to be singular:

$$\det(A - \lambda I) = 0$$

For a 2 × 2 matrix that's the quadratic

$$\lambda^2 - (a + d)\lambda + (ad - bc) = 0$$

whose coefficients are the **trace** $a + d$ (the sum of the eigenvalues) and the **determinant** (their product). For each λ, solve $(A - \lambda I)\mathbf{v} = 0$ for its direction.

**Shortcuts:** a triangular (or diagonal) matrix has its eigenvalues on the diagonal. A symmetric matrix has real eigenvalues and perpendicular eigenvectors. A rotation has complex eigenvalues $e^{\pm j\theta}$: no real direction stays put.

**Why they matter.** Writing a vector in terms of eigenvectors turns a matrix into separate scalings:

$$A^k\mathbf{x} = c_1\lambda_1^k\mathbf{v}_1 + c_2\lambda_2^k\mathbf{v}_2$$

so repeated application is dominated by the largest $|\lambda|$, and everything decays if all $|\lambda| < 1$. For circuits governed by $\dot{\mathbf{x}} = A\mathbf{x}$ (A8), each eigenvalue gives a **natural mode** $e^{\lambda t}$: a negative real λ is a decay with time constant $-1/\lambda$, a complex pair is a ringing oscillation, and any eigenvalue with a positive real part means the circuit is unstable.
:::

::: example
## Find the eigenvalues and eigenvectors of $\begin{bmatrix}2 & 1\\1 & 2\end{bmatrix}$.

::: solution
1. **Try $(1, 1)$.**
   $$\begin{aligned} A(1, 1) &= (3, 3) \\ &= 3(1, 1) \end{aligned}$$
   so $\lambda = 3$.
2. **Try $(1, -1)$.**
   $$A(1, -1) = (1, -1)$$
   so $\lambda = 1$.
3. **Check.** $3 + 1 = 4$ is the trace and $3 \times 1 = 3$ the determinant.

**Answer:** $\lambda = 3$ with eigenvector $(1, 1)$, and $\lambda = 1$ with $(1, -1)$.
:::
:::

::: example
## Does the 90° rotation $\begin{bmatrix}0 & -1\\1 & 0\end{bmatrix}$ have real eigenvectors?

::: solution
1. **Geometry.** Every vector is turned 90°, so none stays on its own line.
2. **Algebra.**
   $$\lambda^2 + 1 = 0$$
   gives $\lambda = \pm j$.
3. **What complex eigenvalues mean.** They are the signature of rotation, and they reappear as oscillation in lessons 34 and 37.

**Answer:** no. Its eigenvalues are $\pm j$, so it has no real eigenvectors.
:::
:::

::: example
## Find the eigenvalues and eigenvectors of $A = \begin{bmatrix}3 & 1\\0 & 2\end{bmatrix}$.

::: solution
1. **Eigenvalues.** $A$ is triangular, so
   $$\det(A - \lambda I) = (3 - \lambda)(2 - \lambda)$$
   and the eigenvalues are the diagonal entries, 3 and 2.
2. **Check.** Their sum is the trace, 5, and their product the determinant, 6.
3. **Eigenvector for $\lambda = 3$.**
   $$A - 3I = \begin{bmatrix}0 & 1\\0 & -1\end{bmatrix}$$
   whose null space is $(1, 0)$.
4. **Eigenvector for $\lambda = 2$.**
   $$A - 2I = \begin{bmatrix}1 & 1\\0 & 0\end{bmatrix}$$
   giving $(1, -1)$. Check: $A(1, -1) = (2, -2)$.

**Answer:** $\lambda = 3$ with eigenvector $(1, 0)$, and $\lambda = 2$ with $(1, -1)$.
:::
:::

::: check
given: a = 1..9 int; b = -9..9 int; d = 1..9 int
answer: (a + d + abs(a - d))/2
tolerance: 0.001

## What is the larger eigenvalue of $\begin{bmatrix} \given{a} & \given{b} \\ 0 & \given{d} \end{bmatrix}$?

::: right
Right. It's triangular, so its eigenvalues are on the diagonal: {a} and {d}.
:::

::: misses
- [any] Not yet. For a triangular matrix, the eigenvalues are the diagonal entries.
:::
:::

::: check
given: s = 2..6 int; b = 1..3 int
answer: s + b
tolerance: 0.5%

## What is the larger eigenvalue of $\begin{bmatrix} \given{s} & \given{b} \\ \given{b} & \given{s} \end{bmatrix}$?

::: right
Right. $\lambda^2 - 2s\lambda + (s^2 - b^2) = 0$ gives $\lambda = s \pm b$, with eigenvectors $(1, 1)$ and $(1, -1)$.
:::

::: misses
- [s] That's the diagonal entry; this matrix isn't triangular.
- [s - b] That's the smaller one.
- [any] Not yet. Solve $\det(A - \lambda I) = (s - \lambda)^2 - b^2 = 0$.
:::
:::

::: check
given: a = 1 | 3 | 5 | 7 | 9; d = 2 | 4 | 6 | 8; b = 2 | 4; c = 1..5 int
answer: a + d
tolerance: 0.5%

## Without solving the quadratic, what is the sum of the eigenvalues of $\begin{bmatrix} \given{a} & \given{b} \\ \given{c} & \given{d} \end{bmatrix}$?

::: right
Right. The sum of the eigenvalues is the trace, $\given{a} + \given{d}$.
:::

::: misses
- [a*d - b*c] That's their product, the determinant.
- [any] Not yet. The eigenvalues add up to the trace, the sum of the diagonal.
:::
:::

::: check
kind: choice

## A circuit's state matrix has eigenvalues $-2 \pm j50$ (in units of 1/ms). What does the circuit do after a disturbance?

- [ ] Decays smoothly without oscillating
- [x] Rings, oscillating while it decays
- [ ] Oscillates forever at constant size
- [ ] Grows without limit

::: right
Right. The imaginary part, 50 rad/ms, sets the ringing frequency; the negative real part, −2/ms, makes it decay with a time constant of 0.5 ms.
:::

::: misses
- [1] Purely real eigenvalues would give a smooth decay. The imaginary part means oscillation.
- [3] That would need a zero real part.
- [4] Growth needs a positive real part.
:::
:::

::: check
kind: parts
given: a = 4 | 5; b = 4 | 9

## Find the eigenvalues of $A = \begin{bmatrix}\given{a} & 1\\\given{b} & \given{a}\end{bmatrix}$.

::: part
answer: a + sqrt(b)
tolerance: 0.5%

### What is the larger eigenvalue?

::: misses
- [a + b] $(a - \lambda)^2 = b$, so $\lambda = a \pm \sqrt b$.
- [any] Solve $\det(A - \lambda I) = 0$.
:::
:::

::: part
answer: a^2 - b
tolerance: 0.5%

### What is the product of the eigenvalues?

::: misses
- [any] It's the determinant.
:::
:::
:::

::: check
kind: derivation
vars: x = 0.5..5, y = 0.5..5

## Find the eigenvectors of $A = \begin{bmatrix}x & 1\\0 & y\end{bmatrix}$.

::: step
answer: x

### $(1, 0)$ is an eigenvector. What is its eigenvalue?
:::

::: step
answer: y - x

### The eigenvector for $\lambda = y$ is $(1, s)$. What is $s$?
:::

::: right
Right. $(A - yI)(1, s) = (x - y + s, 0) = \mathbf 0$ gives $s = y - x$.
:::
:::

::: explain
## What is special about an eigenvector of a matrix, in terms of what the matrix does to it?

::: model
Most vectors are turned to a new direction by a matrix, but an eigenvector stays on its own line: the matrix only stretches it, shrinks it, or flips it, by the factor λ, its eigenvalue. So along that direction the matrix acts like multiplication by a single number, which makes repeated application easy to predict: after k steps, the eigenvector has been scaled by $\lambda^k$.
:::
:::

::: practice

::: check
given: a = 2..9 int; b = -5..5 int; d = -5..-1 int
answer: d
tolerance: 0.001

## What is the smaller eigenvalue of $\begin{bmatrix} \given{a} & 0 \\ \given{b} & \given{d} \end{bmatrix}$?

::: misses
- [any] It's triangular: the eigenvalues are {a} and {d}.
:::
:::

::: check
given: a = 1 | 3 | 5; b = 2 | 4 | 6; c = 1..6 int; d = 2 | 4 | 6
answer: a*d - b*c
tolerance: 0.001

## What is the product of the eigenvalues of $\begin{bmatrix} \given{a} & \given{b} \\ \given{c} & \given{d} \end{bmatrix}$?

::: misses
- [a + d] That's their sum, the trace.
- [any] The product of the eigenvalues is the determinant.
:::
:::

::: check
given: lam = -9..-1 int
answer: -1/lam
unit: ms
tolerance: 0.5%

## A circuit mode has eigenvalue {lam} per ms. What is its time constant, in ms?

::: misses
- [lam] The mode is $e^{\lambda t}$; its time constant is $-1/\lambda$.
- [1/lam] Time constants are positive: $-1/\lambda$.
- [any] $\tau = -1/\lambda$.
:::
:::
:::
