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.Surgery.StandardCap.Existence.Noncollapsing.OrdinaryStableLength |
| 2 | import PoincareLib.Geometry.RicciFlow.Surgery.StandardCap.Existence.Analysis.Basic.FullMeasureOpenImage |
| 3 | |
| 4 | /-! |
| 5 | # Exact endpoint volume on an open ordinary stable set |
| 6 | |
| 7 | The actual slice identification carries an ordinary open region to the |
| 8 | retained slice. Full ordinary capture shows that its stable endpoint |
| 9 | preimage has exactly the original calibrated volume and reduced-length |
| 10 | bound. Source: Morgan-Tian Proposition 12.13, pp. 304-306. |
| 11 | -/ |
| 12 | |
| 13 | set_option autoImplicit false |
| 14 | |
| 15 | open Set MeasureTheory |
| 16 | open scoped Manifold ContDiff Bundle Topology |
| 17 | |
| 18 | universe u |
| 19 | |
| 20 | namespace PoincareMT.M34 |
| 21 | |
| 22 | variable {n : ℕ} {M : Type u} [TopologicalSpace M] |
| 23 | [ChartedSpace (EuclideanSpace ℝ (Fin n)) M] [IsManifold (𝓡 n) ∞ M] |
| 24 | [T3Space M] [ConnectedSpace M] [SecondCountableTopology M] |
| 25 | [MeasurableSpace M] [BorelSpace M] |
| 26 | {I : SpacetimeInterval} {F : RicciFlow n M I.domain} |
| 27 | |
| 28 | /-- An ordinary open region lifts to an open subset of the actual stable |
| 29 | carrier with the same endpoint volume and reduced-length bound |
| 30 | (Proposition 12.13, pp. 304-306). -/ |
| 31 | theorem ordinaryProduct_stable_open_volume |
| 32 | (R : OrdinaryProductRicciGeometry F.metric I) |
| 33 | (hRicci : IntrinsicGeneralizedRicciEquation R.leafwiseConnection) |
| 34 | {T taumax tau l0 : ℝ} (hT : T ∈ I.domain) |
| 35 | (out : M14OrdinaryCaptureOutput (ordinaryProductLGeometry R hRicci) M I |
| 36 | R.product.productCylinder R.product.productMetric F T taumax |
| 37 | (ordinaryProductCaptureData (I := I) (F := F) R hRicci hT taumax)) |
| 38 | {x : (ordinaryProductLGeometry R hRicci).Point} |
| 39 | (E : M14ExponentialFamily (ordinaryProductLGeometry R hRicci) T x) |
| 40 | (H : M14StableSet (ordinaryProductLGeometry R hRicci) T tau x E) |
| 41 | (hmax : tau < taumax) (hmem : T - tau ∈ I.domain) |
| 42 | {Omega : Set M} (hOmega : IsOpen Omega) |
| 43 | (hbound : ∀ y ∈ Omega, |
| 44 | reducedLength F T (ordinaryProductProjection R.product x) y tau ≤ l0) : |
| 45 | ∃ W : Set ((ordinaryProductLGeometry R hRicci).Horizontal x), |
| 46 | IsOpen W ∧ W ⊆ H.carrier ∧ |
| 47 | (∀ Z ∈ W, E.reduced_length Z (Real.sqrt tau) ≤ l0) ∧ |
| 48 | calibratedMetricVolume ((ordinaryProductLGeometry R hRicci).slices |
| 49 | (T - tau)).metricOnPoints (H.endpoint_slice_map '' W) = |
| 50 | calibratedMetricVolume (F.metric (T - tau)) Omega := by |
| 51 | let iota := R.product.sliceIdentification ⟨T - tau, hmem⟩ |
| 52 | let B := iota '' Omega |
| 53 | have hB : IsOpen B := iota.toHomeomorph.isOpenMap _ hOmega |
| 54 | have hx : x ∈ range R.product.productCylinder.toSpacetime := by |
| 55 | rw [ordinaryProductCylinder_range]; trivial |
| 56 | have hfull : calibratedMetricVolume |
| 57 | ((ordinaryProductLGeometry R hRicci).slices (T - tau)).metricOnPoints |
| 58 | (H.endpoint_slice_map '' H.carrier)ᶜ = 0 := by |
| 59 | have h := out.captured_stable_image_full_measure tau x E H hmax hx |
| 60 | simpa only [ordinaryProductCylinder_range, mem_univ, ofPred_true, |
| 61 | compl_eq_univ_sdiff] using h |
| 62 | obtain ⟨W, hW, hWH, hWB, hvol⟩ := exists_open_image_measure_eq H.carrier_open |
| 63 | H.endpoint_slice_continuous _ hfull hB |
| 64 | have hproj : ordinaryProductProjection R.product '' ((fun q => q.val) '' B) = Omega := by |
| 65 | change ordinaryProductProjection R.product '' |
| 66 | ((fun q => q.val) '' (iota '' Omega)) = Omega |
| 67 | rw [image_image, image_image] |
| 68 | have heq : (fun z => ordinaryProductProjection R.product (iota z).val) = id := by |
| 69 | funext z |
| 70 | rw [ordinaryProductProjection_eq, R.product.sliceIdentification_eq] |
| 71 | rfl |
| 72 | rw [heq, image_id] |
| 73 | have hBvol : calibratedMetricVolume |
| 74 | ((ordinaryProductLGeometry R hRicci).slices (T - tau)).metricOnPoints B = |
| 75 | calibratedMetricVolume (F.metric (T - tau)) Omega := by |
| 76 | have hc : (fun q => q.val) '' B ⊆ range R.product.productCylinder.toSpacetime := by |
| 77 | rw [ordinaryProductCylinder_range] |
| 78 | exact subset_univ _ |
| 79 | have h := out.captured_slice_measure_transport tau H.tau_pos hmax B hB.measurableSet hc |
| 80 | change calibratedMetricVolume |
| 81 | ((ordinaryProductLGeometry R hRicci).slices (T - tau)).metricOnPoints B = |
| 82 | calibratedMetricVolume (F.metric (T - tau)) |
| 83 | (ordinaryProductProjection R.product '' ((fun q => q.val) '' B)) at h |
| 84 | exact h.trans (congrArg _ hproj) |
| 85 | refine ⟨W, hW, hWH, ?_, hvol.trans hBvol⟩ |
| 86 | intro Z hZ |
| 87 | obtain ⟨y, hy, hey⟩ := hWB (mem_image_of_mem H.endpoint_slice_map hZ) |
| 88 | rw [ordinaryProduct_stable_reduced_length R hRicci hT out E H hmax.le Z (hWH hZ)] |
| 89 | have hp : ordinaryProductProjection R.product (H.endpoint_map Z) = y := by |
| 90 | rw [← H.endpoint_slice_map_val Z (hWH hZ), ← hey, |
| 91 | ordinaryProductProjection_eq, R.product.sliceIdentification_eq] |
| 92 | rw [hp] |
| 93 | exact hbound y hy |
| 94 | |
| 95 | end PoincareMT.M34 |