| author | wenzelm | 
| Mon, 06 Sep 2021 12:23:06 +0200 | |
| changeset 74245 | 282cd3aa6cc6 | 
| parent 72569 | d56e4eeae967 | 
| child 77200 | 8f2e6186408f | 
| permissions | -rw-r--r-- | 
| 63627 | 1 | (* Title: HOL/Analysis/Homeomorphism.thy | 
| 63130 | 2 | Author: LC Paulson (ported from HOL Light) | 
| 3 | *) | |
| 4 | ||
| 69722 
b5163b2132c5
minor tagging updates in 13 theories
 Angeliki KoutsoukouArgyraki <ak2110@cam.ac.uk> parents: 
69683diff
changeset | 5 | section \<open>Homeomorphism Theorems\<close> | 
| 63130 | 6 | |
| 7 | theory Homeomorphism | |
| 69620 | 8 | imports Homotopy | 
| 63130 | 9 | begin | 
| 10 | ||
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 11 | lemma homeomorphic_spheres': | 
| 64789 
6440577e34ee
connectedness, circles not simply connected , punctured universe
 paulson <lp15@cam.ac.uk> parents: 
64773diff
changeset | 12 | fixes a ::"'a::euclidean_space" and b ::"'b::euclidean_space" | 
| 
6440577e34ee
connectedness, circles not simply connected , punctured universe
 paulson <lp15@cam.ac.uk> parents: 
64773diff
changeset | 13 |   assumes "0 < \<delta>" and dimeq: "DIM('a) = DIM('b)"
 | 
| 
6440577e34ee
connectedness, circles not simply connected , punctured universe
 paulson <lp15@cam.ac.uk> parents: 
64773diff
changeset | 14 | shows "(sphere a \<delta>) homeomorphic (sphere b \<delta>)" | 
| 
6440577e34ee
connectedness, circles not simply connected , punctured universe
 paulson <lp15@cam.ac.uk> parents: 
64773diff
changeset | 15 | proof - | 
| 
6440577e34ee
connectedness, circles not simply connected , punctured universe
 paulson <lp15@cam.ac.uk> parents: 
64773diff
changeset | 16 | obtain f :: "'a\<Rightarrow>'b" and g where "linear f" "linear g" | 
| 
6440577e34ee
connectedness, circles not simply connected , punctured universe
 paulson <lp15@cam.ac.uk> parents: 
64773diff
changeset | 17 | and fg: "\<And>x. norm(f x) = norm x" "\<And>y. norm(g y) = norm y" "\<And>x. g(f x) = x" "\<And>y. f(g y) = y" | 
| 
6440577e34ee
connectedness, circles not simply connected , punctured universe
 paulson <lp15@cam.ac.uk> parents: 
64773diff
changeset | 18 | by (blast intro: isomorphisms_UNIV_UNIV [OF dimeq]) | 
| 
6440577e34ee
connectedness, circles not simply connected , punctured universe
 paulson <lp15@cam.ac.uk> parents: 
64773diff
changeset | 19 | then have "continuous_on UNIV f" "continuous_on UNIV g" | 
| 
6440577e34ee
connectedness, circles not simply connected , punctured universe
 paulson <lp15@cam.ac.uk> parents: 
64773diff
changeset | 20 | using linear_continuous_on linear_linear by blast+ | 
| 
6440577e34ee
connectedness, circles not simply connected , punctured universe
 paulson <lp15@cam.ac.uk> parents: 
64773diff
changeset | 21 | then show ?thesis | 
| 
6440577e34ee
connectedness, circles not simply connected , punctured universe
 paulson <lp15@cam.ac.uk> parents: 
64773diff
changeset | 22 | unfolding homeomorphic_minimal | 
| 
6440577e34ee
connectedness, circles not simply connected , punctured universe
 paulson <lp15@cam.ac.uk> parents: 
64773diff
changeset | 23 | apply(rule_tac x="\<lambda>x. b + f(x - a)" in exI) | 
| 
6440577e34ee
connectedness, circles not simply connected , punctured universe
 paulson <lp15@cam.ac.uk> parents: 
64773diff
changeset | 24 | apply(rule_tac x="\<lambda>x. a + g(x - b)" in exI) | 
| 
6440577e34ee
connectedness, circles not simply connected , punctured universe
 paulson <lp15@cam.ac.uk> parents: 
64773diff
changeset | 25 | using assms | 
| 
6440577e34ee
connectedness, circles not simply connected , punctured universe
 paulson <lp15@cam.ac.uk> parents: 
64773diff
changeset | 26 | apply (force intro: continuous_intros | 
| 
6440577e34ee
connectedness, circles not simply connected , punctured universe
 paulson <lp15@cam.ac.uk> parents: 
64773diff
changeset | 27 | continuous_on_compose2 [of _ f] continuous_on_compose2 [of _ g] simp: dist_commute dist_norm fg) | 
| 
6440577e34ee
connectedness, circles not simply connected , punctured universe
 paulson <lp15@cam.ac.uk> parents: 
64773diff
changeset | 28 | done | 
| 
6440577e34ee
connectedness, circles not simply connected , punctured universe
 paulson <lp15@cam.ac.uk> parents: 
64773diff
changeset | 29 | qed | 
| 
6440577e34ee
connectedness, circles not simply connected , punctured universe
 paulson <lp15@cam.ac.uk> parents: 
64773diff
changeset | 30 | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 31 | lemma homeomorphic_spheres_gen: | 
| 64789 
6440577e34ee
connectedness, circles not simply connected , punctured universe
 paulson <lp15@cam.ac.uk> parents: 
64773diff
changeset | 32 | fixes a :: "'a::euclidean_space" and b :: "'b::euclidean_space" | 
| 
6440577e34ee
connectedness, circles not simply connected , punctured universe
 paulson <lp15@cam.ac.uk> parents: 
64773diff
changeset | 33 |   assumes "0 < r" "0 < s" "DIM('a::euclidean_space) = DIM('b::euclidean_space)"
 | 
| 
6440577e34ee
connectedness, circles not simply connected , punctured universe
 paulson <lp15@cam.ac.uk> parents: 
