All proofs
Project-declaredLean 4.31.0 · mathlib@fabf563a7c95

T sdh game eq

KZG.CommitmentScheme.t_sdh_game_eq

Plain-language statement

Transition 4: the mapped extended binding game is the t-SDH experiment.

Exact Lean statement

lemma t_sdh_game_eq {n : ℕ} {AuxState : Type} [SampleableType G₁]
    (adversary : KzgBindingAdversary p G₁ G₂ n unifSpec AuxState) :
    Pr[Groups.tSdhCondition (p := p) (g₁ := g₁) |
      mapBindingToTsdh (p := p) (n := n) <$> bindingGameExt (g₁ := g₁) (g₂ := g₂)
        AuxState adversary
        (kzg (n := n) (g₁ := g₁) (g₂ := g₂) (pairing := pairing))]
    = Groups.tSdhExperiment (g₁ := g₁) (g₂ := g₂) n
      (bindingReduction (g₁ := g₁) (g₂ := g₂) (pairing := pairing) AuxState
        adversary)

Formal artifact

Lean source

Canonical source
Full Lean sourceLean 4
lemma t_sdh_game_eq {n : } {AuxState : Type} [SampleableType G₁]    (adversary : KzgBindingAdversary p G₁ G₂ n unifSpec AuxState) :    Pr[Groups.tSdhCondition (p := p) (g₁ := g₁) |      mapBindingToTsdh (p := p) (n := n) <$> bindingGameExt (g₁ := g₁) (g₂ := g₂)        AuxState adversary        (kzg (n := n) (g₁ := g₁) (g₂ := g₂) (pairing := pairing))]    = Groups.tSdhExperiment (g₁ := g₁) (g₂ := g₂) n      (bindingReduction (g₁ := g₁) (g₂ := g₂) (pairing := pairing) AuxState        adversary) := by  let scheme := kzg (n := n) (g₁ := g₁) (g₂ := g₂) (pairing := pairing)  simp only [Groups.tSdhExperiment, Groups.tSdhGame]  congr 1  let pSpec' : ProtocolSpec 1 := !v[.P_to_V], !v[G₁]  let impl : QueryImpl _ (StateT unifSpec.QueryCache ProbComp) :=    QueryImpl.addLift      (randomOracle : QueryImpl unifSpec (StateT unifSpec.QueryCache ProbComp))      (challengeQueryImpl (pSpec := pSpec'))  dsimp only [bindingGameExt, bindingReduction, kzg, OptionT.mk, pSpec', impl, scheme,    OptionT.run_map]  convert OptionT.map_mk_bind_eq_of_body      (sample := (Groups.sampleNonzeroZMod (p := p) : ProbComp (ZMod p)))      (body₁ := fun τ => (simulateQ impl (do        let srs := Groups.PowerSrs.generate (g₁ := g₁) (g₂ := g₂) n τ        let cm, query, resp₁, resp₂, st₁, st₂  liftComp (adversary.claim srs) _        let reduction := Reduction.mk (adversary.prover srs) (scheme.opening (srs, srs)).verifier        let result₁  (reduction.run          (cm, (query, resp₁ :            (q : OracleInterface.Query (Fin (n + 1)  ZMod p)) × OracleInterface.Response q))          st₁).run        let result₂  (reduction.run          (cm, (query, resp₂ :            (q : OracleInterface.Query (Fin (n + 1)  ZMod p)) × OracleInterface.Response q))          st₂).run        let accept₁ := result₁.map (fun result => result.2) |>.getD false        let accept₂ := result₂.map (fun result => result.2) |>.getD false        let proof₁ : G₁ := result₁.map (fun result => result.1.1 0) |>.getD (1 : G₁)        let proof₂ : G₁ := result₂.map (fun result => result.1.1 0) |>.getD (1 : G₁)        pure (some (τ, srs, cm, query, resp₁, resp₂, accept₁, accept₂, proof₁,          proof₂)))).run' (∅ : unifSpec.QueryCache))      (body₂ := fun τ => (simulateQ impl (do        let srs := Groups.PowerSrs.generate (g₁ := g₁) (g₂ := g₂) n τ        let cm, query, resp₁, resp₂, st₁, st₂  liftComp (adversary.claim srs) _        let reduction := Reduction.mk (adversary.prover srs) (scheme.opening (srs, srs)).verifier        let result₁  (reduction.run          (cm, (query, resp₁ :            (q : OracleInterface.Query (Fin (n + 1)  ZMod p)) × OracleInterface.Response q))          st₁).run        let result₂  (reduction.run          (cm, (query, resp₂ :            (q : OracleInterface.Query (Fin (n + 1)  ZMod p)) × OracleInterface.Response q))          st₂).run        let accept₁ := result₁.map (fun result => result.2) |>.getD false        let accept₂ := result₂.map (fun result => result.2) |>.getD false        let proof₁ : G₁ := result₁.map (fun result => result.1.1 0) |>.getD (1 : G₁)        let proof₂ : G₁ := result₂.map (fun result => result.1.1 0) |>.getD (1 : G₁)        pure (some (mapBindingInstanceToTsdh (p := p) (n := n)          (srs, cm, query, resp₁, resp₂, accept₁, accept₂, proof₁, proof₂))))).run'            (∅ : unifSpec.QueryCache))      (f := mapBindingToTsdh (p := p) (n := n))      (post := fun τ ((c, h) : ZMod p × G₁) => (τ, c, h))      (hBody := by        intro τ        dsimp only        refine StateT.map_run'_eq_of_map_eq (∅ : unifSpec.QueryCache) ?_        simp only [simulateQ_bind, simulateQ_pure, map_eq_bind_pure_comp, bind_assoc]        congr 1) using 1 <;> rfl
Project
ArkLib
License
Apache-2.0
Commit
fad5cbf80877
Source
ArkLib/Commitments/Functional/KZG/Binding.lean:661-726

Reuse this declaration

Bring the exact result into your workflow

The import identifies the source module. Your project still needs the pinned package dependency shown on this page.

What this badge means

This completion status comes from the project or community source. It has not yet been represented here as an independent rebuild and axiom audit.

Continue in this project

Related declarations

Project-declaredLean 4.31.0

Affine gaps lifted to interleaved codes

affine_gaps_lifted_to_interleaved_codes

Project documentation

This lemma proves the final algebraic step in the DG25 Theorem 3.1 proof. It shows that if R > e + 1, then e * (R / (R - 1)) < e + 1. The intuition is that the fraction R / (R - 1) is always greater than 1, but as R gets larger, it gets closer to 1. The hypothesis R > e + 1 provides a strong enough bound to ensure the product e * (fraction) do...

cryptographyproof systemscoding theory

Source project: ArkLib

Person-level attribution pending.

View proof record
Project-declaredLean 4.31.0

Gadget Decompose coeff

ArkLib.Lattices.Ajtai.gadgetDecompose_coeff

Plain-language statement

The k-th coefficient (k < deg φ) of a gadget-decomposition block is exactly the corresponding digit of the corresponding input coefficient.

cryptographyproof systemscoding theory

Source project: ArkLib

Person-level attribution pending.

View proof record
Project-declaredLean 4.31.0

Gadget Decompose lawful

ArkLib.Lattices.Ajtai.gadgetDecompose_lawful

Plain-language statement

The base-b gadget decomposition is a lawful gadget decomposition.

cryptographyproof systemscoding theory

Source project: ArkLib

Person-level attribution pending.

View proof record