MathIsimple
LA-8.2
Available
Core Topic

Quadratic Forms

Quadratic forms are homogeneous polynomials of degree 2 that arise throughout mathematics and physics. Their classification (positive definite, indefinite, etc.) determines the geometry of conics and quadric surfaces, the nature of critical points in optimization, and the definiteness of energy functions.

Learning Objectives
  • Define quadratic forms and their matrix representation
  • Classify quadratic forms (positive/negative definite, semidefinite, indefinite)
  • Apply Sylvester's criterion for positive definiteness
  • Understand the law of inertia and signature
  • Diagonalize quadratic forms by completing the square
  • Apply quadratic forms to optimization
  • Understand conics and quadric surfaces
  • Connect to eigenvalues and the spectral theorem
Prerequisites
  • Symmetric matrices and spectral theorem (LA-7.5)
  • Eigenvalues and eigenvectors (LA-6.1-6.2)
  • Matrix operations (LA-4.1-4.2)
  • Determinants (LA-5.1-5.3)

1. Definition and Matrix Representation

Definition 8.2: Quadratic Form

A quadratic form on Rn\mathbb{R}^n is a function Q:RnRQ: \mathbb{R}^n \to \mathbb{R}:

Q(x)=xTAx=i,jaijxixjQ(x) = x^T A x = \sum_{i,j} a_{ij} x_i x_j

where AA is a symmetric matrix (we can always assume this).

Example 8.3: Quadratic Form in ℝ²

Q(x,y)=2x2+4xy+3y2Q(x,y) = 2x^2 + 4xy + 3y^2 has matrix:

A=(2223)A = \begin{pmatrix} 2 & 2 \\ 2 & 3 \end{pmatrix}

Note: the coefficient of xyxy is split equally between a12a_{12} and a21a_{21}.

Remark 8.4: Why Symmetric?

For any matrix AA: xTAx=xT(A+AT2)xx^T A x = x^T \left(\frac{A + A^T}{2}\right) x. The symmetric part determines the quadratic form, so we assume A=ATA = A^T without loss of generality.

Example 8.3a: From Polynomial to Matrix

Convert Q(x,y,z)=x2+2y2+3z2+4xy2xz+6yzQ(x,y,z) = x^2 + 2y^2 + 3z^2 + 4xy - 2xz + 6yz to matrix form:

A=(121223133)A = \begin{pmatrix} 1 & 2 & -1 \\ 2 & 2 & 3 \\ -1 & 3 & 3 \end{pmatrix}

Diagonal entries = coefficients of x², y², z². Off-diagonal: half of cross-term coefficient.

Example 8.3b: From Matrix to Polynomial

For A=(1332)A = \begin{pmatrix} 1 & 3 \\ 3 & 2 \end{pmatrix}:

Q(x,y)=x2+6xy+2y2Q(x,y) = x^2 + 6xy + 2y^2

The 6xy comes from 3 + 3 (both off-diagonal entries contribute).

Definition 8.2a: Associated Bilinear Form

Every quadratic form QQ has an associated symmetric bilinear form:

B(x,y)=12[Q(x+y)Q(x)Q(y)]=xTAyB(x,y) = \frac{1}{2}[Q(x+y) - Q(x) - Q(y)] = x^T A y

This recovers the inner product structure from the quadratic form.

Remark 8.4a: Polarization Identity

The bilinear form can be recovered from the quadratic form:

B(x,y)=14[Q(x+y)Q(xy)]B(x,y) = \frac{1}{4}[Q(x+y) - Q(x-y)]

2. Classification

Definition 8.3: Definiteness

A quadratic form Q(x)=xTAxQ(x) = x^T A x is:

  • Positive definite: Q(x)>0Q(x) > 0 for all x0x \neq 0
  • Positive semidefinite: Q(x)0Q(x) \geq 0 for all xx
  • Negative definite: Q(x)<0Q(x) < 0 for all x0x \neq 0
  • Negative semidefinite: Q(x)0Q(x) \leq 0 for all xx
  • Indefinite: Q(x)Q(x) takes both positive and negative values
Theorem 8.3: Eigenvalue Criterion