64773diff
changeset | 34 | shows "(sphere a r homeomorphic sphere b s)" | 
| 72496 | 35 | using assms homeomorphic_trans [OF homeomorphic_spheres homeomorphic_spheres'] by auto | 
| 64789 
6440577e34ee
connectedness, circles not simply connected , punctured universe
 paulson <lp15@cam.ac.uk> parents: 
64773diff
changeset | 36 | |
| 69683 | 37 | subsection \<open>Homeomorphism of all convex compact sets with nonempty interior\<close> | 
| 63130 | 38 | |
| 69739 | 39 | proposition | 
| 63130 | 40 | fixes S :: "'a::euclidean_space set" | 
| 41 | assumes "compact S" and 0: "0 \<in> rel_interior S" | |
| 42 | and star: "\<And>x. x \<in> S \<Longrightarrow> open_segment 0 x \<subseteq> rel_interior S" | |
| 43 | shows starlike_compact_projective1_0: | |
| 44 | "S - rel_interior S homeomorphic sphere 0 1 \<inter> affine hull S" | |
| 45 | (is "?SMINUS homeomorphic ?SPHER") | |
| 46 | and starlike_compact_projective2_0: | |
| 47 | "S homeomorphic cball 0 1 \<inter> affine hull S" | |
| 48 | (is "S homeomorphic ?CBALL") | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 49 | proof - | 
| 63130 | 50 | have starI: "(u *\<^sub>R x) \<in> rel_interior S" if "x \<in> S" "0 \<le> u" "u < 1" for x u | 
| 51 | proof (cases "x=0 \<or> u=0") | |
| 52 | case True with 0 show ?thesis by force | |
| 53 | next | |
| 54 | case False with that show ?thesis | |
| 55 | by (auto simp: in_segment intro: star [THEN subsetD]) | |
| 56 | qed | |
| 57 | have "0 \<in> S" using assms rel_interior_subset by auto | |
| 58 | define proj where "proj \<equiv> \<lambda>x::'a. x /\<^sub>R norm x" | |
| 59 | have eqI: "x = y" if "proj x = proj y" "norm x = norm y" for x y | |
| 60 | using that by (force simp: proj_def) | |
| 61 | then have iff_eq: "\<And>x y. (proj x = proj y \<and> norm x = norm y) \<longleftrightarrow> x = y" | |
| 62 | by blast | |
| 63 | have projI: "x \<in> affine hull S \<Longrightarrow> proj x \<in> affine hull S" for x | |
| 64 | by (metis \<open>0 \<in> S\<close> affine_hull_span_0 hull_inc span_mul proj_def) | |
| 65 | have nproj1 [simp]: "x \<noteq> 0 \<Longrightarrow> norm(proj x) = 1" for x | |
| 66 | by (simp add: proj_def) | |
| 67 | have proj0_iff [simp]: "proj x = 0 \<longleftrightarrow> x = 0" for x | |
| 68 | by (simp add: proj_def) | |
| 69 |   have cont_proj: "continuous_on (UNIV - {0}) proj"
 | |
| 70 | unfolding proj_def by (rule continuous_intros | force)+ | |
| 71 | have proj_spherI: "\<And>x. \<lbrakk>x \<in> affine hull S; x \<noteq> 0\<rbrakk> \<Longrightarrow> proj x \<in> ?SPHER" | |
| 72 | by (simp add: projI) | |
| 73 | have "bounded S" "closed S" | |
| 74 | using \<open>compact S\<close> compact_eq_bounded_closed by blast+ | |
| 75 | have inj_on_proj: "inj_on proj (S - rel_interior S)" | |
| 76 | proof | |
| 77 | fix x y | |
| 78 | assume x: "x \<in> S - rel_interior S" | |
| 79 | and y: "y \<in> S - rel_interior S" and eq: "proj x = proj y" | |
| 80 | then have xynot: "x \<noteq> 0" "y \<noteq> 0" "x \<in> S" "y \<in> S" "x \<notin> rel_interior S" "y \<notin> rel_interior S" | |
| 81 | using 0 by auto | |
| 82 | consider "norm x = norm y" | "norm x < norm y" | "norm x > norm y" by linarith | |
| 83 | then show "x = y" | |
| 84 | proof cases | |
| 85 | assume "norm x = norm y" | |
| 86 | with iff_eq eq show "x = y" by blast | |
| 87 | next | |
| 88 | assume *: "norm x < norm y" | |
| 89 | have "x /\<^sub>R norm x = norm x *\<^sub>R (x /\<^sub>R norm x) /\<^sub>R norm (norm x *\<^sub>R (x /\<^sub>R norm x))" | |
| 90 | by force | |
| 91 | then have "proj ((norm x / norm y) *\<^sub>R y) = proj x" | |
| 92 | by (metis (no_types) divide_inverse local.proj_def eq scaleR_scaleR) | |
| 93 | then have [simp]: "(norm x / norm y) *\<^sub>R y = x" | |
| 94 | by (rule eqI) (simp add: \<open>y \<noteq> 0\<close>) | |
| 95 | have no: "0 \<le> norm x / norm y" "norm x / norm y < 1" | |
| 70817 
dd675800469d
dedicated fact collections for algebraic simplification rules potentially splitting goals
 haftmann parents: 
70802diff
changeset | 96 | using * by (auto simp: field_split_simps) | 
| 63130 | 97 | then show "x = y" | 
| 98 | using starI [OF \<open>y \<in> S\<close> no] xynot by auto | |
| 99 | next | |
| 100 | assume *: "norm x > norm y" | |
| 101 | have "y /\<^sub>R norm y = norm y *\<^sub>R (y /\<^sub>R norm y) /\<^sub>R norm (norm y *\<^sub>R (y /\<^sub>R norm y))" | |
| 102 | by force | |
| 103 | then have "proj ((norm y / norm x) *\<^sub>R x) = proj y" | |
| 104 | by (metis (no_types) divide_inverse local.proj_def eq scaleR_scaleR) | |
| 105 | then have [simp]: "(norm y / norm x) *\<^sub>R x = y" | |
| 106 | by (rule eqI) (simp add: \<open>x \<noteq> 0\<close>) | |
| 107 | have no: "0 \<le> norm y / norm x" "norm y / norm x < 1" | |
| 70817 
dd675800469d
dedicated fact collections for algebraic simplification rules potentially splitting goals
 haftmann parents: 
70802diff
changeset | 108 | using * by (auto simp: field_split_simps) | 
| 63130 | 109 | then show "x = y" | 
| 110 | using starI [OF \<open>x \<in> S\<close> no] xynot by auto | |
| 111 | qed | |
| 112 | qed | |
| 113 | have "\<exists>surf. homeomorphism (S - rel_interior S) ?SPHER proj surf" | |
| 114 | proof (rule homeomorphism_compact) | |
| 115 | show "compact (S - rel_interior S)" | |
| 116 | using \<open>compact S\<close> compact_rel_boundary by blast | |
| 117 | show "continuous_on (S - rel_interior S) proj" | |
| 118 | using 0 by (blast intro: continuous_on_subset [OF cont_proj]) | |
| 119 | show "proj ` (S - rel_interior S) = ?SPHER" | |
| 120 | proof | |
| 121 | show "proj ` (S - rel_interior S) \<subseteq> ?SPHER" | |
| 122 | using 0 by (force simp: hull_inc projI intro: nproj1) | |
| 123 | show "?SPHER \<subseteq> proj ` (S - rel_interior S)" | |
| 124 | proof (clarsimp simp: proj_def) | |
| 125 | fix x | |
| 126 | assume "x \<in> affine hull S" and nox: "norm x = 1" | |
| 127 | then have "x \<noteq> 0" by auto | |
| 128 | obtain d where "0 < d" and dx: "(d *\<^sub>R x) \<in> rel_frontier S" | |
| 72496 | 129 | and ri: "\<And>e. \<lbrakk>0 \<le> e; e < d\<rbrakk> \<Longrightarrow> (e *\<^sub>R x) \<in> rel_interior S" | 
| 63130 | 130 | using ray_to_rel_frontier [OF \<open>bounded S\<close> 0] \<open>x \<in> affine hull S\<close> \<open>x \<noteq> 0\<close> by auto | 
| 131 | show "x \<in> (\<lambda>x. x /\<^sub>R norm x) ` (S - rel_interior S)" | |
| 72496 | 132 | proof | 
| 133 | show "x = d *\<^sub>R x /\<^sub>R norm (d *\<^sub>R x)" | |
| 134 | using \<open>0 < d\<close> by (auto simp: nox) | |
| 135 | show "d *\<^sub>R x \<in> S - rel_interior S" | |
| 136 | using dx \<open>closed S\<close> by (auto simp: rel_frontier_def) | |
| 137 | qed | |
| 63130 | 138 | qed | 
| 139 | qed | |
| 140 | qed (rule inj_on_proj) | |
| 141 | then obtain surf where surf: "homeomorphism (S - rel_interior S) ?SPHER proj surf" | |
| 142 | by blast | |
| 143 | then have cont_surf: "continuous_on (proj ` (S - rel_interior S)) surf" | |
| 144 | by (auto simp: homeomorphism_def) | |
| 145 | have surf_nz: "\<And>x. x \<in> ?SPHER \<Longrightarrow> surf x \<noteq> 0" | |
| 146 | by (metis "0" DiffE homeomorphism_def imageI surf) | |
| 147 | have cont_nosp: "continuous_on (?SPHER) (\<lambda>x. norm x *\<^sub>R ((surf o proj) x))" | |
| 72496 | 148 | proof (intro continuous_intros) | 
| 149 | show "continuous_on (sphere 0 1 \<inter> affine hull S) proj" | |
| 150 | by (rule continuous_on_subset [OF cont_proj], force) | |
| 151 | show "continuous_on (proj ` (sphere 0 1 \<inter> affine hull S)) surf" | |
| 152 | by (intro continuous_on_subset [OF cont_surf]) (force simp: homeomorphism_image1 [OF surf] dest: proj_spherI) | |
| 153 | qed | |
| 63130 | 154 | have surfpS: "\<And>x. \<lbrakk>norm x = 1; x \<in> affine hull S\<rbrakk> \<Longrightarrow> surf (proj x) \<in> S" | 
| 155 | by (metis (full_types) DiffE \<open>0 \<in> S\<close> homeomorphism_def image_eqI norm_zero proj_spherI real_vector.scale_zero_left scaleR_one surf) | |
| 156 | have *: "\<exists>y. norm y = 1 \<and> y \<in> affine hull S \<and> x = surf (proj y)" | |
| 157 | if "x \<in> S" "x \<notin> rel_interior S" for x | |
| 158 | proof - | |
| 159 | have "proj x \<in> ?SPHER" | |
| 160 | by (metis (full_types) "0" hull_inc proj_spherI that) | |
| 161 | moreover have "surf (proj x) = x" | |
| 162 | by (metis Diff_iff homeomorphism_def surf that) | |
| 163 | ultimately show ?thesis | |
| 164 | by (metis \<open>\<And>x. x \<in> ?SPHER \<Longrightarrow> surf x \<noteq> 0\<close> hull_inc inverse_1 local.proj_def norm_sgn projI scaleR_one sgn_div_norm that(1)) | |
| 165 | qed | |
| 166 | have surfp_notin: "\<And>x. \<lbrakk>norm x = 1; x \<in> affine hull S\<rbrakk> \<Longrightarrow> surf (proj x) \<notin> rel_interior S" | |
| 167 | by (metis (full_types) DiffE one_neq_zero homeomorphism_def image_eqI norm_zero proj_spherI surf) | |
| 168 | have no_sp_im: "(\<lambda>x. norm x *\<^sub>R surf (proj x)) ` (?SPHER) = S - rel_interior S" | |
| 169 | by (auto simp: surfpS image_def Bex_def surfp_notin *) | |
| 170 | have inj_spher: "inj_on (\<lambda>x. norm x *\<^sub>R surf (proj x)) ?SPHER" | |
| 171 | proof | |
| 172 | fix x y | |
| 173 | assume xy: "x \<in> ?SPHER" "y \<in> ?SPHER" | |
| 174 | and eq: " norm x *\<^sub>R surf (proj x) = norm y *\<^sub>R surf (proj y)" | |
| 175 | then have "norm x = 1" "norm y = 1" "x \<in> affine hull S" "y \<in> affine hull S" | |
| 176 | using 0 by auto | |
| 177 | with eq show "x = y" | |
| 178 | by (simp add: proj_def) (metis surf xy homeomorphism_def) | |
| 179 | qed | |
| 180 | have co01: "compact ?SPHER" | |
| 71172 | 181 | by (simp add: compact_Int_closed) | 
| 63130 | 182 | show "?SMINUS homeomorphic ?SPHER" | 
| 72496 | 183 | using homeomorphic_def surf by blast | 
| 63130 | 184 | have proj_scaleR: "\<And>a x. 0 < a \<Longrightarrow> proj (a *\<^sub>R x) = proj x" | 
| 185 | by (simp add: proj_def) | |
| 186 |   have cont_sp0: "continuous_on (affine hull S - {0}) (surf o proj)"
 | |
| 72496 | 187 | proof (rule continuous_on_compose [OF continuous_on_subset [OF cont_proj]]) | 
| 188 |     show "continuous_on (proj ` (affine hull S - {0})) surf"
 | |
| 189 | using homeomorphism_image1 proj_spherI surf by (intro continuous_on_subset [OF cont_surf]) fastforce | |
| 190 | qed auto | |
| 63130 | 191 | obtain B where "B>0" and B: "\<And>x. x \<in> S \<Longrightarrow> norm x \<le> B" | 
| 192 | by (metis compact_imp_bounded \<open>compact S\<close> bounded_pos_less less_eq_real_def) | |
| 193 | have cont_nosp: "continuous (at x within ?CBALL) (\<lambda>x. norm x *\<^sub>R surf (proj x))" | |
| 194 | if "norm x \<le> 1" "x \<in> affine hull S" for x | |
| 195 | proof (cases "x=0") | |
| 196 | case True | |
| 72496 | 197 | have "(norm \<longlongrightarrow> 0) (at 0 within cball 0 1 \<inter> affine hull S)" | 
| 198 | by (simp add: tendsto_norm_zero eventually_at) | |
| 199 | with True show ?thesis | |
| 63130 | 200 | apply (simp add: continuous_within) | 
| 201 | apply (rule lim_null_scaleR_bounded [where B=B]) | |
| 72496 | 202 | using B \<open>0 < B\<close> local.proj_def projI surfpS by (auto simp: eventually_at) | 
| 63130 | 203 | next | 
| 204 | case False | |
| 205 |     then have "\<forall>\<^sub>F x in at x. (x \<in> affine hull S - {0}) = (x \<in> affine hull S)"
 | |
| 72496 | 206 | by (force simp: False eventually_at) | 
| 207 | moreover | |
| 208 |     have "continuous (at x within affine hull S - {0}) (\<lambda>x. surf (proj x))"
 | |
| 209 | using cont_sp0 False that by (auto simp add: continuous_on_eq_continuous_within) | |
| 210 | ultimately have *: "continuous (at x within affine hull S) (\<lambda>x. surf (proj x))" | |
| 211 | by (simp add: continuous_within Lim_transform_within_set continuous_on_eq_continuous_within) | |
| 63130 | 212 | show ?thesis | 
| 72496 | 213 | by (intro continuous_within_subset [where s = "affine hull S", OF _ Int_lower2] continuous_intros *) | 
| 63130 | 214 | qed | 
| 215 | have cont_nosp2: "continuous_on ?CBALL (\<lambda>x. norm x *\<^sub>R ((surf o proj) x))" | |
| 216 | by (simp add: continuous_on_eq_continuous_within cont_nosp) | |
| 217 | have "norm y *\<^sub>R surf (proj y) \<in> S" if "y \<in> cball 0 1" and yaff: "y \<in> affine hull S" for y | |
| 218 | proof (cases "y=0") | |
| 219 | case True then show ?thesis | |
| 220 | by (simp add: \<open>0 \<in> S\<close>) | |
| 221 | next | |
| 222 | case False | |
| 223 | then have "norm y *\<^sub>R surf (proj y) = norm y *\<^sub>R surf (proj (y /\<^sub>R norm y))" | |
| 224 | by (simp add: proj_def) | |
| 225 | have "norm y \<le> 1" using that by simp | |
| 226 | have "surf (proj (y /\<^sub>R norm y)) \<in> S" | |
| 72496 | 227 | using False local.proj_def nproj1 projI surfpS yaff by blast | 
| 63130 | 228 | then have "surf (proj y) \<in> S" | 
| 229 | by (simp add: False proj_def) | |
| 230 | then show "norm y *\<^sub>R surf (proj y) \<in> S" | |
| 231 | by (metis dual_order.antisym le_less_linear norm_ge_zero rel_interior_subset scaleR_one | |
| 232 | starI subset_eq \<open>norm y \<le> 1\<close>) | |
| 233 | qed | |
| 234 | moreover have "x \<in> (\<lambda>x. norm x *\<^sub>R surf (proj x)) ` (?CBALL)" if "x \<in> S" for x | |
| 235 | proof (cases "x=0") | |
| 236 | case True with that hull_inc show ?thesis by fastforce | |
| 237 | next | |
| 238 | case False | |
| 239 | then have psp: "proj (surf (proj x)) = proj x" | |
| 240 | by (metis homeomorphism_def hull_inc proj_spherI surf that) | |
| 241 | have nxx: "norm x *\<^sub>R proj x = x" | |
| 242 | by (simp add: False local.proj_def) | |
| 243 | have affineI: "(1 / norm (surf (proj x))) *\<^sub>R x \<in> affine hull S" | |
| 244 | by (metis \<open>0 \<in> S\<close> affine_hull_span_0 hull_inc span_clauses(4) that) | |
| 245 | have sproj_nz: "surf (proj x) \<noteq> 0" | |
| 246 | by (metis False proj0_iff psp) | |
| 247 | then have "proj x = proj (proj x)" | |
| 248 | by (metis False nxx proj_scaleR zero_less_norm_iff) | |
| 249 | moreover have scaleproj: "\<And>a r. r *\<^sub>R proj a = (r / norm a) *\<^sub>R a" | |
| 250 | by (simp add: divide_inverse local.proj_def) | |
| 251 | ultimately have "(norm (surf (proj x)) / norm x) *\<^sub>R x \<notin> rel_interior S" | |
| 252 | by (metis (no_types) sproj_nz divide_self_if hull_inc norm_eq_zero nproj1 projI psp scaleR_one surfp_notin that) | |
| 253 | then have "(norm (surf (proj x)) / norm x) \<ge> 1" | |
| 254 | using starI [OF that] by (meson starI [OF that] le_less_linear norm_ge_zero zero_le_divide_iff) | |
| 255 | then have nole: "norm x \<le> norm (surf (proj x))" | |
| 256 | by (simp add: le_divide_eq_1) | |
| 72496 | 257 | let ?inx = "x /\<^sub>R norm (surf (proj x))" | 
| 63130 | 258 | show ?thesis | 
| 72496 | 259 | proof | 
| 260 | show "x = norm ?inx *\<^sub>R surf (proj ?inx)" | |
| 261 | by (simp add: field_simps) (metis inverse_eq_divide nxx positive_imp_inverse_positive proj_scaleR psp scaleproj sproj_nz zero_less_norm_iff) | |
| 262 | qed (auto simp: field_split_simps nole affineI) | |
| 63130 | 263 | qed | 
| 264 | ultimately have im_cball: "(\<lambda>x. norm x *\<^sub>R surf (proj x)) ` ?CBALL = S" | |
| 265 | by blast | |
| 266 | have inj_cball: "inj_on (\<lambda>x. norm x *\<^sub>R surf (proj x)) ?CBALL" | |
| 267 | proof | |
| 268 | fix x y | |
| 269 | assume "x \<in> ?CBALL" "y \<in> ?CBALL" | |
| 270 | and eq: "norm x *\<^sub>R surf (proj x) = norm y *\<^sub>R surf (proj y)" | |
| 271 | then have x: "x \<in> affine hull S" and y: "y \<in> affine hull S" | |
| 272 | using 0 by auto | |
| 273 | show "x = y" | |
| 274 | proof (cases "x=0 \<or> y=0") | |
| 275 | case True then show "x = y" using eq proj_spherI surf_nz x y by force | |
| 276 | next | |
| 277 | case False | |
| 278 | with x y have speq: "surf (proj x) = surf (proj y)" | |
| 279 | by (metis eq homeomorphism_apply2 proj_scaleR proj_spherI surf zero_less_norm_iff) | |
| 280 | then have "norm x = norm y" | |
| 281 | by (metis \<open>x \<in> affine hull S\<close> \<open>y \<in> affine hull S\<close> eq proj_spherI real_vector.scale_cancel_right surf_nz) | |
| 282 | moreover have "proj x = proj y" | |
| 283 | by (metis (no_types) False speq homeomorphism_apply2 proj_spherI surf x y) | |
| 284 | ultimately show "x = y" | |
| 285 | using eq eqI by blast | |
| 286 | qed | |
| 287 | qed | |
| 288 | have co01: "compact ?CBALL" | |
| 71172 | 289 | by (simp add: compact_Int_closed) | 
| 63130 | 290 | show "S homeomorphic ?CBALL" | 
| 72496 | 291 | using homeomorphic_compact [OF co01 cont_nosp2 [unfolded o_def] im_cball inj_cball] homeomorphic_sym by blast | 
| 63130 | 292 | qed | 
| 293 | ||
| 69739 | 294 | corollary | 
| 63130 | 295 | fixes S :: "'a::euclidean_space set" | 
| 296 | assumes "compact S" and a: "a \<in> rel_interior S" | |
| 297 | and star: "\<And>x. x \<in> S \<Longrightarrow> open_segment a x \<subseteq> rel_interior S" | |
| 298 | shows starlike_compact_projective1: | |
| 299 | "S - rel_interior S homeomorphic sphere a 1 \<inter> affine hull S" | |
| 300 | and starlike_compact_projective2: | |
| 301 | "S homeomorphic cball a 1 \<inter> affine hull S" | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 302 | proof - | 
| 67399 | 303 | have 1: "compact ((+) (-a) ` S)" by (meson assms compact_translation) | 
| 304 | have 2: "0 \<in> rel_interior ((+) (-a) ` S)" | |
| 69661 | 305 | using a rel_interior_translation [of "- a" S] by (simp cong: image_cong_simp) | 
| 67399 | 306 | have 3: "open_segment 0 x \<subseteq> rel_interior ((+) (-a) ` S)" if "x \<in> ((+) (-a) ` S)" for x | 
| 63130 | 307 | proof - | 
| 308 | have "x+a \<in> S" using that by auto | |
| 309 | then have "open_segment a (x+a) \<subseteq> rel_interior S" by (metis star) | |
| 69661 | 310 | then show ?thesis using open_segment_translation [of a 0 x] | 
| 311 | using rel_interior_translation [of "- a" S] by (fastforce simp add: ac_simps image_iff cong: image_cong_simp) | |
| 63130 | 312 | qed | 
| 67399 | 313 | have "S - rel_interior S homeomorphic ((+) (-a) ` S) - rel_interior ((+) (-a) ` S)" | 
| 63130 | 314 | by (metis rel_interior_translation translation_diff homeomorphic_translation) | 
| 67399 | 315 | also have "... homeomorphic sphere 0 1 \<inter> affine hull ((+) (-a) ` S)" | 
| 63130 | 316 | by (rule starlike_compact_projective1_0 [OF 1 2 3]) | 
| 67399 | 317 | also have "... = (+) (-a) ` (sphere a 1 \<inter> affine hull S)" | 
| 63130 | 318 | by (metis affine_hull_translation left_minus sphere_translation translation_Int) | 
| 319 | also have "... homeomorphic sphere a 1 \<inter> affine hull S" | |
| 320 | using homeomorphic_translation homeomorphic_sym by blast | |
| 321 | finally show "S - rel_interior S homeomorphic sphere a 1 \<inter> affine hull S" . | |
| 322 | ||
| 67399 | 323 | have "S homeomorphic ((+) (-a) ` S)" | 
| 63130 | 324 | by (metis homeomorphic_translation) | 
| 67399 | 325 | also have "... homeomorphic cball 0 1 \<inter> affine hull ((+) (-a) ` S)" | 
| 63130 | 326 | by (rule starlike_compact_projective2_0 [OF 1 2 3]) | 
| 67399 | 327 | also have "... = (+) (-a) ` (cball a 1 \<inter> affine hull S)" | 
| 63130 | 328 | by (metis affine_hull_translation left_minus cball_translation translation_Int) | 
| 329 | also have "... homeomorphic cball a 1 \<inter> affine hull S" | |
| 330 | using homeomorphic_translation homeomorphic_sym by blast | |
| 331 | finally show "S homeomorphic cball a 1 \<inter> affine hull S" . | |
| 332 | qed | |
| 333 | ||
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 334 | corollary starlike_compact_projective_special: | 
| 63130 | 335 | assumes "compact S" | 
| 336 | and cb01: "cball (0::'a::euclidean_space) 1 \<subseteq> S" | |
| 337 | and scale: "\<And>x u. \<lbrakk>x \<in> S; 0 \<le> u; u < 1\<rbrakk> \<Longrightarrow> u *\<^sub>R x \<in> S - frontier S" | |
| 338 | shows "S homeomorphic (cball (0::'a::euclidean_space) 1)" | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 339 | proof - | 
| 63130 | 340 | have "ball 0 1 \<subseteq> interior S" | 
| 341 | using cb01 interior_cball interior_mono by blast | |
| 342 | then have 0: "0 \<in> rel_interior S" | |
| 343 | by (meson centre_in_ball subsetD interior_subset_rel_interior le_numeral_extra(2) not_le) | |
| 344 | have [simp]: "affine hull S = UNIV" | |
| 345 | using \<open>ball 0 1 \<subseteq> interior S\<close> by (auto intro!: affine_hull_nonempty_interior) | |
| 346 | have star: "open_segment 0 x \<subseteq> rel_interior S" if "x \<in> S" for x | |
| 63627 | 347 | proof | 
| 63130 | 348 | fix p assume "p \<in> open_segment 0 x" | 
| 349 | then obtain u where "x \<noteq> 0" and u: "0 \<le> u" "u < 1" and p: "u *\<^sub>R x = p" | |
| 63627 | 350 | by (auto simp: in_segment) | 
| 63130 | 351 | then show "p \<in> rel_interior S" | 
| 352 | using scale [OF that u] closure_subset frontier_def interior_subset_rel_interior by fastforce | |
| 353 | qed | |
| 354 | show ?thesis | |
| 355 | using starlike_compact_projective2_0 [OF \<open>compact S\<close> 0 star] by simp | |
| 356 | qed | |
| 357 | ||
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 358 | lemma homeomorphic_convex_lemma: | 
| 63130 | 359 | fixes S :: "'a::euclidean_space set" and T :: "'b::euclidean_space set" | 
| 360 | assumes "convex S" "compact S" "convex T" "compact T" | |
| 361 | and affeq: "aff_dim S = aff_dim T" | |
| 362 | shows "(S - rel_interior S) homeomorphic (T - rel_interior T) \<and> | |
| 363 | S homeomorphic T" | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 364 | proof (cases "rel_interior S = {} \<or> rel_interior T = {}")
 | 
| 63130 | 365 | case True | 
| 366 | then show ?thesis | |
| 367 | by (metis Diff_empty affeq \<open>convex S\<close> \<open>convex T\<close> aff_dim_empty homeomorphic_empty rel_interior_eq_empty aff_dim_empty) | |
| 368 | next | |
| 369 | case False | |
| 370 | then obtain a b where a: "a \<in> rel_interior S" and b: "b \<in> rel_interior T" by auto | |
| 371 | have starS: "\<And>x. x \<in> S \<Longrightarrow> open_segment a x \<subseteq> rel_interior S" | |
| 372 | using rel_interior_closure_convex_segment | |
| 373 | a \<open>convex S\<close> closure_subset subsetCE by blast | |
| 374 | have starT: "\<And>x. x \<in> T \<Longrightarrow> open_segment b x \<subseteq> rel_interior T" | |
| 375 | using rel_interior_closure_convex_segment | |
| 376 | b \<open>convex T\<close> closure_subset subsetCE by blast | |
| 67399 | 377 | let ?aS = "(+) (-a) ` S" and ?bT = "(+) (-b) ` T" | 
| 63130 | 378 | have 0: "0 \<in> affine hull ?aS" "0 \<in> affine hull ?bT" | 
| 379 | by (metis a b subsetD hull_inc image_eqI left_minus rel_interior_subset)+ | |
| 380 | have subs: "subspace (span ?aS)" "subspace (span ?bT)" | |
| 381 | by (rule subspace_span)+ | |
| 382 | moreover | |
| 67399 | 383 | have "dim (span ((+) (- a) ` S)) = dim (span ((+) (- b) ` T))" | 
| 63130 | 384 | by (metis 0 aff_dim_translation_eq aff_dim_zero affeq dim_span nat_int) | 
| 385 | ultimately obtain f g where "linear f" "linear g" | |
| 386 | and fim: "f ` span ?aS = span ?bT" | |
| 387 | and gim: "g ` span ?bT = span ?aS" | |
| 388 | and fno: "\<And>x. x \<in> span ?aS \<Longrightarrow> norm(f x) = norm x" | |
| 389 | and gno: "\<And>x. x \<in> span ?bT \<Longrightarrow> norm(g x) = norm x" | |
| 390 | and gf: "\<And>x. x \<in> span ?aS \<Longrightarrow> g(f x) = x" | |
| 391 | and fg: "\<And>x. x \<in> span ?bT \<Longrightarrow> f(g x) = x" | |
| 392 | by (rule isometries_subspaces) blast | |
| 393 | have [simp]: "continuous_on A f" for A | |
| 394 | using \<open>linear f\<close> linear_conv_bounded_linear linear_continuous_on by blast | |
| 395 | have [simp]: "continuous_on B g" for B | |
| 396 | using \<open>linear g\<close> linear_conv_bounded_linear linear_continuous_on by blast | |
| 397 | have eqspanS: "affine hull ?aS = span ?aS" | |
| 398 | by (metis a affine_hull_span_0 subsetD hull_inc image_eqI left_minus rel_interior_subset) | |
| 399 | have eqspanT: "affine hull ?bT = span ?bT" | |
| 400 | by (metis b affine_hull_span_0 subsetD hull_inc image_eqI left_minus rel_interior_subset) | |
| 401 | have "S homeomorphic cball a 1 \<inter> affine hull S" | |
| 402 | by (rule starlike_compact_projective2 [OF \<open>compact S\<close> a starS]) | |
| 67399 | 403 | also have "... homeomorphic (+) (-a) ` (cball a 1 \<inter> affine hull S)" | 
| 63130 | 404 | by (metis homeomorphic_translation) | 
| 67399 | 405 | also have "... = cball 0 1 \<inter> (+) (-a) ` (affine hull S)" | 
| 63130 | 406 | by (auto simp: dist_norm) | 
| 407 | also have "... = cball 0 1 \<inter> span ?aS" | |
| 408 | using eqspanS affine_hull_translation by blast | |
| 409 | also have "... homeomorphic cball 0 1 \<inter> span ?bT" | |
| 72496 | 410 | proof (rule homeomorphicI) | 
| 411 | show fim1: "f ` (cball 0 1 \<inter> span ?aS) = cball 0 1 \<inter> span ?bT" | |
| 412 | proof | |
| 413 | show "f ` (cball 0 1 \<inter> span ?aS) \<subseteq> cball 0 1 \<inter> span ?bT" | |
| 414 | using fim fno by auto | |
| 415 | show "cball 0 1 \<inter> span ?bT \<subseteq> f ` (cball 0 1 \<inter> span ?aS)" | |
| 416 | by clarify (metis IntI fg gim gno image_eqI mem_cball_0) | |
| 417 | qed | |
| 418 | show "g ` (cball 0 1 \<inter> span ?bT) = cball 0 1 \<inter> span ?aS" | |
| 419 | proof | |
| 420 | show "g ` (cball 0 1 \<inter> span ?bT) \<subseteq> cball 0 1 \<inter> span ?aS" | |
| 421 | using gim gno by auto | |
| 422 | show "cball 0 1 \<inter> span ?aS \<subseteq> g ` (cball 0 1 \<inter> span ?bT)" | |
| 423 | by clarify (metis IntI fim1 gf image_eqI) | |
| 424 | qed | |
| 425 | qed (auto simp: fg gf) | |
| 67399 | 426 | also have "... = cball 0 1 \<inter> (+) (-b) ` (affine hull T)" | 
| 63130 | 427 | using eqspanT affine_hull_translation by blast | 
| 67399 | 428 | also have "... = (+) (-b) ` (cball b 1 \<inter> affine hull T)" | 
| 63130 | 429 | by (auto simp: dist_norm) | 
| 430 | also have "... homeomorphic (cball b 1 \<inter> affine hull T)" | |
| 431 | by (metis homeomorphic_translation homeomorphic_sym) | |
| 432 | also have "... homeomorphic T" | |
| 433 | by (metis starlike_compact_projective2 [OF \<open>compact T\<close> b starT] homeomorphic_sym) | |
| 434 | finally have 1: "S homeomorphic T" . | |
| 435 | ||
| 436 | have "S - rel_interior S homeomorphic sphere a 1 \<inter> affine hull S" | |
| 437 | by (rule starlike_compact_projective1 [OF \<open>compact S\<close> a starS]) | |
| 67399 | 438 | also have "... homeomorphic (+) (-a) ` (sphere a 1 \<inter> affine hull S)" | 
| 63130 | 439 | by (metis homeomorphic_translation) | 
| 67399 | 440 | also have "... = sphere 0 1 \<inter> (+) (-a) ` (affine hull S)" | 
| 63130 | 441 | by (auto simp: dist_norm) | 
| 442 | also have "... = sphere 0 1 \<inter> span ?aS" | |
| 443 | using eqspanS affine_hull_translation by blast | |
| 444 | also have "... homeomorphic sphere 0 1 \<inter> span ?bT" | |
| 72496 | 445 | proof (rule homeomorphicI) | 
| 446 | show fim1: "f ` (sphere 0 1 \<inter> span ?aS) = sphere 0 1 \<inter> span ?bT" | |
| 447 | proof | |
| 448 | show "f ` (sphere 0 1 \<inter> span ?aS) \<subseteq> sphere 0 1 \<inter> span ?bT" | |
| 449 | using fim fno by auto | |
| 450 | show "sphere 0 1 \<inter> span ?bT \<subseteq> f ` (sphere 0 1 \<inter> span ?aS)" | |
| 451 | by clarify (metis IntI fg gim gno image_eqI mem_sphere_0) | |
| 452 | qed | |
| 453 | show "g ` (sphere 0 1 \<inter> span ?bT) = sphere 0 1 \<inter> span ?aS" | |
| 454 | proof | |
| 455 | show "g ` (sphere 0 1 \<inter> span ?bT) \<subseteq> sphere 0 1 \<inter> span ?aS" | |
| 456 | using gim gno by auto | |
| 457 | show "sphere 0 1 \<inter> span ?aS \<subseteq> g ` (sphere 0 1 \<inter> span ?bT)" | |
| 458 | by clarify (metis IntI fim1 gf image_eqI) | |
| 459 | qed | |
| 460 | qed (auto simp: fg gf) | |
| 67399 | 461 | also have "... = sphere 0 1 \<inter> (+) (-b) ` (affine hull T)" | 
| 63130 | 462 | using eqspanT affine_hull_translation by blast | 
| 67399 | 463 | also have "... = (+) (-b) ` (sphere b 1 \<inter> affine hull T)" | 
| 63130 | 464 | by (auto simp: dist_norm) | 
| 465 | also have "... homeomorphic (sphere b 1 \<inter> affine hull T)" | |
| 466 | by (metis homeomorphic_translation homeomorphic_sym) | |
| 467 | also have "... homeomorphic T - rel_interior T" | |
| 468 | by (metis starlike_compact_projective1 [OF \<open>compact T\<close> b starT] homeomorphic_sym) | |
| 469 | finally have 2: "S - rel_interior S homeomorphic T - rel_interior T" . | |
| 470 | show ?thesis | |
| 471 | using 1 2 by blast | |
| 472 | qed | |
| 473 | ||
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 474 | lemma homeomorphic_convex_compact_sets: | 
| 63130 | 475 | fixes S :: "'a::euclidean_space set" and T :: "'b::euclidean_space set" | 
| 476 | assumes "convex S" "compact S" "convex T" "compact T" | |
| 477 | and affeq: "aff_dim S = aff_dim T" | |
| 478 | shows "S homeomorphic T" | |
| 479 | using homeomorphic_convex_lemma [OF assms] assms | |
| 480 | by (auto simp: rel_frontier_def) | |
| 481 | ||
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 482 | lemma homeomorphic_rel_frontiers_convex_bounded_sets: | 
| 63130 | 483 | fixes S :: "'a::euclidean_space set" and T :: "'b::euclidean_space set" | 
| 484 | assumes "convex S" "bounded S" "convex T" "bounded T" | |
| 485 | and affeq: "aff_dim S = aff_dim T" | |
| 486 | shows "rel_frontier S homeomorphic rel_frontier T" | |
| 487 | using assms homeomorphic_convex_lemma [of "closure S" "closure T"] | |
| 488 | by (simp add: rel_frontier_def convex_rel_interior_closure) | |
| 489 | ||
| 490 | ||
| 69683 | 491 | subsection\<open>Homeomorphisms between punctured spheres and affine sets\<close> | 
| 63130 | 492 | text\<open>Including the famous stereoscopic projection of the 3-D sphere to the complex plane\<close> | 
| 493 | ||
| 494 | text\<open>The special case with centre 0 and radius 1\<close> | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 495 | lemma homeomorphic_punctured_affine_sphere_affine_01: | 
| 63130 | 496 | assumes "b \<in> sphere 0 1" "affine T" "0 \<in> T" "b \<in> T" "affine p" | 
| 497 | and affT: "aff_dim T = aff_dim p + 1" | |
| 498 |     shows "(sphere 0 1 \<inter> T) - {b} homeomorphic p"
 | |
| 499 | proof - | |
| 500 | have [simp]: "norm b = 1" "b\<bullet>b = 1" | |
| 501 | using assms by (auto simp: norm_eq_1) | |
| 502 |   have [simp]: "T \<inter> {v. b\<bullet>v = 0} \<noteq> {}"
 | |
| 503 | using \<open>0 \<in> T\<close> by auto | |
| 504 |   have [simp]: "\<not> T \<subseteq> {v. b\<bullet>v = 0}"
 | |
| 505 | using \<open>norm b = 1\<close> \<open>b \<in> T\<close> by auto | |
| 506 | define f where "f \<equiv> \<lambda>x. 2 *\<^sub>R b + (2 / (1 - b\<bullet>x)) *\<^sub>R (x - b)" | |
| 507 | define g where "g \<equiv> \<lambda>y. b + (4 / (norm y ^ 2 + 4)) *\<^sub>R (y - 2 *\<^sub>R b)" | |
| 72496 | 508 | have fg[simp]: "\<And>x. \<lbrakk>x \<in> T; b\<bullet>x = 0\<rbrakk> \<Longrightarrow> f (g x) = x" | 
| 70817 
dd675800469d
dedicated fact collections for algebraic simplification rules potentially splitting goals
 haftmann parents: 
70802diff
changeset | 509 | unfolding f_def g_def by (simp add: algebra_simps field_split_simps add_nonneg_eq_0_iff) | 
| 
dd675800469d
dedicated fact collections for algebraic simplification rules potentially splitting goals
 haftmann parents: 
70802diff
changeset | 510 | have no: "(norm (f x))\<^sup>2 = 4 * (1 + b \<bullet> x) / (1 - b \<bullet> x)" | 
| 
dd675800469d
dedicated fact collections for algebraic simplification rules potentially splitting goals
 haftmann parents: 
70802diff
changeset | 511 | if "norm x = 1" and "b \<bullet> x \<noteq> 1" for x | 
| 72496 | 512 | using that sum_sqs_eq [of 1 "b \<bullet> x"] | 
| 70817 
dd675800469d
dedicated fact collections for algebraic simplification rules potentially splitting goals
 haftmann parents: 
70802diff
changeset | 513 | apply (simp flip: dot_square_norm add: norm_eq_1 nonzero_eq_divide_eq) | 
| 
dd675800469d
dedicated fact collections for algebraic simplification rules potentially splitting goals
 haftmann parents: 
70802diff
changeset | 514 | apply (simp add: f_def vector_add_divide_simps inner_simps) | 
| 72496 | 515 | apply (auto simp add: field_split_simps inner_commute) | 
| 63130 | 516 | done | 
| 517 | have [simp]: "\<And>u::real. 8 + u * (u * 8) = u * 16 \<longleftrightarrow> u=1" | |
| 518 | by algebra | |
| 72496 | 519 | have gf[simp]: "\<And>x. \<lbrakk>norm x = 1; b \<bullet> x \<noteq> 1\<rbrakk> \<Longrightarrow> g (f x) = x" | 
| 70817 
dd675800469d
dedicated fact collections for algebraic simplification rules potentially splitting goals
 haftmann parents: 
70802diff
changeset | 520 | unfolding g_def no by (auto simp: f_def field_split_simps) | 
| 72496 | 521 | have g1: "norm (g x) = 1" if "x \<in> T" and "b \<bullet> x = 0" for x | 
| 70817 
dd675800469d
dedicated fact collections for algebraic simplification rules potentially splitting goals
 haftmann parents: 
70802diff
changeset | 522 | using that | 
| 
dd675800469d
dedicated fact collections for algebraic simplification rules potentially splitting goals
 haftmann parents: 
70802diff
changeset | 523 | apply (simp only: g_def) | 
| 63130 | 524 | apply (rule power2_eq_imp_eq) | 
| 525 | apply (simp_all add: dot_square_norm [symmetric] divide_simps vector_add_divide_simps) | |
| 526 | apply (simp add: algebra_simps inner_commute) | |
| 527 | done | |
| 72496 | 528 | have ne1: "b \<bullet> g x \<noteq> 1" if "x \<in> T" and "b \<bullet> x = 0" for x | 
| 70817 
dd675800469d
dedicated fact collections for algebraic simplification rules potentially splitting goals
 haftmann parents: 
70802diff
changeset | 529 | using that unfolding g_def | 
| 63130 | 530 | apply (simp_all add: dot_square_norm [symmetric] divide_simps vector_add_divide_simps add_nonneg_eq_0_iff) | 
| 531 | apply (auto simp: algebra_simps) | |
| 532 | done | |
| 533 | have "subspace T" | |
| 534 | by (simp add: assms subspace_affine) | |
| 72496 | 535 | have gT: "\<And>x. \<lbrakk>x \<in> T; b \<bullet> x = 0\<rbrakk> \<Longrightarrow> g x \<in> T" | 
| 63130 | 536 | unfolding g_def | 
| 537 | by (blast intro: \<open>subspace T\<close> \<open>b \<in> T\<close> subspace_add subspace_mul subspace_diff) | |
| 538 |   have "f ` {x. norm x = 1 \<and> b\<bullet>x \<noteq> 1} \<subseteq> {x. b\<bullet>x = 0}"
 | |
| 539 | unfolding f_def using \<open>norm b = 1\<close> norm_eq_1 | |
| 540 | by (force simp: field_simps inner_add_right inner_diff_right) | |
| 541 | moreover have "f ` T \<subseteq> T" | |
| 70802 
160eaf566bcb
formally augmented corresponding rules for field_simps
 haftmann parents: 
70620diff
changeset | 542 | unfolding f_def using assms \<open>subspace T\<close> | 
| 
160eaf566bcb
formally augmented corresponding rules for field_simps
 haftmann parents: 
70620diff
changeset | 543 | by (auto simp add: inner_add_right inner_diff_right mem_affine_3_minus subspace_mul) | 
| 63130 | 544 |   moreover have "{x. b\<bullet>x = 0} \<inter> T \<subseteq> f ` ({x. norm x = 1 \<and> b\<bullet>x \<noteq> 1} \<inter> T)"
 | 
| 72496 | 545 | by clarify (metis (mono_tags) IntI ne1 fg gT g1 imageI mem_Collect_eq) | 
| 63130 | 546 |   ultimately have imf: "f ` ({x. norm x = 1 \<and> b\<bullet>x \<noteq> 1} \<inter> T) = {x. b\<bullet>x = 0} \<inter> T"
 | 
| 547 | by blast | |
| 548 | have no4: "\<And>y. b\<bullet>y = 0 \<Longrightarrow> norm ((y\<bullet>y + 4) *\<^sub>R b + 4 *\<^sub>R (y - 2 *\<^sub>R b)) = y\<bullet>y + 4" | |
| 549 | apply (rule power2_eq_imp_eq) | |
| 72496 | 550 | apply (simp_all flip: dot_square_norm) | 
| 63130 | 551 | apply (auto simp: power2_eq_square algebra_simps inner_commute) | 
| 552 | done | |
| 553 | have [simp]: "\<And>x. \<lbrakk>norm x = 1; b \<bullet> x \<noteq> 1\<rbrakk> \<Longrightarrow> b \<bullet> f x = 0" | |
| 70817 
dd675800469d
dedicated fact collections for algebraic simplification rules potentially splitting goals
 haftmann parents: 
70802diff
changeset | 554 | by (simp add: f_def algebra_simps field_split_simps) | 
| 63130 | 555 | have [simp]: "\<And>x. \<lbrakk>x \<in> T; norm x = 1; b \<bullet> x \<noteq> 1\<rbrakk> \<Longrightarrow> f x \<in> T" | 
| 556 | unfolding f_def | |
| 557 | by (blast intro: \<open>subspace T\<close> \<open>b \<in> T\<close> subspace_add subspace_mul subspace_diff) | |
| 558 |   have "g ` {x. b\<bullet>x = 0} \<subseteq> {x. norm x = 1 \<and> b\<bullet>x \<noteq> 1}"
 | |
| 559 | unfolding g_def | |
| 560 | apply (clarsimp simp: no4 vector_add_divide_simps divide_simps add_nonneg_eq_0_iff dot_square_norm [symmetric]) | |
| 561 | apply (auto simp: algebra_simps) | |
| 562 | done | |
| 563 | moreover have "g ` T \<subseteq> T" | |
| 564 | unfolding g_def | |
| 565 | by (blast intro: \<open>subspace T\<close> \<open>b \<in> T\<close> subspace_add subspace_mul subspace_diff) | |
| 566 |   moreover have "{x. norm x = 1 \<and> b\<bullet>x \<noteq> 1} \<inter> T \<subseteq> g ` ({x. b\<bullet>x = 0} \<inter> T)"
 | |
| 72496 | 567 | by clarify (metis (mono_tags, lifting) IntI gf image_iff imf mem_Collect_eq) | 
| 63130 | 568 |   ultimately have img: "g ` ({x. b\<bullet>x = 0} \<inter> T) = {x. norm x = 1 \<and> b\<bullet>x \<noteq> 1} \<inter> T"
 | 
| 569 | by blast | |
| 570 |   have aff: "affine ({x. b\<bullet>x = 0} \<inter> T)"
 | |
| 571 | by (blast intro: affine_hyperplane assms) | |
| 572 |   have contf: "continuous_on ({x. norm x = 1 \<and> b\<bullet>x \<noteq> 1} \<inter> T) f"
 | |
| 573 | unfolding f_def by (rule continuous_intros | force)+ | |
| 574 |   have contg: "continuous_on ({x. b\<bullet>x = 0} \<inter> T) g"
 | |
| 575 | unfolding g_def by (rule continuous_intros | force simp: add_nonneg_eq_0_iff)+ | |
| 576 |   have "(sphere 0 1 \<inter> T) - {b} = {x. norm x = 1 \<and> (b\<bullet>x \<noteq> 1)} \<inter> T"
 | |
| 577 | using \<open>norm b = 1\<close> by (auto simp: norm_eq_1) (metis vector_eq \<open>b\<bullet>b = 1\<close>) | |
| 578 |   also have "... homeomorphic {x. b\<bullet>x = 0} \<inter> T"
 | |
| 579 | by (rule homeomorphicI [OF imf img contf contg]) auto | |
| 580 | also have "... homeomorphic p" | |
| 72496 | 581 | proof (rule homeomorphic_affine_sets [OF aff \<open>affine p\<close>]) | 
| 582 |     show "aff_dim ({x. b \<bullet> x = 0} \<inter> T) = aff_dim p"
 | |
| 583 | by (simp add: Int_commute aff_dim_affine_Int_hyperplane [OF \<open>affine T\<close>] affT) | |
| 584 | qed | |
| 63130 | 585 | finally show ?thesis . | 
| 586 | qed | |
| 587 | ||
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 588 | theorem homeomorphic_punctured_affine_sphere_affine: | 
| 63130 | 589 | fixes a :: "'a :: euclidean_space" | 
| 590 | assumes "0 < r" "b \<in> sphere a r" "affine T" "a \<in> T" "b \<in> T" "affine p" | |
| 591 | and aff: "aff_dim T = aff_dim p + 1" | |
| 66710 
676258a1cf01
eliminated a needless dependence on the theorem homeomorphic_punctured_sphere_affine_gen
 paulson <lp15@cam.ac.uk> parents: 
66690diff
changeset | 592 |     shows "(sphere a r \<inter> T) - {b} homeomorphic p"
 | 
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 593 | proof - | 
| 63130 | 594 | have "a \<noteq> b" using assms by auto | 
| 595 | then have inj: "inj (\<lambda>x::'a. x /\<^sub>R norm (a - b))" | |
| 596 | by (simp add: inj_on_def) | |
| 597 |   have "((sphere a r \<inter> T) - {b}) homeomorphic
 | |
| 67399 | 598 |         (+) (-a) ` ((sphere a r \<inter> T) - {b})"
 | 
| 63130 | 599 | by (rule homeomorphic_translation) | 
| 69064 
5840724b1d71
Prefix form of infix with * on either side no longer needs special treatment
 nipkow parents: 
68833diff
changeset | 600 |   also have "... homeomorphic (*\<^sub>R) (inverse r) ` (+) (- a) ` (sphere a r \<inter> T - {b})"
 | 
| 63130 | 601 | by (metis \<open>0 < r\<close> homeomorphic_scaling inverse_inverse_eq inverse_zero less_irrefl) | 
| 69064 
5840724b1d71
Prefix form of infix with * on either side no longer needs special treatment
 nipkow parents: 
68833diff
changeset | 602 |   also have "... = sphere 0 1 \<inter> ((*\<^sub>R) (inverse r) ` (+) (- a) ` T) - {(b - a) /\<^sub>R r}"
 | 
| 63130 | 603 | using assms by (auto simp: dist_norm norm_minus_commute divide_simps) | 
| 604 | also have "... homeomorphic p" | |
| 69661 | 605 | using assms affine_translation [symmetric, of "- a"] aff_dim_translation_eq [of "- a"] | 
| 72496 | 606 | by (intro homeomorphic_punctured_affine_sphere_affine_01) (auto simp: dist_norm norm_minus_commute affine_scaling inj) | 
| 63130 | 607 | finally show ?thesis . | 
| 608 | qed | |
| 609 | ||
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 610 | corollary homeomorphic_punctured_sphere_affine: | 
| 66710 
676258a1cf01
eliminated a needless dependence on the theorem homeomorphic_punctured_sphere_affine_gen
 paulson <lp15@cam.ac.uk> parents: 
66690diff
changeset | 611 | fixes a :: "'a :: euclidean_space" | 
| 
676258a1cf01
eliminated a needless dependence on the theorem homeomorphic_punctured_sphere_affine_gen
 paulson <lp15@cam.ac.uk> parents: 
66690diff
changeset | 612 | assumes "0 < r" and b: "b \<in> sphere a r" | 
| 
676258a1cf01
eliminated a needless dependence on the theorem homeomorphic_punctured_sphere_affine_gen
 paulson <lp15@cam.ac.uk> parents: 
66690diff
changeset | 613 |       and "affine T" and affS: "aff_dim T + 1 = DIM('a)"
 | 
| 
676258a1cf01
eliminated a needless dependence on the theorem homeomorphic_punctured_sphere_affine_gen
 paulson <lp15@cam.ac.uk> parents: 
66690diff
changeset | 614 |     shows "(sphere a r - {b}) homeomorphic T"
 | 
| 70136 | 615 | using homeomorphic_punctured_affine_sphere_affine [of r b a UNIV T] assms by auto | 
| 66710 
676258a1cf01
eliminated a needless dependence on the theorem homeomorphic_punctured_sphere_affine_gen
 paulson <lp15@cam.ac.uk> parents: 
66690diff
changeset | 616 | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 617 | corollary homeomorphic_punctured_sphere_hyperplane: | 
| 66710 
676258a1cf01
eliminated a needless dependence on the theorem homeomorphic_punctured_sphere_affine_gen
 paulson <lp15@cam.ac.uk> parents: 
66690diff
changeset | 618 | fixes a :: "'a :: euclidean_space" | 
| 
676258a1cf01
eliminated a needless dependence on the theorem homeomorphic_punctured_sphere_affine_gen
 paulson <lp15@cam.ac.uk> parents: 
66690diff
changeset | 619 | assumes "0 < r" and b: "b \<in> sphere a r" | 
| 72496 | 620 | and "c \<noteq> 0" | 
| 621 |   shows "(sphere a r - {b}) homeomorphic {x::'a. c \<bullet> x = d}"
 | |
| 622 | using assms | |
| 623 | by (intro homeomorphic_punctured_sphere_affine) (auto simp: affine_hyperplane of_nat_diff) | |
| 66710 
676258a1cf01
eliminated a needless dependence on the theorem homeomorphic_punctured_sphere_affine_gen
 paulson <lp15@cam.ac.uk> parents: 
66690diff
changeset | 624 | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 625 | proposition homeomorphic_punctured_sphere_affine_gen: | 
| 63130 | 626 | fixes a :: "'a :: euclidean_space" | 
| 627 | assumes "convex S" "bounded S" and a: "a \<in> rel_frontier S" | |
| 628 | and "affine T" and affS: "aff_dim S = aff_dim T + 1" | |
| 629 |     shows "rel_frontier S - {a} homeomorphic T"
 | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 630 | proof - | 
| 66690 
6953b1a29e19
Tiny presentational improvements to homeomorphic_punctured_sphere_affine_gen
 paulson <lp15@cam.ac.uk> parents: 
66287diff
changeset | 631 | obtain U :: "'a set" where "affine U" "convex U" and affdS: "aff_dim U = aff_dim S" | 
| 63130 | 632 | using choose_affine_subset [OF affine_UNIV aff_dim_geq] | 
| 66690 
6953b1a29e19
Tiny presentational improvements to homeomorphic_punctured_sphere_affine_gen
 paulson <lp15@cam.ac.uk> parents: 
66287diff
changeset | 633 | by (meson aff_dim_affine_hull affine_affine_hull affine_imp_convex) | 
| 
6953b1a29e19
Tiny presentational improvements to homeomorphic_punctured_sphere_affine_gen
 paulson <lp15@cam.ac.uk> parents: 
66287diff
changeset | 634 |   have "S \<noteq> {}" using assms by auto
 | 
| 63130 | 635 | then obtain z where "z \<in> U" | 
| 66690 
6953b1a29e19
Tiny presentational improvements to homeomorphic_punctured_sphere_affine_gen
 paulson <lp15@cam.ac.uk> parents: 
66287diff
changeset | 636 | by (metis aff_dim_negative_iff equals0I affdS) | 
| 63130 | 637 |   then have bne: "ball z 1 \<inter> U \<noteq> {}" by force
 | 
| 66690 
6953b1a29e19
Tiny presentational improvements to homeomorphic_punctured_sphere_affine_gen
 paulson <lp15@cam.ac.uk> parents: 
66287diff
changeset | 638 | then have [simp]: "aff_dim(ball z 1 \<inter> U) = aff_dim U" | 
| 
6953b1a29e19
Tiny presentational improvements to homeomorphic_punctured_sphere_affine_gen
 paulson <lp15@cam.ac.uk> parents: 
66287diff
changeset | 639 | using aff_dim_convex_Int_open [OF \<open>convex U\<close> open_ball] | 
| 63130 | 640 | by (fastforce simp add: Int_commute) | 
| 641 | have "rel_frontier S homeomorphic rel_frontier (ball z 1 \<inter> U)" | |
| 68006 | 642 | by (rule homeomorphic_rel_frontiers_convex_bounded_sets) | 
| 643 | (auto simp: \<open>affine U\<close> affine_imp_convex convex_Int affdS assms) | |
| 63130 | 644 | also have "... = sphere z 1 \<inter> U" | 
| 645 | using convex_affine_rel_frontier_Int [of "ball z 1" U] | |
| 646 | by (simp add: \<open>affine U\<close> bne) | |
| 66690 
6953b1a29e19
Tiny presentational improvements to homeomorphic_punctured_sphere_affine_gen
 paulson <lp15@cam.ac.uk> parents: 
66287diff
changeset | 647 | finally have "rel_frontier S homeomorphic sphere z 1 \<inter> U" . | 
| 
6953b1a29e19
Tiny presentational improvements to homeomorphic_punctured_sphere_affine_gen
 paulson <lp15@cam.ac.uk> parents: 
66287diff
changeset | 648 | then obtain h k where him: "h ` rel_frontier S = sphere z 1 \<inter> U" | 
| 63130 | 649 | and kim: "k ` (sphere z 1 \<inter> U) = rel_frontier S" | 
| 650 | and hcon: "continuous_on (rel_frontier S) h" | |
| 651 | and kcon: "continuous_on (sphere z 1 \<inter> U) k" | |
| 652 | and kh: "\<And>x. x \<in> rel_frontier S \<Longrightarrow> k(h(x)) = x" | |
| 653 | and hk: "\<And>y. y \<in> sphere z 1 \<inter> U \<Longrightarrow> h(k(y)) = y" | |
| 654 | unfolding homeomorphic_def homeomorphism_def by auto | |
| 655 |   have "rel_frontier S - {a} homeomorphic (sphere z 1 \<inter> U) - {h a}"
 | |
| 66690 
6953b1a29e19
Tiny presentational improvements to homeomorphic_punctured_sphere_affine_gen
 paulson <lp15@cam.ac.uk> parents: 
66287diff
changeset | 656 | proof (rule homeomorphicI) | 
| 63130 | 657 |     show h: "h ` (rel_frontier S - {a}) = sphere z 1 \<inter> U - {h a}"
 | 
| 658 | using him a kh by auto metis | |
| 659 |     show "k ` (sphere z 1 \<inter> U - {h a}) = rel_frontier S - {a}"
 | |
| 660 | by (force simp: h [symmetric] image_comp o_def kh) | |
| 661 | qed (auto intro: continuous_on_subset hcon kcon simp: kh hk) | |
| 662 | also have "... homeomorphic T" | |
| 68006 | 663 | by (rule homeomorphic_punctured_affine_sphere_affine) | 
| 664 | (use a him in \<open>auto simp: affS affdS \<open>affine T\<close> \<open>affine U\<close> \<open>z \<in> U\<close>\<close>) | |
| 63130 | 665 | finally show ?thesis . | 
| 666 | qed | |
| 667 | ||
| 668 | ||
| 669 | text\<open> When dealing with AR, ANR and ANR later, it's useful to know that every set | |
| 670 | is homeomorphic to a closed subset of a convex set, and | |
| 671 | if the set is locally compact we can take the convex set to be the universe.\<close> | |
| 672 | ||
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 673 | proposition homeomorphic_closedin_convex: | 
| 63130 | 674 | fixes S :: "'m::euclidean_space set" | 
| 675 |   assumes "aff_dim S < DIM('n)"
 | |
| 676 | obtains U and T :: "'n::euclidean_space set" | |
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 677 |      where "convex U" "U \<noteq> {}" "closedin (top_of_set U) T"
 | 
| 63130 | 678 | "S homeomorphic T" | 
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 679 | proof (cases "S = {}")
 | 
| 63130 | 680 | case True then show ?thesis | 
| 681 |     by (rule_tac U=UNIV and T="{}" in that) auto
 | |
| 682 | next | |
| 683 | case False | |
| 684 | then obtain a where "a \<in> S" by auto | |
| 685 | obtain i::'n where i: "i \<in> Basis" "i \<noteq> 0" | |
| 686 | using SOME_Basis Basis_zero by force | |
| 67399 | 687 | have "0 \<in> affine hull ((+) (- a) ` S)" | 
| 63130 | 688 | by (simp add: \<open>a \<in> S\<close> hull_inc) | 
| 67399 | 689 | then have "dim ((+) (- a) ` S) = aff_dim ((+) (- a) ` S)" | 
| 63130 | 690 | by (simp add: aff_dim_zero) | 
| 691 |   also have "... < DIM('n)"
 | |
| 69661 | 692 | by (simp add: aff_dim_translation_eq_subtract assms cong: image_cong_simp) | 
| 67399 | 693 |   finally have dd: "dim ((+) (- a) ` S) < DIM('n)"
 | 
| 63130 | 694 | by linarith | 
| 69661 | 695 |   have span: "span {x. i \<bullet> x = 0} = {x. i \<bullet> x = 0}"
 | 
| 696 |     using span_eq_iff [symmetric, of "{x. i \<bullet> x = 0}"] subspace_hyperplane [of i] by simp
 | |
| 697 |   have "dim ((+) (- a) ` S) \<le> dim {x. i \<bullet> x = 0}"
 | |
| 698 | using dd by (simp add: dim_hyperplane [OF \<open>i \<noteq> 0\<close>]) | |
| 699 |   then obtain T where "subspace T" and Tsub: "T \<subseteq> {x. i \<bullet> x = 0}"
 | |
| 700 | and dimT: "dim T = dim ((+) (- a) ` S)" | |
| 701 | by (rule choose_subspace_of_subspace) (simp add: span) | |
| 67399 | 702 | have "subspace (span ((+) (- a) ` S))" | 
| 63130 | 703 | using subspace_span by blast | 
| 704 | then obtain h k where "linear h" "linear k" | |
| 67399 | 705 | and heq: "h ` span ((+) (- a) ` S) = T" | 
| 706 | and keq:"k ` T = span ((+) (- a) ` S)" | |
| 707 | and hinv [simp]: "\<And>x. x \<in> span ((+) (- a) ` S) \<Longrightarrow> k(h x) = x" | |
| 63130 | 708 | and kinv [simp]: "\<And>x. x \<in> T \<Longrightarrow> h(k x) = x" | 
| 72496 | 709 | by (auto simp: dimT intro: isometries_subspaces [OF _ \<open>subspace T\<close>] dimT) | 
| 63130 | 710 | have hcont: "continuous_on A h" and kcont: "continuous_on B k" for A B | 
| 711 | using \<open>linear h\<close> \<open>linear k\<close> linear_continuous_on linear_conv_bounded_linear by blast+ | |
| 712 | have ihhhh[simp]: "\<And>x. x \<in> S \<Longrightarrow> i \<bullet> h (x - a) = 0" | |
| 68072 
493b818e8e10
added Johannes' generalizations Modules.thy and Vector_Spaces.thy; adapted HOL and HOL-Analysis accordingly
 immler parents: 
67399diff
changeset | 713 | using Tsub [THEN subsetD] heq span_superset by fastforce | 
| 63130 | 714 |   have "sphere 0 1 - {i} homeomorphic {x. i \<bullet> x = 0}"
 | 
| 72496 | 715 | proof (rule homeomorphic_punctured_sphere_affine) | 
| 716 |     show "affine {x. i \<bullet> x = 0}"
 | |
| 717 | by (auto simp: affine_hyperplane) | |
| 718 |     show "aff_dim {x. i \<bullet> x = 0} + 1 = int DIM('n)"
 | |
| 719 | using i by clarsimp (metis DIM_positive Suc_pred add.commute of_nat_Suc) | |
| 720 | qed (use i in auto) | |
| 63130 | 721 |   then obtain f g where fg: "homeomorphism (sphere 0 1 - {i}) {x. i \<bullet> x = 0} f g"
 | 
| 722 | by (force simp: homeomorphic_def) | |
| 723 | show ?thesis | |
| 72496 | 724 | proof | 
| 725 | have "h ` (+) (- a) ` S \<subseteq> T" | |
| 726 | using heq span_superset span_linear_image by blast | |
| 727 |     then have "g ` h ` (+) (- a) ` S \<subseteq> g ` {x. i \<bullet> x = 0}"
 | |
| 728 | using Tsub by (simp add: image_mono) | |
| 729 |     also have "... \<subseteq> sphere 0 1 - {i}"
 | |
| 730 | by (simp add: fg [unfolded homeomorphism_def]) | |
| 731 |     finally have gh_sub_sph: "(g \<circ> h) ` (+) (- a) ` S \<subseteq> sphere 0 1 - {i}"
 | |
| 732 | by (metis image_comp) | |
| 733 | then have gh_sub_cb: "(g \<circ> h) ` (+) (- a) ` S \<subseteq> cball 0 1" | |
| 734 | by (metis Diff_subset order_trans sphere_cball) | |
| 735 | have [simp]: "\<And>u. u \<in> S \<Longrightarrow> norm (g (h (u - a))) = 1" | |
| 736 | using gh_sub_sph [THEN subsetD] by (auto simp: o_def) | |
| 737 | show "convex (ball 0 1 \<union> (g \<circ> h) ` (+) (- a) ` S)" | |
| 738 | by (meson ball_subset_cball convex_intermediate_ball gh_sub_cb sup.bounded_iff sup.cobounded1) | |
| 739 | show "closedin (top_of_set (ball 0 1 \<union> (g \<circ> h) ` (+) (- a) ` S)) ((g \<circ> h) ` (+) (- a) ` S)" | |
| 740 | unfolding closedin_closed | |
| 741 | by (rule_tac x="sphere 0 1" in exI) auto | |
| 742 | have ghcont: "continuous_on ((\<lambda>x. x - a) ` S) (\<lambda>x. g (h x))" | |
| 743 | by (rule continuous_on_compose2 [OF homeomorphism_cont2 [OF fg] hcont], force) | |
| 744 | have kfcont: "continuous_on ((\<lambda>x. g (h (x - a))) ` S) (\<lambda>x. k (f x))" | |
| 745 | proof (rule continuous_on_compose2 [OF kcont]) | |
| 746 | show "continuous_on ((\<lambda>x. g (h (x - a))) ` S) f" | |
| 747 | using homeomorphism_cont1 [OF fg] gh_sub_sph by (fastforce intro: continuous_on_subset) | |
| 748 | qed auto | |
| 749 | have "S homeomorphic (+) (- a) ` S" | |
| 750 | by (fact homeomorphic_translation) | |
| 751 | also have "\<dots> homeomorphic (g \<circ> h) ` (+) (- a) ` S" | |
| 752 | apply (simp add: homeomorphic_def homeomorphism_def cong: image_cong_simp) | |
| 753 | apply (rule_tac x="g \<circ> h" in exI) | |
| 754 | apply (rule_tac x="k \<circ> f" in exI) | |
| 755 | apply (auto simp: ghcont kfcont span_base homeomorphism_apply2 [OF fg] image_comp cong: image_cong_simp) | |
| 756 | done | |
| 757 | finally show "S homeomorphic (g \<circ> h) ` (+) (- a) ` S" . | |
| 758 | qed auto | |
| 63130 | 759 | qed | 
| 760 | ||
| 69683 | 761 | subsection\<open>Locally compact sets in an open set\<close> | 
| 63130 | 762 | |
| 763 | text\<open> Locally compact sets are closed in an open set and are homeomorphic | |
| 764 | to an absolutely closed set if we have one more dimension to play with.\<close> | |
| 765 | ||
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 766 | lemma locally_compact_open_Int_closure: | 
| 63130 | 767 | fixes S :: "'a :: metric_space set" | 
| 768 | assumes "locally compact S" | |
| 769 | obtains T where "open T" "S = T \<inter> closure S" | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 770 | proof - | 
| 63130 | 771 | have "\<forall>x\<in>S. \<exists>T v u. u = S \<inter> T \<and> x \<in> u \<and> u \<subseteq> v \<and> v \<subseteq> S \<and> open T \<and> compact v" | 
| 772 | by (metis assms locally_compact openin_open) | |
| 773 | then obtain t v where | |
| 774 | tv: "\<And>x. x \<in> S | |
| 775 | \<Longrightarrow> v x \<subseteq> S \<and> open (t x) \<and> compact (v x) \<and> (\<exists>u. x \<in> u \<and> u \<subseteq> v x \<and> u = S \<inter> t x)" | |
| 776 | by metis | |
| 69313 | 777 | then have o: "open (\<Union>(t ` S))" | 
| 63130 | 778 | by blast | 
| 779 | have "S = \<Union> (v ` S)" | |
| 780 | using tv by blast | |
| 69313 | 781 | also have "... = \<Union>(t ` S) \<inter> closure S" | 
| 63130 | 782 | proof | 
| 69313 | 783 | show "\<Union>(v ` S) \<subseteq> \<Union>(t ` S) \<inter> closure S" | 
| 72496 | 784 | by clarify (meson IntD2 IntI UN_I closure_subset subsetD tv) | 
| 63130 | 785 | have "t x \<inter> closure S \<subseteq> v x" if "x \<in> S" for x | 
| 786 | proof - | |
| 787 | have "t x \<inter> closure S \<subseteq> closure (t x \<inter> S)" | |
| 788 | by (simp add: open_Int_closure_subset that tv) | |
| 789 | also have "... \<subseteq> v x" | |
| 790 | by (metis Int_commute closure_minimal compact_imp_closed that tv) | |
| 791 | finally show ?thesis . | |
| 792 | qed | |
| 69313 | 793 | then show "\<Union>(t ` S) \<inter> closure S \<subseteq> \<Union>(v ` S)" | 
| 63130 | 794 | by blast | 
| 795 | qed | |
| 69313 | 796 | finally have e: "S = \<Union>(t ` S) \<inter> closure S" . | 
| 63130 | 797 | show ?thesis | 
| 798 | by (rule that [OF o e]) | |
| 799 | qed | |
| 800 | ||
| 801 | ||
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 802 | lemma locally_compact_closedin_open: | 
| 63130 | 803 | fixes S :: "'a :: metric_space set" | 
| 804 | assumes "locally compact S" | |
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 805 | obtains T where "open T" "closedin (top_of_set T) S" | 
| 63130 | 806 | by (metis locally_compact_open_Int_closure [OF assms] closed_closure closedin_closed_Int) | 
| 807 | ||
| 808 | ||
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 809 | lemma locally_compact_homeomorphism_projection_closed: | 
| 63130 | 810 | assumes "locally compact S" | 
| 811 | obtains T and f :: "'a \<Rightarrow> 'a :: euclidean_space \<times> 'b :: euclidean_space" | |
| 72496 | 812 | where "closed T" "homeomorphism S T f fst" | 
| 63130 | 813 | proof (cases "closed S") | 
| 814 | case True | |
| 72496 | 815 | show ?thesis | 
| 816 | proof | |
| 817 |     show "homeomorphism S (S \<times> {0}) (\<lambda>x. (x, 0)) fst"
 | |
| 818 | by (auto simp: homeomorphism_def continuous_intros) | |
| 819 | qed (use True closed_Times in auto) | |
| 63130 | 820 | next | 
| 821 | case False | |
| 822 | obtain U where "open U" and US: "U \<inter> closure S = S" | |
| 823 | by (metis locally_compact_open_Int_closure [OF assms]) | |
| 824 |     with False have Ucomp: "-U \<noteq> {}"
 | |
| 825 | using closure_eq by auto | |
| 826 | have [simp]: "closure (- U) = -U" | |
| 827 | by (simp add: \<open>open U\<close> closed_Compl) | |
| 828 |     define f :: "'a \<Rightarrow> 'a \<times> 'b" where "f \<equiv> \<lambda>x. (x, One /\<^sub>R setdist {x} (- U))"
 | |
| 829 |     have "continuous_on U (\<lambda>x. (x, One /\<^sub>R setdist {x} (- U)))"
 | |
| 72496 | 830 | proof (intro continuous_intros continuous_on_setdist) | 
| 831 |       show "\<forall>x\<in>U. setdist {x} (- U) \<noteq> 0"
 | |
| 832 | by (simp add: Ucomp setdist_eq_0_sing_1) | |
| 833 | qed | |
| 63130 | 834 | then have homU: "homeomorphism U (f`U) f fst" | 
| 835 | by (auto simp: f_def homeomorphism_def image_iff continuous_intros) | |
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 836 | have cloS: "closedin (top_of_set U) S" | 
| 63130 | 837 | by (metis US closed_closure closedin_closed_Int) | 
| 838 |     have cont: "isCont ((\<lambda>x. setdist {x} (- U)) o fst) z" for z :: "'a \<times> 'b"
 | |
| 66827 
c94531b5007d
Divided Topology_Euclidean_Space in two, creating new theory Connected. Also deleted some duplicate / variant theorems
 paulson <lp15@cam.ac.uk> parents: 
66710diff
changeset | 839 | by (rule continuous_at_compose continuous_intros continuous_at_setdist)+ | 
| 63130 | 840 |     have setdist1D: "setdist {a} (- U) *\<^sub>R b = One \<Longrightarrow> setdist {a} (- U) \<noteq> 0" for a::'a and b::'b
 | 
| 841 | by force | |
| 842 | have *: "r *\<^sub>R b = One \<Longrightarrow> b = (1 / r) *\<^sub>R One" for r and b::'b | |
| 843 | by (metis One_non_0 nonzero_divide_eq_eq real_vector.scale_eq_0_iff real_vector.scale_scale scaleR_one) | |
| 72496 | 844 |     have "\<And>a b::'b. setdist {a} (- U) *\<^sub>R b = One \<Longrightarrow> (a,b) \<in> (\<lambda>x. (x, (1 / setdist {x} (- U)) *\<^sub>R One)) ` U"
 | 
| 845 | by (metis (mono_tags, lifting) "*" ComplI image_eqI setdist1D setdist_sing_in_set) | |
| 846 |     then have "f ` U = (\<lambda>z. (setdist {fst z} (- U) *\<^sub>R snd z)) -` {One}"
 | |
| 847 | by (auto simp: f_def setdist_eq_0_sing_1 field_simps Ucomp) | |
| 63130 | 848 | then have clfU: "closed (f ` U)" | 
| 72496 | 849 | by (force intro: continuous_intros cont [unfolded o_def] continuous_closed_vimage) | 
| 63130 | 850 | have "closed (f ` S)" | 
| 72496 | 851 | by (metis closedin_closed_trans [OF _ clfU] homeomorphism_imp_closed_map [OF homU cloS]) | 
| 63130 | 852 | then show ?thesis | 
| 72496 | 853 | by (metis US homU homeomorphism_of_subsets inf_sup_ord(1) that) | 
| 63130 | 854 | qed | 
| 855 | ||
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 856 | lemma locally_compact_closed_Int_open: | 
| 63130 | 857 | fixes S :: "'a :: euclidean_space set" | 
| 72496 | 858 | shows "locally compact S \<longleftrightarrow> (\<exists>U V. closed U \<and> open V \<and> S = U \<inter> V)" (is "?lhs = ?rhs") | 
| 859 | proof | |
| 860 | show "?lhs \<Longrightarrow> ?rhs" | |
| 861 | by (metis closed_closure inf_commute locally_compact_open_Int_closure) | |
| 862 | show "?rhs \<Longrightarrow> ?lhs" | |
| 863 | by (meson closed_imp_locally_compact locally_compact_Int open_imp_locally_compact) | |
| 864 | qed | |
| 63130 | 865 | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 866 | lemma lowerdim_embeddings: | 
| 63945 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 867 |   assumes  "DIM('a) < DIM('b)"
 | 
| 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 868 | obtains f :: "'a::euclidean_space*real \<Rightarrow> 'b::euclidean_space" | 
| 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 869 | and g :: "'b \<Rightarrow> 'a*real" | 
| 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 870 | and j :: 'b | 
| 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 871 | where "linear f" "linear g" "\<And>z. g (f z) = z" "j \<in> Basis" "\<And>x. f(x,0) \<bullet> j = 0" | 
| 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 872 | proof - | 
| 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 873 |   let ?B = "Basis :: ('a*real) set"
 | 
| 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 874 | have b01: "(0,1) \<in> ?B" | 
| 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 875 | by (simp add: Basis_prod_def) | 
| 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 876 |   have "DIM('a * real) \<le> DIM('b)"
 | 
| 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 877 | by (simp add: Suc_leI assms) | 
| 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 878 | then obtain basf :: "'a*real \<Rightarrow> 'b" where sbf: "basf ` ?B \<subseteq> Basis" and injbf: "inj_on basf Basis" | 
| 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 879 | by (metis finite_Basis card_le_inj) | 
| 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 880 | define basg:: "'b \<Rightarrow> 'a * real" where | 
| 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 881 | "basg \<equiv> \<lambda>i. if i \<in> basf ` Basis then inv_into Basis basf i else (0,1)" | 
| 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 882 | have bgf[simp]: "basg (basf i) = i" if "i \<in> Basis" for i | 
| 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 883 | using inv_into_f_f injbf that by (force simp: basg_def) | 
| 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 884 | have sbg: "basg ` Basis \<subseteq> ?B" | 
| 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 885 | by (force simp: basg_def injbf b01) | 
| 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 886 | define f :: "'a*real \<Rightarrow> 'b" where "f \<equiv> \<lambda>u. \<Sum>j\<in>Basis. (u \<bullet> basg j) *\<^sub>R j" | 
| 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 887 | define g :: "'b \<Rightarrow> 'a*real" where "g \<equiv> \<lambda>z. (\<Sum>i\<in>Basis. (z \<bullet> basf i) *\<^sub>R i)" | 
| 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 888 | show ?thesis | 
| 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 889 | proof | 
| 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 890 | show "linear f" | 
| 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 891 | unfolding f_def | 
| 64267 | 892 | by (intro linear_compose_sum linearI ballI) (auto simp: algebra_simps) | 
| 63945 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 893 | show "linear g" | 
| 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 894 | unfolding g_def | 
| 64267 | 895 | by (intro linear_compose_sum linearI ballI) (auto simp: algebra_simps) | 
| 63945 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 896 | have *: "(\<Sum>a \<in> Basis. a \<bullet> basf b * (x \<bullet> basg a)) = x \<bullet> b" if "b \<in> Basis" for x b | 
| 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 897 | using sbf that by auto | 
| 72496 | 898 | show gf: "g (f x) = x" for x | 
| 899 | proof (rule euclidean_eqI) | |
| 900 | show "\<And>b. b \<in> Basis \<Longrightarrow> g (f x) \<bullet> b = x \<bullet> b" | |
| 901 | using f_def g_def sbf by auto | |
| 902 | qed | |
| 63945 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 903 | show "basf(0,1) \<in> Basis" | 
| 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 904 | using b01 sbf by auto | 
| 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 905 | then show "f(x,0) \<bullet> basf(0,1) = 0" for x | 
| 72496 | 906 | unfolding f_def inner_sum_left | 
| 907 | using b01 inner_not_same_Basis | |
| 908 | by (fastforce intro: comm_monoid_add_class.sum.neutral) | |
| 63945 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 909 | qed | 
| 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 910 | qed | 
| 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 911 | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 912 | proposition locally_compact_homeomorphic_closed: | 
| 63130 | 913 | fixes S :: "'a::euclidean_space set" | 
| 914 |   assumes "locally compact S" and dimlt: "DIM('a) < DIM('b)"
 | |
| 915 | obtains T :: "'b::euclidean_space set" where "closed T" "S homeomorphic T" | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 916 | proof - | 
| 63130 | 917 |   obtain U:: "('a*real)set" and h
 | 
| 918 | where "closed U" and homU: "homeomorphism S U h fst" | |
| 919 | using locally_compact_homeomorphism_projection_closed assms by metis | |
| 63945 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 920 | obtain f :: "'a*real \<Rightarrow> 'b" and g :: "'b \<Rightarrow> 'a*real" | 
| 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 921 | where "linear f" "linear g" and gf [simp]: "\<And>z. g (f z) = z" | 
| 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 922 | using lowerdim_embeddings [OF dimlt] by metis | 
| 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 923 | then have "inj f" | 
| 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 924 | by (metis injI) | 
| 63130 | 925 | have gfU: "g ` f ` U = U" | 
| 63945 
444eafb6e864
a few new theorems and a renaming
 paulson <lp15@cam.ac.uk> parents: 
63918diff
changeset | 926 | by (simp add: image_comp o_def) | 
| 63130 | 927 | have "S homeomorphic U" | 
| 928 | using homU homeomorphic_def by blast | |
| 929 | also have "... homeomorphic f ` U" | |
| 72496 | 930 | proof (rule homeomorphicI [OF refl gfU]) | 
| 931 | show "continuous_on U f" | |
| 932 | by (meson \<open>inj f\<close> \<open>linear f\<close> homeomorphism_cont2 linear_homeomorphism_image) | |
| 933 | show "continuous_on (f ` U) g" | |
| 934 | using \<open>linear g\<close> linear_continuous_on linear_conv_bounded_linear by blast | |
| 935 | qed (auto simp: o_def) | |
| 63130 | 936 | finally show ?thesis | 
| 72496 | 937 | using \<open>closed U\<close> \<open>inj f\<close> \<open>linear f\<close> closed_injective_linear_image that by blast | 
| 63130 | 938 | qed | 
| 939 | ||
| 940 | ||
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 941 | lemma homeomorphic_convex_compact_lemma: | 
| 64773 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 942 | fixes S :: "'a::euclidean_space set" | 
| 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 943 | assumes "convex S" | 
| 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 944 | and "compact S" | 
| 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 945 | and "cball 0 1 \<subseteq> S" | 
| 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 946 | shows "S homeomorphic (cball (0::'a) 1)" | 
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 947 | proof (rule starlike_compact_projective_special[OF assms(2-3)]) | 
| 63130 | 948 | fix x u | 
| 64773 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 949 | assume "x \<in> S" and "0 \<le> u" and "u < (1::real)" | 
| 63130 | 950 | have "open (ball (u *\<^sub>R x) (1 - u))" | 
| 951 | by (rule open_ball) | |
| 952 | moreover have "u *\<^sub>R x \<in> ball (u *\<^sub>R x) (1 - u)" | |
| 953 | unfolding centre_in_ball using \<open>u < 1\<close> by simp | |
| 64773 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 954 | moreover have "ball (u *\<^sub>R x) (1 - u) \<subseteq> S" | 
| 63130 | 955 | proof | 
| 956 | fix y | |
| 957 | assume "y \<in> ball (u *\<^sub>R x) (1 - u)" | |
| 958 | then have "dist (u *\<^sub>R x) y < 1 - u" | |
| 959 | unfolding mem_ball . | |
| 960 | with \<open>u < 1\<close> have "inverse (1 - u) *\<^sub>R (y - u *\<^sub>R x) \<in> cball 0 1" | |
| 961 | by (simp add: dist_norm inverse_eq_divide norm_minus_commute) | |
| 64773 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 962 | with assms(3) have "inverse (1 - u) *\<^sub>R (y - u *\<^sub>R x) \<in> S" .. | 
| 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 963 | with assms(1) have "(1 - u) *\<^sub>R ((y - u *\<^sub>R x) /\<^sub>R (1 - u)) + u *\<^sub>R x \<in> S" | 
| 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 964 | using \<open>x \<in> S\<close> \<open>0 \<le> u\<close> \<open>u < 1\<close> [THEN less_imp_le] by (rule convexD_alt) | 
| 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 965 | then show "y \<in> S" using \<open>u < 1\<close> | 
| 63130 | 966 | by simp | 
| 967 | qed | |
| 64773 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 968 | ultimately have "u *\<^sub>R x \<in> interior S" .. | 
| 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 969 | then show "u *\<^sub>R x \<in> S - frontier S" | 
| 63130 | 970 | using frontier_def and interior_subset by auto | 
| 971 | qed | |
| 972 | ||
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 973 | proposition homeomorphic_convex_compact_cball: | 
| 63130 | 974 | fixes e :: real | 
| 64773 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 975 | and S :: "'a::euclidean_space set" | 
| 72496 | 976 |   assumes S: "convex S" "compact S" "interior S \<noteq> {}" and "e > 0"
 | 
| 64773 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 977 | shows "S homeomorphic (cball (b::'a) e)" | 
| 72496 | 978 | proof (rule homeomorphic_trans[OF _ homeomorphic_balls(2)]) | 
| 64773 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 979 | obtain a where "a \<in> interior S" | 
| 72496 | 980 | using assms by auto | 
| 981 | then show "S homeomorphic cball (0::'a) 1" | |
| 982 | by (metis (no_types) aff_dim_cball S compact_cball convex_cball | |
| 983 | homeomorphic_convex_lemma interior_rel_interior_gen zero_less_one) | |
| 984 | qed (use \<open>e>0\<close> in auto) | |
| 63130 | 985 | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 986 | corollary homeomorphic_convex_compact: | 
| 64773 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 987 | fixes S :: "'a::euclidean_space set" | 
| 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 988 | and T :: "'a set" | 
| 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 989 |   assumes "convex S" "compact S" "interior S \<noteq> {}"
 | 
| 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 990 |     and "convex T" "compact T" "interior T \<noteq> {}"
 | 
| 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 991 | shows "S homeomorphic T" | 
| 63130 | 992 | using assms | 
| 993 | by (meson zero_less_one homeomorphic_trans homeomorphic_convex_compact_cball homeomorphic_sym) | |
| 994 | ||
| 70620 
f95193669ad7
removed Brouwer_Fixpoint from imports of Derivative
 immler parents: 
70136diff
changeset | 995 | lemma homeomorphic_closed_intervals: | 
| 
f95193669ad7
removed Brouwer_Fixpoint from imports of Derivative
 immler parents: 
70136diff
changeset | 996 | fixes a :: "'a::euclidean_space" and b and c :: "'a::euclidean_space" and d | 
| 
f95193669ad7
removed Brouwer_Fixpoint from imports of Derivative
 immler parents: 
70136diff
changeset | 997 |   assumes "box a b \<noteq> {}" and "box c d \<noteq> {}"
 | 
| 
f95193669ad7
removed Brouwer_Fixpoint from imports of Derivative
 immler parents: 
70136diff
changeset | 998 | shows "(cbox a b) homeomorphic (cbox c d)" | 
| 72496 | 999 | by (simp add: assms homeomorphic_convex_compact) | 
| 70620 
f95193669ad7
removed Brouwer_Fixpoint from imports of Derivative
 immler parents: 
70136diff
changeset | 1000 | |
| 
f95193669ad7
removed Brouwer_Fixpoint from imports of Derivative
 immler parents: 
70136diff
changeset | 1001 | lemma homeomorphic_closed_intervals_real: | 
| 
f95193669ad7
removed Brouwer_Fixpoint from imports of Derivative
 immler parents: 
70136diff
changeset | 1002 | fixes a::real and b and c::real and d | 
| 
f95193669ad7
removed Brouwer_Fixpoint from imports of Derivative
 immler parents: 
70136diff
changeset | 1003 | assumes "a<b" and "c<d" | 
| 
f95193669ad7
removed Brouwer_Fixpoint from imports of Derivative
 immler parents: 
70136diff
changeset | 1004 |   shows "{a..b} homeomorphic {c..d}"
 | 
| 
f95193669ad7
removed Brouwer_Fixpoint from imports of Derivative
 immler parents: 
70136diff
changeset | 1005 | using assms by (auto intro: homeomorphic_convex_compact) | 
| 
f95193669ad7
removed Brouwer_Fixpoint from imports of Derivative
 immler parents: 
70136diff
changeset | 1006 | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1007 | subsection\<open>Covering spaces and lifting results for them\<close> | 
| 63301 | 1008 | |
| 70136 | 1009 | definition\<^marker>\<open>tag important\<close> covering_space | 
| 63301 | 1010 |            :: "'a::topological_space set \<Rightarrow> ('a \<Rightarrow> 'b) \<Rightarrow> 'b::topological_space set \<Rightarrow> bool"
 | 
| 1011 | where | |
| 64773 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1012 | "covering_space c p S \<equiv> | 
| 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1013 | continuous_on c p \<and> p ` c = S \<and> | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1014 | (\<forall>x \<in> S. \<exists>T. x \<in> T \<and> openin (top_of_set S) T \<and> | 
| 66884 
c2128ab11f61
Switching to inverse image and constant_on, plus some new material
 paulson <lp15@cam.ac.uk> parents: 
66827diff
changeset | 1015 | (\<exists>v. \<Union>v = c \<inter> p -` T \<and> | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1016 | (\<forall>u \<in> v. openin (top_of_set c) u) \<and> | 
| 63301 | 1017 | pairwise disjnt v \<and> | 
| 64773 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1018 | (\<forall>u \<in> v. \<exists>q. homeomorphism u T p q)))" | 
| 63301 | 1019 | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1020 | lemma covering_space_imp_continuous: "covering_space c p S \<Longrightarrow> continuous_on c p" | 
| 63301 | 1021 | by (simp add: covering_space_def) | 
| 1022 | ||
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1023 | lemma covering_space_imp_surjective: "covering_space c p S \<Longrightarrow> p ` c = S" | 
| 63301 | 1024 | by (simp add: covering_space_def) | 
| 1025 | ||
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1026 | lemma homeomorphism_imp_covering_space: "homeomorphism S T f g \<Longrightarrow> covering_space S f T" | 
| 72496 | 1027 | apply (clarsimp simp add: homeomorphism_def covering_space_def) | 
| 64773 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1028 | apply (rule_tac x=T in exI, simp) | 
| 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1029 |   apply (rule_tac x="{S}" in exI, auto)
 | 
