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.ThreeDimensional.Compact.QuotientHomothety |
| 2 | import PoincareLib.Geometry.RicciFlow.Splitting.MaximumPrinciple.RicciPropagation |
| 3 | import PoincareLib.Geometry.RicciFlow.Splitting.CurvatureNullity |
| 4 | import PoincareLib.Geometry.Riemannian.ScalarOperators.Extrema.FiniteRegularity |
| 5 | import PoincareLib.Geometry.Curvature.Operator.SectionalBounds |
| 6 | import PoincareLib.Geometry.Curvature.Operator.RicciBounds |
| 7 | import PoincareLib.Geometry.RicciFlow.Harnack.Regularity |
| 8 | |
| 9 | /-! |
| 10 | # Strict Ricci positivity of compact shrinking solitons |
| 11 | |
| 12 | The potential maximum gives positive Ricci at one point. Spatial constancy |
| 13 | of Ricci nullity on the actual ancient flow propagates this to every point. |
| 14 | -/ |
| 15 | |
| 16 | set_option autoImplicit false |
| 17 | set_option backward.isDefEq.respectTransparency false |
| 18 | |
| 19 | open Set |
| 20 | open scoped Manifold ContDiff Bundle |
| 21 | |
| 22 | universe u |
| 23 | |
| 24 | namespace PoincareMT |
| 25 | |
| 26 | variable {M : Type u} [TopologicalSpace M] |
| 27 | [ChartedSpace (EuclideanSpace ℝ (Fin 3)) M] [IsManifold (𝓡 3) ∞ M] |
| 28 | [MeasurableSpace M] [BorelSpace M] [T2Space M] [T3Space M] |
| 29 | [SecondCountableTopology M] [ConnectedSpace M] |
| 30 | {S : GradientShrinkingSolitonData 3 M} |
| 31 | |
| 32 | /-- Every slice of the supplied shrinking flow has nonnegative sectional curvature. -/ |
| 33 | theorem ShrinkingSolitonFlow.nonnegativeSectionalCurvature |
| 34 | (G : ShrinkingSolitonFlow S) {t : ℝ} (ht : t < 0) : |
| 35 | (G.flow.connection t).NonnegativeSectionalCurvature := by |
| 36 | obtain ⟨E⟩ := G.self_similar t ht |
| 37 | intro x v w |
| 38 | rw [(G.flow.connection t).curvatureTensor_eq_of_local_isometry |
| 39 | (rescaledMetric_connection S.metric S.connection |t| (abs_pos.mpr ht.ne)) |
| 40 | isOpen_univ E.map.contMDiff.contMDiffOn |
| 41 | (fun y _ a b => E.inner_eq y a b) (mem_univ x), rescaledMetric_curvatureTensor] |
| 42 | exact mul_nonneg (abs_nonneg t) |
| 43 | (S.connection.curvatureTensor_self_nonneg_of_nonnegative_curvatureOperator |
| 44 | _ (S.nonnegative_curvature _) _ _) |
| 45 | |
| 46 | omit [MeasurableSpace M] [BorelSpace M] [T2Space M] [T3Space M] |
| 47 | [SecondCountableTopology M] [ConnectedSpace M] in |
| 48 | private theorem ricci_eq_of_metric_eq {g h : RiemannianMetric 3 M} |
| 49 | (D : LeviCivitaData g) (D' : LeviCivitaData h) (heq : g = h) |
| 50 | (x : M) (v w : TangentSpace (𝓡 3) x) : D.ricci x v w = D'.ricci x v w := by |
| 51 | subst h |
| 52 | simp only [LeviCivitaData.ricci, D.curvatureTensor_eq D'] |
| 53 | |
| 54 | /-- Compactness and the original soliton equation rule out all Ricci-null directions. -/ |
| 55 | theorem ShrinkingSolitonFlow.ricci_pos_of_compact [CompactSpace M] |
| 56 | (hC : RicciFlowCurvatureTheory.{u}) (G : ShrinkingSolitonFlow S) |
| 57 | (x : M) (v : TangentSpace (𝓡 3) x) (hv : v ≠ 0) : |
| 58 | 0 < S.connection.ricci x v v := by |
| 59 | let : Bundle.RiemannianBundle (TangentSpace (𝓡 3) : M → Type _) := |
| 60 | ⟨S.metric.toRiemannianMetric⟩ |
| 61 | obtain ⟨p, _, hp⟩ := isCompact_univ.exists_isMaxOn univ_nonempty |
| 62 | S.potential_C2.continuous.continuousOn |
| 63 | have hpRic (z : TangentSpace (𝓡 3) p) (hz : z ≠ 0) : |
| 64 | 0 < S.connection.ricci p z z := by |
| 65 | have hmax := S.connection.hessian_nonpos_of_isLocalMax_C2 S.potential_C2 |
| 66 | (hp.isLocalMax (by simp)) z |
| 67 | have hs := S.soliton_equation p z z |
| 68 | have hnorm : 0 < S.metric.inner p z z := real_inner_self_pos.mpr hz |
| 69 | linarith |
| 70 | have hsame (y : M) (a b : TangentSpace (𝓡 3) y) : |
| 71 | (G.flow.connection (-1)).ricci y a b = S.connection.ricci y a b := |
| 72 | ricci_eq_of_metric_eq _ _ G.at_minus_one y a b |
| 73 | have hker : RicciFlow.Splitting.ricciKernel (G.flow.connection (-1)) p = ⊥ := by |
| 74 | apply le_antisymm _ bot_le |
| 75 | intro z hz |
| 76 | change z = 0 |
| 77 | by_contra hzero |
| 78 | have hz' := (RicciFlow.Splitting.mem_ricciKernel _ _ _).mp hz z |
| 79 | rw [hsame] at hz' |
| 80 | exact (hpRic z hzero).ne' hz' |
| 81 | have hpdim : RicciFlow.Splitting.ricciNullity (G.flow.connection (-1)) p = 0 := by |
| 82 | simp [RicciFlow.Splitting.ricciNullity, hker] |
| 83 | let F := Poincare.Geometry.RicciFlow.Harnack.restrictFlow G.flow |
| 84 | (show Icc (-2 : ℝ) (-1) ⊆ Iio 0 from fun _ hs => lt_of_le_of_lt hs.2 (by norm_num)) |
| 85 | ordConnected_Icc ⟨-2, by simp, -1, by simp, by norm_num⟩ |
| 86 | have hdim := RicciFlow.Splitting.ricciNullity_eq_on_positive_slice hC |
| 87 | (by norm_num : (-2 : ℝ) < -1) F |
| 88 | (fun t ht => G.nonnegativeSectionalCurvature (lt_of_le_of_lt ht.2 (by norm_num))) |
| 89 | (show (-1 : ℝ) ∈ Ioc (-2) (-1) by norm_num) x p |
| 90 | change RicciFlow.Splitting.ricciNullity (G.flow.connection (-1)) x = |
| 91 | RicciFlow.Splitting.ricciNullity (G.flow.connection (-1)) p at hdim |
| 92 | rw [hpdim] at hdim |
| 93 | have hD := hC.tensor_calculus 3 M S.metric S.connection |
| 94 | have hnonneg (z : TangentSpace (𝓡 3) x) : 0 ≤ S.connection.ricci x z z := |
| 95 | (S.connection.ricci_bounds_of_nonnegative_curvatureOperator hD x |
| 96 | (S.nonnegative_curvature x) z).1 |
| 97 | by_contra hpos |
| 98 | have hzero : S.connection.ricci x v v = 0 := |
| 99 | le_antisymm (le_of_not_gt hpos) (hnonneg v) |
| 100 | have hvker : v ∈ RicciFlow.Splitting.ricciKernel (G.flow.connection (-1)) x := by |
| 101 | apply (RicciFlow.Splitting.mem_ricciKernel _ _ _).mpr |
| 102 | intro w |
| 103 | rw [hsame] |
| 104 | exact RicciFlow.Splitting.ricci_eq_zero_of_nonneg_of_self_eq_zero |
| 105 | S.connection hD x hnonneg hzero w |
| 106 | have hdimpos : 0 < RicciFlow.Splitting.ricciNullity (G.flow.connection (-1)) x := by |
| 107 | apply Module.finrank_pos_iff_exists_ne_zero.mpr |
| 108 | exact ⟨⟨v, hvker⟩, fun h => hv (congrArg Subtype.val h)⟩ |
| 109 | omega |
| 110 | |
| 111 | end PoincareMT |