For symmetric AA:

  • AA positive definite ⟺ all eigenvalues > 0
  • AA positive semidefinite ⟺ all eigenvalues ≥ 0
  • AA negative definite ⟺ all eigenvalues < 0
  • AA indefinite ⟺ eigenvalues of both signs
Proof:

By spectral theorem, A=QDQTA = QDQ^T with orthogonal QQ. Let y=QTxy = Q^T x:

Q(x)=xTAx=yTDy=λiyi2Q(x) = x^T A x = y^T D y = \sum \lambda_i y_i^2

The sign of Q(x)Q(x) depends entirely on the signs of eigenvalues λi\lambda_i.

Example 8.3c: Classifying by Eigenvalues

For A=(2112)A = \begin{pmatrix} 2 & 1 \\ 1 & 2 \end{pmatrix}:

Eigenvalues: λ=3,1\lambda = 3, 1 (both positive)

Classification: Positive definite

Example 8.3d: Indefinite Quadratic Form

For A=(1221)A = \begin{pmatrix} 1 & 2 \\ 2 & 1 \end{pmatrix}:

Eigenvalues: λ=3,1\lambda = 3, -1 (mixed signs)

Classification: Indefinite

Geometrically: Q(1,0)=1>0Q(1,0) = 1 > 0 but Q(1,1)=14+1=2<0Q(1,-1) = 1 - 4 + 1 = -2 < 0

Remark 8.4b: Geometric Interpretation

Level sets Q(x)=cQ(x) = c reveal the geometry:

  • Positive definite: Ellipsoids centered at origin
  • Indefinite: Hyperboloids (saddle shapes)
  • Semidefinite: Degenerate (cylindrical) surfaces
Definition 8.3a: Rank of Quadratic Form

The rank of QQ is rank(A) = n - n₀.

A quadratic form is non-degenerate if rank(A) = n (no zero eigenvalues).

3. Sylvester's Criterion

Definition 8.4: Leading Principal Minors

The leading principal minors of AA are:

Δk=det(Ak)where Ak=upper-left k×k submatrix\Delta_k = \det(A_k) \quad \text{where } A_k = \text{upper-left } k \times k \text{ submatrix}
Theorem 8.4: Sylvester's Criterion

A symmetric matrix AA is positive definite if and only if all leading principal minors are positive:

Δ1>0,Δ2>0,,Δn>0\Delta_1 > 0, \quad \Delta_2 > 0, \quad \ldots, \quad \Delta_n > 0
Example 8.4: Checking Positive Definiteness

Is A=(2113)A = \begin{pmatrix} 2 & 1 \\ 1 & 3 \end{pmatrix} positive definite?

  • Δ1=2>0\Delta_1 = 2 > 0
  • Δ2=det(A)=61=5>0\Delta_2 = \det(A) = 6 - 1 = 5 > 0

Yes, AA is positive definite.

Corollary 8.1: Negative Definiteness

AA is negative definite iff (1)kΔk>0(-1)^k \Delta_k > 0 (alternating signs starting negative).

Example 8.4a: Negative Definite Check

Is A=(2113)A = \begin{pmatrix} -2 & 1 \\ 1 & -3 \end{pmatrix} negative definite?

  • Δ1=2<0\Delta_1 = -2 < 0 ✓ (need negative)
  • Δ2=61=5>0\Delta_2 = 6 - 1 = 5 > 0 ✓ (need positive)

Yes, AA is negative definite.

Proof:

Proof of Sylvester's Criterion (Sketch):

By induction on n. The key observation is that for a positive definite matrix:

  1. The upper-left (n-1)×(n-1) submatrix is positive definite
  2. After Gaussian elimination, all pivots are positive
  3. Products of pivots equal leading principal minors
Remark 8.5a: Practical Use

Sylvester's criterion is useful when:

  • Matrix is small (2×2 or 3×3)
  • Only need to check positive definiteness
  • Computing eigenvalues is expensive
Example 8.4b: 3×3 Sylvester Check