| 63301 | 1030 | done | 
| 1031 | ||
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1032 | lemma covering_space_local_homeomorphism: | 
| 64773 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1033 | assumes "covering_space c p S" "x \<in> c" | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1034 | obtains T u q where "x \<in> T" "openin (top_of_set c) T" | 
| 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1035 | "p x \<in> u" "openin (top_of_set S) u" | 
| 64773 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1036 | "homeomorphism T u p q" | 
| 72496 | 1037 | using assms | 
| 1038 | by (clarsimp simp add: covering_space_def) (metis IntI UnionE vimage_eq) | |
| 63301 | 1039 | |
| 1040 | ||
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1041 | lemma covering_space_local_homeomorphism_alt: | 
| 64773 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1042 | assumes p: "covering_space c p S" and "y \<in> S" | 
| 66884 
c2128ab11f61
Switching to inverse image and constant_on, plus some new material
 paulson <lp15@cam.ac.uk> parents: 
66827diff
changeset | 1043 | obtains x T U q where "p x = y" | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1044 | "x \<in> T" "openin (top_of_set c) T" | 
| 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1045 | "y \<in> U" "openin (top_of_set S) U" | 
| 66884 
c2128ab11f61
Switching to inverse image and constant_on, plus some new material
 paulson <lp15@cam.ac.uk> parents: 
