Skip to content

Commit 55d21b5

Browse files
ArkLib Agentclaude
andcommitted
feat(Verified-zkEVM#141): integrate verified refutation as MCAGSPrizeRefutation.lean
Proper tree module (namespace ProximityGap.MCAGSPrizeRefutation) proving the uniform prize conjecture FALSE. Verified axiom-clean [propext, Classical.choice, Quot.sound], 0 sorry. Removes the root scratch keep file. See Verified-zkEVM#141 for the full mathematical finding. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
1 parent ff85de0 commit 55d21b5

1 file changed

Lines changed: 183 additions & 0 deletions

File tree

Lines changed: 183 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,183 @@
1+
/-
2+
Copyright (c) 2026 ArkLib Contributors. All rights reserved.
3+
Released under Apache 2.0 license as described in the file LICENSE.
4+
Authors: ArkLib Contributors
5+
-/
6+
import ArkLib.Data.CodingTheory.ProximityGap.MCAGS
7+
8+
/-!
9+
# ABF26 Grand Challenge 1 (uniform GS form) is FALSE as formalized — statement-level refutation
10+
11+
`MCAGS.uniformEpsMCAgsPrizeBoundConjecture` bounds `epsMCAgs` by `poly(2^m,1/ρ)/q` for EVERY list
12+
family `L`. That `∀ L` is too strong: a non-faithful `L` carrying the line witness but omitting the
13+
row witness makes the GS-row event fire for every `γ`. Witness: stack `(w₀,0)` (`w₀` a nonzero RS
14+
codeword), `L={w₀}` — fires for all `γ`, so `epsMCAgs=1`, while the prize RHS `→0` over `ZMod p`,
15+
`p>2^{c₂+c₃}`. The genuine prize needs `L` FAITHFUL (the dropped clause).
16+
`#print axioms not_uniformEpsMCAgsPrizeBoundConjecture = [propext, Classical.choice, Quot.sound]`.
17+
See #141.
18+
-/
19+
noncomputable section
20+
open scoped NNReal ENNReal
21+
open ProximityGap ProximityGap.MCAGS
22+
23+
namespace ProximityGap.MCAGSPrizeRefutation
24+
25+
variable {ι : Type} [Fintype ι] [Nonempty ι] [DecidableEq ι]
26+
variable {F : Type} [Field F] [Fintype F] [DecidableEq F]
27+
28+
/-- The adversarial stack: row 0 = `w₀`, row 1 = `0`. -/
29+
def badStack (w₀ : ι → F) : Matrix (Fin 2) ι F := ![w₀, 0]
30+
31+
@[simp] theorem badStack_zero (w₀ : ι → F) : (badStack w₀) 0 = w₀ := rfl
32+
@[simp] theorem badStack_one (w₀ : ι → F) : (badStack w₀) 1 = (0 : ι → F) := rfl
33+
34+
/-- **Key lemma.** For any nonzero codeword `w₀ ∈ C` and any `δ ≤ 1`, the GS-row bad event fires
35+
at the bad stack for EVERY challenge `γ`. -/
36+
theorem mcaEventGSrow_badStack
37+
(C : Set (ι → F)) (δ : ℝ≥0) (hδ : δ ≤ 1)
38+
(w₀ : ι → F) (hw₀C : w₀ ∈ C) (hw₀ne : w₀ ≠ 0) (γ : F) :
39+
mcaEventGSrow ({w₀} : Finset (ι → F)) C δ ((badStack w₀) 0) ((badStack w₀) 1) γ := by
40+
classical
41+
refine ⟨Finset.univ, ?_, ⟨w₀, hw₀C, Finset.mem_singleton_self _, ?_⟩, ?_⟩
42+
· -- |univ| = card ι ≥ (1 - δ) * card ι since (1 - δ) ≤ 1
43+
rw [Finset.card_univ]
44+
calc (1 - δ) * (Fintype.card ι : ℝ≥0)
45+
1 * (Fintype.card ι : ℝ≥0) := by
46+
gcongr; exact tsub_le_self
47+
_ = (Fintype.card ι : ℝ≥0) := one_mul _
48+
· -- w₀ matches the line `w₀ + γ•0 = w₀` on univ
49+
intro i _
50+
simp [badStack]
51+
· -- no codeword in {w₀} equals row 1 = 0 on univ, since w₀ ≠ 0
52+
rintro ⟨c, _hcC, hcL, hc0⟩
53+
rw [Finset.mem_singleton] at hcL
54+
subst hcL
55+
apply hw₀ne
56+
funext i
57+
have := hc0 i (Finset.mem_univ i)
58+
simpa [badStack] using this
59+
60+
open ProbabilityTheory
61+
62+
/-- **The bad event has probability 1.** Since `mcaEventGSrow_badStack` holds for every `γ`, the
63+
event is almost-surely true, so its probability under uniform `γ` is `1`. -/
64+
theorem Pr_badStack_eq_one
65+
(C : Set (ι → F)) (δ : ℝ≥0) (hδ : δ ≤ 1)
66+
(w₀ : ι → F) (hw₀C : w₀ ∈ C) (hw₀ne : w₀ ≠ 0) :
67+
Pr_{let γ ← $ᵖ F}[mcaEventGSrow ({w₀} : Finset (ι → F)) C δ
68+
((badStack w₀) 0) ((badStack w₀) 1) γ] = 1 := by
69+
classical
70+
rw [ProbabilityTheory.Pr_eq_tsum_indicator]
71+
have hfun : (fun γ : F => ($ᵖ F) γ *
72+
(if mcaEventGSrow ({w₀} : Finset (ι → F)) C δ ((badStack w₀) 0) ((badStack w₀) 1) γ
73+
then (1 : ENNReal) else 0))
74+
= fun γ : F => ($ᵖ F) γ := by
75+
funext γ
76+
rw [if_pos (mcaEventGSrow_badStack C δ hδ w₀ hw₀C hw₀ne γ), mul_one]
77+
rw [hfun, PMF.tsum_coe]
78+
79+
/-- **`epsMCAgs = 1` for the adversarial list family.** This is the refutation kernel: a
80+
non-faithful `L = fun _ => {w₀}` drives the GS-exposed MCA error to its ceiling, independent of the
81+
field size — so no `poly/q` bound can hold for all `L`. -/
82+
theorem epsMCAgs_badList_eq_one
83+
(C : Set (ι → F)) (δ : ℝ≥0) (hδ : δ ≤ 1)
84+
(w₀ : ι → F) (hw₀C : w₀ ∈ C) (hw₀ne : w₀ ≠ 0) :
85+
epsMCAgs (F := F) C δ (fun _ => ({w₀} : Finset (ι → F))) = 1 := by
86+
classical
87+
refine le_antisymm (by unfold epsMCAgs; exact iSup_le fun u => Pr_le_one _ _) ?_
88+
rw [← Pr_badStack_eq_one C δ hδ w₀ hw₀C hw₀ne]
89+
exact le_iSup (fun u => Pr_{let γ ← $ᵖ F}[mcaEventGSrow ((fun _ => ({w₀} : Finset (ι → F))) u)
90+
C δ (u 0) (u 1) γ]) (badStack w₀)
91+
92+
open scoped NNReal
93+
open Polynomial
94+
95+
/-- **MAIN THEOREM (#141): the formalized uniform prize conjecture is FALSE.**
96+
97+
`uniformEpsMCAgsPrizeBoundConjecture` quantifies over ALL list families `L`. We refute it: choose a
98+
prime field `ZMod p` with `p > 2^{c₂+c₃}`, the rate `ρ = prizeRates 0 = 1/2` over `ι = Fin 2` (RS
99+
dimension `⌊1/2·2⌋ = 1`), the nonzero codeword `w₀ = const 1`, and the adversarial family
100+
`L = fun _ => {w₀}`. Then `epsMCAgs = 1` (the GS-row event fires for every `γ`), while the prize
101+
RHS `= 2^{c₂+c₃}/p < 1` — contradiction. The genuine prize requires `L` FAITHFUL. -/
102+
theorem not_uniformEpsMCAgsPrizeBoundConjecture :
103+
¬ uniformEpsMCAgsPrizeBoundConjecture := by
104+
classical
105+
rintro ⟨c₁, c₂, c₃, h⟩
106+
-- A prime `p` with `(p : ℝ) > 2^(c₂+c₃)` and `p ≥ 3`.
107+
obtain ⟨p, hp_ge, hp_prime⟩ :=
108+
Nat.exists_infinite_primes (max (⌈(2 : ℝ) ^ (c₂ + c₃)⌉₊ + 1) 3)
109+
haveI : Fact p.Prime := ⟨hp_prime⟩
110+
have hp3 : 3 ≤ p := le_trans (le_max_right _ _) hp_ge
111+
-- `2^(c₂+c₃) < (p : ℝ)`.
112+
have hpow_lt : (2 : ℝ) ^ (c₂ + c₃) < (p : ℝ) := by
113+
have h1 : (2 : ℝ) ^ (c₂ + c₃) ≤ (⌈(2 : ℝ) ^ (c₂ + c₃)⌉₊ : ℝ) := Nat.le_ceil _
114+
have h2 : (⌈(2 : ℝ) ^ (c₂ + c₃)⌉₊ : ℝ) < (⌈(2 : ℝ) ^ (c₂ + c₃)⌉₊ + 1 : ℝ) := by linarith
115+
have h3 : ((⌈(2 : ℝ) ^ (c₂ + c₃)⌉₊ + 1 : ℕ) : ℝ) ≤ (p : ℝ) := by
116+
exact_mod_cast le_trans (le_max_left _ _) hp_ge
117+
push_cast at h3
118+
linarith
119+
-- Data: `ι = Fin 2`, `F = ZMod p`, domain `![0,1]`, codeword `w₀ = const 1`.
120+
have h01 : (0 : ZMod p) ≠ (1 : ZMod p) := zero_ne_one
121+
let domain : Fin 2 ↪ ZMod p :=
122+
⟨![0, 1], by
123+
intro a b hab
124+
fin_cases a <;> fin_cases b <;> simp_all⟩
125+
set w₀ : Fin 2 → ZMod p := fun _ => (1 : ZMod p) with hw₀def
126+
have hcard : Fintype.card (Fin 2) = 2 := by simp
127+
-- `⌊prizeRates 0 · card⌋ = 1`.
128+
have hdeg1 : ⌊(prizeRates 0 : ℝ≥0) * (Fintype.card (Fin 2) : ℝ≥0)⌋₊ = 1 := by
129+
rw [hcard]
130+
have : (prizeRates 0 : ℝ≥0) = 1 / 2 := by simp [prizeRates]
131+
rw [this]; norm_num
132+
-- `w₀ = const 1` is a nonzero codeword of `code domain 1`.
133+
have hw₀mem : w₀ ∈ (ReedSolomon.code (domain := domain)
134+
⌊(prizeRates 0 : ℝ≥0) * (Fintype.card (Fin 2) : ℝ≥0)⌋₊ : Set (Fin 2 → ZMod p)) := by
135+
rw [hdeg1]
136+
refine ReedSolomon.mem_code_of_polynomial_of_natDegree_lt_of_eval (Polynomial.C 1) ?_ ?_
137+
· simp
138+
· intro i; simp [hw₀def]
139+
have hw₀ne : w₀ ≠ 0 := by
140+
intro hcon
141+
have : (1 : ZMod p) = 0 := by have := congrFun hcon 0; simpa [hw₀def] using this
142+
exact h01 this.symm
143+
-- Apply the conjecture at `j = 0, m = 0, η = 1/2, δ = 0, L = fun _ => {w₀}`.
144+
have hη : (0 : ℝ≥0) < 1 / 2 := by norm_num
145+
have hδ : ((0 : ℝ≥0) : ℝ) ≤ 1 - (ProximityGap.prizeRates 0 : ℝ) - ((1 / 2 : ℝ≥0) : ℝ) := by
146+
have : (ProximityGap.prizeRates 0 : ℝ) = 1 / 2 := by
147+
have : (prizeRates 0 : ℝ≥0) = 1 / 2 := by simp [prizeRates]
148+
rw [this]; norm_num
149+
rw [this]; norm_num
150+
have key := h (ι := Fin 2) (F := ZMod p) domain 0 0 (1 / 2) 0
151+
(fun _ => ({w₀} : Finset (Fin 2 → ZMod p))) hδ
152+
-- LHS = 1.
153+
rw [epsMCAgs_badList_eq_one _ 0 (by norm_num) w₀ hw₀mem hw₀ne] at key
154+
-- RHS < 1.
155+
have hRHS : epsMCAgsPrizeBound (Fintype.card (ZMod p)) 0 (ProximityGap.prizeRates 0)
156+
(1 / 2) c₁ c₂ c₃ < 1 := by
157+
have hcardF : Fintype.card (ZMod p) = p := ZMod.card p
158+
have hρ : ((ProximityGap.prizeRates 0 : ℝ≥0) : ℝ) = 1 / 2 := by
159+
have : (prizeRates 0 : ℝ≥0) = 1 / 2 := by simp [prizeRates]
160+
rw [this]; norm_num
161+
have hηcast : ((1 / 2 : ℝ≥0) : ℝ) = 1 / 2 := by norm_num
162+
unfold epsMCAgsPrizeBound
163+
rw [hcardF, hρ, hηcast]
164+
-- `(1/p) * ((2:ℝ)^0)^c₁ / ((1/2)^c₂ * (1/2)^c₃) = 2^(c₂+c₃)/p`
165+
have e1 : ((2 : ℝ) ^ (0 : ℕ)) ^ c₁ = 1 := by
166+
norm_num [Real.one_rpow]
167+
have e2 : (1 / 2 : ℝ) ^ c₂ * (1 / 2 : ℝ) ^ c₃ = (1 / 2 : ℝ) ^ (c₂ + c₃) :=
168+
(Real.rpow_add (by norm_num) c₂ c₃).symm
169+
have e3 : (1 / 2 : ℝ) ^ (c₂ + c₃) = ((2 : ℝ) ^ (c₂ + c₃))⁻¹ := by
170+
rw [one_div, Real.inv_rpow (by norm_num)]
171+
have hp_pos : (0 : ℝ) < p := by positivity
172+
have hpow_pos : (0 : ℝ) < (2 : ℝ) ^ (c₂ + c₃) := Real.rpow_pos_of_pos (by norm_num) _
173+
rw [e1, e2, mul_one, e3, div_eq_mul_inv, inv_inv, one_div, inv_mul_eq_div,
174+
div_lt_one hp_pos]
175+
exact hpow_lt
176+
-- `key : 1 ≤ ofReal(RHS)` but `ofReal(RHS) < 1` (since `RHS < 1`): contradiction.
177+
have hlt1 : ENNReal.ofReal
178+
(epsMCAgsPrizeBound (Fintype.card (ZMod p)) 0 (ProximityGap.prizeRates 0) (1 / 2) c₁ c₂ c₃) < 1 :=
179+
ENNReal.ofReal_lt_one.mpr hRHS
180+
exact absurd key (not_le.mpr hlt1)
181+
182+
end ProximityGap.MCAGSPrizeRefutation
183+

0 commit comments

Comments
 (0)