Chapter 58. Sylvester’s Law of Inertia
Sylvester’s law of inertia is a classification theorem for real quadratic forms and real symmetric matrices. It says that although a quadratic form may have many different matrix representations in different bases, the numbers of positive, negative, and zero square terms are invariant. These numbers are called the inertia of the form or matrix. The theorem states that real symmetric matrices related by a congruence transformation have the same numbers of positive, negative, and zero eigenvalues.
58.1 Quadratic Forms
A quadratic form on is a function
of the form
where is a real symmetric matrix.
For example, if
then
Multiplying gives
The cross term appears because the off-diagonal entries of contribute symmetrically.
58.2 Diagonal Quadratic Forms
A diagonal quadratic form has the form
Its behavior is easy to read from the signs of the coefficients.
| Coefficient type | Meaning |
|---|---|
| Positive square direction | |
| Negative square direction | |
| Null direction |
For example,
has one positive square, one negative square, and one zero direction. The variable does not appear, so the quadratic form vanishes in the -direction.
The inertia is
58.3 Congruence
Two real symmetric matrices and are congruent if there exists an invertible matrix such that
This is the matrix transformation induced by a change of basis in a quadratic form.
If
then
Thus
So the same quadratic form has matrix in the -coordinates and matrix
in the -coordinates.
Congruence differs from similarity. Similarity has the form
and preserves eigenvalues. Congruence has the form
and preserves inertia.
58.4 Statement of the Law
Let be a real symmetric matrix. Then there exists an invertible matrix such that
The numbers
are independent of the choice of . They are invariants of the quadratic form. They satisfy
This is Sylvester’s law of inertia. It says that a real quadratic form can be reduced to a sum of positive squares, negative squares, and zero terms, and the number of each kind is intrinsic.
58.5 Inertia
The inertia of a real symmetric matrix is the triple
where:
| Symbol | Meaning |
|---|---|
| Number of positive eigenvalues | |
| Number of negative eigenvalues | |
| Number of zero eigenvalues |
Eigenvalues are counted with algebraic multiplicity.
For a diagonal matrix, the inertia is read directly from the diagonal entries.
For example,
has
There are two positive diagonal entries, one negative diagonal entry, and one zero diagonal entry.
58.6 Signature and Rank
The signature of a real symmetric matrix is often defined as
The rank is
The nullity is
Thus inertia contains signature, rank, and nullity.
For example, if
then
and
58.7 Canonical Form
Sylvester’s law says that every real quadratic form can be written in the canonical form
The remaining variables, if any, do not appear.
More explicitly,
This form gives the complete classification of real quadratic forms under invertible linear changes of variables.
Two real quadratic forms are equivalent under a change of coordinates exactly when they have the same inertia.
58.8 Example: Removing a Cross Term
Consider
This can be rewritten as
Let
Then
The canonical form is
Thus the inertia is
The form has one positive direction, no negative direction, and one null direction. The null direction corresponds to vectors satisfying
58.9 Example: Indefinite Form
Consider
This is already diagonal. Its inertia is
It is positive in the direction
negative in the direction
and zero on the nonzero vectors satisfying
These are the lines
and
An indefinite quadratic form may vanish on nonzero vectors even when its matrix is nonsingular.
58.10 Definite, Semidefinite, and Indefinite Forms
Inertia classifies definiteness.
| Inertia | Type |
|---|---|
| Positive definite | |
| Negative definite | |
| , | Positive semidefinite |
| , | Negative semidefinite |
| and | Indefinite |
Thus a quadratic form is positive definite precisely when all its inertia is positive:
It is indefinite precisely when it has both positive and negative directions.
58.11 Relation to Eigenvalues
Because is real symmetric, the spectral theorem gives
where is orthogonal and is diagonal with real eigenvalues.
Then
Set
Since ,
Therefore
The signs of the eigenvalues give the inertia:
This proves that inertia can be computed from eigenvalues. It also explains why inertia is stable under congruence, not because eigenvalues themselves are preserved, but because their signs are.
58.12 Congruence Does Not Preserve Eigenvalues
Congruent matrices generally do not have the same eigenvalues.
For example, let
and let
Then
The eigenvalues changed from
to
But the inertia stayed the same:
Congruence preserves the signs of the diagonalized form, not the actual eigenvalue magnitudes.
58.13 Completing Squares
Sylvester’s law can be understood by completing squares.
Consider
Complete the square in :
Since
we get
Thus
Let
Then
Both coefficients are positive, so
The quadratic form is positive definite.
58.14 A Three-Dimensional Example
Let
Since
we have
Let
Then
The variable does not appear. Therefore the inertia is
This means the form has one positive direction, one negative direction, and one null direction.
58.15 Maximal Positive and Negative Subspaces
The positive index has a geometric meaning. It is the largest possible dimension of a subspace on which the quadratic form is positive definite.
Similarly, is the largest possible dimension of a subspace on which the quadratic form is negative definite.
For example, if
then
The -plane is a two-dimensional positive definite subspace. The -axis is a one-dimensional negative definite subspace. There cannot be a three-dimensional positive definite subspace because the form is negative in the -direction.
This gives a coordinate-free interpretation of inertia.
58.16 Relation to Positive Definite Matrices
A real symmetric matrix is positive definite if and only if
Equivalently, all eigenvalues are positive.
It is positive semidefinite if and only if
It is nonsingular if and only if
Thus Sylvester’s law gives a compact classification:
| Matrix property | Inertia condition |
|---|---|
| Positive definite | |
| Negative definite | |
| Positive semidefinite | |
| Negative semidefinite | |
| Nonsingular | |
| Indefinite | and |
58.17 LDLT Factorization and Inertia
For a symmetric matrix, a factorization of the form
can be used to compute inertia.
Here is lower triangular and invertible, and is block diagonal or diagonal, depending on pivoting. Since
the matrices and are congruent. Therefore they have the same inertia.
When is diagonal, inertia is read from the signs of the diagonal entries.
This is important in numerical computation. Computing all eigenvalues may be expensive. Factorization methods often give inertia more directly.
58.18 Law of Inertia for Hermitian Matrices
There is a complex analogue.
If is Hermitian, then its eigenvalues are real. Under an invertible complex change of variables,
the numbers of positive, negative, and zero eigenvalues remain unchanged.
Thus Hermitian matrices are classified under congruence by inertia in the same way as real symmetric matrices.
58.19 Applications
Sylvester’s law of inertia appears wherever quadratic behavior must be classified.
| Area | Use |
|---|---|
| Optimization | Classify Hessians at critical points |
| Differential geometry | Classify metric signatures |
| Numerical linear algebra | Determine definiteness and inertia |
| Quadratic forms | Classify forms under coordinate changes |
| Conic and quadric geometry | Classify second-degree surfaces |
| Stability analysis | Count positive and negative energy directions |
In multivariable calculus, if the Hessian matrix at a critical point has inertia , the point is a local minimum. If it has inertia , the point is a local maximum. If it has both positive and negative directions, the point is a saddle point.
58.20 Summary
Sylvester’s law of inertia classifies real quadratic forms under invertible linear changes of variables.
Every real symmetric matrix is congruent to a diagonal matrix with entries only
The numbers of these entries are invariant. They form the inertia
These numbers equal the counts of positive, negative, and zero eigenvalues of .
The law separates what changes under coordinates from what does not. Coefficients and eigenvalue magnitudes may change under congruence. The numbers of positive, negative, and null directions do not.