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.Variation.IndexForm.PullbackLinearity |
| 2 | |
| 3 | /-! |
| 4 | # A zero actual field has zero covariant derivative |
| 5 | |
| 6 | Morgan-Tian Lemma 6.4, pp. 107-108. Affine linearity of the actual |
| 7 | pullback derivative forces every extension of a zero field to have |
| 8 | zero derivative, including closed endpoints with unique derivatives. |
| 9 | -/ |
| 10 | |
| 11 | set_option autoImplicit false |
| 12 | |
| 13 | open Set |
| 14 | open scoped Manifold |
| 15 | |
| 16 | universe u |
| 17 | |
| 18 | namespace PoincareMT.M14 |
| 19 | |
| 20 | variable {n : ℕ} {X : Type u} [TopologicalSpace X] {time : X → ℝ} |
| 21 | {I : SpacetimeInterval} {G : GeneralizedLGeometryTransport n X time I} |
| 22 | {γ : ℝ → G.Point} {J : Set ℝ} {Y : ∀ s, G.Horizontal (γ s)} |
| 23 | |
| 24 | /-- Every actual extension of a zero field has zero covariant |
| 25 | derivative along an arbitrary differentiable base curve, |
| 26 | Lemma 6.4, pp. 107-108. -/ |
| 27 | theorem horizontalCovariantDerivative_zero_field |
| 28 | (E : M14PullbackExtension G γ J Y) (hY : ∀ r ∈ J, Y r = 0) |
| 29 | {s : ℝ} (hs : s ∈ J) (hJ : UniqueDiffWithinAt ℝ J s) |
| 30 | (hγ : MDifferentiableWithinAt (𝓘(ℝ, ℝ)) (spacetimeModel n) γ J s) : |
| 31 | M14HorizontalCovariantDerivative G γ J Y E s = 0 := by |
| 32 | have h := horizontalCovariantDerivative_affine_congr E E E (1 : ℝ) |
| 33 | (fun r hr => by rw [hY r hr, smul_zero, add_zero]) hs hJ hγ |
| 34 | rw [one_smul] at h |
| 35 | exact add_left_cancel (h.symm.trans (add_zero _).symm) |
| 36 | |
| 37 | end PoincareMT.M14 |