Poincaré conjecture: the Lean proof, cleaned up together
The 2026 Lean proof of the Poincaré conjecture after Morgan and Tian, 3 million lines, cleaned up together: smaller, faster to build, more readable, the theorems unchanged

| 1 | import PoincareLib.Geometry.RicciFlow.Surgery.CanonicalInduction.Limit.Noncollapse.LimitNoncollapseSharpCapture |
| 2 | import PoincareLib.Geometry.RicciFlow.Surgery.CanonicalInduction.Limit.Noncollapse.LimitNoncollapseCylinders |
| 3 | import PoincareLib.Geometry.RicciFlow.ReducedGeometry.ReducedLength.Calculus.RiemannianProper |
| 4 | |
| 5 | /-! |
| 6 | # Finite buffers and exact physical volume cancellation |
| 7 | |
| 8 | Each contracted limit test has its own finite included horizon and compact |
| 9 | spatial buffer. Divergence of the actual selected scalar scale removes the |
| 10 | source radius cutoff. Source: MT Proposition 17.1 and the reviewed |
| 11 | limit-noncollapse final-assembly derivation, sections 2, 3 and 6. |
| 12 | -/ |
| 13 | |
| 14 | set_option autoImplicit false |
| 15 | |
| 16 | open Set Filter |
| 17 | open scoped Manifold ContDiff Bundle Topology ENNReal |
| 18 | |
| 19 | universe u |
| 20 | |
| 21 | namespace PoincareMT.M47 |
| 22 | |
| 23 | /-- A closed contracted test lies in one strictly shorter finite horizon, |
| 24 | both for finite and for infinite limit horizon. -/ |
| 25 | theorem limitNoncollapse_exists_finite_test_horizon |
| 26 | {H : ENNReal} {t rho : ℝ} (ht : t ≤ 0) (_hrho : 0 < rho) |
| 27 | (hbottom : t - rho ^ 2 ∈ blowupBackwardInterval H) : |
| 28 | ∃ T : ℝ, 0 < T ∧ ENNReal.ofReal T < H ∧ |
| 29 | Icc (t - rho ^ 2) t ⊆ Ioc (-T) 0 := by |
| 30 | obtain ⟨T, _, hlow, hhigh⟩ := ENNReal.lt_iff_exists_real_btwn.mp hbottom.2 |
| 31 | have hT : 0 < T := ENNReal.ofReal_pos.mp (zero_le.trans_lt hlow) |
| 32 | have hlt : -(t - rho ^ 2) < T := |
| 33 | (ENNReal.ofReal_lt_ofReal_iff hT).mp hlow |
| 34 | refine ⟨T, hT, hhigh, ?_⟩ |
| 35 | intro s hs |
| 36 | exact ⟨by linarith [hs.1], hs.2.trans ht⟩ |
| 37 | |
| 38 | /-- The closure of a strictly smaller metric ball is inside the original |
| 39 | open ball in the actual selected Riemannian distance. -/ |
| 40 | theorem limitNoncollapse_closure_ball_subset |
| 41 | {M : Type*} [TopologicalSpace M] [T3Space M] |
| 42 | [ChartedSpace (EuclideanSpace ℝ (Fin 3)) M] [IsManifold (𝓡 3) ∞ M] |
| 43 | (g : RiemannianMetric 3 M) (p : M) {R r : ℝ} (hr : 0 < r) (hRr : R < r) : |
| 44 | closure (g.ball p R) ⊆ g.ball p r := by |
| 45 | let : PseudoEMetricSpace M := g.comparisonPseudoEMetric |
| 46 | have hclosed : IsClosed {x : M | g.edist p x ≤ ENNReal.ofReal R} := |
| 47 | isClosed_le (continuous_const.edist continuous_id) continuous_const |
| 48 | have hsubset : closure (g.ball p R) ⊆ {x : M | g.edist p x ≤ ENNReal.ofReal R} := |
| 49 | closure_minimal (fun x (hx : x ∈ g.ball p R) => |
| 50 | show g.edist p x ≤ ENNReal.ofReal R from |
| 51 | (show g.edist p x < ENNReal.ofReal R from hx).le) hclosed |
| 52 | intro x hx |
| 53 | exact (hsubset hx).trans_lt ((ENNReal.ofReal_lt_ofReal_iff hr).mpr hRr) |
| 54 | |
| 55 | /-- Every fixed normalized radius eventually meets the physical source |
| 56 | cutoff along the literal selected subsequence. -/ |
| 57 | theorem limitNoncollapse_eventually_physical_radius |
| 58 | {S : GeneralizedBlowupSequence.{u}} {J : Set ℝ} |
| 59 | (G : GeneralizedBlowupConvergence S J) (rho : ℝ) {r0 : ℝ} (hr0 : 0 < r0) : |
| 60 | ∀ᶠ k : ℕ in atTop, rho / Real.sqrt (S.scale (G.subsequence k)) ≤ r0 := by |
| 61 | have hQ : Tendsto (fun k => S.scale (G.subsequence k)) atTop atTop := |
| 62 | S.scalar_diverges.comp G.subsequence_strictMono.tendsto_atTop |
| 63 | have hzero : Tendsto (fun k => rho / Real.sqrt (S.scale (G.subsequence k))) |
| 64 | atTop (𝓝 0) := (Real.tendsto_sqrt_atTop.comp hQ).const_div_atTop rho |
| 65 | exact (hzero.eventually (Iio_mem_nhds hr0)).mono (fun _ hk => hk.le) |
| 66 | |
| 67 | /-- The two physical volume inequalities cancel their exact positive scale. |
| 68 | No finiteness hypothesis is imposed on either measure value. -/ |
| 69 | theorem limitNoncollapse_cancel_physical_volume |
| 70 | {Q lambda rho kappa : ℝ} (hQ : 0 < Q) (hlambda : 0 < lambda) |
| 71 | {W V : ENNReal} |
| 72 | (hlow : ENNReal.ofReal (kappa * (rho / Real.sqrt Q) ^ 3) ≤ W) |
| 73 | (hupp : W ≤ ENNReal.ofReal (1 / (lambda * Real.sqrt Q)) ^ 3 * V) : |
| 74 | ENNReal.ofReal (kappa * lambda ^ 3 * rho ^ 3) ≤ V := by |
| 75 | have hroot : 0 < Real.sqrt Q := Real.sqrt_pos.mpr hQ |
| 76 | have hprod : 0 < lambda * Real.sqrt Q := mul_pos hlambda hroot |
| 77 | have hcancel : ENNReal.ofReal (lambda * Real.sqrt Q) ^ 3 * |
| 78 | ENNReal.ofReal (1 / (lambda * Real.sqrt Q)) ^ 3 = 1 := by |
| 79 | rw [← mul_pow, ← ENNReal.ofReal_mul hprod.le] |
| 80 | simp only [mul_one_div_cancel hprod.ne', ENNReal.ofReal_one, one_pow] |
| 81 | have heq : ENNReal.ofReal (lambda * Real.sqrt Q) ^ 3 * |
| 82 | ENNReal.ofReal (kappa * (rho / Real.sqrt Q) ^ 3) = |
| 83 | ENNReal.ofReal (kappa * lambda ^ 3 * rho ^ 3) := by |
| 84 | rw [← ENNReal.ofReal_pow hprod.le, ← ENNReal.ofReal_mul (pow_nonneg hprod.le 3)] |
| 85 | congr 1 |
| 86 | field_simp |
| 87 | have hb := mul_le_mul_right (hlow.trans hupp) |
| 88 | (ENNReal.ofReal (lambda * Real.sqrt Q) ^ 3) |
| 89 | rwa [heq, ← mul_assoc, hcancel, one_mul] at hb |
| 90 | |
| 91 | end PoincareMT.M47 |