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.Curvature.Integral.Concentration.ScalarAnnuli |
| 2 | |
| 3 | /-! |
| 4 | # Concentration from finitely many annular estimates |
| 5 | |
| 6 | The scalar annular bounds give the complement estimate used by finite-center |
| 7 | concentration, including centers whose critical radius is zero. |
| 8 | -/ |
| 9 | |
| 10 | noncomputable section |
| 11 | set_option autoImplicit false |
| 12 | |
| 13 | open Set MeasureTheory |
| 14 | open scoped Manifold ContDiff Bundle Topology BigOperators |
| 15 | |
| 16 | namespace PoincareMT.LeviCivitaData |
| 17 | |
| 18 | /-- A finite outer-ball cover and actual annular scalar bounds control the |
| 19 | positive scalar integral outside the corresponding critical balls. -/ |
| 20 | theorem integral_scalarCurvature_posPart_outside_iUnion_ball_le_of_scale_annuli |
| 21 | {n : ℕ} {M : Type*} [TopologicalSpace M] |
| 22 | [MeasurableSpace M] [BorelSpace M] [T3Space M] [PreconnectedSpace M] |
| 23 | [ChartedSpace (EuclideanSpace ℝ (Fin n)) M] [IsManifold (𝓡 n) ∞ M] |
| 24 | {g : RiemannianMetric n M} (D : LeviCivitaData g) |
| 25 | (hn : 0 < n) (hcomplete : MetricComplete g) (p : M) |
| 26 | {ι : Type*} [Fintype ι] (q : ι → M) (a r₀ R C : ι → ℝ) {m : ℕ} |
| 27 | (ha : ∀ i, 0 ≤ a i) (hr₀ : ∀ i, 0 < r₀ i) |
| 28 | (hR : ∀ i, R i < 19 * r₀ i / 16) (hC : ∀ i, 0 ≤ C i) (hm : 1 ≤ m) |
| 29 | (hcover : g.ball p 1 ⊆ ⋃ i, g.ball (q i) (R i)) |
| 30 | (hbound : ∀ i, ∀ r : ℝ, 0 < r → 2 * a i ≤ r → r ≤ r₀ i → |
| 31 | (∫ x in {x : M | (g.edist (q i) x).toReal ∈ Icc (113 * r / 96) (19 * r / 16)}, |
| 32 | max 0 (D.scalarCurvature x) ∂g.volumeMeasure) ≤ C i * r ^ m) : |
| 33 | (∫ x in g.ball p 1 \ ⋃ i, g.ball (q i) (4 * a i), |
| 34 | max 0 (D.scalarCurvature x) ∂g.volumeMeasure) ≤ |
| 35 | ∑ i, C i * r₀ i ^ m / (1 - (227 / 228 : ℝ) ^ m) := by |
| 36 | classical |
| 37 | let : ConnectedSpace M := { toNonempty := ⟨p⟩ } |
| 38 | let := g.toMetricSpace |
| 39 | let E := g.ball p 1 \ ⋃ i, g.ball (q i) (4 * a i) |
| 40 | let B := fun i => g.ball (q i) (R i) \ g.ball (q i) (4 * a i) |
| 41 | let h : M → ℝ := fun x => max 0 (D.scalarCurvature x) |
| 42 | have hmeas (x : M) (r : ℝ) : MeasurableSet (g.ball x r) := by |
| 43 | rw [← g.toMetricSpace_ball] |
| 44 | exact Metric.isOpen_ball.measurableSet |
| 45 | have hcont : Continuous h := continuous_const.max D.continuous_scalarCurvature |
| 46 | have hEm : MeasurableSet E := (hmeas p 1).diff |
| 47 | (MeasurableSet.iUnion (fun i => hmeas (q i) (4 * a i))) |
| 48 | have hBm (i : ι) : MeasurableSet (B i) := |
| 49 | (hmeas (q i) (R i)).diff (hmeas (q i) (4 * a i)) |
| 50 | have hEi : IntegrableOn h E g.volumeMeasure := |
| 51 | (g.integrableOn_ball_of_continuous hcomplete hcont p 1).mono_set sdiff_subset |
| 52 | have hBi (i : ι) : IntegrableOn h (B i) g.volumeMeasure := |
| 53 | (g.integrableOn_ball_of_continuous hcomplete hcont (q i) (R i)).mono_set sdiff_subset |
| 54 | have hEB : E ⊆ ⋃ i ∈ (Finset.univ : Finset ι), B i := by |
| 55 | intro x hx |
| 56 | obtain ⟨i, hi⟩ := mem_iUnion.mp (hcover hx.1) |
| 57 | refine mem_iUnion₂.mpr ⟨i, Finset.mem_univ _, hi, ?_⟩ |
| 58 | exact fun hb => hx.2 (mem_iUnion.mpr ⟨i, hb⟩) |
| 59 | apply (Poincare.CurvatureIntegral.integral_le_sum_of_finset_cover hEm |
| 60 | Finset.univ B (fun i _ => hBm i) (fun _ => le_max_left _ _) hEi |
| 61 | (fun i _ => hBi i) hEB).trans |
| 62 | exact Finset.sum_le_sum (fun i _ => |
| 63 | D.integral_scalarCurvature_posPart_outside_ball_le_of_nonneg_scale_annuli |
| 64 | hn hcomplete (q i) (ha i) (hr₀ i) (hR i) (hC i) hm (hbound i)) |
| 65 | |
| 66 | end PoincareMT.LeviCivitaData |