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.Surgery.CanonicalInduction.Blowup.Controls.BlowupControlsCapClock |
| 2 | |
| 3 | /-! |
| 4 | # The original terminal map after rebasing at a cap birth |
| 5 | |
| 6 | An arbitrary actual open source need not be a physical terminal slice. |
| 7 | The birth cylinder returns its original terminal map at every source |
| 8 | point. MT Lemma 17.7; limit-cap-source-included.md, C1. |
| 9 | -/ |
| 10 | |
| 11 | set_option autoImplicit false |
| 12 | set_option backward.isDefEq.respectTransparency false |
| 13 | |
| 14 | open Set |
| 15 | |
| 16 | universe u |
| 17 | |
| 18 | namespace PoincareMT.M47 |
| 19 | |
| 20 | /-- Rebase the actual source at its included birth while retaining its |
| 21 | original, possibly nonidentity, terminal map. -/ |
| 22 | theorem exists_cap_birth_cylinder_terminal_map |
| 23 | {F : SurgeryFlowData.{u}} {C : GeneralizedSliceCarrier.{u}} |
| 24 | {origin Q a : ℝ} {U : Set C.carrier} |
| 25 | (E : SurgeryFlowCylinder F C origin Q (Icc a 0) U) |
| 26 | (hU : IsOpen U) (ha : a < 0) (h : ℝ) (hh : 0 < h) : |
| 27 | let t := origin + a / Q |
| 28 | let V := E.forward a ⟨le_rfl, ha.le⟩ '' U |
| 29 | let d := (origin - t) / h ^ 2 |
| 30 | 0 < d ∧ |
| 31 | ∃ f : SurgeryFlowCylinder F (F.slice t) t (h⁻¹ ^ 2) (Icc 0 d) V, |
| 32 | (∀ hs x, x ∈ V → HEq (f.forward 0 hs x) x) ∧ |
| 33 | ∀ hd hz x, x ∈ U → |
| 34 | HEq (f.forward d hd (E.forward a ⟨le_rfl, ha.le⟩ x)) |
| 35 | (E.forward 0 hz x) := by |
| 36 | dsimp only |
| 37 | have hQ := E.scale_pos |
| 38 | have hd : 0 < (origin - (origin + a / Q)) / h ^ 2 := by |
| 39 | apply div_pos _ (sq_pos_of_pos hh) |
| 40 | linarith only [div_neg_of_neg_of_pos ha hQ] |
| 41 | obtain ⟨hmem, f, based, hpoint⟩ := exists_cap_birth_cylinder E hU ha h hh |
| 42 | refine ⟨hd, f, based, ?_⟩ |
| 43 | intro htop hzero x hx |
| 44 | let d := (origin - (origin + a / Q)) / h ^ 2 |
| 45 | have hparameter : a + Q * d * h ^ 2 = 0 := by |
| 46 | dsimp only [d] |
| 47 | field_simp [hQ.ne', hh.ne'] |
| 48 | ring |
| 49 | have hterminal (s : ℝ) (hs : s ∈ Icc a 0) (hs0 : s = 0) : |
| 50 | HEq (E.forward s hs x) (E.forward 0 hzero x) := by |
| 51 | subst s |
| 52 | rfl |
| 53 | exact (Sigma.mk.inj (hpoint d htop x hx)).2.trans |
| 54 | (hterminal _ (hmem htop) hparameter) |
| 55 | |
| 56 | end PoincareMT.M47 |