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.MeasureTheory.Integral.DominatedConvergence |
| 2 | import Mathlib.MeasureTheory.Measure.OpenPos |
| 3 | import Mathlib.Analysis.SpecificLimits.Basic |
| 4 | |
| 5 | /-! |
| 6 | # Compact uniform approximation paired against an actual L1 field |
| 7 | |
| 8 | The compact bound and uniform error give one integrable dominating |
| 9 | function after any measurable pullback into the compact set. |
| 10 | Source: dominated convergence; M64 boundary semicircle assembly. |
| 11 | |
| 12 | Morgan--Tian context: Lemma 19.15, printed pp. 447-449. This project analytic helper |
| 13 | supports the actual annular minimizer and boundary regularity construction. |
| 14 | -/ |
| 15 | |
| 16 | noncomputable section |
| 17 | set_option autoImplicit false |
| 18 | set_option warningAsError true |
| 19 | |
| 20 | open Set Filter MeasureTheory |
| 21 | open scoped Topology |
| 22 | |
| 23 | namespace PoincareMT |
| 24 | |
| 25 | /-- Uniform geometric error on a compact set passes through every measurable pullback and |
| 26 | actual L1 scalar pairing. Source: dominated convergence, used in the M64 boundary semicircle |
| 27 | assembly derivation. Source/construction: |
| 28 | proof-work/tasks/M64/derivations/2026-09-26-boundary-semicircle-assembly.md. -/ |
| 29 | theorem m64CompactUniform_integral_pairing_tendsto |
| 30 | {X Y : Type*} [MeasurableSpace X] [TopologicalSpace Y] |
| 31 | [MeasurableSpace Y] [BorelSpace Y] {mu : Measure X} |
| 32 | {K : Set Y} (hK : IsCompact K) {q : X → Y} (hq : Measurable q) |
| 33 | (hqK : ∀ᵐ x ∂mu, q x ∈ K) {w : X → ℝ} (hw : Integrable w mu) |
| 34 | {g : ℕ → Y → ℝ} {f : Y → ℝ} |
| 35 | (hg : ∀ j, Continuous (g j)) (hf : Continuous f) |
| 36 | (hclose : ∀ j, ∀ y ∈ K, dist (g j y) (f y) ≤ (1 / 2 : ℝ) ^ j) : |
| 37 | Tendsto (fun j => ∫ x, g j (q x) * w x ∂mu) atTop |
| 38 | (𝓝 (∫ x, f (q x) * w x ∂mu)) := by |
| 39 | obtain ⟨B, hB⟩ := hK.exists_bound_of_continuousOn hf.continuousOn |
| 40 | have hpow : Tendsto (fun j : ℕ => (1 / 2 : ℝ) ^ j) atTop (𝓝 0) := |
| 41 | tendsto_pow_atTop_nhds_zero_of_lt_one (by norm_num) (by norm_num) |
| 42 | apply tendsto_integral_of_dominated_convergence (fun x => (1 + B) * ‖w x‖) |
| 43 | · intro j |
| 44 | exact ((hg j).measurable.comp hq).aestronglyMeasurable.mul hw.aestronglyMeasurable |
| 45 | · exact hw.norm.const_mul (1 + B) |
| 46 | · intro j |
| 47 | filter_upwards [hqK] with x hx |
| 48 | rw [norm_mul] |
| 49 | apply mul_le_mul_of_nonneg_right _ (norm_nonneg _) |
| 50 | calc |
| 51 | ‖g j (q x)‖ ≤ ‖g j (q x) - f (q x)‖ + ‖f (q x)‖ := norm_le_norm_sub_add _ _ |
| 52 | _ ≤ (1 / 2 : ℝ) ^ j + B := add_le_add (by |
| 53 | simpa only [dist_eq_norm] using hclose j (q x) hx) (hB _ hx) |
| 54 | _ ≤ 1 + B := add_le_add |
| 55 | (pow_le_one₀ (by norm_num : (0 : ℝ) ≤ 1 / 2) (by norm_num) (n := j)) le_rfl |
| 56 | · filter_upwards [hqK] with x hx |
| 57 | have hdist : Tendsto (fun j => dist (g j (q x)) (f (q x))) atTop (𝓝 0) := |
| 58 | squeeze_zero (fun _ => dist_nonneg) (fun j => hclose j (q x) hx) hpow |
| 59 | exact (tendsto_iff_dist_tendsto_zero.mpr hdist).mul_const (w x) |
| 60 | |
| 61 | end PoincareMT |