Documentation

CslibFrontier.Crypto.Protocols.FRI.BatchJohnsonSoundness.Helpers

Internal Algebraic, Floor, and Ceiling Helpers for Batched FRI Soundness #

Internal helper lemmas shared across the smooth and binary batched FRI soundness submodules (imported privately by sibling submodules under BatchJohnsonSoundness and not re-exported by CslibFrontier.Crypto.Protocols.FRI.BatchJohnsonSoundness).

theorem Cslib.Crypto.Protocols.FRI.add_sum_natCast_div_ennreal {ι : Type u_1} (B₀ : ℕ) (s : Finset ι) (x : ι → ℕ) (D : ℕ) :
↑B₀ / ↑D + ∑ i ∈ s, ↑(x i) / ↑D = ↑(B₀ + ∑ i ∈ s, x i) / ↑D

Combine an ℝ≥0∞ ratio with a finite sum of ratios over a common denominator.

Nonnegativity of 1 - 1 / 2 ^ m.

Nonnegativity of 2 - 1 / 2 ^ m.

theorem Cslib.Crypto.Protocols.FRI.friSmoothBatchCommitGame_eq_zero_of_two_pow_le {F : Type} [Field F] [Fintype F] (params : FRISmoothParams F) (t B : ℕ) (hB : 2 ^ params.d ≤ B) (stmt : FRIBatchStmt F params.d t) (P : BCS.InteractiveIOPProver params.d F (FRIBatchChal F params.d params.q t)) :
(friSmoothBatchCommitGame params t B stmt P) true = 0

When 2 ^ d ≤ B, strict threshold acceptance B < card in friSmoothBatchCommitGame has probability zero.

theorem Cslib.Crypto.Protocols.FRI.friSmoothBatchCommitGame_le_of_floor {F : Type} [Field F] [Fintype F] (params : FRISmoothParams F) (t : ℕ) {α α₀ : ℝ} {ε_C : ENNReal} (hα₀_nn : 0 ≤ α₀) (hα_le_α₀ : α ≤ α₀) {stmt : FRIBatchStmt F params.d t} (hagree_le : ∀ (D' : Finset (Fin (2 ^ params.d))), ∀ v₀ ∈ params.initialCode, ∀ (v : Fin t → BCS.OracleTable params.d F), (∀ (j : Fin t), v j ∈ params.initialCode) → (∀ s ∈ D', stmt.base s = v₀ s ∧ ∀ (j : Fin t), stmt.terms j s = v j s) → ↑D'.card / 2 ^ params.d ≤ α) (P : BCS.InteractiveIOPProver params.d F (FRIBatchChal F params.d params.q t)) (hprox : ∀ (e₀ : ℕ), stmt ∉ params.batchProximityLang t e₀ → ↑e₀ / 2 ^ params.d < 1 - α₀ → (friSmoothBatchCommitGame params t (2 ^ params.d - e₀ - 1) stmt P) true ≤ ε_C) :
(friSmoothBatchCommitGame params t ⌊α₀ * 2 ^ params.d⌋₊ stmt P) true ≤ ε_C

Real-to-integer floor threshold bridge for friSmoothBatchCommitGame.

theorem Cslib.Crypto.Protocols.FRI.query_pow_le_ofReal_pow {d e q : ℕ} {α : ℝ} (hq_lt : ↑(2 ^ d - e - 1) / 2 ^ d < α) :
(↑(2 ^ d - e - 1) / 2 ^ d) ^ q ≤ ENNReal.ofReal (α ^ q)

Cast and bound the query-round survival power ((2 ^ d - e - 1) / 2 ^ d) ^ q by ENNReal.ofReal (α ^ q).

theorem Cslib.Crypto.Protocols.FRI.friSmoothBatchIOP_interactiveGame_le_of_corrAgree_le {F : Type} [Field F] [Fintype F] [DecidableEq F] (params : FRISmoothParams F) (t : ℕ) {α ε_C : ℝ} (hε_nn : 0 ≤ ε_C) (hα_pos : 0 < α) {stmt : FRIBatchStmt F params.d t} (hfar : stmt ∉ params.batchCorrAgreeLang t α) (P : BCS.InteractiveIOPProver params.d F (FRIBatchChal F params.d params.q t)) (hprox : ∀ (e : ℕ), stmt ∉ params.batchProximityLang t e → ↑e / 2 ^ params.d ≤ 1 - α → (BCS.iopInteractiveGame (friSmoothBatchIOP params t) stmt P) true ≤ ENNReal.ofReal ε_C + (↑(2 ^ params.d - e - 1) / 2 ^ params.d) ^ params.q) :
(BCS.iopInteractiveGame (friSmoothBatchIOP params t) stmt P) true ≤ ENNReal.ofReal (ε_C + α ^ params.q)

Real-density batchCorrAgreeLang to integer batchProximityLang bridge for friSmoothBatchIOP.

theorem Cslib.Crypto.Protocols.FRI.friSmoothBatchRBRError_ceil_le {F : Type} [Field F] [Fintype F] (params : FRISmoothParams F) (ε_batch : ENNReal) {α : ℝ} (hα_pos : 0 < α) (hα_le : α ≤ 1) (B_commit : ℕ) :
friSmoothBatchRBRError params ε_batch (2 ^ params.d - ⌈α * 2 ^ params.d⌉₊) B_commit ≤ max ε_batch (max (↑B_commit / ↑(Fintype.card F)) (ENNReal.ofReal (α ^ params.q)))

Upper-bound friSmoothBatchRBRError at the ceiling proximity threshold 2 ^ d - ⌈α * 2 ^ d⌉₊.

theorem Cslib.Crypto.Protocols.FRI.smooth_johnson_slack_of_le {F : Type} [Field F] (params : FRISmoothParams F) {mJ : ℕ} (hmJ : 1 ≤ mJ) {α x : ℝ} (hα : √(↑(params.dim 0) / 2 ^ params.d) * (1 + 1 / (2 * ↑mJ)) ≤ α) (hx : x ≤ 1 - α) :
0 < α ∧ x ≤ 1 - √(↑(params.dim 0) / 2 ^ params.d) - √(↑(params.dim 0) / 2 ^ params.d) / (2 * ↑mJ)

Arithmetic slack helper converting √ρ * (1 + 1 / (2 * mJ)) ≤ α and x ≤ 1 - α into the Johnson bound condition.