66827diff
changeset | 1046 | "homeomorphism T U p q" | 
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1047 | proof - | 
| 63301 | 1048 | obtain x where "p x = y" "x \<in> c" | 
| 1049 | using assms covering_space_imp_surjective by blast | |
| 1050 | show ?thesis | |
| 72496 | 1051 | using that \<open>p x = y\<close> by (auto intro: covering_space_local_homeomorphism [OF p \<open>x \<in> c\<close>]) | 
| 63301 | 1052 | qed | 
| 1053 | ||
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1054 | proposition covering_space_open_map: | 
| 64773 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1055 | fixes S :: "'a :: metric_space set" and T :: "'b :: metric_space set" | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1056 | assumes p: "covering_space c p S" and T: "openin (top_of_set c) T" | 
| 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1057 | shows "openin (top_of_set S) (p ` T)" | 
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1058 | proof - | 
| 64773 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1059 | have pce: "p ` c = S" | 
| 63301 | 1060 | and covs: | 
| 64773 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1061 | "\<And>x. x \<in> S \<Longrightarrow> | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1062 | \<exists>X VS. x \<in> X \<and> openin (top_of_set S) X \<and> | 
| 66884 
c2128ab11f61
Switching to inverse image and constant_on, plus some new material
 paulson <lp15@cam.ac.uk> parents: 
66827diff
changeset | 1063 | \<Union>VS = c \<inter> p -` X \<and> | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1064 | (\<forall>u \<in> VS. openin (top_of_set c) u) \<and> | 
| 63301 | 1065 | pairwise disjnt VS \<and> | 
| 1066 | (\<forall>u \<in> VS. \<exists>q. homeomorphism u X p q)" | |
| 1067 | using p by (auto simp: covering_space_def) | |
| 64773 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1068 | have "T \<subseteq> c" by (metis openin_euclidean_subtopology_iff T) | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1069 | have "\<exists>X. openin (top_of_set S) X \<and> y \<in> X \<and> X \<subseteq> p ` T" | 
| 64773 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1070 | if "y \<in> p ` T" for y | 
| 63301 | 1071 | proof - | 
| 64773 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1072 | have "y \<in> S" using \<open>T \<subseteq> c\<close> pce that by blast | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1073 | obtain U VS where "y \<in> U" and U: "openin (top_of_set S) U" | 
| 66884 
c2128ab11f61
Switching to inverse image and constant_on, plus some new material
 paulson <lp15@cam.ac.uk> parents: 
66827diff
changeset | 1074 | and VS: "\<Union>VS = c \<inter> p -` U" | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1075 | and openVS: "\<forall>V \<in> VS. openin (top_of_set c) V" | 
| 63301 | 1076 | and homVS: "\<And>V. V \<in> VS \<Longrightarrow> \<exists>q. homeomorphism V U p q" | 
| 64773 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1077 | using covs [OF \<open>y \<in> S\<close>] by auto | 
| 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1078 | obtain x where "x \<in> c" "p x \<in> U" "x \<in> T" "p x = y" | 
| 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1079 | using T [unfolded openin_euclidean_subtopology_iff] \<open>y \<in> U\<close> \<open>y \<in> p ` T\<close> by blast | 
| 63301 | 1080 | with VS obtain V where "x \<in> V" "V \<in> VS" by auto | 
| 1081 | then obtain q where q: "homeomorphism V U p q" using homVS by blast | |
| 66884 
c2128ab11f61
Switching to inverse image and constant_on, plus some new material
 paulson <lp15@cam.ac.uk> parents: 
66827diff
changeset | 1082 | then have ptV: "p ` (T \<inter> V) = U \<inter> q -` (T \<inter> V)" | 
| 63301 | 1083 | using VS \<open>V \<in> VS\<close> by (auto simp: homeomorphism_def) | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1084 | have ocv: "openin (top_of_set c) V" | 
| 63301 | 1085 | by (simp add: \<open>V \<in> VS\<close> openVS) | 
| 72496 | 1086 | have "openin (top_of_set (q ` U)) (T \<inter> V)" | 
| 1087 | using q unfolding homeomorphism_def | |
| 1088 | by (metis T inf.absorb_iff2 ocv openin_imp_subset openin_subtopology_Int subtopology_subtopology) | |
| 1089 | then have "openin (top_of_set U) (U \<inter> q -` (T \<inter> V))" | |
| 1090 | using continuous_on_open homeomorphism_def q by blast | |
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1091 | then have os: "openin (top_of_set S) (U \<inter> q -` (T \<inter> V))" | 
| 63301 | 1092 | using openin_trans [of U] by (simp add: Collect_conj_eq U) | 
| 1093 | show ?thesis | |
| 72496 | 1094 | proof (intro exI conjI) | 
| 1095 | show "openin (top_of_set S) (p ` (T \<inter> V))" | |
| 1096 | by (simp only: ptV os) | |
| 1097 | qed (use \<open>p x = y\<close> \<open>x \<in> V\<close> \<open>x \<in> T\<close> in auto) | |
| 63301 | 1098 | qed | 
| 1099 | with openin_subopen show ?thesis by blast | |
| 1100 | qed | |
| 1101 | ||
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1102 | lemma covering_space_lift_unique_gen: | 
| 63301 | 1103 | fixes f :: "'a::topological_space \<Rightarrow> 'b::topological_space" | 
| 1104 | fixes g1 :: "'a \<Rightarrow> 'c::real_normed_vector" | |
| 64773 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1105 | assumes cov: "covering_space c p S" | 
| 63301 | 1106 | and eq: "g1 a = g2 a" | 
| 64773 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1107 | and f: "continuous_on T f" "f ` T \<subseteq> S" | 
| 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1108 | and g1: "continuous_on T g1" "g1 ` T \<subseteq> c" | 
| 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1109 | and fg1: "\<And>x. x \<in> T \<Longrightarrow> f x = p(g1 x)" | 
| 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1110 | and g2: "continuous_on T g2" "g2 ` T \<subseteq> c" | 
| 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1111 | and fg2: "\<And>x. x \<in> T \<Longrightarrow> f x = p(g2 x)" | 
| 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1112 | and u_compt: "U \<in> components T" and "a \<in> U" "x \<in> U" | 
| 63301 | 1113 | shows "g1 x = g2 x" | 
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1114 | proof - | 
| 64773 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1115 | have "U \<subseteq> T" by (rule in_components_subset [OF u_compt]) | 
| 65064 
a4abec71279a
Renamed ii to imaginary_unit in order to free up ii as a variable name.  Also replaced some legacy def commands
 paulson <lp15@cam.ac.uk> parents: 
64792diff
changeset | 1116 |   define G12 where "G12 \<equiv> {x \<in> U. g1 x - g2 x = 0}"
 | 
| 64773 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1117 | have "connected U" by (rule in_components_connected [OF u_compt]) | 
| 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1118 | have contu: "continuous_on U g1" "continuous_on U g2" | 
| 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1119 | using \<open>U \<subseteq> T\<close> continuous_on_subset g1 g2 by blast+ | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1120 | have o12: "openin (top_of_set U) G12" | 
| 63301 | 1121 | unfolding G12_def | 
| 1122 | proof (subst openin_subopen, clarify) | |
| 1123 | fix z | |
| 64773 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1124 | assume z: "z \<in> U" "g1 z - g2 z = 0" | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1125 | obtain v w q where "g1 z \<in> v" and ocv: "openin (top_of_set c) v" | 
| 72496 | 1126 | and "p (g1 z) \<in> w" and osw: "openin (top_of_set S) w" | 
| 1127 | and hom: "homeomorphism v w p q" | |
| 1128 | proof (rule covering_space_local_homeomorphism [OF cov]) | |
| 1129 | show "g1 z \<in> c" | |
| 1130 | using \<open>U \<subseteq> T\<close> \<open>z \<in> U\<close> g1(2) by blast | |
| 1131 | qed auto | |
| 63301 | 1132 | have "g2 z \<in> v" using \<open>g1 z \<in> v\<close> z by auto | 
| 66884 
c2128ab11f61
Switching to inverse image and constant_on, plus some new material
 paulson <lp15@cam.ac.uk> parents: 
66827diff
changeset | 1133 | have gg: "U \<inter> g -` v = U \<inter> g -` (v \<inter> g ` U)" for g | 
| 63301 | 1134 | by auto | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1135 | have "openin (top_of_set (g1 ` U)) (v \<inter> g1 ` U)" | 
| 64773 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1136 | using ocv \<open>U \<subseteq> T\<close> g1 by (fastforce simp add: openin_open) | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1137 | then have 1: "openin (top_of_set U) (U \<inter> g1 -` v)" | 
| 63301 | 1138 | unfolding gg by (blast intro: contu continuous_on_open [THEN iffD1, rule_format]) | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1139 | have "openin (top_of_set (g2 ` U)) (v \<inter> g2 ` U)" | 
| 64773 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1140 | using ocv \<open>U \<subseteq> T\<close> g2 by (fastforce simp add: openin_open) | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1141 | then have 2: "openin (top_of_set U) (U \<inter> g2 -` v)" | 
| 63301 | 1142 | unfolding gg by (blast intro: contu continuous_on_open [THEN iffD1, rule_format]) | 
| 72496 | 1143 | let ?T = "(U \<inter> g1 -` v) \<inter> (U \<inter> g2 -` v)" | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1144 |     show "\<exists>T. openin (top_of_set U) T \<and> z \<in> T \<and> T \<subseteq> {z \<in> U. g1 z - g2 z = 0}"
 | 
| 72496 | 1145 | proof (intro exI conjI) | 
| 1146 | show "openin (top_of_set U) ?T" | |
| 1147 | using "1" "2" by blast | |
| 1148 | show "z \<in> ?T" | |
| 1149 | using z by (simp add: \<open>g1 z \<in> v\<close> \<open>g2 z \<in> v\<close>) | |
| 1150 |       show "?T \<subseteq> {z \<in> U. g1 z - g2 z = 0}"
 | |
| 1151 | using hom | |
| 1152 | by (clarsimp simp: homeomorphism_def) (metis \<open>U \<subseteq> T\<close> fg1 fg2 subsetD) | |
| 1153 | qed | |
| 63301 | 1154 | qed | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1155 | have c12: "closedin (top_of_set U) G12" | 
| 63301 | 1156 | unfolding G12_def | 
| 1157 | by (intro continuous_intros continuous_closedin_preimage_constant contu) | |
| 64773 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1158 |   have "G12 = {} \<or> G12 = U"
 | 
| 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1159 | by (intro connected_clopen [THEN iffD1, rule_format] \<open>connected U\<close> conjI o12 c12) | 
| 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1160 | with eq \<open>a \<in> U\<close> have "\<And>x. x \<in> U \<Longrightarrow> g1 x - g2 x = 0" by (auto simp: G12_def) | 
| 63301 | 1161 | then show ?thesis | 
| 64773 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1162 | using \<open>x \<in> U\<close> by force | 
| 63301 | 1163 | qed | 
| 1164 | ||
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1165 | proposition covering_space_lift_unique: | 
| 63301 | 1166 | fixes f :: "'a::topological_space \<Rightarrow> 'b::topological_space" | 
| 1167 | fixes g1 :: "'a \<Rightarrow> 'c::real_normed_vector" | |
| 64773 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1168 | assumes "covering_space c p S" | 
| 63301 | 1169 | "g1 a = g2 a" | 
| 64773 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1170 | "continuous_on T f" "f ` T \<subseteq> S" | 
| 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1171 | "continuous_on T g1" "g1 ` T \<subseteq> c" "\<And>x. x \<in> T \<Longrightarrow> f x = p(g1 x)" | 
| 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1172 | "continuous_on T g2" "g2 ` T \<subseteq> c" "\<And>x. x \<in> T \<Longrightarrow> f x = p(g2 x)" | 
| 
223b2ebdda79
Many new theorems, and more tidying
 paulson <lp15@cam.ac.uk> parents: 
64394diff
changeset | 1173 | "connected T" "a \<in> T" "x \<in> T" | 
| 63301 | 1174 | shows "g1 x = g2 x" | 
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1175 | using covering_space_lift_unique_gen [of c p S] in_components_self assms ex_in_conv | 
| 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1176 | by blast | 
| 63301 | 1177 | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1178 | lemma covering_space_locally: | 
| 64791 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1179 | fixes p :: "'a::real_normed_vector \<Rightarrow> 'b::real_normed_vector" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1180 | assumes loc: "locally \<phi> C" and cov: "covering_space C p S" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1181 | and pim: "\<And>T. \<lbrakk>T \<subseteq> C; \<phi> T\<rbrakk> \<Longrightarrow> \<psi>(p ` T)" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1182 | shows "locally \<psi> S" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1183 | proof - | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1184 | have "locally \<psi> (p ` C)" | 
| 72496 | 1185 | proof (rule locally_open_map_image [OF loc]) | 
| 1186 | show "continuous_on C p" | |
| 1187 | using cov covering_space_imp_continuous by blast | |
| 1188 | show "\<And>T. openin (top_of_set C) T \<Longrightarrow> openin (top_of_set (p ` C)) (p ` T)" | |
| 1189 | using cov covering_space_imp_surjective covering_space_open_map by blast | |
| 1190 | qed (simp add: pim) | |
| 64791 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1191 | then show ?thesis | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1192 | using covering_space_imp_surjective [OF cov] by metis | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1193 | qed | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1194 | |
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1195 | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1196 | proposition covering_space_locally_eq: | 
| 64791 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1197 | fixes p :: "'a::real_normed_vector \<Rightarrow> 'b::real_normed_vector" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1198 | assumes cov: "covering_space C p S" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1199 | and pim: "\<And>T. \<lbrakk>T \<subseteq> C; \<phi> T\<rbrakk> \<Longrightarrow> \<psi>(p ` T)" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1200 | and qim: "\<And>q U. \<lbrakk>U \<subseteq> S; continuous_on U q; \<psi> U\<rbrakk> \<Longrightarrow> \<phi>(q ` U)" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1201 | shows "locally \<psi> S \<longleftrightarrow> locally \<phi> C" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1202 | (is "?lhs = ?rhs") | 
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1203 | proof | 
| 64791 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1204 | assume L: ?lhs | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1205 | show ?rhs | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1206 | proof (rule locallyI) | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1207 | fix V x | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1208 | assume V: "openin (top_of_set C) V" and "x \<in> V" | 
| 64791 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1209 | have "p x \<in> p ` C" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1210 | by (metis IntE V \<open>x \<in> V\<close> imageI openin_open) | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1211 | then obtain T \<V> where "p x \<in> T" | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1212 | and opeT: "openin (top_of_set S) T" | 
| 66884 
c2128ab11f61
Switching to inverse image and constant_on, plus some new material
 paulson <lp15@cam.ac.uk> parents: 
