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.Manifold.Circle.FlatCharts |
| 2 | import PoincareLib.Geometry.Manifold.LocalDiffeomorph |
| 3 | import PoincareLib.Topology.Manifold.NeckCap.Fibration.Quotient.Circle |
| 4 | |
| 5 | /-! |
| 6 | # Additive quotient circles and the Euclidean unit circle |
| 7 | |
| 8 | The standard exponential identifies a positive-period additive circle with |
| 9 | the unit sphere in Euclidean two-space. For any smooth atlas in which the |
| 10 | real quotient map is a local diffeomorphism, this identification is a smooth |
| 11 | diffeomorphism. |
| 12 | -/ |
| 13 | |
| 14 | noncomputable section |
| 15 | set_option autoImplicit false |
| 16 | set_option backward.isDefEq.respectTransparency false |
| 17 | |
| 18 | open Set Function |
| 19 | open scoped Manifold ContDiff |
| 20 | |
| 21 | namespace AddCircle |
| 22 | |
| 23 | private abbrev E1 := EuclideanSpace Real (Fin 1) |
| 24 | private abbrev S1 := Metric.sphere (0 : EuclideanSpace Real (Fin 2)) 1 |
| 25 | |
| 26 | /-- The canonical topological identification with the Euclidean unit circle. -/ |
| 27 | def unitSphereHomeomorph {T : Real} (hT : 0 < T) : AddCircle T ≃ₜ S1 := |
| 28 | (homeomorphCircle hT.ne').trans PoincareMT.complexCircleDiffeomorph.toHomeomorph |
| 29 | |
| 30 | @[simp] |
| 31 | theorem unitSphereHomeomorph_apply_coe {T : Real} (hT : 0 < T) (t : Real) : |
| 32 | unitSphereHomeomorph hT (t : AddCircle T) = PoincareMT.unitCircleExp (t / T) := by |
| 33 | change PoincareMT.complexCircleDiffeomorph (homeomorphCircle hT.ne' (t : AddCircle T)) = _ |
| 34 | rw [homeomorphCircle_apply, toCircle_apply_mk] |
| 35 | unfold PoincareMT.unitCircleExp |
| 36 | congr 2 |
| 37 | ring |
| 38 | |
| 39 | /-- Smoothness of the quotient and its local inverse transfers the standard |
| 40 | exponential's local diffeomorphism property to any compatible circle atlas. -/ |
| 41 | theorem isLocalDiffeomorph_unitSphereHomeomorph |
| 42 | {T : Real} (hT : 0 < T) [ChartedSpace E1 (AddCircle T)] |
| 43 | (hq : IsLocalDiffeomorph 𝓘(Real, Real) (𝓡 1) ∞ |
| 44 | (fun t : Real => (t : AddCircle T))) : |
| 45 | IsLocalDiffeomorph (𝓡 1) (𝓡 1) ∞ (unitSphereHomeomorph hT) := by |
| 46 | let A : Diffeomorph 𝓘(Real, Real) 𝓘(Real, Real) Real Real ∞ := { |
| 47 | toEquiv := Equiv.mulRight₀ T⁻¹ (inv_ne_zero hT.ne') |
| 48 | contMDiff_toFun := (contDiff_id.mul contDiff_const).contMDiff |
| 49 | contMDiff_invFun := (contDiff_id.mul contDiff_const).contMDiff } |
| 50 | intro q |
| 51 | obtain ⟨t, rfl⟩ := QuotientAddGroup.mk_surjective q |
| 52 | apply (hq t).of_comp |
| 53 | have h := (A.isLocalDiffeomorph t).comp (𝓡 1) S1 |
| 54 | (PoincareMT.isLocalDiffeomorph_unitCircleExp (A t)) |
| 55 | have heq : (unitSphereHomeomorph hT) ∘ (fun s : Real => (s : AddCircle T)) = |
| 56 | PoincareMT.unitCircleExp ∘ A := by |
| 57 | funext s |
| 58 | simp only [comp_apply, unitSphereHomeomorph_apply_coe] |
| 59 | rfl |
| 60 | rw [heq] |
| 61 | exact h |
| 62 | |
| 63 | /-- The positive-period quotient circle with any atlas making its quotient |
| 64 | map a local diffeomorphism is diffeomorphic to the standard unit circle. -/ |
| 65 | def unitSphereDiffeomorph |
| 66 | {T : Real} (hT : 0 < T) [ChartedSpace E1 (AddCircle T)] |
| 67 | (hq : IsLocalDiffeomorph 𝓘(Real, Real) (𝓡 1) ∞ |
| 68 | (fun t : Real => (t : AddCircle T))) : |
| 69 | Diffeomorph (𝓡 1) (𝓡 1) (AddCircle T) S1 ∞ := |
| 70 | (isLocalDiffeomorph_unitSphereHomeomorph hT hq).diffeomorphOfBijective |
| 71 | (unitSphereHomeomorph hT).bijective |
| 72 | |
| 73 | @[simp] |
| 74 | theorem unitSphereDiffeomorph_apply_coe |
| 75 | {T : Real} (hT : 0 < T) [ChartedSpace E1 (AddCircle T)] |
| 76 | (hq : IsLocalDiffeomorph 𝓘(Real, Real) (𝓡 1) ∞ |
| 77 | (fun t : Real => (t : AddCircle T))) (t : Real) : |
| 78 | unitSphereDiffeomorph hT hq (t : AddCircle T) = PoincareMT.unitCircleExp (t / T) := |
| 79 | unitSphereHomeomorph_apply_coe hT t |
| 80 | |
| 81 | end AddCircle |