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.Price.Intent |
| 2 | import Mathlib.Analysis.SpecialFunctions.Pow.Asymptotics |
| 3 | |
| 4 | /-! |
| 5 | # Uniform entrances for each individual stage |
| 6 | |
| 7 | Use physical units shrink with total σ, not assuming σ₀ > 0. Since protection |
| 8 | exists independent of depth and floorL asks precede anything here, each volume |
| 9 | bill x ↦ `(log(x))^C` is fixed at stage. This allows a single period threshold |
| 10 | along arbitrary depth, not separate by µ. |
| 11 | -/ |
| 12 | set_option autoImplicit false |
| 13 | noncomputable section |
| 14 | namespace YM.RG.Supply |
| 15 | open Wilson Lattice Set Filter Function Asymptotics Finset Real |
| 16 | open scoped Matrix.Norms.Frobenius Topology BigOperators ContDiff |
| 17 | variable {G : Gauge} |
| 18 | |
| 19 | lemma Bar.exists_above {p : Sheet G} {w : Rolls p} {T : Protection w} (W : Delays T) (b : ℝ) : |
| 20 | ∃ P : Bar W, b ≤ P.value := by |
| 21 | have he : ∀ᶠ x : ℝ in atTop, (Real.sqrt x)⁻¹*Real.exp (Real.log (Real.log x)^2) ≤ 1 := by |
| 22 | have hx := (Real.isLittleO_pow_log_id_atTop (n:=2)).def (c:=(1/2:ℝ)) (by norm_num) |
| 23 | filter_upwards [Real.tendsto_log_atTop.eventually hx,eventually_gt_atTop 1] with x hh hp |
| 24 | have hg := Real.log_pos hp |
| 25 | simp only [id_eq,norm_of_nonneg hg.le, norm_of_nonneg (sq_nonneg _)] at hh |
| 26 | have ht : Real.exp (Real.log (Real.log x)^2) ≤ Real.sqrt x := calc |
| 27 | _ ≤ Real.exp ((1/2)*Real.log x) := Real.exp_monotone hh |
| 28 | _ = _ := by rw [show (1/2:ℝ)*Real.log x=Real.log (Real.sqrt x) by rw [Real.log_sqrt (by linarith)]; ring, Real.exp_log (Real.sqrt_pos.2 (by linarith))] |
| 29 | calc |
| 30 | _ ≤ _ := mul_le_mul_of_nonneg_left ht (inv_nonneg.mpr (Real.sqrt_nonneg x)) |
| 31 | _ = _ := inv_mul_cancel₀ (Real.sqrt_pos.2 (by linarith)).ne' |
| 32 | obtain ⟨P,hP⟩ := eventually_atTop.1 he |
| 33 | let a := max (max 2 P) (max b (W.betaEntry p.first)) |
| 34 | have ha : P≤a := le_trans (le_max_right ..) (le_max_left ..) |
| 35 | refine ⟨⟨a,lt_of_lt_of_le (?_ : (1:ℝ)<2) (le_trans (le_max_left ..) (le_max_left ..)), |
| 36 | le_trans (le_max_right ..) (le_max_right ..), fun x H => hP x (ha.trans H)⟩, le_trans (le_max_left ..) (le_max_right ..)⟩ |
| 37 | norm_num |
| 38 | |
| 39 | variable {p : Sheet G} {w : Rolls p} {T : Protection w} {W : Delays T} (Y : Bar W) |
| 40 | |
| 41 | /-- Bill in **output** sites, issued against `m+1→m`. Covers builtin sizeT |
| 42 | and patch too, on top of volume requested. -/ |
| 43 | def Bar.bill (j : ℕ) (s : ℝ) : ℕ := |
| 44 | let y m := Y.value+G.slopeConstant*m |
| 45 | let c := Nat.ceil (Real.log (y s)^2) |
| 46 | let c' := Nat.ceil (Real.log (y (s+Real.log (w.L j).val))^2) |
| 47 | W.shells j * (1+c+c')^(W.growth j) + 100*(c+1) + 100*((j+3)*(w.L j).val+1) |
| 48 | |
| 49 | private lemma isBigO_const_id_atTop (a : ℝ) : (fun _ : ℝ => a) =O[atTop] id := (isLittleO_const_id_atTop _).isBigO |
| 50 | |
| 51 | private lemma ceil_lo (a b r : ℝ) (hb : 0 < b) : |
| 52 | (fun s : ℝ => (Nat.ceil (Real.log (a+b*(s+r))^2) : ℝ)) =O[atTop] id := by |
| 53 | have hh : Tendsto (fun s : ℝ => a+b*(s+r)) atTop atTop := by |
| 54 | apply tendsto_atTop_add_const_left _ a; refine Tendsto.const_mul_atTop hb (tendsto_atTop_add_const_right _ r tendsto_id) |
| 55 | have h1 : (fun s : ℝ => a+b*(s+r)) =O[atTop] id := by |
| 56 | refine (isBigO_const_id_atTop _).add ?_; exact ((isBigO_refl id _).add (isBigO_const_id_atTop _)).const_mul_left _ |
| 57 | have he : (fun s : ℝ => Real.log (a+b*(s+r))^2) =O[atTop] id := |
| 58 | ((Real.isLittleO_pow_log_id_atTop (n:=2)).isBigO.comp_tendsto hh).trans h1 |
| 59 | refine IsBigO.trans ?_ (he.add (isBigO_const_id_atTop (1:ℝ))) |
| 60 | apply isBigO_of_le; intro x |
| 61 | change ‖(Nat.ceil _ : ℝ)‖ ≤ ‖_ + (1 : ℝ)‖; rw [norm_of_nonneg (by positivity), norm_of_nonneg (by positivity)] |
| 62 | exact le_of_lt (Nat.ceil_lt_add_one (sq_nonneg _)) |
| 63 | |
| 64 | theorem Bar.allocated (h : G.Simple) (j : ℕ) : |
| 65 | ∀ᶠ s : ℝ in atTop, (Y.bill j s : ℝ) ≤ Real.exp s := by |
| 66 | have hg := Gauge.slopeConstant_pos h |
| 67 | let c := fun s : ℝ => (Nat.ceil (Real.log (Y.value+G.slopeConstant*s)^2):ℝ) |
| 68 | let c' := fun s : ℝ => (Nat.ceil (Real.log (Y.value+G.slopeConstant*(s+Real.log (w.L j).val))^2):ℝ) |
| 69 | have H : c =O[atTop] id := by simpa only [add_zero,c] using ceil_lo Y.value _ 0 hg |
| 70 | have H' : c' =O[atTop] id := ceil_lo _ _ _ hg |
| 71 | have K := (((isBigO_const_id_atTop (1:ℝ)).add H).add H').pow (W.growth j) |
| 72 | have he (u : ℕ) : (fun x : ℝ => x^u) =o[atTop] Real.exp := by simpa using isLittleO_pow_exp_pos_mul_atTop u (zero_lt_one' ℝ) |
| 73 | have ha : id (α := ℝ) =o[atTop] Real.exp := by simpa only [pow_one] using! he 1 |
| 74 | let q : ℝ := W.shells j |
| 75 | let e : ℝ := 100*(((j:ℝ)+3)*(w.L j).val+1) |
| 76 | have hc := (((K.trans_isLittleO (he _)).const_mul_left q).add (((H.add (isBigO_const_id_atTop (1:ℝ))).trans_isLittleO ha).const_mul_left (100:ℝ))).add |
| 77 | ((isBigO_const_id_atTop e).trans_isLittleO ha) |
| 78 | have hh : (fun s : ℝ => (Y.bill j s:ℝ))=o[atTop] Real.exp := by |
| 79 | refine hc.congr_left fun x => ?_ |
| 80 | unfold Bar.bill |
| 81 | push_cast |
| 82 | rfl |
| 83 | filter_upwards [hh.def (c:=1) zero_lt_one] with s hs |
| 84 | simpa only [norm_of_nonneg (Nat.cast_nonneg _), norm_of_nonneg (Real.exp_pos s).le, one_mul] using hs |
| 85 | |
| 86 | /-- Advance stage after waiting *in the coarser* until the prior step's |
| 87 | scale is large. For periods this ensures volume bill ≤ one physical unit. |
| 88 | First plateau exception can be paid directly for all (finitely many) steps. |
| 89 | -/ |
| 90 | theorem Bar.enters (h : G.Simple) {j : ℕ} (hj : p.first < j) : ∃ n : ℕ, |
| 91 | ∀ m : ℕ, n ≤ m → ∀ s : ℝ, (m:ℝ)*Real.log 3 ≤ s → |
| 92 | W.betaEntry j ≤ Y.value+G.slopeConstant*s ∧ W.scaleEntry j Y.value ≤ s ∧ |
| 93 | 0 < s ∧ Real.log (w.L j).val ≤ (j:ℝ)⁻¹*s ∧ (Y.bill j s : ℝ) ≤ Real.exp s := by |
| 94 | let F : Set ℝ := {s | W.betaEntry j ≤ Y.value+G.slopeConstant*s ∧ W.scaleEntry j Y.value ≤ s ∧ |
| 95 | 0 < s ∧ Real.log (w.L j).val ≤ (j:ℝ)⁻¹*s ∧ (Y.bill j s : ℝ) ≤ Real.exp s} |
| 96 | have he : F ∈ (atTop : Filter ℝ) := by |
| 97 | have hb : Tendsto (fun s : ℝ => Y.value+G.slopeConstant*s) atTop atTop := |
| 98 | tendsto_atTop_add_const_left _ _ ((tendsto_id (x:=atTop)).const_mul_atTop (Gauge.slopeConstant_pos h)) |
| 99 | have hh := (tendsto_id (x:=atTop)).const_mul_atTop (inv_pos.mpr (show 0 < (j:ℝ) from by exact_mod_cast Nat.pos_of_ne_zero (by omega))) |
| 100 | exact (hb.eventually_ge_atTop _).and ((eventually_ge_atTop _).and ((eventually_gt_atTop _).and |
| 101 | ((hh.eventually_ge_atTop _).and (Y.allocated h j)))) |
| 102 | obtain ⟨s,hs⟩ := eventually_atTop.1 (show ∀ᶠ x : ℝ in atTop, x∈F from he) |
| 103 | have hb : Tendsto (fun m : ℕ => (m:ℝ)*Real.log 3) atTop atTop := |
| 104 | tendsto_natCast_atTop_atTop.atTop_mul_const (Real.log_pos (by norm_num : (1:ℝ) < 3)) |
| 105 | obtain ⟨n,hn⟩ := eventually_atTop.1 (hb.eventually_ge_atTop s) |
| 106 | exact ⟨n,fun i hi a ha => hs _ ((hn i hi).trans ha)⟩ |
| 107 | |
| 108 | /-- bench slot for comparisons. Allocate using worst upper scale of plateau. -/ |
| 109 | theorem Wait.lead {Y : Bar W} (B : Wait Y) (j : ℕ) : ∃ m : ℕ, |
| 110 | ∀ k : ℕ, m ≤ k → ∀ s : ℝ, k*Real.log 3 ≤ s → s ≤ k*Real.log (w.L j).val → |
| 111 | B.readyHere j ≤ s ∧ B.window j s ≤ k/2 := by |
| 112 | have ha := (w.large j).size |
| 113 | have hn : 0<Real.log (w.L j).val := Real.log_pos (by exact_mod_cast (show 1 < (w.L j).val by omega)) |
| 114 | have he := (B.sublin j).eventually (ge_mem_nhds (show 0 < (2*Real.log (w.L j).val)⁻¹ by positivity)) |
| 115 | obtain ⟨s,hs⟩ := eventually_atTop.1 (he.and ((eventually_ge_atTop (B.readyHere j)).and (eventually_gt_atTop (0:ℝ)))) |
| 116 | have hb : Tendsto (fun m : ℕ => (m:ℝ)*Real.log 3) atTop atTop := |
| 117 | tendsto_natCast_atTop_atTop.atTop_mul_const (Real.log_pos (by norm_num : (1:ℝ) < 3)) |
| 118 | obtain ⟨n,hu⟩ := eventually_atTop.1 (hb.eventually_ge_atTop s) |
| 119 | refine ⟨n,fun i hi a hl hh => ?_⟩ |
| 120 | have hA := hs _ ((hu i hi).trans hl) |
| 121 | obtain ⟨hf,hf',HG⟩ := hA |
| 122 | refine ⟨hf',?_⟩ |
| 123 | have hg : (B.window j a:ℝ)/a ≤ (2*Real.log (w.L j).val)⁻¹ := hf |
| 124 | have hu := ((div_le_iff₀ HG).mp hg).trans (mul_le_mul_of_nonneg_left hh (by positivity)) |
| 125 | rw [show _⁻¹ *( (i:ℝ)* Real.log (w.L j).val)=(i:ℝ)/2 by field_simp] at hu |
| 126 | rw [Nat.le_div_iff_mul_le (by norm_num)] |
| 127 | exact_mod_cast (le_div_iff₀ (zero_lt_two' ℝ)).1 hu |
| 128 | end YM.RG.Supply |