Yang–Mills: the 2026 Lean construction, rerun and read; the mass gap still open
OpenAI's 2026 Lean construction of 4D Yang–Mills as the expert group keeps it: settle what it proves, rerun it, read it; uniqueness and the mass gap are open, and Clay's problem unsolved

| 1 | import YM.Ovens.Coffee |
| 2 | import YM.Progress.DIRECTED_RECIPE.Padding |
| 3 | |
| 4 | /-! |
| 5 | # A dictionary chosen independently of the population |
| 6 | |
| 7 | A `Pipes` for *this* torus, covering every shape. Flags are still |
| 8 | read as in the specification; extra tests may be placed *inside* |
| 9 | payloads. Raw `X : Pipes` are not required to have trivial tests. We will |
| 10 | store those X as well. There are even *designated* zero addresses (all |
| 11 | shapes) at every step, not just unused numbers depending on where in the |
| 12 | parameter range one starts to mark. Include both transported active slots and |
| 13 | designated zeros in the Moves permutations. Permutations need only be |
| 14 | supplied at each parameter value as in Valid; the dictionary itself will not |
| 15 | vary. No claim that paths never wrap or flag neighborhoods are small. |
| 16 | -/ |
| 17 | |
| 18 | set_option autoImplicit false |
| 19 | noncomputable section |
| 20 | namespace YM.Progress.DirectedRecipe |
| 21 | |
| 22 | open Function Set RG Ovens Wilson Lattice MeasureTheory |
| 23 | open scoped Topology BigOperators ContDiff Matrix.Norms.Frobenius |
| 24 | |
| 25 | section Rooms |
| 26 | variable {α : Type*} |
| 27 | /-- Two independent series of labels for each address shape. -/ |
| 28 | abbrev Slots (α : Type*) := α × (ℕ ⊕ ℕ) |
| 29 | |
| 30 | def rows (α : Type) [Countable α] [Nonempty α] : ℕ ≃ Slots α := |
| 31 | letI := Classical.choice (nonempty_denumerable (Slots α)) |
| 32 | (Denumerable.eqv _).symm |
| 33 | |
| 34 | /-- `j` records a label of the old alphabet even when its support agrees |
| 35 | with that of another label. Never drop decisions. -/ |
| 36 | def use (E : ℕ ≃ Slots α) (f : ℕ → α) : ℕ ↪ ℕ where |
| 37 | toFun j := E.symm (f j, Sum.inl j) |
| 38 | inj' _ _ h := Sum.inl_injective (congr_arg Prod.snd (E.symm.injective h)) |
| 39 | |
| 40 | lemma book (E : ℕ ≃ Slots α) (f : ℕ → α) (j : ℕ) : E (use E f j) = (f j, .inl j) := |
| 41 | Equiv.apply_symm_apply E _ |
| 42 | |
| 43 | /-- Infinitely many specific slots, left dormant. -/ |
| 44 | def spare (E : ℕ ≃ Slots α) : α × ℕ ↪ ℕ where |
| 45 | toFun j := E.symm (j.1, Sum.inr j.2) |
| 46 | inj' _ _ h := Prod.ext (congr_arg (Prod.fst : Slots α → α) (E.symm.injective h)) |
| 47 | (Sum.inr_injective (congr_arg Prod.snd (E.symm.injective h))) |
| 48 | |
| 49 | lemma recorded (E : ℕ ≃ Slots α) (x : α) (j : ℕ) : E (spare E (x,j)) = (x, .inr j) := |
| 50 | Equiv.apply_symm_apply E _ |
| 51 | |
| 52 | lemma distinct (E : ℕ ≃ Slots α) (f : ℕ → α) (x : α) (j : ℕ) : spare E (x,j) ∉ range (use E f) := by |
| 53 | rintro ⟨k,h⟩ |
| 54 | have ht := congr_arg E h |
| 55 | rw [recorded,book] at ht |
| 56 | simp at ht |
| 57 | |
| 58 | /-- Extend an old Moves permutation to the WHOLE dictionary. Active labels |
| 59 | for a shape are sent according to their original permutation. Thus whether |
| 60 | an active label was a real old address is preserved once the footprint law |
| 61 | is in force. This also acts separately on the infinite reserves. -/ |
| 62 | def rearrange (E : ℕ ≃ Slots α) (g : Equiv.Perm α) (p : Equiv.Perm ℕ) : Equiv.Perm ℕ := |
| 63 | (E.trans (Equiv.prodCongr g (Equiv.sumCongr p (Equiv.refl ℕ)))).trans E.symm |
| 64 | |
| 65 | lemma stocked (E : ℕ ≃ Slots α) (g : Equiv.Perm α) (p : Equiv.Perm ℕ) (i : ℕ) : |
| 66 | E (rearrange E g p i) = (g (E i).1, Sum.map p id (E i).2) := by |
| 67 | simp only [rearrange, Equiv.trans_apply, Equiv.apply_symm_apply, Equiv.prodCongr_apply] |
| 68 | rfl |
| 69 | |
| 70 | lemma move_stock (E : ℕ ≃ Slots α) (g : Equiv.Perm α) (p : Equiv.Perm ℕ) (f : ℕ → α) |
| 71 | (h : ∀ i, g (f i) = f (p i)) (j : ℕ) : rearrange E g p (use E f j) = use E f (p j) := by |
| 72 | apply E.injective |
| 73 | simp [stocked,book,h] |
| 74 | |
| 75 | |
| 76 | |
| 77 | lemma unused {e : ℕ ↪ ℕ} {M p : Equiv.Perm ℕ} (hm : ∀ i, M (e i) = e (p i)) {j : ℕ} |
| 78 | (h : j ∉ range e) : M j ∉ range e := by |
| 79 | rintro ⟨i,hi⟩ |
| 80 | obtain ⟨i, rfl⟩ := p.surjective i |
| 81 | rw [← hm] at hi |
| 82 | exact h ⟨i, M.injective hi⟩ |
| 83 | end Rooms |
| 84 | |
| 85 | section Shape |
| 86 | variable {G : Gauge} {n : Side} |
| 87 | |
| 88 | structure Foot (n : Side) where |
| 89 | support : Support n |
| 90 | inventory : Support n |
| 91 | ne : inventory.Nonempty |
| 92 | sub : inventory ⊆ support |
| 93 | |
| 94 | def readFoot (A : ForcedAddress G n) : Foot n := ⟨A.support,A.inventory,A.inventory_ne,A.inventory_sup⟩ |
| 95 | |
| 96 | /-- Every extra test is already enforced by nonzero K (or by nonzero |
| 97 | appointment of a new coefficient, keeping *that* appointment's certificate). |
| 98 | Index by all shapes. Can't index by all possible predicate functions. -/ |
| 99 | def bareFoot (G : Gauge) (A : Foot n) : ForcedAddress G n := |
| 100 | ⟨A.support,A.inventory,A.ne,A.sub,fun _ => True⟩ |
| 101 | |
| 102 | abbrev Zone (n : Side) := { Y : Support n // Y.Nonempty } |
| 103 | |
| 104 | lemma foot_ext {A B : Foot n} (hs : A.support = B.support) (hi : A.inventory = B.inventory) : A=B := by |
| 105 | cases A; cases B; congr |
| 106 | lemma reg_ext {A B : RegularAddress n} (hs : A.site=B.site) (hi : A.support=B.support) : A=B := by |
| 107 | cases A; cases B; congr |
| 108 | |
| 109 | lemma foot_countable (n : Side) : Countable (Foot n) := |
| 110 | Function.Injective.countable (show Function.Injective (fun x : Foot n => (x.support,x.inventory)) from |
| 111 | fun _ _ h => foot_ext (congr_arg Prod.fst h) (congr_arg Prod.snd h)) |
| 112 | lemma reg_countable (n : Side) : Countable (RegularAddress n) := |
| 113 | Function.Injective.countable (show Function.Injective (fun x : RegularAddress n => (x.site,x.support)) from |
| 114 | fun _ _ h => reg_ext (congr_arg Prod.fst h) (congr_arg Prod.snd h)) |
| 115 | |
| 116 | def regularKeys (n : Side) : ℕ ≃ Slots (RegularAddress n) := |
| 117 | @rows _ (reg_countable n) ⟨⟨0,{0},Finset.mem_singleton_self _⟩⟩ |
| 118 | |
| 119 | def hardKeys (n : Side) : ℕ ≃ Slots (Foot n) := |
| 120 | @rows _ (foot_countable n) ⟨⟨{0},{0},Finset.singleton_nonempty _, Finset.Subset.refl _⟩⟩ |
| 121 | |
| 122 | def softKeys (n : Side) : ℕ ≃ Slots (Zone n) := |
| 123 | @rows _ inferInstance ⟨⟨{0},Finset.singleton_nonempty _⟩⟩ |
| 124 | end Shape |
| 125 | |
| 126 | section Box |
| 127 | variable {G : Gauge} {n : Side} |
| 128 | |
| 129 | /-- Chosen even on all small tori. Never depends on the parameter, level, |
| 130 | history or any estimate. -/ |
| 131 | def drawer (G : Gauge) (n : Side) : Pipes G n where |
| 132 | reg i := (regularKeys n i).1 |
| 133 | kernel i := bareFoot G (hardKeys n i).1 |
| 134 | softer i := (softKeys n i).1.val |
| 135 | sites i := (softKeys n i).1.property |
| 136 | |
| 137 | namespace Rack |
| 138 | variable (X : Pipes G n) |
| 139 | |
| 140 | def upE : ℕ ↪ ℕ := use (regularKeys n) X.reg |
| 141 | |
| 142 | def upK : ℕ ↪ ℕ := use (hardKeys n) fun i => readFoot (X.kernel i) |
| 143 | |
| 144 | def upS : ℕ ↪ ℕ := use (softKeys n) fun i => (⟨X.softer i, X.sites i⟩ : Zone n) |
| 145 | |
| 146 | lemma reg_up (i : ℕ) : (drawer G n).reg (upE X i) = X.reg i := by simp [drawer, upE, book] |
| 147 | lemma hard_up (i : ℕ) : (drawer G n).kernel (upK X i) = bareFoot G (readFoot (X.kernel i)) := by |
| 148 | simp [drawer, upK, book] |
| 149 | lemma soft_up (i : ℕ) : (drawer G n).softer (upS X i) = X.softer i := by simp [drawer, upS, book] |
| 150 | |
| 151 | def widen (d : Tap G n) : Tap G n where |
| 152 | regular := stuff (upE X) d.regular |
| 153 | forced := stuff (upK X) d.forced |
| 154 | logarithm := stuff (upS X) d.logarithm |
| 155 | |
| 156 | lemma preserves (d : Tap G n) (P : BudgetPoint) : |
| 157 | Readdress P (upE X) (upK X) (X.pours d) ((drawer G n).pours (widen X d)) := by |
| 158 | refine ⟨reg_up X,fun i => ?_,fun i => ?_,fun _ => stuffed ..,fun _ => stuffed .., |
| 159 | fun _ h => blank _ _ h, fun _ h => blank _ _ h,fun i U h => ?_⟩ |
| 160 | · unfold Pipes.pours |
| 161 | simp only [hard_up,bareFoot,readFoot] |
| 162 | · unfold Pipes.pours |
| 163 | simp only [hard_up,bareFoot,readFoot] |
| 164 | dsimp only [Pipes.pours] |
| 165 | rw [hard_up] |
| 166 | exact ⟨h.1,trivial⟩ |
| 167 | end Rack |
| 168 | end Box |
| 169 | |
| 170 | section Perm |
| 171 | variable {n : Side} (e : Equiv.Perm (Site n)) |
| 172 | |
| 173 | def relocate (A : RegularAddress n) : RegularAddress n := |
| 174 | ⟨e A.site,A.support.image e, Finset.mem_image_of_mem _ A.anchor⟩ |
| 175 | |
| 176 | lemma relocate_inverse : LeftInverse (relocate e.symm) (relocate e) := fun A => by |
| 177 | refine reg_ext ?_ ?_ <;> simp [relocate, Finset.image_image] |
| 178 | |
| 179 | def regMap : Equiv.Perm (RegularAddress n) := |
| 180 | ⟨relocate e, relocate e.symm, relocate_inverse e, relocate_inverse e.symm⟩ |
| 181 | |
| 182 | def stepOn (A : Foot n) : Foot n := |
| 183 | ⟨A.support.image e,A.inventory.image e, A.ne.image _, Finset.image_mono _ A.sub⟩ |
| 184 | |
| 185 | lemma stepOn_inverse : LeftInverse (stepOn e.symm) (stepOn e) := fun A => by |
| 186 | refine foot_ext ?_ ?_ <;> simp [stepOn, Finset.image_image] |
| 187 | |
| 188 | def hardMap : Equiv.Perm (Foot n) := |
| 189 | ⟨stepOn e, stepOn e.symm, stepOn_inverse e, stepOn_inverse e.symm⟩ |
| 190 | |
| 191 | def rezone (A : Zone n) : Zone n := ⟨A.val.image e,A.property.image _⟩ |
| 192 | lemma rezone_inverse : LeftInverse (rezone e.symm) (rezone e) := fun A => Subtype.ext (by |
| 193 | simp [rezone, Finset.image_image]) |
| 194 | |
| 195 | def softMap : Equiv.Perm (Zone n) := |
| 196 | ⟨rezone e,rezone e.symm, rezone_inverse e, rezone_inverse e.symm⟩ |
| 197 | end Perm |
| 198 | |
| 199 | section Lift |
| 200 | open Rack |
| 201 | variable {G : Gauge} {n : Side} {X : Pipes G n} |
| 202 | |
| 203 | def destination (s : Signed) (b : Site n) : Equiv.Perm (Site n) := s.actEquiv.toEquiv.trans (Equiv.addRight b) |
| 204 | |
| 205 | /-- Applies *any* incoming permutation supplied by Moves. The proof uses |
| 206 | that carrier and location footprints transform. Result is a permutation for |
| 207 | the NEW population, with its own kernel eligibility at all entries. -/ |
| 208 | def on_shelves {d : Tap G n} {s : Signed} {b : Site n} (M : (X.pours d).Moves s b) : |
| 209 | ((drawer G n).pours (widen X d)).Moves s b := by |
| 210 | let z := destination s b |
| 211 | let e := rearrange (regularKeys n) (regMap z) M.ep |
| 212 | let k := rearrange (hardKeys n) (hardMap z) M.kp |
| 213 | have hr (i : ℕ) : (drawer G n).reg (e i) = regMap z ((drawer G n).reg i) := |
| 214 | congr_arg Prod.fst (stocked (regularKeys n) (regMap z) M.ep i) |
| 215 | have he (i : ℕ) := congr_arg Prod.fst (stocked (hardKeys n) (hardMap z) M.kp i) |
| 216 | have h1 (i : ℕ) : e (upE X i) = upE X (M.ep i) := move_stock _ _ _ X.reg |
| 217 | (fun i => reg_ext (M.reg_site _).symm (M.reg_support _).symm) i |
| 218 | have h2 (i : ℕ) : k (upK X i) = upK X (M.kp i) := move_stock _ _ _ (fun i => readFoot (X.kernel i)) |
| 219 | (fun i => foot_ext (M.forced_support _).symm (M.forced_inventory _).symm) i |
| 220 | refine ⟨e, k, fun i => congr_arg RegularAddress.site (hr i), fun i => congr_arg RegularAddress.support (hr i), |
| 221 | fun i => congr_arg Foot.support (he i), fun i => congr_arg Foot.inventory (he i), fun _ _ => Iff.rfl, ?_, ?_⟩ |
| 222 | · intro i U |
| 223 | change stuff (upE X) d.regular (e i) U = stuff (upE X) d.regular i _ |
| 224 | by_cases H : i ∈ range (upE X) |
| 225 | · obtain ⟨i,rfl⟩ := H |
| 226 | rw [h1,stuffed,stuffed]; exact M.valuesE .. |
| 227 | rw [blank _ _ (unused h1 H), blank _ _ H]; rfl |
| 228 | intro i U |
| 229 | change stuff (upK X) d.forced (k i) U = stuff (upK X) d.forced i _ |
| 230 | by_cases H : i ∈ range (upK X) |
| 231 | · obtain ⟨i,rfl⟩ := H |
| 232 | rw [h2,stuffed,stuffed]; exact M.valuesK .. |
| 233 | rw [blank _ _ (unused h2 H), blank _ _ H]; rfl |
| 234 | |
| 235 | lemma carries_log {d : Tap G n} (s : Signed) (b : Site n) (p : Equiv.Perm ℕ) |
| 236 | (h : ∀ i, X.softer (p i) = (X.softer i).image (affine s b)) |
| 237 | (hd : ∀ U i, d.logarithm (p i) U = d.logarithm i (pull s b U)) : |
| 238 | let q := rearrange (softKeys n) (softMap (destination s b)) p |
| 239 | (∀ i,(drawer G n).softer (q i) = ((drawer G n).softer i).image (affine s b)) ∧ |
| 240 | ∀ U i, (widen X d).logarithm (q i) U = (widen X d).logarithm i (pull s b U) := by |
| 241 | intro q |
| 242 | have he (i : ℕ) : q (upS X i) = upS X (p i) := move_stock _ _ _ (fun i => ⟨X.softer i, X.sites i⟩) |
| 243 | (fun j => Subtype.ext (h j).symm) i |
| 244 | refine ⟨fun i => congr_arg Subtype.val (congr_arg Prod.fst (stocked (softKeys n) (softMap (destination s b)) p i)),?_⟩ |
| 245 | intro U i |
| 246 | dsimp only [widen] |
| 247 | by_cases H : i ∈ range (upS X) |
| 248 | · obtain ⟨j,rfl⟩ := H |
| 249 | rw [he,stuffed,stuffed,hd] |
| 250 | rw [blank _ _ (unused he H), blank _ _ H]; rfl |
| 251 | end Lift |
| 252 | end YM.Progress.DirectedRecipe |