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.Soliton.Models.Spherical.Normalization |
| 2 | import PoincareLib.Geometry.Riemannian.Normalization.Scaling.Geometry |
| 3 | import PoincareLib.Geometry.Riemannian.SpaceForm.SphereCurvature |
| 4 | |
| 5 | /-! |
| 6 | # The normalized metric and round shrinking sphere |
| 7 | |
| 8 | Rescaling the soliton metric by one quarter gives unit sectional curvature. |
| 9 | On the sphere the model metric has factor -4t at every negative time. |
| 10 | -/ |
| 11 | |
| 12 | noncomputable section |
| 13 | set_option autoImplicit false |
| 14 | set_option backward.isDefEq.respectTransparency false |
| 15 | |
| 16 | open scoped Manifold ContDiff Bundle ENNReal Topology |
| 17 | open Poincare.Geometry.Riemannian.SpaceForm |
| 18 | |
| 19 | namespace PoincareMT |
| 20 | |
| 21 | private theorem gram_ne_zero_of_rescaled {n : ℕ} {M : Type*} [TopologicalSpace M] |
| 22 | [ChartedSpace (EuclideanSpace ℝ (Fin n)) M] [IsManifold (𝓡 n) ∞ M] |
| 23 | (g : RiemannianMetric n M) (c : ℝ) (hc : 0 < c) (x : M) |
| 24 | (u v : TangentSpace (𝓡 n) x) |
| 25 | (hgram : (rescaledMetric g c hc).inner x u u * (rescaledMetric g c hc).inner x v v - |
| 26 | ((rescaledMetric g c hc).inner x u v) ^ 2 ≠ 0) : |
| 27 | g.inner x u u * g.inner x v v - (g.inner x u v) ^ 2 ≠ 0 := by |
| 28 | intro h |
| 29 | apply hgram |
| 30 | simp only [rescaledMetric_inner] |
| 31 | calc |
| 32 | _ = c ^ 2 * (g.inner x u u * g.inner x v v - (g.inner x u v) ^ 2) := by ring |
| 33 | _ = 0 := by rw [h, mul_zero] |
| 34 | |
| 35 | namespace CompactRoundShrinkingModel |
| 36 | |
| 37 | variable {M : Type*} [TopologicalSpace M] |
| 38 | [ChartedSpace (EuclideanSpace ℝ (Fin 3)) M] |
| 39 | [IsManifold (𝓡 3) ∞ M] [MeasurableSpace M] [BorelSpace M] |
| 40 | [T2Space M] [T3Space M] [SecondCountableTopology M] [ConnectedSpace M] |
| 41 | {S : GradientShrinkingSolitonData 3 M} {G : ShrinkingSolitonFlow S} |
| 42 | |
| 43 | /-- The unit-curvature metric to which spherical covering theory applies. -/ |
| 44 | def unitMetric (_C : CompactRoundShrinkingModel G) : RiemannianMetric 3 M := |
| 45 | rescaledMetric S.metric (1 / 4) (by norm_num) |
| 46 | |
| 47 | theorem unitMetric_sectionalCurvature (C : CompactRoundShrinkingModel G) |
| 48 | (x : M) (u v : TangentSpace (𝓡 3) x) |
| 49 | (hgram : C.unitMetric.inner x u u * C.unitMetric.inner x v v - |
| 50 | (C.unitMetric.inner x u v) ^ 2 ≠ 0) : |
| 51 | C.unitMetric.leviCivitaData.sectionalCurvature x u v = 1 := by |
| 52 | let D := rescaledMetric_connection S.metric S.connection (1 / 4) (by norm_num) |
| 53 | have heq : C.unitMetric.leviCivitaData.sectionalCurvature x u v = |
| 54 | D.sectionalCurvature x u v := by |
| 55 | simp only [LeviCivitaData.sectionalCurvature, |
| 56 | C.unitMetric.leviCivitaData.curvatureTensor_eq D] |
| 57 | rfl |
| 58 | rw [heq, rescaledMetric_sectionalCurvature, C.soliton_sectionalCurvature x u v |
| 59 | (gram_ne_zero_of_rescaled S.metric (1 / 4) (by norm_num) x u v hgram)] |
| 60 | norm_num |
| 61 | |
| 62 | /-- A fixed unit-metric covering automatically transports the entire shrinking flow. -/ |
| 63 | theorem inner_pullback_eq_round_scale (C : CompactRoundShrinkingModel G) |
| 64 | (q : UnitSphere 3 → M) |
| 65 | (hq : ∀ x : UnitSphere 3, ∀ u v : TangentSpace (𝓡 3) x, |
| 66 | C.unitMetric.inner (q x) (mfderiv (𝓡 3) (𝓡 3) q x u) |
| 67 | (mfderiv (𝓡 3) (𝓡 3) q x v) = (roundSphereMetric 3).inner x u v) |
| 68 | (t : ℝ) (ht : t < 0) (x : UnitSphere 3) (u v : TangentSpace (𝓡 3) x) : |
| 69 | (G.flow.metric t).inner (q x) (mfderiv (𝓡 3) (𝓡 3) q x u) |
| 70 | (mfderiv (𝓡 3) (𝓡 3) q x v) = (-4 * t) * (roundSphereMetric 3).inner x u v := by |
| 71 | rw [C.inner_eq_neg_time_mul t ht] |
| 72 | have h := hq x u v |
| 73 | change (1 / 4 : ℝ) * S.metric.inner (q x) (mfderiv (𝓡 3) (𝓡 3) q x u) |
| 74 | (mfderiv (𝓡 3) (𝓡 3) q x v) = (roundSphereMetric 3).inner x u v at h |
| 75 | rw [← h] |
| 76 | ring |
| 77 | |
| 78 | end CompactRoundShrinkingModel |
| 79 | |
| 80 | namespace SphericalShrinkingMetric |
| 81 | |
| 82 | /-- A positive total representative of the negative-time shrinking scale. -/ |
| 83 | def scale (t : ℝ) : ℝ := if t < 0 then -4 * t else 1 |
| 84 | |
| 85 | theorem scale_pos (t : ℝ) : 0 < scale t := by |
| 86 | unfold scale |
| 87 | split_ifs with ht |
| 88 | · nlinarith |
| 89 | · norm_num |
| 90 | |
| 91 | def metric (t : ℝ) : RiemannianMetric 3 (UnitSphere 3) := |
| 92 | rescaledMetric (roundSphereMetric 3) (scale t) (scale_pos t) |
| 93 | |
| 94 | def connection (t : ℝ) : LeviCivitaData (metric t) := |
| 95 | rescaledMetric_connection (roundSphereMetric 3) (roundSphereMetric 3).leviCivitaData |
| 96 | (scale t) (scale_pos t) |
| 97 | |
| 98 | theorem inner (t : ℝ) (ht : t < 0) (x : UnitSphere 3) |
| 99 | (u v : TangentSpace (𝓡 3) x) : |
| 100 | (metric t).inner x u v = (-4 * t) * (roundSphereMetric 3).inner x u v := by |
| 101 | simp only [metric, rescaledMetric_inner, scale, if_pos ht] |
| 102 | |
| 103 | theorem round (t : ℝ) : ConstantPositiveSectionalCurvature (metric t) (connection t) := by |
| 104 | refine ⟨(scale t)⁻¹, inv_pos.mpr (scale_pos t), fun x u v hu hv huv => ?_⟩ |
| 105 | have hgram : (metric t).inner x u u * (metric t).inner x v v - |
| 106 | ((metric t).inner x u v) ^ 2 ≠ 0 := by rw [hu, hv, huv]; norm_num |
| 107 | have hbase := gram_ne_zero_of_rescaled (roundSphereMetric 3) (scale t) |
| 108 | (scale_pos t) x u v hgram |
| 109 | rw [connection, rescaledMetric_sectionalCurvature, |
| 110 | roundSphereMetric_unit_sectionalCurvature x u v hbase, mul_one] |
| 111 | |
| 112 | end SphericalShrinkingMetric |
| 113 | |
| 114 | end PoincareMT |