66827diff
changeset | 1213 | and veq: "\<Union>\<V> = C \<inter> p -` T" | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1214 | and ope: "\<forall>U\<in>\<V>. openin (top_of_set C) U" | 
| 64791 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1215 | and hom: "\<forall>U\<in>\<V>. \<exists>q. homeomorphism U T p q" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1216 | using cov unfolding covering_space_def by (blast intro: that) | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1217 | have "x \<in> \<Union>\<V>" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1218 | using V veq \<open>p x \<in> T\<close> \<open>x \<in> V\<close> openin_imp_subset by fastforce | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1219 | then obtain U where "x \<in> U" "U \<in> \<V>" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1220 | by blast | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1221 | then obtain q where opeU: "openin (top_of_set C) U" and q: "homeomorphism U T p q" | 
| 64791 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1222 | using ope hom by blast | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1223 | with V have "openin (top_of_set C) (U \<inter> V)" | 
| 64791 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1224 | by blast | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1225 | then have UV: "openin (top_of_set S) (p ` (U \<inter> V))" | 
| 64791 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1226 | using cov covering_space_open_map by blast | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1227 | obtain W W' where opeW: "openin (top_of_set S) W" and "\<psi> W'" "p x \<in> W" "W \<subseteq> W'" and W'sub: "W' \<subseteq> p ` (U \<inter> V)" | 
| 64791 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1228 | using locallyE [OF L UV] \<open>x \<in> U\<close> \<open>x \<in> V\<close> by blast | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1229 | then have "W \<subseteq> T" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1230 | by (metis Int_lower1 q homeomorphism_image1 image_Int_subset order_trans) | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1231 | show "\<exists>U Z. openin (top_of_set C) U \<and> | 
| 64791 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1232 | \<phi> Z \<and> x \<in> U \<and> U \<subseteq> Z \<and> Z \<subseteq> V" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1233 | proof (intro exI conjI) | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1234 | have "openin (top_of_set T) W" | 
| 64791 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1235 | by (meson opeW opeT openin_imp_subset openin_subset_trans \<open>W \<subseteq> T\<close>) | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1236 | then have "openin (top_of_set U) (q ` W)" | 
| 64791 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1237 | by (meson homeomorphism_imp_open_map homeomorphism_symD q) | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1238 | then show "openin (top_of_set C) (q ` W)" | 
| 64791 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1239 | using opeU openin_trans by blast | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1240 | show "\<phi> (q ` W')" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1241 | by (metis (mono_tags, lifting) Int_subset_iff UV W'sub \<open>\<psi> W'\<close> continuous_on_subset dual_order.trans homeomorphism_def image_Int_subset openin_imp_subset q qim) | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1242 | show "x \<in> q ` W" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1243 | by (metis \<open>p x \<in> W\<close> \<open>x \<in> U\<close> homeomorphism_def imageI q) | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1244 | show "q ` W \<subseteq> q ` W'" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1245 | using \<open>W \<subseteq> W'\<close> by blast | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1246 | have "W' \<subseteq> p ` V" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1247 | using W'sub by blast | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1248 | then show "q ` W' \<subseteq> V" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1249 | using W'sub homeomorphism_apply1 [OF q] by auto | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1250 | qed | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1251 | qed | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1252 | next | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1253 | assume ?rhs | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1254 | then show ?lhs | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1255 | using cov covering_space_locally pim by blast | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1256 | qed | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1257 | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1258 | lemma covering_space_locally_compact_eq: | 
| 64791 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1259 | fixes p :: "'a::real_normed_vector \<Rightarrow> 'b::real_normed_vector" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1260 | assumes "covering_space C p S" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1261 | shows "locally compact S \<longleftrightarrow> locally compact C" | 
| 72496 | 1262 | proof (rule covering_space_locally_eq [OF assms]) | 
| 1263 | show "\<And>T. \<lbrakk>T \<subseteq> C; compact T\<rbrakk> \<Longrightarrow> compact (p ` T)" | |
| 1264 | by (meson assms compact_continuous_image continuous_on_subset covering_space_imp_continuous) | |
| 1265 | qed (use compact_continuous_image in blast) | |
| 64791 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1266 | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1267 | lemma covering_space_locally_connected_eq: | 
| 64791 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1268 | fixes p :: "'a::real_normed_vector \<Rightarrow> 'b::real_normed_vector" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1269 | assumes "covering_space C p S" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1270 | shows "locally connected S \<longleftrightarrow> locally connected C" | 
| 72496 | 1271 | proof (rule covering_space_locally_eq [OF assms]) | 
| 1272 | show "\<And>T. \<lbrakk>T \<subseteq> C; connected T\<rbrakk> \<Longrightarrow> connected (p ` T)" | |
| 1273 | by (meson connected_continuous_image assms continuous_on_subset covering_space_imp_continuous) | |
| 1274 | qed (use connected_continuous_image in blast) | |
| 64791 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1275 | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1276 | lemma covering_space_locally_path_connected_eq: | 
| 64791 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1277 | fixes p :: "'a::real_normed_vector \<Rightarrow> 'b::real_normed_vector" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1278 | assumes "covering_space C p S" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1279 | shows "locally path_connected S \<longleftrightarrow> locally path_connected C" | 
| 72496 | 1280 | proof (rule covering_space_locally_eq [OF assms]) | 
| 1281 | show "\<And>T. \<lbrakk>T \<subseteq> C; path_connected T\<rbrakk> \<Longrightarrow> path_connected (p ` T)" | |
| 1282 | by (meson path_connected_continuous_image assms continuous_on_subset covering_space_imp_continuous) | |
| 1283 | qed (use path_connected_continuous_image in blast) | |
| 64791 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1284 | |
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1285 | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1286 | lemma covering_space_locally_compact: | 
| 64791 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1287 | fixes p :: "'a::real_normed_vector \<Rightarrow> 'b::real_normed_vector" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1288 | assumes "locally compact C" "covering_space C p S" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1289 | shows "locally compact S" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1290 | using assms covering_space_locally_compact_eq by blast | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1291 | |
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1292 | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1293 | lemma covering_space_locally_connected: | 
| 64791 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1294 | fixes p :: "'a::real_normed_vector \<Rightarrow> 'b::real_normed_vector" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1295 | assumes "locally connected C" "covering_space C p S" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1296 | shows "locally connected S" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1297 | using assms covering_space_locally_connected_eq by blast | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1298 | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1299 | lemma covering_space_locally_path_connected: | 
| 64791 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1300 | fixes p :: "'a::real_normed_vector \<Rightarrow> 'b::real_normed_vector" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1301 | assumes "locally path_connected C" "covering_space C p S" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1302 | shows "locally path_connected S" | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1303 | using assms covering_space_locally_path_connected_eq by blast | 
| 
05a2b3b20664
facts about ANRs, ENRs, covering spaces
 paulson <lp15@cam.ac.uk> parents: 
64789diff
changeset | 1304 | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1305 | proposition covering_space_lift_homotopy: | 
| 64792 | 1306 | fixes p :: "'a::real_normed_vector \<Rightarrow> 'b::real_normed_vector" | 
| 1307 | and h :: "real \<times> 'c::real_normed_vector \<Rightarrow> 'b" | |
| 1308 | assumes cov: "covering_space C p S" | |
| 1309 |       and conth: "continuous_on ({0..1} \<times> U) h"
 | |
| 1310 |       and him: "h ` ({0..1} \<times> U) \<subseteq> S"
 | |
| 1311 | and heq: "\<And>y. y \<in> U \<Longrightarrow> h (0,y) = p(f y)" | |
| 1312 | and contf: "continuous_on U f" and fim: "f ` U \<subseteq> C" | |
| 1313 |     obtains k where "continuous_on ({0..1} \<times> U) k"
 | |
| 1314 |                     "k ` ({0..1} \<times> U) \<subseteq> C"
 | |
| 1315 | "\<And>y. y \<in> U \<Longrightarrow> k(0, y) = f y" | |
| 1316 |                     "\<And>z. z \<in> {0..1} \<times> U \<Longrightarrow> h z = p(k z)"
 | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1317 | proof - | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1318 | have "\<exists>V k. openin (top_of_set U) V \<and> y \<in> V \<and> | 
| 64792 | 1319 |               continuous_on ({0..1} \<times> V) k \<and> k ` ({0..1} \<times> V) \<subseteq> C \<and>
 | 
| 1320 |               (\<forall>z \<in> V. k(0, z) = f z) \<and> (\<forall>z \<in> {0..1} \<times> V. h z = p(k z))"
 | |
| 1321 | if "y \<in> U" for y | |
| 1322 | proof - | |
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1323 | obtain UU where UU: "\<And>s. s \<in> S \<Longrightarrow> s \<in> (UU s) \<and> openin (top_of_set S) (UU s) \<and> | 
| 66884 
c2128ab11f61
Switching to inverse image and constant_on, plus some new material
 paulson <lp15@cam.ac.uk> parents: 
66827diff
changeset | 1324 | (\<exists>\<V>. \<Union>\<V> = C \<inter> p -` UU s \<and> | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1325 | (\<forall>U \<in> \<V>. openin (top_of_set C) U) \<and> | 
| 64792 | 1326 | pairwise disjnt \<V> \<and> | 
| 1327 | (\<forall>U \<in> \<V>. \<exists>q. homeomorphism U (UU s) p q))" | |
| 1328 | using cov unfolding covering_space_def by (metis (mono_tags)) | |
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1329 | then have ope: "\<And>s. s \<in> S \<Longrightarrow> s \<in> (UU s) \<and> openin (top_of_set S) (UU s)" | 
| 64792 | 1330 | by blast | 
| 1331 | have "\<exists>k n i. open k \<and> open n \<and> | |
| 1332 |                   t \<in> k \<and> y \<in> n \<and> i \<in> S \<and> h ` (({0..1} \<inter> k) \<times> (U \<inter> n)) \<subseteq> UU i" if "t \<in> {0..1}" for t
 | |
| 1333 | proof - | |
| 1334 | have hinS: "h (t, y) \<in> S" | |
| 1335 | using \<open>y \<in> U\<close> him that by blast | |
| 66884 
c2128ab11f61
Switching to inverse image and constant_on, plus some new material
 paulson <lp15@cam.ac.uk> parents: 
66827diff
changeset | 1336 |       then have "(t,y) \<in> ({0..1} \<times> U) \<inter> h -` UU(h(t, y))"
 | 
| 64792 | 1337 |         using \<open>y \<in> U\<close> \<open>t \<in> {0..1}\<close>  by (auto simp: ope)
 | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1338 |       moreover have ope_01U: "openin (top_of_set ({0..1} \<times> U)) (({0..1} \<times> U) \<inter> h -` UU(h(t, y)))"
 | 
| 64792 | 1339 | using hinS ope continuous_on_open_gen [OF him] conth by blast | 
| 1340 |       ultimately obtain V W where opeV: "open V" and "t \<in> {0..1} \<inter> V" "t \<in> {0..1} \<inter> V"
 | |
| 1341 | and opeW: "open W" and "y \<in> U" "y \<in> W" | |
| 66884 
c2128ab11f61
Switching to inverse image and constant_on, plus some new material
 paulson <lp15@cam.ac.uk> parents: 
66827diff
changeset | 1342 |                               and VW: "({0..1} \<inter> V) \<times> (U \<inter> W)  \<subseteq> (({0..1} \<times> U) \<inter> h -` UU(h(t, y)))"
 | 
| 64792 | 1343 | by (rule Times_in_interior_subtopology) (auto simp: openin_open) | 
| 1344 | then show ?thesis | |
| 1345 | using hinS by blast | |
| 1346 | qed | |
| 1347 | then obtain K NN X where | |
| 1348 |               K: "\<And>t. t \<in> {0..1} \<Longrightarrow> open (K t)"
 | |
| 1349 |           and NN: "\<And>t. t \<in> {0..1} \<Longrightarrow> open (NN t)"
 | |
| 1350 |           and inUS: "\<And>t. t \<in> {0..1} \<Longrightarrow> t \<in> K t \<and> y \<in> NN t \<and> X t \<in> S"
 | |
| 1351 |           and him: "\<And>t. t \<in> {0..1} \<Longrightarrow> h ` (({0..1} \<inter> K t) \<times> (U \<inter> NN t)) \<subseteq> UU (X t)"
 | |
| 1352 | by (metis (mono_tags)) | |
| 1353 |     obtain \<T> where "\<T> \<subseteq> ((\<lambda>i. K i \<times> NN i)) ` {0..1}" "finite \<T>" "{0::real..1} \<times> {y} \<subseteq> \<Union>\<T>"
 | |
| 1354 | proof (rule compactE) | |
| 1355 |       show "compact ({0::real..1} \<times> {y})"
 | |
| 1356 | by (simp add: compact_Times) | |
| 1357 |       show "{0..1} \<times> {y} \<subseteq> (\<Union>i\<in>{0..1}. K i \<times> NN i)"
 | |
| 1358 | using K inUS by auto | |
| 1359 |       show "\<And>B. B \<in> (\<lambda>i. K i \<times> NN i) ` {0..1} \<Longrightarrow> open B"
 | |
| 1360 | using K NN by (auto simp: open_Times) | |
| 1361 | qed blast | |
| 1362 |     then obtain tk where "tk \<subseteq> {0..1}" "finite tk"
 | |
| 1363 |                      and tk: "{0::real..1} \<times> {y} \<subseteq> (\<Union>i \<in> tk. K i \<times> NN i)"
 | |
| 1364 | by (metis (no_types, lifting) finite_subset_image) | |
| 1365 |     then have "tk \<noteq> {}"
 | |
| 1366 | by auto | |
| 69313 | 1367 | define n where "n = \<Inter>(NN ` tk)" | 
| 64792 | 1368 | have "y \<in> n" "open n" | 
| 1369 |       using inUS NN \<open>tk \<subseteq> {0..1}\<close> \<open>finite tk\<close>
 | |
| 1370 | by (auto simp: n_def open_INT subset_iff) | |
| 1371 |     obtain \<delta> where "0 < \<delta>" and \<delta>: "\<And>T. \<lbrakk>T \<subseteq> {0..1}; diameter T < \<delta>\<rbrakk> \<Longrightarrow> \<exists>B\<in>K ` tk. T \<subseteq> B"
 | |
| 1372 |     proof (rule Lebesgue_number_lemma [of "{0..1}" "K ` tk"])
 | |
| 1373 |       show "K ` tk \<noteq> {}"
 | |
| 1374 |         using \<open>tk \<noteq> {}\<close> by auto
 | |
| 69313 | 1375 |       show "{0..1} \<subseteq> \<Union>(K ` tk)"
 | 
| 64792 | 1376 | using tk by auto | 
| 1377 | show "\<And>B. B \<in> K ` tk \<Longrightarrow> open B" | |
| 1378 |         using \<open>tk \<subseteq> {0..1}\<close> K by auto
 | |
| 1379 | qed auto | |
| 1380 | obtain N::nat where N: "N > 1 / \<delta>" | |
| 1381 | using reals_Archimedean2 by blast | |
| 1382 | then have "N > 0" | |
| 1383 | using \<open>0 < \<delta>\<close> order.asym by force | |
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1384 | have *: "\<exists>V k. openin (top_of_set U) V \<and> y \<in> V \<and> | 
| 64792 | 1385 |                    continuous_on ({0..of_nat n / N} \<times> V) k \<and>
 | 
| 1386 |                    k ` ({0..of_nat n / N} \<times> V) \<subseteq> C \<and>
 | |
| 1387 | (\<forall>z\<in>V. k (0, z) = f z) \<and> | |
| 1388 |                    (\<forall>z\<in>{0..of_nat n / N} \<times> V. h z = p (k z))" if "n \<le> N" for n
 | |
| 1389 | using that | |
| 1390 | proof (induction n) | |
| 1391 | case 0 | |
| 1392 | show ?case | |
| 1393 | apply (rule_tac x=U in exI) | |
| 1394 | apply (rule_tac x="f \<circ> snd" in exI) | |
| 1395 | apply (intro conjI \<open>y \<in> U\<close> continuous_intros continuous_on_subset [OF contf]) | |
| 1396 | using fim apply (auto simp: heq) | |
| 1397 | done | |
| 1398 | next | |
| 1399 | case (Suc n) | |
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1400 | then obtain V k where opeUV: "openin (top_of_set U) V" | 
| 64792 | 1401 | and "y \<in> V" | 
| 72496 | 1402 |                         and contk: "continuous_on ({0..n/N} \<times> V) k"
 | 
| 1403 |                         and kim: "k ` ({0..n/N} \<times> V) \<subseteq> C"
 | |
| 64792 | 1404 | and keq: "\<And>z. z \<in> V \<Longrightarrow> k (0, z) = f z" | 
| 72496 | 1405 |                         and heq: "\<And>z. z \<in> {0..n/N} \<times> V \<Longrightarrow> h z = p (k z)"
 | 
| 64792 | 1406 | using Suc_leD by auto | 
| 1407 | have "n \<le> N" | |
| 1408 | using Suc.prems by auto | |
| 72496 | 1409 |       obtain t where "t \<in> tk" and t: "{n/N .. (1 + real n) / N} \<subseteq> K t"
 | 
| 64792 | 1410 | proof (rule bexE [OF \<delta>]) | 
| 72496 | 1411 |         show "{n/N .. (1 + real n) / N} \<subseteq> {0..1}"
 | 
| 71172 | 1412 | using Suc.prems by (auto simp: field_split_simps) | 
| 72496 | 1413 |         show diameter_less: "diameter {n/N .. (1 + real n) / N} < \<delta>"
 | 
| 71172 | 1414 | using \<open>0 < \<delta>\<close> N by (auto simp: field_split_simps) | 
| 64792 | 1415 | qed blast | 
| 1416 |       have t01: "t \<in> {0..1}"
 | |
| 1417 |         using \<open>t \<in> tk\<close> \<open>tk \<subseteq> {0..1}\<close> by blast
 | |
| 66884 
c2128ab11f61
Switching to inverse image and constant_on, plus some new material
 paulson <lp15@cam.ac.uk> parents: 
66827diff
changeset | 1418 | obtain \<V> where \<V>: "\<Union>\<V> = C \<inter> p -` UU (X t)" | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1419 | and opeC: "\<And>U. U \<in> \<V> \<Longrightarrow> openin (top_of_set C) U" | 
| 64792 | 1420 | and "pairwise disjnt \<V>" | 
| 1421 | and homuu: "\<And>U. U \<in> \<V> \<Longrightarrow> \<exists>q. homeomorphism U (UU (X t)) p q" | |
| 1422 | using inUS [OF t01] UU by meson | |
| 72496 | 1423 |       have n_div_N_in: "n/N \<in> {n/N .. (1 + real n) / N}"
 | 
| 71172 | 1424 | using N by (auto simp: field_split_simps) | 
| 72496 | 1425 | with t have nN_in_kkt: "n/N \<in> K t" | 
| 64792 | 1426 | by blast | 
| 72496 | 1427 | have "k (n/N, y) \<in> C \<inter> p -` UU (X t)" | 
| 64792 | 1428 | proof (simp, rule conjI) | 
| 72496 | 1429 | show "k (n/N, y) \<in> C" | 
| 64792 | 1430 | using \<open>y \<in> V\<close> kim keq by force | 
| 72496 | 1431 | have "p (k (n/N, y)) = h (n/N, y)" | 
| 64792 | 1432 | by (simp add: \<open>y \<in> V\<close> heq) | 
| 1433 |         also have "... \<in> h ` (({0..1} \<inter> K t) \<times> (U \<inter> NN t))"
 | |
| 1434 | using \<open>y \<in> V\<close> t01 \<open>n \<le> N\<close> | |
| 72496 | 1435 | by (simp add: nN_in_kkt \<open>y \<in> U\<close> inUS field_split_simps) | 
| 64792 | 1436 | also have "... \<subseteq> UU (X t)" | 
| 1437 | using him t01 by blast | |
| 72496 | 1438 | finally show "p (k (n/N, y)) \<in> UU (X t)" . | 
| 64792 | 1439 | qed | 
| 72496 | 1440 | with \<V> have "k (n/N, y) \<in> \<Union>\<V>" | 
| 66884 
c2128ab11f61
Switching to inverse image and constant_on, plus some new material
 paulson <lp15@cam.ac.uk> parents: 