Is A=(422231213)A = \begin{pmatrix} 4 & 2 & 2 \\ 2 & 3 & 1 \\ 2 & 1 & 3 \end{pmatrix} positive definite?

  • Δ1=4>0\Delta_1 = 4 > 0
  • Δ2=124=8>0\Delta_2 = 12 - 4 = 8 > 0
  • Δ3=det(A)=4(91)2(62)+2(26)=3288=16>0\Delta_3 = \det(A) = 4(9-1) - 2(6-2) + 2(2-6) = 32 - 8 - 8 = 16 > 0

Yes, AA is positive definite.

Definition 8.4a: Cholesky Decomposition

A symmetric positive definite matrix has a unique factorization:

A=LLTA = LL^T

where LL is lower triangular with positive diagonal entries.

Remark 8.5b: Cholesky as Test

Cholesky decomposition exists ⟺ A is positive definite. This provides another practical test.

4. Sylvester's Law of Inertia

Definition 8.5: Signature

The signature of a quadratic form is the triple (n+,n,n0)(n_+, n_-, n_0):

  • n+n_+ = number of positive eigenvalues
  • nn_- = number of negative eigenvalues
  • n0n_0 = number of zero eigenvalues (= nullity)
Theorem 8.5: Law of Inertia

The signature is invariant under congruence transformations. If B=PTAPB = P^T A P for invertible PP, then AA and BB have the same signature.

Remark 8.5: Congruence vs Similarity

Similar: B=P1APB = P^{-1}AP (same eigenvalues). Congruent: B=PTAPB = P^T A P (same signature, different eigenvalues).

Example 8.5a: Computing Signature

For A=(1222)A = \begin{pmatrix} 1 & 2 \\ 2 & -2 \end{pmatrix}:

Eigenvalues: λ=2,3\lambda = 2, -3

Signature: (n+,n,n0)=(1,1,0)(n_+, n_-, n_0) = (1, 1, 0) (indefinite)

Theorem 8.5a: Canonical Form

Every quadratic form is congruent to a diagonal form:

PTAP=diag(1,...,1,1,...,1,0,...,0)P^T A P = \text{diag}(1, ..., 1, -1, ..., -1, 0, ..., 0)

with n+n_+ ones, nn_- minus ones, and n0n_0 zeros.

Remark 8.5c: Why Inertia Matters

The law of inertia says that while different bases give different diagonal forms, the essential structure (signature) is preserved. This is the "intrinsic" property of the quadratic form.

Example 8.5b: Verifying Congruence

Show that A=(1111)A = \begin{pmatrix} 1 & 1 \\ 1 & 1 \end{pmatrix} and B=(2000)B = \begin{pmatrix} 2 & 0 \\ 0 & 0 \end{pmatrix} are congruent:

Both have signature (1, 0, 1): one positive eigenvalue, one zero.

A: eigenvalues 2, 0. B: eigenvalues 2, 0. ✓

Definition 8.5a: Completing the Square

Diagonalization by completing the square finds P such that:

Q(x)=xTAx=yTDywhere y=PxQ(x) = x^T A x = y^T D y \quad \text{where } y = Px

This is a congruence transformation D=PTAPD = P^T A P.

Example 8.5c: Completing the Square

Diagonalize Q(x,y)=x2+4xy+y2Q(x,y) = x^2 + 4xy + y^2:

=(x+2y)24y2+y2=(x+2y)23y2= (x + 2y)^2 - 4y^2 + y^2 = (x + 2y)^2 - 3y^2

Let u=x+2y,v=yu = x + 2y, v = y. Then Q=u23v2Q = u^2 - 3v^2.

Signature: (1, 1, 0) — indefinite.

5. Applications

Optimization

Hessian positive definite → local minimum. Negative definite → local maximum. Indefinite → saddle point.

Conic Sections

xᵀAx = 1: ellipse (both eigenvalues same sign), hyperbola (opposite signs).

Physics: Energy

Kinetic energy is positive definite quadratic form. Stability requires positive definite potential.

Statistics

Covariance matrices are positive semidefinite. Mahalanobis distance uses inverse covariance.

Theorem 8.6: Second Derivative Test

