IOAI ML Notes Mathematics Fundamentals

Eigenvalues and Eigenvectors

A practical guide to eigenvalues and eigenvectors: intuition, computation, diagonalisation, and why they matter in ML.

Syllabus Map


Core Definition

For square matrix AA, an eigenvector v0v \ne 0 and eigenvalue λ\lambda satisfy:

Av=λvAv = \lambda v

How to Compute Eigenvalues

Step 1: Characteristic Equation

Solve:

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

This polynomial is the characteristic polynomial.

Step 2: Find Eigenvectors

For each eigenvalue λ\lambda, solve:

(AλI)v=0(A-\lambda I)v=0

to get non-zero vectors in that null space.


2x2 Example

Let

A=[2112]A=\begin{bmatrix}2 & 1\\1 & 2\end{bmatrix}

Characteristic equation:

det ⁣([2λ112λ])=(2λ)21=0\det\!\left(\begin{bmatrix}2-\lambda & 1\\1 & 2-\lambda\end{bmatrix}\right) =(2-\lambda)^2-1=0

So eigenvalues are λ1=3\lambda_1=3, λ2=1\lambda_2=1.

Corresponding eigenvectors (up to scaling):


Geometric Intuition


Diagonalisation

If AA has enough independent eigenvectors, then:

A=PDP1A=PDP^{-1}

where:

Then powers are easy:

Ak=PDkP1A^k = PD^kP^{-1}

Symmetric Matrices (Very Important)

If A=AA=A^\top:

A=QΛQA = Q\Lambda Q^\top

with orthonormal QQ.

This is the basis of PCA and many optimisation results.


Connection to SVD

For any matrix XX:

X=UΣVX = U\Sigma V^\top σi2=λi(XX)\sigma_i^2 = \lambda_i(X^\top X)

Why This Matters for ML

← Back to Blog