Skip to main content

Positive Definite Matrices

The Central Question: When Does a Quadratic Form Always Curve Upward?

The quadratic form f(x)=xTAxf(x) = x^TAx generalizes the idea of ax2ax^2 to multiple dimensions. When is this bowl-shaped (always positive), guaranteeing a unique minimum? Positive definiteness answers this, connecting eigenvalue signs, pivot signs, Cholesky factorization, and the curvature of loss functions in optimization.

Topics to Cover

Quadratic Forms and Geometry

  • The quadratic form f(x)=xTAxf(x) = x^TAx and its graph
  • Positive definite = bowl (minimum), negative definite = dome (maximum), indefinite = saddle
  • Connection to second-derivative test: Hessian matrix

Tests for Positive Definiteness

  • Five equivalent conditions (for symmetric AA):
    1. All eigenvalues λi>0\lambda_i > 0
    2. All upper-left determinants (leading minors) > 0
    3. All pivots > 0
    4. xTAx>0x^TAx > 0 for all x0x \neq 0 (energy test)
    5. A=RTRA = R^TR for some matrix RR with independent columns (Cholesky)
  • Proving the equivalence chain
  • Positive semi-definite: 0\geq 0 everywhere (allow zero eigenvalues)

Cholesky Decomposition (Deeper Treatment)

  • A=LLTA = LL^T: the "square root" of a positive definite matrix
  • Why it exists (positive pivots guarantee no zero divisions)
  • Cost: 13n3\frac{1}{3}n^3 — half the cost of LU
  • Numerical stability: no pivoting needed
  • Cross-reference to Matrix Operations for the introductory treatment

The Gram Matrix ATAA^TA

  • Always positive semi-definite (proof via energy test: xTATAx=Ax20x^TA^TAx = \|Ax\|^2 \geq 0)
  • Positive definite iff AA has independent columns (trivial nullspace)
  • Central object: normal equations, covariance matrices, kernel matrices

Rayleigh Quotient and Min-Max Principles

  • Rayleigh quotient: R(x)=xTAxxTxR(x) = \frac{x^TAx}{x^Tx}
  • λminR(x)λmax\lambda_{\min} \leq R(x) \leq \lambda_{\max} for all x0x \neq 0
  • Min-max (Courant-Fischer): variational characterization of every eigenvalue
  • Interlacing theorem (eigenvalues of submatrices)

Ellipsoids and Principal Axes

  • xTAx=1x^TAx = 1 defines an ellipsoid
  • Eigenvectors = axis directions, 1/λi1/\sqrt{\lambda_i} = axis lengths
  • Condition number κ=λmax/λmin\kappa = \lambda_{\max}/\lambda_{\min} = elongation of the ellipsoid

Summary

Answering the Central Question: A quadratic form xTAxx^TAx always curves upward (is always positive for x0x \neq 0) exactly when AA is positive definite. Five equivalent tests characterize this: all eigenvalues positive, all pivots positive, all leading principal minors positive, A=RTRA = R^TR for some RR with independent columns, and xTAx>0x^TAx > 0 for all nonzero xx. Cholesky factorization (A=LLTA = LL^T) is the computational signature of positive definiteness.

Applications in Data Science and Machine Learning

  • Optimization: Hessian positive definite ⇔ strict local minimum; condition number controls convergence speed of gradient descent
  • Covariance matrices: always PSD; eigenvalues = variance along principal axes
  • Kernel methods: kernel matrix Kij=k(xi,xj)K_{ij} = k(x_i, x_j) must be PSD (Mercer's condition)
  • Gaussian processes: covariance matrix must be PSD; Cholesky used for sampling and log-likelihood
  • Regularization: ATA+λIA^TA + \lambda I is always positive definite for λ>0\lambda > 0 (Ridge regression makes the bowl rounder)

Guided Problems

References

  • Strang, Introduction to Linear Algebra, Chapter 6 (6.1–6.2)
  • Strang, Linear Algebra and Its Applications, Chapter 6