Round-six lemma `p3U_runs`
ProvedNLogN.KFUU.p3U_runscomplexity-theoryinteger-multiplicationkappa-improvement
An auxiliary lemma of the round-six development, published as a separate node because its proof is long or shared.
The following holds (Lean statement, in the scope of module Solutions.KFUURev12):
theorem NLogN.KFUU.p3U_runs {pM : Fin P} (hM : MulOK I iprog pM MS) {pS : Fin HS} (hpS : LS pS)
(u cz : ℕ) (bs : List Bool) (hcz : 1 ≤ cz) (w : ℕ) (xs0 : List ℤ) (hx : Bnd w xs0) (Z : ℕ)
(hVZ : zsz ((vol (shP u bs) * cz : ℕ) : ℤ) ≤ Z) (hZ2 : 2 ≤ Z)
(zU : zsz ((2 ^ u : ℕ) : ℤ) ≤ Z) (t : IState HS) (R : List Item)
(h0 : t.G 0 = ints (Dl (mzB u bs.length cz) (bgB bs) (List.range bs.length ++ [bs.length])
(lay3 (bgB bs) bs.length 0) xs0 0) ++ R) {RS LZ LU LN : List Item}
(hpS0 : t.G pS = ints (zl (shP u bs)) ++ RS)
(hZ : t.G rCZ = .int (cz : ℤ) :: LZ) (hU : t.G rU2 = .int ((2 ^ u : ℕ) : ℤ) :: LU)
(hN : t.G nR = .int (bs.length : ℤ) :: LN) :
IRuns I iprog (p3U pM pS) t
(t.upd 0 (ints (Dl (mzB u bs.length cz) (bgB bs) (List.range bs.length ++ [bs.length])
(lay3 (bgB bs) bs.length bs.length) xs0 0) ++ R))
((bs.length + 1) * (KFU.cMv (vol (shP u bs) * cz) w + 70 * cU Z))
Context. KFUU §2l: phase 3 in IL (the loop)
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*).
Preamble
-- Round-six κ development (integer-multiplication-kappa), generated by skeleton subtraction.
import Definitions.Def_IntMul_Kappa_K_Defs33
import Definitions.Def_IntMul_Kappa_R6_Defs1
import Mathlib
import Definitions.Def_IntMul_HvdH_M_Defs8
import Definitions.Def_IntMul_MultitapeModel
import Definitions.Def_IntMul_HvdH_Numeric
import Definitions.Def_IntMul_HvdH_ExpApprox
import Definitions.Def_IntMul_HvdH_Twiddle
import Definitions.Def_IntMul_HvdH_RealExp
import Definitions.Def_IntMul_HvdH_MachineRef
set_option autoImplicit false
set_option relaxedAutoImplicit false
set_option maxHeartbeats 1000000
open NLogN NLogN.KFUU
open IntMul NLogN.KIL NLogN.KFB NLogN.KFC NLogN.KFT NLogN.KFU AModel AModelL12
variable {P : ℕ} {I : List Sym} {iprog : Fin P → IStmt HS P}
Formal statement
theorem NLogN.KFUU.p3U_runs {pM : Fin P} (hM : MulOK I iprog pM MS) {pS : Fin HS} (hpS : LS pS)
(u cz : ℕ) (bs : List Bool) (hcz : 1 ≤ cz) (w : ℕ) (xs0 : List ℤ) (hx : Bnd w xs0) (Z : ℕ)
(hVZ : zsz ((vol (shP u bs) * cz : ℕ) : ℤ) ≤ Z) (hZ2 : 2 ≤ Z)
(zU : zsz ((2 ^ u : ℕ) : ℤ) ≤ Z) (t : IState HS) (R : List Item)
(h0 : t.G 0 = ints (Dl (mzB u bs.length cz) (bgB bs) (List.range bs.length ++ [bs.length])
(lay3 (bgB bs) bs.length 0) xs0 0) ++ R) {RS LZ LU LN : List Item}
(hpS0 : t.G pS = ints (zl (shP u bs)) ++ RS)
(hZ : t.G rCZ = .int (cz : ℤ) :: LZ) (hU : t.G rU2 = .int ((2 ^ u : ℕ) : ℤ) :: LU)
(hN : t.G nR = .int (bs.length : ℤ) :: LN) :
IRuns I iprog (p3U pM pS) t
(t.upd 0 (ints (Dl (mzB u bs.length cz) (bgB bs) (List.range bs.length ++ [bs.length])
(lay3 (bgB bs) bs.length bs.length) xs0 0) ++ R))
((bs.length + 1) * (KFU.cMv (vol (shP u bs) * cz) w + 70 * cU Z)) := by sorrySource
S. Jain, round-six networks for the integer-multiplication κ-improvement campaign (https://github.com/Swapnil-jain/integer-mult-kappa, commit 5868dc7) and D. Colkitt, integer-mult-bounds (https://github.com/CrocSwap/integer-mult-bounds); target `IntMul.Kappa.jain_round6_framework`. Lean declaration `NLogN.KFUU.p3U_runs`, Solutions/KFUURev12.lean (lines 124–209) of the round-six development.