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.StandardCap.Uniqueness.Imports |
| 2 | import PoincareLib.Geometry.RicciFlow.Surgery.StandardCap.Uniqueness.Blowup.Cylinder.Geometry.PolarCoordinates |
| 3 | |
| 4 | /-! |
| 5 | # Literal radial annulus coordinates |
| 6 | |
| 7 | Morgan-Tian Theorem 12.32, pp. 326-327. |
| 8 | The affine radial coordinate gives a genuine standard cylinder patch, |
| 9 | with the full open annulus as image and the prescribed radial sphere |
| 10 | as central sphere. This is the spatial map used for a radial cap end; |
| 11 | the cylindrical metric estimate is a separate geometric assertion. |
| 12 | -/ |
| 13 | |
| 14 | set_option autoImplicit false |
| 15 | set_option backward.isDefEq.respectTransparency false |
| 16 | |
| 17 | open Set |
| 18 | open scoped Manifold ContDiff Bundle Topology |
| 19 | |
| 20 | namespace PoincareMT.M35 |
| 21 | |
| 22 | private theorem polar_positive_smul (q₀ q : UnitTwoSphere) {r : ℝ} (hr : 0 < r) : |
| 23 | spherePolarMap q₀ (r • q.val) = (q, r - 1) := by |
| 24 | have hnorm : ‖r • q.val‖ = r := by |
| 25 | rw [norm_smul, Real.norm_eq_abs, abs_of_pos hr, norm_eq_of_mem_sphere, mul_one] |
| 26 | have hne : r • q.val ≠ 0 := norm_ne_zero_iff.mp (hnorm.trans_ne hr.ne') |
| 27 | apply Prod.ext |
| 28 | · apply Subtype.ext |
| 29 | simp only [spherePolarMap, dif_neg hne, hnorm, smul_smul, |
| 30 | inv_mul_cancel₀ hr.ne', one_smul] |
| 31 | · simp only [spherePolarMap, dif_neg hne, hnorm] |
| 32 | |
| 33 | /-- Theorem 12.32, pp. 326-327: the actual affine radial annulus is a smooth cylinder patch of the |
| 34 | literal requested length, centered at the prescribed radial point. -/ |
| 35 | noncomputable def radialAnnulusPatch (q₀ : UnitTwoSphere) (a b length : ℝ) |
| 36 | (hb : 0 < b) (hl : 0 < length) (hinner : 0 < a - b * length) : |
| 37 | StandardCylinderPatch length (a • q₀.val) := by |
| 38 | let : Fact (Module.finrank ℝ StandardCapSpace = 2 + 1) := |
| 39 | ⟨finrank_euclideanSpace_fin⟩ |
| 40 | let f : StandardCylinderSpace → StandardCapSpace := fun z => (a + b * z.2) • z.1.val |
| 41 | let inv : StandardCapSpace → StandardCylinderSpace := fun x => |
| 42 | ((spherePolarMap q₀ x).1, (‖x‖ - a) / b) |
| 43 | let U : Set StandardCapSpace := {x | a - b * length < ‖x‖ ∧ ‖x‖ < a + b * length} |
| 44 | have hpos (z : StandardCylinderSpace) (hz : z.2 ∈ Ioo (-length) length) : |
| 45 | 0 < a + b * z.2 := by |
| 46 | have h := mul_lt_mul_of_pos_left hz.1 hb |
| 47 | linarith |
| 48 | have hnorm (z : StandardCylinderSpace) (hz : z.2 ∈ Ioo (-length) length) : |
| 49 | ‖f z‖ = a + b * z.2 := by |
| 50 | change ‖(a + b * z.2) • z.1.val‖ = a + b * z.2 |
| 51 | rw [norm_smul, Real.norm_eq_abs, abs_of_pos (hpos z hz), |
| 52 | norm_eq_of_mem_sphere, mul_one] |
| 53 | have hinv (x : StandardCapSpace) (hx : x ∈ U) : |
| 54 | (inv x).2 ∈ Ioo (-length) length := by |
| 55 | change -length < (‖x‖ - a) / b ∧ (‖x‖ - a) / b < length |
| 56 | exact ⟨(lt_div_iff₀ hb).mpr (by linarith [hx.1]), |
| 57 | (div_lt_iff₀ hb).mpr (by linarith [hx.2])⟩ |
| 58 | have hright (x : StandardCapSpace) (hx : x ∈ U) : f (inv x) = x := by |
| 59 | have hn : 0 < ‖x‖ := hinner.trans hx.1 |
| 60 | have hne : x ≠ 0 := norm_pos_iff.mp hn |
| 61 | have hc : a + b * ((‖x‖ - a) / b) = ‖x‖ := by field_simp [hb.ne']; ring |
| 62 | simp only [f, inv, spherePolarMap, dif_neg hne, hc, smul_smul, |
| 63 | mul_inv_cancel₀ hn.ne', one_smul] |
| 64 | refine { |
| 65 | length_pos := hl |
| 66 | carrier := U |
| 67 | carrier_open := (isOpen_Ioo.preimage continuous_norm) |
| 68 | coordinate := f |
| 69 | inverse := inv |
| 70 | coordinate_image := ?_ |
| 71 | coordinate_left_inverse := ?_ |
| 72 | coordinate_right_inverse := hright |
| 73 | inverse_domain := hinv |
| 74 | coordinate_smooth := ?_ |
| 75 | inverse_smooth := ?_ |
| 76 | center_sphere := ⟨q₀, by simp [f]⟩ |
| 77 | } |
| 78 | · apply Subset.antisymm |
| 79 | · rintro x ⟨z, hz, rfl⟩ |
| 80 | change a - b * length < ‖f z‖ ∧ ‖f z‖ < a + b * length |
| 81 | rw [hnorm z hz.2] |
| 82 | constructor |
| 83 | · have h := mul_lt_mul_of_pos_left hz.2.1 hb |
| 84 | linarith |
| 85 | · have h := mul_lt_mul_of_pos_left hz.2.2 hb |
| 86 | linarith |
| 87 | · intro x hx |
| 88 | exact ⟨inv x, ⟨mem_univ _, hinv x hx⟩, hright x hx⟩ |
| 89 | · intro z hz |
| 90 | apply Prod.ext |
| 91 | · change (spherePolarMap q₀ ((a + b * z.2) • z.1.val)).1 = z.1 |
| 92 | rw [polar_positive_smul q₀ z.1 (hpos z hz.2)] |
| 93 | · change (‖f z‖ - a) / b = z.2 |
| 94 | rw [hnorm z hz.2] |
| 95 | field_simp [hb.ne'] |
| 96 | ring |
| 97 | · have hs : ContMDiff ((𝓡 2).prod 𝓘(ℝ, ℝ)) 𝓘(ℝ, ℝ) ∞ |
| 98 | (fun z : StandardCylinderSpace => a + b * z.2) := |
| 99 | ((contDiff_const.add (contDiff_const.mul contDiff_id)).contMDiff).comp contMDiff_snd |
| 100 | exact (hs.smul ((contMDiff_coe_sphere (n := 2) (E := StandardCapSpace)).comp |
| 101 | contMDiff_fst)).contMDiffOn |
| 102 | · intro x hx |
| 103 | have hn : 0 < ‖x‖ := hinner.trans hx.1 |
| 104 | have hne : x ≠ 0 := norm_pos_iff.mp hn |
| 105 | have hdir := (spherePolarMap_contMDiffAt q₀ hne).fst |
| 106 | have haxis : ContMDiffAt (𝓡 3) 𝓘(ℝ, ℝ) ∞ |
| 107 | (fun y : StandardCapSpace => (‖y‖ - a) / b) x := |
| 108 | (((contDiffAt_norm ℝ hne).sub contDiffAt_const).div_const b).contMDiffAt |
| 109 | exact (hdir.prodMk haxis).contMDiffWithinAt |
| 110 | |
| 111 | /-- Theorem 12.32, pp. 326-327: the central sphere is the literal Euclidean radial sphere. -/ |
| 112 | theorem radialAnnulusPatch_centralSphere (q₀ : UnitTwoSphere) (a b length : ℝ) |
| 113 | (hb : 0 < b) (hl : 0 < length) (hinner : 0 < a - b * length) : |
| 114 | (radialAnnulusPatch q₀ a b length hb hl hinner).centralSphere = Metric.sphere 0 a := by |
| 115 | have ha : 0 < a := by nlinarith [mul_pos hb hl] |
| 116 | ext x |
| 117 | change (∃ z : StandardCylinderSpace, z ∈ univ ×ˢ ({0} : Set ℝ) ∧ |
| 118 | (a + b * z.2) • z.1.val = x) ↔ x ∈ Metric.sphere 0 a |
| 119 | simp only [Prod.exists, mem_prod, mem_univ, mem_singleton_iff, true_and, |
| 120 | exists_eq_left, mul_zero, add_zero, Metric.mem_sphere, dist_zero_right] |
| 121 | constructor |
| 122 | · rintro ⟨q, rfl⟩ |
| 123 | rw [norm_smul, Real.norm_eq_abs, abs_of_pos ha, norm_eq_of_mem_sphere, mul_one] |
| 124 | · intro hx |
| 125 | let q : UnitTwoSphere := ⟨a⁻¹ • x, by |
| 126 | simp only [Metric.mem_sphere, dist_zero_right, norm_smul, Real.norm_eq_abs, |
| 127 | abs_inv, abs_of_pos ha, hx, inv_mul_cancel₀ ha.ne']⟩ |
| 128 | exact ⟨q, by simp only [q, smul_smul, mul_inv_cancel₀ ha.ne', one_smul]⟩ |
| 129 | |
| 130 | end PoincareMT.M35 |