Mathlib.Analysis.InnerProductSpace.PosDef
PosDef — Mathlib-shaped helpers: Sqrt.
Sqrt 6 core · 9 supporting This file constructs the positive square root of a positive operator on a finite-dimensional real inner-product space by diagonalizing the operator in an orthonormal eigenbasis. ★ posSqrt_mul_self★ posSqrtCLM_comp_self
Positive square roots of finite-dimensional positive operators
This file constructs the positive square root of a positive operator on a
finite-dimensional real inner-product space by diagonalizing the operator in an
orthonormal eigenbasis. The main linear-map construction is posSqrt, with
posSqrt_mul_self, posSqrt_isSymmetric, and posSqrt_isPositive proving that it
is the positive square root. The file also packages the same map as a continuous
linear map posSqrtCLM, proves it is self-adjoint, and proves the corresponding
continuous square law posSqrtCLM_comp_self.
An orthonormal eigenbasis of T, obtained from the symmetry of a positive operator.
Definition (Lean source)
The real eigenvalues of T, indexed compatibly with eigBasis.
The positive square root of T: the linear operator that acts as √(eigenvalue) on each vector of the chosen orthonormal eigenbasis.
Definition (Lean source)
Composing the positive square root of T with itself recovers T.
Formal statement
Proof (Lean source)
posSqrt packaged as a continuous linear map (finite-dimensional domain).
Definition (Lean source)
Composing the continuous positive square root of T with itself recovers T, packaged as a continuous linear map.
Formal statement
Proof (Lean source)
9 supporting declarations (lemmas, instances)
-
apply_eigBasistheorem — Applying the operator to an eigenbasis vector scales that vector by its indexed eigenvalue.hypothesesconclusionT (hT.eigBasis i) = (hT.eigVals i) • hT.eigBasis i -
eigVals_nonnegtheorem — Eigenvalues of a positive operator are nonnegative.hypothesesconclusion0 ≤ hT.eigVals iProof (Lean source)
theorem eigVals_nonneg (i : Fin (finrank ℝ E)) : 0 ≤ hT.eigVals i := by have hb : ⟪hT.eigBasis i, hT.eigBasis i⟫ = 1 := by have := (hT.eigBasis).orthonormal.1 i rw [real_inner_self_eq_norm_sq, this]; norm_num have hpos := hT.2 (hT.eigBasis i) rw [hT.apply_eigBasis i, inner_smul_left] at hpos -- `hpos : 0 ≤ ⟪T (b i), b i⟫` becomes `0 ≤ μ i` simpa only [conj_trivial, hb, mul_one, RCLike.re_to_real] using hpos -
posSqrt_apply_eigBasistheorem — The positive square root sends each eigenbasis vector to the same vector scaled by the square root of its eigenvalue.hypothesesconclusionhT.posSqrt (hT.eigBasis i) = sqrt (hT.eigVals i) • hT.eigBasis iProof (Lean source)
theorem posSqrt_apply_eigBasis (i : Fin (finrank ℝ E)) : hT.posSqrt (hT.eigBasis i) = sqrt (hT.eigVals i) • hT.eigBasis i := by rw [posSqrt, ← OrthonormalBasis.coe_toBasis, Basis.constr_basis] -
posSqrt_innertheorem — Inner-product form of posSqrt: a symmetric weighted sum over the eigenbasis.hypothesesE :sharedType u_1E →ₗ[ℝ] EhT :sharedT.IsPositivex y :Econclusion⟪hT.posSqrt x, y⟫= ∑ i, sqrt (hT.eigVals i) * ⟪hT.eigBasis i, x⟫ * ⟪hT.eigBasis i, y⟫Proof (Lean source)
theorem posSqrt_inner (x y : E) : ⟪hT.posSqrt x, y⟫ = ∑ i, sqrt (hT.eigVals i) * ⟪hT.eigBasis i, x⟫ * ⟪hT.eigBasis i, y⟫ := by have hx : hT.posSqrt x = ∑ i, (⟪hT.eigBasis i, x⟫ * sqrt (hT.eigVals i)) • hT.eigBasis i := by conv_lhs => rw [← (hT.eigBasis).sum_repr x] rw [map_sum] refine Finset.sum_congr rfl fun i _ => ?_ rw [map_smul, hT.posSqrt_apply_eigBasis i, smul_smul, OrthonormalBasis.repr_apply_apply] rw [hx, sum_inner] refine Finset.sum_congr rfl fun i _ => ?_ rw [inner_smul_left, conj_trivial] ring -
posSqrt_isSymmetrictheorem — posSqrt is symmetric.hypothesesE :sharedType u_1E →ₗ[ℝ] EhT :sharedT.IsPositiveconclusionhT.posSqrt.IsSymmetricProof (Lean source)
theorem posSqrt_isSymmetric : hT.posSqrt.IsSymmetric := fun x y => by rw [hT.posSqrt_inner x y, show ⟪x, hT.posSqrt y⟫ = ⟪hT.posSqrt y, x⟫ from real_inner_comm _ _, hT.posSqrt_inner y x] exact Finset.sum_congr rfl fun i _ => by ring -
posSqrt_isPositivetheorem — posSqrt is itself a positive operator.hypothesesE :sharedType u_1E →ₗ[ℝ] EhT :sharedT.IsPositiveconclusionhT.posSqrt.IsPositiveProof (Lean source)
theorem posSqrt_isPositive : hT.posSqrt.IsPositive := by refine (LinearMap.isPositive_iff _).mpr ⟨hT.posSqrt_isSymmetric, fun x => ?_⟩ rw [hT.posSqrt_inner x x] refine Finset.sum_nonneg fun i _ => ?_ nlinarith [Real.sqrt_nonneg (hT.eigVals i), mul_self_nonneg ⟪hT.eigBasis i, x⟫] -
posSqrtCLM_applytheorem — The continuous-linear-map packaging of the positive square root has the same pointwise action as the linear-map square root.hypothesesE :sharedType u_1E →ₗ[ℝ] EhT :sharedT.IsPositivex :EconclusionhT.posSqrtCLM x = hT.posSqrt xProof (Lean source)
@[simp] theorem posSqrtCLM_apply (x : E) : hT.posSqrtCLM x = hT.posSqrt x := rfl -
posSqrtCLM_isSelfAdjointtheorem — The continuous square root is self-adjoint.hypothesesE :sharedType u_1E →ₗ[ℝ] EhT :sharedT.IsPositiveconclusionIsSelfAdjoint hT.posSqrtCLMProof (Lean source)
theorem posSqrtCLM_isSelfAdjoint : IsSelfAdjoint hT.posSqrtCLM := (LinearMap.isSelfAdjoint_toContinuousLinearMap_iff _).mpr ((LinearMap.isSymmetric_iff_isSelfAdjoint _).mp hT.posSqrt_isSymmetric) -
posSqrtCLM_adjointtheorem — Adjoint form of self-adjointness.hypothesesE :sharedType u_1E →ₗ[ℝ] EhT :sharedT.IsPositiveconclusionadjoint hT.posSqrtCLM = hT.posSqrtCLMProof (Lean source)
theorem posSqrtCLM_adjoint : adjoint hT.posSqrtCLM = hT.posSqrtCLM := by rw [← ContinuousLinearMap.star_eq_adjoint]; exact hT.posSqrtCLM_isSelfAdjoint