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.Existence.Analysis.CanonicalGeometry.NeckDiagonalContraction |
| 2 | import PoincareLib.Geometry.RicciFlow.Surgery.StandardCap.Existence.Analysis.Coordinates.RoundCylinderJetErrorBound |
| 3 | |
| 4 | /-! |
| 5 | # Positivity and restriction of literal cylinder comparisons |
| 6 | |
| 7 | The exact inverse-Gram contractions are positive at the selected chart |
| 8 | centers for every model time below one. Their finite sum is therefore |
| 9 | monotone in derivative order. These are the smaller-neck comparison steps |
| 10 | in Morgan-Tian Theorem 12.28, pp. 323-324; see the task-local derivation |
| 11 | `strong-neck-persistence-implementation.md`. |
| 12 | -/ |
| 13 | |
| 14 | set_option autoImplicit false |
| 15 | |
| 16 | open scoped Manifold ContDiff BigOperators |
| 17 | |
| 18 | namespace PoincareMT.M34 |
| 19 | |
| 20 | local notation "E₂" => EuclideanSpace ℝ (Fin 2) |
| 21 | |
| 22 | /-- The exact squared cylinder norm is nonnegative at the selected chart |
| 23 | center whenever the evolving cylinder metric is positive definite. -/ |
| 24 | theorem roundCylinderTensorNormSquared_chart_center_nonneg |
| 25 | {u : ℝ} (hu : u < 1) (q : UnitTwoSphere) (s : ℝ) {r : ℕ} |
| 26 | (T : (Fin r → Fin 3) → ℝ) : |
| 27 | 0 ≤ roundCylinderTensorNormSquared u (chartAt E₂ q) (chartAt E₂ q q, s) T := by |
| 28 | unfold roundCylinderTensorNormSquared |
| 29 | rw [roundCylinderGram_chart_center_inv hu.ne q s] |
| 30 | apply diagonal_tensor_contraction_nonneg |
| 31 | intro i |
| 32 | fin_cases i |
| 33 | · exact inv_nonneg.mpr (mul_nonneg (by norm_num) (sub_nonneg.mpr hu.le)) |
| 34 | · exact inv_nonneg.mpr (mul_nonneg (by norm_num) (sub_nonneg.mpr hu.le)) |
| 35 | · norm_num |
| 36 | |
| 37 | /-- The frozen sum of squared covariant derivative errors is nonnegative |
| 38 | at every cylinder point and every model time below one. -/ |
| 39 | theorem roundCylinderJetErrorSquared_nonneg {u : ℝ} (hu : u < 1) |
| 40 | (B : RoundCylinderTwoTensor) (order : ℕ) (z : RoundCylinderSpace) : |
| 41 | 0 ≤ roundCylinderJetErrorSquared u B order z := by |
| 42 | unfold roundCylinderJetErrorSquared |
| 43 | exact Finset.sum_nonneg fun _ _ => |
| 44 | roundCylinderTensorNormSquared_chart_center_nonneg hu _ _ _ |
| 45 | |
| 46 | /-- Reducing the derivative order reduces the actual intrinsic cylinder |
| 47 | error. The positivity premise retains the model's genuine time domain. -/ |
| 48 | theorem roundCylinderJetErrorSquared_mono_order {u : ℝ} (hu : u < 1) |
| 49 | (B : RoundCylinderTwoTensor) {m n : ℕ} (hmn : m ≤ n) (z : RoundCylinderSpace) : |
| 50 | roundCylinderJetErrorSquared u B m z ≤ roundCylinderJetErrorSquared u B n z := by |
| 51 | unfold roundCylinderJetErrorSquared |
| 52 | apply Finset.sum_le_sum_of_subset_of_nonneg (Finset.range_mono (Nat.add_le_add_right hmn 1)) |
| 53 | intro k _ _ |
| 54 | exact roundCylinderTensorNormSquared_chart_center_nonneg hu _ _ _ |
| 55 | |
| 56 | /-- The literal array difference controls the increase of the squared |
| 57 | cylinder norm, without imposing any regularity on the arrays. -/ |
| 58 | theorem roundCylinderTensorNormSquared_chart_center_le |
| 59 | {u : ℝ} (hu : u < 1) (q : UnitTwoSphere) (s : ℝ) {r : ℕ} |
| 60 | (T S : (Fin r → Fin 3) → ℝ) : |
| 61 | roundCylinderTensorNormSquared u (chartAt E₂ q) (chartAt E₂ q q, s) T ≤ |
| 62 | 2 * roundCylinderTensorNormSquared u (chartAt E₂ q) (chartAt E₂ q q, s) S + |
| 63 | 2 * roundCylinderTensorNormSquared u (chartAt E₂ q) (chartAt E₂ q q, s) |
| 64 | (fun a => T a - S a) := by |
| 65 | unfold roundCylinderTensorNormSquared |
| 66 | rw [roundCylinderGram_chart_center_inv hu.ne q s] |
| 67 | apply diagonal_tensor_contraction_le |
| 68 | intro i |
| 69 | fin_cases i |
| 70 | · exact inv_nonneg.mpr (mul_nonneg (by norm_num) (sub_nonneg.mpr hu.le)) |
| 71 | · exact inv_nonneg.mpr (mul_nonneg (by norm_num) (sub_nonneg.mpr hu.le)) |
| 72 | · norm_num |
| 73 | |
| 74 | /-- The frozen squared jet error obeys the squared triangle estimate, |
| 75 | with the difference of the actual recursively defined derivative arrays. -/ |
| 76 | theorem roundCylinderJetErrorSquared_le_two_mul |
| 77 | {u : ℝ} (hu : u < 1) (B D : RoundCylinderTwoTensor) |
| 78 | (order : ℕ) (z : RoundCylinderSpace) : |
| 79 | roundCylinderJetErrorSquared u B order z ≤ |
| 80 | 2 * roundCylinderJetErrorSquared u D order z + |
| 81 | 2 * ∑ k ∈ Finset.range (order + 1), |
| 82 | roundCylinderTensorNormSquared u (chartAt E₂ z.1) (chartAt E₂ z.1 z.1, z.2) |
| 83 | (fun a => |
| 84 | roundCylinderIteratedDerivative u (chartAt E₂ z.1) B k |
| 85 | (chartAt E₂ z.1 z.1, z.2) a - |
| 86 | roundCylinderIteratedDerivative u (chartAt E₂ z.1) D k |
| 87 | (chartAt E₂ z.1 z.1, z.2) a) := by |
| 88 | unfold roundCylinderJetErrorSquared |
| 89 | rw [Finset.mul_sum, Finset.mul_sum, ← Finset.sum_add_distrib] |
| 90 | exact Finset.sum_le_sum fun _ _ => |
| 91 | roundCylinderTensorNormSquared_chart_center_le hu _ _ _ _ |
| 92 | |
| 93 | end PoincareMT.M34 |
| 94 | |
| 95 | namespace PoincareMT |
| 96 | |
| 97 | /-- Shortening the axial interval retains all coefficient smoothness |
| 98 | conditions of the literal cylinder comparison. -/ |
| 99 | theorem RoundCylinderTensorSmoothOn.mono_epsilon {delta epsilon : ℝ} |
| 100 | (hdelta : 0 < delta) (hde : delta ≤ epsilon) {B : RoundCylinderTwoTensor} |
| 101 | (hB : RoundCylinderTensorSmoothOn delta B) : |
| 102 | RoundCylinderTensorSmoothOn epsilon B := by |
| 103 | have hinv : epsilon⁻¹ ≤ delta⁻¹ := inv_anti₀ hdelta hde |
| 104 | intro q a b |
| 105 | exact (hB q a b).mono fun p hp => |
| 106 | ⟨hp.1, lt_of_le_of_lt (neg_le_neg hinv) hp.2.1, hp.2.2.trans_le hinv⟩ |
| 107 | |
| 108 | /-- A more accurate neck is a shorter, weaker neck for the same tensor |
| 109 | at every nonsingular model time. The original uniform bound is retained. -/ |
| 110 | theorem RoundCylinderClose.mono_epsilon {delta epsilon u : ℝ} |
| 111 | (hdelta : 0 < delta) (hde : delta ≤ epsilon) (hu : u < 1) |
| 112 | {B : RoundCylinderTwoTensor} (hB : RoundCylinderClose delta u B) : |
| 113 | RoundCylinderClose epsilon u B := by |
| 114 | obtain ⟨hsmooth, b, hb, hjet⟩ := hB |
| 115 | have hinv : epsilon⁻¹ ≤ delta⁻¹ := inv_anti₀ hdelta hde |
| 116 | refine ⟨hsmooth.mono_epsilon hdelta hde, b, |
| 117 | hb.trans_le (pow_le_pow_left₀ hdelta.le hde 2), ?_⟩ |
| 118 | intro z hz |
| 119 | exact (M34.roundCylinderJetErrorSquared_mono_order hu B |
| 120 | (Nat.floor_mono hinv) z).trans (hjet z |
| 121 | ⟨lt_of_le_of_lt (neg_le_neg hinv) hz.1, hz.2.trans_le hinv⟩) |
| 122 | |
| 123 | /-- One common strict family bound survives an increase of epsilon, |
| 124 | provided all its model times precede the cylinder singular time. -/ |
| 125 | theorem RoundCylinderFamilyClose.mono_epsilon {delta epsilon : ℝ} |
| 126 | (hdelta : 0 < delta) (hde : delta ≤ epsilon) {I : Set ℝ} |
| 127 | (hI : ∀ u ∈ I, u < 1) {B : ℝ → RoundCylinderTwoTensor} |
| 128 | (hB : RoundCylinderFamilyClose delta I B) : |
| 129 | RoundCylinderFamilyClose epsilon I B := by |
| 130 | obtain ⟨hsmooth, b, hb, hjet⟩ := hB |
| 131 | have hinv : epsilon⁻¹ ≤ delta⁻¹ := inv_anti₀ hdelta hde |
| 132 | refine ⟨fun u hu => (hsmooth u hu).mono_epsilon hdelta hde, b, |
| 133 | hb.trans_le (pow_le_pow_left₀ hdelta.le hde 2), ?_⟩ |
| 134 | intro u hu z hz |
| 135 | exact (M34.roundCylinderJetErrorSquared_mono_order (hI u hu) (B u) |
| 136 | (Nat.floor_mono hinv) z).trans (hjet u hu z |
| 137 | ⟨lt_of_le_of_lt (neg_le_neg hinv) hz.1, hz.2.trans_le hinv⟩) |
| 138 | |
| 139 | end PoincareMT |