Use symbolic linear algebraLesson 34 of 48 · 8 min

Find directions that keep their line

Interpret an eigenvector and verify its eigenvalue equation.

Maths refresher: Scaling along a direction

Multiplying a vector by a scalar changes its magnitude and possibly its sign without changing the line it lies on.

A(11)=3(11)A\begin{pmatrix}1\\1\end{pmatrix}=3\begin{pmatrix}1\\1\end{pmatrix}
Worked example

For A=(2112)A=\begin{pmatrix}2&1\\1&2\end{pmatrix}, the vector (1,1)(1,1) becomes (3,3)(3,3). Its eigenvalue is 33, and (2,2)(2,2) is another eigenvector on the same line.

Maths prerequisite map ↗

An eigenvector is a nonzero vector whose transformed result remains on the same line. Its eigenvalue is the scalar multiplying that vector. The scalar may stretch, shrink, reverse or, in complex settings, have a broader interpretation.

See the mathematics
vAvw = Awequal axis scale
vAvw = Awequal axis scale
A=(2112)A=\begin{pmatrix}2&1\\1&2\end{pmatrix}
Starter reference. Along v = (1, 1), the matrix scales by 3. Along w = (1, −1), it scales by 1. Both directions stay on their own lines.

SymPy eigenvals reports eigenvalues with algebraic multiplicity. eigenvects also reports bases for the corresponding eigenspaces. An eigenvector’s scale is not unique: any nonzero scalar multiple represents the same direction.

The symmetric matrix below has two real eigenvalues. Check the chosen direction directly by calculating Av−λvAv-\lambda v. This zero-vector residual is clearer evidence than a picture alone. The zero vector is excluded from the definition because it would satisfy that equation for every scalar.

Must every eigenvector returned by another implementation have exactly the same scale?

Write a prediction (optional)

Exact symbolic investigation

Select Run Python with the code unchanged.

Tools
About Python

Python and the course packages can load while you read. Each run starts with fresh user variables; imported modules stay loaded. Stop replaces the worker. Runtime details ↗

Ctrl+Enter or ⌘+Enter runs Python.

Compare with the worked example

Executed from the published Python during the site build. Your own run appears above. Build environment ↗

Eigenvalues and multiplicities
{1:1, 3:1}\left\{ 1 : 1, \ 3 : 1\right\}
Eigenspace bases
[(1, 1, [[−11]]), (3, 1, [[11]])]\left[ \left( 1, \ 1, \ \left[ \left[\begin{matrix}-1\\1\end{matrix}\right]\right]\right), \ \left( 3, \ 1, \ \left[ \left[\begin{matrix}1\\1\end{matrix}\right]\right]\right)\right]
Chosen direction
[11]\left[\begin{matrix}1\\1\end{matrix}\right]
Eigen residual
[00]\left[\begin{matrix}0\\0\end{matrix}\right]
Worked text output
Eigenvalues and multiplicities: {3: 1, 1: 1}
Eigenspace bases: [(1, 1, [Matrix([
[-1],
[ 1]])]), (3, 1, [Matrix([
[1],
[1]])])]
Chosen direction: Matrix([[1], [1]])
Eigen residual: Matrix([[0], [0]])

Read the starter result

Read Eigenspace bases as one list of basis vectors per eigenvalue. The starter Eigen residual is a zero vector, so the chosen direction satisfies the eigenvector equation. Any nonzero multiple represents the same line.

Edit and compare

Replace v = sp.Matrix([1,1]) with v = sp.Matrix([1,-1]). Check Eigenspace bases from your first run to choose the eigenvalue. Set eigenvalue = 3 to eigenvalue = 1 and select Run Python. Does Eigen residual verify that direction?

Return to the editor

Scope. Eigenvalue multiplicity and eigenspace dimension differ in general; not every square matrix has a full eigenvector basis.

Try a fresh case

Why is the zero vector excluded from the eigenvector definition?

Choose an answer
Need a hint?
Hint 1

Substitute v=0v=0 into both sides.

Hint 2

No scalar can be distinguished that way.

Your notesNotes save in this browser when storage is available.