The Matrix That Must Never Go Negative: SPD Matrices in Engineering
Contents
Push a spring. It pushes back. You do work, it stores energy. Push harder, it stores more. Never does a spring hand you free energy on the way in. That one sentence is the whole story of symmetric positive definite (SPD) matrices.
Picture a marble in a bowl π₯£ vs. on a saddle π΄. In the bowl, every nudge costs energy β the marble rolls back. On a saddle, one direction costs energy, the perpendicular direction gives it away. SPD = bowl. Indefinite = saddle. Thatβs it.
Two requirements, each with a physical meaning:
- Symmetric ($k_{ij} = k_{ji}$): the push at joint $i$ from moving joint $j$ equals the push at $j$ from moving $i$. For most stiffness matrices youβll meet β linear elastic and hyperelastic systems β this follows from MaxwellβBetti reciprocity. (Non-associated plasticity, frictional contact, and follower loads are the exceptions where the tangent stiffness can be non-symmetric.)
- Positive definite ($\mathbf v^\top \mathbf K \mathbf v > 0$ for every $\mathbf v \neq \mathbf 0$): every possible deformation stores positive energy. No free lunch.
See also: The geometric projector tensor Β Β·Β Tensor visualization (rank 2, 3, 4)
Where SPD shows up
Pretty much everywhere you store energy, spread uncertainty, or fit a model:
| Field | Matrix | The βenergyβ being positive |
|---|---|---|
| FEM | Stiffness $\mathbf K$ | Strain energy |
| FEM | Mass $\mathbf M$ | Kinetic energy |
| Micromechanics | Elasticity tensor $\mathbb C$ | Strain energy density |
| Statistics | Covariance $\boldsymbol\Sigma$ (PSD) | Variance in any direction |
| Surrogates | Gram matrix $\mathbf G$ | Unique least-squares fit |
| Dynamics | Damping $\mathbf C$ (PSD) | Dissipation, never injection |
Three things can go wrong:
- One zero eigenvalue β singular. The structure has a free direction it can move without deforming β a rigid-body mode or a mechanism. (Think: a chair with one leg missing that slides sideways for free.)
- One negative eigenvalue β indefinite. Thereβs a direction where deforming gives back energy. In real structures this is buckling β the instant a column buckles, its effective stiffness goes negative.
- All positive β SPD. Everything is fine. Solve and go home.
Energy test: what goes wrong
The strain energy is $U = \tfrac12\mathbf v^\top \mathbf K \mathbf v$. We need $U > 0$ for every $\mathbf v$, not just the one we happen to try. The cleanest way to guarantee that: demand every eigenvalue $\lambda_i > 0$. One negative $\lambda$ is enough to break the universe.
Two-node spring element anchored to a wall. Dashed circles mark the rest positions. Amber arrows = displacement v; coloured arrows = restoring force βKv. SPD: nodes oscillate stably back to rest (green). Singular: nodes drift β no restoring force in one direction (yellow). Indefinite: displacement grows without bound and the structure goes unstable (red flash).
Play with it
Drag the sliders. Try to break the bowl into a saddle.
The 2Γ2 symmetric matrix $\mathbf A$. Off-diagonal entries are forced equal.
Quadratic form $f(\mathbf v) = \mathbf v^\top \mathbf A\, \mathbf v$. Bowl = SPD. Saddle = indefinite.
Level set $\mathbf v^\top \mathbf A\, \mathbf v = 1$. SPD (green) β ellipsoid, semi-axes $= 1/\sqrt{\lambda_i}$. Singular (yellow) β disc (one axis β β). Indefinite (red) β hyperboloid saddle, no closed surface. Drag to orbit.
The ellipsoid tells you everything
Draw the set of points where $\mathbf v^\top \mathbf A\, \mathbf v = 1$. Its shape is the matrix:
- Axis directions = eigenvectors (the natural grain of the material).
- Axis lengths = $1/\sqrt{\lambda_i}$. Big $\lambda$ β short axis (stiff direction β hard to squash). Small $\lambda$ β long axis (soft direction β easy to squash).
- SPD π’ β a proper ellipsoid. Isotropic ($\lambda_1 = \lambda_2$) β a sphere.
- Singular π‘ β one $\lambda = 0$, so one axis $= \infty$. The βellipsoidβ opens into an infinite cylinder β a free direction in which deforming costs nothing.
- Indefinite π΄ β one $\lambda < 0$. The level set is a hyperboloid (a saddle surface) β it runs off to infinity through the negative direction.
The 2Γ2 quick check
For $\begin{bmatrix} a & b \ b & d \end{bmatrix}$:
\[\text{SPD} \iff a > 0 \;\text{and}\; ad - b^2 > 0.\]Thatβs two numbers. Done. (The trace $a + d$ is then automatically positive.)
Spectral decomposition in one line
Every symmetric $\mathbf A = \mathbf Q \boldsymbol\Lambda \mathbf Q^\top$. In the eigenbasis, the quadratic form collapses to $\sum_i \lambda_i w_i^2$ β a weighted sum of squares. Thatβs the whole theory.
Equivalent tests for SPD
Four ways to say the same thing β pick whichever is cheapest to check:
- All eigenvalues $> 0$.
- All leading principal minors $> 0$ (Sylvester).
- Cholesky $\mathbf A = \mathbf L \mathbf L^\top$ exists with $L_{ii} > 0$.
- $\mathbf v^\top \mathbf A \mathbf v > 0$ for all $\mathbf v \neq \mathbf 0$.
References
[1] Strang, G. (2016). Introduction to Linear Algebra (5th ed.) β Ch. 6, positive definiteness. [2] Horn & Johnson (2013). Matrix Analysis (2nd ed.). [3] Golub & Van Loan (2013). Matrix Computations (4th ed.) β Ch. 8, symmetric eigenproblem. [4] Bathe, K.-J. (1996). Finite Element Procedures β Ch. 4, stiffness/mass definiteness and rigid-body modes.
Basem Rajjoub