Every matrix is a rotation, a stretch and a rotation
Eigendecomposition needs a square matrix, and even then it can fail. The singular value decomposition works for every matrix, rectangular or not: A=UΣVT with U and V orthogonal and Σ diagonal with non-negative entries σ1≥σ2≥⋯≥0, the singular values. Geometrically A first rotates by VT, then stretches each axis i by σi, then rotates by U. A unit circle becomes an ellipse whose semi-axes are the singular values.
The columns of V are the eigenvectors of ATA and the columns of U are the eigenvectors of AAT, with eigenvalues σi2. So the SVD is the spectral theorem applied to ATA, but computed without ever forming that product, which would square the condition number and lose half the digits. Reading off facts is easy: the rank is the number of non-zero singular values, ∥A∥2=σ1 is the largest stretch, the Frobenius norm squared is the sum of the squared singular values, ∣detA∣=∏σi for a square matrix, and the condition number σ1/σmin measures how much A can amplify errors. For a m×n data matrix with m≥n, the full U is m×m, Σ is m×n and V is n×n.
A 2 by 2 exampleTake A=(3405). Then ATA=(25202025) has eigenvalues 45 and 5, so the singular values are σ1=45≈6.708 and σ2=5≈2.236. Checks: σ12+σ22=50=9+16+25=∥A∥F2, and σ1σ2=15=∣detA∣. The condition number is σ1/σ2=3. If σ2 were 0.001 instead, the condition number would be about 6,700 and solving Ax=b would lose almost four digits.
SVD: every matrix is UΣVT with orthogonal U, V and non-negative sorted singular values.
Facts: rank is the count of non-zero σi, ∥A∥F2=∑σi2, ∣detA∣=∏σi.
Condition number: σ1/σmin; a large value means unstable solves and unreliable inverses.
From returns to components in one callIf X is a T×N matrix of demeaned returns, its covariance is XTX/(T−1), so the right singular vectors of X are the principal directions and σi2/(T−1) are the variances along them. Taking the SVD of X directly gives PCA more accurately than eigendecomposing the covariance matrix, and it works even when N>T.
Lab · what's graded
The largest singular value20 pts
The Frobenius identity10 pts
The product of singular values10 pts
Shapes of a full SVD15 pts
Singular values and eigenvalues15 pts
A condition number15 pts
Why not eigendecompose AᵀA15 pts
0/ 7 answered
1Numeric answer20 ptsNot answered
Find the largest singular value of A=(3405), given that ATA=(25202025). Give it to three decimals.
sigma1=accepted: ± 0.01
2Numeric answer10 ptsNot answered
For the same A, the sum of squares of all its entries equals σ12+σ22. What is ∥A∥F2?
Frobeniussquared=accepted: ± 0.01
3Numeric answer10 ptsNot answered
For the same A, the product σ1σ2 equals ∣detA∣. What is it?
product=accepted: ± 0.01
4Fill the blanks15 ptsNot answered
A data matrix A has 5 rows and 3 columns. Fill in the sizes of the factors in its full SVD A=UΣVT.
U:×,Σ:×,V:×
5Choice15 ptsNot answered
How are the singular values of A related to eigenvalues?
6Numeric answer15 ptsNot answered
A matrix has singular values 6, 3 and 0.5. What is its condition number?
kappa=accepted: ± 0.01
7Explain in words15 ptsNot answered
In one or two sentences, say why computing the SVD of A is numerically better than eigendecomposing ATA.
Math modeKeyboard or LaTeX inputTask 1 of 7 · Ctrl ⏎ to check