author | wenzelm |
Thu, 22 Oct 2015 21:34:28 +0200 | |
changeset 61504 | a7ae3ef886a9 |
parent 61426 | d53db136e8fd |
child 61518 | ff12606337e9 |
permissions | -rw-r--r-- |
41959 | 1 |
(* Title: HOL/Multivariate_Analysis/Path_Connected.thy |
60303 | 2 |
Author: Robert Himmelmann, TU Muenchen, and LCP with material from HOL Light |
36583 | 3 |
*) |
4 |
||
60420 | 5 |
section \<open>Continuous paths and path-connected sets\<close> |
36583 | 6 |
|
7 |
theory Path_Connected |
|
37674
f86de9c00c47
convert theorem path_connected_sphere to euclidean_space class
huffman
parents:
37489
diff
changeset
|
8 |
imports Convex_Euclidean_Space |
36583 | 9 |
begin |
10 |
||
60303 | 11 |
(*FIXME move up?*) |
12 |
lemma image_affinity_interval: |
|
13 |
fixes c :: "'a::ordered_real_vector" |
|
14 |
shows "((\<lambda>x. m *\<^sub>R x + c) ` {a..b}) = (if {a..b}={} then {} |
|
15 |
else if 0 <= m then {m *\<^sub>R a + c .. m *\<^sub>R b + c} |
|
16 |
else {m *\<^sub>R b + c .. m *\<^sub>R a + c})" |
|
17 |
apply (case_tac "m=0", force) |
|
18 |
apply (auto simp: scaleR_left_mono) |
|
19 |
apply (rule_tac x="inverse m *\<^sub>R (x-c)" in rev_image_eqI, auto simp: pos_le_divideR_eq le_diff_eq scaleR_left_mono_neg) |
|
20 |
apply (metis diff_le_eq inverse_inverse_eq order.not_eq_order_implies_strict pos_le_divideR_eq positive_imp_inverse_positive) |
|
21 |
apply (rule_tac x="inverse m *\<^sub>R (x-c)" in rev_image_eqI, auto simp: not_le neg_le_divideR_eq diff_le_eq) |
|
60809
457abb82fb9e
the Cauchy integral theorem and related material
paulson <lp15@cam.ac.uk>
parents:
60420
diff
changeset
|
22 |
using le_diff_eq scaleR_le_cancel_left_neg |
60303 | 23 |
apply fastforce |
24 |
done |
|
25 |
||
60420 | 26 |
subsection \<open>Paths and Arcs\<close> |
36583 | 27 |
|
49653 | 28 |
definition path :: "(real \<Rightarrow> 'a::topological_space) \<Rightarrow> bool" |
53640 | 29 |
where "path g \<longleftrightarrow> continuous_on {0..1} g" |
36583 | 30 |
|
49653 | 31 |
definition pathstart :: "(real \<Rightarrow> 'a::topological_space) \<Rightarrow> 'a" |
36583 | 32 |
where "pathstart g = g 0" |
33 |
||
49653 | 34 |
definition pathfinish :: "(real \<Rightarrow> 'a::topological_space) \<Rightarrow> 'a" |
36583 | 35 |
where "pathfinish g = g 1" |
36 |
||
49653 | 37 |
definition path_image :: "(real \<Rightarrow> 'a::topological_space) \<Rightarrow> 'a set" |
36583 | 38 |
where "path_image g = g ` {0 .. 1}" |
39 |
||
53640 | 40 |
definition reversepath :: "(real \<Rightarrow> 'a::topological_space) \<Rightarrow> real \<Rightarrow> 'a" |
36583 | 41 |
where "reversepath g = (\<lambda>x. g(1 - x))" |
42 |
||
53640 | 43 |
definition joinpaths :: "(real \<Rightarrow> 'a::topological_space) \<Rightarrow> (real \<Rightarrow> 'a) \<Rightarrow> real \<Rightarrow> 'a" |
36583 | 44 |
(infixr "+++" 75) |
45 |
where "g1 +++ g2 = (\<lambda>x. if x \<le> 1/2 then g1 (2 * x) else g2 (2 * x - 1))" |
|
46 |
||
49653 | 47 |
definition simple_path :: "(real \<Rightarrow> 'a::topological_space) \<Rightarrow> bool" |
36583 | 48 |
where "simple_path g \<longleftrightarrow> |
60303 | 49 |
path g \<and> (\<forall>x\<in>{0..1}. \<forall>y\<in>{0..1}. g x = g y \<longrightarrow> x = y \<or> x = 0 \<and> y = 1 \<or> x = 1 \<and> y = 0)" |
36583 | 50 |
|
60303 | 51 |
definition arc :: "(real \<Rightarrow> 'a :: topological_space) \<Rightarrow> bool" |
52 |
where "arc g \<longleftrightarrow> path g \<and> inj_on g {0..1}" |
|
36583 | 53 |
|
49653 | 54 |
|
60420 | 55 |
subsection\<open>Invariance theorems\<close> |
60303 | 56 |
|
57 |
lemma path_eq: "path p \<Longrightarrow> (\<And>t. t \<in> {0..1} \<Longrightarrow> p t = q t) \<Longrightarrow> path q" |
|
58 |
using continuous_on_eq path_def by blast |
|
59 |
||
60 |
lemma path_continuous_image: "path g \<Longrightarrow> continuous_on (path_image g) f \<Longrightarrow> path(f o g)" |
|
61 |
unfolding path_def path_image_def |
|
62 |
using continuous_on_compose by blast |
|
63 |
||
64 |
lemma path_translation_eq: |
|
65 |
fixes g :: "real \<Rightarrow> 'a :: real_normed_vector" |
|
66 |
shows "path((\<lambda>x. a + x) o g) = path g" |
|
67 |
proof - |
|
68 |
have g: "g = (\<lambda>x. -a + x) o ((\<lambda>x. a + x) o g)" |
|
69 |
by (rule ext) simp |
|
70 |
show ?thesis |
|
71 |
unfolding path_def |
|
72 |
apply safe |
|
73 |
apply (subst g) |
|
74 |
apply (rule continuous_on_compose) |
|
75 |
apply (auto intro: continuous_intros) |
|
76 |
done |
|
77 |
qed |
|
78 |
||
79 |
lemma path_linear_image_eq: |
|
80 |
fixes f :: "'a::euclidean_space \<Rightarrow> 'b::euclidean_space" |
|
81 |
assumes "linear f" "inj f" |
|
82 |
shows "path(f o g) = path g" |
|
83 |
proof - |
|
84 |
from linear_injective_left_inverse [OF assms] |
|
85 |
obtain h where h: "linear h" "h \<circ> f = id" |
|
86 |
by blast |
|
87 |
then have g: "g = h o (f o g)" |
|
88 |
by (metis comp_assoc id_comp) |
|
89 |
show ?thesis |
|
90 |
unfolding path_def |
|
91 |
using h assms |
|
92 |
by (metis g continuous_on_compose linear_continuous_on linear_conv_bounded_linear) |
|
93 |
qed |
|
94 |
||
95 |
lemma pathstart_translation: "pathstart((\<lambda>x. a + x) o g) = a + pathstart g" |
|
96 |
by (simp add: pathstart_def) |
|
97 |
||
98 |
lemma pathstart_linear_image_eq: "linear f \<Longrightarrow> pathstart(f o g) = f(pathstart g)" |
|
99 |
by (simp add: pathstart_def) |
|
100 |
||
101 |
lemma pathfinish_translation: "pathfinish((\<lambda>x. a + x) o g) = a + pathfinish g" |
|
102 |
by (simp add: pathfinish_def) |
|
103 |
||
104 |
lemma pathfinish_linear_image: "linear f \<Longrightarrow> pathfinish(f o g) = f(pathfinish g)" |
|
105 |
by (simp add: pathfinish_def) |
|
106 |
||
107 |
lemma path_image_translation: "path_image((\<lambda>x. a + x) o g) = (\<lambda>x. a + x) ` (path_image g)" |
|
108 |
by (simp add: image_comp path_image_def) |
|
109 |
||
110 |
lemma path_image_linear_image: "linear f \<Longrightarrow> path_image(f o g) = f ` (path_image g)" |
|
111 |
by (simp add: image_comp path_image_def) |
|
112 |
||
113 |
lemma reversepath_translation: "reversepath((\<lambda>x. a + x) o g) = (\<lambda>x. a + x) o reversepath g" |
|
114 |
by (rule ext) (simp add: reversepath_def) |
|
36583 | 115 |
|
60303 | 116 |
lemma reversepath_linear_image: "linear f \<Longrightarrow> reversepath(f o g) = f o reversepath g" |
117 |
by (rule ext) (simp add: reversepath_def) |
|
118 |
||
119 |
lemma joinpaths_translation: |
|
120 |
"((\<lambda>x. a + x) o g1) +++ ((\<lambda>x. a + x) o g2) = (\<lambda>x. a + x) o (g1 +++ g2)" |
|
121 |
by (rule ext) (simp add: joinpaths_def) |
|
122 |
||
123 |
lemma joinpaths_linear_image: "linear f \<Longrightarrow> (f o g1) +++ (f o g2) = f o (g1 +++ g2)" |
|
124 |
by (rule ext) (simp add: joinpaths_def) |
|
125 |
||
60809
457abb82fb9e
the Cauchy integral theorem and related material
paulson <lp15@cam.ac.uk>
parents:
60420
diff
changeset
|
126 |
lemma simple_path_translation_eq: |
60303 | 127 |
fixes g :: "real \<Rightarrow> 'a::euclidean_space" |
128 |
shows "simple_path((\<lambda>x. a + x) o g) = simple_path g" |
|
129 |
by (simp add: simple_path_def path_translation_eq) |
|
130 |
||
131 |
lemma simple_path_linear_image_eq: |
|
132 |
fixes f :: "'a::euclidean_space \<Rightarrow> 'b::euclidean_space" |
|
133 |
assumes "linear f" "inj f" |
|
134 |
shows "simple_path(f o g) = simple_path g" |
|
135 |
using assms inj_on_eq_iff [of f] |
|
136 |
by (auto simp: path_linear_image_eq simple_path_def path_translation_eq) |
|
137 |
||
138 |
lemma arc_translation_eq: |
|
139 |
fixes g :: "real \<Rightarrow> 'a::euclidean_space" |
|
140 |
shows "arc((\<lambda>x. a + x) o g) = arc g" |
|
141 |
by (auto simp: arc_def inj_on_def path_translation_eq) |
|
142 |
||
143 |
lemma arc_linear_image_eq: |
|
144 |
fixes f :: "'a::euclidean_space \<Rightarrow> 'b::euclidean_space" |
|
145 |
assumes "linear f" "inj f" |
|
146 |
shows "arc(f o g) = arc g" |
|
147 |
using assms inj_on_eq_iff [of f] |
|
148 |
by (auto simp: arc_def inj_on_def path_linear_image_eq) |
|
149 |
||
60420 | 150 |
subsection\<open>Basic lemmas about paths\<close> |
60303 | 151 |
|
152 |
lemma arc_imp_simple_path: "arc g \<Longrightarrow> simple_path g" |
|
153 |
by (simp add: arc_def inj_on_def simple_path_def) |
|
154 |
||
155 |
lemma arc_imp_path: "arc g \<Longrightarrow> path g" |
|
156 |
using arc_def by blast |
|
157 |
||
158 |
lemma simple_path_imp_path: "simple_path g \<Longrightarrow> path g" |
|
159 |
using simple_path_def by blast |
|
160 |
||
161 |
lemma simple_path_cases: "simple_path g \<Longrightarrow> arc g \<or> pathfinish g = pathstart g" |
|
162 |
unfolding simple_path_def arc_def inj_on_def pathfinish_def pathstart_def |
|
163 |
by (force) |
|
164 |
||
165 |
lemma simple_path_imp_arc: "simple_path g \<Longrightarrow> pathfinish g \<noteq> pathstart g \<Longrightarrow> arc g" |
|
166 |
using simple_path_cases by auto |
|
167 |
||
168 |
lemma arc_distinct_ends: "arc g \<Longrightarrow> pathfinish g \<noteq> pathstart g" |
|
169 |
unfolding arc_def inj_on_def pathfinish_def pathstart_def |
|
170 |
by fastforce |
|
171 |
||
172 |
lemma arc_simple_path: "arc g \<longleftrightarrow> simple_path g \<and> pathfinish g \<noteq> pathstart g" |
|
173 |
using arc_distinct_ends arc_imp_simple_path simple_path_cases by blast |
|
174 |
||
175 |
lemma simple_path_eq_arc: "pathfinish g \<noteq> pathstart g \<Longrightarrow> (simple_path g = arc g)" |
|
176 |
by (simp add: arc_simple_path) |
|
36583 | 177 |
|
60974
6a6f15d8fbc4
New material and fixes related to the forthcoming Stone-Weierstrass development
paulson <lp15@cam.ac.uk>
parents:
60809
diff
changeset
|
178 |
lemma path_image_nonempty [simp]: "path_image g \<noteq> {}" |
56188 | 179 |
unfolding path_image_def image_is_empty box_eq_empty |
53640 | 180 |
by auto |
36583 | 181 |
|
53640 | 182 |
lemma pathstart_in_path_image[intro]: "pathstart g \<in> path_image g" |
183 |
unfolding pathstart_def path_image_def |
|
184 |
by auto |
|
36583 | 185 |
|
53640 | 186 |
lemma pathfinish_in_path_image[intro]: "pathfinish g \<in> path_image g" |
187 |
unfolding pathfinish_def path_image_def |
|
188 |
by auto |
|
189 |
||
190 |
lemma connected_path_image[intro]: "path g \<Longrightarrow> connected (path_image g)" |
|
36583 | 191 |
unfolding path_def path_image_def |
60303 | 192 |
using connected_continuous_image connected_Icc by blast |
36583 | 193 |
|
53640 | 194 |
lemma compact_path_image[intro]: "path g \<Longrightarrow> compact (path_image g)" |
36583 | 195 |
unfolding path_def path_image_def |
60303 | 196 |
using compact_continuous_image connected_Icc by blast |
36583 | 197 |
|
53640 | 198 |
lemma reversepath_reversepath[simp]: "reversepath (reversepath g) = g" |
199 |
unfolding reversepath_def |
|
200 |
by auto |
|
36583 | 201 |
|
53640 | 202 |
lemma pathstart_reversepath[simp]: "pathstart (reversepath g) = pathfinish g" |
203 |
unfolding pathstart_def reversepath_def pathfinish_def |
|
204 |
by auto |
|
36583 | 205 |
|
53640 | 206 |
lemma pathfinish_reversepath[simp]: "pathfinish (reversepath g) = pathstart g" |
207 |
unfolding pathstart_def reversepath_def pathfinish_def |
|
208 |
by auto |
|
36583 | 209 |
|
49653 | 210 |
lemma pathstart_join[simp]: "pathstart (g1 +++ g2) = pathstart g1" |
53640 | 211 |
unfolding pathstart_def joinpaths_def pathfinish_def |
212 |
by auto |
|
36583 | 213 |
|
49653 | 214 |
lemma pathfinish_join[simp]: "pathfinish (g1 +++ g2) = pathfinish g2" |
53640 | 215 |
unfolding pathstart_def joinpaths_def pathfinish_def |
216 |
by auto |
|
36583 | 217 |
|
53640 | 218 |
lemma path_image_reversepath[simp]: "path_image (reversepath g) = path_image g" |
49653 | 219 |
proof - |
53640 | 220 |
have *: "\<And>g. path_image (reversepath g) \<subseteq> path_image g" |
49653 | 221 |
unfolding path_image_def subset_eq reversepath_def Ball_def image_iff |
60303 | 222 |
by force |
49653 | 223 |
show ?thesis |
224 |
using *[of g] *[of "reversepath g"] |
|
53640 | 225 |
unfolding reversepath_reversepath |
226 |
by auto |
|
49653 | 227 |
qed |
36583 | 228 |
|
53640 | 229 |
lemma path_reversepath [simp]: "path (reversepath g) \<longleftrightarrow> path g" |
49653 | 230 |
proof - |
231 |
have *: "\<And>g. path g \<Longrightarrow> path (reversepath g)" |
|
232 |
unfolding path_def reversepath_def |
|
233 |
apply (rule continuous_on_compose[unfolded o_def, of _ "\<lambda>x. 1 - x"]) |
|
56371
fb9ae0727548
extend continuous_intros; remove continuous_on_intros and isCont_intros
hoelzl
parents:
56188
diff
changeset
|
234 |
apply (intro continuous_intros) |
53640 | 235 |
apply (rule continuous_on_subset[of "{0..1}"]) |
236 |
apply assumption |
|
49653 | 237 |
apply auto |
238 |
done |
|
239 |
show ?thesis |
|
240 |
using *[of "reversepath g"] *[of g] |
|
241 |
unfolding reversepath_reversepath |
|
242 |
by (rule iffI) |
|
243 |
qed |
|
244 |
||
60303 | 245 |
lemma arc_reversepath: |
246 |
assumes "arc g" shows "arc(reversepath g)" |
|
247 |
proof - |
|
248 |
have injg: "inj_on g {0..1}" |
|
249 |
using assms |
|
250 |
by (simp add: arc_def) |
|
251 |
have **: "\<And>x y::real. 1-x = 1-y \<Longrightarrow> x = y" |
|
252 |
by simp |
|
253 |
show ?thesis |
|
254 |
apply (auto simp: arc_def inj_on_def path_reversepath) |
|
255 |
apply (simp add: arc_imp_path assms) |
|
256 |
apply (rule **) |
|
257 |
apply (rule inj_onD [OF injg]) |
|
258 |
apply (auto simp: reversepath_def) |
|
259 |
done |
|
260 |
qed |
|
261 |
||
262 |
lemma simple_path_reversepath: "simple_path g \<Longrightarrow> simple_path (reversepath g)" |
|
263 |
apply (simp add: simple_path_def) |
|
264 |
apply (force simp: reversepath_def) |
|
265 |
done |
|
266 |
||
49653 | 267 |
lemmas reversepath_simps = |
268 |
path_reversepath path_image_reversepath pathstart_reversepath pathfinish_reversepath |
|
36583 | 269 |
|
49653 | 270 |
lemma path_join[simp]: |
271 |
assumes "pathfinish g1 = pathstart g2" |
|
272 |
shows "path (g1 +++ g2) \<longleftrightarrow> path g1 \<and> path g2" |
|
273 |
unfolding path_def pathfinish_def pathstart_def |
|
51478
270b21f3ae0a
move continuous and continuous_on to the HOL image; isCont is an abbreviation for continuous (at x) (isCont is now restricted to a T2 space)
hoelzl
parents:
50935
diff
changeset
|
274 |
proof safe |
270b21f3ae0a
move continuous and continuous_on to the HOL image; isCont is an abbreviation for continuous (at x) (isCont is now restricted to a T2 space)
hoelzl
parents:
50935
diff
changeset
|
275 |
assume cont: "continuous_on {0..1} (g1 +++ g2)" |
270b21f3ae0a
move continuous and continuous_on to the HOL image; isCont is an abbreviation for continuous (at x) (isCont is now restricted to a T2 space)
hoelzl
parents:
50935
diff
changeset
|
276 |
have g1: "continuous_on {0..1} g1 \<longleftrightarrow> continuous_on {0..1} ((g1 +++ g2) \<circ> (\<lambda>x. x / 2))" |
270b21f3ae0a
move continuous and continuous_on to the HOL image; isCont is an abbreviation for continuous (at x) (isCont is now restricted to a T2 space)
hoelzl
parents:
50935
diff
changeset
|
277 |
by (intro continuous_on_cong refl) (auto simp: joinpaths_def) |
270b21f3ae0a
move continuous and continuous_on to the HOL image; isCont is an abbreviation for continuous (at x) (isCont is now restricted to a T2 space)
hoelzl
parents:
50935
diff
changeset
|
278 |
have g2: "continuous_on {0..1} g2 \<longleftrightarrow> continuous_on {0..1} ((g1 +++ g2) \<circ> (\<lambda>x. x / 2 + 1/2))" |
53640 | 279 |
using assms |
280 |
by (intro continuous_on_cong refl) (auto simp: joinpaths_def pathfinish_def pathstart_def) |
|
281 |
show "continuous_on {0..1} g1" and "continuous_on {0..1} g2" |
|
51481
ef949192e5d6
move continuous_on_inv to HOL image (simplifies isCont_inverse_function)
hoelzl
parents:
51478
diff
changeset
|
282 |
unfolding g1 g2 |
56371
fb9ae0727548
extend continuous_intros; remove continuous_on_intros and isCont_intros
hoelzl
parents:
56188
diff
changeset
|
283 |
by (auto intro!: continuous_intros continuous_on_subset[OF cont] simp del: o_apply) |
51478
270b21f3ae0a
move continuous and continuous_on to the HOL image; isCont is an abbreviation for continuous (at x) (isCont is now restricted to a T2 space)
hoelzl
parents:
50935
diff
changeset
|
284 |
next |
270b21f3ae0a
move continuous and continuous_on to the HOL image; isCont is an abbreviation for continuous (at x) (isCont is now restricted to a T2 space)
hoelzl
parents:
50935
diff
changeset
|
285 |
assume g1g2: "continuous_on {0..1} g1" "continuous_on {0..1} g2" |
270b21f3ae0a
move continuous and continuous_on to the HOL image; isCont is an abbreviation for continuous (at x) (isCont is now restricted to a T2 space)
hoelzl
parents:
50935
diff
changeset
|
286 |
have 01: "{0 .. 1} = {0..1/2} \<union> {1/2 .. 1::real}" |
36583 | 287 |
by auto |
53640 | 288 |
{ |
289 |
fix x :: real |
|
290 |
assume "0 \<le> x" and "x \<le> 1" |
|
291 |
then have "x \<in> (\<lambda>x. x * 2) ` {0..1 / 2}" |
|
292 |
by (intro image_eqI[where x="x/2"]) auto |
|
293 |
} |
|
51478
270b21f3ae0a
move continuous and continuous_on to the HOL image; isCont is an abbreviation for continuous (at x) (isCont is now restricted to a T2 space)
hoelzl
parents:
50935
diff
changeset
|
294 |
note 1 = this |
53640 | 295 |
{ |
296 |
fix x :: real |
|
297 |
assume "0 \<le> x" and "x \<le> 1" |
|
298 |
then have "x \<in> (\<lambda>x. x * 2 - 1) ` {1 / 2..1}" |
|
299 |
by (intro image_eqI[where x="x/2 + 1/2"]) auto |
|
300 |
} |
|
51478
270b21f3ae0a
move continuous and continuous_on to the HOL image; isCont is an abbreviation for continuous (at x) (isCont is now restricted to a T2 space)
hoelzl
parents:
50935
diff
changeset
|
301 |
note 2 = this |
49653 | 302 |
show "continuous_on {0..1} (g1 +++ g2)" |
53640 | 303 |
using assms |
304 |
unfolding joinpaths_def 01 |
|
56371
fb9ae0727548
extend continuous_intros; remove continuous_on_intros and isCont_intros
hoelzl
parents:
56188
diff
changeset
|
305 |
apply (intro continuous_on_cases closed_atLeastAtMost g1g2[THEN continuous_on_compose2] continuous_intros) |
53640 | 306 |
apply (auto simp: field_simps pathfinish_def pathstart_def intro!: 1 2) |
307 |
done |
|
49653 | 308 |
qed |
36583 | 309 |
|
60420 | 310 |
section \<open>Path Images\<close> |
60303 | 311 |
|
312 |
lemma bounded_path_image: "path g \<Longrightarrow> bounded(path_image g)" |
|
313 |
by (simp add: compact_imp_bounded compact_path_image) |
|
314 |
||
60809
457abb82fb9e
the Cauchy integral theorem and related material
paulson <lp15@cam.ac.uk>
parents:
60420
diff
changeset
|
315 |
lemma closed_path_image: |
60303 | 316 |
fixes g :: "real \<Rightarrow> 'a::t2_space" |
317 |
shows "path g \<Longrightarrow> closed(path_image g)" |
|
318 |
by (metis compact_path_image compact_imp_closed) |
|
319 |
||
320 |
lemma connected_simple_path_image: "simple_path g \<Longrightarrow> connected(path_image g)" |
|
321 |
by (metis connected_path_image simple_path_imp_path) |
|
322 |
||
323 |
lemma compact_simple_path_image: "simple_path g \<Longrightarrow> compact(path_image g)" |
|
324 |
by (metis compact_path_image simple_path_imp_path) |
|
325 |
||
326 |
lemma bounded_simple_path_image: "simple_path g \<Longrightarrow> bounded(path_image g)" |
|
327 |
by (metis bounded_path_image simple_path_imp_path) |
|
328 |
||
329 |
lemma closed_simple_path_image: |
|
330 |
fixes g :: "real \<Rightarrow> 'a::t2_space" |
|
331 |
shows "simple_path g \<Longrightarrow> closed(path_image g)" |
|
332 |
by (metis closed_path_image simple_path_imp_path) |
|
333 |
||
334 |
lemma connected_arc_image: "arc g \<Longrightarrow> connected(path_image g)" |
|
335 |
by (metis connected_path_image arc_imp_path) |
|
336 |
||
337 |
lemma compact_arc_image: "arc g \<Longrightarrow> compact(path_image g)" |
|
338 |
by (metis compact_path_image arc_imp_path) |
|
339 |
||
340 |
lemma bounded_arc_image: "arc g \<Longrightarrow> bounded(path_image g)" |
|
341 |
by (metis bounded_path_image arc_imp_path) |
|
342 |
||
343 |
lemma closed_arc_image: |
|
344 |
fixes g :: "real \<Rightarrow> 'a::t2_space" |
|
345 |
shows "arc g \<Longrightarrow> closed(path_image g)" |
|
346 |
by (metis closed_path_image arc_imp_path) |
|
347 |
||
53640 | 348 |
lemma path_image_join_subset: "path_image (g1 +++ g2) \<subseteq> path_image g1 \<union> path_image g2" |
349 |
unfolding path_image_def joinpaths_def |
|
350 |
by auto |
|
36583 | 351 |
|
352 |
lemma subset_path_image_join: |
|
53640 | 353 |
assumes "path_image g1 \<subseteq> s" |
354 |
and "path_image g2 \<subseteq> s" |
|
355 |
shows "path_image (g1 +++ g2) \<subseteq> s" |
|
356 |
using path_image_join_subset[of g1 g2] and assms |
|
357 |
by auto |
|
36583 | 358 |
|
359 |
lemma path_image_join: |
|
60303 | 360 |
"pathfinish g1 = pathstart g2 \<Longrightarrow> path_image(g1 +++ g2) = path_image g1 \<union> path_image g2" |
361 |
apply (rule subset_antisym [OF path_image_join_subset]) |
|
362 |
apply (auto simp: pathfinish_def pathstart_def path_image_def joinpaths_def image_def) |
|
363 |
apply (drule sym) |
|
364 |
apply (rule_tac x="xa/2" in bexI, auto) |
|
365 |
apply (rule ccontr) |
|
366 |
apply (drule_tac x="(xa+1)/2" in bspec) |
|
367 |
apply (auto simp: field_simps) |
|
368 |
apply (drule_tac x="1/2" in bspec, auto) |
|
369 |
done |
|
36583 | 370 |
|
371 |
lemma not_in_path_image_join: |
|
53640 | 372 |
assumes "x \<notin> path_image g1" |
373 |
and "x \<notin> path_image g2" |
|
374 |
shows "x \<notin> path_image (g1 +++ g2)" |
|
375 |
using assms and path_image_join_subset[of g1 g2] |
|
376 |
by auto |
|
36583 | 377 |
|
60303 | 378 |
lemma pathstart_compose: "pathstart(f o p) = f(pathstart p)" |
379 |
by (simp add: pathstart_def) |
|
380 |
||
381 |
lemma pathfinish_compose: "pathfinish(f o p) = f(pathfinish p)" |
|
382 |
by (simp add: pathfinish_def) |
|
383 |
||
384 |
lemma path_image_compose: "path_image (f o p) = f ` (path_image p)" |
|
385 |
by (simp add: image_comp path_image_def) |
|
386 |
||
387 |
lemma path_compose_join: "f o (p +++ q) = (f o p) +++ (f o q)" |
|
388 |
by (rule ext) (simp add: joinpaths_def) |
|
389 |
||
390 |
lemma path_compose_reversepath: "f o reversepath p = reversepath(f o p)" |
|
391 |
by (rule ext) (simp add: reversepath_def) |
|
392 |
||
393 |
lemma join_paths_eq: |
|
394 |
"(\<And>t. t \<in> {0..1} \<Longrightarrow> p t = p' t) \<Longrightarrow> |
|
395 |
(\<And>t. t \<in> {0..1} \<Longrightarrow> q t = q' t) |
|
396 |
\<Longrightarrow> t \<in> {0..1} \<Longrightarrow> (p +++ q) t = (p' +++ q') t" |
|
397 |
by (auto simp: joinpaths_def) |
|
398 |
||
399 |
lemma simple_path_inj_on: "simple_path g \<Longrightarrow> inj_on g {0<..<1}" |
|
400 |
by (auto simp: simple_path_def path_image_def inj_on_def less_eq_real_def Ball_def) |
|
401 |
||
402 |
||
60420 | 403 |
subsection\<open>Simple paths with the endpoints removed\<close> |
60303 | 404 |
|
405 |
lemma simple_path_endless: |
|
406 |
"simple_path c \<Longrightarrow> path_image c - {pathstart c,pathfinish c} = c ` {0<..<1}" |
|
407 |
apply (auto simp: simple_path_def path_image_def pathstart_def pathfinish_def Ball_def Bex_def image_def) |
|
408 |
apply (metis eq_iff le_less_linear) |
|
409 |
apply (metis leD linear) |
|
410 |
using less_eq_real_def zero_le_one apply blast |
|
411 |
using less_eq_real_def zero_le_one apply blast |
|
49653 | 412 |
done |
36583 | 413 |
|
60303 | 414 |
lemma connected_simple_path_endless: |
415 |
"simple_path c \<Longrightarrow> connected(path_image c - {pathstart c,pathfinish c})" |
|
416 |
apply (simp add: simple_path_endless) |
|
417 |
apply (rule connected_continuous_image) |
|
418 |
apply (meson continuous_on_subset greaterThanLessThan_subseteq_atLeastAtMost_iff le_numeral_extra(3) le_numeral_extra(4) path_def simple_path_imp_path) |
|
419 |
by auto |
|
420 |
||
421 |
lemma nonempty_simple_path_endless: |
|
422 |
"simple_path c \<Longrightarrow> path_image c - {pathstart c,pathfinish c} \<noteq> {}" |
|
423 |
by (simp add: simple_path_endless) |
|
424 |
||
425 |
||
60420 | 426 |
subsection\<open>The operations on paths\<close> |
60303 | 427 |
|
428 |
lemma path_image_subset_reversepath: "path_image(reversepath g) \<le> path_image g" |
|
429 |
by (auto simp: path_image_def reversepath_def) |
|
430 |
||
431 |
lemma continuous_on_op_minus: "continuous_on (s::real set) (op - x)" |
|
432 |
by (rule continuous_intros | simp)+ |
|
433 |
||
434 |
lemma path_imp_reversepath: "path g \<Longrightarrow> path(reversepath g)" |
|
435 |
apply (auto simp: path_def reversepath_def) |
|
436 |
using continuous_on_compose [of "{0..1}" "\<lambda>x. 1 - x" g] |
|
437 |
apply (auto simp: continuous_on_op_minus) |
|
438 |
done |
|
439 |
||
61204 | 440 |
lemma half_bounded_equal: "1 \<le> x * 2 \<Longrightarrow> x * 2 \<le> 1 \<longleftrightarrow> x = (1/2::real)" |
441 |
by simp |
|
60303 | 442 |
|
443 |
lemma continuous_on_joinpaths: |
|
444 |
assumes "continuous_on {0..1} g1" "continuous_on {0..1} g2" "pathfinish g1 = pathstart g2" |
|
445 |
shows "continuous_on {0..1} (g1 +++ g2)" |
|
446 |
proof - |
|
447 |
have *: "{0..1::real} = {0..1/2} \<union> {1/2..1}" |
|
448 |
by auto |
|
449 |
have gg: "g2 0 = g1 1" |
|
450 |
by (metis assms(3) pathfinish_def pathstart_def) |
|
61204 | 451 |
have 1: "continuous_on {0..1/2} (g1 +++ g2)" |
60303 | 452 |
apply (rule continuous_on_eq [of _ "g1 o (\<lambda>x. 2*x)"]) |
61204 | 453 |
apply (rule continuous_intros | simp add: joinpaths_def assms)+ |
60303 | 454 |
done |
61204 | 455 |
have "continuous_on {1/2..1} (g2 o (\<lambda>x. 2*x-1))" |
456 |
apply (rule continuous_on_subset [of "{1/2..1}"]) |
|
457 |
apply (rule continuous_intros | simp add: image_affinity_atLeastAtMost_diff assms)+ |
|
458 |
done |
|
459 |
then have 2: "continuous_on {1/2..1} (g1 +++ g2)" |
|
460 |
apply (rule continuous_on_eq [of "{1/2..1}" "g2 o (\<lambda>x. 2*x-1)"]) |
|
461 |
apply (rule assms continuous_intros | simp add: joinpaths_def mult.commute half_bounded_equal gg)+ |
|
60303 | 462 |
done |
463 |
show ?thesis |
|
464 |
apply (subst *) |
|
465 |
apply (rule continuous_on_union) |
|
466 |
using 1 2 |
|
467 |
apply auto |
|
468 |
done |
|
469 |
qed |
|
470 |
||
471 |
lemma path_join_imp: "\<lbrakk>path g1; path g2; pathfinish g1 = pathstart g2\<rbrakk> \<Longrightarrow> path(g1 +++ g2)" |
|
472 |
by (simp add: path_join) |
|
473 |
||
474 |
lemmas join_paths_simps = path_join path_image_join pathstart_join pathfinish_join |
|
475 |
||
36583 | 476 |
lemma simple_path_join_loop: |
60809
457abb82fb9e
the Cauchy integral theorem and related material
paulson <lp15@cam.ac.uk>
parents:
60420
diff
changeset
|
477 |
assumes "arc g1" "arc g2" |
457abb82fb9e
the Cauchy integral theorem and related material
paulson <lp15@cam.ac.uk>
parents:
60420
diff
changeset
|
478 |
"pathfinish g1 = pathstart g2" "pathfinish g2 = pathstart g1" |
60303 | 479 |
"path_image g1 \<inter> path_image g2 \<subseteq> {pathstart g1, pathstart g2}" |
480 |
shows "simple_path(g1 +++ g2)" |
|
481 |
proof - |
|
482 |
have injg1: "inj_on g1 {0..1}" |
|
483 |
using assms |
|
484 |
by (simp add: arc_def) |
|
485 |
have injg2: "inj_on g2 {0..1}" |
|
486 |
using assms |
|
487 |
by (simp add: arc_def) |
|
60809
457abb82fb9e
the Cauchy integral theorem and related material
paulson <lp15@cam.ac.uk>
parents:
60420
diff
changeset
|
488 |
have g12: "g1 1 = g2 0" |
457abb82fb9e
the Cauchy integral theorem and related material
paulson <lp15@cam.ac.uk>
parents:
60420
diff
changeset
|
489 |
and g21: "g2 1 = g1 0" |
60303 | 490 |
and sb: "g1 ` {0..1} \<inter> g2 ` {0..1} \<subseteq> {g1 0, g2 0}" |
491 |
using assms |
|
492 |
by (simp_all add: arc_def pathfinish_def pathstart_def path_image_def) |
|
493 |
{ fix x and y::real |
|
60809
457abb82fb9e
the Cauchy integral theorem and related material
paulson <lp15@cam.ac.uk>
parents:
60420
diff
changeset
|
494 |
assume xyI: "x = 1 \<longrightarrow> y \<noteq> 0" |
60303 | 495 |
and xy: "x \<le> 1" "0 \<le> y" " y * 2 \<le> 1" "\<not> x * 2 \<le> 1" "g2 (2 * x - 1) = g1 (2 * y)" |
496 |
have g1im: "g1 (2 * y) \<in> g1 ` {0..1} \<inter> g2 ` {0..1}" |
|
497 |
using xy |
|
498 |
apply simp |
|
499 |
apply (rule_tac x="2 * x - 1" in image_eqI, auto) |
|
500 |
done |
|
501 |
have False |
|
60809
457abb82fb9e
the Cauchy integral theorem and related material
paulson <lp15@cam.ac.uk>
parents:
60420
diff
changeset
|
502 |
using subsetD [OF sb g1im] xy |
60303 | 503 |
apply auto |
504 |
apply (drule inj_onD [OF injg1]) |
|
505 |
using g21 [symmetric] xyI |
|
506 |
apply (auto dest: inj_onD [OF injg2]) |
|
507 |
done |
|
508 |
} note * = this |
|
509 |
{ fix x and y::real |
|
510 |
assume xy: "y \<le> 1" "0 \<le> x" "\<not> y * 2 \<le> 1" "x * 2 \<le> 1" "g1 (2 * x) = g2 (2 * y - 1)" |
|
511 |
have g1im: "g1 (2 * x) \<in> g1 ` {0..1} \<inter> g2 ` {0..1}" |
|
512 |
using xy |
|
513 |
apply simp |
|
514 |
apply (rule_tac x="2 * x" in image_eqI, auto) |
|
515 |
done |
|
516 |
have "x = 0 \<and> y = 1" |
|
60809
457abb82fb9e
the Cauchy integral theorem and related material
paulson <lp15@cam.ac.uk>
parents:
60420
diff
changeset
|
517 |
using subsetD [OF sb g1im] xy |
60303 | 518 |
apply auto |
519 |
apply (force dest: inj_onD [OF injg1]) |
|
520 |
using g21 [symmetric] |
|
521 |
apply (auto dest: inj_onD [OF injg2]) |
|
522 |
done |
|
523 |
} note ** = this |
|
524 |
show ?thesis |
|
525 |
using assms |
|
526 |
apply (simp add: arc_def simple_path_def path_join, clarify) |
|
527 |
apply (simp add: joinpaths_def split: split_if_asm) |
|
528 |
apply (force dest: inj_onD [OF injg1]) |
|
529 |
apply (metis *) |
|
530 |
apply (metis **) |
|
531 |
apply (force dest: inj_onD [OF injg2]) |
|
532 |
done |
|
533 |
qed |
|
534 |
||
535 |
lemma arc_join: |
|
60809
457abb82fb9e
the Cauchy integral theorem and related material
paulson <lp15@cam.ac.uk>
parents:
60420
diff
changeset
|
536 |
assumes "arc g1" "arc g2" |
60303 | 537 |
"pathfinish g1 = pathstart g2" |
538 |
"path_image g1 \<inter> path_image g2 \<subseteq> {pathstart g2}" |
|
539 |
shows "arc(g1 +++ g2)" |
|
540 |
proof - |
|
541 |
have injg1: "inj_on g1 {0..1}" |
|
542 |
using assms |
|
543 |
by (simp add: arc_def) |
|
544 |
have injg2: "inj_on g2 {0..1}" |
|
545 |
using assms |
|
546 |
by (simp add: arc_def) |
|
547 |
have g11: "g1 1 = g2 0" |
|
548 |
and sb: "g1 ` {0..1} \<inter> g2 ` {0..1} \<subseteq> {g2 0}" |
|
549 |
using assms |
|
550 |
by (simp_all add: arc_def pathfinish_def pathstart_def path_image_def) |
|
551 |
{ fix x and y::real |
|
60809
457abb82fb9e
the Cauchy integral theorem and related material
paulson <lp15@cam.ac.uk>
parents:
60420
diff
changeset
|
552 |
assume xy: "x \<le> 1" "0 \<le> y" " y * 2 \<le> 1" "\<not> x * 2 \<le> 1" "g2 (2 * x - 1) = g1 (2 * y)" |
60303 | 553 |
have g1im: "g1 (2 * y) \<in> g1 ` {0..1} \<inter> g2 ` {0..1}" |
554 |
using xy |
|
555 |
apply simp |
|
556 |
apply (rule_tac x="2 * x - 1" in image_eqI, auto) |
|
557 |
done |
|
558 |
have False |
|
60809
457abb82fb9e
the Cauchy integral theorem and related material
paulson <lp15@cam.ac.uk>
parents:
60420
diff
changeset
|
559 |
using subsetD [OF sb g1im] xy |
60303 | 560 |
by (auto dest: inj_onD [OF injg2]) |
561 |
} note * = this |
|
562 |
show ?thesis |
|
563 |
apply (simp add: arc_def inj_on_def) |
|
564 |
apply (clarsimp simp add: arc_imp_path assms path_join) |
|
565 |
apply (simp add: joinpaths_def split: split_if_asm) |
|
566 |
apply (force dest: inj_onD [OF injg1]) |
|
567 |
apply (metis *) |
|
568 |
apply (metis *) |
|
569 |
apply (force dest: inj_onD [OF injg2]) |
|
570 |
done |
|
571 |
qed |
|
572 |
||
573 |
lemma reversepath_joinpaths: |
|
574 |
"pathfinish g1 = pathstart g2 \<Longrightarrow> reversepath(g1 +++ g2) = reversepath g2 +++ reversepath g1" |
|
575 |
unfolding reversepath_def pathfinish_def pathstart_def joinpaths_def |
|
576 |
by (rule ext) (auto simp: mult.commute) |
|
577 |
||
578 |
||
60420 | 579 |
subsection\<open>Choosing a subpath of an existing path\<close> |
60809
457abb82fb9e
the Cauchy integral theorem and related material
paulson <lp15@cam.ac.uk>
parents:
60420
diff
changeset
|
580 |
|
60303 | 581 |
definition subpath :: "real \<Rightarrow> real \<Rightarrow> (real \<Rightarrow> 'a) \<Rightarrow> real \<Rightarrow> 'a::real_normed_vector" |
582 |
where "subpath a b g \<equiv> \<lambda>x. g((b - a) * x + a)" |
|
583 |
||
60809
457abb82fb9e
the Cauchy integral theorem and related material
paulson <lp15@cam.ac.uk>
parents:
60420
diff
changeset
|
584 |
lemma path_image_subpath_gen [simp]: |
60303 | 585 |
fixes g :: "real \<Rightarrow> 'a::real_normed_vector" |
586 |
shows "path_image(subpath u v g) = g ` (closed_segment u v)" |
|
587 |
apply (simp add: closed_segment_real_eq path_image_def subpath_def) |
|
588 |
apply (subst o_def [of g, symmetric]) |
|
589 |
apply (simp add: image_comp [symmetric]) |
|
590 |
done |
|
591 |
||
592 |
lemma path_image_subpath [simp]: |
|
593 |
fixes g :: "real \<Rightarrow> 'a::real_normed_vector" |
|
594 |
shows "path_image(subpath u v g) = (if u \<le> v then g ` {u..v} else g ` {v..u})" |
|
595 |
by (simp add: closed_segment_eq_real_ivl) |
|
596 |
||
597 |
lemma path_subpath [simp]: |
|
598 |
fixes g :: "real \<Rightarrow> 'a::real_normed_vector" |
|
599 |
assumes "path g" "u \<in> {0..1}" "v \<in> {0..1}" |
|
600 |
shows "path(subpath u v g)" |
|
601 |
proof - |
|
602 |
have "continuous_on {0..1} (g o (\<lambda>x. ((v-u) * x+ u)))" |
|
603 |
apply (rule continuous_intros | simp)+ |
|
604 |
apply (simp add: image_affinity_atLeastAtMost [where c=u]) |
|
605 |
using assms |
|
606 |
apply (auto simp: path_def continuous_on_subset) |
|
607 |
done |
|
608 |
then show ?thesis |
|
609 |
by (simp add: path_def subpath_def) |
|
49653 | 610 |
qed |
36583 | 611 |
|
60303 | 612 |
lemma pathstart_subpath [simp]: "pathstart(subpath u v g) = g(u)" |
613 |
by (simp add: pathstart_def subpath_def) |
|
614 |
||
615 |
lemma pathfinish_subpath [simp]: "pathfinish(subpath u v g) = g(v)" |
|
616 |
by (simp add: pathfinish_def subpath_def) |
|
617 |
||
618 |
lemma subpath_trivial [simp]: "subpath 0 1 g = g" |
|
619 |
by (simp add: subpath_def) |
|
620 |
||
621 |
lemma subpath_reversepath: "subpath 1 0 g = reversepath g" |
|
622 |
by (simp add: reversepath_def subpath_def) |
|
623 |
||
624 |
lemma reversepath_subpath: "reversepath(subpath u v g) = subpath v u g" |
|
625 |
by (simp add: reversepath_def subpath_def algebra_simps) |
|
626 |
||
627 |
lemma subpath_translation: "subpath u v ((\<lambda>x. a + x) o g) = (\<lambda>x. a + x) o subpath u v g" |
|
628 |
by (rule ext) (simp add: subpath_def) |
|
629 |
||
630 |
lemma subpath_linear_image: "linear f \<Longrightarrow> subpath u v (f o g) = f o subpath u v g" |
|
631 |
by (rule ext) (simp add: subpath_def) |
|
632 |
||
60809
457abb82fb9e
the Cauchy integral theorem and related material
paulson <lp15@cam.ac.uk>
parents:
60420
diff
changeset
|
633 |
lemma affine_ineq: |
457abb82fb9e
the Cauchy integral theorem and related material
paulson <lp15@cam.ac.uk>
parents:
60420
diff
changeset
|
634 |
fixes x :: "'a::linordered_idom" |
60303 | 635 |
assumes "x \<le> 1" "v < u" |
636 |
shows "v + x * u \<le> u + x * v" |
|
637 |
proof - |
|
638 |
have "(1-x)*(u-v) \<ge> 0" |
|
639 |
using assms by auto |
|
640 |
then show ?thesis |
|
641 |
by (simp add: algebra_simps) |
|
49653 | 642 |
qed |
36583 | 643 |
|
60809
457abb82fb9e
the Cauchy integral theorem and related material
paulson <lp15@cam.ac.uk>
parents:
60420
diff
changeset
|
644 |
lemma simple_path_subpath_eq: |
60303 | 645 |
"simple_path(subpath u v g) \<longleftrightarrow> |
646 |
path(subpath u v g) \<and> u\<noteq>v \<and> |
|
647 |
(\<forall>x y. x \<in> closed_segment u v \<and> y \<in> closed_segment u v \<and> g x = g y |
|
648 |
\<longrightarrow> x = y \<or> x = u \<and> y = v \<or> x = v \<and> y = u)" |
|
649 |
(is "?lhs = ?rhs") |
|
650 |
proof (rule iffI) |
|
651 |
assume ?lhs |
|
652 |
then have p: "path (\<lambda>x. g ((v - u) * x + u))" |
|
60809
457abb82fb9e
the Cauchy integral theorem and related material
paulson <lp15@cam.ac.uk>
parents:
60420
diff
changeset
|
653 |
and sim: "(\<And>x y. \<lbrakk>x\<in>{0..1}; y\<in>{0..1}; g ((v - u) * x + u) = g ((v - u) * y + u)\<rbrakk> |
60303 | 654 |
\<Longrightarrow> x = y \<or> x = 0 \<and> y = 1 \<or> x = 1 \<and> y = 0)" |
655 |
by (auto simp: simple_path_def subpath_def) |
|
656 |
{ fix x y |
|
657 |
assume "x \<in> closed_segment u v" "y \<in> closed_segment u v" "g x = g y" |
|
658 |
then have "x = y \<or> x = u \<and> y = v \<or> x = v \<and> y = u" |
|
659 |
using sim [of "(x-u)/(v-u)" "(y-u)/(v-u)"] p |
|
60809
457abb82fb9e
the Cauchy integral theorem and related material
paulson <lp15@cam.ac.uk>
parents:
60420
diff
changeset
|
660 |
by (auto simp: closed_segment_real_eq image_affinity_atLeastAtMost divide_simps |
60303 | 661 |
split: split_if_asm) |
662 |
} moreover |
|
663 |
have "path(subpath u v g) \<and> u\<noteq>v" |
|
664 |
using sim [of "1/3" "2/3"] p |
|
665 |
by (auto simp: subpath_def) |
|
666 |
ultimately show ?rhs |
|
667 |
by metis |
|
668 |
next |
|
669 |
assume ?rhs |
|
60809
457abb82fb9e
the Cauchy integral theorem and related material
paulson <lp15@cam.ac.uk>
parents:
60420
diff
changeset
|
670 |
then |
60303 | 671 |
have d1: "\<And>x y. \<lbrakk>g x = g y; u \<le> x; x \<le> v; u \<le> y; y \<le> v\<rbrakk> \<Longrightarrow> x = y \<or> x = u \<and> y = v \<or> x = v \<and> y = u" |
672 |
and d2: "\<And>x y. \<lbrakk>g x = g y; v \<le> x; x \<le> u; v \<le> y; y \<le> u\<rbrakk> \<Longrightarrow> x = y \<or> x = u \<and> y = v \<or> x = v \<and> y = u" |
|
673 |
and ne: "u < v \<or> v < u" |
|
674 |
and psp: "path (subpath u v g)" |
|
675 |
by (auto simp: closed_segment_real_eq image_affinity_atLeastAtMost) |
|
676 |
have [simp]: "\<And>x. u + x * v = v + x * u \<longleftrightarrow> u=v \<or> x=1" |
|
677 |
by algebra |
|
678 |
show ?lhs using psp ne |
|
679 |
unfolding simple_path_def subpath_def |
|
680 |
by (fastforce simp add: algebra_simps affine_ineq mult_left_mono crossproduct_eq dest: d1 d2) |
|
681 |
qed |
|
682 |
||
60809
457abb82fb9e
the Cauchy integral theorem and related material
paulson <lp15@cam.ac.uk>
parents:
60420
diff
changeset
|
683 |
lemma arc_subpath_eq: |
60303 | 684 |
"arc(subpath u v g) \<longleftrightarrow> path(subpath u v g) \<and> u\<noteq>v \<and> inj_on g (closed_segment u v)" |
685 |
(is "?lhs = ?rhs") |
|
686 |
proof (rule iffI) |
|
687 |
assume ?lhs |
|
688 |
then have p: "path (\<lambda>x. g ((v - u) * x + u))" |
|
60809
457abb82fb9e
the Cauchy integral theorem and related material
paulson <lp15@cam.ac.uk>
parents:
60420
diff
changeset
|
689 |
and sim: "(\<And>x y. \<lbrakk>x\<in>{0..1}; y\<in>{0..1}; g ((v - u) * x + u) = g ((v - u) * y + u)\<rbrakk> |
60303 | 690 |
\<Longrightarrow> x = y)" |
691 |
by (auto simp: arc_def inj_on_def subpath_def) |
|
692 |
{ fix x y |
|
693 |
assume "x \<in> closed_segment u v" "y \<in> closed_segment u v" "g x = g y" |
|
694 |
then have "x = y" |
|
695 |
using sim [of "(x-u)/(v-u)" "(y-u)/(v-u)"] p |
|
60809
457abb82fb9e
the Cauchy integral theorem and related material
paulson <lp15@cam.ac.uk>
parents:
60420
diff
changeset
|
696 |
by (force simp add: inj_on_def closed_segment_real_eq image_affinity_atLeastAtMost divide_simps |
60303 | 697 |
split: split_if_asm) |
698 |
} moreover |
|
699 |
have "path(subpath u v g) \<and> u\<noteq>v" |
|
700 |
using sim [of "1/3" "2/3"] p |
|
701 |
by (auto simp: subpath_def) |
|
702 |
ultimately show ?rhs |
|
60809
457abb82fb9e
the Cauchy integral theorem and related material
paulson <lp15@cam.ac.uk>
parents:
60420
diff
changeset
|
703 |
unfolding inj_on_def |
60303 | 704 |
by metis |
705 |
next |
|
706 |
assume ?rhs |
|
60809
457abb82fb9e
the Cauchy integral theorem and related material
paulson <lp15@cam.ac.uk>
parents:
60420
diff
changeset
|
707 |
then |
60303 | 708 |
have d1: "\<And>x y. \<lbrakk>g x = g y; u \<le> x; x \<le> v; u \<le> y; y \<le> v\<rbrakk> \<Longrightarrow> x = y" |
709 |
and d2: "\<And>x y. \<lbrakk>g x = g y; v \<le> x; x \<le> u; v \<le> y; y \<le> u\<rbrakk> \<Longrightarrow> x = y" |
|
710 |
and ne: "u < v \<or> v < u" |
|
711 |
and psp: "path (subpath u v g)" |
|
712 |
by (auto simp: inj_on_def closed_segment_real_eq image_affinity_atLeastAtMost) |
|
713 |
show ?lhs using psp ne |
|
714 |
unfolding arc_def subpath_def inj_on_def |
|
715 |
by (auto simp: algebra_simps affine_ineq mult_left_mono crossproduct_eq dest: d1 d2) |
|
716 |
qed |
|
717 |
||
718 |
||
60809
457abb82fb9e
the Cauchy integral theorem and related material
paulson <lp15@cam.ac.uk>
parents:
60420
diff
changeset
|
719 |
lemma simple_path_subpath: |
60303 | 720 |
assumes "simple_path g" "u \<in> {0..1}" "v \<in> {0..1}" "u \<noteq> v" |
721 |
shows "simple_path(subpath u v g)" |
|
722 |
using assms |
|
723 |
apply (simp add: simple_path_subpath_eq simple_path_imp_path) |
|
724 |
apply (simp add: simple_path_def closed_segment_real_eq image_affinity_atLeastAtMost, fastforce) |
|
725 |
done |
|
726 |
||
727 |
lemma arc_simple_path_subpath: |
|
728 |
"\<lbrakk>simple_path g; u \<in> {0..1}; v \<in> {0..1}; g u \<noteq> g v\<rbrakk> \<Longrightarrow> arc(subpath u v g)" |
|
729 |
by (force intro: simple_path_subpath simple_path_imp_arc) |
|
730 |
||
731 |
lemma arc_subpath_arc: |
|
732 |
"\<lbrakk>arc g; u \<in> {0..1}; v \<in> {0..1}; u \<noteq> v\<rbrakk> \<Longrightarrow> arc(subpath u v g)" |
|
733 |
by (meson arc_def arc_imp_simple_path arc_simple_path_subpath inj_onD) |
|
734 |
||
60809
457abb82fb9e
the Cauchy integral theorem and related material
paulson <lp15@cam.ac.uk>
parents:
60420
diff
changeset
|
735 |
lemma arc_simple_path_subpath_interior: |
60303 | 736 |
"\<lbrakk>simple_path g; u \<in> {0..1}; v \<in> {0..1}; u \<noteq> v; \<bar>u-v\<bar> < 1\<rbrakk> \<Longrightarrow> arc(subpath u v g)" |
737 |
apply (rule arc_simple_path_subpath) |
|
738 |
apply (force simp: simple_path_def)+ |
|
739 |
done |
|
740 |
||
60809
457abb82fb9e
the Cauchy integral theorem and related material
paulson <lp15@cam.ac.uk>
parents:
60420
diff
changeset
|
741 |
lemma path_image_subpath_subset: |
60303 | 742 |
"\<lbrakk>path g; u \<in> {0..1}; v \<in> {0..1}\<rbrakk> \<Longrightarrow> path_image(subpath u v g) \<subseteq> path_image g" |
743 |
apply (simp add: closed_segment_real_eq image_affinity_atLeastAtMost) |
|
744 |
apply (auto simp: path_image_def) |
|
745 |
done |
|
746 |
||
747 |
lemma join_subpaths_middle: "subpath (0) ((1 / 2)) p +++ subpath ((1 / 2)) 1 p = p" |
|
748 |
by (rule ext) (simp add: joinpaths_def subpath_def divide_simps) |
|
53640 | 749 |
|
49653 | 750 |
|
60420 | 751 |
subsection \<open>Reparametrizing a closed curve to start at some chosen point\<close> |
36583 | 752 |
|
53640 | 753 |
definition shiftpath :: "real \<Rightarrow> (real \<Rightarrow> 'a::topological_space) \<Rightarrow> real \<Rightarrow> 'a" |
754 |
where "shiftpath a f = (\<lambda>x. if (a + x) \<le> 1 then f (a + x) else f (a + x - 1))" |
|
36583 | 755 |
|
53640 | 756 |
lemma pathstart_shiftpath: "a \<le> 1 \<Longrightarrow> pathstart (shiftpath a g) = g a" |
36583 | 757 |
unfolding pathstart_def shiftpath_def by auto |
758 |
||
49653 | 759 |
lemma pathfinish_shiftpath: |
53640 | 760 |
assumes "0 \<le> a" |
761 |
and "pathfinish g = pathstart g" |
|
762 |
shows "pathfinish (shiftpath a g) = g a" |
|
763 |
using assms |
|
764 |
unfolding pathstart_def pathfinish_def shiftpath_def |
|
36583 | 765 |
by auto |
766 |
||
767 |
lemma endpoints_shiftpath: |
|
53640 | 768 |
assumes "pathfinish g = pathstart g" |
769 |
and "a \<in> {0 .. 1}" |
|
770 |
shows "pathfinish (shiftpath a g) = g a" |
|
771 |
and "pathstart (shiftpath a g) = g a" |
|
772 |
using assms |
|
773 |
by (auto intro!: pathfinish_shiftpath pathstart_shiftpath) |
|
36583 | 774 |
|
775 |
lemma closed_shiftpath: |
|
53640 | 776 |
assumes "pathfinish g = pathstart g" |
777 |
and "a \<in> {0..1}" |
|
778 |
shows "pathfinish (shiftpath a g) = pathstart (shiftpath a g)" |
|
779 |
using endpoints_shiftpath[OF assms] |
|
780 |
by auto |
|
36583 | 781 |
|
782 |
lemma path_shiftpath: |
|
53640 | 783 |
assumes "path g" |
784 |
and "pathfinish g = pathstart g" |
|
785 |
and "a \<in> {0..1}" |
|
786 |
shows "path (shiftpath a g)" |
|
49653 | 787 |
proof - |
53640 | 788 |
have *: "{0 .. 1} = {0 .. 1-a} \<union> {1-a .. 1}" |
789 |
using assms(3) by auto |
|
49653 | 790 |
have **: "\<And>x. x + a = 1 \<Longrightarrow> g (x + a - 1) = g (x + a)" |
53640 | 791 |
using assms(2)[unfolded pathfinish_def pathstart_def] |
792 |
by auto |
|
49653 | 793 |
show ?thesis |
794 |
unfolding path_def shiftpath_def * |
|
795 |
apply (rule continuous_on_union) |
|
796 |
apply (rule closed_real_atLeastAtMost)+ |
|
53640 | 797 |
apply (rule continuous_on_eq[of _ "g \<circ> (\<lambda>x. a + x)"]) |
798 |
prefer 3 |
|
799 |
apply (rule continuous_on_eq[of _ "g \<circ> (\<lambda>x. a - 1 + x)"]) |
|
800 |
prefer 3 |
|
56371
fb9ae0727548
extend continuous_intros; remove continuous_on_intros and isCont_intros
hoelzl
parents:
56188
diff
changeset
|
801 |
apply (rule continuous_intros)+ |
53640 | 802 |
prefer 2 |
56371
fb9ae0727548
extend continuous_intros; remove continuous_on_intros and isCont_intros
hoelzl
parents:
56188
diff
changeset
|
803 |
apply (rule continuous_intros)+ |
49653 | 804 |
apply (rule_tac[1-2] continuous_on_subset[OF assms(1)[unfolded path_def]]) |
805 |
using assms(3) and ** |
|
53640 | 806 |
apply auto |
807 |
apply (auto simp add: field_simps) |
|
49653 | 808 |
done |
809 |
qed |
|
36583 | 810 |
|
49653 | 811 |
lemma shiftpath_shiftpath: |
53640 | 812 |
assumes "pathfinish g = pathstart g" |
813 |
and "a \<in> {0..1}" |
|
814 |
and "x \<in> {0..1}" |
|
36583 | 815 |
shows "shiftpath (1 - a) (shiftpath a g) x = g x" |
53640 | 816 |
using assms |
817 |
unfolding pathfinish_def pathstart_def shiftpath_def |
|
818 |
by auto |
|
36583 | 819 |
|
820 |
lemma path_image_shiftpath: |
|
53640 | 821 |
assumes "a \<in> {0..1}" |
822 |
and "pathfinish g = pathstart g" |
|
823 |
shows "path_image (shiftpath a g) = path_image g" |
|
49653 | 824 |
proof - |
825 |
{ fix x |
|
53640 | 826 |
assume as: "g 1 = g 0" "x \<in> {0..1::real}" " \<forall>y\<in>{0..1} \<inter> {x. \<not> a + x \<le> 1}. g x \<noteq> g (a + y - 1)" |
49654 | 827 |
then have "\<exists>y\<in>{0..1} \<inter> {x. a + x \<le> 1}. g x = g (a + y)" |
49653 | 828 |
proof (cases "a \<le> x") |
829 |
case False |
|
49654 | 830 |
then show ?thesis |
49653 | 831 |
apply (rule_tac x="1 + x - a" in bexI) |
36583 | 832 |
using as(1,2) and as(3)[THEN bspec[where x="1 + x - a"]] and assms(1) |
49653 | 833 |
apply (auto simp add: field_simps atomize_not) |
834 |
done |
|
835 |
next |
|
836 |
case True |
|
53640 | 837 |
then show ?thesis |
838 |
using as(1-2) and assms(1) |
|
839 |
apply (rule_tac x="x - a" in bexI) |
|
840 |
apply (auto simp add: field_simps) |
|
841 |
done |
|
49653 | 842 |
qed |
843 |
} |
|
49654 | 844 |
then show ?thesis |
53640 | 845 |
using assms |
846 |
unfolding shiftpath_def path_image_def pathfinish_def pathstart_def |
|
847 |
by (auto simp add: image_iff) |
|
49653 | 848 |
qed |
849 |
||
36583 | 850 |
|
60420 | 851 |
subsection \<open>Special case of straight-line paths\<close> |
36583 | 852 |
|
49653 | 853 |
definition linepath :: "'a::real_normed_vector \<Rightarrow> 'a \<Rightarrow> real \<Rightarrow> 'a" |
854 |
where "linepath a b = (\<lambda>x. (1 - x) *\<^sub>R a + x *\<^sub>R b)" |
|
36583 | 855 |
|
53640 | 856 |
lemma pathstart_linepath[simp]: "pathstart (linepath a b) = a" |
857 |
unfolding pathstart_def linepath_def |
|
858 |
by auto |
|
36583 | 859 |
|
53640 | 860 |
lemma pathfinish_linepath[simp]: "pathfinish (linepath a b) = b" |
861 |
unfolding pathfinish_def linepath_def |
|
862 |
by auto |
|
36583 | 863 |
|
864 |
lemma continuous_linepath_at[intro]: "continuous (at x) (linepath a b)" |
|
53640 | 865 |
unfolding linepath_def |
866 |
by (intro continuous_intros) |
|
36583 | 867 |
|
868 |
lemma continuous_on_linepath[intro]: "continuous_on s (linepath a b)" |
|
53640 | 869 |
using continuous_linepath_at |
870 |
by (auto intro!: continuous_at_imp_continuous_on) |
|
36583 | 871 |
|
53640 | 872 |
lemma path_linepath[intro]: "path (linepath a b)" |
873 |
unfolding path_def |
|
874 |
by (rule continuous_on_linepath) |
|
36583 | 875 |
|
53640 | 876 |
lemma path_image_linepath[simp]: "path_image (linepath a b) = closed_segment a b" |
49653 | 877 |
unfolding path_image_def segment linepath_def |
60303 | 878 |
by auto |
49653 | 879 |
|
53640 | 880 |
lemma reversepath_linepath[simp]: "reversepath (linepath a b) = linepath b a" |
49653 | 881 |
unfolding reversepath_def linepath_def |
36583 | 882 |
by auto |
883 |
||
60303 | 884 |
lemma arc_linepath: |
49653 | 885 |
assumes "a \<noteq> b" |
60303 | 886 |
shows "arc (linepath a b)" |
36583 | 887 |
proof - |
53640 | 888 |
{ |
889 |
fix x y :: "real" |
|
36583 | 890 |
assume "x *\<^sub>R b + y *\<^sub>R a = x *\<^sub>R a + y *\<^sub>R b" |
53640 | 891 |
then have "(x - y) *\<^sub>R a = (x - y) *\<^sub>R b" |
892 |
by (simp add: algebra_simps) |
|
893 |
with assms have "x = y" |
|
894 |
by simp |
|
895 |
} |
|
49654 | 896 |
then show ?thesis |
60809
457abb82fb9e
the Cauchy integral theorem and related material
paulson <lp15@cam.ac.uk>
parents:
60420
diff
changeset
|
897 |
unfolding arc_def inj_on_def |
60303 | 898 |
by (simp add: path_linepath) (force simp: algebra_simps linepath_def) |
49653 | 899 |
qed |
36583 | 900 |
|
53640 | 901 |
lemma simple_path_linepath[intro]: "a \<noteq> b \<Longrightarrow> simple_path (linepath a b)" |
60303 | 902 |
by (simp add: arc_imp_simple_path arc_linepath) |
49653 | 903 |
|
36583 | 904 |
|
60420 | 905 |
subsection \<open>Bounding a point away from a path\<close> |
36583 | 906 |
|
907 |
lemma not_on_path_ball: |
|
908 |
fixes g :: "real \<Rightarrow> 'a::heine_borel" |
|
53640 | 909 |
assumes "path g" |
910 |
and "z \<notin> path_image g" |
|
911 |
shows "\<exists>e > 0. ball z e \<inter> path_image g = {}" |
|
49653 | 912 |
proof - |
913 |
obtain a where "a \<in> path_image g" "\<forall>y \<in> path_image g. dist z a \<le> dist z y" |
|
36583 | 914 |
using distance_attains_inf[OF _ path_image_nonempty, of g z] |
915 |
using compact_path_image[THEN compact_imp_closed, OF assms(1)] by auto |
|
49654 | 916 |
then show ?thesis |
49653 | 917 |
apply (rule_tac x="dist z a" in exI) |
918 |
using assms(2) |
|
919 |
apply (auto intro!: dist_pos_lt) |
|
920 |
done |
|
921 |
qed |
|
36583 | 922 |
|
923 |
lemma not_on_path_cball: |
|
924 |
fixes g :: "real \<Rightarrow> 'a::heine_borel" |
|
53640 | 925 |
assumes "path g" |
926 |
and "z \<notin> path_image g" |
|
49653 | 927 |
shows "\<exists>e>0. cball z e \<inter> (path_image g) = {}" |
928 |
proof - |
|
53640 | 929 |
obtain e where "ball z e \<inter> path_image g = {}" "e > 0" |
49653 | 930 |
using not_on_path_ball[OF assms] by auto |
53640 | 931 |
moreover have "cball z (e/2) \<subseteq> ball z e" |
60420 | 932 |
using \<open>e > 0\<close> by auto |
53640 | 933 |
ultimately show ?thesis |
934 |
apply (rule_tac x="e/2" in exI) |
|
935 |
apply auto |
|
936 |
done |
|
49653 | 937 |
qed |
938 |
||
36583 | 939 |
|
60420 | 940 |
subsection \<open>Path component, considered as a "joinability" relation (from Tom Hales)\<close> |
36583 | 941 |
|
49653 | 942 |
definition "path_component s x y \<longleftrightarrow> |
943 |
(\<exists>g. path g \<and> path_image g \<subseteq> s \<and> pathstart g = x \<and> pathfinish g = y)" |
|
36583 | 944 |
|
61426
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
945 |
abbreviation |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
946 |
"path_component_set s x \<equiv> Collect (path_component s x)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
947 |
|
53640 | 948 |
lemmas path_defs = path_def pathstart_def pathfinish_def path_image_def path_component_def |
36583 | 949 |
|
49653 | 950 |
lemma path_component_mem: |
951 |
assumes "path_component s x y" |
|
53640 | 952 |
shows "x \<in> s" and "y \<in> s" |
953 |
using assms |
|
954 |
unfolding path_defs |
|
955 |
by auto |
|
36583 | 956 |
|
49653 | 957 |
lemma path_component_refl: |
958 |
assumes "x \<in> s" |
|
959 |
shows "path_component s x x" |
|
960 |
unfolding path_defs |
|
961 |
apply (rule_tac x="\<lambda>u. x" in exI) |
|
53640 | 962 |
using assms |
56371
fb9ae0727548
extend continuous_intros; remove continuous_on_intros and isCont_intros
hoelzl
parents:
56188
diff
changeset
|
963 |
apply (auto intro!: continuous_intros) |
53640 | 964 |
done |
36583 | 965 |
|
966 |
lemma path_component_refl_eq: "path_component s x x \<longleftrightarrow> x \<in> s" |
|
49653 | 967 |
by (auto intro!: path_component_mem path_component_refl) |
36583 | 968 |
|
969 |
lemma path_component_sym: "path_component s x y \<Longrightarrow> path_component s y x" |
|
49653 | 970 |
using assms |
971 |
unfolding path_component_def |
|
972 |
apply (erule exE) |
|
973 |
apply (rule_tac x="reversepath g" in exI) |
|
974 |
apply auto |
|
975 |
done |
|
36583 | 976 |
|
49653 | 977 |
lemma path_component_trans: |
61426
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
978 |
assumes "path_component s x y" and "path_component s y z" |
49653 | 979 |
shows "path_component s x z" |
980 |
using assms |
|
981 |
unfolding path_component_def |
|
53640 | 982 |
apply (elim exE) |
49653 | 983 |
apply (rule_tac x="g +++ ga" in exI) |
984 |
apply (auto simp add: path_image_join) |
|
985 |
done |
|
36583 | 986 |
|
53640 | 987 |
lemma path_component_of_subset: "s \<subseteq> t \<Longrightarrow> path_component s x y \<Longrightarrow> path_component t x y" |
36583 | 988 |
unfolding path_component_def by auto |
989 |
||
61426
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
990 |
lemma path_connected_linepath: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
991 |
fixes s :: "'a::real_normed_vector set" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
992 |
shows "closed_segment a b \<subseteq> s \<Longrightarrow> path_component s a b" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
993 |
apply (simp add: path_component_def) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
994 |
apply (rule_tac x="linepath a b" in exI, auto) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
995 |
done |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
996 |
|
49653 | 997 |
|
60420 | 998 |
text \<open>Can also consider it as a set, as the name suggests.\<close> |
36583 | 999 |
|
49653 | 1000 |
lemma path_component_set: |
61426
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1001 |
"path_component_set s x = |
49653 | 1002 |
{y. (\<exists>g. path g \<and> path_image g \<subseteq> s \<and> pathstart g = x \<and> pathfinish g = y)}" |
61426
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1003 |
by (auto simp: path_component_def) |
36583 | 1004 |
|
61426
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1005 |
lemma path_component_subset: "path_component_set s x \<subseteq> s" |
60303 | 1006 |
by (auto simp add: path_component_mem(2)) |
36583 | 1007 |
|
61426
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1008 |
lemma path_component_eq_empty: "path_component_set s x = {} \<longleftrightarrow> x \<notin> s" |
60303 | 1009 |
using path_component_mem path_component_refl_eq |
1010 |
by fastforce |
|
36583 | 1011 |
|
61426
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1012 |
lemma path_component_mono: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1013 |
"s \<subseteq> t \<Longrightarrow> (path_component_set s x) \<subseteq> (path_component_set t x)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1014 |
by (simp add: Collect_mono path_component_of_subset) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1015 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1016 |
lemma path_component_eq: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1017 |
"y \<in> path_component_set s x \<Longrightarrow> path_component_set s y = path_component_set s x" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1018 |
by (metis (no_types, lifting) Collect_cong mem_Collect_eq path_component_sym path_component_trans) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1019 |
|
60420 | 1020 |
subsection \<open>Path connectedness of a space\<close> |
36583 | 1021 |
|
49653 | 1022 |
definition "path_connected s \<longleftrightarrow> |
53640 | 1023 |
(\<forall>x\<in>s. \<forall>y\<in>s. \<exists>g. path g \<and> path_image g \<subseteq> s \<and> pathstart g = x \<and> pathfinish g = y)" |
36583 | 1024 |
|
1025 |
lemma path_connected_component: "path_connected s \<longleftrightarrow> (\<forall>x\<in>s. \<forall>y\<in>s. path_component s x y)" |
|
1026 |
unfolding path_connected_def path_component_def by auto |
|
1027 |
||
61426
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1028 |
lemma path_connected_component_set: "path_connected s \<longleftrightarrow> (\<forall>x\<in>s. path_component_set s x = s)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1029 |
unfolding path_connected_component path_component_subset |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1030 |
using path_component_mem by blast |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1031 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1032 |
lemma path_component_maximal: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1033 |
"\<lbrakk>x \<in> t; path_connected t; t \<subseteq> s\<rbrakk> \<Longrightarrow> t \<subseteq> (path_component_set s x)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1034 |
by (metis path_component_mono path_connected_component_set) |
36583 | 1035 |
|
60420 | 1036 |
subsection \<open>Some useful lemmas about path-connectedness\<close> |
36583 | 1037 |
|
1038 |
lemma convex_imp_path_connected: |
|
1039 |
fixes s :: "'a::real_normed_vector set" |
|
53640 | 1040 |
assumes "convex s" |
1041 |
shows "path_connected s" |
|
49653 | 1042 |
unfolding path_connected_def |
53640 | 1043 |
apply rule |
1044 |
apply rule |
|
1045 |
apply (rule_tac x = "linepath x y" in exI) |
|
49653 | 1046 |
unfolding path_image_linepath |
1047 |
using assms [unfolded convex_contains_segment] |
|
1048 |
apply auto |
|
1049 |
done |
|
36583 | 1050 |
|
49653 | 1051 |
lemma path_connected_imp_connected: |
1052 |
assumes "path_connected s" |
|
1053 |
shows "connected s" |
|
1054 |
unfolding connected_def not_ex |
|
53640 | 1055 |
apply rule |
1056 |
apply rule |
|
1057 |
apply (rule ccontr) |
|
49653 | 1058 |
unfolding not_not |
53640 | 1059 |
apply (elim conjE) |
49653 | 1060 |
proof - |
1061 |
fix e1 e2 |
|
1062 |
assume as: "open e1" "open e2" "s \<subseteq> e1 \<union> e2" "e1 \<inter> e2 \<inter> s = {}" "e1 \<inter> s \<noteq> {}" "e2 \<inter> s \<noteq> {}" |
|
53640 | 1063 |
then obtain x1 x2 where obt:"x1 \<in> e1 \<inter> s" "x2 \<in> e2 \<inter> s" |
1064 |
by auto |
|
1065 |
then obtain g where g: "path g" "path_image g \<subseteq> s" "pathstart g = x1" "pathfinish g = x2" |
|
36583 | 1066 |
using assms[unfolded path_connected_def,rule_format,of x1 x2] by auto |
49653 | 1067 |
have *: "connected {0..1::real}" |
1068 |
by (auto intro!: convex_connected convex_real_interval) |
|
1069 |
have "{0..1} \<subseteq> {x \<in> {0..1}. g x \<in> e1} \<union> {x \<in> {0..1}. g x \<in> e2}" |
|
1070 |
using as(3) g(2)[unfolded path_defs] by blast |
|
1071 |
moreover have "{x \<in> {0..1}. g x \<in> e1} \<inter> {x \<in> {0..1}. g x \<in> e2} = {}" |
|
53640 | 1072 |
using as(4) g(2)[unfolded path_defs] |
1073 |
unfolding subset_eq |
|
1074 |
by auto |
|
49653 | 1075 |
moreover have "{x \<in> {0..1}. g x \<in> e1} \<noteq> {} \<and> {x \<in> {0..1}. g x \<in> e2} \<noteq> {}" |
53640 | 1076 |
using g(3,4)[unfolded path_defs] |
1077 |
using obt |
|
36583 | 1078 |
by (simp add: ex_in_conv [symmetric], metis zero_le_one order_refl) |
49653 | 1079 |
ultimately show False |
53640 | 1080 |
using *[unfolded connected_local not_ex, rule_format, |
1081 |
of "{x\<in>{0..1}. g x \<in> e1}" "{x\<in>{0..1}. g x \<in> e2}"] |
|
36583 | 1082 |
using continuous_open_in_preimage[OF g(1)[unfolded path_def] as(1)] |
49653 | 1083 |
using continuous_open_in_preimage[OF g(1)[unfolded path_def] as(2)] |
1084 |
by auto |
|
1085 |
qed |
|
36583 | 1086 |
|
1087 |
lemma open_path_component: |
|
53593 | 1088 |
fixes s :: "'a::real_normed_vector set" |
49653 | 1089 |
assumes "open s" |
61426
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1090 |
shows "open (path_component_set s x)" |
49653 | 1091 |
unfolding open_contains_ball |
1092 |
proof |
|
1093 |
fix y |
|
61426
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1094 |
assume as: "y \<in> path_component_set s x" |
49654 | 1095 |
then have "y \<in> s" |
49653 | 1096 |
apply - |
1097 |
apply (rule path_component_mem(2)) |
|
1098 |
unfolding mem_Collect_eq |
|
1099 |
apply auto |
|
1100 |
done |
|
53640 | 1101 |
then obtain e where e: "e > 0" "ball y e \<subseteq> s" |
1102 |
using assms[unfolded open_contains_ball] |
|
1103 |
by auto |
|
61426
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1104 |
show "\<exists>e > 0. ball y e \<subseteq> path_component_set s x" |
49653 | 1105 |
apply (rule_tac x=e in exI) |
60420 | 1106 |
apply (rule,rule \<open>e>0\<close>) |
53640 | 1107 |
apply rule |
49653 | 1108 |
unfolding mem_ball mem_Collect_eq |
1109 |
proof - |
|
1110 |
fix z |
|
1111 |
assume "dist y z < e" |
|
49654 | 1112 |
then show "path_component s x z" |
53640 | 1113 |
apply (rule_tac path_component_trans[of _ _ y]) |
1114 |
defer |
|
49653 | 1115 |
apply (rule path_component_of_subset[OF e(2)]) |
1116 |
apply (rule convex_imp_path_connected[OF convex_ball, unfolded path_connected_component, rule_format]) |
|
60420 | 1117 |
using \<open>e > 0\<close> as |
49653 | 1118 |
apply auto |
1119 |
done |
|
1120 |
qed |
|
1121 |
qed |
|
36583 | 1122 |
|
1123 |
lemma open_non_path_component: |
|
53593 | 1124 |
fixes s :: "'a::real_normed_vector set" |
49653 | 1125 |
assumes "open s" |
61426
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1126 |
shows "open (s - path_component_set s x)" |
49653 | 1127 |
unfolding open_contains_ball |
1128 |
proof |
|
1129 |
fix y |
|
61426
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1130 |
assume as: "y \<in> s - path_component_set s x" |
53640 | 1131 |
then obtain e where e: "e > 0" "ball y e \<subseteq> s" |
1132 |
using assms [unfolded open_contains_ball] |
|
1133 |
by auto |
|
61426
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1134 |
show "\<exists>e>0. ball y e \<subseteq> s - path_component_set s x" |
49653 | 1135 |
apply (rule_tac x=e in exI) |
53640 | 1136 |
apply rule |
60420 | 1137 |
apply (rule \<open>e>0\<close>) |
53640 | 1138 |
apply rule |
1139 |
apply rule |
|
1140 |
defer |
|
49653 | 1141 |
proof (rule ccontr) |
1142 |
fix z |
|
61426
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1143 |
assume "z \<in> ball y e" "\<not> z \<notin> path_component_set s x" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1144 |
then have "y \<in> path_component_set s x" |
60420 | 1145 |
unfolding not_not mem_Collect_eq using \<open>e>0\<close> |
49653 | 1146 |
apply - |
1147 |
apply (rule path_component_trans, assumption) |
|
1148 |
apply (rule path_component_of_subset[OF e(2)]) |
|
1149 |
apply (rule convex_imp_path_connected[OF convex_ball, unfolded path_connected_component, rule_format]) |
|
1150 |
apply auto |
|
1151 |
done |
|
53640 | 1152 |
then show False |
1153 |
using as by auto |
|
49653 | 1154 |
qed (insert e(2), auto) |
1155 |
qed |
|
36583 | 1156 |
|
1157 |
lemma connected_open_path_connected: |
|
53593 | 1158 |
fixes s :: "'a::real_normed_vector set" |
53640 | 1159 |
assumes "open s" |
1160 |
and "connected s" |
|
49653 | 1161 |
shows "path_connected s" |
1162 |
unfolding path_connected_component_set |
|
1163 |
proof (rule, rule, rule path_component_subset, rule) |
|
1164 |
fix x y |
|
53640 | 1165 |
assume "x \<in> s" and "y \<in> s" |
61426
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1166 |
show "y \<in> path_component_set s x" |
49653 | 1167 |
proof (rule ccontr) |
53640 | 1168 |
assume "\<not> ?thesis" |
61426
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1169 |
moreover have "path_component_set s x \<inter> s \<noteq> {}" |
60420 | 1170 |
using \<open>x \<in> s\<close> path_component_eq_empty path_component_subset[of s x] |
53640 | 1171 |
by auto |
49653 | 1172 |
ultimately |
1173 |
show False |
|
60420 | 1174 |
using \<open>y \<in> s\<close> open_non_path_component[OF assms(1)] open_path_component[OF assms(1)] |
53640 | 1175 |
using assms(2)[unfolded connected_def not_ex, rule_format, |
61426
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1176 |
of "path_component_set s x" "s - path_component_set s x"] |
49653 | 1177 |
by auto |
1178 |
qed |
|
1179 |
qed |
|
36583 | 1180 |
|
1181 |
lemma path_connected_continuous_image: |
|
53640 | 1182 |
assumes "continuous_on s f" |
1183 |
and "path_connected s" |
|
49653 | 1184 |
shows "path_connected (f ` s)" |
1185 |
unfolding path_connected_def |
|
1186 |
proof (rule, rule) |
|
1187 |
fix x' y' |
|
1188 |
assume "x' \<in> f ` s" "y' \<in> f ` s" |
|
53640 | 1189 |
then obtain x y where x: "x \<in> s" and y: "y \<in> s" and x': "x' = f x" and y': "y' = f y" |
1190 |
by auto |
|
1191 |
from x y obtain g where "path g \<and> path_image g \<subseteq> s \<and> pathstart g = x \<and> pathfinish g = y" |
|
1192 |
using assms(2)[unfolded path_connected_def] by fast |
|
49654 | 1193 |
then show "\<exists>g. path g \<and> path_image g \<subseteq> f ` s \<and> pathstart g = x' \<and> pathfinish g = y'" |
53640 | 1194 |
unfolding x' y' |
49653 | 1195 |
apply (rule_tac x="f \<circ> g" in exI) |
1196 |
unfolding path_defs |
|
51481
ef949192e5d6
move continuous_on_inv to HOL image (simplifies isCont_inverse_function)
hoelzl
parents:
51478
diff
changeset
|
1197 |
apply (intro conjI continuous_on_compose continuous_on_subset[OF assms(1)]) |
ef949192e5d6
move continuous_on_inv to HOL image (simplifies isCont_inverse_function)
hoelzl
parents:
51478
diff
changeset
|
1198 |
apply auto |
49653 | 1199 |
done |
1200 |
qed |
|
36583 | 1201 |
|
1202 |
lemma homeomorphic_path_connectedness: |
|
53640 | 1203 |
"s homeomorphic t \<Longrightarrow> path_connected s \<longleftrightarrow> path_connected t" |
49653 | 1204 |
unfolding homeomorphic_def homeomorphism_def |
53640 | 1205 |
apply (erule exE|erule conjE)+ |
49653 | 1206 |
apply rule |
53640 | 1207 |
apply (drule_tac f=f in path_connected_continuous_image) |
1208 |
prefer 3 |
|
49653 | 1209 |
apply (drule_tac f=g in path_connected_continuous_image) |
1210 |
apply auto |
|
1211 |
done |
|
36583 | 1212 |
|
1213 |
lemma path_connected_empty: "path_connected {}" |
|
1214 |
unfolding path_connected_def by auto |
|
1215 |
||
1216 |
lemma path_connected_singleton: "path_connected {a}" |
|
1217 |
unfolding path_connected_def pathstart_def pathfinish_def path_image_def |
|
53640 | 1218 |
apply clarify |
1219 |
apply (rule_tac x="\<lambda>x. a" in exI) |
|
1220 |
apply (simp add: image_constant_conv) |
|
36583 | 1221 |
apply (simp add: path_def continuous_on_const) |
1222 |
done |
|
1223 |
||
49653 | 1224 |
lemma path_connected_Un: |
53640 | 1225 |
assumes "path_connected s" |
1226 |
and "path_connected t" |
|
1227 |
and "s \<inter> t \<noteq> {}" |
|
49653 | 1228 |
shows "path_connected (s \<union> t)" |
1229 |
unfolding path_connected_component |
|
1230 |
proof (rule, rule) |
|
1231 |
fix x y |
|
1232 |
assume as: "x \<in> s \<union> t" "y \<in> s \<union> t" |
|
53640 | 1233 |
from assms(3) obtain z where "z \<in> s \<inter> t" |
1234 |
by auto |
|
49654 | 1235 |
then show "path_component (s \<union> t) x y" |
49653 | 1236 |
using as and assms(1-2)[unfolded path_connected_component] |
53640 | 1237 |
apply - |
49653 | 1238 |
apply (erule_tac[!] UnE)+ |
1239 |
apply (rule_tac[2-3] path_component_trans[of _ _ z]) |
|
1240 |
apply (auto simp add:path_component_of_subset [OF Un_upper1] path_component_of_subset[OF Un_upper2]) |
|
1241 |
done |
|
1242 |
qed |
|
36583 | 1243 |
|
37674
f86de9c00c47
convert theorem path_connected_sphere to euclidean_space class
huffman
parents:
37489
diff
changeset
|
1244 |
lemma path_connected_UNION: |
f86de9c00c47
convert theorem path_connected_sphere to euclidean_space class
huffman
parents:
37489
diff
changeset
|
1245 |
assumes "\<And>i. i \<in> A \<Longrightarrow> path_connected (S i)" |
49653 | 1246 |
and "\<And>i. i \<in> A \<Longrightarrow> z \<in> S i" |
37674
f86de9c00c47
convert theorem path_connected_sphere to euclidean_space class
huffman
parents:
37489
diff
changeset
|
1247 |
shows "path_connected (\<Union>i\<in>A. S i)" |
49653 | 1248 |
unfolding path_connected_component |
1249 |
proof clarify |
|
37674
f86de9c00c47
convert theorem path_connected_sphere to euclidean_space class
huffman
parents:
37489
diff
changeset
|
1250 |
fix x i y j |
f86de9c00c47
convert theorem path_connected_sphere to euclidean_space class
huffman
parents:
37489
diff
changeset
|
1251 |
assume *: "i \<in> A" "x \<in> S i" "j \<in> A" "y \<in> S j" |
49654 | 1252 |
then have "path_component (S i) x z" and "path_component (S j) z y" |
37674
f86de9c00c47
convert theorem path_connected_sphere to euclidean_space class
huffman
parents:
37489
diff
changeset
|
1253 |
using assms by (simp_all add: path_connected_component) |
49654 | 1254 |
then have "path_component (\<Union>i\<in>A. S i) x z" and "path_component (\<Union>i\<in>A. S i) z y" |
48125
602dc0215954
tuned proofs -- prefer direct "rotated" instead of old-style COMP;
wenzelm
parents:
44647
diff
changeset
|
1255 |
using *(1,3) by (auto elim!: path_component_of_subset [rotated]) |
49654 | 1256 |
then show "path_component (\<Union>i\<in>A. S i) x y" |
37674
f86de9c00c47
convert theorem path_connected_sphere to euclidean_space class
huffman
parents:
37489
diff
changeset
|
1257 |
by (rule path_component_trans) |
f86de9c00c47
convert theorem path_connected_sphere to euclidean_space class
huffman
parents:
37489
diff
changeset
|
1258 |
qed |
36583 | 1259 |
|
61426
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1260 |
lemma path_component_path_image_pathstart: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1261 |
assumes p: "path p" and x: "x \<in> path_image p" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1262 |
shows "path_component (path_image p) (pathstart p) x" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1263 |
using x |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1264 |
proof (clarsimp simp add: path_image_def) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1265 |
fix y |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1266 |
assume "x = p y" and y: "0 \<le> y" "y \<le> 1" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1267 |
show "path_component (p ` {0..1}) (pathstart p) (p y)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1268 |
proof (cases "y=0") |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1269 |
case True then show ?thesis |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1270 |
by (simp add: path_component_refl_eq pathstart_def) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1271 |
next |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1272 |
case False have "continuous_on {0..1} (p o (op*y))" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1273 |
apply (rule continuous_intros)+ |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1274 |
using p [unfolded path_def] y |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1275 |
apply (auto simp: mult_le_one intro: continuous_on_subset [of _ p]) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1276 |
done |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1277 |
then have "path (\<lambda>u. p (y * u))" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1278 |
by (simp add: path_def) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1279 |
then show ?thesis |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1280 |
apply (simp add: path_component_def) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1281 |
apply (rule_tac x = "\<lambda>u. p (y * u)" in exI) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1282 |
apply (intro conjI) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1283 |
using y False |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1284 |
apply (auto simp: mult_le_one pathstart_def pathfinish_def path_image_def) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1285 |
done |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1286 |
qed |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1287 |
qed |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1288 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1289 |
lemma path_connected_path_image: "path p \<Longrightarrow> path_connected(path_image p)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1290 |
unfolding path_connected_component |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1291 |
by (meson path_component_path_image_pathstart path_component_sym path_component_trans) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1292 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1293 |
lemma path_connected_path_component: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1294 |
"path_connected (path_component_set s x)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1295 |
proof - |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1296 |
{ fix y z |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1297 |
assume pa: "path_component s x y" "path_component s x z" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1298 |
then have pae: "path_component_set s x = path_component_set s y" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1299 |
using path_component_eq by auto |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1300 |
have yz: "path_component s y z" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1301 |
using pa path_component_sym path_component_trans by blast |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1302 |
then have "\<exists>g. path g \<and> path_image g \<subseteq> path_component_set s x \<and> pathstart g = y \<and> pathfinish g = z" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1303 |
apply (simp add: path_component_def, clarify) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1304 |
apply (rule_tac x=g in exI) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1305 |
by (simp add: pae path_component_maximal path_connected_path_image pathstart_in_path_image) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1306 |
} |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1307 |
then show ?thesis |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1308 |
by (simp add: path_connected_def) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1309 |
qed |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1310 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1311 |
lemma path_component: "path_component s x y \<longleftrightarrow> (\<exists>t. path_connected t \<and> t \<subseteq> s \<and> x \<in> t \<and> y \<in> t)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1312 |
apply (intro iffI) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1313 |
apply (metis path_connected_path_image path_defs(5) pathfinish_in_path_image pathstart_in_path_image) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1314 |
using path_component_of_subset path_connected_component by blast |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1315 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1316 |
lemma path_component_path_component [simp]: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1317 |
"path_component_set (path_component_set s x) x = path_component_set s x" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1318 |
proof (cases "x \<in> s") |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1319 |
case True show ?thesis |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1320 |
apply (rule subset_antisym) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1321 |
apply (simp add: path_component_subset) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1322 |
by (simp add: True path_component_maximal path_component_refl path_connected_path_component) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1323 |
next |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1324 |
case False then show ?thesis |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1325 |
by (metis False empty_iff path_component_eq_empty) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1326 |
qed |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1327 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1328 |
lemma path_component_subset_connected_component: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1329 |
"(path_component_set s x) \<subseteq> (connected_component_set s x)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1330 |
proof (cases "x \<in> s") |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1331 |
case True show ?thesis |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1332 |
apply (rule connected_component_maximal) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1333 |
apply (auto simp: True path_component_subset path_component_refl path_connected_imp_connected path_connected_path_component) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1334 |
done |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1335 |
next |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1336 |
case False then show ?thesis |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1337 |
using path_component_eq_empty by auto |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1338 |
qed |
49653 | 1339 |
|
60420 | 1340 |
subsection \<open>Sphere is path-connected\<close> |
37489
44e42d392c6e
Introduce a type class for euclidean spaces, port most lemmas from real^'n to this type class.
hoelzl
parents:
36583
diff
changeset
|
1341 |
|
36583 | 1342 |
lemma path_connected_punctured_universe: |
37674
f86de9c00c47
convert theorem path_connected_sphere to euclidean_space class
huffman
parents:
37489
diff
changeset
|
1343 |
assumes "2 \<le> DIM('a::euclidean_space)" |
61426
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1344 |
shows "path_connected (- {a::'a})" |
49653 | 1345 |
proof - |
50526
899c9c4e4a4c
Remove the indexed basis from the definition of euclidean spaces and only use the set of Basis vectors
hoelzl
parents:
49654
diff
changeset
|
1346 |
let ?A = "{x::'a. \<exists>i\<in>Basis. x \<bullet> i < a \<bullet> i}" |
899c9c4e4a4c
Remove the indexed basis from the definition of euclidean spaces and only use the set of Basis vectors
hoelzl
parents:
49654
diff
changeset
|
1347 |
let ?B = "{x::'a. \<exists>i\<in>Basis. a \<bullet> i < x \<bullet> i}" |
36583 | 1348 |
|
49653 | 1349 |
have A: "path_connected ?A" |
1350 |
unfolding Collect_bex_eq |
|
37674
f86de9c00c47
convert theorem path_connected_sphere to euclidean_space class
huffman
parents:
37489
diff
changeset
|
1351 |
proof (rule path_connected_UNION) |
50526
899c9c4e4a4c
Remove the indexed basis from the definition of euclidean spaces and only use the set of Basis vectors
hoelzl
parents:
49654
diff
changeset
|
1352 |
fix i :: 'a |
899c9c4e4a4c
Remove the indexed basis from the definition of euclidean spaces and only use the set of Basis vectors
hoelzl
parents:
49654
diff
changeset
|
1353 |
assume "i \<in> Basis" |
53640 | 1354 |
then show "(\<Sum>i\<in>Basis. (a \<bullet> i - 1)*\<^sub>R i) \<in> {x::'a. x \<bullet> i < a \<bullet> i}" |
1355 |
by simp |
|
50526
899c9c4e4a4c
Remove the indexed basis from the definition of euclidean spaces and only use the set of Basis vectors
hoelzl
parents:
49654
diff
changeset
|
1356 |
show "path_connected {x. x \<bullet> i < a \<bullet> i}" |
899c9c4e4a4c
Remove the indexed basis from the definition of euclidean spaces and only use the set of Basis vectors
hoelzl
parents:
49654
diff
changeset
|
1357 |
using convex_imp_path_connected [OF convex_halfspace_lt, of i "a \<bullet> i"] |
899c9c4e4a4c
Remove the indexed basis from the definition of euclidean spaces and only use the set of Basis vectors
hoelzl
parents:
49654
diff
changeset
|
1358 |
by (simp add: inner_commute) |
37674
f86de9c00c47
convert theorem path_connected_sphere to euclidean_space class
huffman
parents:
37489
diff
changeset
|
1359 |
qed |
53640 | 1360 |
have B: "path_connected ?B" |
1361 |
unfolding Collect_bex_eq |
|
37674
f86de9c00c47
convert theorem path_connected_sphere to euclidean_space class
huffman
parents:
37489
diff
changeset
|
1362 |
proof (rule path_connected_UNION) |
50526
899c9c4e4a4c
Remove the indexed basis from the definition of euclidean spaces and only use the set of Basis vectors
hoelzl
parents:
49654
diff
changeset
|
1363 |
fix i :: 'a |
899c9c4e4a4c
Remove the indexed basis from the definition of euclidean spaces and only use the set of Basis vectors
hoelzl
parents:
49654
diff
changeset
|
1364 |
assume "i \<in> Basis" |
53640 | 1365 |
then show "(\<Sum>i\<in>Basis. (a \<bullet> i + 1) *\<^sub>R i) \<in> {x::'a. a \<bullet> i < x \<bullet> i}" |
1366 |
by simp |
|
50526
899c9c4e4a4c
Remove the indexed basis from the definition of euclidean spaces and only use the set of Basis vectors
hoelzl
parents:
49654
diff
changeset
|
1367 |
show "path_connected {x. a \<bullet> i < x \<bullet> i}" |
899c9c4e4a4c
Remove the indexed basis from the definition of euclidean spaces and only use the set of Basis vectors
hoelzl
parents:
49654
diff
changeset
|
1368 |
using convex_imp_path_connected [OF convex_halfspace_gt, of "a \<bullet> i" i] |
899c9c4e4a4c
Remove the indexed basis from the definition of euclidean spaces and only use the set of Basis vectors
hoelzl
parents:
49654
diff
changeset
|
1369 |
by (simp add: inner_commute) |
37674
f86de9c00c47
convert theorem path_connected_sphere to euclidean_space class
huffman
parents:
37489
diff
changeset
|
1370 |
qed |
53640 | 1371 |
obtain S :: "'a set" where "S \<subseteq> Basis" and "card S = Suc (Suc 0)" |
1372 |
using ex_card[OF assms] |
|
1373 |
by auto |
|
1374 |
then obtain b0 b1 :: 'a where "b0 \<in> Basis" and "b1 \<in> Basis" and "b0 \<noteq> b1" |
|
50526
899c9c4e4a4c
Remove the indexed basis from the definition of euclidean spaces and only use the set of Basis vectors
hoelzl
parents:
49654
diff
changeset
|
1375 |
unfolding card_Suc_eq by auto |
53640 | 1376 |
then have "a + b0 - b1 \<in> ?A \<inter> ?B" |
1377 |
by (auto simp: inner_simps inner_Basis) |
|
1378 |
then have "?A \<inter> ?B \<noteq> {}" |
|
1379 |
by fast |
|
37674
f86de9c00c47
convert theorem path_connected_sphere to euclidean_space class
huffman
parents:
37489
diff
changeset
|
1380 |
with A B have "path_connected (?A \<union> ?B)" |
f86de9c00c47
convert theorem path_connected_sphere to euclidean_space class
huffman
parents:
37489
diff
changeset
|
1381 |
by (rule path_connected_Un) |
50526
899c9c4e4a4c
Remove the indexed basis from the definition of euclidean spaces and only use the set of Basis vectors
hoelzl
parents:
49654
diff
changeset
|
1382 |
also have "?A \<union> ?B = {x. \<exists>i\<in>Basis. x \<bullet> i \<noteq> a \<bullet> i}" |
37674
f86de9c00c47
convert theorem path_connected_sphere to euclidean_space class
huffman
parents:
37489
diff
changeset
|
1383 |
unfolding neq_iff bex_disj_distrib Collect_disj_eq .. |
f86de9c00c47
convert theorem path_connected_sphere to euclidean_space class
huffman
parents:
37489
diff
changeset
|
1384 |
also have "\<dots> = {x. x \<noteq> a}" |
53640 | 1385 |
unfolding euclidean_eq_iff [where 'a='a] |
1386 |
by (simp add: Bex_def) |
|
61426
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1387 |
also have "\<dots> = - {a}" |
53640 | 1388 |
by auto |
37674
f86de9c00c47
convert theorem path_connected_sphere to euclidean_space class
huffman
parents:
37489
diff
changeset
|
1389 |
finally show ?thesis . |
f86de9c00c47
convert theorem path_connected_sphere to euclidean_space class
huffman
parents:
37489
diff
changeset
|
1390 |
qed |
36583 | 1391 |
|
37674
f86de9c00c47
convert theorem path_connected_sphere to euclidean_space class
huffman
parents:
37489
diff
changeset
|
1392 |
lemma path_connected_sphere: |
f86de9c00c47
convert theorem path_connected_sphere to euclidean_space class
huffman
parents:
37489
diff
changeset
|
1393 |
assumes "2 \<le> DIM('a::euclidean_space)" |
53640 | 1394 |
shows "path_connected {x::'a. norm (x - a) = r}" |
37674
f86de9c00c47
convert theorem path_connected_sphere to euclidean_space class
huffman
parents:
37489
diff
changeset
|
1395 |
proof (rule linorder_cases [of r 0]) |
49653 | 1396 |
assume "r < 0" |
53640 | 1397 |
then have "{x::'a. norm(x - a) = r} = {}" |
1398 |
by auto |
|
1399 |
then show ?thesis |
|
1400 |
using path_connected_empty by simp |
|
37674
f86de9c00c47
convert theorem path_connected_sphere to euclidean_space class
huffman
parents:
37489
diff
changeset
|
1401 |
next |
f86de9c00c47
convert theorem path_connected_sphere to euclidean_space class
huffman
parents:
37489
diff
changeset
|
1402 |
assume "r = 0" |
53640 | 1403 |
then show ?thesis |
1404 |
using path_connected_singleton by simp |
|
37674
f86de9c00c47
convert theorem path_connected_sphere to euclidean_space class
huffman
parents:
37489
diff
changeset
|
1405 |
next |
f86de9c00c47
convert theorem path_connected_sphere to euclidean_space class
huffman
parents:
37489
diff
changeset
|
1406 |
assume r: "0 < r" |
53640 | 1407 |
have *: "{x::'a. norm(x - a) = r} = (\<lambda>x. a + r *\<^sub>R x) ` {x. norm x = 1}" |
1408 |
apply (rule set_eqI) |
|
1409 |
apply rule |
|
49653 | 1410 |
unfolding image_iff |
1411 |
apply (rule_tac x="(1/r) *\<^sub>R (x - a)" in bexI) |
|
1412 |
unfolding mem_Collect_eq norm_scaleR |
|
53640 | 1413 |
using r |
49653 | 1414 |
apply (auto simp add: scaleR_right_diff_distrib) |
1415 |
done |
|
61426
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1416 |
have **: "{x::'a. norm x = 1} = (\<lambda>x. (1/norm x) *\<^sub>R x) ` (- {0})" |
53640 | 1417 |
apply (rule set_eqI) |
1418 |
apply rule |
|
49653 | 1419 |
unfolding image_iff |
1420 |
apply (rule_tac x=x in bexI) |
|
1421 |
unfolding mem_Collect_eq |
|
53640 | 1422 |
apply (auto split: split_if_asm) |
49653 | 1423 |
done |
61426
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1424 |
have "continuous_on (- {0}) (\<lambda>x::'a. 1 / norm x)" |
59557 | 1425 |
by (auto intro!: continuous_intros) |
53640 | 1426 |
then show ?thesis |
1427 |
unfolding * ** |
|
1428 |
using path_connected_punctured_universe[OF assms] |
|
56371
fb9ae0727548
extend continuous_intros; remove continuous_on_intros and isCont_intros
hoelzl
parents:
56188
diff
changeset
|
1429 |
by (auto intro!: path_connected_continuous_image continuous_intros) |
37674
f86de9c00c47
convert theorem path_connected_sphere to euclidean_space class
huffman
parents:
37489
diff
changeset
|
1430 |
qed |
36583 | 1431 |
|
61426
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1432 |
corollary connected_sphere: "2 \<le> DIM('a::euclidean_space) \<Longrightarrow> connected {x::'a. norm (x - a) = r}" |
53640 | 1433 |
using path_connected_sphere path_connected_imp_connected |
1434 |
by auto |
|
36583 | 1435 |
|
61426
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1436 |
corollary path_connected_complement_bounded_convex: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1437 |
fixes s :: "'a :: euclidean_space set" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1438 |
assumes "bounded s" "convex s" and 2: "2 \<le> DIM('a)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1439 |
shows "path_connected (- s)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1440 |
proof (cases "s={}") |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1441 |
case True then show ?thesis |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1442 |
using convex_imp_path_connected by auto |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1443 |
next |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1444 |
case False |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1445 |
then obtain a where "a \<in> s" by auto |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1446 |
{ fix x y assume "x \<notin> s" "y \<notin> s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1447 |
then have "x \<noteq> a" "y \<noteq> a" using `a \<in> s` by auto |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1448 |
then have bxy: "bounded(insert x (insert y s))" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1449 |
by (simp add: `bounded s`) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1450 |
then obtain B::real where B: "0 < B" and Bx: "norm (a - x) < B" and By: "norm (a - y) < B" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1451 |
and "s \<subseteq> ball a B" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1452 |
using bounded_subset_ballD [OF bxy, of a] by (auto simp: dist_norm) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1453 |
def C == "B / norm(x - a)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1454 |
{ fix u |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1455 |
assume u: "(1 - u) *\<^sub>R x + u *\<^sub>R (a + C *\<^sub>R (x - a)) \<in> s" and "0 \<le> u" "u \<le> 1" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1456 |
have CC: "1 \<le> 1 + (C - 1) * u" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1457 |
using `x \<noteq> a` `0 \<le> u` |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1458 |
apply (simp add: C_def divide_simps norm_minus_commute) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1459 |
by (metis Bx diff_le_iff(1) less_eq_real_def mult_nonneg_nonneg) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1460 |
have *: "\<And>v. (1 - u) *\<^sub>R x + u *\<^sub>R (a + v *\<^sub>R (x - a)) = a + (1 + (v - 1) * u) *\<^sub>R (x - a)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1461 |
by (simp add: algebra_simps) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1462 |
have "a + ((1 / (1 + C * u - u)) *\<^sub>R x + ((u / (1 + C * u - u)) *\<^sub>R a + (C * u / (1 + C * u - u)) *\<^sub>R x)) = |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1463 |
(1 + (u / (1 + C * u - u))) *\<^sub>R a + ((1 / (1 + C * u - u)) + (C * u / (1 + C * u - u))) *\<^sub>R x" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1464 |
by (simp add: algebra_simps) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1465 |
also have "... = (1 + (u / (1 + C * u - u))) *\<^sub>R a + (1 + (u / (1 + C * u - u))) *\<^sub>R x" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1466 |
using CC by (simp add: field_simps) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1467 |
also have "... = x + (1 + (u / (1 + C * u - u))) *\<^sub>R a + (u / (1 + C * u - u)) *\<^sub>R x" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1468 |
by (simp add: algebra_simps) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1469 |
also have "... = x + ((1 / (1 + C * u - u)) *\<^sub>R a + |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1470 |
((u / (1 + C * u - u)) *\<^sub>R x + (C * u / (1 + C * u - u)) *\<^sub>R a))" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1471 |
using CC by (simp add: field_simps) (simp add: add_divide_distrib scaleR_add_left) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1472 |
finally have xeq: "(1 - 1 / (1 + (C - 1) * u)) *\<^sub>R a + (1 / (1 + (C - 1) * u)) *\<^sub>R (a + (1 + (C - 1) * u) *\<^sub>R (x - a)) = x" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1473 |
by (simp add: algebra_simps) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1474 |
have False |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1475 |
using `convex s` |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1476 |
apply (simp add: convex_alt) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1477 |
apply (drule_tac x=a in bspec) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1478 |
apply (rule `a \<in> s`) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1479 |
apply (drule_tac x="a + (1 + (C - 1) * u) *\<^sub>R (x - a)" in bspec) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1480 |
using u apply (simp add: *) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1481 |
apply (drule_tac x="1 / (1 + (C - 1) * u)" in spec) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1482 |
using `x \<noteq> a` `x \<notin> s` `0 \<le> u` CC |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1483 |
apply (auto simp: xeq) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1484 |
done |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1485 |
} |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1486 |
then have pcx: "path_component (- s) x (a + C *\<^sub>R (x - a))" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1487 |
by (force simp: closed_segment_def intro!: path_connected_linepath) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1488 |
def D == "B / norm(y - a)" --{*massive duplication with the proof above*} |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1489 |
{ fix u |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1490 |
assume u: "(1 - u) *\<^sub>R y + u *\<^sub>R (a + D *\<^sub>R (y - a)) \<in> s" and "0 \<le> u" "u \<le> 1" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1491 |
have DD: "1 \<le> 1 + (D - 1) * u" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1492 |
using `y \<noteq> a` `0 \<le> u` |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1493 |
apply (simp add: D_def divide_simps norm_minus_commute) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1494 |
by (metis By diff_le_iff(1) less_eq_real_def mult_nonneg_nonneg) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1495 |
have *: "\<And>v. (1 - u) *\<^sub>R y + u *\<^sub>R (a + v *\<^sub>R (y - a)) = a + (1 + (v - 1) * u) *\<^sub>R (y - a)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1496 |
by (simp add: algebra_simps) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1497 |
have "a + ((1 / (1 + D * u - u)) *\<^sub>R y + ((u / (1 + D * u - u)) *\<^sub>R a + (D * u / (1 + D * u - u)) *\<^sub>R y)) = |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1498 |
(1 + (u / (1 + D * u - u))) *\<^sub>R a + ((1 / (1 + D * u - u)) + (D * u / (1 + D * u - u))) *\<^sub>R y" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1499 |
by (simp add: algebra_simps) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1500 |
also have "... = (1 + (u / (1 + D * u - u))) *\<^sub>R a + (1 + (u / (1 + D * u - u))) *\<^sub>R y" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1501 |
using DD by (simp add: field_simps) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1502 |
also have "... = y + (1 + (u / (1 + D * u - u))) *\<^sub>R a + (u / (1 + D * u - u)) *\<^sub>R y" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1503 |
by (simp add: algebra_simps) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1504 |
also have "... = y + ((1 / (1 + D * u - u)) *\<^sub>R a + |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1505 |
((u / (1 + D * u - u)) *\<^sub>R y + (D * u / (1 + D * u - u)) *\<^sub>R a))" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1506 |
using DD by (simp add: field_simps) (simp add: add_divide_distrib scaleR_add_left) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1507 |
finally have xeq: "(1 - 1 / (1 + (D - 1) * u)) *\<^sub>R a + (1 / (1 + (D - 1) * u)) *\<^sub>R (a + (1 + (D - 1) * u) *\<^sub>R (y - a)) = y" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1508 |
by (simp add: algebra_simps) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1509 |
have False |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1510 |
using `convex s` |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1511 |
apply (simp add: convex_alt) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1512 |
apply (drule_tac x=a in bspec) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1513 |
apply (rule `a \<in> s`) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1514 |
apply (drule_tac x="a + (1 + (D - 1) * u) *\<^sub>R (y - a)" in bspec) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1515 |
using u apply (simp add: *) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1516 |
apply (drule_tac x="1 / (1 + (D - 1) * u)" in spec) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1517 |
using `y \<noteq> a` `y \<notin> s` `0 \<le> u` DD |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1518 |
apply (auto simp: xeq) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1519 |
done |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1520 |
} |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1521 |
then have pdy: "path_component (- s) y (a + D *\<^sub>R (y - a))" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1522 |
by (force simp: closed_segment_def intro!: path_connected_linepath) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1523 |
have pyx: "path_component (- s) (a + D *\<^sub>R (y - a)) (a + C *\<^sub>R (x - a))" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1524 |
apply (rule path_component_of_subset [of "{x. norm(x - a) = B}"]) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1525 |
using `s \<subseteq> ball a B` |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1526 |
apply (force simp: ball_def dist_norm norm_minus_commute) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1527 |
apply (rule path_connected_sphere [OF 2, of a B, simplified path_connected_component, rule_format]) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1528 |
using `x \<noteq> a` using `y \<noteq> a` B apply (auto simp: C_def D_def) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1529 |
done |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1530 |
have "path_component (- s) x y" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1531 |
by (metis path_component_trans path_component_sym pcx pdy pyx) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1532 |
} |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1533 |
then show ?thesis |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1534 |
by (auto simp: path_connected_component) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1535 |
qed |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1536 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1537 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1538 |
lemma connected_complement_bounded_convex: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1539 |
fixes s :: "'a :: euclidean_space set" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1540 |
assumes "bounded s" "convex s" "2 \<le> DIM('a)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1541 |
shows "connected (- s)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1542 |
using path_connected_complement_bounded_convex [OF assms] path_connected_imp_connected by blast |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1543 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1544 |
lemma connected_diff_ball: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1545 |
fixes s :: "'a :: euclidean_space set" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1546 |
assumes "connected s" "cball a r \<subseteq> s" "2 \<le> DIM('a)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1547 |
shows "connected (s - ball a r)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1548 |
apply (rule connected_diff_open_from_closed [OF ball_subset_cball]) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1549 |
using assms connected_sphere |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1550 |
apply (auto simp: cball_diff_eq_sphere dist_norm) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1551 |
done |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1552 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1553 |
subsection\<open>Relations between components and path components\<close> |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1554 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1555 |
lemma open_connected_component: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1556 |
fixes s :: "'a::real_normed_vector set" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1557 |
shows "open s \<Longrightarrow> open (connected_component_set s x)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1558 |
apply (simp add: open_contains_ball, clarify) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1559 |
apply (rename_tac y) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1560 |
apply (drule_tac x=y in bspec) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1561 |
apply (simp add: connected_component_in, clarify) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1562 |
apply (rule_tac x=e in exI) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1563 |
by (metis mem_Collect_eq connected_component_eq connected_component_maximal centre_in_ball connected_ball) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1564 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1565 |
corollary open_components: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1566 |
fixes s :: "'a::real_normed_vector set" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1567 |
shows "\<lbrakk>open u; s \<in> components u\<rbrakk> \<Longrightarrow> open s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1568 |
by (simp add: components_iff) (metis open_connected_component) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1569 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1570 |
lemma in_closure_connected_component: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1571 |
fixes s :: "'a::real_normed_vector set" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1572 |
assumes x: "x \<in> s" and s: "open s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1573 |
shows "x \<in> closure (connected_component_set s y) \<longleftrightarrow> x \<in> connected_component_set s y" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1574 |
proof - |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1575 |
{ assume "x \<in> closure (connected_component_set s y)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1576 |
moreover have "x \<in> connected_component_set s x" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1577 |
using x by simp |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1578 |
ultimately have "x \<in> connected_component_set s y" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1579 |
using s by (meson Compl_disjoint closure_iff_nhds_not_empty connected_component_disjoint disjoint_eq_subset_Compl open_connected_component) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1580 |
} |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1581 |
then show ?thesis |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1582 |
by (auto simp: closure_def) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1583 |
qed |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1584 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1585 |
subsection\<open>Existence of unbounded components\<close> |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1586 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1587 |
lemma cobounded_unbounded_component: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1588 |
fixes s :: "'a :: euclidean_space set" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1589 |
assumes "bounded (-s)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1590 |
shows "\<exists>x. x \<in> s \<and> ~ bounded (connected_component_set s x)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1591 |
proof - |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1592 |
obtain i::'a where i: "i \<in> Basis" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1593 |
using nonempty_Basis by blast |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1594 |
obtain B where B: "B>0" "-s \<subseteq> ball 0 B" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1595 |
using bounded_subset_ballD [OF assms, of 0] by auto |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1596 |
then have *: "\<And>x. B \<le> norm x \<Longrightarrow> x \<in> s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1597 |
by (force simp add: ball_def dist_norm) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1598 |
have unbounded_inner: "~ bounded {x. inner i x \<ge> B}" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1599 |
apply (auto simp: bounded_def dist_norm) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1600 |
apply (rule_tac x="x + (max B e + 1 + \<bar>i \<bullet> x\<bar>) *\<^sub>R i" in exI) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1601 |
apply simp |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1602 |
using i |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1603 |
apply (auto simp: algebra_simps) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1604 |
done |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1605 |
have **: "{x. B \<le> i \<bullet> x} \<subseteq> connected_component_set s (B *\<^sub>R i)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1606 |
apply (rule connected_component_maximal) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1607 |
apply (auto simp: i intro: convex_connected convex_halfspace_ge [of B]) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1608 |
apply (rule *) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1609 |
apply (rule order_trans [OF _ Basis_le_norm [OF i]]) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1610 |
by (simp add: inner_commute) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1611 |
have "B *\<^sub>R i \<in> s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1612 |
by (rule *) (simp add: norm_Basis [OF i]) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1613 |
then show ?thesis |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1614 |
apply (rule_tac x="B *\<^sub>R i" in exI, clarify) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1615 |
apply (frule bounded_subset [of _ "{x. B \<le> i \<bullet> x}", OF _ **]) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1616 |
using unbounded_inner apply blast |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1617 |
done |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1618 |
qed |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1619 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1620 |
lemma cobounded_unique_unbounded_component: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1621 |
fixes s :: "'a :: euclidean_space set" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1622 |
assumes bs: "bounded (-s)" and "2 \<le> DIM('a)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1623 |
and bo: "~ bounded(connected_component_set s x)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1624 |
"~ bounded(connected_component_set s y)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1625 |
shows "connected_component_set s x = connected_component_set s y" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1626 |
proof - |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1627 |
obtain i::'a where i: "i \<in> Basis" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1628 |
using nonempty_Basis by blast |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1629 |
obtain B where B: "B>0" "-s \<subseteq> ball 0 B" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1630 |
using bounded_subset_ballD [OF bs, of 0] by auto |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1631 |
then have *: "\<And>x. B \<le> norm x \<Longrightarrow> x \<in> s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1632 |
by (force simp add: ball_def dist_norm) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1633 |
have ccb: "connected (- ball 0 B :: 'a set)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1634 |
using assms by (auto intro: connected_complement_bounded_convex) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1635 |
obtain x' where x': "connected_component s x x'" "norm x' > B" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1636 |
using bo [unfolded bounded_def dist_norm, simplified, rule_format] |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1637 |
by (metis diff_zero norm_minus_commute not_less) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1638 |
obtain y' where y': "connected_component s y y'" "norm y' > B" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1639 |
using bo [unfolded bounded_def dist_norm, simplified, rule_format] |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1640 |
by (metis diff_zero norm_minus_commute not_less) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1641 |
have x'y': "connected_component s x' y'" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1642 |
apply (simp add: connected_component_def) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1643 |
apply (rule_tac x="- ball 0 B" in exI) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1644 |
using x' y' |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1645 |
apply (auto simp: ccb dist_norm *) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1646 |
done |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1647 |
show ?thesis |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1648 |
apply (rule connected_component_eq) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1649 |
using x' y' x'y' |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1650 |
by (metis (no_types, lifting) connected_component_eq_empty connected_component_eq_eq connected_component_idemp connected_component_in) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1651 |
qed |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1652 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1653 |
lemma cobounded_unbounded_components: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1654 |
fixes s :: "'a :: euclidean_space set" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1655 |
shows "bounded (-s) \<Longrightarrow> \<exists>c. c \<in> components s \<and> ~bounded c" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1656 |
by (metis cobounded_unbounded_component components_def imageI) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1657 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1658 |
lemma cobounded_unique_unbounded_components: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1659 |
fixes s :: "'a :: euclidean_space set" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1660 |
shows "\<lbrakk>bounded (- s); c \<in> components s; \<not> bounded c; c' \<in> components s; \<not> bounded c'; 2 \<le> DIM('a)\<rbrakk> \<Longrightarrow> c' = c" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1661 |
unfolding components_iff |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1662 |
by (metis cobounded_unique_unbounded_component) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1663 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1664 |
lemma cobounded_has_bounded_component: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1665 |
fixes s :: "'a :: euclidean_space set" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1666 |
shows "\<lbrakk>bounded (- s); ~connected s; 2 \<le> DIM('a)\<rbrakk> \<Longrightarrow> \<exists>c. c \<in> components s \<and> bounded c" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1667 |
by (meson cobounded_unique_unbounded_components connected_eq_connected_components_eq) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1668 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1669 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1670 |
subsection\<open>The "inside" and "outside" of a set\<close> |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1671 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1672 |
text\<open>The inside comprises the points in a bounded connected component of the set's complement. |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1673 |
The outside comprises the points in unbounded connected component of the complement.\<close> |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1674 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1675 |
definition inside where |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1676 |
"inside s \<equiv> {x. (x \<notin> s) \<and> bounded(connected_component_set ( - s) x)}" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1677 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1678 |
definition outside where |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1679 |
"outside s \<equiv> -s \<inter> {x. ~ bounded(connected_component_set (- s) x)}" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1680 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1681 |
lemma outside: "outside s = {x. ~ bounded(connected_component_set (- s) x)}" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1682 |
by (auto simp: outside_def) (metis Compl_iff bounded_empty connected_component_eq_empty) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1683 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1684 |
lemma inside_no_overlap [simp]: "inside s \<inter> s = {}" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1685 |
by (auto simp: inside_def) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1686 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1687 |
lemma outside_no_overlap [simp]: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1688 |
"outside s \<inter> s = {}" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1689 |
by (auto simp: outside_def) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1690 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1691 |
lemma inside_inter_outside [simp]: "inside s \<inter> outside s = {}" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1692 |
by (auto simp: inside_def outside_def) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1693 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1694 |
lemma inside_union_outside [simp]: "inside s \<union> outside s = (- s)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1695 |
by (auto simp: inside_def outside_def) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1696 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1697 |
lemma inside_eq_outside: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1698 |
"inside s = outside s \<longleftrightarrow> s = UNIV" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1699 |
by (auto simp: inside_def outside_def) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1700 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1701 |
lemma inside_outside: "inside s = (- (s \<union> outside s))" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1702 |
by (force simp add: inside_def outside) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1703 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1704 |
lemma outside_inside: "outside s = (- (s \<union> inside s))" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1705 |
by (auto simp: inside_outside) (metis IntI equals0D outside_no_overlap) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1706 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1707 |
lemma union_with_inside: "s \<union> inside s = - outside s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1708 |
by (auto simp: inside_outside) (simp add: outside_inside) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1709 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1710 |
lemma union_with_outside: "s \<union> outside s = - inside s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1711 |
by (simp add: inside_outside) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1712 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1713 |
lemma outside_mono: "s \<subseteq> t \<Longrightarrow> outside t \<subseteq> outside s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1714 |
by (auto simp: outside bounded_subset connected_component_mono) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1715 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1716 |
lemma inside_mono: "s \<subseteq> t \<Longrightarrow> inside s - t \<subseteq> inside t" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1717 |
by (auto simp: inside_def bounded_subset connected_component_mono) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1718 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1719 |
lemma segment_bound_lemma: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1720 |
fixes u::real |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1721 |
assumes "x \<ge> B" "y \<ge> B" "0 \<le> u" "u \<le> 1" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1722 |
shows "(1 - u) * x + u * y \<ge> B" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1723 |
proof - |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1724 |
obtain dx dy where "dx \<ge> 0" "dy \<ge> 0" "x = B + dx" "y = B + dy" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1725 |
using assms by auto (metis add.commute diff_add_cancel) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1726 |
with `0 \<le> u` `u \<le> 1` show ?thesis |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1727 |
by (simp add: add_increasing2 mult_left_le field_simps) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1728 |
qed |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1729 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1730 |
lemma cobounded_outside: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1731 |
fixes s :: "'a :: real_normed_vector set" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1732 |
assumes "bounded s" shows "bounded (- outside s)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1733 |
proof - |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1734 |
obtain B where B: "B>0" "s \<subseteq> ball 0 B" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1735 |
using bounded_subset_ballD [OF assms, of 0] by auto |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1736 |
{ fix x::'a and C::real |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1737 |
assume Bno: "B \<le> norm x" and C: "0 < C" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1738 |
have "\<exists>y. connected_component (- s) x y \<and> norm y > C" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1739 |
proof (cases "x = 0") |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1740 |
case True with B Bno show ?thesis by force |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1741 |
next |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1742 |
case False with B C show ?thesis |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1743 |
apply (rule_tac x="((B+C)/norm x) *\<^sub>R x" in exI) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1744 |
apply (simp add: connected_component_def) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1745 |
apply (rule_tac x="closed_segment x (((B+C)/norm x) *\<^sub>R x)" in exI) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1746 |
apply simp |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1747 |
apply (rule_tac y="- ball 0 B" in order_trans) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1748 |
prefer 2 apply force |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1749 |
apply (simp add: closed_segment_def ball_def dist_norm, clarify) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1750 |
apply (simp add: real_vector_class.scaleR_add_left [symmetric] divide_simps) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1751 |
using segment_bound_lemma [of B "norm x" "B+C" ] Bno |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1752 |
by (meson le_add_same_cancel1 less_eq_real_def not_le) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1753 |
qed |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1754 |
} |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1755 |
then show ?thesis |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1756 |
apply (simp add: outside_def assms) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1757 |
apply (rule bounded_subset [OF bounded_ball [of 0 B]]) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1758 |
apply (force simp add: dist_norm not_less bounded_pos) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1759 |
done |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1760 |
qed |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1761 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1762 |
lemma unbounded_outside: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1763 |
fixes s :: "'a::{real_normed_vector, perfect_space} set" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1764 |
shows "bounded s \<Longrightarrow> ~ bounded(outside s)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1765 |
using cobounded_imp_unbounded cobounded_outside by blast |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1766 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1767 |
lemma bounded_inside: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1768 |
fixes s :: "'a::{real_normed_vector, perfect_space} set" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1769 |
shows "bounded s \<Longrightarrow> bounded(inside s)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1770 |
by (simp add: bounded_Int cobounded_outside inside_outside) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1771 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1772 |
lemma connected_outside: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1773 |
fixes s :: "'a::euclidean_space set" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1774 |
assumes "bounded s" "2 \<le> DIM('a)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1775 |
shows "connected(outside s)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1776 |
apply (simp add: connected_iff_connected_component, clarify) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1777 |
apply (simp add: outside) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1778 |
apply (rule_tac s="connected_component_set (- s) x" in connected_component_of_subset) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1779 |
apply (metis (no_types) assms cobounded_unbounded_component cobounded_unique_unbounded_component connected_component_eq_eq connected_component_idemp double_complement mem_Collect_eq) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1780 |
apply clarify |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1781 |
apply (metis connected_component_eq_eq connected_component_in) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1782 |
done |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1783 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1784 |
lemma outside_connected_component_lt: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1785 |
"outside s = {x. \<forall>B. \<exists>y. B < norm(y) \<and> connected_component (- s) x y}" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1786 |
apply (auto simp: outside bounded_def dist_norm) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1787 |
apply (metis diff_0 norm_minus_cancel not_less) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1788 |
by (metis less_diff_eq norm_minus_commute norm_triangle_ineq2 order.trans pinf(6)) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1789 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1790 |
lemma outside_connected_component_le: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1791 |
"outside s = |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1792 |
{x. \<forall>B. \<exists>y. B \<le> norm(y) \<and> |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1793 |
connected_component (- s) x y}" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1794 |
apply (simp add: outside_connected_component_lt) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1795 |
apply (simp add: Set.set_eq_iff) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1796 |
by (meson gt_ex leD le_less_linear less_imp_le order.trans) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1797 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1798 |
lemma not_outside_connected_component_lt: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1799 |
fixes s :: "'a::euclidean_space set" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1800 |
assumes s: "bounded s" and "2 \<le> DIM('a)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1801 |
shows "- (outside s) = {x. \<forall>B. \<exists>y. B < norm(y) \<and> ~ (connected_component (- s) x y)}" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1802 |
proof - |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1803 |
obtain B::real where B: "0 < B" and Bno: "\<And>x. x \<in> s \<Longrightarrow> norm x \<le> B" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1804 |
using s [simplified bounded_pos] by auto |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1805 |
{ fix y::'a and z::'a |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1806 |
assume yz: "B < norm z" "B < norm y" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1807 |
have "connected_component (- cball 0 B) y z" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1808 |
apply (rule connected_componentI [OF _ subset_refl]) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1809 |
apply (rule connected_complement_bounded_convex) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1810 |
using assms yz |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1811 |
by (auto simp: dist_norm) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1812 |
then have "connected_component (- s) y z" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1813 |
apply (rule connected_component_of_subset) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1814 |
apply (metis Bno Compl_anti_mono mem_cball_0 subset_iff) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1815 |
done |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1816 |
} note cyz = this |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1817 |
show ?thesis |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1818 |
apply (auto simp: outside) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1819 |
apply (metis Compl_iff bounded_iff cobounded_imp_unbounded mem_Collect_eq not_le) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1820 |
apply (simp add: bounded_pos) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1821 |
by (metis B connected_component_trans cyz not_le) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1822 |
qed |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1823 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1824 |
lemma not_outside_connected_component_le: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1825 |
fixes s :: "'a::euclidean_space set" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1826 |
assumes s: "bounded s" "2 \<le> DIM('a)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1827 |
shows "- (outside s) = {x. \<forall>B. \<exists>y. B \<le> norm(y) \<and> ~ (connected_component (- s) x y)}" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1828 |
apply (auto intro: less_imp_le simp: not_outside_connected_component_lt [OF assms]) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1829 |
by (meson gt_ex less_le_trans) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1830 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1831 |
lemma inside_connected_component_lt: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1832 |
fixes s :: "'a::euclidean_space set" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1833 |
assumes s: "bounded s" "2 \<le> DIM('a)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1834 |
shows "inside s = {x. (x \<notin> s) \<and> (\<forall>B. \<exists>y. B < norm(y) \<and> ~(connected_component (- s) x y))}" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1835 |
by (auto simp: inside_outside not_outside_connected_component_lt [OF assms]) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1836 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1837 |
lemma inside_connected_component_le: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1838 |
fixes s :: "'a::euclidean_space set" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1839 |
assumes s: "bounded s" "2 \<le> DIM('a)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1840 |
shows "inside s = {x. (x \<notin> s) \<and> (\<forall>B. \<exists>y. B \<le> norm(y) \<and> ~(connected_component (- s) x y))}" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1841 |
by (auto simp: inside_outside not_outside_connected_component_le [OF assms]) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1842 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1843 |
lemma inside_subset: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1844 |
assumes "connected u" and "~bounded u" and "t \<union> u = - s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1845 |
shows "inside s \<subseteq> t" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1846 |
apply (auto simp: inside_def) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1847 |
by (metis bounded_subset [of "connected_component_set (- s) _"] connected_component_maximal |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1848 |
Compl_iff Un_iff assms subsetI) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1849 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1850 |
lemma frontier_interiors: "frontier s = - interior(s) - interior(-s)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1851 |
by (simp add: Int_commute frontier_def interior_closure) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1852 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1853 |
lemma connected_inter_frontier: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1854 |
"\<lbrakk>connected s; s \<inter> t \<noteq> {}; s - t \<noteq> {}\<rbrakk> \<Longrightarrow> (s \<inter> frontier t \<noteq> {})" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1855 |
apply (simp add: frontier_interiors connected_open_in, safe) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1856 |
apply (drule_tac x="s \<inter> interior t" in spec, safe) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1857 |
apply (drule_tac [2] x="s \<inter> interior (-t)" in spec) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1858 |
apply (auto simp: disjoint_eq_subset_Compl dest: interior_subset [THEN subsetD]) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1859 |
done |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1860 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1861 |
lemma connected_component_UNIV: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1862 |
fixes x :: "'a::real_normed_vector" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1863 |
shows "connected_component_set UNIV x = UNIV" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1864 |
using connected_iff_eq_connected_component_set [of "UNIV::'a set"] connected_UNIV |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1865 |
by auto |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1866 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1867 |
lemma connected_component_eq_UNIV: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1868 |
fixes x :: "'a::real_normed_vector" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1869 |
shows "connected_component_set s x = UNIV \<longleftrightarrow> s = UNIV" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1870 |
using connected_component_in connected_component_UNIV by blast |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1871 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1872 |
lemma components_univ [simp]: "components UNIV = {UNIV :: 'a::real_normed_vector set}" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1873 |
by (auto simp: components_eq_sing_iff) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1874 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1875 |
lemma interior_inside_frontier: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1876 |
fixes s :: "'a::real_normed_vector set" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1877 |
assumes "bounded s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1878 |
shows "interior s \<subseteq> inside (frontier s)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1879 |
proof - |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1880 |
{ fix x y |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1881 |
assume x: "x \<in> interior s" and y: "y \<notin> s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1882 |
and cc: "connected_component (- frontier s) x y" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1883 |
have "connected_component_set (- frontier s) x \<inter> frontier s \<noteq> {}" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1884 |
apply (rule connected_inter_frontier, simp) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1885 |
apply (metis IntI cc connected_component_in connected_component_refl empty_iff interiorE mem_Collect_eq set_rev_mp x) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1886 |
using y cc |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1887 |
by blast |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1888 |
then have "bounded (connected_component_set (- frontier s) x)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1889 |
using connected_component_in by auto |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1890 |
} |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1891 |
then show ?thesis |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1892 |
apply (auto simp: inside_def frontier_def) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1893 |
apply (rule classical) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1894 |
apply (rule bounded_subset [OF assms], blast) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1895 |
done |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1896 |
qed |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1897 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1898 |
lemma inside_empty [simp]: "inside {} = ({} :: 'a :: {real_normed_vector, perfect_space} set)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1899 |
by (simp add: inside_def connected_component_UNIV) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1900 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1901 |
lemma outside_empty [simp]: "outside {} = (UNIV :: 'a :: {real_normed_vector, perfect_space} set)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1902 |
using inside_empty inside_union_outside by blast |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1903 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1904 |
lemma inside_same_component: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1905 |
"\<lbrakk>connected_component (- s) x y; x \<in> inside s\<rbrakk> \<Longrightarrow> y \<in> inside s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1906 |
using connected_component_eq connected_component_in |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1907 |
by (fastforce simp add: inside_def) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1908 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1909 |
lemma outside_same_component: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1910 |
"\<lbrakk>connected_component (- s) x y; x \<in> outside s\<rbrakk> \<Longrightarrow> y \<in> outside s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1911 |
using connected_component_eq connected_component_in |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1912 |
by (fastforce simp add: outside_def) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1913 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1914 |
lemma convex_in_outside: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1915 |
fixes s :: "'a :: {real_normed_vector, perfect_space} set" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1916 |
assumes s: "convex s" and z: "z \<notin> s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1917 |
shows "z \<in> outside s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1918 |
proof (cases "s={}") |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1919 |
case True then show ?thesis by simp |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1920 |
next |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1921 |
case False then obtain a where "a \<in> s" by blast |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1922 |
with z have zna: "z \<noteq> a" by auto |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1923 |
{ assume "bounded (connected_component_set (- s) z)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1924 |
with bounded_pos_less obtain B where "B>0" and B: "\<And>x. connected_component (- s) z x \<Longrightarrow> norm x < B" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1925 |
by (metis mem_Collect_eq) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1926 |
def C \<equiv> "((B + 1 + norm z) / norm (z-a))" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1927 |
have "C > 0" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1928 |
using `0 < B` zna by (simp add: C_def divide_simps add_strict_increasing) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1929 |
have "\<bar>norm (z + C *\<^sub>R (z-a)) - norm (C *\<^sub>R (z-a))\<bar> \<le> norm z" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1930 |
by (metis add_diff_cancel norm_triangle_ineq3) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1931 |
moreover have "norm (C *\<^sub>R (z-a)) > norm z + B" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1932 |
using zna `B>0` by (simp add: C_def le_max_iff_disj field_simps) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1933 |
ultimately have C: "norm (z + C *\<^sub>R (z-a)) > B" by linarith |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1934 |
{ fix u::real |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1935 |
assume u: "0\<le>u" "u\<le>1" and ins: "(1 - u) *\<^sub>R z + u *\<^sub>R (z + C *\<^sub>R (z - a)) \<in> s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1936 |
then have Cpos: "1 + u * C > 0" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1937 |
by (meson `0 < C` add_pos_nonneg less_eq_real_def zero_le_mult_iff zero_less_one) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1938 |
then have *: "(1 / (1 + u * C)) *\<^sub>R z + (u * C / (1 + u * C)) *\<^sub>R z = z" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1939 |
by (simp add: scaleR_add_left [symmetric] divide_simps) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1940 |
then have False |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1941 |
using convexD_alt [OF s `a \<in> s` ins, of "1/(u*C + 1)"] `C>0` `z \<notin> s` Cpos u |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1942 |
by (simp add: * divide_simps algebra_simps) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1943 |
} note contra = this |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1944 |
have "connected_component (- s) z (z + C *\<^sub>R (z-a))" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1945 |
apply (rule connected_componentI [OF connected_segment [of z "z + C *\<^sub>R (z-a)"]]) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1946 |
apply (simp add: closed_segment_def) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1947 |
using contra |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1948 |
apply auto |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1949 |
done |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1950 |
then have False |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1951 |
using zna B [of "z + C *\<^sub>R (z-a)"] C |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1952 |
by (auto simp: divide_simps max_mult_distrib_right) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1953 |
} |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1954 |
then show ?thesis |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1955 |
by (auto simp: outside_def z) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1956 |
qed |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1957 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1958 |
lemma outside_convex: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1959 |
fixes s :: "'a :: {real_normed_vector, perfect_space} set" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1960 |
assumes "convex s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1961 |
shows "outside s = - s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1962 |
by (metis ComplD assms convex_in_outside equalityI inside_union_outside subsetI sup.cobounded2) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1963 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1964 |
lemma inside_convex: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1965 |
fixes s :: "'a :: {real_normed_vector, perfect_space} set" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1966 |
shows "convex s \<Longrightarrow> inside s = {}" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1967 |
by (simp add: inside_outside outside_convex) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1968 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1969 |
lemma outside_subset_convex: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1970 |
fixes s :: "'a :: {real_normed_vector, perfect_space} set" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1971 |
shows "\<lbrakk>convex t; s \<subseteq> t\<rbrakk> \<Longrightarrow> - t \<subseteq> outside s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1972 |
using outside_convex outside_mono by blast |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1973 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1974 |
lemma outside_frontier_misses_closure: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1975 |
fixes s :: "'a::real_normed_vector set" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1976 |
assumes "bounded s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1977 |
shows "outside(frontier s) \<subseteq> - closure s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1978 |
unfolding outside_inside Lattices.boolean_algebra_class.compl_le_compl_iff |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1979 |
proof - |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1980 |
{ assume "interior s \<subseteq> inside (frontier s)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1981 |
hence "interior s \<union> inside (frontier s) = inside (frontier s)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1982 |
by (simp add: subset_Un_eq) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1983 |
then have "closure s \<subseteq> frontier s \<union> inside (frontier s)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1984 |
using frontier_def by auto |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1985 |
} |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1986 |
then show "closure s \<subseteq> frontier s \<union> inside (frontier s)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1987 |
using interior_inside_frontier [OF assms] by blast |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1988 |
qed |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1989 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1990 |
lemma outside_frontier_eq_complement_closure: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1991 |
fixes s :: "'a :: {real_normed_vector, perfect_space} set" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1992 |
assumes "bounded s" "convex s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1993 |
shows "outside(frontier s) = - closure s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1994 |
by (metis Diff_subset assms convex_closure frontier_def outside_frontier_misses_closure |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1995 |
outside_subset_convex subset_antisym) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1996 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1997 |
lemma open_inside: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1998 |
fixes s :: "'a::real_normed_vector set" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
1999 |
assumes "closed s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2000 |
shows "open (inside s)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2001 |
proof - |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2002 |
{ fix x assume x: "x \<in> inside s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2003 |
have "open (connected_component_set (- s) x)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2004 |
using assms open_connected_component by blast |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2005 |
then obtain e where e: "e>0" and e: "\<And>y. dist y x < e \<longrightarrow> connected_component (- s) x y" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2006 |
using dist_not_less_zero |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2007 |
apply (simp add: open_dist) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2008 |
by (metis (no_types, lifting) Compl_iff connected_component_refl_eq inside_def mem_Collect_eq x) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2009 |
then have "\<exists>e>0. ball x e \<subseteq> inside s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2010 |
by (metis e dist_commute inside_same_component mem_ball subsetI x) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2011 |
} |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2012 |
then show ?thesis |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2013 |
by (simp add: open_contains_ball) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2014 |
qed |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2015 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2016 |
lemma open_outside: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2017 |
fixes s :: "'a::real_normed_vector set" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2018 |
assumes "closed s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2019 |
shows "open (outside s)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2020 |
proof - |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2021 |
{ fix x assume x: "x \<in> outside s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2022 |
have "open (connected_component_set (- s) x)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2023 |
using assms open_connected_component by blast |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2024 |
then obtain e where e: "e>0" and e: "\<And>y. dist y x < e \<longrightarrow> connected_component (- s) x y" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2025 |
using dist_not_less_zero |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2026 |
apply (simp add: open_dist) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2027 |
by (metis Int_iff outside_def connected_component_refl_eq x) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2028 |
then have "\<exists>e>0. ball x e \<subseteq> outside s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2029 |
by (metis e dist_commute outside_same_component mem_ball subsetI x) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2030 |
} |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2031 |
then show ?thesis |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2032 |
by (simp add: open_contains_ball) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2033 |
qed |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2034 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2035 |
lemma closure_inside_subset: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2036 |
fixes s :: "'a::real_normed_vector set" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2037 |
assumes "closed s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2038 |
shows "closure(inside s) \<subseteq> s \<union> inside s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2039 |
by (metis assms closure_minimal open_closed open_outside sup.cobounded2 union_with_inside) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2040 |
|
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2041 |
lemma frontier_inside_subset: |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2042 |
fixes s :: "'a::real_normed_vector set" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2043 |
assumes "closed s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2044 |
shows "frontier(inside s) \<subseteq> s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2045 |
proof - |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2046 |
have "closure (inside s) \<inter> - inside s = closure (inside s) - interior (inside s)" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2047 |
by (metis (no_types) Diff_Compl assms closure_closed interior_closure open_closed open_inside) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2048 |
moreover have "- inside s \<inter> - outside s = s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2049 |
by (metis (no_types) compl_sup double_compl inside_union_outside) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2050 |
moreover have "closure (inside s) \<subseteq> - outside s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2051 |
by (metis (no_types) assms closure_inside_subset union_with_inside) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2052 |
ultimately have "closure (inside s) - interior (inside s) \<subseteq> s" |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2053 |
by blast |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2054 |
then show ?thesis |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2055 |
by (simp add: frontier_def open_inside interior_open) |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2056 |
qed |
d53db136e8fd
new material on path_component_sets, inside, outside, etc. And more default simprules
paulson <lp15@cam.ac.uk>
parents:
61204
diff
changeset
|
2057 |
|
36583 | 2058 |
end |