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 Mathlib.Algebra.Order.Archimedean.Real.Basic |
| 2 | import Mathlib.Tactic.FieldSimp |
| 3 | import Mathlib.Tactic.Linarith |
| 4 | import Mathlib.Tactic.NormNum |
| 5 | import Mathlib.Tactic.Positivity |
| 6 | import Mathlib.Tactic.Push |
| 7 | |
| 8 | /-! |
| 9 | # Point selection with controlled displacement |
| 10 | |
| 11 | For a bounded size function, repeated doubling terminates while the sum of |
| 12 | the reciprocal-size displacements stays bounded. Time is only required to |
| 13 | decrease. This is the point-selection step in Chen, Theorem 3.1, manuscript |
| 14 | p. 10, applied to the square root of curvature. |
| 15 | -/ |
| 16 | |
| 17 | set_option autoImplicit false |
| 18 | |
| 19 | open Set |
| 20 | |
| 21 | namespace Poincare.Parabolic |
| 22 | |
| 23 | /-- A bounded size function has a point whose earlier nearby values are at |
| 24 | most twice its size. The reciprocal-size displacement budget is retained. -/ |
| 25 | theorem exists_point_with_doubling_bound |
| 26 | {X : Type*} (S : Set X) (size radius time : X → ℝ) |
| 27 | (hbounded : BddAbove (size '' S)) {L : ℝ} (hL : 0 ≤ L) |
| 28 | {x : X} (hx : x ∈ S) (hxpos : 0 < size x) : |
| 29 | ∃ y ∈ S, time y ≤ time x ∧ size x ≤ size y ∧ |
| 30 | radius y + 2 * L / size y ≤ radius x + 2 * L / size x ∧ |
| 31 | ∀ z ∈ S, time z ≤ time y → radius z ≤ radius y + L / size y → |
| 32 | size z ≤ 2 * size y := by |
| 33 | classical |
| 34 | by_contra h |
| 35 | push Not at h |
| 36 | have hseq (k : ℕ) : ∃ y ∈ S, time y ≤ time x ∧ size x ≤ size y ∧ |
| 37 | radius y + 2 * L / size y ≤ radius x + 2 * L / size x ∧ |
| 38 | 2 ^ k * size x ≤ size y := by |
| 39 | induction k with |
| 40 | | zero => exact ⟨x, hx, le_rfl, le_rfl, le_rfl, by simp⟩ |
| 41 | | succ k ih => |
| 42 | obtain ⟨y, hy, hty, hxy, hry, hqy⟩ := ih |
| 43 | obtain ⟨z, hz, htz, hrz, hqz⟩ := h y hy hty hxy hry |
| 44 | have hypos : 0 < size y := hxpos.trans_le hxy |
| 45 | have hstep : 2 * L / size z ≤ L / size y := by |
| 46 | calc |
| 47 | 2 * L / size z ≤ 2 * L / (2 * size y) := |
| 48 | div_le_div_of_nonneg_left (by positivity) (by positivity) hqz.le |
| 49 | _ = L / size y := by field_simp |
| 50 | refine ⟨z, hz, htz.trans hty, hxy.trans (by linarith), ?_, ?_⟩ |
| 51 | · calc |
| 52 | radius z + 2 * L / size z ≤ radius y + 2 * L / size y := by |
| 53 | simp only [mul_div_assoc] at hstep ⊢ |
| 54 | linarith |
| 55 | _ ≤ _ := hry |
| 56 | · rw [pow_succ] |
| 57 | nlinarith |
| 58 | obtain ⟨K, hK⟩ := hbounded |
| 59 | obtain ⟨k, hk⟩ := pow_unbounded_of_one_lt (K / size x) (by norm_num : (1 : ℝ) < 2) |
| 60 | obtain ⟨y, hy, _, _, _, hqy⟩ := hseq k |
| 61 | have hupper : size y ≤ K := hK (mem_image_of_mem size hy) |
| 62 | have hlower : K < 2 ^ k * size x := (div_lt_iff₀ hxpos).mp hk |
| 63 | linarith |
| 64 | |
| 65 | end Poincare.Parabolic |