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.Control.Calibration |
| 2 | import PoincareLib.Geometry.RicciFlow.Surgery.Induction.EpochExtension.Calibration.HeightRestriction |
| 3 | |
| 4 | /-! |
| 5 | # Selecting surgery heights after the analytic coefficient |
| 6 | |
| 7 | The geometric calibration is unchanged. M32 supplies a new selector at the |
| 8 | chosen coefficient, restricted to the two existing surgery bounds. This |
| 9 | construction precedes all prefixes and flows and asserts no analytic estimate. |
| 10 | See `reviews/contracts/2026-09-15-analytic-selector-round1.md`. |
| 11 | -/ |
| 12 | |
| 13 | set_option autoImplicit false |
| 14 | |
| 15 | universe u |
| 16 | |
| 17 | namespace PoincareMT.RepairedControlledSchedulesData |
| 18 | |
| 19 | /-- Reselect the geometric height at a positive analytic coefficient, keeping |
| 20 | the exact standard geometry, geometric constants and initial seeds. -/ |
| 21 | noncomputable def recalibrateAnalytic |
| 22 | (S : RepairedControlledSchedulesData.{u}) (A : ℝ) (hA : 0 < A) : |
| 23 | RepairedControlledSchedulesData.{u} := by |
| 24 | let raw := Classical.choice (S.calibration.horn_selection A hA) |
| 25 | have hbound : 0 < S.constants.R₀ ^ (-1 / 2 : ℝ) := |
| 26 | Real.rpow_pos_of_pos S.constants.R₀_pos _ |
| 27 | let selected := raw.restrictHeight S.constants.delta₀ |
| 28 | (S.constants.R₀ ^ (-1 / 2 : ℝ)) S.constants.delta₀_pos hbound |
| 29 | let setup : SurgeryControlSetup S.constants := |
| 30 | { S.setup with |
| 31 | selector := selected.toCommonSurgeryScaleSelector |
| 32 | selector_delta := fun rho delta _ _ => |
| 33 | raw.restrictHeight_le_radius _ _ S.constants.delta₀_pos hbound rho delta } |
| 34 | exact { S with |
| 35 | setup := setup |
| 36 | calibration := { S.calibration with |
| 37 | analytic_constant := A |
| 38 | analytic_constant_pos := hA |
| 39 | horn_selector := selected |
| 40 | selector_eq := rfl |
| 41 | selector_initial_bound := |
| 42 | raw.restrictHeight_le_bound _ _ S.constants.delta₀_pos hbound _ _ } } |
| 43 | |
| 44 | theorem recalibrateAnalytic_constant |
| 45 | (S : RepairedControlledSchedulesData.{u}) (A : ℝ) (hA : 0 < A) : |
| 46 | (S.recalibrateAnalytic A hA).calibration.analytic_constant = A := rfl |
| 47 | |
| 48 | theorem recalibrateAnalytic_constants |
| 49 | (S : RepairedControlledSchedulesData.{u}) (A : ℝ) (hA : 0 < A) : |
| 50 | (S.recalibrateAnalytic A hA).constants = S.constants := rfl |
| 51 | |
| 52 | theorem recalibrateAnalytic_epsilon |
| 53 | (S : RepairedControlledSchedulesData.{u}) (A : ℝ) (hA : 0 < A) : |
| 54 | (S.recalibrateAnalytic A hA).setup.epsilon = S.setup.epsilon := rfl |
| 55 | |
| 56 | theorem recalibrateAnalytic_C |
| 57 | (S : RepairedControlledSchedulesData.{u}) (A : ℝ) (hA : 0 < A) : |
| 58 | (S.recalibrateAnalytic A hA).setup.C = S.setup.C := rfl |
| 59 | |
| 60 | theorem recalibrateAnalytic_kappa0 |
| 61 | (S : RepairedControlledSchedulesData.{u}) (A : ℝ) (hA : 0 < A) : |
| 62 | (S.recalibrateAnalytic A hA).kappa0 = S.kappa0 := rfl |
| 63 | |
| 64 | theorem recalibrateAnalytic_Delta0 |
| 65 | (S : RepairedControlledSchedulesData.{u}) (A : ℝ) (hA : 0 < A) : |
| 66 | (S.recalibrateAnalytic A hA).Delta0 = S.Delta0 := rfl |
| 67 | |
| 68 | theorem recalibrateAnalytic_standard_initial |
| 69 | (S : RepairedControlledSchedulesData.{u}) (A : ℝ) (hA : 0 < A) : |
| 70 | (S.recalibrateAnalytic A hA).standard_initial = S.standard_initial := rfl |
| 71 | |
| 72 | theorem recalibrateAnalytic_setup_standard_initial |
| 73 | (S : RepairedControlledSchedulesData.{u}) (A : ℝ) (hA : 0 < A) : |
| 74 | (S.recalibrateAnalytic A hA).setup.standard_initial = S.setup.standard_initial := rfl |
| 75 | |
| 76 | theorem recalibrateAnalytic_standard_flow |
| 77 | (S : RepairedControlledSchedulesData.{u}) (A : ℝ) (hA : 0 < A) : |
| 78 | (S.recalibrateAnalytic A hA).setup.standard_flow = S.setup.standard_flow := rfl |
| 79 | |
| 80 | theorem recalibrateAnalytic_cap_persistence |
| 81 | (S : RepairedControlledSchedulesData.{u}) (A : ℝ) (hA : 0 < A) : |
| 82 | (S.recalibrateAnalytic A hA).cap_persistence = S.cap_persistence := rfl |
| 83 | |
| 84 | theorem recalibrateAnalytic_appendixA |
| 85 | (S : RepairedControlledSchedulesData.{u}) (A : ℝ) (hA : 0 < A) : |
| 86 | (S.recalibrateAnalytic A hA).calibration.appendixA = S.calibration.appendixA := rfl |
| 87 | |
| 88 | theorem recalibrateAnalytic_common_epsilon |
| 89 | (S : RepairedControlledSchedulesData.{u}) (A : ℝ) (hA : 0 < A) : |
| 90 | (S.recalibrateAnalytic A hA).calibration.common_epsilon = |
| 91 | S.calibration.common_epsilon := rfl |
| 92 | |
| 93 | end PoincareMT.RepairedControlledSchedulesData |