§6.9, Theorem 1 — Normal equations characterize least squares
ProvedVectorSpaceOpt.normal_equations_iff_best_approximationLet and be real Hilbert spaces, a continuous linear map, a target, and a candidate. Then globally minimizes the residual norm if and only if it satisfies the normal equation:
No closed-range assumption is needed for this equivalence. It converts an optimization property quantified over all candidates into an operator equation and provides the reusable interface between best approximation and the normal operators appearing in the pseudoinverse identities.
import Mathlib open scoped InnerProduct
namespace VectorSpaceOpt
theorem normal_equations_iff_best_approximation
{G H : Type*} [NormedAddCommGroup G] [InnerProductSpace ℝ G] [CompleteSpace G]
[NormedAddCommGroup H] [InnerProductSpace ℝ H] [CompleteSpace H]
(A : G →L[ℝ] H) (y : H) (x : G) :
(∀ z : G, ‖y - A x‖ ≤ ‖y - A z‖) ↔ ((A†) ∘L A) x = (A†) y := by sorry
end VectorSpaceOptRead-back
What the Lean code literally says, in plain math · gpt-5
Let and be complete real inner-product spaces, let be any continuous real-linear map, and fix arbitrary and . The assertion that globally minimizes the residual norm, namely for every , is equivalent to the exact equation . No closed-range, existence, uniqueness, finite-dimensionality, or nontriviality assumption is made; this is an equivalence for the particular arbitrary point .
Confirmed by the mission captain (proposal self-audit).