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.Analysis.Parabolic.PointPicking |
| 2 | import PoincareLib.Geometry.RicciFlow.Curvature.Theory |
| 3 | import PoincareLib.Geometry.RicciFlow.Harnack.Noncompact.CurvatureControl.MetricMonotonicity |
| 4 | import PoincareLib.Geometry.Riemannian.Distance.CompleteBalls |
| 5 | |
| 6 | /-! |
| 7 | # Scalar-curvature point selection |
| 8 | |
| 9 | Nonnegative Ricci curvature confines earlier moving balls inside the terminal |
| 10 | ball. Completeness and joint scalar regularity then bound scalar curvature on |
| 11 | their union. Finite doubling selects an earlier point with curvature control |
| 12 | on a neighborhood of its inverse-square-root curvature scale. |
| 13 | |
| 14 | This is the point-selection part of Chen, Theorem 3.1, manuscript p. 10, |
| 15 | with a factor four in scalar curvature. The subsequent parabolic distance |
| 16 | and cutoff estimates are separate geometric steps. |
| 17 | -/ |
| 18 | |
| 19 | set_option autoImplicit false |
| 20 | set_option backward.isDefEq.respectTransparency false |
| 21 | |
| 22 | open Set |
| 23 | open scoped Manifold ContDiff Bundle ENNReal |
| 24 | |
| 25 | universe u |
| 26 | |
| 27 | namespace PoincareMT.RicciFlow |
| 28 | |
| 29 | variable {n : ℕ} {M : Type u} [TopologicalSpace M] [T3Space M] |
| 30 | [ChartedSpace (EuclideanSpace ℝ (Fin n)) M] [IsManifold (𝓡 n) ∞ M] |
| 31 | {J : Set ℝ} |
| 32 | |
| 33 | /-- On earlier moving balls, select a point with scalar curvature controlled |
| 34 | within its curvature scale. No uniform curvature bound is assumed. -/ |
| 35 | theorem exists_scalarCurvature_point_with_doubling_bound |
| 36 | (hC : RicciFlowCurvatureTheory.{u}) (F : RicciFlow n M J) |
| 37 | {a b : ℝ} (hJ : Icc a b ⊆ interior J) |
| 38 | (hcomplete : MetricComplete (F.metric b)) |
| 39 | (hRic : ∀ t ∈ Icc a b, ∀ x : M, ∀ v : TangentSpace (𝓡 n) x, |
| 40 | 0 ≤ (F.connection t).ricci x v v) |
| 41 | (p : M) (r : ℝ) {L : ℝ} (hL : 0 ≤ L) |
| 42 | {t₀ : ℝ} (ht₀ : t₀ ∈ Icc a b) {x₀ : M} |
| 43 | (hx₀ : x₀ ∈ (F.metric t₀).ball p r) |
| 44 | (hR₀ : 0 < (F.connection t₀).scalarCurvature x₀) : |
| 45 | ∃ t ∈ Icc a t₀, ∃ x ∈ (F.metric t).ball p r, |
| 46 | (F.connection t₀).scalarCurvature x₀ ≤ (F.connection t).scalarCurvature x ∧ |
| 47 | ((F.metric t).edist p x).toReal + |
| 48 | 2 * L / Real.sqrt ((F.connection t).scalarCurvature x) ≤ |
| 49 | ((F.metric t₀).edist p x₀).toReal + |
| 50 | 2 * L / Real.sqrt ((F.connection t₀).scalarCurvature x₀) ∧ |
| 51 | ∀ s ∈ Icc a t, ∀ y ∈ (F.metric s).ball p r, |
| 52 | ((F.metric s).edist p y).toReal ≤ ((F.metric t).edist p x).toReal + |
| 53 | L / Real.sqrt ((F.connection t).scalarCurvature x) → |
| 54 | (F.connection s).scalarCurvature y ≤ 4 * (F.connection t).scalarCurvature x := by |
| 55 | let S : Set (ℝ × M) := {z | z.1 ∈ Icc a b ∧ z.2 ∈ (F.metric z.1).ball p r} |
| 56 | let K : Set (ℝ × M) := Icc a b ×ˢ {x | (F.metric b).edist p x ≤ ENNReal.ofReal r} |
| 57 | let q : ℝ × M → ℝ := fun z => Real.sqrt ((F.connection z.1).scalarCurvature z.2) |
| 58 | let radius : ℝ × M → ℝ := fun z => ((F.metric z.1).edist p z.2).toReal |
| 59 | have hb : b ∈ Icc a b := ⟨ht₀.1.trans ht₀.2, le_rfl⟩ |
| 60 | have hSK : S ⊆ K := by |
| 61 | rintro ⟨s, y⟩ ⟨hs, hy⟩ |
| 62 | refine ⟨hs, ?_⟩ |
| 63 | have hball := F.ball_subset_ball_of_ricci_nonneg hJ p r hs hb hs.2 |
| 64 | (fun t ht x _ v => hRic t ht x v) hy |
| 65 | exact (show (F.metric b).edist p y < ENNReal.ofReal r from hball).le |
| 66 | have hK : IsCompact K := isCompact_Icc.prod |
| 67 | ((F.metric b).isCompact_closedBall_of_metricComplete hcomplete p r) |
| 68 | have hq : ContinuousOn q K := Real.continuous_sqrt.comp_continuousOn |
| 69 | ((hC.scalar_regular n M J F).continuousOn.mono (fun z hz => |
| 70 | ⟨interior_subset (hJ hz.1), mem_univ _⟩)) |
| 71 | have hbound : BddAbove (q '' S) := (hK.bddAbove_image hq).mono (image_mono hSK) |
| 72 | obtain ⟨⟨t, x⟩, htx, htt, hRx, hrad, hlocal⟩ := |
| 73 | Poincare.Parabolic.exists_point_with_doubling_bound S q radius Prod.fst hbound hL |
| 74 | (show (t₀, x₀) ∈ S from ⟨ht₀, hx₀⟩) (Real.sqrt_pos.mpr hR₀) |
| 75 | have hR (s : ℝ) (hs : s ∈ Icc a b) (y : M) : |
| 76 | 0 ≤ (F.connection s).scalarCurvature y := |
| 77 | Finset.sum_nonneg (fun i _ => hRic s hs y _) |
| 78 | have hRx' : (F.connection t₀).scalarCurvature x₀ ≤ |
| 79 | (F.connection t).scalarCurvature x := by |
| 80 | have hsq := sq_le_sq₀ (Real.sqrt_nonneg ((F.connection t₀).scalarCurvature x₀)) |
| 81 | (Real.sqrt_nonneg ((F.connection t).scalarCurvature x)) |
| 82 | simpa only [Real.sq_sqrt hR₀.le, Real.sq_sqrt (hR t htx.1 x)] using hsq.mpr hRx |
| 83 | refine ⟨t, ⟨htx.1.1, htt⟩, x, htx.2, hRx', hrad, ?_⟩ |
| 84 | intro s hs y hy hdist |
| 85 | have hs' : s ∈ Icc a b := ⟨hs.1, hs.2.trans htx.1.2⟩ |
| 86 | have h := hlocal (s, y) ⟨hs', hy⟩ hs.2 hdist |
| 87 | have hsq := mul_self_le_mul_self (Real.sqrt_nonneg ((F.connection s).scalarCurvature y)) h |
| 88 | dsimp only [q] at hsq |
| 89 | nlinarith [Real.sq_sqrt (hR s hs' y), Real.sq_sqrt (hR t htx.1 x)] |
| 90 | |
| 91 | end PoincareMT.RicciFlow |