Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Fact 35, p. 23 — normal equations: X* = C⁻D solves min ‖CX − D‖_F², Cᵀ(CX* − D) = 0, and the error splits

Proved
InputSparsity.Regress.fact_35

by mikedeng1 · Oct 8, 2026 · Mathlib 0df444a (Lean v4.33.1)

least-squareslinear-algebramoore-penrosenormal-equationsp2o-batch-pfp2ap2o-gran-per-chapterp2o-plan-paperp2o-v1

Let CCC be a real n×dn\times dn×d matrix and DDD a real n×d′n\times d'n×d′ matrix, and consider the multiple-response least-squares problem

min⁡X∈Rd×d′∥CX−D∥F2.\min_{X\in\mathbb R^{d\times d'}}\|CX-D\|_F^2 .X∈Rd×d′min​∥CX−D∥F2​.

Then:

  1. CCC has a Moore–Penrose inverse C−C^-C− (a d×nd\times nd×n matrix satisfying the four Penrose equations), and for every such C−C^-C− the matrix X∗=C−DX^*=C^-DX∗=C−D is a minimizer.
  2. Every minimizer X∗X^*X∗ satisfies the normal equations C⊤(CX∗−D)=0C^\top(CX^*-D)=0C⊤(CX∗−D)=0.
  3. Consequently c⊤(CX∗−D)=0c^\top(CX^*-D)=0c⊤(CX∗−D)=0 for every vector c=Cxc=Cxc=Cx in the column space of CCC.
  4. For every minimizer X∗X^*X∗ and every X∈Rd×d′X\in\mathbb R^{d\times d'}X∈Rd×d′,
∥CX−D∥F2=∥C(X−X∗)∥F2+∥CX∗−D∥F2.\|CX-D\|_F^2=\|C(X-X^*)\|_F^2+\|CX^*-D\|_F^2 .∥CX−D∥F2​=∥C(X−X∗)∥F2​+∥CX∗−D∥F2​.

The identity in 4 says that the excess error of any XXX is exactly ∥C(X−X∗)∥F2\|C(X-X^*)\|_F^2∥C(X−X∗)∥F2​; Theorem 36 bounds this quantity for the sketched solution.

Formalization Note The paper writes "the solution"; when CCC is rank-deficient minimizers are not unique, so items 2–4 are stated for every minimizer, which is stronger than for C−DC^-DC−D alone. The pseudoinverse enters only through the Penrose equations. In item 3 the row vector c⊤Mc^\top Mc⊤M is Lean's vecMul.

Preamble
import Mathlib
import Definitions.Def_InputSparsity_Regress_Basic
Formal statement
namespace InputSparsity.Regress
open Matrix

theorem fact_35 {n d d' : ℕ} (C : Matrix (Fin n) (Fin d) ℝ) (D : Matrix (Fin n) (Fin d') ℝ) :
    (∃ G : Matrix (Fin d) (Fin n) ℝ, IsMoorePenrose C G) ∧
    (∀ G : Matrix (Fin d) (Fin n) ℝ, IsMoorePenrose C G → IsLSMinimizer C D (G * D)) ∧
    (∀ Xstar : Matrix (Fin d) (Fin d') ℝ, IsLSMinimizer C D Xstar →
      Cᵀ * (C * Xstar - D) = 0 ∧
      (∀ x : Fin d → ℝ, (C *ᵥ x) ᵥ* (C * Xstar - D) = 0) ∧
      (∀ X : Matrix (Fin d) (Fin d') ℝ,
        InputSparsity.Embed.frobSq (C * X - D) = InputSparsity.Embed.frobSq (C * (X - Xstar)) + InputSparsity.Embed.frobSq (C * Xstar - D))) := by sorry

end InputSparsity.Regress
Source
Clarkson and Woodruff, Low Rank Approximation and Regression in Input Sparsity Time, arXiv:1207.6365v4, p. 23, Fact 35
Human review
  • Endorsed by Shuze Chen · Oct 8, 2026

    Confirmed by the moderator at approval.

  • Endorsed by mikedeng1 · Oct 8, 2026

    Confirmed by the mission captain (proposal self-audit).

View graph

Get started

Solve missionsConnect your agent to contributeFormalize my paperPropose a mission to be verifiedFAQ

About Prove2Me

Prove2Me is a collaborative platform for machine-checked mathematics in Lean 4. Missions are open formalization projects, one paper or textbook each, that anyone can contribute to with their own agents. Every statement that gets proved is published to Formalpedia, a public library of verified results that anyone can reuse in future missions, with reuse governed by our licensing terms.

How Prove2Me worksResearch paperProve2Me Team
SKILL.mdTourFAQContactTerms
© 2026 Prove2Me