For f:RnRf: \mathbb{R}^n \to \mathbb{R} at critical point x0x_0 (where f=0\nabla f = 0):

  • Hessian positive definite → local minimum
  • Hessian negative definite → local maximum
  • Hessian indefinite → saddle point
  • Hessian semidefinite → test inconclusive
Example 8.6a: Optimization Example

Classify critical point of f(x,y)=x2+xy+y23xf(x,y) = x^2 + xy + y^2 - 3x:

Hessian: H=(2112)H = \begin{pmatrix} 2 & 1 \\ 1 & 2 \end{pmatrix}

Sylvester: Δ₁ = 2 > 0, Δ₂ = 3 > 0 → positive definite → local minimum

Example 8.6b: Conic Section Classification

Classify x2+4xy2y2=1x^2 + 4xy - 2y^2 = 1:

Matrix: A=(1222)A = \begin{pmatrix} 1 & 2 \\ 2 & -2 \end{pmatrix}

det(A) = -2 - 4 = -6 < 0 → mixed eigenvalue signs → hyperbola

Definition 8.6: Quadric Surfaces

In ℝ³, xTAx=1x^T A x = 1 describes:

  • Ellipsoid: All eigenvalues same sign (positive definite)
  • Hyperboloid of one sheet: Two positive, one negative
  • Hyperboloid of two sheets: One positive, two negative
Example 8.6c: Quadric Surface

Identify x2+2y2+3z2=6x^2 + 2y^2 + 3z^2 = 6:

Matrix: diag(1, 2, 3) — all positive eigenvalues

Surface: Ellipsoid with semi-axes √6, √3, √2

Remark 8.6: Physics: Stability

In mechanics, stability of equilibrium is determined by the potential energy V:

  • Hessian of V positive definite → stable equilibrium
  • Hessian indefinite → unstable (saddle point)
  • Kinetic energy T is always positive definite quadratic in velocities

6. Common Mistakes

Forgetting to symmetrize the matrix

The coefficient of xy in Q(x,y) must be split equally between a₁₂ and a₂₁.

Confusing definite with semidefinite

Positive definite: Q(x) > 0 for ALL x ≠ 0. Semidefinite allows Q(x) = 0 for some x ≠ 0.

Wrong Sylvester test for negative definite

For negative definite, need (-1)ᵏΔₖ > 0, not just all Δₖ < 0.

Confusing congruence with similarity

Congruent: PᵀAP (same signature). Similar: P⁻¹AP (same eigenvalues).

7. Key Formulas Summary

Quadratic Form

  • Q(x)=xTAxQ(x) = x^T A x
  • AA symmetric
  • • Diagonal form: λiyi2\sum \lambda_i y_i^2

Classification

  • • Pos. def.: all λi>0\lambda_i > 0
  • • Sylvester: all Δk>0\Delta_k > 0
  • • Signature: (n+,n,n0)(n_+, n_-, n_0)

Classification Summary Table

TypeEigenvaluesSylvester
Positive definiteAll > 0All Δₖ > 0
Negative definiteAll < 0(-1)ᵏΔₖ > 0
Positive semidefiniteAll ≥ 0, some = 0All Δₖ ≥ 0
IndefiniteMixed signsN/A

8. More Worked Examples

Example 8.7: Complete Classification

Classify Q(x,y)=2x22xy+2y2Q(x,y) = 2x^2 - 2xy + 2y^2:

Matrix: A=(2112)A = \begin{pmatrix} 2 & -1 \\ -1 & 2 \end{pmatrix}

Sylvester: Δ₁ = 2 > 0, Δ₂ = 4 - 1 = 3 > 0

Eigenvalues: λ = 3, 1 (both positive)

Classification: Positive definite

Example 8.8: Completing the Square (3 variables)

Diagonalize Q=x2+2xy+2y2+2yz+z2Q = x^2 + 2xy + 2y^2 + 2yz + z^2:

Step 1: =(x+y)2+y2+2yz+z2= (x + y)^2 + y^2 + 2yz + z^2

Step 2: =(x+y)2+(y+z)2= (x + y)^2 + (y + z)^2

Signature: (2, 0, 1) — positive semidefinite (rank 2 in ℝ³)

