While this submission is a draft, it cannot be used by other submissions.

One amplification round on a fixed affine host

Lax956329.OneRound · concepts/Lax956329/OneRound.lean · lax-956329

proven

Loading review…

Sign in with ORCID

Community review

Flags

Each flag is tied to a public ORCID identity and explains why this concept may be incorrect.

No flags have been submitted.

    Community review

    Flag this concept

    State precisely what appears incorrect. This explanation will be public under your ORCID name.

    No source line selected.

    Natural Language Statement

    Lemma

    The input and output both contain the four forward affine generators, their inverses and two identity ports. The algorithm prepends one fixed radix, preserves perfect completeness, and doubles the gap up to a fixed cutoff. All constants are independent of the input modulus.

    Concept map
    11 concepts; 5 descendants hidden
    100%
    Proven claimDefinitionThis conceptRelated conceptA → B: B builds on A
    Evidence

    Each proof establishes this claim relative to its assumptions.

    Lean source view on GitHub

    1import Lax956329.Amplification
    2import Mathlib.Algebra.Group.Fin.Basic
    3import Mathlib.Logic.Equiv.Fin.Basic
    4
    5/-!
    6---
    7title: One amplification round on a fixed affine host
    8type: lemma
    9---
    10The input and output both contain the four forward affine generators, their
    11inverses and two identity ports. The algorithm prepends one fixed radix,
    12preserves perfect completeness, and doubles the gap up to a fixed cutoff.
    13All constants are independent of the input modulus.
    14-/
    15
    16namespace Lax956329.OneRound
    17
    18open Hierarchy Amplification Instances Lax434930.PolynomialTime
    19
    20/-- A modular shear with a constant translation in the first coordinate. -/
    21def shear (m : ℕ) [NeZero m] (k c : ℕ) : Equiv.Perm (Owner m) where
    22 toFun z := (z.1+Fin.ofNat m (k*z.2.val+c),z.2)
    23 invFun z := (z.1-Fin.ofNat m (k*z.2.val+c),z.2)
    24 left_inv z := Prod.ext (add_sub_cancel_right ..) rfl
    25 right_inv z := Prod.ext (sub_add_cancel ..) rfl
    26
    27def vertical (m : ℕ) [NeZero m] (k c : ℕ) : Equiv.Perm (Owner m) :=
    28 ((Equiv.prodComm _ _).trans (shear m k c)).trans (Equiv.prodComm _ _)
    29
    30def forward (i : Fin 10) : Port := finSumFinEquiv (Sum.inl i : Fin 10 ⊕ Fin 10)
    31
    32def backward (i : Fin 10) : Port := finSumFinEquiv (Sum.inr i : Fin 10 ⊕ Fin 10)
    33
    34def Affine {b : ℕ} (S : System b) : Prop :=
    35 letI : NeZero S.m := ⟨S.positive.ne'⟩
    36 (∀ i, S.reverse (forward i) = backward i) ∧
    37 S.move (forward 2) = shear S.m 2 0 ∧ S.move (forward 3) = shear S.m 2 1 ∧
    38 S.move (forward 4) = vertical S.m 2 0 ∧ S.move (forward 5) = vertical S.m 2 1 ∧
    39 S.move (forward 9) = Equiv.refl _
    40
    41/-- A single uniform local construction, with its modulus and new first digit specified. -/
    42axiom construct : ∃ b t s : ℕ, 4 ≤ b ∧ 0 < t ∧ 0 < s ∧ ∃ f : Word → Word, Poly f ∧
    43 ∀ S : System b, Affine S → ∃ T : System b,
    44 f S.bits = T.bits ∧ Affine T ∧ T.m = s*S.m ∧ T.radices = s :: S.radices ∧
    45 (S.satisfied → T.satisfied) ∧
    46 ∀ g : ℝ, 0 ≤ g → LowerBound S g → LowerBound T (2 * min g (1 / (t : ℝ)))
    47
    48end Lax956329.OneRound
    49
    Show Proof

    Discussion

    Ask a question or add context. Endorsements and structured flags are kept in the review panel above.

    Loading discussion…