Residual of the elimination (round six, `geSolve_resid`)
ProvedJ6Seg.geSolve_residResidual of the elimination. If A/2^P is within η of the identity in row sums on L,
η + |L|²/2^P ≤ 1/2, and the computed solution is bounded by Z on L, then every residual
(A z - b)_i / 2^P (i ∈ L) is at most (Z+1)(|L|+1)²/2^P.
The following holds (Lean statement, in the scope of module Solutions.J6SegFix):
theorem J6Seg.geSolve_resid : ∀ (L : List ℕ) (A : ℕ → ℕ → ℤ) (b : ℕ → ℤ) (η Z : ℝ),
L.Nodup → 0 ≤ η → η + (L.length : ℝ) ^ 2 / 2 ^ P ≤ 1 / 2 →
(∀ i ∈ L, ∑ k ∈ L.toFinset, |(A i k : ℝ) / 2 ^ P - kd i k| ≤ η) →
(∀ k ∈ L, |(geSolve P L A b k : ℝ) / 2 ^ P| ≤ Z) →
∀ i ∈ L, |∑ k ∈ L.toFinset, (A i k : ℝ) / 2 ^ P * ((geSolve P L A b k : ℝ) / 2 ^ P) -
(b i : ℝ) / 2 ^ P| ≤ (Z + 1) * ((L.length : ℝ) + 1) ^ 2 / 2 ^ P
Context. Segmented inverse (S2): fixed-point primitives and elimination without pivoting
Fixed-point numbers of precision P are integers a standing for a / 2^P.
rq a b = ⌊a/b + 1/2⌋(rounded quotient),rs P a = rq a (2^P),fmul P x y = rs P (x*y)andfdiv P x y = rq (x 2^P) y(errors≤ 1/2ulp).geSolve P L A b: Gaussian elimination without pivoting in the order of the index listL, written as forward elimination of the head pivot followed by back substitution.schur_row(report L9): if every row ofA - Ihas absolute sum≤ η ≤ 1/2, the same holds for the Schur complement after eliminating one pivot; hence for every Schur complement, and no pivoting is ever needed (any order, any sparsity pattern, cyclic borders included).near_id:‖A - I‖_∞ ≤ η < 1and‖A z - r‖ ≤ ρgive‖z‖ ≤ (‖r‖ + ρ)/(1 - η).geSolve_resid: the computed solution has residual≤ (Z+1)(|L|+1)²/2^P;geSolve_bound: and|z| ≤ 4B + 1.
Formalization Note. Part of the Lean formalization of the round-six κ-improvement (integer-multiplication-kappa campaign, target IntMul.Kappa.jain_round6_framework). The statement is copied verbatim from the Lean development; the platform node carries the same declaration name. Definitions it mentions live in the IntMul_Kappa_R6_Defs* bundles (on top of the published κ bundles IntMul_Kappa_K_Defs*).
-- Round-six κ development (integer-multiplication-kappa), generated by skeleton subtraction. import Definitions.Def_IntMul_Kappa_R6_Defs3 set_option autoImplicit false set_option relaxedAutoImplicit false set_option maxHeartbeats 1000000 open J6Seg open Finset variable (P : ℕ)
theorem J6Seg.geSolve_resid : ∀ (L : List ℕ) (A : ℕ → ℕ → ℤ) (b : ℕ → ℤ) (η Z : ℝ),
L.Nodup → 0 ≤ η → η + (L.length : ℝ) ^ 2 / 2 ^ P ≤ 1 / 2 →
(∀ i ∈ L, ∑ k ∈ L.toFinset, |(A i k : ℝ) / 2 ^ P - kd i k| ≤ η) →
(∀ k ∈ L, |(geSolve P L A b k : ℝ) / 2 ^ P| ≤ Z) →
∀ i ∈ L, |∑ k ∈ L.toFinset, (A i k : ℝ) / 2 ^ P * ((geSolve P L A b k : ℝ) / 2 ^ P) -
(b i : ℝ) / 2 ^ P| ≤ (Z + 1) * ((L.length : ℝ) + 1) ^ 2 / 2 ^ P := by sorry