Example 8.9: Constrained Optimization

Minimize Q(x,y)=x2+y2Q(x,y) = x^2 + y^2 subject to x+y=1x + y = 1:

Substitute y=1xy = 1 - x: Q=x2+(1x)2=2x22x+1Q = x^2 + (1-x)^2 = 2x^2 - 2x + 1

Critical point: x=1/2x = 1/2, minimum value = 1/2

Example 8.10: Mahalanobis Distance

The Mahalanobis distance uses covariance matrix Σ:

d2(x,μ)=(xμ)TΣ1(xμ)d^2(x, \mu) = (x - \mu)^T \Sigma^{-1} (x - \mu)

This is a quadratic form in (x - μ). Since Σ is positive definite, so is Σ⁻¹, and d² ≥ 0.

9. Connections and Extensions

Quadratic Forms in Linear Algebra

Spectral Theorem (LA-7.5)

Diagonalization A = QDQᵀ gives Q(x) = Σλᵢyᵢ² where y = Qᵀx.

Inner Products (LA-7.1)

Positive definite A defines inner product ⟨x,y⟩ = xᵀAy.

SVD (LA-8.1)

AᵀA is positive semidefinite. xᵀ(AᵀA)x = ||Ax||².

Determinants (LA-5)

Sylvester uses leading principal minors (determinants of submatrices).

Remark 8.7: Generalization to Complex

For complex vector spaces, quadratic forms become Hermitian forms:

H(x)=xAxwhere A=AH(x) = x^* A x \quad \text{where } A = A^*

All eigenvalues are real, and classification by eigenvalue signs still applies.

10. Chapter Summary

Key Takeaways

Core Concepts
  • • Q(x) = xᵀAx with A symmetric
  • • Classification by eigenvalue signs
  • • Sylvester criterion for positive definiteness
  • • Signature invariant under congruence
Applications
  • • Optimization (Hessian test)
  • • Conic sections and quadric surfaces
  • • Physics (energy, stability)
  • • Statistics (covariance, Mahalanobis)
Remark 8.8: Mastery Checklist

You've mastered quadratic forms when you can:

  • ✓ Convert between polynomial and matrix form
  • ✓ Classify by computing eigenvalues or using Sylvester
  • ✓ Diagonalize by completing the square
  • ✓ Apply to optimization and geometry
  • ✓ Understand the law of inertia and signature

Pro Tips for Exams

  • • Coefficient of xᵢxⱼ (i ≠ j) splits equally: aᵢⱼ = aⱼᵢ = (coefficient)/2
  • • Sylvester is fastest for 2×2 and 3×3 matrices
  • • For Hessian test: positive definite → minimum, negative definite → maximum
  • • Completing square gives signature directly from diagonal form
  • • Congruent ≠ similar (different invariants: signature vs eigenvalues)

11. Additional Theory

Theorem 8.7: Principal Axis Theorem

For any quadratic form Q(x) = xᵀAx with symmetric A, there exists an orthonormal basis in which:

Q(x)=λ1y12+λ2y22++λnyn2Q(x) = \lambda_1 y_1^2 + \lambda_2 y_2^2 + \cdots + \lambda_n y_n^2

where λᵢ are eigenvalues of A and y = Qᵀx for orthogonal Q.

Proof:

This is a restatement of the Spectral Theorem. By spectral decomposition A = QDQᵀ:

xTAx=xTQDQTx=(QTx)TD(QTx)=yTDy=λiyi2x^T A x = x^T Q D Q^T x = (Q^T x)^T D (Q^T x) = y^T D y = \sum \lambda_i y_i^2
Definition 8.7: Principal Axes

The principal axes of the quadric xᵀAx = 1 are the eigenvectors of A. The lengths of the semi-axes are 1/√|λᵢ|.

Example 8.11: Finding Principal Axes

For ellipse 5x2+8xy+5y2=15x^2 + 8xy + 5y^2 = 1:

Matrix: A=(5445)A = \begin{pmatrix} 5 & 4 \\ 4 & 5 \end{pmatrix}

