diff -r 6ebe97815275 -r 11065b70407d src/HOL/Analysis/T1_Spaces.thy --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/src/HOL/Analysis/T1_Spaces.thy Thu Mar 07 14:08:05 2019 +0000 @@ -0,0 +1,201 @@ +section\T1 spaces with equivalences to many naturally "nice" properties. \ + +theory T1_Spaces +imports Function_Topology +begin + +definition t1_space where + "t1_space X \ \x \ topspace X. \y \ topspace X. x\y \ (\U. openin X U \ x \ U \ y \ U)" + +lemma t1_space_expansive: + "\topspace Y = topspace X; \U. openin X U \ openin Y U\ \ t1_space X \ t1_space Y" + by (metis t1_space_def) + +lemma t1_space_alt: + "t1_space X \ (\x \ topspace X. \y \ topspace X. x\y \ (\U. closedin X U \ x \ U \ y \ U))" + by (metis DiffE DiffI closedin_def openin_closedin_eq t1_space_def) + +lemma t1_space_empty: "topspace X = {} \ t1_space X" + by (simp add: t1_space_def) + +lemma t1_space_derived_set_of_singleton: + "t1_space X \ (\x \ topspace X. X derived_set_of {x} = {})" + apply (simp add: t1_space_def derived_set_of_def, safe) + apply (metis openin_topspace) + by force + +lemma t1_space_derived_set_of_finite: + "t1_space X \ (\S. finite S \ X derived_set_of S = {})" +proof (intro iffI allI impI) + fix S :: "'a set" + assume "finite S" + then have fin: "finite ((\x. {x}) ` (topspace X \ S))" + by blast + assume "t1_space X" + then have "X derived_set_of (\x \ topspace X \ S. {x}) = {}" + unfolding derived_set_of_Union [OF fin] + by (auto simp: t1_space_derived_set_of_singleton) + then have "X derived_set_of (topspace X \ S) = {}" + by simp + then show "X derived_set_of S = {}" + by simp +qed (auto simp: t1_space_derived_set_of_singleton) + +lemma t1_space_closedin_singleton: + "t1_space X \ (\x \ topspace X. closedin X {x})" + apply (rule iffI) + apply (simp add: closedin_contains_derived_set t1_space_derived_set_of_singleton) + using t1_space_alt by auto + +lemma closedin_t1_singleton: + "\t1_space X; a \ topspace X\ \ closedin X {a}" + by (simp add: t1_space_closedin_singleton) + +lemma t1_space_closedin_finite: + "t1_space X \ (\S. finite S \ S \ topspace X \ closedin X S)" + apply (rule iffI) + apply (simp add: closedin_contains_derived_set t1_space_derived_set_of_finite) + by (simp add: t1_space_closedin_singleton) + +lemma closure_of_singleton: + "t1_space X \ X closure_of {a} = (if a \ topspace X then {a} else {})" + by (simp add: closure_of_eq t1_space_closedin_singleton closure_of_eq_empty_gen) + +lemma separated_in_singleton: + assumes "t1_space X" + shows "separatedin X {a} S \ a \ topspace X \ S \ topspace X \ (a \ X closure_of S)" + "separatedin X S {a} \ a \ topspace X \ S \ topspace X \ (a \ X closure_of S)" + unfolding separatedin_def + using assms closure_of closure_of_singleton by fastforce+ + +lemma t1_space_openin_delete: + "t1_space X \ (\U x. openin X U \ x \ U \ openin X (U - {x}))" + apply (rule iffI) + apply (meson closedin_t1_singleton in_mono openin_diff openin_subset) + by (simp add: closedin_def t1_space_closedin_singleton) + +lemma t1_space_openin_delete_alt: + "t1_space X \ (\U x. openin X U \ openin X (U - {x}))" + by (metis Diff_empty Diff_insert0 t1_space_openin_delete) + + +lemma t1_space_singleton_Inter_open: + "t1_space X \ (\x \ topspace X. \{U. openin X U \ x \ U} = {x})" (is "?P=?Q") + and t1_space_Inter_open_supersets: + "t1_space X \ (\S. S \ topspace X \ \{U. openin X U \ S \ U} = S)" (is "?P=?R") +proof - + have "?R \ ?Q" + apply clarify + apply (drule_tac x="{x}" in spec, simp) + done + moreover have "?Q \ ?P" + apply (clarsimp simp add: t1_space_def) + apply (drule_tac x=x in bspec) + apply (simp_all add: set_eq_iff) + by (metis (no_types, lifting)) + moreover have "?P \ ?R" + proof (clarsimp simp add: t1_space_closedin_singleton, rule subset_antisym) + fix S + assume S: "\x\topspace X. closedin X {x}" "S \ topspace X" + then show "\ {U. openin X U \ S \ U} \ S" + apply clarsimp + by (metis Diff_insert_absorb Set.set_insert closedin_def openin_topspace subset_insert) + qed force + ultimately show "?P=?Q" "?P=?R" + by auto +qed + +lemma t1_space_derived_set_of_infinite_openin: + "t1_space X \ + (\S. X derived_set_of S = + {x \ topspace X. \U. x \ U \ openin X U \ infinite(S \ U)})" + (is "_ = ?rhs") +proof + assume "t1_space X" + show ?rhs + proof safe + fix S x U + assume "x \ X derived_set_of S" "x \ U" "openin X U" "finite (S \ U)" + with \t1_space X\ show "False" + apply (simp add: t1_space_derived_set_of_finite) + by (metis IntI empty_iff empty_subsetI inf_commute openin_Int_derived_set_of_subset subset_antisym) + next + fix S x + have eq: "(\y. (y \ x) \ y \ S \ y \ T) \ ~((S \ T) \ {x})" for x S T + by blast + assume "x \ topspace X" "\U. x \ U \ openin X U \ infinite (S \ U)" + then show "x \ X derived_set_of S" + apply (clarsimp simp add: derived_set_of_def eq) + by (meson finite.emptyI finite.insertI finite_subset) + qed (auto simp: in_derived_set_of) +qed (auto simp: t1_space_derived_set_of_singleton) + +lemma finite_t1_space_imp_discrete_topology: + "\topspace X = U; finite U; t1_space X\ \ X = discrete_topology U" + by (metis discrete_topology_unique_derived_set t1_space_derived_set_of_finite) + +lemma t1_space_subtopology: "t1_space X \ t1_space(subtopology X U)" + by (simp add: derived_set_of_subtopology t1_space_derived_set_of_finite) + +lemma closedin_derived_set_of_gen: + "t1_space X \ closedin X (X derived_set_of S)" + apply (clarsimp simp add: in_derived_set_of closedin_contains_derived_set derived_set_of_subset_topspace) + by (metis DiffD2 insert_Diff insert_iff t1_space_openin_delete) + +lemma derived_set_of_derived_set_subset_gen: + "t1_space X \ X derived_set_of (X derived_set_of S) \ X derived_set_of S" + by (meson closedin_contains_derived_set closedin_derived_set_of_gen) + +lemma subtopology_eq_discrete_topology_gen_finite: + "\t1_space X; finite S\ \ subtopology X S = discrete_topology(topspace X \ S)" + by (simp add: subtopology_eq_discrete_topology_gen t1_space_derived_set_of_finite) + +lemma subtopology_eq_discrete_topology_finite: + "\t1_space X; S \ topspace X; finite S\ + \ subtopology X S = discrete_topology S" + by (simp add: subtopology_eq_discrete_topology_eq t1_space_derived_set_of_finite) + +lemma t1_space_closed_map_image: + "\closed_map X Y f; f ` (topspace X) = topspace Y; t1_space X\ \ t1_space Y" + by (metis closed_map_def finite_subset_image t1_space_closedin_finite) + +lemma homeomorphic_t1_space: "X homeomorphic_space Y \ (t1_space X \ t1_space Y)" + apply (clarsimp simp add: homeomorphic_space_def) + by (meson homeomorphic_eq_everything_map homeomorphic_maps_map t1_space_closed_map_image) + +proposition t1_space_product_topology: + "t1_space (product_topology X I) +\ topspace(product_topology X I) = {} \ (\i \ I. t1_space (X i))" +proof (cases "topspace(product_topology X I) = {}") + case True + then show ?thesis + using True t1_space_empty by blast +next + case False + then obtain f where f: "f \ (\\<^sub>E i\I. topspace(X i))" + by fastforce + have "t1_space (product_topology X I) \ (\i\I. t1_space (X i))" + proof (intro iffI ballI) + show "t1_space (X i)" if "t1_space (product_topology X I)" and "i \ I" for i + proof - + have clo: "\h. h \ (\\<^sub>E i\I. topspace (X i)) \ closedin (product_topology X I) {h}" + using that by (simp add: t1_space_closedin_singleton) + show ?thesis + unfolding t1_space_closedin_singleton + proof clarify + show "closedin (X i) {xi}" if "xi \ topspace (X i)" for xi + using clo [of "\j \ I. if i=j then xi else f j"] f that \i \ I\ + by (fastforce simp add: closedin_product_topology_singleton) + qed + qed + next + next + show "t1_space (product_topology X I)" if "\i\I. t1_space (X i)" + using that + by (simp add: t1_space_closedin_singleton Ball_def PiE_iff closedin_product_topology_singleton) + qed + then show ?thesis + using False by blast +qed + +end