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.Spacetime.Product.Frame |
| 2 | |
| 3 | /-! |
| 4 | # Actual fixed-time slices of spacetime |
| 5 | |
| 6 | The fixed-time inclusion has the actual horizontal differential. Scalar |
| 7 | chain rules and smooth spatial sections therefore restrict to the genuine |
| 8 | spatial slices, as in MT2015Correction equation (0.1), p. 2. |
| 9 | -/ |
| 10 | |
| 11 | set_option autoImplicit false |
| 12 | set_option backward.isDefEq.respectTransparency false |
| 13 | |
| 14 | open scoped Manifold ContDiff Bundle |
| 15 | |
| 16 | namespace PoincareMT.M62.SpacetimeCharts |
| 17 | |
| 18 | variable {n : ℕ} {M : Type*} [TopologicalSpace M] |
| 19 | [ChartedSpace (EuclideanSpace ℝ (Fin n)) M] [IsManifold (𝓡 n) ∞ M] |
| 20 | {a b : ℝ} |
| 21 | |
| 22 | /-- Each actual fixed-time slice is smooth; MT2015Correction (0.1), p. 2. -/ |
| 23 | theorem contMDiff_space_slice (C : SpacetimeCharts n M a b) |
| 24 | (t : OpenTime a b) : |
| 25 | ContMDiff (M' := C.Point) (𝓡 n) (𝓡 (n + 1)) ∞ (fun p : M => (p, t)) := by |
| 26 | let := C.chartedSpace |
| 27 | exact C.from_product_smooth.comp (contMDiff_id.prodMk contMDiff_const) |
| 28 | |
| 29 | /-- The slice differential is the frozen horizontal lift; |
| 30 | MT2015Correction (0.1), p. 2. -/ |
| 31 | theorem mfderiv_space_slice (C : SpacetimeCharts n M a b) |
| 32 | (t : OpenTime a b) (p : M) (V : TangentSpace (𝓡 n) p) : |
| 33 | mfderiv (M' := C.Point) (𝓡 n) (𝓡 (n + 1)) (fun x : M => (x, t)) p V = |
| 34 | C.horizontal (p, t) V := by |
| 35 | let := C.chartedSpace |
| 36 | have h := mfderiv_comp_apply |
| 37 | (I := 𝓡 n) (I' := (𝓡 n).prod 𝓘(ℝ, ℝ)) (I'' := 𝓡 (n + 1)) |
| 38 | (f := fun x : M => ((x, t) : SpacetimeCarrier M a b)) |
| 39 | (g := (id : SpacetimeCarrier M a b → C.Point)) p |
| 40 | (C.from_product_smooth.mdifferentiableAt (by simp)) |
| 41 | (mdifferentiableAt_id.prodMk mdifferentiableAt_const) V |
| 42 | erw [mfderiv_prodMk mdifferentiableAt_id mdifferentiableAt_const] at h |
| 43 | apply (C.split (p, t)).injective |
| 44 | change C.split (p, t) |
| 45 | (mfderiv (𝓡 n) (𝓡 (n + 1)) (id ∘ fun x : M => ((x, t) : |
| 46 | SpacetimeCarrier M a b)) p V) = _ |
| 47 | rw [h] |
| 48 | erw [C.split_mfderiv_from_product] |
| 49 | simp [horizontal, mfderiv_id, mfderiv_const] |
| 50 | rfl |
| 51 | |
| 52 | /-- Horizontal scalar differentiation agrees with differentiation on the |
| 53 | actual fixed-time slice; MT2015Correction (0.1), p. 2. -/ |
| 54 | theorem mvfderiv_space_slice (C : SpacetimeCharts n M a b) |
| 55 | (f : C.Point → ℝ) (q : C.Point) |
| 56 | (hf : MDifferentiableAt (𝓡 (n + 1)) 𝓘(ℝ, ℝ) f q) |
| 57 | (V : TangentSpace (𝓡 n) q.1) : |
| 58 | mvfderiv (𝓡 (n + 1)) f q (C.horizontal q V) = |
| 59 | mvfderiv (𝓡 n) (fun p => f (p, q.2)) q.1 V := by |
| 60 | let := C.chartedSpace |
| 61 | have h := mfderiv_comp_apply (f := fun p : M => ((p, q.2) : C.Point)) |
| 62 | (g := f) q.1 hf ((C.contMDiff_space_slice q.2).mdifferentiableAt (by simp)) V |
| 63 | rw [C.mfderiv_space_slice] at h |
| 64 | exact h.symm |
| 65 | |
| 66 | /-- A smooth lifted spatial field is smooth on every actual spatial slice; |
| 67 | MT2015Correction (0.1), p. 2. -/ |
| 68 | theorem liftSpatialField_slice_smooth (C : SpacetimeCharts n M a b) |
| 69 | (B : ℝ → (p : M) → TangentSpace (𝓡 n) p) |
| 70 | (hB : C.IsSmoothField (C.liftSpatialField B)) (t : OpenTime a b) : |
| 71 | ContMDiff (𝓡 n) (𝓡 n).tangent ∞ (T% (B t)) := by |
| 72 | have h := (C.liftSpatialField_smooth_iff B).mp hB |
| 73 | exact h.comp (contMDiff_id.prodMk (contMDiff_const (c := t))) |
| 74 | |
| 75 | /-- A smooth lifted section germ restricts to the actual spatial section |
| 76 | germ; MT2015Correction (0.1), p. 2. -/ |
| 77 | theorem liftSpatialField_slice_smoothAt (C : SpacetimeCharts n M a b) |
| 78 | (B : ℝ → (p : M) → TangentSpace (𝓡 n) p) (q : C.Point) |
| 79 | (hB : ContMDiffAt (𝓡 (n + 1)) (𝓡 (n + 1)).tangent ∞ |
| 80 | (T% (C.liftSpatialField B)) q) : |
| 81 | ContMDiffAt (𝓡 n) (𝓡 n).tangent ∞ (T% (B q.2)) q.1 := by |
| 82 | let := C.chartedSpace |
| 83 | have h := ((C.contMDiff_space.contMDiff_tangentMap (m := ∞) (by simp)).contMDiffAt.comp |
| 84 | q hB).comp q.1 (C.contMDiff_space_slice q.2 q.1) |
| 85 | apply h.congr_of_eventuallyEq |
| 86 | filter_upwards [] with p |
| 87 | dsimp only [Function.comp_apply, tangentMap] |
| 88 | rw [Bundle.TotalSpace.mk_inj] |
| 89 | symm |
| 90 | change mfderiv (𝓡 (n + 1)) (𝓡 n) (Prod.fst : C.Point → M) (p, q.2) |
| 91 | (C.horizontal (p, q.2) (B q.2 p)) = B q.2 p |
| 92 | rw [← C.split_space] |
| 93 | exact congrArg Prod.fst ((C.split (p, q.2)).apply_symm_apply (B q.2 p, 0)) |
| 94 | |
| 95 | end PoincareMT.M62.SpacetimeCharts |