66827diff
changeset | 1441 | by blast | 
| 72496 | 1442 | then obtain W where W: "k (n/N, y) \<in> W" and "W \<in> \<V>" | 
| 64792 | 1443 | by blast | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1444 | then obtain p' where opeC': "openin (top_of_set C) W" | 
| 64792 | 1445 | and hom': "homeomorphism W (UU (X t)) p p'" | 
| 1446 | using homuu opeC by blast | |
| 1447 | then have "W \<subseteq> C" | |
| 1448 | using openin_imp_subset by blast | |
| 1449 | define W' where "W' = UU(X t)" | |
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1450 | have opeVW: "openin (top_of_set V) (V \<inter> (k \<circ> Pair (n / N)) -` W)" | 
| 72496 | 1451 | proof (rule continuous_openin_preimage [OF _ _ opeC']) | 
| 1452 | show "continuous_on V (k \<circ> Pair (n/N))" | |
| 1453 | by (intro continuous_intros continuous_on_subset [OF contk], auto) | |
| 1454 | show "(k \<circ> Pair (n/N)) ` V \<subseteq> C" | |
| 1455 | using kim by (auto simp: \<open>y \<in> V\<close> W) | |
| 1456 | qed | |
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1457 | obtain N' where opeUN': "openin (top_of_set U) N'" | 
| 72496 | 1458 |                 and "y \<in> N'" and kimw: "k ` ({(n/N)} \<times> N') \<subseteq> W"
 | 
| 1459 | proof | |
| 1460 | show "openin (top_of_set U) (V \<inter> (k \<circ> Pair (n/N)) -` W)" | |
| 1461 | using opeUV opeVW openin_trans by blast | |
| 1462 | qed (use \<open>y \<in> V\<close> W in \<open>force+\<close>) | |
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1463 | obtain Q Q' where opeUQ: "openin (top_of_set U) Q" | 
| 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1464 | and cloUQ': "closedin (top_of_set U) Q'" | 
| 64792 | 1465 | and "y \<in> Q" "Q \<subseteq> Q'" | 
| 1466 | and Q': "Q' \<subseteq> (U \<inter> NN(t)) \<inter> N' \<inter> V" | |
| 1467 | proof - | |
| 1468 | obtain VO VX where "open VO" "open VX" and VO: "V = U \<inter> VO" and VX: "N' = U \<inter> VX" | |
| 1469 | using opeUV opeUN' by (auto simp: openin_open) | |
| 1470 | then have "open (NN(t) \<inter> VO \<inter> VX)" | |
| 1471 | using NN t01 by blast | |
| 1472 | then obtain e where "e > 0" and e: "cball y e \<subseteq> NN(t) \<inter> VO \<inter> VX" | |
| 1473 | by (metis Int_iff \<open>N' = U \<inter> VX\<close> \<open>V = U \<inter> VO\<close> \<open>y \<in> N'\<close> \<open>y \<in> V\<close> inUS open_contains_cball t01) | |
| 1474 | show ?thesis | |
| 1475 | proof | |
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1476 | show "openin (top_of_set U) (U \<inter> ball y e)" | 
| 64792 | 1477 | by blast | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1478 | show "closedin (top_of_set U) (U \<inter> cball y e)" | 
| 64792 | 1479 | using e by (auto simp: closedin_closed) | 
| 1480 | qed (use \<open>y \<in> U\<close> \<open>e > 0\<close> VO VX e in auto) | |
| 1481 | qed | |
| 1482 | then have "y \<in> Q'" "Q \<subseteq> (U \<inter> NN(t)) \<inter> N' \<inter> V" | |
| 1483 | by blast+ | |
| 72496 | 1484 |       have neq: "{0..n/N} \<union> {n/N..(1 + real n) / N} = {0..(1 + real n) / N}"
 | 
| 70817 
dd675800469d
dedicated fact collections for algebraic simplification rules potentially splitting goals
 haftmann parents: 
70802diff
changeset | 1485 | apply (auto simp: field_split_simps) | 
| 72569 
d56e4eeae967
mult_le_cancel_iff1, mult_le_cancel_iff2, mult_less_iff1 generalised from the real_ versions
 paulson <lp15@cam.ac.uk> parents: 
72496diff
changeset | 1486 | by (metis not_less of_nat_0_le_iff of_nat_0_less_iff order_trans zero_le_mult_iff) | 
| 72496 | 1487 |       then have neqQ': "{0..n/N} \<times> Q' \<union> {n/N..(1 + real n) / N} \<times> Q' = {0..(1 + real n) / N} \<times> Q'"
 | 
| 64792 | 1488 | by blast | 
| 72496 | 1489 |       have cont: "continuous_on ({0..(1 + real n) / N} \<times> Q') (\<lambda>x. if x \<in> {0..n/N} \<times> Q' then k x else (p' \<circ> h) x)"
 | 
| 64792 | 1490 | unfolding neqQ' [symmetric] | 
| 1491 | proof (rule continuous_on_cases_local, simp_all add: neqQ' del: comp_apply) | |
| 72496 | 1492 |         have "\<exists>T. closed T \<and> {0..n/N} \<times> Q' = {0..(1+n)/N} \<times> Q' \<inter> T"
 | 
| 1493 | using n_div_N_in | |
| 1494 |           by (rule_tac x="{0 .. n/N} \<times> UNIV" in exI) (auto simp: closed_Times)
 | |
| 1495 |         then show "closedin (top_of_set ({0..(1 + real n) / N} \<times> Q')) ({0..n/N} \<times> Q')"
 | |
| 1496 | by (simp add: closedin_closed) | |
| 1497 |         have "\<exists>T. closed T \<and> {n/N..(1+n)/N} \<times> Q' = {0..(1+n)/N} \<times> Q' \<inter> T"
 | |
| 1498 |           by (rule_tac x="{n/N..(1+n)/N} \<times> UNIV" in exI) (auto simp: closed_Times order_trans [rotated])
 | |
| 1499 |         then show "closedin (top_of_set ({0..(1 + real n) / N} \<times> Q')) ({n/N..(1 + real n) / N} \<times> Q')"
 | |
| 1500 | by (simp add: closedin_closed) | |
| 1501 |         show "continuous_on ({0..n/N} \<times> Q') k"
 | |
| 1502 | using Q' by (auto intro: continuous_on_subset [OF contk]) | |
| 1503 |         have "continuous_on ({n/N..(1 + real n) / N} \<times> Q') h"
 | |
| 64792 | 1504 | proof (rule continuous_on_subset [OF conth]) | 
| 72496 | 1505 |           show "{n/N..(1 + real n) / N} \<times> Q' \<subseteq> {0..1} \<times> U"
 | 
| 1506 | proof (clarsimp, intro conjI) | |
| 1507 | fix a b | |
| 1508 | assume "b \<in> Q'" and a: "n/N \<le> a" "a \<le> (1 + real n) / N" | |
| 1509 | have "0 \<le> n/N" "(1 + real n) / N \<le> 1" | |
| 1510 | using a Suc.prems by (auto simp: divide_simps) | |
| 1511 | with a show "0 \<le> a" "a \<le> 1" | |
| 1512 | by linarith+ | |
| 1513 | show "b \<in> U" | |
| 1514 | using \<open>b \<in> Q'\<close> cloUQ' closedin_imp_subset by blast | |
| 1515 | qed | |
| 64792 | 1516 | qed | 
| 72496 | 1517 |         moreover have "continuous_on (h ` ({n/N..(1 + real n) / N} \<times> Q')) p'"
 | 
| 64792 | 1518 | proof (rule continuous_on_subset [OF homeomorphism_cont2 [OF hom']]) | 
| 72496 | 1519 |           have "h ` ({n/N..(1 + real n) / N} \<times> Q') \<subseteq> h ` (({0..1} \<inter> K t) \<times> (U \<inter> NN t))"
 | 
| 1520 | proof (rule image_mono) | |
| 1521 |             show "{n/N..(1 + real n) / N} \<times> Q' \<subseteq> ({0..1} \<inter> K t) \<times> (U \<inter> NN t)"
 | |
| 1522 | proof (clarsimp, intro conjI) | |
| 1523 | fix a::real and b | |
| 1524 | assume "b \<in> Q'" "n/N \<le> a" "a \<le> (1 + real n) / N" | |
| 1525 | show "0 \<le> a" | |
| 1526 | by (meson \<open>n/N \<le> a\<close> divide_nonneg_nonneg of_nat_0_le_iff order_trans) | |
| 1527 | show "a \<le> 1" | |
| 1528 | using Suc.prems \<open>a \<le> (1 + real n) / N\<close> order_trans by force | |
| 1529 | show "a \<in> K t" | |
| 1530 | using \<open>a \<le> (1 + real n) / N\<close> \<open>n/N \<le> a\<close> t by auto | |
| 1531 | show "b \<in> U" | |
| 1532 | using \<open>b \<in> Q'\<close> cloUQ' closedin_imp_subset by blast | |
| 1533 | show "b \<in> NN t" | |
| 1534 | using Q' \<open>b \<in> Q'\<close> by auto | |
| 1535 | qed | |
| 1536 | qed | |
| 1537 |           with him show "h ` ({n/N..(1 + real n) / N} \<times> Q') \<subseteq> UU (X t)"
 | |
| 64792 | 1538 | using t01 by blast | 
| 1539 | qed | |
| 72496 | 1540 |         ultimately show "continuous_on ({n/N..(1 + real n) / N} \<times> Q') (p' \<circ> h)"
 | 
| 64792 | 1541 | by (rule continuous_on_compose) | 
| 72496 | 1542 | have "k (n/N, b) = p' (h (n/N, b))" if "b \<in> Q'" for b | 
| 64792 | 1543 | proof - | 
| 72496 | 1544 | have "k (n/N, b) \<in> W" | 
| 64792 | 1545 | using that Q' kimw by force | 
| 72496 | 1546 | then have "k (n/N, b) = p' (p (k (n/N, b)))" | 
| 64792 | 1547 | by (simp add: homeomorphism_apply1 [OF hom']) | 
| 1548 | then show ?thesis | |
| 1549 | using Q' that by (force simp: heq) | |
| 1550 | qed | |
| 72496 | 1551 |         then show "\<And>x. x \<in> {n/N..(1 + real n) / N} \<times> Q' \<and>
 | 
| 1552 |                   x \<in> {0..n/N} \<times> Q' \<Longrightarrow> k x = (p' \<circ> h) x"
 | |
| 64792 | 1553 | by auto | 
| 1554 | qed | |
| 72496 | 1555 | have h_in_UU: "h (x, y) \<in> UU (X t)" if "y \<in> Q" "\<not> x \<le> n/N" "0 \<le> x" "x \<le> (1 + real n) / N" for x y | 
| 64792 | 1556 | proof - | 
| 1557 | have "x \<le> 1" | |
| 1558 | using Suc.prems that order_trans by force | |
| 1559 | moreover have "x \<in> K t" | |
| 1560 | by (meson atLeastAtMost_iff le_less not_le subset_eq t that) | |
| 1561 | moreover have "y \<in> U" | |
| 1562 | using \<open>y \<in> Q\<close> opeUQ openin_imp_subset by blast | |
| 1563 | moreover have "y \<in> NN t" | |
| 1564 | using Q' \<open>Q \<subseteq> Q'\<close> \<open>y \<in> Q\<close> by auto | |
| 1565 |         ultimately have "(x, y) \<in> (({0..1} \<inter> K t) \<times> (U \<inter> NN t))"
 | |
| 1566 | using that by auto | |
| 1567 |         then have "h (x, y) \<in> h ` (({0..1} \<inter> K t) \<times> (U \<inter> NN t))"
 | |
| 1568 | by blast | |
| 1569 | also have "... \<subseteq> UU (X t)" | |
| 1570 | by (metis him t01) | |
| 1571 | finally show ?thesis . | |
| 1572 | qed | |
| 72496 | 1573 |       let ?k = "(\<lambda>x. if x \<in> {0..n/N} \<times> Q' then k x else (p' \<circ> h) x)"
 | 
| 64792 | 1574 | show ?case | 
| 1575 | proof (intro exI conjI) | |
| 72496 | 1576 |         show "continuous_on ({0..real (Suc n) / N} \<times> Q) ?k"
 | 
| 1577 | using \<open>Q \<subseteq> Q'\<close> by (auto intro: continuous_on_subset [OF cont]) | |
| 1578 | have "\<And>x y. \<lbrakk>x \<le> n/N; y \<in> Q'; 0 \<le> x\<rbrakk> \<Longrightarrow> k (x, y) \<in> C" | |
| 64792 | 1579 | using kim Q' by force | 
| 72496 | 1580 | moreover have "p' (h (x, y)) \<in> C" if "y \<in> Q" "\<not> x \<le> n/N" "0 \<le> x" "x \<le> (1 + real n) / N" for x y | 
| 1581 | proof (rule \<open>W \<subseteq> C\<close> [THEN subsetD]) | |
| 1582 | show "p' (h (x, y)) \<in> W" | |
| 1583 | using homeomorphism_image2 [OF hom', symmetric] h_in_UU Q' \<open>Q \<subseteq> Q'\<close> \<open>W \<subseteq> C\<close> that by auto | |
| 1584 | qed | |
| 1585 |         ultimately show "?k ` ({0..real (Suc n) / N} \<times> Q) \<subseteq> C"
 | |
| 64792 | 1586 | using Q' \<open>Q \<subseteq> Q'\<close> by force | 
| 1587 | show "\<forall>z\<in>Q. ?k (0, z) = f z" | |
| 1588 | using Q' keq \<open>Q \<subseteq> Q'\<close> by auto | |
| 72496 | 1589 |         show "\<forall>z \<in> {0..real (Suc n) / N} \<times> Q. h z = p(?k z)"
 | 
| 1590 | using \<open>Q \<subseteq> U \<inter> NN t \<inter> N' \<inter> V\<close> heq Q' \<open>Q \<subseteq> Q'\<close> | |
| 1591 | by (auto simp: homeomorphism_apply2 [OF hom'] dest: h_in_UU) | |
| 64792 | 1592 | qed (auto simp: \<open>y \<in> Q\<close> opeUQ) | 
| 1593 | qed | |
| 1594 | show ?thesis | |
| 72496 | 1595 | using *[OF order_refl] N \<open>0 < \<delta>\<close> by (simp add: split: if_split_asm) | 
| 64792 | 1596 | qed | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1597 | then obtain V fs where opeV: "\<And>y. y \<in> U \<Longrightarrow> openin (top_of_set U) (V y)" | 
| 64792 | 1598 | and V: "\<And>y. y \<in> U \<Longrightarrow> y \<in> V y" | 
| 1599 |           and contfs: "\<And>y. y \<in> U \<Longrightarrow> continuous_on ({0..1} \<times> V y) (fs y)"
 | |
| 1600 |           and *: "\<And>y. y \<in> U \<Longrightarrow> (fs y) ` ({0..1} \<times> V y) \<subseteq> C \<and>
 | |
| 1601 | (\<forall>z \<in> V y. fs y (0, z) = f z) \<and> | |
| 1602 |                             (\<forall>z \<in> {0..1} \<times> V y. h z = p(fs y z))"
 | |
| 1603 | by (metis (mono_tags)) | |
| 1604 | then have VU: "\<And>y. y \<in> U \<Longrightarrow> V y \<subseteq> U" | |
| 1605 | by (meson openin_imp_subset) | |
| 1606 |   obtain k where contk: "continuous_on ({0..1} \<times> U) k"
 | |
| 1607 |              and k: "\<And>x i. \<lbrakk>i \<in> U; x \<in> {0..1} \<times> U \<inter> {0..1} \<times> V i\<rbrakk> \<Longrightarrow> k x = fs i x"
 | |
| 1608 | proof (rule pasting_lemma_exists) | |
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1609 |     let ?X = "top_of_set ({0..1::real} \<times> U)"
 | 
| 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1610 |     show "topspace ?X \<subseteq> (\<Union>i\<in>U. {0..1} \<times> V i)"
 | 
| 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1611 | using V by force | 
| 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1612 |     show "\<And>i. i \<in> U \<Longrightarrow> openin (top_of_set ({0..1} \<times> U)) ({0..1} \<times> V i)"
 | 
| 69986 
f2d327275065
generalised homotopic_with to topologies; homotopic_with_canon is the old version
 paulson <lp15@cam.ac.uk> parents: 
69922diff
changeset | 1613 | by (simp add: Abstract_Topology.openin_Times opeV) | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1614 | show "\<And>i. i \<in> U \<Longrightarrow> continuous_map | 
| 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1615 |               (subtopology (top_of_set ({0..1} \<times> U)) ({0..1} \<times> V i)) euclidean (fs i)"
 | 
| 72496 | 1616 | by (metis contfs subtopology_subtopology continuous_map_iff_continuous Times_Int_Times VU inf.absorb_iff2 inf.idem) | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1617 |     show "fs i x = fs j x"  if "i \<in> U" "j \<in> U" and x: "x \<in> topspace ?X \<inter> {0..1} \<times> V i \<inter> {0..1} \<times> V j"
 | 
| 64792 | 1618 | for i j x | 
| 1619 | proof - | |
| 1620 | obtain u y where "x = (u, y)" "y \<in> V i" "y \<in> V j" "0 \<le> u" "u \<le> 1" | |
| 1621 | using x by auto | |
| 1622 | show ?thesis | |
| 1623 |       proof (rule covering_space_lift_unique [OF cov, of _ "(0,y)" _ "{0..1} \<times> {y}" h])
 | |
| 1624 | show "fs i (0, y) = fs j (0, y)" | |
| 1625 | using*V by (simp add: \<open>y \<in> V i\<close> \<open>y \<in> V j\<close> that) | |
| 1626 |         show conth_y: "continuous_on ({0..1} \<times> {y}) h"
 | |
| 72496 | 1627 | using VU \<open>y \<in> V j\<close> that by (auto intro: continuous_on_subset [OF conth]) | 
| 64792 | 1628 |         show "h ` ({0..1} \<times> {y}) \<subseteq> S"
 | 
| 1629 | using \<open>y \<in> V i\<close> assms(3) VU that by fastforce | |
| 1630 |         show "continuous_on ({0..1} \<times> {y}) (fs i)"
 | |
| 1631 | using continuous_on_subset [OF contfs] \<open>i \<in> U\<close> | |
| 1632 | by (simp add: \<open>y \<in> V i\<close> subset_iff) | |
| 1633 |         show "fs i ` ({0..1} \<times> {y}) \<subseteq> C"
 | |
| 1634 | using "*" \<open>y \<in> V i\<close> \<open>i \<in> U\<close> by fastforce | |
| 1635 |         show "\<And>x. x \<in> {0..1} \<times> {y} \<Longrightarrow> h x = p (fs i x)"
 | |
| 1636 | using "*" \<open>y \<in> V i\<close> \<open>i \<in> U\<close> by blast | |
| 1637 |         show "continuous_on ({0..1} \<times> {y}) (fs j)"
 | |
| 1638 | using continuous_on_subset [OF contfs] \<open>j \<in> U\<close> | |
| 1639 | by (simp add: \<open>y \<in> V j\<close> subset_iff) | |
| 1640 |         show "fs j ` ({0..1} \<times> {y}) \<subseteq> C"
 | |
| 1641 | using "*" \<open>y \<in> V j\<close> \<open>j \<in> U\<close> by fastforce | |
| 1642 |         show "\<And>x. x \<in> {0..1} \<times> {y} \<Longrightarrow> h x = p (fs j x)"
 | |
| 1643 | using "*" \<open>y \<in> V j\<close> \<open>j \<in> U\<close> by blast | |
| 1644 |         show "connected ({0..1::real} \<times> {y})"
 | |
| 1645 | using connected_Icc connected_Times connected_sing by blast | |
| 1646 |         show "(0, y) \<in> {0..1::real} \<times> {y}"
 | |
| 1647 | by force | |
| 1648 |         show "x \<in> {0..1} \<times> {y}"
 | |
| 1649 | using \<open>x = (u, y)\<close> x by blast | |
| 1650 | qed | |
| 1651 | qed | |
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 1652 | qed force | 
| 64792 | 1653 | show ?thesis | 
| 1654 | proof | |
| 1655 |     show "k ` ({0..1} \<times> U) \<subseteq> C"
 | |
| 1656 | using V*k VU by fastforce | |
| 1657 | show "\<And>y. y \<in> U \<Longrightarrow> k (0, y) = f y" | |
| 1658 | by (simp add: V*k) | |
| 1659 |     show "\<And>z. z \<in> {0..1} \<times> U \<Longrightarrow> h z = p (k z)"
 | |
| 1660 | using V*k by auto | |
| 1661 | qed (auto simp: contk) | |
| 1662 | qed | |
| 1663 | ||
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1664 | corollary covering_space_lift_homotopy_alt: | 
| 64792 | 1665 | fixes p :: "'a::real_normed_vector \<Rightarrow> 'b::real_normed_vector" | 
| 1666 | and h :: "'c::real_normed_vector \<times> real \<Rightarrow> 'b" | |
| 1667 | assumes cov: "covering_space C p S" | |
| 1668 |       and conth: "continuous_on (U \<times> {0..1}) h"
 | |
| 1669 |       and him: "h ` (U \<times> {0..1}) \<subseteq> S"
 | |
| 1670 | and heq: "\<And>y. y \<in> U \<Longrightarrow> h (y,0) = p(f y)" | |
| 1671 | and contf: "continuous_on U f" and fim: "f ` U \<subseteq> C" | |
| 1672 |   obtains k where "continuous_on (U \<times> {0..1}) k"
 | |
| 1673 |                   "k ` (U \<times> {0..1}) \<subseteq> C"
 | |
| 1674 | "\<And>y. y \<in> U \<Longrightarrow> k(y, 0) = f y" | |
| 1675 |                   "\<And>z. z \<in> U \<times> {0..1} \<Longrightarrow> h z = p(k z)"
 | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1676 | proof - | 
| 64792 | 1677 |   have "continuous_on ({0..1} \<times> U) (h \<circ> (\<lambda>z. (snd z, fst z)))"
 | 
| 1678 | by (intro continuous_intros continuous_on_subset [OF conth]) auto | |
| 1679 |   then obtain k where contk: "continuous_on ({0..1} \<times> U) k"
 | |
| 1680 |                   and kim:  "k ` ({0..1} \<times> U) \<subseteq> C"
 | |
| 1681 | and k0: "\<And>y. y \<in> U \<Longrightarrow> k(0, y) = f y" | |
| 1682 |                   and heqp: "\<And>z. z \<in> {0..1} \<times> U \<Longrightarrow> (h \<circ> (\<lambda>z. Pair (snd z) (fst z))) z = p(k z)"
 | |
| 1683 | apply (rule covering_space_lift_homotopy [OF cov _ _ _ contf fim]) | |
| 1684 | using him by (auto simp: contf heq) | |
| 1685 | show ?thesis | |
| 72496 | 1686 | proof | 
| 1687 |     show "continuous_on (U \<times> {0..1}) (k \<circ> (\<lambda>z. (snd z, fst z)))"
 | |
| 1688 | by (intro continuous_intros continuous_on_subset [OF contk]) auto | |
| 1689 | qed (use kim heqp in \<open>auto simp: k0\<close>) | |
| 64792 | 1690 | qed | 
| 1691 | ||
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1692 | corollary covering_space_lift_homotopic_function: | 
| 64792 | 1693 | fixes p :: "'a::real_normed_vector \<Rightarrow> 'b::real_normed_vector" and g:: "'c::real_normed_vector \<Rightarrow> 'a" | 
| 1694 | assumes cov: "covering_space C p S" | |
| 1695 | and contg: "continuous_on U g" | |
| 1696 | and gim: "g ` U \<subseteq> C" | |
| 1697 | and pgeq: "\<And>y. y \<in> U \<Longrightarrow> p(g y) = f y" | |
| 69986 
f2d327275065
generalised homotopic_with to topologies; homotopic_with_canon is the old version
 paulson <lp15@cam.ac.uk> parents: 
69922diff
changeset | 1698 | and hom: "homotopic_with_canon (\<lambda>x. True) U S f f'" | 
| 64792 | 1699 | obtains g' where "continuous_on U g'" "image g' U \<subseteq> C" "\<And>y. y \<in> U \<Longrightarrow> p(g' y) = f' y" | 
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1700 | proof - | 
| 64792 | 1701 |   obtain h where conth: "continuous_on ({0..1::real} \<times> U) h"
 | 
| 1702 |              and him: "h ` ({0..1} \<times> U) \<subseteq> S"
 | |
| 1703 | and h0: "\<And>x. h(0, x) = f x" | |
| 1704 | and h1: "\<And>x. h(1, x) = f' x" | |
| 1705 | using hom by (auto simp: homotopic_with_def) | |
| 1706 | have "\<And>y. y \<in> U \<Longrightarrow> h (0, y) = p (g y)" | |
| 1707 | by (simp add: h0 pgeq) | |
| 1708 |   then obtain k where contk: "continuous_on ({0..1} \<times> U) k"
 | |
| 1709 |                   and kim: "k ` ({0..1} \<times> U) \<subseteq> C"
 | |
| 1710 | and k0: "\<And>y. y \<in> U \<Longrightarrow> k(0, y) = g y" | |
| 1711 |                   and heq: "\<And>z. z \<in> {0..1} \<times> U \<Longrightarrow> h z = p(k z)"
 | |
| 1712 | using covering_space_lift_homotopy [OF cov conth him _ contg gim] by metis | |
| 1713 | show ?thesis | |
| 1714 | proof | |
| 1715 | show "continuous_on U (k \<circ> Pair 1)" | |
| 1716 | by (meson contk atLeastAtMost_iff continuous_on_o_Pair order_refl zero_le_one) | |
| 1717 | show "(k \<circ> Pair 1) ` U \<subseteq> C" | |
| 1718 | using kim by auto | |
| 1719 | show "\<And>y. y \<in> U \<Longrightarrow> p ((k \<circ> Pair 1) y) = f' y" | |
| 1720 | by (auto simp: h1 heq [symmetric]) | |
| 1721 | qed | |
| 1722 | qed | |
| 1723 | ||
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1724 | corollary covering_space_lift_inessential_function: | 
| 64792 | 1725 | fixes p :: "'a::real_normed_vector \<Rightarrow> 'b::real_normed_vector" and U :: "'c::real_normed_vector set" | 
| 1726 | assumes cov: "covering_space C p S" | |
| 69986 
f2d327275065
generalised homotopic_with to topologies; homotopic_with_canon is the old version
 paulson <lp15@cam.ac.uk> parents: 
69922diff
changeset | 1727 | and hom: "homotopic_with_canon (\<lambda>x. True) U S f (\<lambda>x. a)" | 
| 64792 | 1728 | obtains g where "continuous_on U g" "g ` U \<subseteq> C" "\<And>y. y \<in> U \<Longrightarrow> p(g y) = f y" | 
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1729 | proof (cases "U = {}")
 | 
| 64792 | 1730 | case True | 
| 1731 | then show ?thesis | |
| 1732 | using that continuous_on_empty by blast | |
| 1733 | next | |
| 1734 | case False | |
| 1735 | then obtain b where b: "b \<in> C" "p b = a" | |
| 1736 | using covering_space_imp_surjective [OF cov] homotopic_with_imp_subset2 [OF hom] | |
| 1737 | by auto | |
| 1738 | then have gim: "(\<lambda>y. b) ` U \<subseteq> C" | |
| 1739 | by blast | |
| 1740 | show ?thesis | |
| 72496 | 1741 | proof (rule covering_space_lift_homotopic_function [OF cov continuous_on_const gim]) | 
| 1742 | show "\<And>y. y \<in> U \<Longrightarrow> p b = a" | |
| 1743 | using b by auto | |
| 1744 | qed (use that homotopic_with_symD [OF hom] in auto) | |
| 64792 | 1745 | qed | 
| 1746 | ||
| 69683 | 1747 | subsection\<open> Lifting of general functions to covering space\<close> | 
| 64792 | 1748 | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1749 | proposition covering_space_lift_path_strong: | 
| 64792 | 1750 | fixes p :: "'a::real_normed_vector \<Rightarrow> 'b::real_normed_vector" | 
| 1751 | and f :: "'c::real_normed_vector \<Rightarrow> 'b" | |
| 1752 | assumes cov: "covering_space C p S" and "a \<in> C" | |
| 1753 | and "path g" and pag: "path_image g \<subseteq> S" and pas: "pathstart g = p a" | |
| 1754 | obtains h where "path h" "path_image h \<subseteq> C" "pathstart h = a" | |
| 1755 |                 and "\<And>t. t \<in> {0..1} \<Longrightarrow> p(h t) = g t"
 | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1756 | proof - | 
| 64792 | 1757 | obtain k:: "real \<times> 'c \<Rightarrow> 'a" | 
| 1758 |     where contk: "continuous_on ({0..1} \<times> {undefined}) k"
 | |
| 1759 |       and kim: "k ` ({0..1} \<times> {undefined}) \<subseteq> C"
 | |
| 1760 | and k0: "k (0, undefined) = a" | |
| 1761 |       and pk: "\<And>z. z \<in> {0..1} \<times> {undefined} \<Longrightarrow> p(k z) = (g \<circ> fst) z"
 | |
| 1762 |   proof (rule covering_space_lift_homotopy [OF cov, of "{undefined}" "g \<circ> fst"])
 | |
| 1763 |     show "continuous_on ({0..1::real} \<times> {undefined::'c}) (g \<circ> fst)"
 | |
| 72496 | 1764 | using \<open>path g\<close> by (intro continuous_intros) (simp add: path_def) | 
| 64792 | 1765 |     show "(g \<circ> fst) ` ({0..1} \<times> {undefined}) \<subseteq> S"
 | 
| 1766 | using pag by (auto simp: path_image_def) | |
| 1767 |     show "(g \<circ> fst) (0, y) = p a" if "y \<in> {undefined}" for y::'c
 | |
| 1768 | by (metis comp_def fst_conv pas pathstart_def) | |
| 1769 | qed (use assms in auto) | |
| 1770 | show ?thesis | |
| 1771 | proof | |
| 1772 | show "path (k \<circ> (\<lambda>t. Pair t undefined))" | |
| 1773 | unfolding path_def | |
| 1774 | by (intro continuous_on_compose continuous_intros continuous_on_subset [OF contk]) auto | |
| 1775 | show "path_image (k \<circ> (\<lambda>t. (t, undefined))) \<subseteq> C" | |
| 1776 | using kim by (auto simp: path_image_def) | |
| 1777 | show "pathstart (k \<circ> (\<lambda>t. (t, undefined))) = a" | |
| 1778 | by (auto simp: pathstart_def k0) | |
| 1779 |     show "\<And>t. t \<in> {0..1} \<Longrightarrow> p ((k \<circ> (\<lambda>t. (t, undefined))) t) = g t"
 | |
| 1780 | by (auto simp: pk) | |
| 1781 | qed | |
| 1782 | qed | |
| 1783 | ||
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1784 | corollary covering_space_lift_path: | 
| 64792 | 1785 | fixes p :: "'a::real_normed_vector \<Rightarrow> 'b::real_normed_vector" | 
| 1786 | assumes cov: "covering_space C p S" and "path g" and pig: "path_image g \<subseteq> S" | |
| 1787 |   obtains h where "path h" "path_image h \<subseteq> C" "\<And>t. t \<in> {0..1} \<Longrightarrow> p(h t) = g t"
 | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1788 | proof - | 
| 64792 | 1789 | obtain a where "a \<in> C" "pathstart g = p a" | 
| 1790 | by (metis pig cov covering_space_imp_surjective imageE pathstart_in_path_image subsetCE) | |
| 1791 | show ?thesis | |
| 1792 | using covering_space_lift_path_strong [OF cov \<open>a \<in> C\<close> \<open>path g\<close> pig] | |
| 1793 | by (metis \<open>pathstart g = p a\<close> that) | |
| 1794 | qed | |
| 1795 | ||
| 1796 | ||
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1797 | proposition covering_space_lift_homotopic_paths: | 
| 64792 | 1798 | fixes p :: "'a::real_normed_vector \<Rightarrow> 'b::real_normed_vector" | 
| 1799 | assumes cov: "covering_space C p S" | |
| 1800 | and "path g1" and pig1: "path_image g1 \<subseteq> S" | |
| 1801 | and "path g2" and pig2: "path_image g2 \<subseteq> S" | |
| 1802 | and hom: "homotopic_paths S g1 g2" | |
| 1803 |       and "path h1" and pih1: "path_image h1 \<subseteq> C" and ph1: "\<And>t. t \<in> {0..1} \<Longrightarrow> p(h1 t) = g1 t"
 | |
| 1804 |       and "path h2" and pih2: "path_image h2 \<subseteq> C" and ph2: "\<And>t. t \<in> {0..1} \<Longrightarrow> p(h2 t) = g2 t"
 | |
| 1805 | and h1h2: "pathstart h1 = pathstart h2" | |
| 1806 | shows "homotopic_paths C h1 h2" | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1807 | proof - | 
| 64792 | 1808 | obtain h :: "real \<times> real \<Rightarrow> 'b" | 
| 1809 |      where conth: "continuous_on ({0..1} \<times> {0..1}) h"
 | |
| 1810 |        and him: "h ` ({0..1} \<times> {0..1}) \<subseteq> S"
 | |
| 1811 | and h0: "\<And>x. h (0, x) = g1 x" and h1: "\<And>x. h (1, x) = g2 x" | |
| 1812 |        and heq0: "\<And>t. t \<in> {0..1} \<Longrightarrow> h (t, 0) = g1 0"
 | |
| 1813 |        and heq1: "\<And>t. t \<in> {0..1} \<Longrightarrow> h (t, 1) = g1 1"
 | |
| 1814 | using hom by (auto simp: homotopic_paths_def homotopic_with_def pathstart_def pathfinish_def) | |
| 1815 |   obtain k where contk: "continuous_on ({0..1} \<times> {0..1}) k"
 | |
| 1816 |              and kim: "k ` ({0..1} \<times> {0..1}) \<subseteq> C"
 | |
| 1817 |              and kh2: "\<And>y. y \<in> {0..1} \<Longrightarrow> k (y, 0) = h2 0"
 | |
| 1818 |              and hpk: "\<And>z. z \<in> {0..1} \<times> {0..1} \<Longrightarrow> h z = p (k z)"
 | |
| 72496 | 1819 | proof (rule covering_space_lift_homotopy_alt [OF cov conth him]) | 
| 1820 |     show "\<And>y. y \<in> {0..1} \<Longrightarrow> h (y, 0) = p (h2 0)"
 | |
| 1821 | by (metis atLeastAtMost_iff h1h2 heq0 order_refl pathstart_def ph1 zero_le_one) | |
| 1822 | qed (use path_image_def pih2 in \<open>fastforce+\<close>) | |
| 64792 | 1823 |   have contg1: "continuous_on {0..1} g1" and contg2: "continuous_on {0..1} g2"
 | 
| 1824 | using \<open>path g1\<close> \<open>path g2\<close> path_def by blast+ | |
| 1825 |   have g1im: "g1 ` {0..1} \<subseteq> S" and g2im: "g2 ` {0..1} \<subseteq> S"
 | |
| 1826 | using path_image_def pig1 pig2 by auto | |
| 1827 |   have conth1: "continuous_on {0..1} h1" and conth2: "continuous_on {0..1} h2"
 | |
| 1828 | using \<open>path h1\<close> \<open>path h2\<close> path_def by blast+ | |
| 1829 |   have h1im: "h1 ` {0..1} \<subseteq> C" and h2im: "h2 ` {0..1} \<subseteq> C"
 | |
| 1830 | using path_image_def pih1 pih2 by auto | |
| 1831 | show ?thesis | |
| 1832 | unfolding homotopic_paths pathstart_def pathfinish_def | |
| 1833 | proof (intro exI conjI ballI) | |
| 1834 |     show keqh1: "k(0, x) = h1 x" if "x \<in> {0..1}" for x
 | |
| 1835 | proof (rule covering_space_lift_unique [OF cov _ contg1 g1im]) | |
| 1836 | show "k (0,0) = h1 0" | |
| 1837 | by (metis atLeastAtMost_iff h1h2 kh2 order_refl pathstart_def zero_le_one) | |
| 1838 |       show "continuous_on {0..1} (\<lambda>a. k (0, a))"
 | |
| 1839 | by (intro continuous_intros continuous_on_compose2 [OF contk]) auto | |
| 1840 |       show "\<And>x. x \<in> {0..1} \<Longrightarrow> g1 x = p (k (0, x))"
 | |
| 1841 | by (metis atLeastAtMost_iff h0 hpk zero_le_one mem_Sigma_iff order_refl) | |
| 1842 | qed (use conth1 h1im kim that in \<open>auto simp: ph1\<close>) | |
| 1843 |     show "k(1, x) = h2 x" if "x \<in> {0..1}" for x
 | |
| 1844 | proof (rule covering_space_lift_unique [OF cov _ contg2 g2im]) | |
| 1845 | show "k (1,0) = h2 0" | |
| 1846 | by (metis atLeastAtMost_iff kh2 order_refl zero_le_one) | |
| 1847 |       show "continuous_on {0..1} (\<lambda>a. k (1, a))"
 | |
| 1848 | by (intro continuous_intros continuous_on_compose2 [OF contk]) auto | |
| 1849 |       show "\<And>x. x \<in> {0..1} \<Longrightarrow> g2 x = p (k (1, x))"
 | |
| 1850 | by (metis atLeastAtMost_iff h1 hpk mem_Sigma_iff order_refl zero_le_one) | |
| 1851 | qed (use conth2 h2im kim that in \<open>auto simp: ph2\<close>) | |
| 1852 |     show "\<And>t. t \<in> {0..1} \<Longrightarrow> (k \<circ> Pair t) 0 = h1 0"
 | |
| 1853 | by (metis comp_apply h1h2 kh2 pathstart_def) | |
| 1854 |     show "(k \<circ> Pair t) 1 = h1 1" if "t \<in> {0..1}" for t
 | |
| 1855 | proof (rule covering_space_lift_unique | |
| 1856 |            [OF cov, of "\<lambda>a. (k \<circ> Pair a) 1" 0 "\<lambda>a. h1 1" "{0..1}"  "\<lambda>x. g1 1"])
 | |
| 1857 | show "(k \<circ> Pair 0) 1 = h1 1" | |
| 1858 | using keqh1 by auto | |
| 1859 |       show "continuous_on {0..1} (\<lambda>a. (k \<circ> Pair a) 1)"
 | |
| 72496 | 1860 | by (auto intro!: continuous_intros continuous_on_compose2 [OF contk]) | 
| 64792 | 1861 |       show "\<And>x. x \<in> {0..1} \<Longrightarrow> g1 1 = p ((k \<circ> Pair x) 1)"
 | 
| 1862 | using heq1 hpk by auto | |
| 71172 | 1863 | qed (use contk kim g1im h1im that in \<open>auto simp: ph1\<close>) | 
| 64792 | 1864 | qed (use contk kim in auto) | 
| 1865 | qed | |
| 1866 | ||
| 1867 | ||
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1868 | corollary covering_space_monodromy: | 
| 64792 | 1869 | fixes p :: "'a::real_normed_vector \<Rightarrow> 'b::real_normed_vector" | 
| 1870 | assumes cov: "covering_space C p S" | |
| 1871 | and "path g1" and pig1: "path_image g1 \<subseteq> S" | |
| 1872 | and "path g2" and pig2: "path_image g2 \<subseteq> S" | |
| 1873 | and hom: "homotopic_paths S g1 g2" | |
| 1874 |       and "path h1" and pih1: "path_image h1 \<subseteq> C" and ph1: "\<And>t. t \<in> {0..1} \<Longrightarrow> p(h1 t) = g1 t"
 | |
| 1875 |       and "path h2" and pih2: "path_image h2 \<subseteq> C" and ph2: "\<And>t. t \<in> {0..1} \<Longrightarrow> p(h2 t) = g2 t"
 | |
| 1876 | and h1h2: "pathstart h1 = pathstart h2" | |
| 1877 | shows "pathfinish h1 = pathfinish h2" | |
| 70136 | 1878 | using covering_space_lift_homotopic_paths [OF assms] homotopic_paths_imp_pathfinish | 
| 1879 | by blast | |
| 64792 | 1880 | |
| 1881 | ||
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1882 | corollary covering_space_lift_homotopic_path: | 
| 64792 | 1883 | fixes p :: "'a::real_normed_vector \<Rightarrow> 'b::real_normed_vector" | 
| 1884 | assumes cov: "covering_space C p S" | |
| 1885 | and hom: "homotopic_paths S f f'" | |
| 1886 | and "path g" and pig: "path_image g \<subseteq> C" | |
| 1887 | and a: "pathstart g = a" and b: "pathfinish g = b" | |
| 1888 |       and pgeq: "\<And>t. t \<in> {0..1} \<Longrightarrow> p(g t) = f t"
 | |
| 1889 | obtains g' where "path g'" "path_image g' \<subseteq> C" | |
| 1890 |                    "pathstart g' = a" "pathfinish g' = b" "\<And>t. t \<in> {0..1} \<Longrightarrow> p(g' t) = f' t"
 | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1891 | proof (rule covering_space_lift_path_strong [OF cov, of a f']) | 
| 64792 | 1892 | show "a \<in> C" | 
| 1893 | using a pig by auto | |
| 1894 | show "path f'" "path_image f' \<subseteq> S" | |
| 1895 | using hom homotopic_paths_imp_path homotopic_paths_imp_subset by blast+ | |
| 1896 | show "pathstart f' = p a" | |
| 1897 | by (metis a atLeastAtMost_iff hom homotopic_paths_imp_pathstart order_refl pathstart_def pgeq zero_le_one) | |
| 1898 | qed (metis (mono_tags, lifting) assms cov covering_space_monodromy hom homotopic_paths_imp_path homotopic_paths_imp_subset pgeq pig) | |
| 1899 | ||
| 1900 | ||
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1901 | proposition covering_space_lift_general: | 
| 64792 | 1902 | fixes p :: "'a::real_normed_vector \<Rightarrow> 'b::real_normed_vector" | 
| 1903 | and f :: "'c::real_normed_vector \<Rightarrow> 'b" | |
| 1904 | assumes cov: "covering_space C p S" and "a \<in> C" "z \<in> U" | |
| 1905 | and U: "path_connected U" "locally path_connected U" | |
| 1906 | and contf: "continuous_on U f" and fim: "f ` U \<subseteq> S" | |
| 1907 | and feq: "f z = p a" | |
| 1908 | and hom: "\<And>r. \<lbrakk>path r; path_image r \<subseteq> U; pathstart r = z; pathfinish r = z\<rbrakk> | |
| 1909 | \<Longrightarrow> \<exists>q. path q \<and> path_image q \<subseteq> C \<and> | |
| 1910 | pathstart q = a \<and> pathfinish q = a \<and> | |
| 1911 | homotopic_paths S (f \<circ> r) (p \<circ> q)" | |
| 1912 | obtains g where "continuous_on U g" "g ` U \<subseteq> C" "g z = a" "\<And>y. y \<in> U \<Longrightarrow> p(g y) = f y" | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 1913 | proof - | 
| 64792 | 1914 | have *: "\<exists>g h. path g \<and> path_image g \<subseteq> U \<and> | 
| 1915 | pathstart g = z \<and> pathfinish g = y \<and> | |
| 1916 | path h \<and> path_image h \<subseteq> C \<and> pathstart h = a \<and> | |
| 1917 |                  (\<forall>t \<in> {0..1}. p(h t) = f(g t))"
 | |
| 1918 | if "y \<in> U" for y | |
| 1919 | proof - | |
| 1920 | obtain g where "path g" "path_image g \<subseteq> U" and pastg: "pathstart g = z" | |
| 1921 | and pafig: "pathfinish g = y" | |
| 1922 | using U \<open>z \<in> U\<close> \<open>y \<in> U\<close> by (force simp: path_connected_def) | |
| 1923 | obtain h where "path h" "path_image h \<subseteq> C" "pathstart h = a" | |
| 1924 |                and "\<And>t. t \<in> {0..1} \<Longrightarrow> p(h t) = (f \<circ> g) t"
 | |
| 1925 | proof (rule covering_space_lift_path_strong [OF cov \<open>a \<in> C\<close>]) | |
| 1926 | show "path (f \<circ> g)" | |
| 1927 | using \<open>path g\<close> \<open>path_image g \<subseteq> U\<close> contf continuous_on_subset path_continuous_image by blast | |
| 1928 | show "path_image (f \<circ> g) \<subseteq> S" | |
| 1929 | by (metis \<open>path_image g \<subseteq> U\<close> fim image_mono path_image_compose subset_trans) | |
| 1930 | show "pathstart (f \<circ> g) = p a" | |
| 1931 | by (simp add: feq pastg pathstart_compose) | |
| 1932 | qed auto | |
| 1933 | then show ?thesis | |
| 1934 | by (metis \<open>path g\<close> \<open>path_image g \<subseteq> U\<close> comp_apply pafig pastg) | |
| 1935 | qed | |
| 1936 | have "\<exists>l. \<forall>g h. path g \<and> path_image g \<subseteq> U \<and> pathstart g = z \<and> pathfinish g = y \<and> | |
| 1937 | path h \<and> path_image h \<subseteq> C \<and> pathstart h = a \<and> | |
| 1938 |                   (\<forall>t \<in> {0..1}. p(h t) = f(g t))  \<longrightarrow> pathfinish h = l" for y
 | |
| 1939 | proof - | |
| 1940 | have "pathfinish h = pathfinish h'" | |
| 1941 | if g: "path g" "path_image g \<subseteq> U" "pathstart g = z" "pathfinish g = y" | |
| 1942 | and h: "path h" "path_image h \<subseteq> C" "pathstart h = a" | |
| 1943 |             and phg: "\<And>t. t \<in> {0..1} \<Longrightarrow> p(h t) = f(g t)"
 | |
| 1944 | and g': "path g'" "path_image g' \<subseteq> U" "pathstart g' = z" "pathfinish g' = y" | |
| 1945 | and h': "path h'" "path_image h' \<subseteq> C" "pathstart h' = a" | |
| 1946 |             and phg': "\<And>t. t \<in> {0..1} \<Longrightarrow> p(h' t) = f(g' t)"
 | |
| 1947 | for g h g' h' | |
| 1948 | proof - | |
| 1949 | obtain q where "path q" and piq: "path_image q \<subseteq> C" and pastq: "pathstart q = a" and pafiq: "pathfinish q = a" | |
| 1950 | and homS: "homotopic_paths S (f \<circ> g +++ reversepath g') (p \<circ> q)" | |
| 1951 | using g g' hom [of "g +++ reversepath g'"] by (auto simp: subset_path_image_join) | |
| 1952 | have papq: "path (p \<circ> q)" | |
| 1953 | using homS homotopic_paths_imp_path by blast | |
| 1954 | have pipq: "path_image (p \<circ> q) \<subseteq> S" | |
| 1955 | using homS homotopic_paths_imp_subset by blast | |
| 1956 | obtain q' where "path q'" "path_image q' \<subseteq> C" | |
| 1957 | and "pathstart q' = pathstart q" "pathfinish q' = pathfinish q" | |
| 1958 |                 and pq'_eq: "\<And>t. t \<in> {0..1} \<Longrightarrow> p (q' t) = (f \<circ> g +++ reversepath g') t"
 | |
| 1959 | using covering_space_lift_homotopic_path [OF cov homotopic_paths_sym [OF homS] \<open>path q\<close> piq refl refl] | |
| 1960 | by auto | |
| 69064 
5840724b1d71
Prefix form of infix with * on either side no longer needs special treatment
 nipkow parents: 
68833diff
changeset | 1961 | have "q' t = (h \<circ> (*\<^sub>R) 2) t" if "0 \<le> t" "t \<le> 1/2" for t | 
| 
5840724b1d71
Prefix form of infix with * on either side no longer needs special treatment
 nipkow parents: 
68833diff
changeset | 1962 |       proof (rule covering_space_lift_unique [OF cov, of q' 0 "h \<circ> (*\<^sub>R) 2" "{0..1/2}" "f \<circ> g \<circ> (*\<^sub>R) 2" t])
 | 
| 
5840724b1d71
Prefix form of infix with * on either side no longer needs special treatment
 nipkow parents: 
68833diff
changeset | 1963 | show "q' 0 = (h \<circ> (*\<^sub>R) 2) 0" | 
| 71633 | 1964 | by (metis \<open>pathstart q' = pathstart q\<close> comp_def h(3) pastq pathstart_def pth_4(2)) | 
| 69064 
5840724b1d71
Prefix form of infix with * on either side no longer needs special treatment
 nipkow parents: 
68833diff
changeset | 1965 |         show "continuous_on {0..1/2} (f \<circ> g \<circ> (*\<^sub>R) 2)"
 | 
| 72496 | 1966 | proof (intro continuous_intros continuous_on_path [OF \<open>path g\<close>] continuous_on_subset [OF contf]) | 
| 1967 |           show "g ` (*\<^sub>R) 2 ` {0..1/2} \<subseteq> U"
 | |
| 1968 | using g path_image_def by fastforce | |
| 1969 | qed auto | |
| 69064 
5840724b1d71
Prefix form of infix with * on either side no longer needs special treatment
 nipkow parents: 
68833diff
changeset | 1970 |         show "(f \<circ> g \<circ> (*\<^sub>R) 2) ` {0..1/2} \<subseteq> S"
 | 
| 64792 | 1971 | using g(2) path_image_def fim by fastforce | 
| 69064 
5840724b1d71
Prefix form of infix with * on either side no longer needs special treatment
 nipkow parents: 
68833diff
changeset | 1972 |         show "(h \<circ> (*\<^sub>R) 2) ` {0..1/2} \<subseteq> C"
 | 
| 64792 | 1973 | using h path_image_def by fastforce | 
| 1974 |         show "q' ` {0..1/2} \<subseteq> C"
 | |
| 1975 | using \<open>path_image q' \<subseteq> C\<close> path_image_def by fastforce | |
| 69064 
5840724b1d71
Prefix form of infix with * on either side no longer needs special treatment
 nipkow parents: 
68833diff
changeset | 1976 |         show "\<And>x. x \<in> {0..1/2} \<Longrightarrow> (f \<circ> g \<circ> (*\<^sub>R) 2) x = p (q' x)"
 | 
| 64792 | 1977 | by (auto simp: joinpaths_def pq'_eq) | 
| 69064 
5840724b1d71
Prefix form of infix with * on either side no longer needs special treatment
 nipkow parents: 
68833diff
changeset | 1978 |         show "\<And>x. x \<in> {0..1/2} \<Longrightarrow> (f \<circ> g \<circ> (*\<^sub>R) 2) x = p ((h \<circ> (*\<^sub>R) 2) x)"
 | 
| 64792 | 1979 | by (simp add: phg) | 
| 1980 |         show "continuous_on {0..1/2} q'"
 | |
| 1981 | by (simp add: continuous_on_path \<open>path q'\<close>) | |
| 69064 
5840724b1d71
Prefix form of infix with * on either side no longer needs special treatment
 nipkow parents: 
68833diff
changeset | 1982 |         show "continuous_on {0..1/2} (h \<circ> (*\<^sub>R) 2)"
 | 
| 72496 | 1983 | by (intro continuous_intros continuous_on_path [OF \<open>path h\<close>]) auto | 
| 64792 | 1984 | qed (use that in auto) | 
| 1985 | moreover have "q' t = (reversepath h' \<circ> (\<lambda>t. 2 *\<^sub>R t - 1)) t" if "1/2 < t" "t \<le> 1" for t | |
| 1986 |       proof (rule covering_space_lift_unique [OF cov, of q' 1 "reversepath h' \<circ> (\<lambda>t. 2 *\<^sub>R t - 1)" "{1/2<..1}" "f \<circ> reversepath g' \<circ> (\<lambda>t. 2 *\<^sub>R t - 1)" t])
 | |
| 1987 | show "q' 1 = (reversepath h' \<circ> (\<lambda>t. 2 *\<^sub>R t - 1)) 1" | |
| 1988 | using h' \<open>pathfinish q' = pathfinish q\<close> pafiq | |
| 1989 | by (simp add: pathstart_def pathfinish_def reversepath_def) | |
| 1990 |         show "continuous_on {1/2<..1} (f \<circ> reversepath g' \<circ> (\<lambda>t. 2 *\<^sub>R t - 1))"
 | |
| 72496 | 1991 | proof (intro continuous_intros continuous_on_path \<open>path g'\<close> continuous_on_subset [OF contf]) | 
| 1992 |           show "reversepath g' ` (\<lambda>t. 2 *\<^sub>R t - 1) ` {1/2<..1} \<subseteq> U"
 | |
| 1993 | using g' by (auto simp: path_image_def reversepath_def) | |
| 1994 | qed (use g' in auto) | |
| 64792 | 1995 |         show "(f \<circ> reversepath g' \<circ> (\<lambda>t. 2 *\<^sub>R t - 1)) ` {1/2<..1} \<subseteq> S"
 | 
| 1996 | using g'(2) path_image_def fim by (auto simp: image_subset_iff path_image_def reversepath_def) | |
| 1997 |         show "q' ` {1/2<..1} \<subseteq> C"
 | |
| 1998 | using \<open>path_image q' \<subseteq> C\<close> path_image_def by fastforce | |
| 1999 |         show "(reversepath h' \<circ> (\<lambda>t. 2 *\<^sub>R t - 1)) ` {1/2<..1} \<subseteq> C"
 | |
| 2000 | using h' by (simp add: path_image_def reversepath_def subset_eq) | |
| 2001 |         show "\<And>x. x \<in> {1/2<..1} \<Longrightarrow> (f \<circ> reversepath g' \<circ> (\<lambda>t. 2 *\<^sub>R t - 1)) x = p (q' x)"
 | |
| 2002 | by (auto simp: joinpaths_def pq'_eq) | |
| 2003 |         show "\<And>x. x \<in> {1/2<..1} \<Longrightarrow>
 | |
| 2004 | (f \<circ> reversepath g' \<circ> (\<lambda>t. 2 *\<^sub>R t - 1)) x = p ((reversepath h' \<circ> (\<lambda>t. 2 *\<^sub>R t - 1)) x)" | |
| 2005 | by (simp add: phg' reversepath_def) | |
| 2006 |         show "continuous_on {1/2<..1} q'"
 | |
| 2007 | by (auto intro: continuous_on_path [OF \<open>path q'\<close>]) | |
| 2008 |         show "continuous_on {1/2<..1} (reversepath h' \<circ> (\<lambda>t. 2 *\<^sub>R t - 1))"
 | |
| 72496 | 2009 | by (intro continuous_intros continuous_on_path \<open>path h'\<close>) (use h' in auto) | 
| 64792 | 2010 | qed (use that in auto) | 
| 2011 | ultimately have "q' t = (h +++ reversepath h') t" if "0 \<le> t" "t \<le> 1" for t | |
| 2012 | using that by (simp add: joinpaths_def) | |
| 2013 | then have "path(h +++ reversepath h')" | |
| 2014 | by (auto intro: path_eq [OF \<open>path q'\<close>]) | |
| 2015 | then show ?thesis | |
| 2016 | by (auto simp: \<open>path h\<close> \<open>path h'\<close>) | |
| 2017 | qed | |
| 2018 | then show ?thesis by metis | |
| 2019 | qed | |
| 2020 | then obtain l :: "'c \<Rightarrow> 'a" | |
| 2021 | where l: "\<And>y g h. \<lbrakk>path g; path_image g \<subseteq> U; pathstart g = z; pathfinish g = y; | |
| 2022 | path h; path_image h \<subseteq> C; pathstart h = a; | |
| 2023 |                              \<And>t. t \<in> {0..1} \<Longrightarrow> p(h t) = f(g t)\<rbrakk> \<Longrightarrow> pathfinish h = l y"
 | |
| 2024 | by metis | |
| 2025 | show ?thesis | |
| 2026 | proof | |
| 2027 | show pleq: "p (l y) = f y" if "y \<in> U" for y | |
| 2028 | using*[OF \<open>y \<in> U\<close>] by (metis l atLeastAtMost_iff order_refl pathfinish_def zero_le_one) | |
| 2029 | show "l z = a" | |
| 2030 | using l [of "linepath z z" z "linepath a a"] by (auto simp: assms) | |
| 2031 | show LC: "l ` U \<subseteq> C" | |
| 2032 | by (clarify dest!: *) (metis (full_types) l pathfinish_in_path_image subsetCE) | |
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 2033 | have "\<exists>T. openin (top_of_set U) T \<and> y \<in> T \<and> T \<subseteq> U \<inter> l -` X" | 
| 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 2034 | if X: "openin (top_of_set C) X" and "y \<in> U" "l y \<in> X" for X y | 
| 64792 | 2035 | proof - | 
| 2036 | have "X \<subseteq> C" | |
| 2037 | using X openin_euclidean_subtopology_iff by blast | |
| 2038 | have "f y \<in> S" | |
| 2039 | using fim \<open>y \<in> U\<close> by blast | |
| 2040 | then obtain W \<V> | |
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 2041 | where WV: "f y \<in> W \<and> openin (top_of_set S) W \<and> | 
| 66884 
c2128ab11f61
Switching to inverse image and constant_on, plus some new material
 paulson <lp15@cam.ac.uk> parents: 
66827diff
changeset | 2042 | (\<Union>\<V> = C \<inter> p -` W \<and> | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 2043 | (\<forall>U \<in> \<V>. openin (top_of_set C) U) \<and> | 
| 64792 | 2044 | pairwise disjnt \<V> \<and> | 
| 2045 | (\<forall>U \<in> \<V>. \<exists>q. homeomorphism U W p q))" | |
| 2046 | using cov by (force simp: covering_space_def) | |
| 2047 | then have "l y \<in> \<Union>\<V>" | |
| 2048 | using \<open>X \<subseteq> C\<close> pleq that by auto | |
| 2049 | then obtain W' where "l y \<in> W'" and "W' \<in> \<V>" | |
| 2050 | by blast | |
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 2051 | with WV obtain p' where opeCW': "openin (top_of_set C) W'" | 
| 64792 | 2052 | and homUW': "homeomorphism W' W p p'" | 
| 2053 | by blast | |
| 2054 | then have contp': "continuous_on W p'" and p'im: "p' ` W \<subseteq> W'" | |
| 2055 | using homUW' homeomorphism_image2 homeomorphism_cont2 by fastforce+ | |
| 2056 | obtain V where "y \<in> V" "y \<in> U" and fimW: "f ` V \<subseteq> W" "V \<subseteq> U" | |
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 2057 | and "path_connected V" and opeUV: "openin (top_of_set U) V" | 
| 64792 | 2058 | proof - | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 2059 | have "openin (top_of_set U) (U \<inter> f -` W)" | 
| 64792 | 2060 | using WV contf continuous_on_open_gen fim by auto | 
| 72496 | 2061 | then obtain UO where "openin (top_of_set U) UO \<and> path_connected UO \<and> y \<in> UO \<and> UO \<subseteq> U \<inter> f -` W" | 
| 2062 | using U WV \<open>y \<in> U\<close> unfolding locally_path_connected by (meson IntI vimage_eq) | |
| 64792 | 2063 | then show ?thesis | 
| 72496 | 2064 | by (meson \<open>y \<in> U\<close> image_subset_iff_subset_vimage le_inf_iff that) | 
| 64792 | 2065 | qed | 
| 2066 | have "W' \<subseteq> C" "W \<subseteq> S" | |
| 2067 | using opeCW' WV openin_imp_subset by auto | |
| 2068 | have p'im: "p' ` W \<subseteq> W'" | |
| 2069 | using homUW' homeomorphism_image2 by fastforce | |
| 2070 | show ?thesis | |
| 2071 | proof (intro exI conjI) | |
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 2072 | have "openin (top_of_set S) (W \<inter> p' -` (W' \<inter> X))" | 
| 64792 | 2073 | proof (rule openin_trans) | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 2074 | show "openin (top_of_set W) (W \<inter> p' -` (W' \<inter> X))" | 
| 72496 | 2075 | using X \<open>W' \<subseteq> C\<close> by (intro continuous_openin_preimage [OF contp' p'im]) (auto simp: openin_open) | 
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 2076 | show "openin (top_of_set S) W" | 
| 64792 | 2077 | using WV by blast | 
| 2078 | qed | |
| 69922 
4a9167f377b0
new material about topology, etc.; also fixes for yesterday's
 paulson <lp15@cam.ac.uk> parents: 
69739diff
changeset | 2079 | then show "openin (top_of_set U) (V \<inter> (U \<inter> (f -` (W \<inter> (p' -` (W' \<inter> X))))))" | 
| 66884 
c2128ab11f61
Switching to inverse image and constant_on, plus some new material
 paulson <lp15@cam.ac.uk> parents: 
66827diff
changeset | 2080 | by (blast intro: opeUV openin_subtopology_self continuous_openin_preimage [OF contf fim]) | 
| 
c2128ab11f61
Switching to inverse image and constant_on, plus some new material
 paulson <lp15@cam.ac.uk> parents: 
66827diff
changeset | 2081 | have "p' (f y) \<in> X" | 
| 64792 | 2082 | using \<open>l y \<in> W'\<close> homeomorphism_apply1 [OF homUW'] pleq \<open>y \<in> U\<close> \<open>l y \<in> X\<close> by fastforce | 
| 66884 
c2128ab11f61
Switching to inverse image and constant_on, plus some new material
 paulson <lp15@cam.ac.uk> parents: 
66827diff
changeset | 2083 | then show "y \<in> V \<inter> (U \<inter> f -` (W \<inter> p' -` (W' \<inter> X)))" | 
| 64792 | 2084 | using \<open>y \<in> U\<close> \<open>y \<in> V\<close> WV p'im by auto | 
| 66884 
c2128ab11f61
Switching to inverse image and constant_on, plus some new material
 paulson <lp15@cam.ac.uk> parents: 
66827diff
changeset | 2085 | show "V \<inter> (U \<inter> f -` (W \<inter> p' -` (W' \<inter> X))) \<subseteq> U \<inter> l -` X" | 
| 
c2128ab11f61
Switching to inverse image and constant_on, plus some new material
 paulson <lp15@cam.ac.uk> parents: 
66827diff
changeset | 2086 | proof (intro subsetI IntI; clarify) | 
| 64792 | 2087 | fix y' | 
| 2088 | assume y': "y' \<in> V" "y' \<in> U" "f y' \<in> W" "p' (f y') \<in> W'" "p' (f y') \<in> X" | |
| 2089 | then obtain \<gamma> where "path \<gamma>" "path_image \<gamma> \<subseteq> V" "pathstart \<gamma> = y" "pathfinish \<gamma> = y'" | |
| 2090 | by (meson \<open>path_connected V\<close> \<open>y \<in> V\<close> path_connected_def) | |
| 72496 | 2091 | obtain pp qq where pp: "path pp" "path_image pp \<subseteq> U" "pathstart pp = z" "pathfinish pp = y" | 
| 2092 | and qq: "path qq" "path_image qq \<subseteq> C" "pathstart qq = a" | |
| 64792 | 2093 |                          and pqqeq: "\<And>t. t \<in> {0..1} \<Longrightarrow> p(qq t) = f(pp t)"
 | 
| 2094 | using*[OF \<open>y \<in> U\<close>] by blast | |
| 2095 | have finW: "\<And>x. \<lbrakk>0 \<le> x; x \<le> 1\<rbrakk> \<Longrightarrow> f (\<gamma> x) \<in> W" | |
| 2096 | using \<open>path_image \<gamma> \<subseteq> V\<close> by (auto simp: image_subset_iff path_image_def fimW [THEN subsetD]) | |
| 2097 | have "pathfinish (qq +++ (p' \<circ> f \<circ> \<gamma>)) = l y'" | |
| 66884 
c2128ab11f61
Switching to inverse image and constant_on, plus some new material
 paulson <lp15@cam.ac.uk> parents: 
66827diff
changeset | 2098 | proof (rule l [of "pp +++ \<gamma>" y' "qq +++ (p' \<circ> f \<circ> \<gamma>)"]) | 
| 64792 | 2099 | show "path (pp +++ \<gamma>)" | 
| 2100 | by (simp add: \<open>path \<gamma>\<close> \<open>path pp\<close> \<open>pathfinish pp = y\<close> \<open>pathstart \<gamma> = y\<close>) | |
| 2101 | show "path_image (pp +++ \<gamma>) \<subseteq> U" | |
| 2102 | using \<open>V \<subseteq> U\<close> \<open>path_image \<gamma> \<subseteq> V\<close> \<open>path_image pp \<subseteq> U\<close> not_in_path_image_join by blast | |
| 2103 | show "pathstart (pp +++ \<gamma>) = z" | |
| 2104 | by (simp add: \<open>pathstart pp = z\<close>) | |
| 2105 | show "pathfinish (pp +++ \<gamma>) = y'" | |
| 2106 | by (simp add: \<open>pathfinish \<gamma> = y'\<close>) | |
| 72496 | 2107 | have "pathfinish qq = l y" | 
| 2108 | using \<open>path pp\<close> \<open>path qq\<close> \<open>path_image pp \<subseteq> U\<close> \<open>path_image qq \<subseteq> C\<close> \<open>pathfinish pp = y\<close> \<open>pathstart pp = z\<close> \<open>pathstart qq = a\<close> l pqqeq by blast | |
| 2109 | also have "... = p' (f y)" | |
| 2110 | using \<open>l y \<in> W'\<close> homUW' homeomorphism_apply1 pleq that(2) by fastforce | |
| 2111 | finally have "pathfinish qq = p' (f y)" . | |
| 2112 | then have paqq: "pathfinish qq = pathstart (p' \<circ> f \<circ> \<gamma>)" | |
| 2113 | by (simp add: \<open>pathstart \<gamma> = y\<close> pathstart_compose) | |
| 64792 | 2114 | have "continuous_on (path_image \<gamma>) (p' \<circ> f)" | 
| 2115 | proof (rule continuous_on_compose) | |
| 2116 | show "continuous_on (path_image \<gamma>) f" | |
| 2117 | using \<open>path_image \<gamma> \<subseteq> V\<close> \<open>V \<subseteq> U\<close> contf continuous_on_subset by blast | |
| 2118 | show "continuous_on (f ` path_image \<gamma>) p'" | |
| 72496 | 2119 | proof (rule continuous_on_subset [OF contp']) | 
| 2120 | show "f ` path_image \<gamma> \<subseteq> W" | |
| 2121 | by (auto simp: path_image_def pathfinish_def pathstart_def finW) | |
| 2122 | qed | |
| 64792 | 2123 | qed | 
| 2124 | then show "path (qq +++ (p' \<circ> f \<circ> \<gamma>))" | |
| 2125 | using \<open>path \<gamma>\<close> \<open>path qq\<close> paqq path_continuous_image path_join_imp by blast | |
| 2126 | show "path_image (qq +++ (p' \<circ> f \<circ> \<gamma>)) \<subseteq> C" | |
| 72496 | 2127 | proof (rule subset_path_image_join) | 
| 2128 | show "path_image qq \<subseteq> C" | |
| 2129 | by (simp add: \<open>path_image qq \<subseteq> C\<close>) | |
| 2130 | show "path_image (p' \<circ> f \<circ> \<gamma>) \<subseteq> C" | |
| 2131 | by (metis \<open>W' \<subseteq> C\<close> \<open>path_image \<gamma> \<subseteq> V\<close> dual_order.trans fimW(1) image_comp image_mono p'im path_image_compose) | |
| 2132 | qed | |
| 64792 | 2133 | show "pathstart (qq +++ (p' \<circ> f \<circ> \<gamma>)) = a" | 
| 2134 | by (simp add: \<open>pathstart qq = a\<close>) | |
| 2135 |             show "p ((qq +++ (p' \<circ> f \<circ> \<gamma>)) \<xi>) = f ((pp +++ \<gamma>) \<xi>)" if \<xi>: "\<xi> \<in> {0..1}" for \<xi>
 | |
| 2136 | proof (simp add: joinpaths_def, safe) | |
| 2137 | show "p (qq (2*\<xi>)) = f (pp (2*\<xi>))" if "\<xi>*2 \<le> 1" | |
| 2138 |                 using \<open>\<xi> \<in> {0..1}\<close> pqqeq that by auto
 | |
| 2139 | show "p (p' (f (\<gamma> (2*\<xi> - 1)))) = f (\<gamma> (2*\<xi> - 1))" if "\<not> \<xi>*2 \<le> 1" | |
| 72496 | 2140 | using that \<xi> by (auto intro: homeomorphism_apply2 [OF homUW' finW]) | 
| 64792 | 2141 | qed | 
| 2142 | qed | |
| 66884 
c2128ab11f61
Switching to inverse image and constant_on, plus some new material
 paulson <lp15@cam.ac.uk> parents: 
66827diff
changeset | 2143 | with \<open>pathfinish \<gamma> = y'\<close> \<open>p' (f y') \<in> X\<close> show "y' \<in> l -` X" | 
| 64792 | 2144 | unfolding pathfinish_join by (simp add: pathfinish_def) | 
| 2145 | qed | |
| 2146 | qed | |
| 2147 | qed | |
| 2148 | then show "continuous_on U l" | |
| 66884 
c2128ab11f61
Switching to inverse image and constant_on, plus some new material
 paulson <lp15@cam.ac.uk> parents: 
66827diff
changeset | 2149 | by (metis IntD1 IntD2 vimage_eq openin_subopen continuous_on_open_gen [OF LC]) | 
| 64792 | 2150 | qed | 
| 2151 | qed | |
| 2152 | ||
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 2153 | corollary covering_space_lift_stronger: | 
| 64792 | 2154 | fixes p :: "'a::real_normed_vector \<Rightarrow> 'b::real_normed_vector" | 
| 2155 | and f :: "'c::real_normed_vector \<Rightarrow> 'b" | |
| 2156 | assumes cov: "covering_space C p S" "a \<in> C" "z \<in> U" | |
| 2157 | and U: "path_connected U" "locally path_connected U" | |
| 2158 | and contf: "continuous_on U f" and fim: "f ` U \<subseteq> S" | |
| 2159 | and feq: "f z = p a" | |
| 2160 | and hom: "\<And>r. \<lbrakk>path r; path_image r \<subseteq> U; pathstart r = z; pathfinish r = z\<rbrakk> | |
| 2161 | \<Longrightarrow> \<exists>b. homotopic_paths S (f \<circ> r) (linepath b b)" | |
| 2162 | obtains g where "continuous_on U g" "g ` U \<subseteq> C" "g z = a" "\<And>y. y \<in> U \<Longrightarrow> p(g y) = f y" | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 2163 | proof (rule covering_space_lift_general [OF cov U contf fim feq]) | 
| 64792 | 2164 | fix r | 
| 2165 | assume "path r" "path_image r \<subseteq> U" "pathstart r = z" "pathfinish r = z" | |
| 2166 | then obtain b where b: "homotopic_paths S (f \<circ> r) (linepath b b)" | |
| 2167 | using hom by blast | |
| 2168 | then have "f (pathstart r) = b" | |
| 2169 | by (metis homotopic_paths_imp_pathstart pathstart_compose pathstart_linepath) | |
| 2170 | then have "homotopic_paths S (f \<circ> r) (linepath (f z) (f z))" | |
| 2171 | by (simp add: b \<open>pathstart r = z\<close>) | |
| 2172 | then have "homotopic_paths S (f \<circ> r) (p \<circ> linepath a a)" | |
| 2173 | by (simp add: o_def feq linepath_def) | |
| 2174 | then show "\<exists>q. path q \<and> | |
| 2175 | path_image q \<subseteq> C \<and> | |
| 2176 | pathstart q = a \<and> pathfinish q = a \<and> homotopic_paths S (f \<circ> r) (p \<circ> q)" | |
| 2177 | by (force simp: \<open>a \<in> C\<close>) | |
| 2178 | qed auto | |
| 2179 | ||
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 2180 | corollary covering_space_lift_strong: | 
| 64792 | 2181 | fixes p :: "'a::real_normed_vector \<Rightarrow> 'b::real_normed_vector" | 
| 2182 | and f :: "'c::real_normed_vector \<Rightarrow> 'b" | |
| 2183 | assumes cov: "covering_space C p S" "a \<in> C" "z \<in> U" | |
| 2184 | and scU: "simply_connected U" and lpcU: "locally path_connected U" | |
| 2185 | and contf: "continuous_on U f" and fim: "f ` U \<subseteq> S" | |
| 2186 | and feq: "f z = p a" | |
| 2187 | obtains g where "continuous_on U g" "g ` U \<subseteq> C" "g z = a" "\<And>y. y \<in> U \<Longrightarrow> p(g y) = f y" | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 2188 | proof (rule covering_space_lift_stronger [OF cov _ lpcU contf fim feq]) | 
| 64792 | 2189 | show "path_connected U" | 
| 2190 | using scU simply_connected_eq_contractible_loop_some by blast | |
| 2191 | fix r | |
| 2192 | assume r: "path r" "path_image r \<subseteq> U" "pathstart r = z" "pathfinish r = z" | |
| 2193 | have "linepath (f z) (f z) = f \<circ> linepath z z" | |
| 2194 | by (simp add: o_def linepath_def) | |
| 2195 | then have "homotopic_paths S (f \<circ> r) (linepath (f z) (f z))" | |
| 2196 | by (metis r contf fim homotopic_paths_continuous_image scU simply_connected_eq_contractible_path) | |
| 2197 | then show "\<exists>b. homotopic_paths S (f \<circ> r) (linepath b b)" | |
| 2198 | by blast | |
| 2199 | qed blast | |
| 2200 | ||
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 2201 | corollary covering_space_lift: | 
| 64792 | 2202 | fixes p :: "'a::real_normed_vector \<Rightarrow> 'b::real_normed_vector" | 
| 2203 | and f :: "'c::real_normed_vector \<Rightarrow> 'b" | |
| 2204 | assumes cov: "covering_space C p S" | |
| 2205 | and U: "simply_connected U" "locally path_connected U" | |
| 2206 | and contf: "continuous_on U f" and fim: "f ` U \<subseteq> S" | |
| 2207 | obtains g where "continuous_on U g" "g ` U \<subseteq> C" "\<And>y. y \<in> U \<Longrightarrow> p(g y) = f y" | |
| 69681 
689997a8a582
redo tagging-related changes from a06b204527e6, 0f4d4a13dc16, and a8faf6f15da7
 immler parents: 
69680diff
changeset | 2208 | proof (cases "U = {}")
 | 
| 64792 | 2209 | case True | 
| 2210 | with that show ?thesis by auto | |
| 2211 | next | |
| 2212 | case False | |
| 2213 | then obtain z where "z \<in> U" by blast | |
| 2214 | then obtain a where "a \<in> C" "f z = p a" | |
| 2215 | by (metis cov covering_space_imp_surjective fim image_iff image_subset_iff) | |
| 2216 | then show ?thesis | |
| 2217 | by (metis that covering_space_lift_strong [OF cov _ \<open>z \<in> U\<close> U contf fim]) | |
| 2218 | qed | |
| 2219 | ||
| 71184 
d62fdaafdafc
renamed Analysis/Winding_Numbers to Winding_Numbers_2; reorganised Analysis/Cauchy_Integral_Theorem by splitting it into Contour_Integration, Winding_Numbers,Cauchy_Integral_Theorem and Cauchy_Integral_Formula.
 Wenda Li <wl302@cam.ac.uk> parents: 
71172diff
changeset | 2220 | subsection\<^marker>\<open>tag unimportant\<close> \<open>Homeomorphisms of arc images\<close> | 
| 
d62fdaafdafc
renamed Analysis/Winding_Numbers to Winding_Numbers_2; reorganised Analysis/Cauchy_Integral_Theorem by splitting it into Contour_Integration, Winding_Numbers,Cauchy_Integral_Theorem and Cauchy_Integral_Formula.
 Wenda Li <wl302@cam.ac.uk> parents: 
71172diff
changeset | 2221 | |
| 
d62fdaafdafc
renamed Analysis/Winding_Numbers to Winding_Numbers_2; reorganised Analysis/Cauchy_Integral_Theorem by splitting it into Contour_Integration, Winding_Numbers,Cauchy_Integral_Theorem and Cauchy_Integral_Formula.
 Wenda Li <wl302@cam.ac.uk> parents: 
71172diff
changeset | 2222 | lemma homeomorphism_arc: | 
| 
d62fdaafdafc
renamed Analysis/Winding_Numbers to Winding_Numbers_2; reorganised Analysis/Cauchy_Integral_Theorem by splitting it into Contour_Integration, Winding_Numbers,Cauchy_Integral_Theorem and Cauchy_Integral_Formula.
 Wenda Li <wl302@cam.ac.uk> parents: 
71172diff
changeset | 2223 | fixes g :: "real \<Rightarrow> 'a::t2_space" | 
| 
d62fdaafdafc
renamed Analysis/Winding_Numbers to Winding_Numbers_2; reorganised Analysis/Cauchy_Integral_Theorem by splitting it into Contour_Integration, Winding_Numbers,Cauchy_Integral_Theorem and Cauchy_Integral_Formula.
 Wenda Li <wl302@cam.ac.uk> parents: 
71172diff
changeset | 2224 | assumes "arc g" | 
| 
d62fdaafdafc
renamed Analysis/Winding_Numbers to Winding_Numbers_2; reorganised Analysis/Cauchy_Integral_Theorem by splitting it into Contour_Integration, Winding_Numbers,Cauchy_Integral_Theorem and Cauchy_Integral_Formula.
 Wenda Li <wl302@cam.ac.uk> parents: 
71172diff
changeset | 2225 |   obtains h where "homeomorphism {0..1} (path_image g) g h"
 | 
| 
d62fdaafdafc
renamed Analysis/Winding_Numbers to Winding_Numbers_2; reorganised Analysis/Cauchy_Integral_Theorem by splitting it into Contour_Integration, Winding_Numbers,Cauchy_Integral_Theorem and Cauchy_Integral_Formula.
 Wenda Li <wl302@cam.ac.uk> parents: 
71172diff
changeset | 2226 | using assms by (force simp: arc_def homeomorphism_compact path_def path_image_def) | 
| 
d62fdaafdafc
renamed Analysis/Winding_Numbers to Winding_Numbers_2; reorganised Analysis/Cauchy_Integral_Theorem by splitting it into Contour_Integration, Winding_Numbers,Cauchy_Integral_Theorem and Cauchy_Integral_Formula.
 Wenda Li <wl302@cam.ac.uk> parents: 
71172diff
changeset | 2227 | |
| 
d62fdaafdafc
renamed Analysis/Winding_Numbers to Winding_Numbers_2; reorganised Analysis/Cauchy_Integral_Theorem by splitting it into Contour_Integration, Winding_Numbers,Cauchy_Integral_Theorem and Cauchy_Integral_Formula.
 Wenda Li <wl302@cam.ac.uk> parents: 
71172diff
changeset | 2228 | lemma homeomorphic_arc_image_interval: | 
| 
d62fdaafdafc
renamed Analysis/Winding_Numbers to Winding_Numbers_2; reorganised Analysis/Cauchy_Integral_Theorem by splitting it into Contour_Integration, Winding_Numbers,Cauchy_Integral_Theorem and Cauchy_Integral_Formula.
 Wenda Li <wl302@cam.ac.uk> parents: 
71172diff
changeset | 2229 | fixes g :: "real \<Rightarrow> 'a::t2_space" and a::real | 
| 
d62fdaafdafc
renamed Analysis/Winding_Numbers to Winding_Numbers_2; reorganised Analysis/Cauchy_Integral_Theorem by splitting it into Contour_Integration, Winding_Numbers,Cauchy_Integral_Theorem and Cauchy_Integral_Formula.
 Wenda Li <wl302@cam.ac.uk> parents: 
71172diff
changeset | 2230 | assumes "arc g" "a < b" | 
| 
d62fdaafdafc
renamed Analysis/Winding_Numbers to Winding_Numbers_2; reorganised Analysis/Cauchy_Integral_Theorem by splitting it into Contour_Integration, Winding_Numbers,Cauchy_Integral_Theorem and Cauchy_Integral_Formula.
 Wenda Li <wl302@cam.ac.uk> parents: 
71172diff
changeset | 2231 |   shows "(path_image g) homeomorphic {a..b}"
 | 
| 
d62fdaafdafc
renamed Analysis/Winding_Numbers to Winding_Numbers_2; reorganised Analysis/Cauchy_Integral_Theorem by splitting it into Contour_Integration, Winding_Numbers,Cauchy_Integral_Theorem and Cauchy_Integral_Formula.
 Wenda Li <wl302@cam.ac.uk> parents: 
71172diff
changeset | 2232 | proof - | 
| 
d62fdaafdafc
renamed Analysis/Winding_Numbers to Winding_Numbers_2; reorganised Analysis/Cauchy_Integral_Theorem by splitting it into Contour_Integration, Winding_Numbers,Cauchy_Integral_Theorem and Cauchy_Integral_Formula.
 Wenda Li <wl302@cam.ac.uk> parents: 
71172diff
changeset | 2233 |   have "(path_image g) homeomorphic {0..1::real}"
 | 
| 
d62fdaafdafc
renamed Analysis/Winding_Numbers to Winding_Numbers_2; reorganised Analysis/Cauchy_Integral_Theorem by splitting it into Contour_Integration, Winding_Numbers,Cauchy_Integral_Theorem and Cauchy_Integral_Formula.
 Wenda Li <wl302@cam.ac.uk> parents: 
71172diff
changeset | 2234 | by (meson assms(1) homeomorphic_def homeomorphic_sym homeomorphism_arc) | 
| 
d62fdaafdafc
renamed Analysis/Winding_Numbers to Winding_Numbers_2; reorganised Analysis/Cauchy_Integral_Theorem by splitting it into Contour_Integration, Winding_Numbers,Cauchy_Integral_Theorem and Cauchy_Integral_Formula.
 Wenda Li <wl302@cam.ac.uk> parents: 
71172diff
changeset | 2235 |   also have "\<dots> homeomorphic {a..b}"
 | 
| 
d62fdaafdafc
renamed Analysis/Winding_Numbers to Winding_Numbers_2; reorganised Analysis/Cauchy_Integral_Theorem by splitting it into Contour_Integration, Winding_Numbers,Cauchy_Integral_Theorem and Cauchy_Integral_Formula.
 Wenda Li <wl302@cam.ac.uk> parents: 
71172diff
changeset | 2236 | using assms by (force intro: homeomorphic_closed_intervals_real) | 
| 
d62fdaafdafc
renamed Analysis/Winding_Numbers to Winding_Numbers_2; reorganised Analysis/Cauchy_Integral_Theorem by splitting it into Contour_Integration, Winding_Numbers,Cauchy_Integral_Theorem and Cauchy_Integral_Formula.
 Wenda Li <wl302@cam.ac.uk> parents: 
71172diff
changeset | 2237 | finally show ?thesis . | 
| 
d62fdaafdafc
renamed Analysis/Winding_Numbers to Winding_Numbers_2; reorganised Analysis/Cauchy_Integral_Theorem by splitting it into Contour_Integration, Winding_Numbers,Cauchy_Integral_Theorem and Cauchy_Integral_Formula.
 Wenda Li <wl302@cam.ac.uk> parents: 
71172diff
changeset | 2238 | qed | 
| 
d62fdaafdafc
renamed Analysis/Winding_Numbers to Winding_Numbers_2; reorganised Analysis/Cauchy_Integral_Theorem by splitting it into Contour_Integration, Winding_Numbers,Cauchy_Integral_Theorem and Cauchy_Integral_Formula.
 Wenda Li <wl302@cam.ac.uk> parents: 
71172diff
changeset | 2239 | |
| 
d62fdaafdafc
renamed Analysis/Winding_Numbers to Winding_Numbers_2; reorganised Analysis/Cauchy_Integral_Theorem by splitting it into Contour_Integration, Winding_Numbers,Cauchy_Integral_Theorem and Cauchy_Integral_Formula.
 Wenda Li <wl302@cam.ac.uk> parents: 
71172diff
changeset | 2240 | lemma homeomorphic_arc_images: | 
| 
d62fdaafdafc
renamed Analysis/Winding_Numbers to Winding_Numbers_2; reorganised Analysis/Cauchy_Integral_Theorem by splitting it into Contour_Integration, Winding_Numbers,Cauchy_Integral_Theorem and Cauchy_Integral_Formula.
 Wenda Li <wl302@cam.ac.uk> parents: 
71172diff
changeset | 2241 | fixes g :: "real \<Rightarrow> 'a::t2_space" and h :: "real \<Rightarrow> 'b::t2_space" | 
| 
d62fdaafdafc
renamed Analysis/Winding_Numbers to Winding_Numbers_2; reorganised Analysis/Cauchy_Integral_Theorem by splitting it into Contour_Integration, Winding_Numbers,Cauchy_Integral_Theorem and Cauchy_Integral_Formula.
 Wenda Li <wl302@cam.ac.uk> parents: 
71172diff
changeset | 2242 | assumes "arc g" "arc h" | 
| 
d62fdaafdafc
renamed Analysis/Winding_Numbers to Winding_Numbers_2; reorganised Analysis/Cauchy_Integral_Theorem by splitting it into Contour_Integration, Winding_Numbers,Cauchy_Integral_Theorem and Cauchy_Integral_Formula.
 Wenda Li <wl302@cam.ac.uk> parents: 
71172diff
changeset | 2243 | shows "(path_image g) homeomorphic (path_image h)" | 
| 
d62fdaafdafc
renamed Analysis/Winding_Numbers to Winding_Numbers_2; reorganised Analysis/Cauchy_Integral_Theorem by splitting it into Contour_Integration, Winding_Numbers,Cauchy_Integral_Theorem and Cauchy_Integral_Formula.
 Wenda Li <wl302@cam.ac.uk> parents: 
71172diff
changeset | 2244 | proof - | 
| 
d62fdaafdafc
renamed Analysis/Winding_Numbers to Winding_Numbers_2; reorganised Analysis/Cauchy_Integral_Theorem by splitting it into Contour_Integration, Winding_Numbers,Cauchy_Integral_Theorem and Cauchy_Integral_Formula.
 Wenda Li <wl302@cam.ac.uk> parents: 
71172diff
changeset | 2245 |   have "(path_image g) homeomorphic {0..1::real}"
 | 
| 
d62fdaafdafc
renamed Analysis/Winding_Numbers to Winding_Numbers_2; reorganised Analysis/Cauchy_Integral_Theorem by splitting it into Contour_Integration, Winding_Numbers,Cauchy_Integral_Theorem and Cauchy_Integral_Formula.
 Wenda Li <wl302@cam.ac.uk> parents: 
71172diff
changeset | 2246 | by (meson assms homeomorphic_def homeomorphic_sym homeomorphism_arc) | 
| 
d62fdaafdafc
renamed Analysis/Winding_Numbers to Winding_Numbers_2; reorganised Analysis/Cauchy_Integral_Theorem by splitting it into Contour_Integration, Winding_Numbers,Cauchy_Integral_Theorem and Cauchy_Integral_Formula.
 Wenda Li <wl302@cam.ac.uk> parents: 
71172diff
changeset | 2247 | also have "\<dots> homeomorphic (path_image h)" | 
| 
d62fdaafdafc
renamed Analysis/Winding_Numbers to Winding_Numbers_2; reorganised Analysis/Cauchy_Integral_Theorem by splitting it into Contour_Integration, Winding_Numbers,Cauchy_Integral_Theorem and Cauchy_Integral_Formula.
 Wenda Li <wl302@cam.ac.uk> parents: 
71172diff
changeset | 2248 | by (meson assms homeomorphic_def homeomorphism_arc) | 
| 
d62fdaafdafc
renamed Analysis/Winding_Numbers to Winding_Numbers_2; reorganised Analysis/Cauchy_Integral_Theorem by splitting it into Contour_Integration, Winding_Numbers,Cauchy_Integral_Theorem and Cauchy_Integral_Formula.
 Wenda Li <wl302@cam.ac.uk> parents: 
71172diff
changeset | 2249 | finally show ?thesis . | 
| 
d62fdaafdafc
renamed Analysis/Winding_Numbers to Winding_Numbers_2; reorganised Analysis/Cauchy_Integral_Theorem by splitting it into Contour_Integration, Winding_Numbers,Cauchy_Integral_Theorem and Cauchy_Integral_Formula.
 Wenda Li <wl302@cam.ac.uk> parents: 
71172diff
changeset | 2250 | qed | 
| 
d62fdaafdafc
renamed Analysis/Winding_Numbers to Winding_Numbers_2; reorganised Analysis/Cauchy_Integral_Theorem by splitting it into Contour_Integration, Winding_Numbers,Cauchy_Integral_Theorem and Cauchy_Integral_Formula.
 Wenda Li <wl302@cam.ac.uk> parents: 
71172diff
changeset | 2251 | |
| 63130 | 2252 | end |