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.Push.LOOP_COEFFICIENT.Ghost |
| 2 | import YM.Push.LOOP_COEFFICIENT.LogDet |
| 3 | |
| 4 | /-! |
| 5 | # Vector matrices of the prescription and their real regularity |
| 6 | |
| 7 | Cell estimates are separate (nothing uniform asserted here). Fine and joint |
| 8 | entities all depend on the *actual* `mainTerm` etc of these same W,p. |
| 9 | -/ |
| 10 | set_option autoImplicit false |
| 11 | noncomputable section |
| 12 | namespace YM.Push.Loops |
| 13 | open Matrix Function Filter Lattice RG Exterior Wilson Precision Set |
| 14 | open scoped Topology Matrix.Norms.Frobenius ContDiff BigOperators |
| 15 | variable {c f n : Side} {G : Gauge} {S : StepData c f} {p : Clip} {W : PathData G} {σ C Λ : ℝ} |
| 16 | |
| 17 | /-- Transfer a site operator diagonally onto link directions at INITIAL sites. -/ |
| 18 | def parallel {R : Type} [Zero R] (M : Matrix (SiteKey G n) (SiteKey G n) R) : Matrix (BondKey G n) (BondKey G n) R := |
| 19 | of fun i j => if i.1.2=j.1.2 then M (i.1.1,i.2) (j.1.1,j.2) else 0 |
| 20 | |
| 21 | def reference (μ : ℝ) (p : Clip) (W : PathData G) (U : Config G n) := |
| 22 | cost (mainTerm p W) U + R_g U * regulation μ U ^2 * (R_g U).transpose + μ^2 • (parallel (dressing μ U)^depth) |
| 23 | |
| 24 | /-- Full logarithmic vector operator . Rooted notation for all group maps. -/ |
| 25 | def vector (p : Clip) (W : PathData G) (t : S.Choices) (V : Config G c) (U : Loops.Inputs G c f) := |
| 26 | cost (completed p W t V) U + (completion t U).transpose * completion t U |
| 27 | |
| 28 | /-- Base version `N_b`, which lacks the map drift only. -/ |
| 29 | def baseVector (p : Clip) (W : PathData G) (t : S.Choices) (V : Config G c) (U : Loops.Inputs G c f) := |
| 30 | cost (mainTerm p W ∘ positions) U + |
| 31 | (rate (Zmap t) U).transpose * cost (penalty S V) (Zmap t U) * rate (Zmap t) U + |
| 32 | (completion t U).transpose * completion t U |
| 33 | |
| 34 | /-- Exact scalar functions. -/ |
| 35 | def scalar (p : Clip) (W : PathData G) (t : S.Choices) (V : Config G c) (U : Loops.Inputs G c f) := |
| 36 | (1/2 : ℝ) * Real.log (vector p W t V U).det - Real.log (ghost (mu S) (positions U)).det |
| 37 | |
| 38 | def scalarRef (μ : ℝ) (p : Clip) (W : PathData G) (U : Config G n) := |
| 39 | (1/2 : ℝ) * Real.log (reference μ p W U).det - Real.log (ghost μ U).det |
| 40 | |
| 41 | def Yresp (p : Clip) (W : PathData G) (t : S.Choices) (V : Config G c) (U : Loops.Inputs G c f) (v : Loops.Links G c) := |
| 42 | ((baseVector p W t V U)⁻¹ * acceleration (Zmap t) U v).trace |
| 43 | |
| 44 | lemma vector_eq (hw : W.Bounds p σ C Λ) (t : S.Choices) (V : Config G c) (U : Loops.Inputs G c f) |
| 45 | (hu : MatDiffAt (Zmap t ∘ vary U) 0) : vector p W t V U = baseVector p W t V U + |
| 46 | acceleration (Zmap t) U (first (penalty S V) (Zmap t U)) := by |
| 47 | have hp : ContDiffAt ℝ ω (penalty S V ∘ vary (Zmap t U)) 0 := penalty_diff S (matDiffAt_const _) vary_diff |
| 48 | rw [vector, show completed p W t V = (mainTerm p W ∘ positions) + penalty S V ∘ Zmap t from rfl, |
| 49 | cost_add (Work.F02.mainTerm_contDiffAt hw (A:=positions ∘ vary U) (x:=0) (fun _ => vary_diff _)) |
| 50 | (hu.along (by simp) hp), cost_comp hu hp, baseVector]; abel |
| 51 | |
| 52 | lemma vector_flat (h : S.patch.Branches S.kernel G) (hw : W.Bounds p σ C Λ) (t : S.Choices) : |
| 53 | vector p W t 1 (1:Loops.Inputs G c f) = baseVector p W t 1 1 := by |
| 54 | rw [vector_eq hw t 1 _ (Zmap_diff h t (by simp) vary_diff),Zmap_one h] |
| 55 | have he : fderiv ℝ (penalty S (1:Config G c) ∘ vary 1) 0 = 0 := by |
| 56 | have hf : HasFDerivAt (𝕜:=ℝ) (fun a : Loops.Links G c => ∑ i, G.price (G.lieExp (paint G _ a i))) 0 0 := by |
| 57 | have ht (i : Bonds c) : HasFDerivAt (𝕜:=ℝ) (fun a : Loops.Links G c => G.price (G.lieExp (paint G _ a i))) 0 0 := by |
| 58 | let L := ((LinearMap.proj i).comp (paint G (Bonds c)).toLinearMap).toContinuousLinearMap |
| 59 | have he := ((Work.F03.price_smooth (A:=G.lieExp) G.exp_jet.contDiffAt).differentiableAt (by simp)).hasFDerivAt |
| 60 | rw [exp_price_rate.1,← L.map_zero] at he |
| 61 | exact (he.comp 0 L.hasFDerivAt).congr_fderiv (ContinuousLinearMap.zero_comp _) |
| 62 | simpa using HasFDerivAt.fun_sum (fun i (_ : i∈Finset.univ) => ht i) |
| 63 | have eq : penalty S (1:Config G c) ∘ vary 1 = (fun a : Loops.Links G c => S.kernel.penalty • (∑ i,G.price (G.lieExp (paint G _ a i)))) := by |
| 64 | ext a; simp [penalty,smul_eq_mul] |
| 65 | rw [eq]; simpa using! (hf.const_smul S.kernel.penalty).fderiv |
| 66 | unfold acceleration first grad |
| 67 | rw [he]; change _ + twist _ _ 0 = _ |
| 68 | rw [twist_zero,add_zero] |
| 69 | |
| 70 | /-- `mainTerm` piece sees no frame slots. -/ |
| 71 | lemma cost_input (hw : W.Bounds p σ C Λ) (U : Loops.Inputs G c f) : |
| 72 | cost (mainTerm p W ∘ positions) U = (projectFine G c f).transpose * cost (mainTerm p W) (positions U) * projectFine G c f := by |
| 73 | let P := ((projectFine G c f).mulVecLin).toContinuousLinearMap |
| 74 | have he : positions ∘ vary U = vary (positions U) ∘ P := by |
| 75 | funext v i; unfold positions; simp only [Function.comp_apply,vary]; congr 1 |
| 76 | apply PiLp.ext; intro j |
| 77 | change v (.inl i,j) = (projectFine G c f *ᵥ v) (i,j) |
| 78 | rw [projectFine,LinearMap.toMatrix'_mulVec]; rfl |
| 79 | have hp := Work.F02.mainTerm_contDiffAt hw (A:=vary (positions U)) (x:=0) vary_diff |
| 80 | rw [cost, Function.comp_assoc, he, ← Function.comp_assoc, bilinearAt_chain (P.map_zero.symm ▸ hp) P.contDiff.contDiffAt, P.map_zero, |
| 81 | linearAt,P.fderiv, show LinearMap.toMatrix' (P : _ →ₗ[_] _) = projectFine G c f by exact LinearMap.toMatrix'_toLin' _, cost, show twist (P : _ → Loops.Links G f) 0 _ = 0 from ?_,add_zero] |
| 82 | apply Finset.sum_eq_zero; intro i _; suffices bilinearAt (fun z => P z i) 0 = 0 by rw [this, smul_zero] |
| 83 | let L := ((LinearMap.proj i).comp P.toLinearMap).toContinuousLinearMap |
| 84 | ext m n |
| 85 | change bilinearAt (L : _ → ℝ) 0 m n = _ |
| 86 | rw [bilinearAt_apply,iteratedFDeriv_two_apply, |
| 87 | show fderiv ℝ (L : _ → ℝ) = fun _ => L by ext1; rw [L.fderiv], fderiv_fun_const]; rfl |
| 88 | |
| 89 | variable {E : Type} [NormedAddCommGroup E] [NormedSpace ℝ E] {x : E} {m k l : Type} [Fintype m] [Fintype k] [Fintype l] |
| 90 | |
| 91 | lemma matrix_component {f : E → Matrix m k ℝ} (hf : ContDiffAt ℝ ω f x) (i j) : |
| 92 | ContDiffAt ℝ ω (fun y => f y i j) x := |
| 93 | (contDiff_apply ℝ _ j).contDiffAt.comp _ ((contDiff_apply ℝ _ i).contDiffAt.comp |
| 94 | (f := fun y => (Matrix.ofLinearEquiv ℝ).symm (f y)) _ |
| 95 | ((Matrix.ofLinearEquiv ℝ (m:=m) (n:=k) (α:=ℝ)).symm.toContinuousLinearEquiv.contDiff.contDiffAt.comp (f:=f) x hf)) |
| 96 | |
| 97 | lemma smooth_transpose {f : E → Matrix m k ℝ} (hf : ContDiffAt ℝ ω f x) : |
| 98 | ContDiffAt ℝ ω (fun t => (f t).transpose) x := matrix_diff (fun i j => matrix_component hf j i) |
| 99 | |
| 100 | lemma smooth_mul {f : E → Matrix m k ℝ} {g : E → Matrix k l ℝ} (hf : ContDiffAt ℝ ω f x) |
| 101 | (hg : ContDiffAt ℝ ω g x) : ContDiffAt ℝ ω (fun t => f t * g t) x := matrix_diff |
| 102 | (fun i j => ContDiffAt.sum (fun k _ => (matrix_component hf i k).mul (matrix_component hg k j))) |
| 103 | |
| 104 | lemma smooth_R {U : E → Config G n} (h : MatDiffAt U x) : ContDiffAt ℝ ω (fun y => R_g (U y)) x := by |
| 105 | refine matrix_diff (fun ⟨i,k⟩ j => ?_) |
| 106 | let a := (Pi.single j 1 : Nodes G n) |
| 107 | change ContDiffAt ℝ ω (fun y => paint G _ (brace (U y) a) i k) x |
| 108 | simp_rw [paint_brace] |
| 109 | have hd := adjoint_diff (a:=fun _ => paint G _ a (i.1+step i.2)) (h i) contDiffAt_const |
| 110 | exact (PiLp.proj (𝕜:=ℝ) 2 _ k).contDiff.contDiffAt.comp (f:=fun y => _ - G.adjoint (U y i) _) x (contDiffAt_const.sub hd) |
| 111 | |
| 112 | lemma smooth_ghost {U : E → Config G n} (μ : ℝ) (h : MatDiffAt U x) : |
| 113 | ContDiffAt ℝ ω (fun t => ghost μ (U t)) x := (smooth_mul (smooth_transpose (smooth_R h)) (smooth_R h)).add contDiffAt_const |
| 114 | |
| 115 | lemma smooth_dressing {U : E → Config G n} {μ : ℝ} (hμ : 0 < μ) (h : MatDiffAt U x) : |
| 116 | ContDiffAt ℝ ω (fun t => dressing μ (U t)) x := |
| 117 | ((inv_contDiffAt _ (isUnit_iff_ne_zero.mpr (ghost_pos _ μ hμ).det_pos.ne')).comp x (smooth_ghost μ h)).const_smul _ |
| 118 | |
| 119 | lemma smooth_regulation {U : E → Config G n} {μ : ℝ} (hμ : 0 < μ) (h : MatDiffAt U x) : |
| 120 | ContDiffAt ℝ ω (fun t => regulation μ (U t)) x := ContDiffAt.sum (s:=Finset.range (depth+1)) fun i _ => (smooth_dressing hμ h).pow i |
| 121 | |
| 122 | variable [DecidableEq m] [DecidableEq k] |
| 123 | |
| 124 | omit [DecidableEq k] in |
| 125 | lemma smooth_rate {U : E → PatchField G m} {f : PatchField G m → PatchField G k} (hu : MatDiffAt U x) (h : MatDiffAt (f ∘ vary (U x)) 0) : |
| 126 | ContDiffAt ℝ ω (fun t => rate f (U t)) x := by |
| 127 | have he : MatDiffAt (f ∘ U) x := fun i => hu.along (g:=fun v => G.mat (f v i)) rfl (h i) |
| 128 | have hw := (hu.comp (show ContDiffAt ℝ ω Prod.fst (x,(0:Array G m)) from contDiffAt_fst)).vary contDiffAt_snd |
| 129 | have hh : MatDiffAt (fun z => f (vary (U z.1) z.2)) (x,(0:Array G m)) := |
| 130 | fun i => hw.along (g:=fun v => G.mat (f v i)) (U:=U x) (by simp) (h i) |
| 131 | have hi := (MatDiffAt.comp (x:=(x,(0:Array G m))) (f:=Prod.fst) (v:=f ∘ U) he contDiffAt_fst).displacement |
| 132 | hh (by change f (vary (U x) 0) = f (U x); rw [vary_zero]) |
| 133 | exact ContDiffAt.comp (g:=uncurry fun v w => linearAt (localize f (U v)) w) (f:=fun t => (t,0)) x |
| 134 | (linearAt_diff (m:=Point G m) (n:=Point G k) (x:=x) hi) (contDiffAt_id.prodMk contDiffAt_const) |
| 135 | |
| 136 | omit [DecidableEq k] in |
| 137 | lemma smooth_cost {U : E → PatchField G m} {f : E → PatchField G m → ℝ} (hf : ContDiffAt ℝ ω |
| 138 | (uncurry fun v a => f v (vary (U v) a)) (x,0)) : ContDiffAt ℝ ω (fun t => cost (f t) (U t)) x := |
| 139 | ContDiffAt.comp (g:=uncurry fun v w => bilinearAt (f v ∘ vary (U v)) w) (f:=fun t => (t,0)) x |
| 140 | (bilinearAt_diff hf) (contDiffAt_id.prodMk contDiffAt_const) |
| 141 | |
| 142 | lemma smooth_completion (h : S.patch.Branches S.kernel G) (t : S.Choices) {U : E → Loops.Inputs G c f} |
| 143 | (h1 : U x = 1) (hu : MatDiffAt U x) : ContDiffAt ℝ ω (fun x => completion t (U x)) x := by |
| 144 | have hX : ContDiffAt ℝ ω (fun x => X₀ t (U x)) x := smooth_rate hu (fun i => mat_inv_diff |
| 145 | ((Psi_diff h t (by simp [h1]) vary_diff) i)) |
| 146 | have hv : MatDiffAt (positions ∘ U) x := fun i => hu (Sum.inl i) |
| 147 | exact (smooth_mul (smooth_mul (smooth_regulation mu_pos hv) (smooth_transpose (smooth_R hv))) contDiffAt_const).add |
| 148 | ((smooth_mul ((smooth_dressing mu_pos hv).pow _) hX).const_smul _) |
| 149 | |
| 150 | lemma smooth_vector (h : S.patch.Branches S.kernel G) (hw : W.Bounds p σ C Λ) (t : S.Choices) |
| 151 | {V : E → Config G c} {U : E → Loops.Inputs G c f} (h1 : U x = 1) (hu : MatDiffAt U x) (hv : MatDiffAt V x) : |
| 152 | ContDiffAt ℝ ω (fun x => vector p W t (V x) (U x)) x := |
| 153 | (smooth_cost (completed_diff h hw t (U:=fun z : E × Loops.Dual G c f => vary (U z.1) z.2) (x:=(x,0)) ((vary_zero (U x)).trans h1) ((hu.comp contDiffAt_fst).vary contDiffAt_snd) |
| 154 | (V:=V ∘ Prod.fst) (hv.comp contDiffAt_fst))).add (smooth_mul (smooth_transpose (smooth_completion h t h1 hu)) (smooth_completion h t h1 hu)) |
| 155 | |
| 156 | lemma smooth_base (h : S.patch.Branches S.kernel G) (hw : W.Bounds p σ C Λ) (t : S.Choices) |
| 157 | {V : E → Config G c} {U : E → Loops.Inputs G c f} (h1 : U x = 1) (hu : MatDiffAt U x) (hv : MatDiffAt V x) : |
| 158 | ContDiffAt ℝ ω (fun x => baseVector p W t (V x) (U x)) x := by |
| 159 | have hZ : MatDiffAt (Zmap t ∘ vary (U x)) 0 := Zmap_diff h t (by simp [h1]) vary_diff |
| 160 | have hr := smooth_rate (f:=Zmap t) hu hZ |
| 161 | have hZ' := (MatDiffAt.comp (x:=(x,(0:Loops.Links G c))) (v:=Zmap t ∘ U) (f:=Prod.fst) (Zmap_diff h t h1 hu) contDiffAt_fst).vary contDiffAt_snd |
| 162 | have hv' := MatDiffAt.comp (x:=(x,(0:Loops.Links G c))) (v:=V) (f:=Prod.fst) hv contDiffAt_fst |
| 163 | have hp := smooth_cost (x:=x) (U:=Zmap t ∘ U) (f:=fun x => penalty S (V x)) |
| 164 | (penalty_diff S (x:=(x,(0:Loops.Links G c))) (Z:=fun z => vary (Zmap t (U z.1)) z.2) (V:=V ∘ Prod.fst) hv' hZ') |
| 165 | have ht := (hu.comp (show ContDiffAt ℝ ω Prod.fst (x,(0:Loops.Dual G c f)) from contDiffAt_fst)).vary contDiffAt_snd |
| 166 | have he := smooth_completion h t h1 hu |
| 167 | exact ((smooth_cost (U:=U) (f:=fun _ => mainTerm p W ∘ positions) (Work.F02.mainTerm_contDiffAt hw (A:=fun z : E × Loops.Dual G c f => positions (vary ((U ∘ Prod.fst) z) z.2)) |
| 168 | (x:=(x,0)) (fun i => ht (.inl i)))).add (smooth_mul (smooth_mul (smooth_transpose hr) hp) hr)).add |
| 169 | (smooth_mul (smooth_transpose he) he) |
| 170 | |
| 171 | lemma smooth_reference {U : E → Config G n} {μ : ℝ} (hμ : 0 < μ) (hw : W.Bounds p σ C Λ) (hu : MatDiffAt U x) : |
| 172 | ContDiffAt ℝ ω (fun x => reference μ p W (U x)) x := by |
| 173 | have hr := smooth_R hu |
| 174 | have hp : ContDiffAt ℝ ω (fun x => parallel (dressing μ (U x))) x := by |
| 175 | refine matrix_diff fun i j => ?_; unfold parallel; dsimp only [of_apply]; split |
| 176 | · exact matrix_component (smooth_dressing hμ hu) .. |
| 177 | exact contDiffAt_const |
| 178 | exact ((smooth_cost (U:=U) (f:=fun _ => mainTerm p W) (Work.F02.mainTerm_contDiffAt hw ((hu.comp contDiffAt_fst).vary contDiffAt_snd))).add |
| 179 | (smooth_mul (smooth_mul hr ((smooth_regulation hμ hu).pow 2)) (smooth_transpose hr))).add |
| 180 | ((hp.pow _).const_smul _) |
| 181 | |
| 182 | end YM.Push.Loops |