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.FactorLimit |
| 2 | |
| 3 | set_option autoImplicit false |
| 4 | |
| 5 | namespace PoincareMT |
| 6 | |
| 7 | /-- Choose one multiplicative tolerance before choosing a left time neighborhood. -/ |
| 8 | theorem m67_factor_tolerance {v epsilon : ℝ} (hv : 0 ≤ v) (hepsilon : 0 < epsilon) : |
| 9 | ∃ eta : ℝ, 0 < eta ∧ ∀ w : ℝ, v ≤ (1 + eta) ^ 2 * w → v ≤ w + epsilon := by |
| 10 | let eta := min 1 (epsilon / (4 * (v + 1))) |
| 11 | have hden : 0 < 4 * (v + 1) := by positivity |
| 12 | have heta : 0 < eta := lt_min zero_lt_one (div_pos hepsilon hden) |
| 13 | have hsmall : eta ≤ 1 := min_le_left _ _ |
| 14 | have hbudget : 4 * eta * (v + 1) ≤ epsilon := by |
| 15 | have := (le_div_iff₀ hden).mp (min_le_right 1 (epsilon / (4 * (v + 1)))) |
| 16 | dsimp [eta] |
| 17 | nlinarith |
| 18 | refine ⟨eta, heta, fun w hbound => ?_⟩ |
| 19 | by_cases hlarge : v ≤ w |
| 20 | · linarith |
| 21 | have hwv : w ≤ v := (lt_of_not_ge hlarge).le |
| 22 | have hfactor : 0 < (1 + eta) ^ 2 := sq_pos_of_pos (by linarith) |
| 23 | have hw : 0 ≤ w := by nlinarith |
| 24 | have hsquare : eta ^ 2 ≤ eta := by nlinarith |
| 25 | have hsqw : eta ^ 2 * w ≤ eta * w := mul_le_mul_of_nonneg_right hsquare hw |
| 26 | have hmul : eta * w ≤ eta * v := mul_le_mul_of_nonneg_left hwv heta.le |
| 27 | nlinarith |
| 28 | |
| 29 | /-- Uniform multiplicative bounds near a time imply the additive lower-limit |
| 30 | clause, without assuming left continuity or a left width limit. -/ |
| 31 | theorem m67_lower_limit_of_factor_bounds |
| 32 | {T : ℝ} (width : Set.Icc (0 : ℝ) T → ℝ) (s : Set.Icc (0 : ℝ) T) |
| 33 | (hs : 0 ≤ width s) |
| 34 | (hfactor : ∀ eta : ℝ, 0 < eta → ∃ delta : ℝ, 0 < delta ∧ |
| 35 | ∀ t : Set.Icc (0 : ℝ) T, s.1 - delta < t.1 → t.1 < s.1 → |
| 36 | width s ≤ (1 + eta) ^ 2 * width t) : |
| 37 | ∀ epsilon : ℝ, 0 < epsilon → ∃ delta : ℝ, 0 < delta ∧ |
| 38 | ∀ t : Set.Icc (0 : ℝ) T, s.1 - delta < t.1 → t.1 < s.1 → |
| 39 | width s ≤ width t + epsilon := by |
| 40 | intro epsilon hepsilon |
| 41 | obtain ⟨eta, heta, htol⟩ := m67_factor_tolerance hs hepsilon |
| 42 | obtain ⟨delta, hdelta, hbound⟩ := hfactor eta heta |
| 43 | exact ⟨delta, hdelta, fun t ht hts => htol (width t) (hbound t ht hts)⟩ |
| 44 | |
| 45 | end PoincareMT |