@@ -289,6 +289,20 @@ lemma RelCWComplex.map_zero_mem_closedCell [RelCWComplex C D] (n : ℕ) (i : cel
289289 map n i 0 ∈ closedCell n i :=
290290 openCell_subset_closedCell _ _ (map_zero_mem_openCell _ _)
291291
292+ lemma RelCWComplex.openCell_nonempty [RelCWComplex C D] (n : ℕ) (j : cell C n) :
293+ (openCell n j).Nonempty :=
294+ ⟨(map n j) 0 , map_zero_mem_openCell n j⟩
295+
296+ lemma RelCWComplex.closedCell_nonempty [RelCWComplex C D] (n : ℕ) (j : cell C n) :
297+ (closedCell n j).Nonempty :=
298+ ⟨(map n j) 0 , map_zero_mem_closedCell n j⟩
299+
300+ /-- If two open cells are equal, so are the underlying cells. -/
301+ lemma RelCWComplex.openCell_congr [RelCWComplex C D] (n : ℕ) {s t : cell C n}
302+ (st : openCell n s = openCell n t) : s = t := by
303+ contrapose! st
304+ exact (disjoint_openCell_of_ne (by simpa)).ne (openCell_nonempty n s).ne_empty
305+
292306/-- This is an auxiliary lemma used to prove `RelCWComplex.eq_of_eq_union_iUnion`. -/
293307private lemma RelCWComplex.subset_of_eq_union_iUnion [RelCWComplex C D] (I J : Π n, Set (cell C n))
294308 (hIJ : D ∪ ⋃ (n : ℕ) (j : I n), openCell (C := C) n j =
@@ -1061,4 +1075,45 @@ lemma RelCWComplex.disjoint_interior_base_iUnion_closedCell [T2Space X] [RelCWCo
10611075 simp_rw [disjoint_iff_inter_eq_empty, inter_iUnion, disjoint_interior_base_closedCell.inter_eq,
10621076 iUnion_empty]
10631077
1078+ /-- A closed discrete subset of a space is a CW complex. -/
1079+ @ [reducible, simps -isSimp]
1080+ def CWComplex.OfDiscreteClosed (hD : IsDiscrete D) (Dc : IsClosed D) : CWComplex D where
1081+ cell n := match n with
1082+ | 0 => D
1083+ | (_ + 1 ) => PEmpty
1084+ map n i := match n with
1085+ | 0 => PartialEquiv.single ![] i
1086+ | (_ + 1 ) => i.elim
1087+ source_eq n i := match n with
1088+ | 0 => by simp [ball, Matrix.empty_eq, eq_univ_iff_forall]
1089+ | (_ + 1 ) => i.elim
1090+ continuousOn n i := match n with
1091+ | 0 => continuousOn_const
1092+ | (_ + 1 ) => i.elim
1093+ continuousOn_symm n i := match n with
1094+ | 0 => continuousOn_const
1095+ | (_ + 1 ) => i.elim
1096+ pairwiseDisjoint' := by
1097+ simp_rw [PairwiseDisjoint, Set.Pairwise, Function.onFun]
1098+ rintro ⟨_|n, j⟩ _ ⟨_|m, i⟩ _ ne
1099+ · simp_all [Subtype.coe_injective.ne]
1100+ · exact i.elim
1101+ · tauto
1102+ · exact i.elim
1103+ mapsTo' n i := match n with
1104+ | 0 => by simp [Matrix.zero_empty, sphere_eq_empty_of_subsingleton]
1105+ | (_ + 1 ) => i.elim
1106+ closed' A AD _ := isClosed_of_subset_discrete_closed AD hD Dc
1107+ union' := by
1108+ apply subset_antisymm (iUnion₂_subset_iff.mpr fun n ↦ by cases n <;> simp)
1109+ intro x xD
1110+ simp only [mem_iUnion, mem_image, mem_closedBall, dist_zero_right]
1111+ refine ⟨0 , ?_⟩
1112+ simpa [-Matrix.zero_empty]
1113+
1114+ /-- A discrete space is a CW complex. -/
1115+ instance CWComplex.ofDiscreteTopology {X : Type *} [TopologicalSpace X] [DiscreteTopology X] :
1116+ CWComplex (univ : Set X) :=
1117+ CWComplex.OfDiscreteClosed IsDiscrete.univ isClosed_univ
1118+
10641119end Topology
0 commit comments