Eigenvalues: λ = 9, 1. Eigenvectors: (1,1)ᵀ/√2, (1,-1)ᵀ/√2

In principal axes: 9u2+v2=19u^2 + v^2 = 1 (ellipse with axes 1/3, 1)

Remark 8.9: Rotation Angle

For 2×2 quadratic form, the rotation angle θ to principal axes satisfies:

tan(2θ)=2a12a11a22\tan(2\theta) = \frac{2a_{12}}{a_{11} - a_{22}}
Theorem 8.8: Rayleigh Quotient

For symmetric A, the Rayleigh quotient R(x)=xTAxxTxR(x) = \frac{x^T A x}{x^T x} satisfies:

λminR(x)λmax\lambda_{\min} \leq R(x) \leq \lambda_{\max}

with extrema achieved at corresponding eigenvectors.

Example 8.12: Rayleigh Quotient Bounds

For A=(3113)A = \begin{pmatrix} 3 & 1 \\ 1 & 3 \end{pmatrix} with λ = 4, 2:

R(x) ranges from 2 (at eigenvector (1,-1)ᵀ) to 4 (at eigenvector (1,1)ᵀ).

12. Additional Practice

Example 8.13: Practice Problem 1

Classify Q(x,y,z)=x2+y2+z2+2xy+2xz+2yzQ(x,y,z) = x^2 + y^2 + z^2 + 2xy + 2xz + 2yz:

Solution:

Matrix: A=(111111111)A = \begin{pmatrix} 1 & 1 & 1 \\ 1 & 1 & 1 \\ 1 & 1 & 1 \end{pmatrix}

Note: A = vvᵀ where v = (1,1,1)ᵀ, so rank(A) = 1

Eigenvalues: 3, 0, 0. Signature: (1, 0, 2)

Classification: Positive semidefinite (not definite)

Example 8.14: Practice Problem 2

For what values of k is A=(2kk2)A = \begin{pmatrix} 2 & k \\ k & 2 \end{pmatrix} positive definite?

Solution:

Sylvester: Δ₁ = 2 > 0 ✓

Δ₂ = 4 - k² > 0 ⟹ |k| < 2

Answer: -2 < k < 2

Example 8.15: Practice Problem 3

Complete the square for Q=x2+2xy3y2Q = x^2 + 2xy - 3y^2:

Solution:

=(x+y)2y23y2=(x+y)24y2= (x + y)^2 - y^2 - 3y^2 = (x + y)^2 - 4y^2

Let u = x + y, v = y. Then Q = u² - 4v²

Signature: (1, 1, 0) — indefinite

Example 8.16: Practice Problem 4

Classify the critical point of f(x,y)=x3+y33xyf(x,y) = x^3 + y^3 - 3xy at (1,1):

Solution:

Hessian: H=(6x336y)H = \begin{pmatrix} 6x & -3 \\ -3 & 6y \end{pmatrix}

At (1,1): H=(6336)H = \begin{pmatrix} 6 & -3 \\ -3 & 6 \end{pmatrix}

Δ₁ = 6 > 0, Δ₂ = 36 - 9 = 27 > 0 → positive definite

Classification: local minimum

Remark 8.10: Practice Strategy

For exam preparation:

  • Practice converting polynomials to matrices and back
  • Use Sylvester for small matrices (2×2, 3×3)
  • Use eigenvalues for larger matrices or when you need the signature
  • Know when to use completing the square vs spectral decomposition

13. Quick Reference

Tests for Positive Definiteness

  1. All eigenvalues positive
  2. All leading principal minors positive (Sylvester)
  3. Cholesky decomposition exists (A = LLᵀ)
  4. xᵀAx > 0 for all x ≠ 0 (definition)

Geometry of xᵀAx = 1

  • • Pos. def. → Ellipsoid (bounded)
  • • Neg. def. → Empty (no solutions)
  • • Indefinite → Hyperboloid
  • • Semidefinite → Degenerate

Key Formulas

Q(x) = xᵀAxQuadratic form
Δₖ = det(Aₖ)Leading principal minor
(n₊, n₋, n₀)Signature
B = PᵀAPCongruence transformation
R(x) = xᵀAx/xᵀxRayleigh quotient

