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.CurveShortening.Comparison.Compatibility.SourceNames |
| 2 | import PoincareLib.Geometry.Riemannian.LoopSpace.Area.LoopNeighborhoods |
| 3 | import PoincareLib.Geometry.Riemannian.LoopSpace.Length.PeriodicSpeed |
| 4 | |
| 5 | /-! |
| 6 | # Finite value nets of a compact C1 loop family |
| 7 | |
| 8 | The nodes are actual source parameters. One finite choice controls all |
| 9 | angular parameters, before any circle product or circumference is chosen. |
| 10 | |
| 11 | Morgan--Tian context: Section 19.6, Lemmas 19.30-19.31, printed pp. 461-466. |
| 12 | -/ |
| 13 | |
| 14 | set_option autoImplicit false |
| 15 | |
| 16 | open Set |
| 17 | open scoped Manifold ContDiff |
| 18 | |
| 19 | universe u |
| 20 | |
| 21 | namespace PoincareMT |
| 22 | |
| 23 | /-- An intrinsic C1 compact family has finitely many actual parameter nodes that uniformly |
| 24 | approximate loop values. Source: Auxiliary step for MT Section 19.6, pp. 461-462; project |
| 25 | construction in `proof-work/tasks/M64/reports/2026-09-24-finite-nets-closed.md`. -/ |
| 26 | theorem m64_finite_loop_value_net |
| 27 | {M : Type u} [TopologicalSpace M] [T2Space M] |
| 28 | [ChartedSpace LoopAmbient M] [IsManifold (𝓡 3) ∞ M] |
| 29 | (g : RiemannianMetric 3 M) |
| 30 | {Z : Type*} [TopologicalSpace Z] [CompactSpace Z] |
| 31 | (Gamma : Z → C1FreeLoopSpace (M := M)) (hGamma : Continuous Gamma) |
| 32 | {epsilon : ℝ} (hepsilon : 0 < epsilon) : |
| 33 | ∃ k : ℕ, ∃ nodes : Fin k → Z, ∀ z : Z, ∃ i : Fin k, |
| 34 | ∀ x : ℝ, g.edist (periodicFreeLoop (Gamma z) x) |
| 35 | (periodicFreeLoop (Gamma (nodes i)) x) < ENNReal.ofReal epsilon := by |
| 36 | classical |
| 37 | have hnear (w : Z) := m60_exists_loop_close_neighborhood g (Gamma w) hepsilon |
| 38 | choose U hU hself hclose using hnear |
| 39 | let V : Z → Set Z := fun w => Gamma ⁻¹' U w |
| 40 | have hV (w : Z) : IsOpen (V w) := (hU w).preimage hGamma |
| 41 | obtain ⟨S, hS⟩ := isCompact_univ.elim_finite_subcover V hV |
| 42 | (fun z _ => mem_iUnion.mpr ⟨z, hself z⟩) |
| 43 | let e : Fin (Fintype.card S) ≃ S := (Fintype.equivFin S).symm |
| 44 | refine ⟨Fintype.card S, fun i => (e i).val, ?_⟩ |
| 45 | intro z |
| 46 | obtain ⟨w, hwS, hzw⟩ := mem_iUnion₂.mp (hS (mem_univ z)) |
| 47 | refine ⟨e.symm ⟨w, hwS⟩, ?_⟩ |
| 48 | intro x |
| 49 | simp only [e.apply_symm_apply] |
| 50 | let q : LoopCircle := |
| 51 | ⟨Proofs.M58.angularPoint x, Proofs.M58.norm_angularPoint x⟩ |
| 52 | have h := hclose w (Gamma z) hzw q |
| 53 | rw [← (Gamma z).boundary q, ← (Gamma w).boundary q] at h |
| 54 | exact h |
| 55 | |
| 56 | end PoincareMT |