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.Compactness.Ancient.Coordinates.Bounds |
| 2 | import PoincareLib.Geometry.RicciFlow.Harnack.Noncompact.CurvatureControl.Cylinders.Compactness |
| 3 | import PoincareLib.Analysis.Calculus.SmoothCompactness.Eventual |
| 4 | |
| 5 | /-! |
| 6 | # Uniform ancient-window bounds in one set of cylinder charts |
| 7 | |
| 8 | Every compact time set below the buffered terminal time lies in a finite |
| 9 | window on which a tail of the expanding cylinders satisfies M07. Extending |
| 10 | reference normal charts on that window supplies eventual smoothness, |
| 11 | positive ellipticity, and all spacetime jet bounds for the original shifted |
| 12 | metric family and the original chart maps. |
| 13 | |
| 14 | Reference: Kleiner--Lott, Corollary 44.1, pp. 2682--2683, and Appendix E, |
| 15 | pp. 2848--2849. |
| 16 | -/ |
| 17 | |
| 18 | set_option autoImplicit false |
| 19 | set_option backward.isDefEq.respectTransparency false |
| 20 | set_option synthInstance.maxHeartbeats 100000 |
| 21 | set_option maxSynthPendingDepth 12 |
| 22 | set_option maxHeartbeats 1000000 |
| 23 | |
| 24 | open Set Filter |
| 25 | open scoped Manifold ContDiff Bundle ENNReal Topology |
| 26 | |
| 27 | namespace PoincareMT.RicciFlow |
| 28 | |
| 29 | attribute [local instance] FlowCarrier.topologicalSpace FlowCarrier.measurableSpace |
| 30 | FlowCarrier.borelSpace FlowCarrier.chartedSpace FlowCarrier.isManifold |
| 31 | FlowCarrier.t2Space FlowCarrier.t3Space FlowCarrier.secondCountable |
| 32 | |
| 33 | /-- The actual expanding-cylinder hypotheses provide all analytic estimates |
| 34 | in any fixed reference normal charts, simultaneously on every compact ancient |
| 35 | time set. None of the reference chart maps depends on the selected time set. -/ |
| 36 | theorem eventually_referenceChart_estimates_of_expanding_cylinders |
| 37 | {m : ℕ} (hC : RicciFlowCurvatureTheory.{0}) (hm : 0 < m) |
| 38 | (C : ℕ → FlowCarrier.{0} (m + 1)) (J : ℕ → Set ℝ) |
| 39 | (F : ∀ k, RicciFlow (m + 1) (C k).carrier (J k)) |
| 40 | (p : ∀ k, (C k).carrier) (A L : ℕ → ℝ) |
| 41 | (hA : Tendsto A atTop atTop) (hL : Tendsto L atTop atTop) |
| 42 | (hJ : ∀ k, Icc (-A k) 0 ⊆ interior (J k)) |
| 43 | (hcomplete : ∀ k, ∀ t ∈ Icc (-A k) 0, MetricComplete ((F k).metric t)) |
| 44 | (hoperator : ∀ k, ∀ t ∈ Icc (-A k) 0, ∀ x : (C k).carrier, |
| 45 | ((F k).connection t).NonnegativeCurvatureOperator x) |
| 46 | (hscalar : ∀ k, ∀ t ∈ Icc (-A k) 0, |
| 47 | ∀ x ∈ ((F k).metric 0).ball (p k) (L k), |
| 48 | ((F k).connection t).scalarCurvature x ≤ 4) |
| 49 | {ν : ℝ} (hν : 0 < ν) |
| 50 | (hvolume : ∀ᶠ k in atTop, ENNReal.ofReal ν ≤ |
| 51 | ((F k).metric 0).volumeMeasure (((F k).metric 0).ball (p k) 1)) |
| 52 | {δ S' S r R ρ a b : ℝ} {N : ℕ} (hδ : 0 < δ) (hδone : δ < 1) |
| 53 | (hS : S' < 0 ∧ 0 < S) (hr : 0 < r) (hρ : 0 < ρ) |
| 54 | (hρR : 2 * ρ < R) (ha : 0 < a) (hb : 0 < b) |
| 55 | {I : Set ℝ} (hIcompact : IsCompact I) (hI : I ⊆ Iio δ) : |
| 56 | ∃ T' a' b' : ℝ, T' < 0 ∧ I ⊆ Ioo T' δ ∧ 0 < a' ∧ 0 < b' ∧ |
| 57 | (∀ᶠ k in atTop, |
| 58 | ∀ cover : NormalChartCover (fun t => (F k).metric (t - δ)) |
| 59 | (p k) S' S r R ρ a b N, |
| 60 | ∀ i, |
| 61 | ContDiffOn ℝ ∞ (fun z : ℝ × EuclideanSpace ℝ (Fin (m + 1)) => |
| 62 | ((F k).metric (z.1 - δ)).pullbackCoefficients (cover.chart i) z.2) |
| 63 | (Ioo T' δ ×ˢ Metric.ball 0 R) ∧ |
| 64 | ∀ t ∈ Ioo T' δ, ∀ x ∈ Metric.closedBall 0 (2 * ρ), ∀ v, |
| 65 | a' * ‖v‖ ^ 2 ≤ ((F k).metric (t - δ)).pullbackCoefficients |
| 66 | (cover.chart i) x v v ∧ |
| 67 | ((F k).metric (t - δ)).pullbackCoefficients (cover.chart i) x v v ≤ |
| 68 | b' * ‖v‖ ^ 2) ∧ |
| 69 | ∀ d : ℕ, ∃ B : ℝ, 0 ≤ B ∧ ∀ᶠ k in atTop, |
| 70 | ∀ cover : NormalChartCover (fun t => (F k).metric (t - δ)) |
| 71 | (p k) S' S r R ρ a b N, |
| 72 | ∀ i, ∀ t ∈ I, ∀ x ∈ Metric.closedBall 0 ρ, |
| 73 | ‖iteratedFDeriv ℝ d (fun z : ℝ × EuclideanSpace ℝ (Fin (m + 1)) => |
| 74 | ((F k).metric (z.1 - δ)).pullbackCoefficients (cover.chart i) z.2) |
| 75 | (t, x)‖ ≤ B := by |
| 76 | obtain ⟨l, hl⟩ := hIcompact.bddBelow |
| 77 | let q := min (-2) (l - δ - 1) |
| 78 | have hq : q ≤ -2 := min_le_left _ _ |
| 79 | have hqI : I ⊆ Ioo (q + δ) δ := by |
| 80 | intro t ht |
| 81 | refine ⟨?_, hI ht⟩ |
| 82 | have hqt : q ≤ l - δ - 1 := min_le_right _ _ |
| 83 | linarith [hl ht] |
| 84 | obtain ⟨j, hj⟩ := eventually_atTop.mp (hA.eventually_ge_atTop (-q)) |
| 85 | have hsub (k : ℕ) : Icc q 0 ⊆ Icc (-A (k + j)) 0 := |
| 86 | Icc_subset_Icc (by linarith [hj (k + j) (Nat.le_add_left j k)]) le_rfl |
| 87 | have hJj : ∀ k, Icc q 0 ⊆ interior (J (k + j)) := |
| 88 | fun k _ ht => hJ (k + j) (hsub k ht) |
| 89 | have htail : Tendsto (fun k : ℕ => k + j) atTop atTop := tendsto_add_atTop_nat j |
| 90 | obtain ⟨H, hHS⟩ := exists_pointedCompactnessHypotheses_of_terminal_cylinders |
| 91 | hC hm (fun k => C (k + j)) (fun k => J (k + j)) |
| 92 | (fun k => F (k + j)) (fun k => p (k + j)) (by linarith : q ≤ -1) |
| 93 | hδ hδone.le (by linarith) hJj |
| 94 | (fun k t ht => hcomplete (k + j) t (hsub k ht)) |
| 95 | (fun k t ht x => hoperator (k + j) t (hsub k ht) x) |
| 96 | (fun k => L (k + j)) (hL.comp htail) |
| 97 | (fun k t ht x hx => hscalar (k + j) t (hsub k ht) x hx) |
| 98 | hν (htail.eventually hvolume) |
| 99 | obtain ⟨a', b', ha', hb', helliptic⟩ := |
| 100 | H.eventually_referenceNormalChartCover_ellipticity hS (N := N) hr hρ hρR ha hb |
| 101 | have hsmooth := H.referenceNormalChartCover_contDiffOn (S' := S') (S := S) |
| 102 | (A := r) (R := R) (ρ := ρ) (a := a) (b := b) (N := N) |
| 103 | have hjets (d : ℕ) := H.eventually_referenceNormalChartCover_spacetime_jet_bound |
| 104 | hC.local_derivative_estimates hS hIcompact hqI (N := N) hr hρ hρR ha hb d |
| 105 | rcases H with ⟨hT, seq, hvol, hcompact, hspace, hall, hnoncollapse⟩ |
| 106 | dsimp only at hHS |
| 107 | subst seq |
| 108 | refine ⟨q + δ, a', b', by linarith, hqI, ha', hb', ?_, ?_⟩ |
| 109 | · rw [← map_add_atTop_eq_nat j] |
| 110 | apply eventually_map.mpr |
| 111 | filter_upwards [helliptic] with k hk |
| 112 | intro cover i |
| 113 | exact ⟨hsmooth k cover i, hk cover i⟩ |
| 114 | · intro d |
| 115 | obtain ⟨B, hB, hbound⟩ := hjets d |
| 116 | refine ⟨B, hB, ?_⟩ |
| 117 | rw [← map_add_atTop_eq_nat j] |
| 118 | exact eventually_map.mpr hbound |
| 119 | |
| 120 | /-- Selected reference charts satisfy the precise local smoothness, compact |
| 121 | jet, and positive quadratic-form estimates used by ancient coordinate |
| 122 | extraction. These conclusions hold for the original shifted source metrics. -/ |
| 123 | theorem referenceCharts_analytic_bounds_of_expanding_cylinders |
| 124 | {m : ℕ} (hC : RicciFlowCurvatureTheory.{0}) (hm : 0 < m) |
| 125 | (C : ℕ → FlowCarrier.{0} (m + 1)) (J : ℕ → Set ℝ) |
| 126 | (F : ∀ k, RicciFlow (m + 1) (C k).carrier (J k)) |
| 127 | (p : ∀ k, (C k).carrier) (A L : ℕ → ℝ) |
| 128 | (hA : Tendsto A atTop atTop) (hL : Tendsto L atTop atTop) |
| 129 | (hJ : ∀ k, Icc (-A k) 0 ⊆ interior (J k)) |
| 130 | (hcomplete : ∀ k, ∀ t ∈ Icc (-A k) 0, MetricComplete ((F k).metric t)) |
| 131 | (hoperator : ∀ k, ∀ t ∈ Icc (-A k) 0, ∀ x : (C k).carrier, |
| 132 | ((F k).connection t).NonnegativeCurvatureOperator x) |
| 133 | (hscalar : ∀ k, ∀ t ∈ Icc (-A k) 0, |
| 134 | ∀ x ∈ ((F k).metric 0).ball (p k) (L k), |
| 135 | ((F k).connection t).scalarCurvature x ≤ 4) |
| 136 | {ν : ℝ} (hν : 0 < ν) |
| 137 | (hvolume : ∀ᶠ k in atTop, ENNReal.ofReal ν ≤ |
| 138 | ((F k).metric 0).volumeMeasure (((F k).metric 0).ball (p k) 1)) |
| 139 | {δ S' S r R ρ a b : ℝ} {N : ℕ} (hδ : 0 < δ) (hδone : δ < 1) |
| 140 | (hS : S' < 0 ∧ 0 < S) (hr : 0 < r) (hρ : 0 < ρ) |
| 141 | (hρR : 2 * ρ < R) (ha : 0 < a) (hb : 0 < b) |
| 142 | (cover : ∀ k, NormalChartCover (fun t => (F k).metric (t - δ)) |
| 143 | (p k) S' S r R ρ a b N) : |
| 144 | ∀ i : Fin (N + 1), |
| 145 | Poincare.Analysis.Calculus.LocallyEventuallyContDiff |
| 146 | (Iio δ ×ˢ Metric.ball 0 ρ) |
| 147 | (fun k (z : ℝ × EuclideanSpace ℝ (Fin (m + 1))) => |
| 148 | ((F k).metric (z.1 - δ)).pullbackCoefficients ((cover k).chart i) z.2) ∧ |
| 149 | (∀ d : ℕ, ∀ K : Set (ℝ × EuclideanSpace ℝ (Fin (m + 1))), |
| 150 | IsCompact K → K ⊆ Iio δ ×ˢ Metric.ball 0 ρ → |
| 151 | ∃ B : ℝ, 0 ≤ B ∧ ∀ᶠ k in atTop, ∀ z ∈ K, |
| 152 | ‖iteratedFDeriv ℝ d (fun w : ℝ × EuclideanSpace ℝ (Fin (m + 1)) => |
| 153 | ((F k).metric (w.1 - δ)).pullbackCoefficients ((cover k).chart i) w.2) z‖ ≤ B) ∧ |
| 154 | (∀ t ∈ Iio δ, ∀ x ∈ Metric.ball 0 ρ, ∃ a' : ℝ, 0 < a' ∧ ∀ᶠ k in atTop, |
| 155 | ∀ v, a' * ‖v‖ ^ 2 ≤ ((F k).metric (t - δ)).pullbackCoefficients |
| 156 | ((cover k).chart i) x v v) := by |
| 157 | intro i |
| 158 | have estimates {I : Set ℝ} (hIcompact : IsCompact I) (hI : I ⊆ Iio δ) := |
| 159 | eventually_referenceChart_estimates_of_expanding_cylinders |
| 160 | hC hm C J F p A L hA hL hJ hcomplete hoperator hscalar hν hvolume |
| 161 | hδ hδone hS hr hρ hρR ha hb (N := N) hIcompact hI |
| 162 | refine ⟨?_, ?_, ?_⟩ |
| 163 | · intro K hK hKΩ |
| 164 | have hKI : Prod.fst '' K ⊆ Iio δ := by |
| 165 | rintro t ⟨z, hz, rfl⟩ |
| 166 | exact (hKΩ hz).1 |
| 167 | obtain ⟨T', a', b', hT', htime, ha', hb', hsmooth, _⟩ := |
| 168 | estimates (hK.image continuous_fst) hKI |
| 169 | filter_upwards [hsmooth] with k hk |
| 170 | refine ⟨Ioo T' δ ×ˢ Metric.ball 0 R, isOpen_Ioo.prod Metric.isOpen_ball, ?_, |
| 171 | (hk (cover k) i).1⟩ |
| 172 | intro z hz |
| 173 | exact ⟨htime (mem_image_of_mem Prod.fst hz), |
| 174 | Metric.ball_subset_ball (by linarith) (hKΩ hz).2⟩ |
| 175 | · intro d K hK hKΩ |
| 176 | have hKI : Prod.fst '' K ⊆ Iio δ := by |
| 177 | rintro t ⟨z, hz, rfl⟩ |
| 178 | exact (hKΩ hz).1 |
| 179 | obtain ⟨T', a', b', hT', htime, ha', hb', hsmooth, hjets⟩ := |
| 180 | estimates (hK.image continuous_fst) hKI |
| 181 | obtain ⟨B, hB, hbound⟩ := hjets d |
| 182 | refine ⟨B, hB, ?_⟩ |
| 183 | filter_upwards [hbound] with k hk |
| 184 | intro z hz |
| 185 | exact hk (cover k) i z.1 (mem_image_of_mem Prod.fst hz) z.2 |
| 186 | (Metric.ball_subset_closedBall (hKΩ hz).2) |
| 187 | · intro t ht x hx |
| 188 | obtain ⟨T', a', b', hT', htime, ha', hb', hbound, _⟩ := |
| 189 | estimates isCompact_singleton (singleton_subset_iff.mpr ht) |
| 190 | refine ⟨a', ha', ?_⟩ |
| 191 | filter_upwards [hbound] with k hk |
| 192 | intro v |
| 193 | exact ((hk (cover k) i).2 t (htime (mem_singleton t)) x |
| 194 | (Metric.closedBall_subset_closedBall (by linarith) |
| 195 | (Metric.ball_subset_closedBall hx)) v).1 |
| 196 | |
| 197 | end PoincareMT.RicciFlow |