14. Final Synthesis

The Big Picture

Quadratic forms are the bridge between linear algebra and analysis/geometry. They encode the "second-order behavior" of functions and transformations, determining curvature, stability, and optimal directions.

Algebra

Q(x) = xᵀAx with symmetric A. Classification by eigenvalues.

Geometry

Conics, quadrics, principal axes. Shape determined by signature.

Analysis

Hessian test, optimization, stability of equilibria.

Remark 8.11: Looking Forward

Quadratic forms lead naturally to:

  • Tensors (LA-8.3): Multilinear generalizations
  • Differential geometry: Riemannian metrics, curvature
  • Convex optimization: Positive definiteness ensures convexity
  • Control theory: Lyapunov stability

15. Advanced Applications

Example 8.17: Lagrange Multipliers

Optimize Q(x) = xᵀAx subject to ||x|| = 1:

  1. Set up Lagrangian: L = xᵀAx - λ(xᵀx - 1)
  2. Gradient condition: 2Ax = 2λx → Ax = λx
  3. Solutions are eigenvectors! λ are eigenvalues.
  4. Maximum = λₘₐₓ, minimum = λₘᵢₙ
Example 8.18: Normal Modes

For coupled oscillators with kinetic energy T and potential V:

T=12x˙TMx˙,V=12xTKxT = \frac{1}{2}\dot{x}^T M \dot{x}, \quad V = \frac{1}{2}x^T K x

Normal modes solve the generalized eigenvalue problem Kv = ω²Mv.

Frequencies ω² must be positive for stable oscillation (K positive definite).

Example 8.19: Gaussian Distribution

The multivariate Gaussian PDF involves a quadratic form:

f(x)=1(2π)nΣexp(12(xμ)TΣ1(xμ))f(x) = \frac{1}{\sqrt{(2\pi)^n |\Sigma|}} \exp\left(-\frac{1}{2}(x-\mu)^T \Sigma^{-1}(x-\mu)\right)

Level curves are ellipsoids determined by covariance Σ (positive definite).

Remark 8.12: Energy Functions

In many physical systems, energy takes quadratic form near equilibrium:

  • Elastic: E = ½kx² (spring)
  • Kinetic: T = ½mv² (mass)
  • Electromagnetic: E = ½CV² (capacitor)

Positive definiteness ensures stability.

Example 8.20: Convexity

A function f is convex if its Hessian is positive semidefinite everywhere.

For f(x) = xᵀAx + bᵀx + c:

  • Hessian H = 2A (constant)
  • f is convex ⟺ A is positive semidefinite
  • f is strictly convex ⟺ A is positive definite

16. Computational Methods

Methods Comparison
MethodInformationCost
EigenvaluesFull classification + signatureO(n³)
SylvesterOnly definitenessO(n³) determinants
CholeskyPositive definiteness checkO(n³/3)
Complete squareSignature (diagonalization)O(n³)
Example 8.21: Cholesky Test

Check if A=(4223)A = \begin{pmatrix} 4 & 2 \\ 2 & 3 \end{pmatrix} is positive definite using Cholesky:

L11=4=2L_{11} = \sqrt{4} = 2

L21=2/2=1L_{21} = 2/2 = 1

L22=31=2L_{22} = \sqrt{3 - 1} = \sqrt{2}

Success! A=(2012)(2102)A = \begin{pmatrix} 2 & 0 \\ 1 & \sqrt{2} \end{pmatrix}\begin{pmatrix} 2 & 1 \\ 0 & \sqrt{2} \end{pmatrix}

Remark 8.13: Numerical Considerations

In practice:

  • Cholesky is fastest for positive definiteness check
  • Eigenvalues needed for signature or when near-semidefinite
  • Near-zero eigenvalues indicate near-singularity
  • Machine precision affects classification near boundaries

17. More Practice Problems

Example 8.22: Practice Problem 5

Find all values of a for which Q = x² + 2axy + y² is positive definite:

Solution:

Matrix: A=(1aa1)A = \begin{pmatrix} 1 & a \\ a & 1 \end{pmatrix}

