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.Generalized.ReducedGeometry.Calculus.Local.InitialFamilyNeighborhood |
| 2 | import PoincareLib.Geometry.RicciFlow.Generalized.ReducedGeometry.Variation.Coordinates.GaugeLift |
| 3 | |
| 4 | /-! |
| 5 | # A smooth initial gauge family with its prescribed constant initial lift |
| 6 | |
| 7 | Morgan-Tian Claim 6.20, p. 114. The cylinder's actual local inverse |
| 8 | at a prescribed initial preimage lifts a common smooth initial tube. |
| 9 | All initial parameters have that same exact lift at time zero. |
| 10 | -/ |
| 11 | |
| 12 | set_option autoImplicit false |
| 13 | |
| 14 | open Set Filter |
| 15 | open scoped Manifold ContDiff Topology |
| 16 | |
| 17 | universe u |
| 18 | |
| 19 | namespace PoincareMT.M14 |
| 20 | |
| 21 | variable {n : ℕ} {X : Type u} [TopologicalSpace X] {time : X → ℝ} |
| 22 | {I : SpacetimeInterval} {G : GeneralizedLGeometryTransport n X time I} |
| 23 | {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] |
| 24 | |
| 25 | /-- A family with common initial point has a smooth gauge lift on |
| 26 | a smaller positive initial tube whose initial value is the prescribed |
| 27 | covering preimage for every parameter, Claim 6.20, p. 114. -/ |
| 28 | theorem exists_smooth_initial_gaugeFamily |
| 29 | (b : G.gaugeCover.index) |
| 30 | (t₀ : (G.timeIntervals.interval (G.gaugeCover.interval b)).Point) |
| 31 | (x₀ : G.gaugeCover.spatial b) |
| 32 | {U : Set E} (hU : IsOpen U) {z₀ : E} (hz₀ : z₀ ∈ U) {S : ℝ} (hS : 0 < S) |
| 33 | (γ : E × ℝ → G.Point) |
| 34 | (hγ : ContMDiffOn ((𝓘(ℝ, E)).prod (𝓘(ℝ, ℝ))) (spacetimeModel n) ∞ γ |
| 35 | (U ×ˢ Icc 0 S)) |
| 36 | (hzero : ∀ A ∈ U, γ (A, 0) = (G.gaugeCover.cylinder b).toSpacetime (t₀, x₀)) : |
| 37 | ∃ V : Set E, IsOpen V ∧ z₀ ∈ V ∧ V ⊆ U ∧ ∃ d : ℝ, 0 < d ∧ d ≤ S ∧ |
| 38 | ∃ β : E × ℝ → (G.timeIntervals.interval (G.gaugeCover.interval b)).Point × |
| 39 | G.gaugeCover.spatial b, |
| 40 | ContMDiffOn ((𝓘(ℝ, E)).prod (𝓘(ℝ, ℝ))) (spacetimeModel n) ∞ β (V ×ˢ Icc 0 d) ∧ |
| 41 | (∀ z ∈ V ×ˢ Icc 0 d, (G.gaugeCover.cylinder b).toSpacetime (β z) = γ z) ∧ |
| 42 | (∀ z ∈ V ×ˢ Icc 0 d, (β z).1.val = G.spacetime.timeFunction (γ z)) ∧ |
| 43 | ∀ A ∈ V, β (A, 0) = (t₀, x₀) := by |
| 44 | let h := G.gaugeCover.local_diffeomorph b (t₀, x₀) |
| 45 | have hz : γ (z₀, 0) ∈ h.localInverse.source := by |
| 46 | rw [hzero z₀ hz₀] |
| 47 | exact h.localInverse_mem_source |
| 48 | have hnear : γ ⁻¹' h.localInverse.source ∈ 𝓝[U ×ˢ Icc 0 S] (z₀, 0) := |
| 49 | (hγ.continuousOn (z₀, 0) ⟨hz₀, le_rfl, hS.le⟩).preimage_mem_nhdsWithin |
| 50 | (h.localInverse_open_source.mem_nhds hz) |
| 51 | obtain ⟨V, hV, hzV, hVU, d, hd, hdS, hmap⟩ := |
| 52 | exists_open_initial_family_neighborhood hU hz₀ hS hnear |
| 53 | refine ⟨V, hV, hzV, hVU, d, hd, hdS, h.localInverse ∘ γ, |
| 54 | h.localInverse_contMDiffOn.comp |
| 55 | (hγ.mono (prod_mono hVU (Icc_subset_Icc le_rfl hdS))) hmap, ?_, ?_, ?_⟩ |
| 56 | · intro z hz |
| 57 | exact h.localInverse_right_inv (hmap hz) |
| 58 | · intro z hz |
| 59 | exact ((G.gaugeCover.cylinder b).time_eq (h.localInverse (γ z))).symm.trans |
| 60 | (congrArg G.spacetime.timeFunction (h.localInverse_right_inv (hmap hz))) |
| 61 | · intro A hA |
| 62 | change h.localInverse (γ (A, 0)) = (t₀, x₀) |
| 63 | rw [hzero A (hVU hA)] |
| 64 | exact h.localInverse_left_inv h.localInverse_mem_target |
| 65 | |
| 66 | end PoincareMT.M14 |