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.CurveShortening.Comparison.IntrinsicComparison.Two.ArcCoveredBands |
| 2 | import PoincareLib.Geometry.CurveShortening.Comparison.IntrinsicComparison.Corner.FrontierLines |
| 3 | import PoincareLib.Topology.Surface.Triangulation.Regions.PolygonalCores |
| 4 | |
| 5 | /-! The exact polygonal residual mesh of an actual two-arc Jordan region. |
| 6 | |
| 7 | Context: Morgan--Tian Lemma 19.46, printed pp. 474-478; Proposition 19.35, printed pp. |
| 8 | 467-481. |
| 9 | -/ |
| 10 | |
| 11 | noncomputable section |
| 12 | set_option autoImplicit false |
| 13 | set_option backward.isDefEq.respectTransparency false |
| 14 | |
| 15 | open Set Filter |
| 16 | open scoped Topology ContDiff Manifold Matrix |
| 17 | open Poincare.Topology.Plane.Curves PoincareMT.Topology.Surface |
| 18 | open Poincare.Topology.Plane.Meshes ChartCircleArrangementVertexPatch |
| 19 | |
| 20 | namespace PoincareMT |
| 21 | |
| 22 | /-- Construct the two occupied corner families, original attached band chains and exact |
| 23 | residual mesh of the given two-arc Jordan region. Source/construction: |
| 24 | proof-work/tasks/M64/derivations/2026-09-25-two-arc-coordinate-triangulation.md, Existing |
| 25 | geometric construction. -/ |
| 26 | theorem m64Intrinsic_exists_two_arc_remainder_mesh |
| 27 | {alpha beta : ℝ → AnnulusCoordinates} (ha : ContDiff ℝ ∞ alpha) |
| 28 | (hb : ContDiff ℝ ∞ beta) {A B : ℝ} (hA : 0 < A) (hB : 0 < B) |
| 29 | (hai : InjOn alpha (Icc 0 A)) (hbi : InjOn beta (Icc 0 B)) |
| 30 | (hareg : ∀ t ∈ Ioo (0 : ℝ) A, deriv alpha t ≠ 0) |
| 31 | (hbreg : ∀ t ∈ Ioo (0 : ℝ) B, deriv beta t ≠ 0) |
| 32 | (hinter : (alpha '' Icc 0 A) ∩ (beta '' Icc 0 B) ⊆ {alpha 0, alpha A}) |
| 33 | (hbase : beta 0 = alpha 0) (hend : beta B = alpha A) |
| 34 | (hind0 : LinearIndependent ℝ |
| 35 | (![deriv alpha 0, deriv beta 0] : Fin 2 → AnnulusCoordinates)) |
| 36 | (hind1 : LinearIndependent ℝ |
| 37 | (![-deriv alpha A, -deriv beta B] : Fin 2 → AnnulusCoordinates)) |
| 38 | {U V : Set AnnulusCoordinates} (hU : IsOpen U) (hV : IsOpen V) |
| 39 | (hdisj : Disjoint U V) (hfU : frontier U = alpha '' Icc 0 A ∪ beta '' Icc 0 B) |
| 40 | (hfV : frontier V = frontier U) (hcompact : IsCompact (closure U)) : |
| 41 | ∃ (H : Bool → OpenPartialHomeomorph (ℝ × ℝ) AnnulusCoordinates) (r : Bool → ℝ) |
| 42 | (F : Bool → Bool × Bool → OpenPartialHomeomorph (ℝ × ℝ) AnnulusCoordinates) |
| 43 | (W : Bool → Set AnnulusCoordinates) (positive : Bool → Bool), |
| 44 | let C (e : Bool) (i : Bool × Bool) := |
| 45 | F e i '' {q : ℝ × ℝ | 0 ≤ q.1 ∧ 0 ≤ q.2 ∧ q.1 + q.2 ≤ r e} |
| 46 | let D (e : Bool) := ⋃ i, |
| 47 | ⋃ (_ : if positive e then i = (true, true) else i ≠ (true, true)), C e i |
| 48 | (∀ e : Bool, |
| 49 | 0 < r e ∧ r e ≤ min A B / 3 ∧ (0 : ℝ × ℝ) ∈ (H e).source ∧ |
| 50 | H e 0 = alpha (if e then A else 0) ∧ |
| 51 | ContDiffOn ℝ ∞ (H e) (H e).source ∧ ContDiffOn ℝ ∞ (H e).symm (H e).target ∧ |
| 52 | (∀ s : ℝ, H e (s, 0) = alpha (if e then A - s else s)) ∧ |
| 53 | (∀ s : ℝ, H e (0, s) = beta (if e then B - s else s)) ∧ |
| 54 | (∀ i : Bool × Bool, ∀ s ∈ Icc (0 : ℝ) (r e), |
| 55 | sectorParameterEquiv 0 i (s, 0) ∈ (H e).source ∧ |
| 56 | sectorParameterEquiv 0 i (0, s) ∈ (H e).source) ∧ |
| 57 | (∀ q ∈ (H e).source, H e q ∈ frontier U ↔ |
| 58 | (q.1 = 0 ∧ 0 ≤ q.2) ∨ (0 ≤ q.1 ∧ q.2 = 0)) ∧ |
| 59 | (∀ q ∈ (H e).source, H e q ∈ closure U ↔ |
| 60 | if positive e then 0 ≤ q.1 ∧ 0 ≤ q.2 else q.1 ≤ 0 ∨ q.2 ≤ 0) ∧ |
| 61 | (∀ i, |
| 62 | {q : ℝ × ℝ | 0 ≤ q.1 ∧ 0 ≤ q.2 ∧ q.1 + q.2 ≤ r e} ⊆ (F e i).source ∧ |
| 63 | (F e i).target ⊆ (H e).target ∧ |
| 64 | ContDiffOn ℝ ∞ (F e i) (F e i).source ∧ |
| 65 | ContDiffOn ℝ ∞ (F e i).symm (F e i).target ∧ |
| 66 | (∀ s ∈ Icc (0 : ℝ) (r e), F e i (s, 0) = H e (sectorParameterEquiv 0 i (s, 0))) ∧ |
| 67 | (∀ s ∈ Icc (0 : ℝ) (r e), F e i (0, s) = H e (sectorParameterEquiv 0 i (0, s))) ∧ |
| 68 | (∀ t : ℝ, F e i ((1 - t) * r e, t * r e) = |
| 69 | (1 - t) • F e i (r e, 0) + t • F e i (0, r e)) ∧ |
| 70 | C e i ⊆ H e '' ((H e).source ∩ (sectorParameterEquiv 0 i) '' |
| 71 | {q : ℝ × ℝ | 0 ≤ q.1 ∧ 0 ≤ q.2}) ∧ |
| 72 | C e i ∩ H e '' ((H e).source ∩ {q : ℝ × ℝ | q.1 = 0 ∨ q.2 = 0}) = |
| 73 | H e '' ((sectorParameterEquiv 0 i) '' |
| 74 | ((Icc (0 : ℝ) (r e) ×ˢ {0}) ∪ ({0} ×ˢ Icc (0 : ℝ) (r e))))) ∧ |
| 75 | IsOpen (W e) ∧ alpha (if e then A else 0) ∈ W e ∧ |
| 76 | IsCompact (D e) ∧ D e ⊆ closure U ∧ W e ∩ closure U ⊆ D e ∧ |
| 77 | D e ∩ frontier U = |
| 78 | (fun s => alpha (if e then A - s else s)) '' Icc 0 (r e) ∪ |
| 79 | (fun s => beta (if e then B - s else s)) '' Icc 0 (r e)) ∧ |
| 80 | Disjoint (D false) (D true) ∧ |
| 81 | ∃ rev0 : Bool, |
| 82 | let g0 : ℝ → AnnulusCoordinates := fun t => alpha (if rev0 then A - t else t) |
| 83 | let r0 (e : Bool) := r (if rev0 then !e else e) |
| 84 | ∃ (d0 : ℝ → AnnulusCoordinates) (n0 : ℕ) (c0 : Fin (n0 + 1) → ℝ) |
| 85 | (L0 : Fin n0 → AnnulusCoordinates ≃L[ℝ] (ℝ × ℝ)) |
| 86 | (G0 : Fin n0 → OpenPartialHomeomorph ℝ ℝ) (f0 : Fin n0 → ℝ → ℝ) (ell0 : ℝ), |
| 87 | 0 < n0 ∧ StrictMono c0 ∧ c0 0 = r0 false ∧ c0 (Fin.last n0) = A - r0 true ∧ 0 < ell0 ∧ |
| 88 | ∃ B0 : ∀ i : Fin n0, |
| 89 | ObliqueBandFaces |
| 90 | (collarParameterEquiv.trans (L0 i).symm).toHomeomorph.toOpenPartialHomeomorph |
| 91 | (f0 i) (G0 i (c0 i.castSucc)) (G0 i (c0 i.succ)) |
| 92 | (L0 i (d0 (c0 i.castSucc))).1 (L0 i (d0 (c0 i.castSucc))).2 |
| 93 | (L0 i (d0 (c0 i.succ))).1 (L0 i (d0 (c0 i.succ))).2 ell0 ell0, |
| 94 | (∀ i, (B0 i).lowerArc = g0 '' Icc (c0 i.castSucc) (c0 i.succ) ∧ |
| 95 | (B0 i).leftCut = segment ℝ (g0 (c0 i.castSucc)) |
| 96 | (g0 (c0 i.castSucc) + ell0 • d0 (c0 i.castSucc)) ∧ |
| 97 | (B0 i).rightCut = segment ℝ (g0 (c0 i.succ)) |
| 98 | (g0 (c0 i.succ) + ell0 • d0 (c0 i.succ)) ∧ |
| 99 | (B0 i).carrier ⊆ closure U ∧ (B0 i).carrier \ (B0 i).lowerArc ⊆ U) ∧ |
| 100 | (∀ i j : Fin n0, i.succ < j.castSucc → Disjoint (B0 i).carrier (B0 j).carrier) ∧ |
| 101 | (∀ i j : Fin n0, i.succ = j.castSucc → |
| 102 | (B0 i).carrier ∩ (B0 j).carrier = segment ℝ (g0 (c0 i.succ)) |
| 103 | (g0 (c0 i.succ) + ell0 • d0 (c0 i.succ))) ∧ |
| 104 | (∀ i, (D false ∪ D true) ∩ (B0 i).carrier = |
| 105 | (if c0 i.castSucc = r0 false then (B0 i).leftCut else ∅) ∪ |
| 106 | (if c0 i.succ = A - r0 true then (B0 i).rightCut else ∅)) ∧ |
| 107 | (∀ p ∈ Icc (0 : ℝ) A, ∃ W : Set AnnulusCoordinates, |
| 108 | IsOpen W ∧ g0 p ∈ W ∧ |
| 109 | W ∩ closure U ⊆ (D false ∪ D true) ∪ ⋃ i, (B0 i).carrier) ∧ |
| 110 | ∃ rev1 : Bool, |
| 111 | let g1 : ℝ → AnnulusCoordinates := fun t => beta (if rev1 then B - t else t) |
| 112 | let r1 (e : Bool) := r (if rev1 then !e else e) |
| 113 | ∃ (d1 : ℝ → AnnulusCoordinates) (n1 : ℕ) (c1 : Fin (n1 + 1) → ℝ) |
| 114 | (L1 : Fin n1 → AnnulusCoordinates ≃L[ℝ] (ℝ × ℝ)) |
| 115 | (G1 : Fin n1 → OpenPartialHomeomorph ℝ ℝ) (f1 : Fin n1 → ℝ → ℝ) (ell1 : ℝ), |
| 116 | 0 < n1 ∧ StrictMono c1 ∧ c1 0 = r1 false ∧ c1 (Fin.last n1) = B - r1 true ∧ 0 < ell1 ∧ |
| 117 | ∃ B1 : ∀ i : Fin n1, |
| 118 | ObliqueBandFaces |
| 119 | (collarParameterEquiv.trans (L1 i).symm).toHomeomorph.toOpenPartialHomeomorph |
| 120 | (f1 i) (G1 i (c1 i.castSucc)) (G1 i (c1 i.succ)) |
| 121 | (L1 i (d1 (c1 i.castSucc))).1 (L1 i (d1 (c1 i.castSucc))).2 |
| 122 | (L1 i (d1 (c1 i.succ))).1 (L1 i (d1 (c1 i.succ))).2 ell1 ell1, |
| 123 | (∀ i, (B1 i).lowerArc = g1 '' Icc (c1 i.castSucc) (c1 i.succ) ∧ |
| 124 | (B1 i).leftCut = segment ℝ (g1 (c1 i.castSucc)) |
| 125 | (g1 (c1 i.castSucc) + ell1 • d1 (c1 i.castSucc)) ∧ |
| 126 | (B1 i).rightCut = segment ℝ (g1 (c1 i.succ)) |
| 127 | (g1 (c1 i.succ) + ell1 • d1 (c1 i.succ)) ∧ |
| 128 | (B1 i).carrier ⊆ closure U ∧ (B1 i).carrier \ (B1 i).lowerArc ⊆ U) ∧ |
| 129 | (∀ i j : Fin n1, i.succ < j.castSucc → Disjoint (B1 i).carrier (B1 j).carrier) ∧ |
| 130 | (∀ i j : Fin n1, i.succ = j.castSucc → |
| 131 | (B1 i).carrier ∩ (B1 j).carrier = segment ℝ (g1 (c1 i.succ)) |
| 132 | (g1 (c1 i.succ) + ell1 • d1 (c1 i.succ))) ∧ |
| 133 | (∀ i, (D false ∪ D true) ∩ (B1 i).carrier = |
| 134 | (if c1 i.castSucc = r1 false then (B1 i).leftCut else ∅) ∪ |
| 135 | (if c1 i.succ = B - r1 true then (B1 i).rightCut else ∅)) ∧ |
| 136 | (∀ p ∈ Icc (0 : ℝ) B, ∃ W : Set AnnulusCoordinates, |
| 137 | IsOpen W ∧ g1 p ∈ W ∧ |
| 138 | W ∩ closure U ⊆ (D false ∪ D true) ∪ ⋃ i, (B1 i).carrier) |
| 139 | ∧ (∀ i j, Disjoint (B0 i).carrier (B1 j).carrier) ∧ |
| 140 | let R := ((D false ∪ D true) ∪ ⋃ i, (B0 i).carrier) ∪ ⋃ i, (B1 i).carrier |
| 141 | ∃ core : TriangleMesh, |
| 142 | core.toPlaneComplex.support = closure (U \ R) ∧ |
| 143 | closure U = R ∪ core.toPlaneComplex.support ∧ |
| 144 | ∀ p ∈ closure U ∩ frontier U, ∃ Q : Set AnnulusCoordinates, |
| 145 | IsOpen Q ∧ p ∈ Q ∧ Q ∩ closure U ⊆ R := by |
| 146 | classical |
| 147 | obtain ⟨H, r, F, W, positive, hdata, hCC, |
| 148 | rev0, d0, n0, c0, L0, G0, f0, ell0, hn0, hc0, hfirst0, hlast0, hell0, |
| 149 | B0, hB0, hsep0, hadj0, hcap0, hcover0, |
| 150 | rev1, d1, n1, c1, L1, G1, f1, ell1, hn1, hc1, hfirst1, hlast1, hell1, |
| 151 | B1, hB1, hsep1, hadj1, hcap1, hcover1, hcross⟩ := |
| 152 | m64Intrinsic_exists_two_arc_covered_bands ha hb hA hB hai hbi hareg hbreg hinter |
| 153 | hbase hend hind0 hind1 hU hV hdisj hfU hfV |
| 154 | let D (e : Bool) := ⋃ i, |
| 155 | ⋃ (_ : if positive e then i = (true, true) else i ≠ (true, true)), |
| 156 | F e i '' {q : ℝ × ℝ | 0 ≤ q.1 ∧ 0 ≤ q.2 ∧ q.1 + q.2 ≤ r e} |
| 157 | let R := ((D false ∪ D true) ∪ ⋃ i, (B0 i).carrier) ∪ ⋃ i, (B1 i).carrier |
| 158 | let g0 : ℝ → AnnulusCoordinates := fun t => alpha (if rev0 then A - t else t) |
| 159 | let g1 : ℝ → AnnulusCoordinates := fun t => beta (if rev1 then B - t else t) |
| 160 | have hr (e : Bool) := (hdata e).1 |
| 161 | have hrbound (e : Bool) := (hdata e).2.1 |
| 162 | have hax0 (e : Bool) := (hdata e).2.2.2.2.2.2.1 |
| 163 | have hax1 (e : Bool) := (hdata e).2.2.2.2.2.2.2.1 |
| 164 | have hFdata (e : Bool) := (hdata e).2.2.2.2.2.2.2.2.2.2.2.1 |
| 165 | have hCcompact (e : Bool) := (hdata e).2.2.2.2.2.2.2.2.2.2.2.2.2.2.1 |
| 166 | have hsub (e : Bool) := (hdata e).2.2.2.2.2.2.2.2.2.2.2.2.2.2.2.1 |
| 167 | have hrA (e : Bool) : r e ≤ A := by |
| 168 | have hb := (hrbound e).trans |
| 169 | (div_le_div_of_nonneg_right (min_le_left A B) (by norm_num : (0 : ℝ) ≤ 3)) |
| 170 | linarith |
| 171 | have hrB (e : Bool) : r e ≤ B := by |
| 172 | have hb := (hrbound e).trans |
| 173 | (div_le_div_of_nonneg_right (min_le_right A B) (by norm_num : (0 : ℝ) ≤ 3)) |
| 174 | linarith |
| 175 | have himage0 : g0 '' Icc 0 A = alpha '' Icc 0 A := by |
| 176 | cases rev0 |
| 177 | · rfl |
| 178 | · change (alpha ∘ fun t => A - t) '' Icc 0 A = _ |
| 179 | rw [image_comp, image_const_sub_Icc] |
| 180 | simp only [sub_self, sub_zero] |
| 181 | have himage1 : g1 '' Icc 0 B = beta '' Icc 0 B := by |
| 182 | cases rev1 |
| 183 | · rfl |
| 184 | · change (beta ∘ fun t => B - t) '' Icc 0 B = _ |
| 185 | rw [image_comp, image_const_sub_Icc] |
| 186 | simp only [sub_self, sub_zero] |
| 187 | have hcut0 (k : Fin (n0 + 1)) : c0 k ∈ Icc (0 : ℝ) A := by |
| 188 | have hl := hc0.monotone (Fin.zero_le k) |
| 189 | have hu := hc0.monotone (Fin.le_last k) |
| 190 | rw [hfirst0] at hl |
| 191 | rw [hlast0] at hu |
| 192 | exact ⟨(hr _).le.trans hl, hu.trans (sub_le_self A (hr _).le)⟩ |
| 193 | have hcut1 (k : Fin (n1 + 1)) : c1 k ∈ Icc (0 : ℝ) B := by |
| 194 | have hl := hc1.monotone (Fin.zero_le k) |
| 195 | have hu := hc1.monotone (Fin.le_last k) |
| 196 | rw [hfirst1] at hl |
| 197 | rw [hlast1] at hu |
| 198 | exact ⟨(hr _).le.trans hl, hu.trans (sub_le_self B (hr _).le)⟩ |
| 199 | have hlower0 (i : Fin n0) : (B0 i).lowerArc ⊆ frontier U := by |
| 200 | have him : g0 '' Icc 0 A ⊆ frontier U := by |
| 201 | rw [himage0, hfU] |
| 202 | exact subset_union_left |
| 203 | rw [(hB0 i).1] |
| 204 | exact (image_mono (Icc_subset_Icc (hcut0 i.castSucc).1 (hcut0 i.succ).2)).trans him |
| 205 | have hlower1 (i : Fin n1) : (B1 i).lowerArc ⊆ frontier U := by |
| 206 | have him : g1 '' Icc 0 B ⊆ frontier U := by |
| 207 | rw [himage1, hfU] |
| 208 | exact subset_union_right |
| 209 | rw [(hB1 i).1] |
| 210 | exact (image_mono (Icc_subset_Icc (hcut1 i.castSucc).1 (hcut1 i.succ).2)).trans him |
| 211 | have hlocal : ∀ p ∈ closure U ∩ frontier U, ∃ Q : Set AnnulusCoordinates, |
| 212 | IsOpen Q ∧ p ∈ Q ∧ Q ∩ closure U ⊆ R := by |
| 213 | intro p hp |
| 214 | rw [hfU, ← himage0, ← himage1] at hp |
| 215 | rcases hp.2 with ⟨t, ht, rfl⟩ | ⟨t, ht, rfl⟩ |
| 216 | · obtain ⟨Q, hQ, hpQ, hcover⟩ := hcover0 t ht |
| 217 | exact ⟨Q, hQ, hpQ, hcover.trans subset_union_left⟩ |
| 218 | · obtain ⟨Q, hQ, hpQ, hcover⟩ := hcover1 t ht |
| 219 | exact ⟨Q, hQ, hpQ, hcover.trans |
| 220 | (union_subset (fun _ hz => Or.inl (Or.inl hz)) (fun _ hz => Or.inr hz))⟩ |
| 221 | have hparam {T r : ℝ} (hr : 0 ≤ r) (hrT : r ≤ T) |
| 222 | (e : Bool) (t : ℝ) (ht : t ∈ Icc (0 : ℝ) 1) : |
| 223 | (if e then T - t * r else t * r) ∈ Icc (0 : ℝ) T := by |
| 224 | have ht' : t * r ∈ Icc (0 : ℝ) T := |
| 225 | ⟨mul_nonneg ht.1 hr, (mul_le_of_le_one_left hr ht.2).trans hrT⟩ |
| 226 | cases e |
| 227 | · exact ht' |
| 228 | · change T - t * r ∈ Icc (0 : ℝ) T |
| 229 | constructor <;> linarith [ht'.1, ht'.2] |
| 230 | have haxes (e : Bool) : |
| 231 | (fun t : ℝ => H e (0, t * r e)) '' Icc 0 1 ∪ |
| 232 | (fun t : ℝ => H e (t * r e, 0)) '' Icc 0 1 ⊆ frontier U := by |
| 233 | rintro z (⟨t, ht, rfl⟩ | ⟨t, ht, rfl⟩) |
| 234 | · dsimp only |
| 235 | rw [hax1, hfU] |
| 236 | exact Or.inr ⟨_, hparam (hr e).le (hrB e) e t ht, rfl⟩ |
| 237 | · dsimp only |
| 238 | rw [hax0, hfU] |
| 239 | exact Or.inl ⟨_, hparam (hr e).le (hrA e) e t ht, rfl⟩ |
| 240 | have hcaplines (e : Bool) := m64Intrinsic_retained_corner_frontier_lines |
| 241 | (hr e) (H e) (F e) (positive e) |
| 242 | (fun i => (hFdata e i).1) (fun i => (hFdata e i).2.2.1) |
| 243 | (fun i => (hFdata e i).2.2.2.1) (fun i => (hFdata e i).2.2.2.2.1) |
| 244 | (fun i => (hFdata e i).2.2.2.2.2.1) |
| 245 | (fun i => (hFdata e i).2.2.2.2.2.2.1) |
| 246 | (fun i => (hFdata e i).2.2.2.2.2.2.2.1) (haxes e) |
| 247 | let pieces : Bool ⊕ (Fin n0 ⊕ Fin n1) → Set AnnulusCoordinates |
| 248 | | .inl e => D e |
| 249 | | .inr (.inl i) => (B0 i).carrier |
| 250 | | .inr (.inr i) => (B1 i).carrier |
| 251 | have hpieces : (⋃ i, pieces i) = R := by |
| 252 | ext p |
| 253 | simp only [pieces, R, mem_iUnion, Sum.exists, Bool.exists_bool, mem_union] |
| 254 | tauto |
| 255 | have hclosed : ∀ i, IsClosed (pieces i) := by |
| 256 | rintro (e | (i | i)) |
| 257 | · exact (hCcompact e).isClosed |
| 258 | · exact (B0 i).isClosed_carrier |
| 259 | · exact (B1 i).isClosed_carrier |
| 260 | have hsub' : ∀ i, pieces i ⊆ closure U := by |
| 261 | rintro (e | (i | i)) |
| 262 | · exact hsub e |
| 263 | · exact (hB0 i).2.2.2.1 |
| 264 | · exact (hB1 i).2.2.2.1 |
| 265 | have hlinefamily : ∀ i, |
| 266 | ∃ lines : List (AnnulusCoordinates →ᵃ[ℝ] ℝ), |
| 267 | (∀ l ∈ lines, Function.Surjective l) ∧ |
| 268 | frontier (pieces i) \ frontier U ⊆ ⋃ l ∈ lines, {z | l z = 0} := by |
| 269 | rintro (e | (i | i)) |
| 270 | · obtain ⟨_, _, lines, hlines, hfront⟩ := hcaplines e |
| 271 | exact ⟨lines, hlines, fun z hz => (hfront hz.1).resolve_left hz.2⟩ |
| 272 | · obtain ⟨lines, hlines, hfront⟩ := m64Intrinsic_linear_band_frontier_lines (L0 i).symm (B0 i) |
| 273 | exact ⟨lines, hlines, fun z hz => |
| 274 | (hfront hz.1).resolve_left (fun h => hz.2 (hlower0 i h))⟩ |
| 275 | · obtain ⟨lines, hlines, hfront⟩ := m64Intrinsic_linear_band_frontier_lines (L1 i).symm (B1 i) |
| 276 | exact ⟨lines, hlines, fun z hz => |
| 277 | (hfront hz.1).resolve_left (fun h => hz.2 (hlower1 i h))⟩ |
| 278 | obtain ⟨lines, hlines, hlinesub⟩ := Poincare.Topology.Plane.exists_affine_lines_iUnion |
| 279 | (fun i => frontier (pieces i) \ frontier U) hlinefamily |
| 280 | have hfront : ∀ i, frontier (pieces i) ⊆ frontier U ∪ |
| 281 | (chartAt AnnulusCoordinates (0 : AnnulusCoordinates)) ⁻¹' |
| 282 | (⋃ l ∈ lines, {z | l z = 0}) := by |
| 283 | intro i z hz |
| 284 | by_cases htrace : z ∈ frontier U |
| 285 | · exact Or.inl htrace |
| 286 | · right |
| 287 | simpa using hlinesub (mem_iUnion.mpr ⟨i, hz, htrace⟩) |
| 288 | obtain ⟨core, hcore, _, _, _, hrecovery, _, _⟩ := |
| 289 | exists_exact_polygonal_remainder_mesh_with_refinement (0 : AnnulusCoordinates) |
| 290 | hU hcompact (by intro z _; simp) pieces hclosed hsub' (Subset.refl (frontier U)) |
| 291 | lines hlines hfront (by simpa only [hpieces] using hlocal) |
| 292 | have hcore' : core.toPlaneComplex.support = closure (U \ R) := by |
| 293 | simpa only [hpieces, chartAt_self_eq, OpenPartialHomeomorph.refl_apply, image_id] using hcore |
| 294 | have hrecovery' : closure U = R ∪ core.toPlaneComplex.support := by |
| 295 | simpa [hpieces] using hrecovery |
| 296 | exact ⟨H, r, F, W, positive, hdata, hCC, |
| 297 | rev0, d0, n0, c0, L0, G0, f0, ell0, hn0, hc0, hfirst0, hlast0, hell0, |
| 298 | B0, hB0, hsep0, hadj0, hcap0, hcover0, |
| 299 | rev1, d1, n1, c1, L1, G1, f1, ell1, hn1, hc1, hfirst1, hlast1, hell1, |
| 300 | B1, hB1, hsep1, hadj1, hcap1, hcover1, hcross, core, hcore', hrecovery', hlocal⟩ |
| 301 | |
| 302 | end PoincareMT |