Sylvester: Δ₁ = 1 > 0 ✓, Δ₂ = 1 - a² > 0

Answer: |a| < 1

Example 8.23: Practice Problem 6

Identify the quadric surface x² + y² - z² = 1:

Matrix: diag(1, 1, -1). Signature: (2, 1, 0)

Surface: Hyperboloid of one sheet

Example 8.24: Practice Problem 7

Show that AᵀA is always positive semidefinite:

Proof: xᵀ(AᵀA)x = (Ax)ᵀ(Ax) = ||Ax||² ≥ 0 for all x

Positive definite iff A has full column rank (null(A) = {0})

Example 8.25: Practice Problem 8

Classify critical points of f(x,y) = x² - 2xy + 3y²:

Hessian: H=(2226)H = \begin{pmatrix} 2 & -2 \\ -2 & 6 \end{pmatrix} (constant)

Sylvester: Δ₁ = 2 > 0, Δ₂ = 12 - 4 = 8 > 0

H is positive definite → f has a unique global minimum at (0,0)

Quadratic Forms Practice
12
Questions
0
Correct
0%
Accuracy
1
A quadratic form Q(x)=xTAxQ(x) = x^T A x requires AA to be:
Easy
Not attempted
2
Positive definite means:
Easy
Not attempted
3
AA is positive definite iff:
Medium
Not attempted
4
Sylvester's criterion: AA is positive definite iff:
Medium
Not attempted
5
The signature of a quadratic form is:
Medium
Not attempted
6
Sylvester's law of inertia states:
Medium
Not attempted
7
For Q(x,y)=x2+4xy+y2Q(x,y) = x^2 + 4xy + y^2, the matrix is:
Medium
Not attempted
8
A quadratic form is indefinite if:
Easy
Not attempted
9
Completing the square diagonalizes by:
Hard
Not attempted
10
At a critical point, the Hessian being positive definite means:
Medium
Not attempted
11
The equation xTAx=1x^T A x = 1 with positive definite AA describes:
Medium
Not attempted
12
Negative semidefinite means:
Hard
Not attempted

Frequently Asked Questions

Why must the matrix be symmetric?

Any matrix A can be replaced by (A+Aᵀ)/2 without changing xᵀAx, since xᵀAx is a scalar and equals xᵀAᵀx. So we may assume symmetry without loss of generality.

What's the difference between positive definite and positive semidefinite?

Definite: Q(x) > 0 for all x ≠ 0 (all eigenvalues positive). Semidefinite: Q(x) ≥ 0 for all x (eigenvalues ≥ 0, at least one is zero).

How do I check positive definiteness quickly?

Three ways: (1) All eigenvalues positive, (2) Sylvester's criterion (leading principal minors positive), (3) Cholesky decomposition exists (A = LLᵀ).

What is the law of inertia?

The signature (n₊, n₋, n₀) is invariant under congruence transformations PᵀAP. Different bases may give different diagonal forms, but the number of positive/negative/zero entries stays the same.

How does this relate to optimization?

At a critical point, the Hessian (matrix of second derivatives) determines the nature: positive definite → minimum, negative definite → maximum, indefinite → saddle point.

What are conics and quadric surfaces?

xᵀAx + bᵀx + c = 0 describes conics (2D) or quadric surfaces (3D). The eigenvalues of A determine the type: ellipse/ellipsoid (all same sign), hyperbola/hyperboloid (mixed signs).

Can I always diagonalize a quadratic form?

Yes! By spectral theorem (orthogonally) or completing the square (by congruence). The diagonal form shows the signature directly.

What's the connection to inner products?

A positive definite symmetric matrix A defines an inner product ⟨x,y⟩ = xᵀAy. Conversely, every inner product on ℝⁿ has this form for some positive definite A.

Why does Sylvester's criterion work?

The leading principal minors are products of eigenvalues of submatrices. All positive means no sign changes, hence all eigenvalues positive.

How do eigenvalues determine the shape?

For xᵀAx = 1: eigenvalues give 1/(semi-axis length)². Larger eigenvalue → shorter axis. Positive definite → ellipsoid, indefinite → hyperboloid.