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 | /- Adapted from Mapher `PoincareMT/Proofs/M03/FiniteCoordinateCutoffs.lean` at |
| 2 | f927d9e1f0810042766d3b5f64d3f4da02ee93cc. See |
| 3 | `references/ricci-flow/mapher/local-theory/port.json`. -/ |
| 4 | |
| 5 | import PoincareLib.Geometry.RicciFlow.Local.Energy.Localization.CoordinateCutoff |
| 6 | |
| 7 | /-! |
| 8 | # Finite coordinate cutoffs |
| 9 | |
| 10 | Preferred charts and compactness give finitely many inner balls covering the |
| 11 | manifold, with smooth scalar cutoffs supported inside the corresponding targets. |
| 12 | Derivation: proof-work/tasks/M03/reviews/finite-coordinate-cutoffs-derivation.md. |
| 13 | -/ |
| 14 | |
| 15 | set_option autoImplicit false |
| 16 | |
| 17 | open scoped ContDiff Topology |
| 18 | open Set |
| 19 | |
| 20 | universe u |
| 21 | |
| 22 | namespace PoincareMT.RicciFlow.Local |
| 23 | |
| 24 | theorem exists_finite_coordinate_cutoffs |
| 25 | {n : ℕ} {M : Type u} [TopologicalSpace M] |
| 26 | [ChartedSpace (EuclideanSpace ℝ (Fin n)) M] [CompactSpace M] : |
| 27 | ∃ (s : Finset M) (r R : M → ℝ) |
| 28 | (φ : M → EuclideanSpace ℝ (Fin n) → ℝ), |
| 29 | (∀ c ∈ s, |
| 30 | 0 < r c ∧ r c < R c ∧ |
| 31 | Metric.closedBall (chartAt (EuclideanSpace ℝ (Fin n)) c c) (R c) ⊆ |
| 32 | (chartAt (EuclideanSpace ℝ (Fin n)) c).target ∧ |
| 33 | ContDiff ℝ ∞ (φ c) ∧ HasCompactSupport (φ c) ∧ |
| 34 | (∀ z, φ c z ∈ Icc (0 : ℝ) 1) ∧ |
| 35 | EqOn (φ c) (fun _ => 1) |
| 36 | (Metric.closedBall (chartAt (EuclideanSpace ℝ (Fin n)) c c) (r c)) ∧ |
| 37 | tsupport (φ c) ⊆ |
| 38 | Metric.closedBall (chartAt (EuclideanSpace ℝ (Fin n)) c c) (R c) ∧ |
| 39 | IsCompact ((chartAt (EuclideanSpace ℝ (Fin n)) c).symm '' tsupport (φ c)) ∧ |
| 40 | (chartAt (EuclideanSpace ℝ (Fin n)) c).symm '' tsupport (φ c) ⊆ |
| 41 | (chartAt (EuclideanSpace ℝ (Fin n)) c).source) ∧ |
| 42 | ∀ x : M, ∃ c ∈ s, |
| 43 | x ∈ (chartAt (EuclideanSpace ℝ (Fin n)) c).source ∧ |
| 44 | chartAt (EuclideanSpace ℝ (Fin n)) c x ∈ |
| 45 | Metric.ball (chartAt (EuclideanSpace ℝ (Fin n)) c c) (r c) := by |
| 46 | classical |
| 47 | choose ε hε hεV using fun c : M => |
| 48 | Metric.mem_nhds_iff.mp (chart_target_mem_nhds (EuclideanSpace ℝ (Fin n)) c) |
| 49 | have hr (c : M) : 0 < ε c / 4 := div_pos (hε c) (by norm_num) |
| 50 | have hrR (c : M) : ε c / 4 < ε c / 2 := by linarith [hε c] |
| 51 | choose φ hφ hφc hφrange hφone hφsupp using fun c : M => |
| 52 | exists_smooth_coordinate_cutoff |
| 53 | (chartAt (EuclideanSpace ℝ (Fin n)) c c) (hr c) (hrR c) |
| 54 | let U : M → Set M := fun c => |
| 55 | (chartAt (EuclideanSpace ℝ (Fin n)) c).source ∩ |
| 56 | (chartAt (EuclideanSpace ℝ (Fin n)) c) ⁻¹' |
| 57 | Metric.ball (chartAt (EuclideanSpace ℝ (Fin n)) c c) (ε c / 4) |
| 58 | have hUo (c : M) : IsOpen (U c) := |
| 59 | (chartAt (EuclideanSpace ℝ (Fin n)) c).continuousOn.isOpen_inter_preimage |
| 60 | (chartAt (EuclideanSpace ℝ (Fin n)) c).open_source Metric.isOpen_ball |
| 61 | have hUcover : (univ : Set M) ⊆ ⋃ c, U c := by |
| 62 | intro x _ |
| 63 | exact mem_iUnion.mpr ⟨x, mem_chart_source _ x, Metric.mem_ball_self (hr x)⟩ |
| 64 | obtain ⟨s, hs⟩ := isCompact_univ.elim_finite_subcover U hUo hUcover |
| 65 | refine ⟨s, (fun c => ε c / 4), (fun c => ε c / 2), φ, ?_, ?_⟩ |
| 66 | · intro c _ |
| 67 | have houter : Metric.closedBall (chartAt (EuclideanSpace ℝ (Fin n)) c c) |
| 68 | (ε c / 2) ⊆ (chartAt (EuclideanSpace ℝ (Fin n)) c).target := |
| 69 | (Metric.closedBall_subset_ball (by linarith [hε c])).trans (hεV c) |
| 70 | have htarget := (hφsupp c).trans houter |
| 71 | refine ⟨hr c, hrR c, houter, hφ c, hφc c, hφrange c, hφone c, hφsupp c, ?_, ?_⟩ |
| 72 | · exact (hφc c).image_of_continuousOn |
| 73 | ((chartAt (EuclideanSpace ℝ (Fin n)) c).continuousOn_symm.mono htarget) |
| 74 | · rintro _ ⟨z, hz, rfl⟩ |
| 75 | exact (chartAt (EuclideanSpace ℝ (Fin n)) c).map_target (htarget hz) |
| 76 | · intro x |
| 77 | obtain ⟨c, hc⟩ := mem_iUnion.mp (hs (mem_univ x)) |
| 78 | obtain ⟨hcs, hx⟩ := mem_iUnion.mp hc |
| 79 | exact ⟨c, hcs, hx⟩ |
| 80 | |
| 81 | end PoincareMT.RicciFlow.Local |