Documentation

TauCeti.LinearAlgebra.QuadraticForm.Real

Classification of real quadratic forms by their signature #

Mathlib proves the two halves of Sylvester's law of inertia separately: every real quadratic form on a finite-dimensional space is equivalent to a weighted sum of squares with weights 1, 0 and -1, and the numbers of positive and of negative weights are the invariants sigPos and sigNeg. This file combines them into the classification itself: two real quadratic forms are isometric exactly when their dimensions and their two indices of inertia agree. For a nondegenerate form the two indices already determine the dimension, so a regular real form is classified by its signature alone.

The file also supplies the normal form realizing a prescribed signature, the orthogonal sum of p copies of ⟨1⟩ and q copies of ⟨-1⟩, and shows that every regular real form is isometric to the normal form of its own signature.

Without any finite-dimensionality assumption, a real quadratic form is anisotropic exactly when it is positive or negative definite. This identifies the algebraic condition used in compactness criteria for real orthogonal groups with the usual order-theoretic notion of definiteness.

Main results #

References #

@[simp]
theorem QuadraticMap.map_inv_sqrt_smul_eq_one {M : Type u_1} [AddCommMonoid M] [Module ℝ M] {Q : QuadraticForm ℝ M} {v : M} (hpos : 0 < Q v) :
Q ((√(Q v))⁻¹ • v) = 1

Scaling a vector by the inverse square root of its positive quadratic value gives value one.

theorem QuadraticMap.map_inv_sqrt_abs_smul {M : Type u_1} [AddCommMonoid M] [Module ℝ M] (Q : QuadraticForm ℝ M) (v : M) :
Q ((√|Q v|)⁻¹ • v) = Q v / |Q v|

Scaling a vector by the inverse square root of the absolute value of its quadratic value gives value Q v / |Q v|, which is 1, -1 or 0 according to the sign of Q v.

theorem QuadraticMap.map_inv_sqrt_abs_smul_eq_one_or_neg_one {M : Type u_1} [AddCommMonoid M] [Module ℝ M] {Q : QuadraticForm ℝ M} {v : M} (hv : Q v ≠ 0) :
Q ((√|Q v|)⁻¹ • v) = 1 ∨ Q ((√|Q v|)⁻¹ • v) = -1

Scaling a vector of nonzero quadratic value by the inverse square root of the absolute value of that quadratic value gives value 1 or -1.

theorem QuadraticMap.exists_isOrtho_of_mul_pos {M : Type u_1} [AddCommGroup M] [Module ℝ M] {Q : QuadraticForm ℝ M} {e f : M} (hef : IsOrtho Q e f) (h : 0 < Q e * Q f) :
∃ (e' : M) (f' : M), (Q e' = 1 ∨ Q e' = -1) ∧ Q f' = Q e' ∧ IsOrtho Q e' f'

Two orthogonal vectors whose quadratic values are nonzero of the same sign rescale to two orthogonal vectors with the same quadratic value 1 or -1.

A real quadratic form is anisotropic if and only if it is positive or negative definite. No finite-dimensionality assumption is needed; on the zero space both alternatives hold.

A real quadratic form with trivial radical on a finite-dimensional space is anisotropic if and only if one of its two indices of inertia vanishes: an indefinite regular real form is isotropic.

theorem QuadraticMap.anisotropic_weightedSumSquares_iff {ι : Type u_2} [Fintype ι] (b : ι → ℝ) :
(weightedSumSquares ℝ b).Anisotropic ↔ (∀ (i : ι), 0 < b i) ∨ ∀ (i : ι), b i < 0

A real diagonal form ⟨b₁, …, bₙ⟩ is anisotropic exactly when its coefficients are all positive or all negative. No nonvanishing hypothesis is needed: a zero coefficient makes the corresponding basis vector isotropic and rules out both alternatives.

theorem QuadraticForm.sigPos_weightedSumSquares_signType {ι : Type u_1} [Fintype ι] (u : ι → SignType) :
sigPos (QuadraticMap.weightedSumSquares ℝ fun (i : ι) => ↑(u i)) = {i : ι | u i = 1}.ncard

The positive index of inertia of a sign-weighted sum of squares counts the weights 1.

theorem QuadraticForm.sigNeg_weightedSumSquares_signType {ι : Type u_1} [Fintype ι] (u : ι → SignType) :
sigNeg (QuadraticMap.weightedSumSquares ℝ fun (i : ι) => ↑(u i)) = {i : ι | u i = -1}.ncard

The negative index of inertia of a sign-weighted sum of squares counts the weights -1.

Sylvester's law of inertia, classification form: two real quadratic forms on finite-dimensional spaces are isometric exactly when their dimensions agree and both indices of inertia agree. The dimension is a genuine third condition: it records the number of zero weights in a diagonalization, which the two indices do not see.

Sylvester's law of inertia for regular forms: two nondegenerate real quadratic forms are isometric exactly when their signatures agree.

The normal form of signature (p, q): the orthogonal sum of p copies of ⟨1⟩ and q copies of ⟨-1⟩.

Instances For

    The normal form is the weighted sum of squares with p positive and q negative weights.

    @[simp]
    theorem QuadraticForm.realSignatureForm_apply (p q : ℕ) (x : Fin p ⊕ Fin q → ℝ) :
    (realSignatureForm p q) x = ∑ i : Fin p, x (Sum.inl i) ^ 2 - ∑ j : Fin q, x (Sum.inr j) ^ 2
    @[simp]

    The positive index of inertia of the normal form realSignatureForm p q is p.

    @[simp]

    The negative index of inertia of the normal form realSignatureForm p q is q.

    @[simp]

    The normal form of signature (p, q) is regular, so every signature is realized by a regular real quadratic form.

    @[simp]

    A regular real quadratic form is isometric to the normal form of signature (p, q) exactly when its positive and negative indices are p and q.

    Two normal forms are isometric exactly when their signatures coincide, so the signature is a complete and independent system of invariants for regular real quadratic forms.

    Every regular real quadratic form is isometric to the normal form of its signature.

    Sylvester's normal form with the negative squares first. A regular real quadratic form Q on an n-dimensional space is isometric to the diagonal form -x₀² - ⋯ - x_{q-1}² + x_q² + ⋯ + x_{n-1}² on Fin n → ℝ, where q = sigNeg Q. This is the coordinate order of Morse charts, in which the negative directions of a Hessian come first.

    Every signature (p, n - p) with p ≤ n is the signature of a regular quadratic form on the coordinate space ℝⁿ: the normal form realSignatureForm p (n - p) transported along a bijection of its index type with Fin n.

    A positive definite real quadratic form is isometric to the standard sum-of-squares form in its dimension.