Level 0: Foundation
★☆☆☆☆ Introductory⏱ 5 minGeneral audience. No mathematics required.Every machine is turn, stretch, turn
Draw a circle on a rubber sheet and apply any linear machine. The circle always becomes an ellipse (or, if the machine squashes, a flat line). Here’s the amazing part: every linear machine can be done in three simple steps:
- Turn the sheet;
- Stretch it along the two straight axes, by different amounts;
- Turn it again.
This recipe is the Singular Value Decomposition. The stretch amounts are the singular values: the long and short radii of the ellipse.
A photo is a big table of numbers. The SVD finds the few “main patterns” that make up most of the picture. Keep only those and you have a compressed photo that still looks almost the same (A2.3-6).
- 1. A linear machine turns a circle into…
- 2. How many steps does the SVD recipe have?
- 3. A circle of radius 1 stretched 3× sideways and 2× upward. Longest radius?
Level 1: Beginner
★★☆☆☆ Basic⏱ 15 minSecondary-school mathematics: arithmetic and elementary algebra.The formula
- : rotate (an orthogonal matrix).
- : stretch along the axes by .
- : rotate again (orthogonal).
It works for any matrix, even rectangular or singular ones. Eigen-decompositions can’t do that.
Simple examples
- : the singular values are and . Singular values are always . The minus sign is absorbed into or .
- A rotation: both singular values are 1. It turns but doesn’t stretch.
- : singular values 2 and 0. A zero means a squashed direction.
Rank from singular values
The rank equals the number of non-zero singular values. has rank 2.
- 1. Largest singular value of diag(3, −2)?
- 2. Singular values of any rotation?
- 3. A matrix has singular values 7, 2, 0, 0. Its rank?
Level 2: Intermediate
★★★☆☆ Intermediate⏱ 40 minUndergraduate students and practising engineers.Shapes and pieces
For with rank :
| Piece | Meaning |
|---|---|
| (right singular vectors) | orthonormal input directions |
| (left singular vectors) | orthonormal output directions, with |
| how much direction is stretched |
The “thin” SVD keeps only (or ) columns. For a matrix, is .
Connection to eigenvalues
So the are the eigenvalues of . For example, gives , with eigenvalues 45 and 5, so and . Check: and .
What the SVD tells you
| Question | Answer from the SVD |
|---|---|
| Rank? | the number of (above a tolerance, in practice) |
| Largest stretch, ? | |
| How close to singular? | , and the condition number |
| Column and row spaces? | the first columns of and of |
| Null space? | the remaining columns of (A2.1-6) |
| Best rank- approximation? | keep the top terms (A2.3-6) |
For a centred data matrix , the right singular vectors are the principal components, and are the variances. Working on directly avoids forming the covariance matrix, which squares the condition number, so libraries like scikit-learn compute PCA by SVD (D9).
- 1. The σᵢ² are the eigenvalues of…
- 2. For a square A, the product of its singular values equals…
- 3. Shape of U in the thin SVD of a 5 × 3 matrix?
Level 3: Advanced
★★★★☆ Advanced⏱ 45 minGraduate level, with full derivations and proofs.Existence for every matrix
Every real matrix has a factorization with orthogonal , orthogonal , and diagonal with non-negative entries in decreasing order. The singular values are unique.
Proof. is symmetric PSD, so the spectral theorem (A2.3-2) gives orthonormal eigenvectors with eigenvalues . Set , and for let . These are orthonormal: . Extend the to an orthonormal basis of . Then for every , which in matrix form is . ∎
Extremal characterization
So for every . It follows from writing in the basis: .
SVD vs eigen-decomposition
| Eigen | SVD | |
|---|---|---|
| Exists for | some square matrices | every matrix |
| Bases | one (input = output), maybe not orthogonal | two orthonormal ones |
| Diagonal | can be negative or complex | always real, |
| Same when | is symmetric PSD |
Polar decomposition
is an orthogonal matrix times a PSD stretch. is the closest orthogonal matrix to . Robotics uses this to re-orthogonalize a rotation matrix that has drifted through integration errors (Practice Code 4).
Exercise 3.1: Show that the singular values of an orthogonal Q are all 1
, whose eigenvalues are all 1, so every .
- 1. A singular value of 4 corresponds to which eigenvalue of AᵀA?
- 2. σ = (10, 0.1). Condition number?
- 3. The closest orthogonal matrix to A = UΣVᵀ is…
Level 4: Expert
★★★★★ Expert⏱ 35 minResearchers: original papers and open problems.Aligning point clouds: the Kabsch / Procrustes problem
Given matched 3-D points and (for example, two LiDAR scans), find the rotation and translation minimizing . The answer comes from one SVD of the cross-covariance : . The determinant term prevents a reflection. This closed form (Kabsch, 1976; Arun, Huang and Blostein, 1987) is the inner step of ICP scan matching, used by every LiDAR-based robot and autonomous car (T4).
SVD across research
- Computer vision. The essential matrix in two-view geometry is estimated and decomposed by SVD (the 8-point algorithm, Hartley, 1997), giving camera rotation and translation (T4).
- Deep learning analysis. The singular-value spectra of weight matrices reveal training quality: heavy-tailed spectra correlate with generalization (Martin and Mahoney, 2021). Spectral normalization divides by to stabilize GAN training (Miyato et al., 2018).
- Recommender systems. Netflix-prize-era models were low-rank matrix factorizations, close relatives of the SVD (D13).
- Model compression. Low-rank SVD of trained weight matrices compresses networks. LoRA’s adapters are low-rank by design (F6).
References
- E. Beltrami (1873) and C. Jordan (1874). (Independent discoveries of the SVD.)
- C. Eckart and G. Young (1936). “The approximation of one matrix by another of lower rank.” Psychometrika, 1.
- G. Golub and W. Kahan (1965). “Calculating the singular values and pseudo-inverse of a matrix.” SIAM Journal on Numerical Analysis, 2(2).
- W. Kabsch (1976). “A solution for the best rotation to relate two sets of vectors.” Acta Crystallographica A, 32.
- K. S. Arun, T. Huang, S. Blostein (1987). “Least-squares fitting of two 3-D point sets.” IEEE TPAMI, 9(5).
- T. Miyato, T. Kataoka, M. Koyama, Y. Yoshida (2018). “Spectral normalization for generative adversarial networks.” ICLR.
- C. Martin and M. Mahoney (2021). “Implicit self-regularization in deep neural networks.” JMLR, 22(165).
- G. Strang (2016). Introduction to Linear Algebra, 5th ed. Chapter 7.