Squeeze a circle with a symmetric matrix. Watch it become an ellipse whose two axes meet at a right angle, whatever you do.
Stretching along perpendicular axes
A symmetric matrix S = [5 s; s 2] turns the circle into an ellipse.
The unit circle and the matrix S = [5 2; 2 2], symmetric.
Describe this picture
One panel with the unit circle and a faint grid. The matrix is , starting at . Over about 8 s the circle and the grid warp into an ellipse, and its two semi-axes grow out from the centre as arrows, with a right-angle mark between them: a long one of 6 along , at 26.57°, and a short one of 1 along , at 116.57°. Readouts give the two semi-axes and the angle of the long one. One control after the clip: a slider for from 0 to 3.16. The ellipse changes shape and the axes turn, but they stay at a right angle. At the axes lie along the coordinate axes with lengths 5 and 2. At they are 6.854 and 0.146 long, at 31.72°. Near the short axis shrinks to almost nothing.
Perpendicular axes
A matrix like the one in the picture has a mirror pattern: the entry above the diagonal equals the entry below it. A matrix that equals its own transpose, from Transposes and permutations, is symmetric:
I write a symmetric matrix as . Every symmetric matrix in the picture turns the circle into an ellipse whose two axes meet at a right angle. The eigenvectors point along the axes, and the eigenvalues are the lengths of the semi-axes (their sizes, if one is negative). Take :
Its trace is 7 and its determinant , so its eigenvalues are 6 and 1, as on Finding eigenvalues. The eigenvectors are , since , and , since . And : a right angle.
Compare the matrix of the eigenvectors page, , which is not symmetric. Its eigenvectors and have , so they meet at 71.57°, not 90°. Right angles are a gift of symmetry, not of every matrix.
Why the axes are perpendicular
Here is the reason, in one line. Let and . Move across the dot product with the transpose, , and use :
So . When the two eigenvalues differ, the dot product must be 0, and the eigenvectors are perpendicular. When they are equal, every direction in their plane is stretched alike, so you may choose a perpendicular pair.
Real eigenvalues
A symmetric matrix never has complex eigenvalues. For the quantity under the square root in the formula of Finding eigenvalues is
It is a sum of squares, so the roots are real. The angle of the axes comes out neatly too: the eigenvector of the larger eigenvalue sits at the angle with
For , , so is 26.57°, which is 0.4636 rad: the direction of .
The spectral theorem
Scale each eigenvector to length 1. For above, and . They are perpendicular and of length 1, so the matrix with them as columns,
has orthonormal columns, as in Orthonormal bases and Gram–Schmidt: , so its inverse is its transpose. Diagonalising as in Diagonalisation and matrix powers, with in place of , gives
This is the spectral theorem: every real symmetric matrix is a turn to its axes (), a stretch along each axis (), and a turn back (). No inverse is needed, only a transpose.
A sum of stretches
Multiply out by columns times rows, as in Matrix multiplication:
Each is the projection onto one axis, from Projections. So a symmetric matrix projects a point onto each axis, stretches each piece by its eigenvalue, and adds the pieces.
Sum of two pieces
S = [5 2; 2 2] as two flat pieces, one per eigenvector.
6 q_{1} q_{1}ᵀ flattens the circle onto the line of (2, 1) and stretches it to 6 each way.
Describe this picture
Three small panels for , side by side (stacked on a phone), each starting with the unit circle. In turn, about 2 s each: the first shows , the circle flattened onto the line of and stretched to 6 each way. The second shows , the circle flattened onto the line of , 1 each way. The third adds them, point by point, and the ellipse of the first picture appears. There is no control.
With numbers:
In signal processing · eigenvectors of a correlation matrix
The autocorrelations of a random process fill a symmetric matrix with constant diagonals, entry in row and column . Its eigenvectors are perpendicular, by this page, and for long records they are close to sinusoids. Power spectral density, in the signal processing course, uses that to read the spectrum from its eigenvalues. Matrix entries count from 1, while lags and samples count from 0.
Worked example
1. Eigenvalues, axes, factors. : trace 7, determinant 6, and 1, eigenvectors and . The pieces add back to , as above. A check that needs no eigenvectors: the squares of the entries add up to , and so do the squares of the eigenvalues, .
2. Not symmetric, not perpendicular. The eigenvectors and of meet at 71.57°.
3. A data cloud. Two measurements, each with spread 1 and correlation 0.8, have the covariance matrix . Its eigenvalues are 1.8 along and 0.2 along . The ellipse that holds the cloud at one standard deviation has semi-axes and , tilted at 45°.
4. Two masses on springs. Two equal masses are joined to two walls and to each other by three equal springs, with stiffness over mass . Their positions obey with
Its eigenvalues are 100, along , and 300, along . A motion along an eigenvector needs , so the masses swing together at rad/s, or 1.59 Hz, and against each other at rad/s, or 2.76 Hz.
Try these before you read the answers.
- A symmetric matrix has eigenvalues 3 and 1. At what angle do its eigenvectors meet? 90°.
- Eigenvalues and directions of ? 3 along , and 1 along .
- Can a real symmetric matrix have complex eigenvalues? No: .
- If , what is ? , when no eigenvalue is 0.
Where this leads · the ellipse of a data cloud
Joint distributions, in the probability and statistics course, draws clouds of points with correlation 0.8. The ellipse those clouds fill is the ellipse of example 3: its axes are the eigenvectors of the covariance matrix.
Where you’ll meet this
Principal axes. A cloud of data points, the stress inside a beam and the way a body resists being spun all have a symmetric matrix. Its eigenvectors are the natural axes of the problem, at right angles, and its eigenvalues say how much happens along each.
Vibration modes. Anything built from masses and springs, from a guitar body to a bridge, vibrates in modes that are the eigenvectors of a symmetric matrix, as in example 4. There the masses are equal, so the modes are perpendicular, and each can be excited and measured on its own.
Least squares. The matrix of Least squares is always symmetric, since .
Reference card
| Quantity | Formula | Notes |
|---|---|---|
| Symmetric | mirror pattern across the diagonal | |
| Eigenvalues | all real | : |
| Eigenvectors | perpendicular | for different eigenvalues |
| Spectral theorem | ||
| Pieces | a stretch along each axis | |
| Axis angle, | for | |
| Inverse | when no eigenvalue is 0 |