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.Extinction.Width.Transport.ConstantFamily |
| 2 | import PoincareLib.Geometry.RicciFlow.Extinction.Width.Deformation.SmoothTimeData |
| 3 | |
| 4 | set_option autoImplicit false |
| 5 | |
| 6 | open scoped Manifold ContDiff Bundle ENNReal Topology intervalIntegral |
| 7 | |
| 8 | universe u |
| 9 | |
| 10 | namespace PoincareMT |
| 11 | |
| 12 | /-! Build the M66 class data from the normalized M59 representative carried by |
| 13 | an M67 slice. The only non-formal scalar inputs are the two scalar-infimum |
| 14 | clauses already required by M66 itself. |
| 15 | -/ |
| 16 | noncomputable def m66ClassData_of_m59_representation |
| 17 | {M : Type u} [TopologicalSpace M] |
| 18 | [ChartedSpace LoopAmbient M] [IsManifold (𝓡 3) ∞ M] |
| 19 | [T2Space M] [SecondCountableTopology M] |
| 20 | {a b : ℝ} |
| 21 | (input : M65RawFlowInput M a b) |
| 22 | (hab : a < b) |
| 23 | (connected : IsConnected (Set.univ : Set M)) |
| 24 | (basepoint : M) |
| 25 | (pi_two : Subsingleton (HomotopyGroup.Pi 2 M basepoint)) |
| 26 | (S : M59IdentificationSystem.{u}) |
| 27 | (alpha : HomotopyGroup.Pi 2 (C1FreeLoopSpace (M := M)) |
| 28 | (constantC1Loop basepoint)) |
| 29 | (hrep : M61Represents S.quotient basepoint alpha input.family) |
| 30 | (loop_pi_three : HomotopyGroup.Pi 2 |
| 31 | (C1FreeLoopSpace (M := M)) (constantC1Loop basepoint) ≃* |
| 32 | HomotopyGroup.Pi 3 M basepoint) |
| 33 | (hnonzero : loop_pi_three alpha ≠ 1) |
| 34 | (scalar_infimum_attained : ∀ t : Set.Icc a b, ∃ x : M, |
| 35 | (input.flow.connection t.1).scalarCurvature x = |
| 36 | flowScalarCurvatureInfimum input.flow t.1) |
| 37 | (scalar_infimum_continuous : Continuous (fun t : Set.Icc a b => |
| 38 | flowScalarCurvatureInfimum input.flow t.1)) : |
| 39 | M66ClassData input := by |
| 40 | let witness := Classical.choose hrep |
| 41 | let hwitness := Classical.choose_spec hrep |
| 42 | let Gamma : FreeTwoSphereFamily (M := M) := witness |
| 43 | have hnormalized : M59NormalizedAt S.quotient basepoint Gamma := hwitness.1 |
| 44 | have hclass : familySigmaClass Gamma = ⟨basepoint, alpha⟩ := hwitness.2.1 |
| 45 | have hhom : input.family.Homotopic (m59FamilyMap Gamma) := hwitness.2.2 |
| 46 | have halpha : alpha ≠ 1 := by |
| 47 | intro h |
| 48 | apply hnonzero |
| 49 | rw [h] |
| 50 | exact loop_pi_three.map_one |
| 51 | have hGamma_nontrivial : |
| 52 | ¬ (m59FamilyMap Gamma).Homotopic (constantLoopFamily basepoint) := |
| 53 | m67_raw_nontrivial_of_normalized_family S input.compact connected basepoint |
| 54 | pi_two alpha Gamma hnormalized hclass halpha |
| 55 | refine { |
| 56 | strict_time := hab |
| 57 | connected := connected |
| 58 | basepoint := basepoint |
| 59 | pi_two_subsingleton := pi_two |
| 60 | raw_nontrivial := ?_ |
| 61 | scalar_infimum_attained := scalar_infimum_attained |
| 62 | scalar_infimum_continuous := scalar_infimum_continuous } |
| 63 | intro hconst |
| 64 | apply hGamma_nontrivial |
| 65 | exact hhom.symm.trans hconst |
| 66 | |
| 67 | end PoincareMT |