# HG changeset patch # User paulson # Date 1572709967 0 # Node ID 3e374c65f96b4c50281f02169b7ed019100cc77c # Parent 98308c6582edb651bb2c704c2ad3afc9552dcd80 reorganisation to eliminate Brouwer_Fixpoint from complex analysis diff -r 98308c6582ed -r 3e374c65f96b src/HOL/Analysis/Complex_Analysis_Basics.thy --- a/src/HOL/Analysis/Complex_Analysis_Basics.thy Sat Nov 02 14:31:48 2019 +0000 +++ b/src/HOL/Analysis/Complex_Analysis_Basics.thy Sat Nov 02 15:52:47 2019 +0000 @@ -5,7 +5,7 @@ section \Complex Analysis Basics\ theory Complex_Analysis_Basics - imports Brouwer_Fixpoint "HOL-Library.Nonpos_Ints" + imports Derivative "HOL-Library.Nonpos_Ints" begin (* TODO FIXME: A lot of the things in here have nothing to do with complex analysis *) @@ -880,32 +880,6 @@ apply (auto simp: bounded_linear_mult_right) done -lemma has_field_derivative_inverse_strong: - fixes f :: "'a::{euclidean_space,real_normed_field} \ 'a" - shows "DERIV f x :> f' \ - f' \ 0 \ - open S \ - x \ S \ - continuous_on S f \ - (\z. z \ S \ g (f z) = z) - \ DERIV g (f x) :> inverse (f')" - unfolding has_field_derivative_def - apply (rule has_derivative_inverse_strong [of S x f g ]) - by auto - -lemma has_field_derivative_inverse_strong_x: - fixes f :: "'a::{euclidean_space,real_normed_field} \ 'a" - shows "DERIV f (g y) :> f' \ - f' \ 0 \ - open S \ - continuous_on S f \ - g y \ S \ f(g y) = y \ - (\z. z \ S \ g (f z) = z) - \ DERIV g y :> inverse (f')" - unfolding has_field_derivative_def - apply (rule has_derivative_inverse_strong_x [of S g y f]) - by auto - subsection\<^marker>\tag unimportant\ \Taylor on Complex Numbers\ lemma sum_Suc_reindex: diff -r 98308c6582ed -r 3e374c65f96b src/HOL/Analysis/Complex_Transcendental.thy --- a/src/HOL/Analysis/Complex_Transcendental.thy Sat Nov 02 14:31:48 2019 +0000 +++ b/src/HOL/Analysis/Complex_Transcendental.thy Sat Nov 02 15:52:47 2019 +0000 @@ -4053,254 +4053,4 @@ apply (auto simp: Re_complex_div_eq_0 exp_of_nat_mult [symmetric] mult_ac exp_Euler) done -subsection\Formulation of loop homotopy in terms of maps out of type complex\ - -lemma homotopic_circlemaps_imp_homotopic_loops: - assumes "homotopic_with_canon (\h. True) (sphere 0 1) S f g" - shows "homotopic_loops S (f \ exp \ (\t. 2 * of_real pi * of_real t * \)) - (g \ exp \ (\t. 2 * of_real pi * of_real t * \))" -proof - - have "homotopic_with_canon (\f. True) {z. cmod z = 1} S f g" - using assms by (auto simp: sphere_def) - moreover have "continuous_on {0..1} (exp \ (\t. 2 * of_real pi * of_real t * \))" - by (intro continuous_intros) - moreover have "(exp \ (\t. 2 * of_real pi * of_real t * \)) ` {0..1} \ {z. cmod z = 1}" - by (auto simp: norm_mult) - ultimately - show ?thesis - apply (simp add: homotopic_loops_def comp_assoc) - apply (rule homotopic_with_compose_continuous_right) - apply (auto simp: pathstart_def pathfinish_def) - done -qed - -lemma homotopic_loops_imp_homotopic_circlemaps: - assumes "homotopic_loops S p q" - shows "homotopic_with_canon (\h. True) (sphere 0 1) S - (p \ (\z. (Arg2pi z / (2 * pi)))) - (q \ (\z. (Arg2pi z / (2 * pi))))" -proof - - obtain h where conth: "continuous_on ({0..1::real} \ {0..1}) h" - and him: "h ` ({0..1} \ {0..1}) \ S" - and h0: "(\x. h (0, x) = p x)" - and h1: "(\x. h (1, x) = q x)" - and h01: "(\t\{0..1}. h (t, 1) = h (t, 0)) " - using assms - by (auto simp: homotopic_loops_def sphere_def homotopic_with_def pathstart_def pathfinish_def) - define j where "j \ \z. if 0 \ Im (snd z) - then h (fst z, Arg2pi (snd z) / (2 * pi)) - else h (fst z, 1 - Arg2pi (cnj (snd z)) / (2 * pi))" - have Arg2pi_eq: "1 - Arg2pi (cnj y) / (2 * pi) = Arg2pi y / (2 * pi) \ Arg2pi y = 0 \ Arg2pi (cnj y) = 0" if "cmod y = 1" for y - using that Arg2pi_eq_0_pi Arg2pi_eq_pi by (force simp: Arg2pi_cnj field_split_simps) - show ?thesis - proof (simp add: homotopic_with; intro conjI ballI exI) - show "continuous_on ({0..1} \ sphere 0 1) (\w. h (fst w, Arg2pi (snd w) / (2 * pi)))" - proof (rule continuous_on_eq) - show j: "j x = h (fst x, Arg2pi (snd x) / (2 * pi))" if "x \ {0..1} \ sphere 0 1" for x - using Arg2pi_eq that h01 by (force simp: j_def) - have eq: "S = S \ (UNIV \ {z. 0 \ Im z}) \ S \ (UNIV \ {z. Im z \ 0})" for S :: "(real*complex)set" - by auto - have c1: "continuous_on ({0..1} \ sphere 0 1 \ UNIV \ {z. 0 \ Im z}) (\x. h (fst x, Arg2pi (snd x) / (2 * pi)))" - apply (intro continuous_intros continuous_on_compose2 [OF conth] continuous_on_compose2 [OF continuous_on_upperhalf_Arg2pi]) - apply (auto simp: Arg2pi) - apply (meson Arg2pi_lt_2pi linear not_le) - done - have c2: "continuous_on ({0..1} \ sphere 0 1 \ UNIV \ {z. Im z \ 0}) (\x. h (fst x, 1 - Arg2pi (cnj (snd x)) / (2 * pi)))" - apply (intro continuous_intros continuous_on_compose2 [OF conth] continuous_on_compose2 [OF continuous_on_upperhalf_Arg2pi]) - apply (auto simp: Arg2pi) - apply (meson Arg2pi_lt_2pi linear not_le) - done - show "continuous_on ({0..1} \ sphere 0 1) j" - apply (simp add: j_def) - apply (subst eq) - apply (rule continuous_on_cases_local) - apply (simp_all add: eq [symmetric] closedin_closed_Int closed_Times closed_halfspace_Im_le closed_halfspace_Im_ge c1 c2) - using Arg2pi_eq h01 - by force - qed - have "(\w. h (fst w, Arg2pi (snd w) / (2 * pi))) ` ({0..1} \ sphere 0 1) \ h ` ({0..1} \ {0..1})" - by (auto simp: Arg2pi_ge_0 Arg2pi_lt_2pi less_imp_le) - also have "... \ S" - using him by blast - finally show "(\w. h (fst w, Arg2pi (snd w) / (2 * pi))) ` ({0..1} \ sphere 0 1) \ S" . - qed (auto simp: h0 h1) -qed - -lemma simply_connected_homotopic_loops: - "simply_connected S \ - (\p q. homotopic_loops S p p \ homotopic_loops S q q \ homotopic_loops S p q)" -unfolding simply_connected_def using homotopic_loops_refl by metis - - -lemma simply_connected_eq_homotopic_circlemaps1: - fixes f :: "complex \ 'a::topological_space" and g :: "complex \ 'a" - assumes S: "simply_connected S" - and contf: "continuous_on (sphere 0 1) f" and fim: "f ` (sphere 0 1) \ S" - and contg: "continuous_on (sphere 0 1) g" and gim: "g ` (sphere 0 1) \ S" - shows "homotopic_with_canon (\h. True) (sphere 0 1) S f g" -proof - - have "homotopic_loops S (f \ exp \ (\t. of_real(2 * pi * t) * \)) (g \ exp \ (\t. of_real(2 * pi * t) * \))" - apply (rule S [unfolded simply_connected_homotopic_loops, rule_format]) - apply (simp add: homotopic_circlemaps_imp_homotopic_loops homotopic_with_refl contf fim contg gim) - done - then show ?thesis - apply (rule homotopic_with_eq [OF homotopic_loops_imp_homotopic_circlemaps]) - apply (auto simp: o_def complex_norm_eq_1_exp mult.commute) - done -qed - -lemma simply_connected_eq_homotopic_circlemaps2a: - fixes h :: "complex \ 'a::topological_space" - assumes conth: "continuous_on (sphere 0 1) h" and him: "h ` (sphere 0 1) \ S" - and hom: "\f g::complex \ 'a. - \continuous_on (sphere 0 1) f; f ` (sphere 0 1) \ S; - continuous_on (sphere 0 1) g; g ` (sphere 0 1) \ S\ - \ homotopic_with_canon (\h. True) (sphere 0 1) S f g" - shows "\a. homotopic_with_canon (\h. True) (sphere 0 1) S h (\x. a)" - apply (rule_tac x="h 1" in exI) - apply (rule hom) - using assms - by (auto simp: continuous_on_const) - -lemma simply_connected_eq_homotopic_circlemaps2b: - fixes S :: "'a::real_normed_vector set" - assumes "\f g::complex \ 'a. - \continuous_on (sphere 0 1) f; f ` (sphere 0 1) \ S; - continuous_on (sphere 0 1) g; g ` (sphere 0 1) \ S\ - \ homotopic_with_canon (\h. True) (sphere 0 1) S f g" - shows "path_connected S" -proof (clarsimp simp add: path_connected_eq_homotopic_points) - fix a b - assume "a \ S" "b \ S" - then show "homotopic_loops S (linepath a a) (linepath b b)" - using homotopic_circlemaps_imp_homotopic_loops [OF assms [of "\x. a" "\x. b"]] - by (auto simp: o_def continuous_on_const linepath_def) -qed - -lemma simply_connected_eq_homotopic_circlemaps3: - fixes h :: "complex \ 'a::real_normed_vector" - assumes "path_connected S" - and hom: "\f::complex \ 'a. - \continuous_on (sphere 0 1) f; f `(sphere 0 1) \ S\ - \ \a. homotopic_with_canon (\h. True) (sphere 0 1) S f (\x. a)" - shows "simply_connected S" -proof (clarsimp simp add: simply_connected_eq_contractible_loop_some assms) - fix p - assume p: "path p" "path_image p \ S" "pathfinish p = pathstart p" - then have "homotopic_loops S p p" - by (simp add: homotopic_loops_refl) - then obtain a where homp: "homotopic_with_canon (\h. True) (sphere 0 1) S (p \ (\z. Arg2pi z / (2 * pi))) (\x. a)" - by (metis homotopic_with_imp_subset2 homotopic_loops_imp_homotopic_circlemaps homotopic_with_imp_continuous hom) - show "\a. a \ S \ homotopic_loops S p (linepath a a)" - proof (intro exI conjI) - show "a \ S" - using homotopic_with_imp_subset2 [OF homp] - by (metis dist_0_norm image_subset_iff mem_sphere norm_one) - have teq: "\t. \0 \ t; t \ 1\ - \ t = Arg2pi (exp (2 * of_real pi * of_real t * \)) / (2 * pi) \ t=1 \ Arg2pi (exp (2 * of_real pi * of_real t * \)) = 0" - apply (rule disjCI) - using Arg2pi_of_real [of 1] apply (auto simp: Arg2pi_exp) - done - have "homotopic_loops S p (p \ (\z. Arg2pi z / (2 * pi)) \ exp \ (\t. 2 * complex_of_real pi * complex_of_real t * \))" - apply (rule homotopic_loops_eq [OF p]) - using p teq apply (fastforce simp: pathfinish_def pathstart_def) - done - then - show "homotopic_loops S p (linepath a a)" - by (simp add: linepath_refl homotopic_loops_trans [OF _ homotopic_circlemaps_imp_homotopic_loops [OF homp, simplified K_record_comp]]) - qed -qed - - -proposition simply_connected_eq_homotopic_circlemaps: - fixes S :: "'a::real_normed_vector set" - shows "simply_connected S \ - (\f g::complex \ 'a. - continuous_on (sphere 0 1) f \ f ` (sphere 0 1) \ S \ - continuous_on (sphere 0 1) g \ g ` (sphere 0 1) \ S - \ homotopic_with_canon (\h. True) (sphere 0 1) S f g)" - apply (rule iffI) - apply (blast elim: dest: simply_connected_eq_homotopic_circlemaps1) - by (simp add: simply_connected_eq_homotopic_circlemaps2a simply_connected_eq_homotopic_circlemaps2b simply_connected_eq_homotopic_circlemaps3) - -proposition simply_connected_eq_contractible_circlemap: - fixes S :: "'a::real_normed_vector set" - shows "simply_connected S \ - path_connected S \ - (\f::complex \ 'a. - continuous_on (sphere 0 1) f \ f `(sphere 0 1) \ S - \ (\a. homotopic_with_canon (\h. True) (sphere 0 1) S f (\x. a)))" - apply (rule iffI) - apply (simp add: simply_connected_eq_homotopic_circlemaps1 simply_connected_eq_homotopic_circlemaps2a simply_connected_eq_homotopic_circlemaps2b) - using simply_connected_eq_homotopic_circlemaps3 by blast - -corollary homotopy_eqv_simple_connectedness: - fixes S :: "'a::real_normed_vector set" and T :: "'b::real_normed_vector set" - shows "S homotopy_eqv T \ simply_connected S \ simply_connected T" - by (simp add: simply_connected_eq_homotopic_circlemaps homotopy_eqv_homotopic_triviality) - - -subsection\Homeomorphism of simple closed curves to circles\ - -proposition homeomorphic_simple_path_image_circle: - fixes a :: complex and \ :: "real \ 'a::t2_space" - assumes "simple_path \" and loop: "pathfinish \ = pathstart \" and "0 < r" - shows "(path_image \) homeomorphic sphere a r" -proof - - have "homotopic_loops (path_image \) \ \" - by (simp add: assms homotopic_loops_refl simple_path_imp_path) - then have hom: "homotopic_with_canon (\h. True) (sphere 0 1) (path_image \) - (\ \ (\z. Arg2pi z / (2*pi))) (\ \ (\z. Arg2pi z / (2*pi)))" - by (rule homotopic_loops_imp_homotopic_circlemaps) - have "\g. homeomorphism (sphere 0 1) (path_image \) (\ \ (\z. Arg2pi z / (2*pi))) g" - proof (rule homeomorphism_compact) - show "continuous_on (sphere 0 1) (\ \ (\z. Arg2pi z / (2*pi)))" - using hom homotopic_with_imp_continuous by blast - show "inj_on (\ \ (\z. Arg2pi z / (2*pi))) (sphere 0 1)" - proof - fix x y - assume xy: "x \ sphere 0 1" "y \ sphere 0 1" - and eq: "(\ \ (\z. Arg2pi z / (2*pi))) x = (\ \ (\z. Arg2pi z / (2*pi))) y" - then have "(Arg2pi x / (2*pi)) = (Arg2pi y / (2*pi))" - proof - - have "(Arg2pi x / (2*pi)) \ {0..1}" "(Arg2pi y / (2*pi)) \ {0..1}" - using Arg2pi_ge_0 Arg2pi_lt_2pi dual_order.strict_iff_order by fastforce+ - with eq show ?thesis - using \simple_path \\ Arg2pi_lt_2pi unfolding simple_path_def o_def - by (metis eq_divide_eq_1 not_less_iff_gr_or_eq) - qed - with xy show "x = y" - by (metis is_Arg_def Arg2pi Arg2pi_0 dist_0_norm divide_cancel_right dual_order.strict_iff_order mem_sphere) - qed - have "\z. cmod z = 1 \ \x\{0..1}. \ (Arg2pi z / (2*pi)) = \ x" - by (metis Arg2pi_ge_0 Arg2pi_lt_2pi atLeastAtMost_iff divide_less_eq_1 less_eq_real_def zero_less_mult_iff pi_gt_zero zero_le_divide_iff zero_less_numeral) - moreover have "\z\sphere 0 1. \ x = \ (Arg2pi z / (2*pi))" if "0 \ x" "x \ 1" for x - proof (cases "x=1") - case True - with Arg2pi_of_real [of 1] loop show ?thesis - by (rule_tac x=1 in bexI) (auto simp: pathfinish_def pathstart_def \0 \ x\) - next - case False - then have *: "(Arg2pi (exp (\*(2* of_real pi* of_real x))) / (2*pi)) = x" - using that by (auto simp: Arg2pi_exp field_split_simps) - show ?thesis - by (rule_tac x="exp(\ * of_real(2*pi*x))" in bexI) (auto simp: *) - qed - ultimately show "(\ \ (\z. Arg2pi z / (2*pi))) ` sphere 0 1 = path_image \" - by (auto simp: path_image_def image_iff) - qed auto - then have "path_image \ homeomorphic sphere (0::complex) 1" - using homeomorphic_def homeomorphic_sym by blast - also have "... homeomorphic sphere a r" - by (simp add: assms homeomorphic_spheres) - finally show ?thesis . -qed - -lemma homeomorphic_simple_path_images: - fixes \1 :: "real \ 'a::t2_space" and \2 :: "real \ 'b::t2_space" - assumes "simple_path \1" and loop: "pathfinish \1 = pathstart \1" - assumes "simple_path \2" and loop: "pathfinish \2 = pathstart \2" - shows "(path_image \1) homeomorphic (path_image \2)" - by (meson assms homeomorphic_simple_path_image_circle homeomorphic_sym homeomorphic_trans loop pi_gt_zero) - end diff -r 98308c6582ed -r 3e374c65f96b src/HOL/Analysis/Conformal_Mappings.thy --- a/src/HOL/Analysis/Conformal_Mappings.thy Sat Nov 02 14:31:48 2019 +0000 +++ b/src/HOL/Analysis/Conformal_Mappings.thy Sat Nov 02 15:52:47 2019 +0000 @@ -226,7 +226,7 @@ proposition isolated_zeros: assumes holf: "f holomorphic_on S" and "open S" "connected S" "\ \ S" "f \ = 0" "\ \ S" "f \ \ 0" - obtains r where "0 < r" and "ball \ r \ S" and + obtains r where "0 < r" and "ball \ r \ S" and "\z. z \ ball \ r - {\} \ f z \ 0" proof - obtain r where "0 < r" and r: "ball \ r \ S" @@ -280,15 +280,15 @@ qed corollary analytic_continuation_open: - assumes "open s" and "open s'" and "s \ {}" and "connected s'" + assumes "open s" and "open s'" and "s \ {}" and "connected s'" and "s \ s'" - assumes "f holomorphic_on s'" and "g holomorphic_on s'" + assumes "f holomorphic_on s'" and "g holomorphic_on s'" and "\z. z \ s \ f z = g z" assumes "z \ s'" shows "f z = g z" proof - from \s \ {}\ obtain \ where "\ \ s" by auto - with \open s\ have \: "\ islimpt s" + with \open s\ have \: "\ islimpt s" by (intro interior_limit_point) (auto simp: interior_open) have "f z - g z = 0" by (rule analytic_continuation[of "\z. f z - g z" s' s \]) @@ -450,7 +450,7 @@ using w \open X\ interior_eq by auto have hol: "(\z. f z - x) holomorphic_on S" by (simp add: holf holomorphic_on_diff) - with fne [unfolded constant_on_def] + with fne [unfolded constant_on_def] analytic_continuation[OF hol S \connected S\ \X \ S\ _ wis] not \X \ S\ w show False by auto qed @@ -1270,6 +1270,32 @@ text\Hence a nice clean inverse function theorem\ +lemma has_field_derivative_inverse_strong: + fixes f :: "'a::{euclidean_space,real_normed_field} ⇒ 'a" + shows "DERIV f x :> f' ⟹ + f' ≠ 0 ⟹ + open S ⟹ + x ∈ S ⟹ + continuous_on S f ⟹ + (⋀z. z ∈ S ⟹ g (f z) = z) + ⟹ DERIV g (f x) :> inverse (f')" + unfolding has_field_derivative_def + apply (rule has_derivative_inverse_strong [of S x f g ]) + by auto + +lemma has_field_derivative_inverse_strong_x: + fixes f :: "'a::{euclidean_space,real_normed_field} ⇒ 'a" + shows "DERIV f (g y) :> f' ⟹ + f' ≠ 0 ⟹ + open S ⟹ + continuous_on S f ⟹ + g y ∈ S ⟹ f(g y) = y ⟹ + (⋀z. z ∈ S ⟹ g (f z) = z) + ⟹ DERIV g y :> inverse (f')" + unfolding has_field_derivative_def + apply (rule has_derivative_inverse_strong_x [of S g y f]) + by auto + proposition holomorphic_has_inverse: assumes holf: "f holomorphic_on S" and "open S" and injf: "inj_on f S" @@ -1379,9 +1405,9 @@ and no: "\z. norm z < 1 \ norm (f z) < 1" and \: "norm \ < 1" shows "norm (f \) \ norm \" and "norm(deriv f 0) \ 1" - and "((\z. norm z < 1 \ z \ 0 \ norm(f z) = norm z) + and "((\z. norm z < 1 \ z \ 0 \ norm(f z) = norm z) \ norm(deriv f 0) = 1) - \ \\. (\z. norm z < 1 \ f z = \ * z) \ norm \ = 1" + \ \\. (\z. norm z < 1 \ f z = \ * z) \ norm \ = 1" (is "?P \ ?Q") proof - obtain h where holh: "h holomorphic_on (ball 0 1)" @@ -1456,9 +1482,9 @@ corollary Schwarz_Lemma': assumes holf: "f holomorphic_on (ball 0 1)" and [simp]: "f 0 = 0" and no: "\z. norm z < 1 \ norm (f z) < 1" - shows "((\\. norm \ < 1 \ norm (f \) \ norm \) - \ norm(deriv f 0) \ 1) - \ (((\z. norm z < 1 \ z \ 0 \ norm(f z) = norm z) + shows "((\\. norm \ < 1 \ norm (f \) \ norm \) + \ norm(deriv f 0) \ 1) + \ (((\z. norm z < 1 \ z \ 0 \ norm(f z) = norm z) \ norm(deriv f 0) = 1) \ (\\. (\z. norm z < 1 \ f z = \ * z) \ norm \ = 1))" using Schwarz_Lemma [OF assms] @@ -2183,8 +2209,8 @@ have "residue f z = residue g z" unfolding residue_def proof (rule Eps_cong) fix c :: complex - have "\e>0. ?P g c e" - if "\e>0. ?P f c e" and "eventually (\z. f z = g z) (at z)" for f g + have "\e>0. ?P g c e" + if "\e>0. ?P f c e" and "eventually (\z. f z = g z) (at z)" for f g proof - from that(1) obtain e where e: "e > 0" "?P f c e" by blast @@ -2193,7 +2219,7 @@ have "?P g c (min e e')" proof (intro allI exI impI, goal_cases) case (1 \) - hence "(f has_contour_integral of_real (2 * pi) * \ * c) (circlepath z \)" + hence "(f has_contour_integral of_real (2 * pi) * \ * c) (circlepath z \)" using e(2) by auto thus ?case proof (rule has_contour_integral_eq) @@ -2468,7 +2494,7 @@ qed lemma residue_simple': - assumes s: "open s" "z \ s" and holo: "f holomorphic_on (s - {z})" + assumes s: "open s" "z \ s" and holo: "f holomorphic_on (s - {z})" and lim: "((\w. f w * (w - z)) \ c) (at z)" shows "residue f z = c" proof - @@ -2510,7 +2536,7 @@ using assms r by (intro Cauchy_has_contour_integral_higher_derivative_circlepath) (auto intro!: holomorphic_on_subset[OF assms(3)] holomorphic_on_imp_continuous_on) - ultimately have "2 * pi * \ * residue ?f z0 = 2 * pi * \ / fact n * (deriv ^^ n) f z0" + ultimately have "2 * pi * \ * residue ?f z0 = 2 * pi * \ / fact n * (deriv ^^ n) f z0" by (rule has_contour_integral_unique) thus ?thesis by (simp add: field_simps) qed @@ -2967,7 +2993,7 @@ subsection \Non-essential singular points\ -definition\<^marker>\tag important\ is_pole :: +definition\<^marker>\tag important\ is_pole :: "('a::topological_space \ 'b::real_normed_vector) \ 'a \ bool" where "is_pole f a = (LIM x (at a). f x :> at_infinity)" @@ -3065,10 +3091,10 @@ shows "is_pole (\w. f w / w ^ n) 0" using is_pole_basic[of f A 0] assms by simp -text \The proposition - \<^term>\\x. ((f::complex\complex) \ x) (at z) \ is_pole f z\ -can be interpreted as the complex function \<^term>\f\ has a non-essential singularity at \<^term>\z\ -(i.e. the singularity is either removable or a pole).\ +text \The proposition + \<^term>\\x. ((f::complex\complex) \ x) (at z) \ is_pole f z\ +can be interpreted as the complex function \<^term>\f\ has a non-essential singularity at \<^term>\z\ +(i.e. the singularity is either removable or a pole).\ definition not_essential::"[complex \ complex, complex] \ bool" where "not_essential f z = (\x. f\z\x \ is_pole f z)" @@ -3102,7 +3128,7 @@ have "f' z=0" using \n>m\ unfolding f'_def by auto moreover have "continuous F f'" unfolding f'_def F_def continuous_def apply (subst Lim_ident_at) - using \n>m\ by (auto intro!:tendsto_powr_complex_0 tendsto_eq_intros) + using \n>m\ by (auto intro!:tendsto_powr_complex_0 tendsto_eq_intros) ultimately have "(f' \ 0) F" unfolding F_def by (simp add: continuous_within) moreover have "(g \ g z) F" @@ -3149,7 +3175,7 @@ qed lemma holomorphic_factor_puncture: - assumes f_iso:"isolated_singularity_at f z" + assumes f_iso:"isolated_singularity_at f z" and "not_essential f z" \ \\<^term>\f\ has either a removable singularity or a pole at \<^term>\z\\ and non_zero:"\\<^sub>Fw in (at z). f w\0" \ \\<^term>\f\ will not be constantly zero in a neighbour of \<^term>\z\\ shows "\!n::int. \g r. 0 < r \ g holomorphic_on cball z r \ g z\0 @@ -3157,7 +3183,7 @@ proof - define P where "P = (\f n g r. 0 < r \ g holomorphic_on cball z r \ g z\0 \ (\w\cball z r - {z}. f w = g w * (w-z) powr (of_int n) \ g w\0))" - have imp_unique:"\!n::int. \g r. P f n g r" when "\n g r. P f n g r" + have imp_unique:"\!n::int. \g r. P f n g r" when "\n g r. P f n g r" proof (rule ex_ex1I[OF that]) fix n1 n2 :: int assume g1_asm:"\g1 r1. P f n1 g1 r1" and g2_asm:"\g2 r2. P f n2 g2 r2" @@ -3168,17 +3194,17 @@ and "fac n2 g2 r2" using g2_asm unfolding P_def fac_def by auto define r where "r \ min r1 r2" have "r>0" using \r1>0\ \r2>0\ unfolding r_def by auto - moreover have "\w\ball z r-{z}. f w = g1 w * (w-z) powr n1 \ g1 w\0 + moreover have "\w\ball z r-{z}. f w = g1 w * (w-z) powr n1 \ g1 w\0 \ f w = g2 w * (w - z) powr n2 \ g2 w\0" using \fac n1 g1 r1\ \fac n2 g2 r2\ unfolding fac_def r_def by fastforce ultimately show "n1=n2" using g1_holo g2_holo \g1 z\0\ \g2 z\0\ apply (elim holomorphic_factor_unique) - by (auto simp add:r_def) + by (auto simp add:r_def) qed - have P_exist:"\ n g r. P h n g r" when - "\z'. (h \ z') (at z)" "isolated_singularity_at h z" "\\<^sub>Fw in (at z). h w\0" + have P_exist:"\ n g r. P h n g r" when + "\z'. (h \ z') (at z)" "isolated_singularity_at h z" "\\<^sub>Fw in (at z). h w\0" for h proof - from that(2) obtain r where "r>0" "h analytic_on ball z r - {z}" @@ -3186,15 +3212,15 @@ obtain z' where "(h \ z') (at z)" using \\z'. (h \ z') (at z)\ by auto define h' where "h'=(\x. if x=z then z' else h x)" have "h' holomorphic_on ball z r" - apply (rule no_isolated_singularity'[of "{z}"]) + apply (rule no_isolated_singularity'[of "{z}"]) subgoal by (metis LIM_equal Lim_at_imp_Lim_at_within \h \z\ z'\ empty_iff h'_def insert_iff) - subgoal using \h analytic_on ball z r - {z}\ analytic_imp_holomorphic h'_def holomorphic_transform + subgoal using \h analytic_on ball z r - {z}\ analytic_imp_holomorphic h'_def holomorphic_transform by fastforce by auto have ?thesis when "z'=0" - proof - + proof - have "h' z=0" using that unfolding h'_def by auto - moreover have "\ h' constant_on ball z r" + moreover have "\ h' constant_on ball z r" using \\\<^sub>Fw in (at z). h w\0\ unfolding constant_on_def frequently_def eventually_at h'_def apply simp by (metis \0 < r\ centre_in_ball dist_commute mem_ball that) @@ -3202,9 +3228,9 @@ ultimately obtain g r1 n where "0 < n" "0 < r1" "ball z r1 \ ball z r" and g:"g holomorphic_on ball z r1" "\w. w \ ball z r1 \ h' w = (w - z) ^ n * g w" - "\w. w \ ball z r1 \ g w \ 0" + "\w. w \ ball z r1 \ g w \ 0" using holomorphic_factor_zero_nonconstant[of _ "ball z r" z thesis,simplified, - OF \h' holomorphic_on ball z r\ \r>0\ \h' z=0\ \\ h' constant_on ball z r\] + OF \h' holomorphic_on ball z r\ \r>0\ \h' z=0\ \\ h' constant_on ball z r\] by (auto simp add:dist_commute) define rr where "rr=r1/2" have "P h' n g rr" @@ -3224,9 +3250,9 @@ then obtain r2 where r2:"r2>0" "\x\ball z r2. h' x\0" using continuous_at_avoid[of z h' 0 ] unfolding ball_def by auto define r1 where "r1=min r2 r / 2" - have "0 < r1" "cball z r1 \ ball z r" + have "0 < r1" "cball z r1 \ ball z r" using \r2>0\ \r>0\ unfolding r1_def by auto - moreover have "\x\cball z r1. h' x \ 0" + moreover have "\x\cball z r1. h' x \ 0" using r2 unfolding r1_def by simp ultimately show ?thesis using that by auto qed @@ -3256,21 +3282,21 @@ apply (rule that[of e]) using e1 e2 unfolding e_def by auto qed - + define h where "h \ \x. inverse (f x)" have "\n g r. P h n g r" proof - - have "h \z\ 0" + have "h \z\ 0" using Lim_transform_within_open assms(2) h_def is_pole_tendsto that by fastforce moreover have "\\<^sub>Fw in (at z). h w\0" - using non_zero + using non_zero apply (elim frequently_rev_mp) unfolding h_def eventually_at by (auto intro:exI[where x=1]) moreover have "isolated_singularity_at h z" unfolding isolated_singularity_at_def h_def apply (rule exI[where x=e]) - using e_holo e_nz \e>0\ by (metis open_ball analytic_on_open + using e_holo e_nz \e>0\ by (metis open_ball analytic_on_open holomorphic_on_inverse open_delete) ultimately show ?thesis using P_exist[of h] by auto @@ -3283,14 +3309,14 @@ have "P f (-n) (inverse o g) r" proof - have "f w = inverse (g w) * (w - z) powr of_int (- n)" when "w\cball z r - {z}" for w - using g_fac[rule_format,of w] that unfolding h_def + using g_fac[rule_format,of w] that unfolding h_def apply (auto simp add:powr_minus ) by (metis inverse_inverse_eq inverse_mult_distrib) - then show ?thesis + then show ?thesis unfolding P_def comp_def using \r>0\ g_holo g_fac \g z\0\ by (auto intro:holomorphic_intros) qed - then show "\x g r. 0 < r \ g holomorphic_on cball z r \ g z \ 0 + then show "\x g r. 0 < r \ g holomorphic_on cball z r \ g z \ 0 \ (\w\cball z r - {z}. f w = g w * (w - z) powr of_int x \ g w \ 0)" unfolding P_def by blast qed @@ -3300,14 +3326,14 @@ lemma not_essential_transform: assumes "not_essential g z" assumes "\\<^sub>F w in (at z). g w = f w" - shows "not_essential f z" + shows "not_essential f z" using assms unfolding not_essential_def by (simp add: filterlim_cong is_pole_cong) lemma isolated_singularity_at_transform: assumes "isolated_singularity_at g z" assumes "\\<^sub>F w in (at z). g w = f w" - shows "isolated_singularity_at f z" + shows "isolated_singularity_at f z" proof - obtain r1 where "r1>0" and r1:"g analytic_on ball z r1 - {z}" using assms(1) unfolding isolated_singularity_at_def by auto @@ -3320,9 +3346,9 @@ have "g holomorphic_on ball z r3 - {z}" using r1 unfolding r3_def by (subst (asm) analytic_on_open,auto) then have "f holomorphic_on ball z r3 - {z}" - using r2 unfolding r3_def + using r2 unfolding r3_def by (auto simp add:dist_commute elim!:holomorphic_transform) - then show ?thesis by (subst analytic_on_open,auto) + then show ?thesis by (subst analytic_on_open,auto) qed ultimately show ?thesis unfolding isolated_singularity_at_def by auto qed @@ -3334,16 +3360,16 @@ define fp where "fp=(\w. (f w) powr (of_int n))" have ?thesis when "n>0" proof - - have "(\w. (f w) ^ (nat n)) \z\ x ^ nat n" + have "(\w. (f w) ^ (nat n)) \z\ x ^ nat n" using that assms unfolding filterlim_at by (auto intro!:tendsto_eq_intros) - then have "fp \z\ x ^ nat n" unfolding fp_def + then have "fp \z\ x ^ nat n" unfolding fp_def apply (elim Lim_transform_within[where d=1],simp) by (metis less_le powr_0 powr_of_int that zero_less_nat_eq zero_power) then show ?thesis unfolding not_essential_def fp_def by auto qed moreover have ?thesis when "n=0" proof - - have "fp \z\ 1 " + have "fp \z\ 1 " apply (subst tendsto_cong[where g="\_.1"]) using that filterlim_at_within_not_equal[OF assms,of 0] unfolding fp_def by auto then show ?thesis unfolding fp_def not_essential_def by auto @@ -3355,7 +3381,7 @@ apply (subst filterlim_inverse_at_iff[symmetric],simp) apply (rule filterlim_atI) subgoal using assms True that unfolding filterlim_at by (auto intro!:tendsto_eq_intros) - subgoal using filterlim_at_within_not_equal[OF assms,of 0] + subgoal using filterlim_at_within_not_equal[OF assms,of 0] by (eventually_elim,insert that,auto) done then have "LIM w (at z). fp w :> at_infinity" @@ -3373,7 +3399,7 @@ using assms False unfolding filterlim_at by (auto intro!:tendsto_eq_intros) then have "fp \z\?xx" apply (elim Lim_transform_within[where d=1],simp) - unfolding fp_def by (metis inverse_zero nat_mono_iff nat_zero_as_int neg_0_less_iff_less + unfolding fp_def by (metis inverse_zero nat_mono_iff nat_zero_as_int neg_0_less_iff_less not_le power_eq_0_iff powr_0 powr_of_int that) then show ?thesis unfolding fp_def not_essential_def by auto qed @@ -3403,13 +3429,13 @@ qed lemma non_zero_neighbour: - assumes f_iso:"isolated_singularity_at f z" - and f_ness:"not_essential f z" + assumes f_iso:"isolated_singularity_at f z" + and f_ness:"not_essential f z" and f_nconst:"\\<^sub>Fw in (at z). f w\0" shows "\\<^sub>F w in (at z). f w\0" proof - obtain fn fp fr where [simp]:"fp z \ 0" and "fr > 0" - and fr: "fp holomorphic_on cball z fr" + and fr: "fp holomorphic_on cball z fr" "\w\cball z fr - {z}. f w = fp w * (w - z) powr of_int fn \ fp w \ 0" using holomorphic_factor_puncture[OF f_iso f_ness f_nconst,THEN ex1_implies_ex] by auto have "f w \ 0" when " w \ z" "dist w z < fr" for w @@ -3426,7 +3452,7 @@ lemma non_zero_neighbour_pole: assumes "is_pole f z" shows "\\<^sub>F w in (at z). f w\0" - using assms filterlim_at_infinity_imp_eventually_ne[of f "at z" 0] + using assms filterlim_at_infinity_imp_eventually_ne[of f "at z" 0] unfolding is_pole_def by auto lemma non_zero_neighbour_alt: @@ -3435,19 +3461,19 @@ shows "\\<^sub>F w in (at z). f w\0 \ w\S" proof (cases "f z = 0") case True - from isolated_zeros[OF holo \open S\ \connected S\ \z \ S\ True \\ \ S\ \f \ \ 0\] - obtain r where "0 < r" "ball z r \ S" "\w \ ball z r - {z}.f w \ 0" by metis - then show ?thesis unfolding eventually_at + from isolated_zeros[OF holo \open S\ \connected S\ \z \ S\ True \\ \ S\ \f \ \ 0\] + obtain r where "0 < r" "ball z r \ S" "\w \ ball z r - {z}.f w \ 0" by metis + then show ?thesis unfolding eventually_at apply (rule_tac x=r in exI) by (auto simp add:dist_commute) next case False obtain r1 where r1:"r1>0" "\y. dist z y < r1 \ f y \ 0" - using continuous_at_avoid[of z f, OF _ False] assms(2,4) continuous_on_eq_continuous_at + using continuous_at_avoid[of z f, OF _ False] assms(2,4) continuous_on_eq_continuous_at holo holomorphic_on_imp_continuous_on by blast - obtain r2 where r2:"r2>0" "ball z r2 \ S" + obtain r2 where r2:"r2>0" "ball z r2 \ S" using assms(2) assms(4) openE by blast - show ?thesis unfolding eventually_at + show ?thesis unfolding eventually_at apply (rule_tac x="min r1 r2" in exI) using r1 r2 by (auto simp add:dist_commute) qed @@ -3460,7 +3486,7 @@ define fg where "fg = (\w. f w * g w)" have ?thesis when "\ ((\\<^sub>Fw in (at z). f w\0) \ (\\<^sub>Fw in (at z). g w\0))" proof - - have "\\<^sub>Fw in (at z). fg w=0" + have "\\<^sub>Fw in (at z). fg w=0" using that[unfolded frequently_def, simplified] unfolding fg_def by (auto elim: eventually_rev_mp) from tendsto_cong[OF this] have "fg \z\0" by auto @@ -3469,14 +3495,14 @@ moreover have ?thesis when f_nconst:"\\<^sub>Fw in (at z). f w\0" and g_nconst:"\\<^sub>Fw in (at z). g w\0" proof - obtain fn fp fr where [simp]:"fp z \ 0" and "fr > 0" - and fr: "fp holomorphic_on cball z fr" + and fr: "fp holomorphic_on cball z fr" "\w\cball z fr - {z}. f w = fp w * (w - z) powr of_int fn \ fp w \ 0" using holomorphic_factor_puncture[OF f_iso f_ness f_nconst,THEN ex1_implies_ex] by auto obtain gn gp gr where [simp]:"gp z \ 0" and "gr > 0" - and gr: "gp holomorphic_on cball z gr" + and gr: "gp holomorphic_on cball z gr" "\w\cball z gr - {z}. g w = gp w * (w - z) powr of_int gn \ gp w \ 0" using holomorphic_factor_puncture[OF g_iso g_ness g_nconst,THEN ex1_implies_ex] by auto - + define r1 where "r1=(min fr gr)" have "r1>0" unfolding r1_def using \fr>0\ \gr>0\ by auto have fg_times:"fg w = (fp w * gp w) * (w - z) powr (of_int (fn+gn))" and fgp_nz:"fp w*gp w\0" @@ -3492,23 +3518,23 @@ have [intro]: "fp \z\fp z" "gp \z\gp z" using fr(1) \fr>0\ gr(1) \gr>0\ - by (meson open_ball ball_subset_cball centre_in_ball - continuous_on_eq_continuous_at continuous_within holomorphic_on_imp_continuous_on + by (meson open_ball ball_subset_cball centre_in_ball + continuous_on_eq_continuous_at continuous_within holomorphic_on_imp_continuous_on holomorphic_on_subset)+ - have ?thesis when "fn+gn>0" + have ?thesis when "fn+gn>0" proof - - have "(\w. (fp w * gp w) * (w - z) ^ (nat (fn+gn))) \z\0" + have "(\w. (fp w * gp w) * (w - z) ^ (nat (fn+gn))) \z\0" using that by (auto intro!:tendsto_eq_intros) then have "fg \z\ 0" apply (elim Lim_transform_within[OF _ \r1>0\]) - by (metis (no_types, hide_lams) Diff_iff cball_trivial dist_commute dist_self - eq_iff_diff_eq_0 fg_times less_le linorder_not_le mem_ball mem_cball powr_of_int + by (metis (no_types, hide_lams) Diff_iff cball_trivial dist_commute dist_self + eq_iff_diff_eq_0 fg_times less_le linorder_not_le mem_ball mem_cball powr_of_int that) then show ?thesis unfolding not_essential_def fg_def by auto qed - moreover have ?thesis when "fn+gn=0" + moreover have ?thesis when "fn+gn=0" proof - - have "(\w. fp w * gp w) \z\fp z*gp z" + have "(\w. fp w * gp w) \z\fp z*gp z" using that by (auto intro!:tendsto_eq_intros) then have "fg \z\ fp z*gp z" apply (elim Lim_transform_within[OF _ \r1>0\]) @@ -3516,7 +3542,7 @@ by (auto simp add:dist_commute that) then show ?thesis unfolding not_essential_def fg_def by auto qed - moreover have ?thesis when "fn+gn<0" + moreover have ?thesis when "fn+gn<0" proof - have "LIM w (at z). fp w * gp w / (w-z)^nat (-(fn+gn)) :> at_infinity" apply (rule filterlim_divide_at_infinity) @@ -3542,7 +3568,7 @@ define vf where "vf = (\w. inverse (f w))" have ?thesis when "\(\\<^sub>Fw in (at z). f w\0)" proof - - have "\\<^sub>Fw in (at z). f w=0" + have "\\<^sub>Fw in (at z). f w=0" using that[unfolded frequently_def, simplified] by (auto elim: eventually_rev_mp) then have "\\<^sub>Fw in (at z). vf w=0" unfolding vf_def by auto @@ -3588,7 +3614,7 @@ define vf where "vf = (\w. inverse (f w))" have ?thesis when "\(\\<^sub>Fw in (at z). f w\0)" proof - - have "\\<^sub>Fw in (at z). f w=0" + have "\\<^sub>Fw in (at z). f w=0" using that[unfolded frequently_def, simplified] by (auto elim: eventually_rev_mp) then have "\\<^sub>Fw in (at z). vf w=0" unfolding vf_def by auto @@ -3632,7 +3658,7 @@ then show ?thesis by (simp add:field_simps) qed -lemma +lemma assumes f_iso:"isolated_singularity_at f z" and g_iso:"isolated_singularity_at g z" shows isolated_singularity_at_times[singularity_intros]: @@ -3640,21 +3666,21 @@ isolated_singularity_at_add[singularity_intros]: "isolated_singularity_at (\w. f w + g w) z" proof - - obtain d1 d2 where "d1>0" "d2>0" + obtain d1 d2 where "d1>0" "d2>0" and d1:"f analytic_on ball z d1 - {z}" and d2:"g analytic_on ball z d2 - {z}" using f_iso g_iso unfolding isolated_singularity_at_def by auto define d3 where "d3=min d1 d2" have "d3>0" unfolding d3_def using \d1>0\ \d2>0\ by auto - + have "(\w. f w * g w) analytic_on ball z d3 - {z}" apply (rule analytic_on_mult) using d1 d2 unfolding d3_def by (auto elim:analytic_on_subset) - then show "isolated_singularity_at (\w. f w * g w) z" + then show "isolated_singularity_at (\w. f w * g w) z" using \d3>0\ unfolding isolated_singularity_at_def by auto have "(\w. f w + g w) analytic_on ball z d3 - {z}" apply (rule analytic_on_add) using d1 d2 unfolding d3_def by (auto elim:analytic_on_subset) - then show "isolated_singularity_at (\w. f w + g w) z" + then show "isolated_singularity_at (\w. f w + g w) z" using \d3>0\ unfolding isolated_singularity_at_def by auto qed @@ -3689,7 +3715,7 @@ lemma isolated_singularity_at_holomorphic: assumes "f holomorphic_on s-{z}" "open s" "z\s" shows "isolated_singularity_at f z" - using assms unfolding isolated_singularity_at_def + using assms unfolding isolated_singularity_at_def by (metis analytic_on_holomorphic centre_in_ball insert_Diff openE open_delete subset_insert_iff) subsubsection \The order of non-essential singularities (i.e. removable singularities or poles)\ @@ -3709,15 +3735,15 @@ lemma zorder_exist: fixes f::"complex \ complex" and z::complex defines "n\zorder f z" and "g\zor_poly f z" - assumes f_iso:"isolated_singularity_at f z" - and f_ness:"not_essential f z" + assumes f_iso:"isolated_singularity_at f z" + and f_ness:"not_essential f z" and f_nconst:"\\<^sub>Fw in (at z). f w\0" shows "g z\0 \ (\r. r>0 \ g holomorphic_on cball z r \ (\w\cball z r - {z}. f w = g w * (w-z) powr n \ g w \0))" proof - define P where "P = (\n g r. 0 < r \ g holomorphic_on cball z r \ g z\0 \ (\w\cball z r - {z}. f w = g w * (w-z) powr (of_int n) \ g w\0))" - have "\!n. \g r. P n g r" + have "\!n. \g r. P n g r" using holomorphic_factor_puncture[OF assms(3-)] unfolding P_def by auto then have "\g r. P n g r" unfolding n_def P_def zorder_def @@ -3729,27 +3755,27 @@ then show ?thesis unfolding P_def by auto qed -lemma +lemma fixes f::"complex \ complex" and z::complex - assumes f_iso:"isolated_singularity_at f z" - and f_ness:"not_essential f z" + assumes f_iso:"isolated_singularity_at f z" + and f_ness:"not_essential f z" and f_nconst:"\\<^sub>Fw in (at z). f w\0" shows zorder_inverse: "zorder (\w. inverse (f w)) z = - zorder f z" - and zor_poly_inverse: "\\<^sub>Fw in (at z). zor_poly (\w. inverse (f w)) z w + and zor_poly_inverse: "\\<^sub>Fw in (at z). zor_poly (\w. inverse (f w)) z w = inverse (zor_poly f z w)" proof - define vf where "vf = (\w. inverse (f w))" - define fn vfn where + define fn vfn where "fn = zorder f z" and "vfn = zorder vf z" - define fp vfp where + define fp vfp where "fp = zor_poly f z" and "vfp = zor_poly vf z" obtain fr where [simp]:"fp z \ 0" and "fr > 0" - and fr: "fp holomorphic_on cball z fr" + and fr: "fp holomorphic_on cball z fr" "\w\cball z fr - {z}. f w = fp w * (w - z) powr of_int fn \ fp w \ 0" using zorder_exist[OF f_iso f_ness f_nconst,folded fn_def fp_def] by auto - have fr_inverse: "vf w = (inverse (fp w)) * (w - z) powr (of_int (-fn))" + have fr_inverse: "vf w = (inverse (fp w)) * (w - z) powr (of_int (-fn))" and fr_nz: "inverse (fp w)\0" when "w\ball z fr - {z}" for w proof - @@ -3758,14 +3784,14 @@ then show "vf w = (inverse (fp w)) * (w - z) powr (of_int (-fn))" "inverse (fp w)\0" unfolding vf_def by (auto simp add:powr_minus) qed - obtain vfr where [simp]:"vfp z \ 0" and "vfr>0" and vfr:"vfp holomorphic_on cball z vfr" + obtain vfr where [simp]:"vfp z \ 0" and "vfr>0" and vfr:"vfp holomorphic_on cball z vfr" "(\w\cball z vfr - {z}. vf w = vfp w * (w - z) powr of_int vfn \ vfp w \ 0)" proof - - have "isolated_singularity_at vf z" - using isolated_singularity_at_inverse[OF f_iso f_ness] unfolding vf_def . - moreover have "not_essential vf z" + have "isolated_singularity_at vf z" + using isolated_singularity_at_inverse[OF f_iso f_ness] unfolding vf_def . + moreover have "not_essential vf z" using not_essential_inverse[OF f_ness f_iso] unfolding vf_def . - moreover have "\\<^sub>F w in at z. vf w \ 0" + moreover have "\\<^sub>F w in at z. vf w \ 0" using f_nconst unfolding vf_def by (auto elim:frequently_elim1) ultimately show ?thesis using zorder_exist[of vf z, folded vfn_def vfp_def] that by auto qed @@ -3782,11 +3808,11 @@ proof (rule ballI) fix w assume "w \ ball z r1 - {z}" then have "w \ ball z fr - {z}" "w \ cball z vfr - {z}" unfolding r1_def by auto - from fr_inverse[OF this(1)] fr_nz[OF this(1)] vfr(2)[rule_format,OF this(2)] - show "vf w = vfp w * (w - z) powr of_int vfn \ vfp w \ 0 + from fr_inverse[OF this(1)] fr_nz[OF this(1)] vfr(2)[rule_format,OF this(2)] + show "vf w = vfp w * (w - z) powr of_int vfn \ vfp w \ 0 \ vf w = inverse (fp w) * (w - z) powr of_int (- fn) \ inverse (fp w) \ 0" by auto qed - subgoal using vfr(1) unfolding r1_def by (auto intro!:holomorphic_intros) + subgoal using vfr(1) unfolding r1_def by (auto intro!:holomorphic_intros) subgoal using fr unfolding r1_def by (auto intro!:holomorphic_intros) done @@ -3802,28 +3828,28 @@ by (auto simp add:dist_commute) qed -lemma +lemma fixes f g::"complex \ complex" and z::complex - assumes f_iso:"isolated_singularity_at f z" and g_iso:"isolated_singularity_at g z" - and f_ness:"not_essential f z" and g_ness:"not_essential g z" + assumes f_iso:"isolated_singularity_at f z" and g_iso:"isolated_singularity_at g z" + and f_ness:"not_essential f z" and g_ness:"not_essential g z" and fg_nconst: "\\<^sub>Fw in (at z). f w * g w\ 0" shows zorder_times:"zorder (\w. f w * g w) z = zorder f z + zorder g z" and - zor_poly_times:"\\<^sub>Fw in (at z). zor_poly (\w. f w * g w) z w + zor_poly_times:"\\<^sub>Fw in (at z). zor_poly (\w. f w * g w) z w = zor_poly f z w *zor_poly g z w" proof - define fg where "fg = (\w. f w * g w)" - define fn gn fgn where + define fn gn fgn where "fn = zorder f z" and "gn = zorder g z" and "fgn = zorder fg z" - define fp gp fgp where + define fp gp fgp where "fp = zor_poly f z" and "gp = zor_poly g z" and "fgp = zor_poly fg z" have f_nconst:"\\<^sub>Fw in (at z). f w \ 0" and g_nconst:"\\<^sub>Fw in (at z).g w\ 0" using fg_nconst by (auto elim!:frequently_elim1) - obtain fr where [simp]:"fp z \ 0" and "fr > 0" - and fr: "fp holomorphic_on cball z fr" + obtain fr where [simp]:"fp z \ 0" and "fr > 0" + and fr: "fp holomorphic_on cball z fr" "\w\cball z fr - {z}. f w = fp w * (w - z) powr of_int fn \ fp w \ 0" using zorder_exist[OF f_iso f_ness f_nconst,folded fp_def fn_def] by auto - obtain gr where [simp]:"gp z \ 0" and "gr > 0" - and gr: "gp holomorphic_on cball z gr" + obtain gr where [simp]:"gp z \ 0" and "gr > 0" + and gr: "gp holomorphic_on cball z gr" "\w\cball z gr - {z}. g w = gp w * (w - z) powr of_int gn \ gp w \ 0" using zorder_exist[OF g_iso g_ness g_nconst,folded gn_def gp_def] by auto define r1 where "r1=min fr gr" @@ -3840,10 +3866,10 @@ qed obtain fgr where [simp]:"fgp z \ 0" and "fgr > 0" - and fgr: "fgp holomorphic_on cball z fgr" + and fgr: "fgp holomorphic_on cball z fgr" "\w\cball z fgr - {z}. fg w = fgp w * (w - z) powr of_int fgn \ fgp w \ 0" proof - - have "fgp z \ 0 \ (\r>0. fgp holomorphic_on cball z r + have "fgp z \ 0 \ (\r>0. fgp holomorphic_on cball z r \ (\w\cball z r - {z}. fg w = fgp w * (w - z) powr of_int fgn \ fgp w \ 0))" apply (rule zorder_exist[of fg z, folded fgn_def fgp_def]) subgoal unfolding fg_def using isolated_singularity_at_times[OF f_iso g_iso] . @@ -3863,11 +3889,11 @@ proof (rule ballI) fix w assume "w \ ball z r2 - {z}" then have "w \ ball z r1 - {z}" "w \ cball z fgr - {z}" unfolding r2_def by auto - from fg_times[OF this(1)] fgp_nz[OF this(1)] fgr(2)[rule_format,OF this(2)] - show "fg w = fgp w * (w - z) powr of_int fgn \ fgp w \ 0 + from fg_times[OF this(1)] fgp_nz[OF this(1)] fgr(2)[rule_format,OF this(2)] + show "fg w = fgp w * (w - z) powr of_int fgn \ fgp w \ 0 \ fg w = fp w * gp w * (w - z) powr of_int (fn + gn) \ fp w * gp w \ 0" by auto qed - subgoal using fgr(1) unfolding r2_def r1_def by (auto intro!:holomorphic_intros) + subgoal using fgr(1) unfolding r2_def r1_def by (auto intro!:holomorphic_intros) subgoal using fr(1) gr(1) unfolding r2_def r1_def by (auto intro!:holomorphic_intros) done @@ -3877,17 +3903,17 @@ from fg_times[OF this(1)] fgp_nz[OF this(1)] fgr(2)[rule_format,OF this(2)] \fgn = fn + gn\ \w\z\ show ?thesis by auto qed - then show "\\<^sub>Fw in (at z). fgp w = fp w * gp w" + then show "\\<^sub>Fw in (at z). fgp w = fp w * gp w" using \r2>0\ unfolding eventually_at by (auto simp add:dist_commute) qed -lemma +lemma fixes f g::"complex \ complex" and z::complex - assumes f_iso:"isolated_singularity_at f z" and g_iso:"isolated_singularity_at g z" - and f_ness:"not_essential f z" and g_ness:"not_essential g z" + assumes f_iso:"isolated_singularity_at f z" and g_iso:"isolated_singularity_at g z" + and f_ness:"not_essential f z" and g_ness:"not_essential g z" and fg_nconst: "\\<^sub>Fw in (at z). f w * g w\ 0" shows zorder_divide:"zorder (\w. f w / g w) z = zorder f z - zorder g z" and - zor_poly_divide:"\\<^sub>Fw in (at z). zor_poly (\w. f w / g w) z w + zor_poly_divide:"\\<^sub>Fw in (at z). zor_poly (\w. f w / g w) z w = zor_poly f z w / zor_poly g z w" proof - have f_nconst:"\\<^sub>Fw in (at z). f w \ 0" and g_nconst:"\\<^sub>Fw in (at z).g w\ 0" @@ -3900,7 +3926,7 @@ subgoal unfolding vg_def using fg_nconst by (auto elim!:frequently_elim1) done then show "zorder (\w. f w / g w) z = zorder f z - zorder g z" - using zorder_inverse[OF g_iso g_ness g_nconst,folded vg_def] unfolding vg_def + using zorder_inverse[OF g_iso g_ness g_nconst,folded vg_def] unfolding vg_def by (auto simp add:field_simps) have "\\<^sub>F w in at z. zor_poly (\w. f w * vg w) z w = zor_poly f z w * zor_poly vg z w" @@ -3918,28 +3944,28 @@ lemma zorder_exist_zero: fixes f::"complex \ complex" and z::complex defines "n\zorder f z" and "g\zor_poly f z" - assumes holo: "f holomorphic_on s" and + assumes holo: "f holomorphic_on s" and "open s" "connected s" "z\s" and non_const: "\w\s. f w \ 0" shows "(if f z=0 then n > 0 else n=0) \ (\r. r>0 \ cball z r \ s \ g holomorphic_on cball z r \ (\w\cball z r. f w = g w * (w-z) ^ nat n \ g w \0))" proof - - obtain r where "g z \ 0" and r: "r>0" "cball z r \ s" "g holomorphic_on cball z r" + obtain r where "g z \ 0" and r: "r>0" "cball z r \ s" "g holomorphic_on cball z r" "(\w\cball z r - {z}. f w = g w * (w - z) powr of_int n \ g w \ 0)" proof - - have "g z \ 0 \ (\r>0. g holomorphic_on cball z r + have "g z \ 0 \ (\r>0. g holomorphic_on cball z r \ (\w\cball z r - {z}. f w = g w * (w - z) powr of_int n \ g w \ 0))" proof (rule zorder_exist[of f z,folded g_def n_def]) show "isolated_singularity_at f z" unfolding isolated_singularity_at_def using holo assms(4,6) by (meson Diff_subset open_ball analytic_on_holomorphic holomorphic_on_subset openE) - show "not_essential f z" unfolding not_essential_def - using assms(4,6) at_within_open continuous_on holo holomorphic_on_imp_continuous_on + show "not_essential f z" unfolding not_essential_def + using assms(4,6) at_within_open continuous_on holo holomorphic_on_imp_continuous_on by fastforce have "\\<^sub>F w in at z. f w \ 0 \ w\s" proof - obtain w where "w\s" "f w\0" using non_const by auto - then show ?thesis + then show ?thesis by (rule non_zero_neighbour_alt[OF holo \open s\ \connected s\ \z\s\]) qed then show "\\<^sub>F w in at z. f w \ 0" @@ -3949,18 +3975,18 @@ then obtain r1 where "g z \ 0" "r1>0" and r1:"g holomorphic_on cball z r1" "(\w\cball z r1 - {z}. f w = g w * (w - z) powr of_int n \ g w \ 0)" by auto - obtain r2 where r2: "r2>0" "cball z r2 \ s" + obtain r2 where r2: "r2>0" "cball z r2 \ s" using assms(4,6) open_contains_cball_eq by blast define r3 where "r3=min r1 r2" have "r3>0" "cball z r3 \ s" using \r1>0\ r2 unfolding r3_def by auto - moreover have "g holomorphic_on cball z r3" + moreover have "g holomorphic_on cball z r3" using r1(1) unfolding r3_def by auto - moreover have "(\w\cball z r3 - {z}. f w = g w * (w - z) powr of_int n \ g w \ 0)" + moreover have "(\w\cball z r3 - {z}. f w = g w * (w - z) powr of_int n \ g w \ 0)" using r1(2) unfolding r3_def by auto - ultimately show ?thesis using that[of r3] \g z\0\ by auto + ultimately show ?thesis using that[of r3] \g z\0\ by auto qed - have if_0:"if f z=0 then n > 0 else n=0" + have if_0:"if f z=0 then n > 0 else n=0" proof - have "f\ z \ f z" by (metis assms(4,6,7) at_within_open continuous_on holo holomorphic_on_imp_continuous_on) @@ -3968,7 +3994,7 @@ apply (elim Lim_transform_within_open[where s="ball z r"]) using r by auto moreover have "g \z\g z" - by (metis (mono_tags, lifting) open_ball at_within_open_subset + by (metis (mono_tags, lifting) open_ball at_within_open_subset ball_subset_cball centre_in_ball continuous_on holomorphic_on_imp_continuous_on r(1,3) subsetCE) ultimately have "(\w. (g w * (w - z) powr of_int n) / g w) \z\ f z/g z" apply (rule_tac tendsto_divide) @@ -3977,10 +4003,10 @@ apply (elim Lim_transform_within_open[where s="ball z r"]) using r by auto - have ?thesis when "n\0" "f z=0" + have ?thesis when "n\0" "f z=0" proof - have "(\w. (w - z) ^ nat n) \z\ f z/g z" - using powr_tendsto + using powr_tendsto apply (elim Lim_transform_within[where d=r]) by (auto simp add: powr_of_int \n\0\ \r>0\) then have *:"(\w. (w - z) ^ nat n) \z\ 0" using \f z=0\ by simp @@ -3992,12 +4018,12 @@ qed ultimately show ?thesis using that by fastforce qed - moreover have ?thesis when "n\0" "f z\0" + moreover have ?thesis when "n\0" "f z\0" proof - have False when "n>0" proof - have "(\w. (w - z) ^ nat n) \z\ f z/g z" - using powr_tendsto + using powr_tendsto apply (elim Lim_transform_within[where d=r]) by (auto simp add: powr_of_int \n\0\ \r>0\) moreover have "(\w. (w - z) ^ nat n) \z\ 0" @@ -4014,9 +4040,9 @@ by (elim Lim_transform_within_open[where s=UNIV],auto) subgoal using that by (auto intro!:tendsto_eq_intros) done - from tendsto_mult[OF this,simplified] + from tendsto_mult[OF this,simplified] have "(\x. inverse ((x - z) ^ nat (- n)) * (x - z) ^ nat (- n)) \z\ 0" . - then have "(\x. 1::complex) \z\ 0" + then have "(\x. 1::complex) \z\ 0" by (elim Lim_transform_within_open[where s=UNIV],auto) then show False using LIM_const_eq by fastforce qed @@ -4025,7 +4051,7 @@ moreover have "f w = g w * (w-z) ^ nat n \ g w \0" when "w\cball z r" for w proof (cases "w=z") case True - then have "f \z\f w" + then have "f \z\f w" using assms(4,6) at_within_open continuous_on holo holomorphic_on_imp_continuous_on by fastforce then have "(\w. g w * (w-z) ^ nat n) \z\f w" proof (elim Lim_transform_within[OF _ \r>0\]) @@ -4041,7 +4067,7 @@ qed moreover have "(\w. g w * (w-z) ^ nat n) \z\ g w * (w-z) ^ nat n" using True apply (auto intro!:tendsto_eq_intros) - by (metis open_ball at_within_open_subset ball_subset_cball centre_in_ball + by (metis open_ball at_within_open_subset ball_subset_cball centre_in_ball continuous_on holomorphic_on_imp_continuous_on r(1) r(3) that) ultimately have "f w = g w * (w-z) ^ nat n" using LIM_unique by blast then show ?thesis using \g z\0\ True by auto @@ -4057,23 +4083,23 @@ lemma zorder_exist_pole: fixes f::"complex \ complex" and z::complex defines "n\zorder f z" and "g\zor_poly f z" - assumes holo: "f holomorphic_on s-{z}" and + assumes holo: "f holomorphic_on s-{z}" and "open s" "z\s" and "is_pole f z" shows "n < 0 \ g z\0 \ (\r. r>0 \ cball z r \ s \ g holomorphic_on cball z r \ (\w\cball z r - {z}. f w = g w / (w-z) ^ nat (- n) \ g w \0))" proof - - obtain r where "g z \ 0" and r: "r>0" "cball z r \ s" "g holomorphic_on cball z r" + obtain r where "g z \ 0" and r: "r>0" "cball z r \ s" "g holomorphic_on cball z r" "(\w\cball z r - {z}. f w = g w * (w - z) powr of_int n \ g w \ 0)" proof - - have "g z \ 0 \ (\r>0. g holomorphic_on cball z r + have "g z \ 0 \ (\r>0. g holomorphic_on cball z r \ (\w\cball z r - {z}. f w = g w * (w - z) powr of_int n \ g w \ 0))" proof (rule zorder_exist[of f z,folded g_def n_def]) show "isolated_singularity_at f z" unfolding isolated_singularity_at_def using holo assms(4,5) by (metis analytic_on_holomorphic centre_in_ball insert_Diff openE open_delete subset_insert_iff) - show "not_essential f z" unfolding not_essential_def - using assms(4,6) at_within_open continuous_on holo holomorphic_on_imp_continuous_on + show "not_essential f z" unfolding not_essential_def + using assms(4,6) at_within_open continuous_on holo holomorphic_on_imp_continuous_on by fastforce from non_zero_neighbour_pole[OF \is_pole f z\] show "\\<^sub>F w in at z. f w \ 0" apply (elim eventually_frequentlyE) @@ -4082,23 +4108,23 @@ then obtain r1 where "g z \ 0" "r1>0" and r1:"g holomorphic_on cball z r1" "(\w\cball z r1 - {z}. f w = g w * (w - z) powr of_int n \ g w \ 0)" by auto - obtain r2 where r2: "r2>0" "cball z r2 \ s" + obtain r2 where r2: "r2>0" "cball z r2 \ s" using assms(4,5) open_contains_cball_eq by metis define r3 where "r3=min r1 r2" have "r3>0" "cball z r3 \ s" using \r1>0\ r2 unfolding r3_def by auto - moreover have "g holomorphic_on cball z r3" + moreover have "g holomorphic_on cball z r3" using r1(1) unfolding r3_def by auto - moreover have "(\w\cball z r3 - {z}. f w = g w * (w - z) powr of_int n \ g w \ 0)" + moreover have "(\w\cball z r3 - {z}. f w = g w * (w - z) powr of_int n \ g w \ 0)" using r1(2) unfolding r3_def by auto - ultimately show ?thesis using that[of r3] \g z\0\ by auto + ultimately show ?thesis using that[of r3] \g z\0\ by auto qed have "n<0" proof (rule ccontr) assume " \ n < 0" define c where "c=(if n=0 then g z else 0)" - have [simp]:"g \z\ g z" - by (metis open_ball at_within_open ball_subset_cball centre_in_ball + have [simp]:"g \z\ g z" + by (metis open_ball at_within_open ball_subset_cball centre_in_ball continuous_on holomorphic_on_imp_continuous_on holomorphic_on_subset r(1) r(3) ) have "\\<^sub>F x in at z. f x = g x * (x - z) ^ nat n" unfolding eventually_at_topological @@ -4112,15 +4138,15 @@ case False then have "(\x. (x - z) ^ nat n) \z\ 0" using \\ n < 0\ by (auto intro!:tendsto_eq_intros) - from tendsto_mult[OF _ this,of g "g z",simplified] + from tendsto_mult[OF _ this,of g "g z",simplified] show ?thesis unfolding c_def using False by simp qed ultimately have "f \z\c" using tendsto_cong by fast - then show False using \is_pole f z\ at_neq_bot not_tendsto_and_filterlim_at_infinity + then show False using \is_pole f z\ at_neq_bot not_tendsto_and_filterlim_at_infinity unfolding is_pole_def by blast qed moreover have "\w\cball z r - {z}. f w = g w / (w-z) ^ nat (- n) \ g w \0" - using r(4) \n<0\ powr_of_int + using r(4) \n<0\ powr_of_int by (metis Diff_iff divide_inverse eq_iff_diff_eq_0 insert_iff linorder_not_le) ultimately show ?thesis using r(1-3) \g z\0\ by auto qed @@ -4157,32 +4183,32 @@ next have "not_essential ?gg z" proof (intro singularity_intros) - show "not_essential g z" - by (meson \continuous_on s g\ assms(1) assms(2) continuous_on_eq_continuous_at + show "not_essential g z" + by (meson \continuous_on s g\ assms(1) assms(2) continuous_on_eq_continuous_at isCont_def not_essential_def) show " \\<^sub>F w in at z. w - z \ 0" by (simp add: eventually_at_filter) - then show "LIM w at z. w - z :> at 0" + then show "LIM w at z. w - z :> at 0" unfolding filterlim_at by (auto intro:tendsto_eq_intros) - show "isolated_singularity_at g z" - by (meson Diff_subset open_ball analytic_on_holomorphic + show "isolated_singularity_at g z" + by (meson Diff_subset open_ball analytic_on_holomorphic assms(1,2,3) holomorphic_on_subset isolated_singularity_at_def openE) qed then show "not_essential f z" apply (elim not_essential_transform) - unfolding eventually_at using assms(1,2) assms(5)[symmetric] + unfolding eventually_at using assms(1,2) assms(5)[symmetric] by (metis dist_commute mem_ball openE subsetCE) - show "\\<^sub>F w in at z. f w \ 0" unfolding frequently_at + show "\\<^sub>F w in at z. f w \ 0" unfolding frequently_at proof (rule,rule) fix d::real assume "0 < d" define z' where "z'=z+min d r / 2" have "z' \ z" " dist z' z < d " - unfolding z'_def using \d>0\ \r>0\ + unfolding z'_def using \d>0\ \r>0\ by (auto simp add:dist_norm) - moreover have "f z' \ 0" + moreover have "f z' \ 0" proof (subst fg_eq[OF _ \z'\z\]) have "z' \ cball z r" unfolding z'_def using \r>0\ \d>0\ by (auto simp add:dist_norm) then show " z' \ s" using r(2) by blast - show "g z' * (z' - z) powr of_int n \ 0" + show "g z' * (z' - z) powr of_int n \ 0" using P_def \P n g r\ \z' \ cball z r\ calculation(1) by auto qed ultimately show "\x\UNIV. x \ z \ dist x z < d \ f x \ 0" by auto @@ -4206,7 +4232,7 @@ obtain r where "0 < n" "0 < r" and r_cball:"cball z r \ ball z e" and h_holo: "h holomorphic_on cball z r" and h_divide:"(\w\cball z r. (w\z \ f w = h w / (w - z) ^ n) \ h w \ 0)" proof - - obtain r where r:"zorder f z < 0" "h z \ 0" "r>0" "cball z r \ ball z e" "h holomorphic_on cball z r" + obtain r where r:"zorder f z < 0" "h z \ 0" "r>0" "cball z r \ ball z e" "h holomorphic_on cball z r" "(\w\cball z r - {z}. f w = h w / (w - z) ^ n \ h w \ 0)" using zorder_exist_pole[OF f_holo,simplified,OF \is_pole f z\,folded n_def h_def] by auto have "n>0" using \zorder f z < 0\ unfolding n_def by simp @@ -4235,7 +4261,7 @@ then show "h' x = f x" using h_divide unfolding h'_def by auto qed moreover have "(f has_contour_integral c * residue f z) (circlepath z r)" - using base_residue[of \ball z e\ z,simplified,OF \r>0\ f_holo r_cball,folded c_def] + using base_residue[of \ball z e\ z,simplified,OF \r>0\ f_holo r_cball,folded c_def] unfolding c_def by simp ultimately have "c * der_f = c * residue f z" using has_contour_integral_unique by blast hence "der_f = residue f z" unfolding c_def by auto @@ -4249,7 +4275,7 @@ using assms(1-4) by (rule zorder_eqI) (use assms(5) in auto) lemma higher_deriv_power: - shows "(deriv ^^ j) (\w. (w - z) ^ n) w = + shows "(deriv ^^ j) (\w. (w - z) ^ n) w = pochhammer (of_nat (Suc n - j)) j * (w - z) ^ (n - j)" proof (induction j arbitrary: w) case 0 @@ -4258,16 +4284,16 @@ case (Suc j w) have "(deriv ^^ Suc j) (\w. (w - z) ^ n) w = deriv ((deriv ^^ j) (\w. (w - z) ^ n)) w" by simp - also have "(deriv ^^ j) (\w. (w - z) ^ n) = + also have "(deriv ^^ j) (\w. (w - z) ^ n) = (\w. pochhammer (of_nat (Suc n - j)) j * (w - z) ^ (n - j))" using Suc by (intro Suc.IH ext) also { have "(\ has_field_derivative of_nat (n - j) * pochhammer (of_nat (Suc n - j)) j * (w - z) ^ (n - Suc j)) (at w)" using Suc.prems by (auto intro!: derivative_eq_intros) - also have "of_nat (n - j) * pochhammer (of_nat (Suc n - j)) j = + also have "of_nat (n - j) * pochhammer (of_nat (Suc n - j)) j = pochhammer (of_nat (Suc n - Suc j)) (Suc j)" - by (cases "Suc j \ n", subst pochhammer_rec) + by (cases "Suc j \ n", subst pochhammer_rec) (insert Suc.prems, simp_all add: algebra_simps Suc_diff_le pochhammer_0_left) finally have "deriv (\w. pochhammer (of_nat (Suc n - j)) j * (w - z) ^ (n - j)) w = \ * (w - z) ^ (n - Suc j)" @@ -4288,7 +4314,7 @@ proof (rule ccontr) assume "\ (\w\ball z r. f w \ 0)" then have "eventually (\u. f u = 0) (nhds z)" - using \r>0\ unfolding eventually_nhds + using \r>0\ unfolding eventually_nhds apply (rule_tac x="ball z r" in exI) by auto then have "(deriv ^^ nat n) f z = (deriv ^^ nat n) (\_. 0) z" @@ -4310,7 +4336,7 @@ show ?thesis by blast qed from this(1,2,5) have "zn\0" "g z\0" - subgoal by (auto split:if_splits) + subgoal by (auto split:if_splits) subgoal using \0 < e\ ball_subset_cball centre_in_ball e_fac by blast done @@ -4320,25 +4346,25 @@ have "eventually (\w. w \ ball z e) (nhds z)" using \cball z e \ ball z r\ \e>0\ by (intro eventually_nhds_in_open) auto hence "eventually (\w. f w = (w - z) ^ (nat zn) * g w) (nhds z)" - apply eventually_elim + apply eventually_elim by (use e_fac in auto) hence "(deriv ^^ i) f z = (deriv ^^ i) (\w. (w - z) ^ nat zn * g w) z" by (intro higher_deriv_cong_ev) auto also have "\ = (\j=0..i. of_nat (i choose j) * (deriv ^^ j) (\w. (w - z) ^ nat zn) z * (deriv ^^ (i - j)) g z)" - using g_holo \e>0\ + using g_holo \e>0\ by (intro higher_deriv_mult[of _ "ball z e"]) (auto intro!: holomorphic_intros) - also have "\ = (\j=0..i. if j = nat zn then + also have "\ = (\j=0..i. if j = nat zn then of_nat (i choose nat zn) * fact (nat zn) * (deriv ^^ (i - nat zn)) g z else 0)" proof (intro sum.cong refl, goal_cases) case (1 j) - have "(deriv ^^ j) (\w. (w - z) ^ nat zn) z = + have "(deriv ^^ j) (\w. (w - z) ^ nat zn) z = pochhammer (of_nat (Suc (nat zn) - j)) j * 0 ^ (nat zn - j)" by (subst higher_deriv_power) auto also have "\ = (if j = nat zn then fact j else 0)" by (auto simp: not_less pochhammer_0_left pochhammer_fact) - also have "of_nat (i choose j) * \ * (deriv ^^ (i - j)) g z = - (if j = nat zn then of_nat (i choose (nat zn)) * fact (nat zn) + also have "of_nat (i choose j) * \ * (deriv ^^ (i - j)) g z = + (if j = nat zn then of_nat (i choose (nat zn)) * fact (nat zn) * (deriv ^^ (i - nat zn)) g z else 0)" by simp finally show ?case . @@ -4351,12 +4377,12 @@ have False when "nn\0\ by auto + using deriv_A[of "nat n"] that \n\0\ by auto with nz show False by auto qed moreover have "n\zn" proof - - have "g z \ 0" using e_fac[rule_format,of z] \e>0\ by simp + have "g z \ 0" using e_fac[rule_format,of z] \e>0\ by simp then have "(deriv ^^ nat zn) f z \ 0" using deriv_A[of "nat zn"] by(auto simp add:A_def) then have "nat zn \ nat n" using zero[of "nat zn"] by linarith @@ -4366,15 +4392,15 @@ ultimately show ?thesis unfolding zn_def by fastforce qed -lemma +lemma assumes "eventually (\z. f z = g z) (at z)" "z = z'" shows zorder_cong:"zorder f z = zorder g z'" and zor_poly_cong:"zor_poly f z = zor_poly g z'" proof - define P where "P = (\ff n h r. 0 < r \ h holomorphic_on cball z r \ h z\0 \ (\w\cball z r - {z}. ff w = h w * (w-z) powr (of_int n) \ h w\0))" - have "(\r. P f n h r) = (\r. P g n h r)" for n h + have "(\r. P f n h r) = (\r. P g n h r)" for n h proof - - have *: "\r. P g n h r" if "\r. P f n h r" and "eventually (\x. f x = g x) (at z)" for f g + have *: "\r. P g n h r" if "\r. P f n h r" and "eventually (\x. f x = g x) (at z)" for f g proof - from that(1) obtain r1 where r1_P:"P f n h r1" by auto from that(2) obtain r2 where "r2>0" and r2_dist:"\x. x \ z \ dist x z \ r2 \ f x = g x" @@ -4387,8 +4413,8 @@ proof - have "f w = h w * (w - z) powr of_int n \ h w \ 0" using r1_P that unfolding P_def r_def by auto - moreover have "f w=g w" using r2_dist[rule_format,of w] that unfolding r_def - by (simp add: dist_commute) + moreover have "f w=g w" using r2_dist[rule_format,of w] that unfolding r_def + by (simp add: dist_commute) ultimately show ?thesis by simp qed ultimately show ?thesis unfolding P_def by auto @@ -4398,7 +4424,7 @@ show ?thesis by (rule iffI[OF *[OF _ assms(1)] *[OF _ eq']]) qed - then show "zorder f z = zorder g z'" "zor_poly f z = zor_poly g z'" + then show "zorder f z = zorder g z'" "zor_poly f z = zor_poly g z'" using \z=z'\ unfolding P_def zorder_def zor_poly_def by auto qed @@ -4413,10 +4439,10 @@ assumes "isolated_singularity_at f z" "not_essential f z" "\\<^sub>F w in at z. f w \ 0" shows "eventually (\w. zor_poly f z w = f w * (w - z) powr - zorder f z) (at z)" proof - - obtain r where r:"r>0" + obtain r where r:"r>0" "(\w\cball z r - {z}. f w = zor_poly f z w * (w - z) powr of_int (zorder f z))" using zorder_exist[OF assms] by blast - then have *: "\w\ball z r - {z}. zor_poly f z w = f w * (w - z) powr - zorder f z" + then have *: "\w\ball z r - {z}. zor_poly f z w = f w * (w - z) powr - zorder f z" by (auto simp: field_simps powr_minus) have "eventually (\w. w \ ball z r - {z}) (at z)" using r eventually_at_ball'[of r z UNIV] by auto @@ -4427,10 +4453,10 @@ assumes "f holomorphic_on s" "open s" "connected s" "z \ s" "\w\s. f w \ 0" shows "eventually (\w. zor_poly f z w = f w / (w - z) ^ nat (zorder f z)) (at z)" proof - - obtain r where r:"r>0" + obtain r where r:"r>0" "(\w\cball z r - {z}. f w = zor_poly f z w * (w - z) ^ nat (zorder f z))" using zorder_exist_zero[OF assms] by auto - then have *: "\w\ball z r - {z}. zor_poly f z w = f w / (w - z) ^ nat (zorder f z)" + then have *: "\w\ball z r - {z}. zor_poly f z w = f w / (w - z) ^ nat (zorder f z)" by (auto simp: field_simps powr_minus) have "eventually (\w. w \ ball z r - {z}) (at z)" using r eventually_at_ball'[of r z UNIV] by auto @@ -4443,10 +4469,10 @@ proof - obtain e where [simp]:"e>0" and f_holo:"f holomorphic_on ball z e - {z}" using f_iso analytic_imp_holomorphic unfolding isolated_singularity_at_def by blast - obtain r where r:"r>0" + obtain r where r:"r>0" "(\w\cball z r - {z}. f w = zor_poly f z w / (w - z) ^ nat (- zorder f z))" using zorder_exist_pole[OF f_holo,simplified,OF \is_pole f z\] by auto - then have *: "\w\ball z r - {z}. zor_poly f z w = f w * (w - z) ^ nat (- zorder f z)" + then have *: "\w\ball z r - {z}. zor_poly f z w = f w * (w - z) ^ nat (- zorder f z)" by (auto simp: field_simps) have "eventually (\w. w \ ball z r - {z}) (at z)" using r eventually_at_ball'[of r z UNIV] by auto @@ -4520,8 +4546,8 @@ shows "zor_poly f z0 z0 = c" proof - obtain r where r: "r > 0" "zor_poly f z0 holomorphic_on cball z0 r" - proof - - have "\\<^sub>F w in at z0. f w \ 0" + proof - + have "\\<^sub>F w in at z0. f w \ 0" using non_zero_neighbour_pole[OF \is_pole f z0\] by (auto elim:eventually_frequentlyE) moreover have "not_essential f z0" unfolding not_essential_def using \is_pole f z0\ by simp ultimately show ?thesis using that zorder_exist[OF f_iso,folded n_def] by auto @@ -4544,13 +4570,13 @@ qed lemma residue_simple_pole: - assumes "isolated_singularity_at f z0" + assumes "isolated_singularity_at f z0" assumes "is_pole f z0" "zorder f z0 = - 1" shows "residue f z0 = zor_poly f z0 z0" using assms by (subst residue_pole_order) simp_all lemma residue_simple_pole_limit: - assumes "isolated_singularity_at f z0" + assumes "isolated_singularity_at f z0" assumes "is_pole f z0" "zorder f z0 = - 1" assumes "((\x. f (g x) * (g x - z0)) \ c) F" assumes "filterlim g (at z0) F" "F \ bot" @@ -4565,7 +4591,7 @@ qed lemma lhopital_complex_simple: - assumes "(f has_field_derivative f') (at z)" + assumes "(f has_field_derivative f') (at z)" assumes "(g has_field_derivative g') (at z)" assumes "f z = 0" "g z = 0" "g' \ 0" "f' / g' = c" shows "((\w. f w / g w) \ c) (at z)" @@ -4582,8 +4608,8 @@ qed lemma - assumes f_holo:"f holomorphic_on s" and g_holo:"g holomorphic_on s" - and "open s" "connected s" "z \ s" + assumes f_holo:"f holomorphic_on s" and g_holo:"g holomorphic_on s" + and "open s" "connected s" "z \ s" assumes g_deriv:"(g has_field_derivative g') (at z)" assumes "f z \ 0" "g z = 0" "g' \ 0" shows porder_simple_pole_deriv: "zorder (\w. f w / g w) z = - 1" @@ -4595,11 +4621,11 @@ have [simp]:"not_essential f z" "not_essential g z" unfolding not_essential_def using f_holo g_holo assms(3,5) by (meson continuous_on_eq_continuous_at continuous_within holomorphic_on_imp_continuous_on)+ - have g_nconst:"\\<^sub>F w in at z. g w \0 " + have g_nconst:"\\<^sub>F w in at z. g w \0 " proof (rule ccontr) assume "\ (\\<^sub>F w in at z. g w \ 0)" then have "\\<^sub>F w in nhds z. g w = 0" - unfolding eventually_at eventually_nhds frequently_at using \g z = 0\ + unfolding eventually_at eventually_nhds frequently_at using \g z = 0\ by (metis open_ball UNIV_I centre_in_ball dist_commute mem_ball) then have "deriv g z = deriv (\_. 0) z" by (intro deriv_cong_ev) auto @@ -4607,13 +4633,13 @@ then have "g' = 0" using g_deriv DERIV_imp_deriv by blast then show False using \g'\0\ by auto qed - + have "zorder (\w. f w / g w) z = zorder f z - zorder g z" proof - - have "\\<^sub>F w in at z. f w \0 \ w\s" + have "\\<^sub>F w in at z. f w \0 \ w\s" apply (rule non_zero_neighbour_alt) using assms by auto - with g_nconst have "\\<^sub>F w in at z. f w * g w \ 0" + with g_nconst have "\\<^sub>F w in at z. f w * g w \ 0" by (elim frequently_rev_mp eventually_rev_mp,auto) then show ?thesis using zorder_divide[of f z g] by auto qed @@ -4627,22 +4653,22 @@ subgoal by simp done ultimately show "zorder (\w. f w / g w) z = - 1" by auto - + show "residue (\w. f w / g w) z = f z / g'" proof (rule residue_simple_pole_limit[where g=id and F="at z",simplified]) show "zorder (\w. f w / g w) z = - 1" by fact - show "isolated_singularity_at (\w. f w / g w) z" + show "isolated_singularity_at (\w. f w / g w) z" by (auto intro: singularity_intros) - show "is_pole (\w. f w / g w) z" + show "is_pole (\w. f w / g w) z" proof (rule is_pole_divide) - have "\\<^sub>F x in at z. g x \ 0" + have "\\<^sub>F x in at z. g x \ 0" apply (rule non_zero_neighbour) using g_nconst by auto - moreover have "g \z\ 0" + moreover have "g \z\ 0" using DERIV_isCont assms(8) continuous_at g_deriv by force ultimately show "filterlim g (at 0) (at z)" unfolding filterlim_at by simp - show "isCont f z" - using assms(3,5) continuous_on_eq_continuous_at f_holo holomorphic_on_imp_continuous_on + show "isCont f z" + using assms(3,5) continuous_on_eq_continuous_at f_holo holomorphic_on_imp_continuous_on by auto show "f z \ 0" by fact qed @@ -4702,10 +4728,10 @@ have "f holomorphic_on ball p e1 - {p}" apply (intro holomorphic_on_subset[OF f_holo]) using e1_avoid \p\pz\ unfolding avoid_def pz_def by force - then show ?thesis unfolding isolated_singularity_at_def + then show ?thesis unfolding isolated_singularity_at_def using \e1>0\ analytic_on_open open_delete by blast qed - moreover have "not_essential f p" + moreover have "not_essential f p" proof (cases "is_pole f p") case True then show ?thesis unfolding not_essential_def by auto @@ -4713,7 +4739,7 @@ case False then have "p\s-poles" using \p\s\ poles unfolding pz_def by auto moreover have "open (s-poles)" - using \open s\ + using \open s\ apply (elim open_Diff) apply (rule finite_imp_closed) using finite unfolding pz_def by simp @@ -4721,7 +4747,7 @@ using holomorphic_on_imp_continuous_on[OF f_holo] continuous_on_eq_continuous_at by auto then show ?thesis unfolding isCont_def not_essential_def by auto - qed + qed moreover have "\\<^sub>F w in at p. f w \ 0 " proof (rule ccontr) assume "\ (\\<^sub>F w in at p. f w \ 0)" @@ -4735,17 +4761,17 @@ unfolding pz_def infinite_super by auto then show False using \finite pz\ by auto qed - ultimately obtain r where "pp p \ 0" and r:"r>0" "pp holomorphic_on cball p r" + ultimately obtain r where "pp p \ 0" and r:"r>0" "pp holomorphic_on cball p r" "(\w\cball p r - {p}. f w = pp w * (w - p) powr of_int po \ pp w \ 0)" using zorder_exist[of f p,folded po_def pp_def] by auto define r1 where "r1=min r e1 / 2" have "r1e1>0\ \r>0\ by auto - moreover have "r1>0" "pp holomorphic_on cball p r1" + moreover have "r1>0" "pp holomorphic_on cball p r1" "(\w\cball p r1 - {p}. f w = pp w * (w - p) powr of_int po \ pp w \ 0)" unfolding r1_def using \e1>0\ r by auto ultimately show ?thesis using that \pp p\0\ by auto qed - + define e2 where "e2 \ r/2" have "e2>0" using \r>0\ unfolding e2_def by auto define anal where "anal \ \w. deriv pp w * h w / pp w" @@ -4780,7 +4806,7 @@ have "(pp has_field_derivative (deriv pp w)) (at w)" using DERIV_deriv_iff_has_field_derivative pp_holo \w\p\ by (meson open_ball \w \ ball p r\ ball_subset_cball holomorphic_derivI holomorphic_on_subset) - then show " (f' has_field_derivative of_int po * pp w * (w - p) powr of_int (po - 1) + then show " (f' has_field_derivative of_int po * pp w * (w - p) powr of_int (po - 1) + deriv pp w * (w - p) powr of_int po) (at w)" unfolding f'_def using \w\p\ by (auto intro!: derivative_eq_intros DERIV_cong[OF has_field_derivative_powr_of_int]) @@ -4805,7 +4831,7 @@ have "ball p e1 - {p} \ s - poles" using ball_subset_cball e1_avoid[unfolded avoid_def] unfolding pz_def by auto - then have "ball p r - {p} \ s - poles" + then have "ball p r - {p} \ s - poles" apply (elim dual_order.trans) using \r by auto then show "f holomorphic_on ball p r - {p}" using f_holo @@ -4979,7 +5005,7 @@ ultimately have "(h has_field_derivative der t) (at t)" unfolding h_def der_def using g_holo f_holo \open s\ by (auto intro!: holomorphic_derivI derivative_eq_intros) - then show "h field_differentiable at (\ x)" + then show "h field_differentiable at (\ x)" unfolding t_def field_differentiable_def by blast qed then have " ((/) 1 has_contour_integral 0) (h \ \) diff -r 98308c6582ed -r 3e374c65f96b src/HOL/Analysis/Further_Topology.thy --- a/src/HOL/Analysis/Further_Topology.thy Sat Nov 02 14:31:48 2019 +0000 +++ b/src/HOL/Analysis/Further_Topology.thy Sat Nov 02 15:52:47 2019 +0000 @@ -2748,6 +2748,256 @@ using clopen [of S] False by simp qed +subsection\Formulation of loop homotopy in terms of maps out of type complex\ + +lemma homotopic_circlemaps_imp_homotopic_loops: + assumes "homotopic_with_canon (\h. True) (sphere 0 1) S f g" + shows "homotopic_loops S (f \ exp \ (\t. 2 * of_real pi * of_real t * \)) + (g \ exp \ (\t. 2 * of_real pi * of_real t * \))" +proof - + have "homotopic_with_canon (\f. True) {z. cmod z = 1} S f g" + using assms by (auto simp: sphere_def) + moreover have "continuous_on {0..1} (exp \ (\t. 2 * of_real pi * of_real t * \))" + by (intro continuous_intros) + moreover have "(exp \ (\t. 2 * of_real pi * of_real t * \)) ` {0..1} \ {z. cmod z = 1}" + by (auto simp: norm_mult) + ultimately + show ?thesis + apply (simp add: homotopic_loops_def comp_assoc) + apply (rule homotopic_with_compose_continuous_right) + apply (auto simp: pathstart_def pathfinish_def) + done +qed + +lemma homotopic_loops_imp_homotopic_circlemaps: + assumes "homotopic_loops S p q" + shows "homotopic_with_canon (\h. True) (sphere 0 1) S + (p \ (\z. (Arg2pi z / (2 * pi)))) + (q \ (\z. (Arg2pi z / (2 * pi))))" +proof - + obtain h where conth: "continuous_on ({0..1::real} \ {0..1}) h" + and him: "h ` ({0..1} \ {0..1}) \ S" + and h0: "(\x. h (0, x) = p x)" + and h1: "(\x. h (1, x) = q x)" + and h01: "(\t\{0..1}. h (t, 1) = h (t, 0)) " + using assms + by (auto simp: homotopic_loops_def sphere_def homotopic_with_def pathstart_def pathfinish_def) + define j where "j \ \z. if 0 \ Im (snd z) + then h (fst z, Arg2pi (snd z) / (2 * pi)) + else h (fst z, 1 - Arg2pi (cnj (snd z)) / (2 * pi))" + have Arg2pi_eq: "1 - Arg2pi (cnj y) / (2 * pi) = Arg2pi y / (2 * pi) \ Arg2pi y = 0 \ Arg2pi (cnj y) = 0" if "cmod y = 1" for y + using that Arg2pi_eq_0_pi Arg2pi_eq_pi by (force simp: Arg2pi_cnj field_split_simps) + show ?thesis + proof (simp add: homotopic_with; intro conjI ballI exI) + show "continuous_on ({0..1} \ sphere 0 1) (\w. h (fst w, Arg2pi (snd w) / (2 * pi)))" + proof (rule continuous_on_eq) + show j: "j x = h (fst x, Arg2pi (snd x) / (2 * pi))" if "x \ {0..1} \ sphere 0 1" for x + using Arg2pi_eq that h01 by (force simp: j_def) + have eq: "S = S \ (UNIV \ {z. 0 \ Im z}) \ S \ (UNIV \ {z. Im z \ 0})" for S :: "(real*complex)set" + by auto + have c1: "continuous_on ({0..1} \ sphere 0 1 \ UNIV \ {z. 0 \ Im z}) (\x. h (fst x, Arg2pi (snd x) / (2 * pi)))" + apply (intro continuous_intros continuous_on_compose2 [OF conth] continuous_on_compose2 [OF continuous_on_upperhalf_Arg2pi]) + apply (auto simp: Arg2pi) + apply (meson Arg2pi_lt_2pi linear not_le) + done + have c2: "continuous_on ({0..1} \ sphere 0 1 \ UNIV \ {z. Im z \ 0}) (\x. h (fst x, 1 - Arg2pi (cnj (snd x)) / (2 * pi)))" + apply (intro continuous_intros continuous_on_compose2 [OF conth] continuous_on_compose2 [OF continuous_on_upperhalf_Arg2pi]) + apply (auto simp: Arg2pi) + apply (meson Arg2pi_lt_2pi linear not_le) + done + show "continuous_on ({0..1} \ sphere 0 1) j" + apply (simp add: j_def) + apply (subst eq) + apply (rule continuous_on_cases_local) + apply (simp_all add: eq [symmetric] closedin_closed_Int closed_Times closed_halfspace_Im_le closed_halfspace_Im_ge c1 c2) + using Arg2pi_eq h01 + by force + qed + have "(\w. h (fst w, Arg2pi (snd w) / (2 * pi))) ` ({0..1} \ sphere 0 1) \ h ` ({0..1} \ {0..1})" + by (auto simp: Arg2pi_ge_0 Arg2pi_lt_2pi less_imp_le) + also have "... \ S" + using him by blast + finally show "(\w. h (fst w, Arg2pi (snd w) / (2 * pi))) ` ({0..1} \ sphere 0 1) \ S" . + qed (auto simp: h0 h1) +qed + +lemma simply_connected_homotopic_loops: + "simply_connected S \ + (\p q. homotopic_loops S p p \ homotopic_loops S q q \ homotopic_loops S p q)" +unfolding simply_connected_def using homotopic_loops_refl by metis + + +lemma simply_connected_eq_homotopic_circlemaps1: + fixes f :: "complex \ 'a::topological_space" and g :: "complex \ 'a" + assumes S: "simply_connected S" + and contf: "continuous_on (sphere 0 1) f" and fim: "f ` (sphere 0 1) \ S" + and contg: "continuous_on (sphere 0 1) g" and gim: "g ` (sphere 0 1) \ S" + shows "homotopic_with_canon (\h. True) (sphere 0 1) S f g" +proof - + have "homotopic_loops S (f \ exp \ (\t. of_real(2 * pi * t) * \)) (g \ exp \ (\t. of_real(2 * pi * t) * \))" + apply (rule S [unfolded simply_connected_homotopic_loops, rule_format]) + apply (simp add: homotopic_circlemaps_imp_homotopic_loops homotopic_with_refl contf fim contg gim) + done + then show ?thesis + apply (rule homotopic_with_eq [OF homotopic_loops_imp_homotopic_circlemaps]) + apply (auto simp: o_def complex_norm_eq_1_exp mult.commute) + done +qed + +lemma simply_connected_eq_homotopic_circlemaps2a: + fixes h :: "complex \ 'a::topological_space" + assumes conth: "continuous_on (sphere 0 1) h" and him: "h ` (sphere 0 1) \ S" + and hom: "\f g::complex \ 'a. + \continuous_on (sphere 0 1) f; f ` (sphere 0 1) \ S; + continuous_on (sphere 0 1) g; g ` (sphere 0 1) \ S\ + \ homotopic_with_canon (\h. True) (sphere 0 1) S f g" + shows "\a. homotopic_with_canon (\h. True) (sphere 0 1) S h (\x. a)" + apply (rule_tac x="h 1" in exI) + apply (rule hom) + using assms + by (auto simp: continuous_on_const) + +lemma simply_connected_eq_homotopic_circlemaps2b: + fixes S :: "'a::real_normed_vector set" + assumes "\f g::complex \ 'a. + \continuous_on (sphere 0 1) f; f ` (sphere 0 1) \ S; + continuous_on (sphere 0 1) g; g ` (sphere 0 1) \ S\ + \ homotopic_with_canon (\h. True) (sphere 0 1) S f g" + shows "path_connected S" +proof (clarsimp simp add: path_connected_eq_homotopic_points) + fix a b + assume "a \ S" "b \ S" + then show "homotopic_loops S (linepath a a) (linepath b b)" + using homotopic_circlemaps_imp_homotopic_loops [OF assms [of "\x. a" "\x. b"]] + by (auto simp: o_def continuous_on_const linepath_def) +qed + +lemma simply_connected_eq_homotopic_circlemaps3: + fixes h :: "complex \ 'a::real_normed_vector" + assumes "path_connected S" + and hom: "\f::complex \ 'a. + \continuous_on (sphere 0 1) f; f `(sphere 0 1) \ S\ + \ \a. homotopic_with_canon (\h. True) (sphere 0 1) S f (\x. a)" + shows "simply_connected S" +proof (clarsimp simp add: simply_connected_eq_contractible_loop_some assms) + fix p + assume p: "path p" "path_image p \ S" "pathfinish p = pathstart p" + then have "homotopic_loops S p p" + by (simp add: homotopic_loops_refl) + then obtain a where homp: "homotopic_with_canon (\h. True) (sphere 0 1) S (p \ (\z. Arg2pi z / (2 * pi))) (\x. a)" + by (metis homotopic_with_imp_subset2 homotopic_loops_imp_homotopic_circlemaps homotopic_with_imp_continuous hom) + show "\a. a \ S \ homotopic_loops S p (linepath a a)" + proof (intro exI conjI) + show "a \ S" + using homotopic_with_imp_subset2 [OF homp] + by (metis dist_0_norm image_subset_iff mem_sphere norm_one) + have teq: "\t. \0 \ t; t \ 1\ + \ t = Arg2pi (exp (2 * of_real pi * of_real t * \)) / (2 * pi) \ t=1 \ Arg2pi (exp (2 * of_real pi * of_real t * \)) = 0" + apply (rule disjCI) + using Arg2pi_of_real [of 1] apply (auto simp: Arg2pi_exp) + done + have "homotopic_loops S p (p \ (\z. Arg2pi z / (2 * pi)) \ exp \ (\t. 2 * complex_of_real pi * complex_of_real t * \))" + apply (rule homotopic_loops_eq [OF p]) + using p teq apply (fastforce simp: pathfinish_def pathstart_def) + done + then + show "homotopic_loops S p (linepath a a)" + by (simp add: linepath_refl homotopic_loops_trans [OF _ homotopic_circlemaps_imp_homotopic_loops [OF homp, simplified K_record_comp]]) + qed +qed + + +proposition simply_connected_eq_homotopic_circlemaps: + fixes S :: "'a::real_normed_vector set" + shows "simply_connected S \ + (\f g::complex \ 'a. + continuous_on (sphere 0 1) f \ f ` (sphere 0 1) \ S \ + continuous_on (sphere 0 1) g \ g ` (sphere 0 1) \ S + \ homotopic_with_canon (\h. True) (sphere 0 1) S f g)" + apply (rule iffI) + apply (blast elim: dest: simply_connected_eq_homotopic_circlemaps1) + by (simp add: simply_connected_eq_homotopic_circlemaps2a simply_connected_eq_homotopic_circlemaps2b simply_connected_eq_homotopic_circlemaps3) + +proposition simply_connected_eq_contractible_circlemap: + fixes S :: "'a::real_normed_vector set" + shows "simply_connected S \ + path_connected S \ + (\f::complex \ 'a. + continuous_on (sphere 0 1) f \ f `(sphere 0 1) \ S + \ (\a. homotopic_with_canon (\h. True) (sphere 0 1) S f (\x. a)))" + apply (rule iffI) + apply (simp add: simply_connected_eq_homotopic_circlemaps1 simply_connected_eq_homotopic_circlemaps2a simply_connected_eq_homotopic_circlemaps2b) + using simply_connected_eq_homotopic_circlemaps3 by blast + +corollary homotopy_eqv_simple_connectedness: + fixes S :: "'a::real_normed_vector set" and T :: "'b::real_normed_vector set" + shows "S homotopy_eqv T \ simply_connected S \ simply_connected T" + by (simp add: simply_connected_eq_homotopic_circlemaps homotopy_eqv_homotopic_triviality) + + +subsection\Homeomorphism of simple closed curves to circles\ + +proposition homeomorphic_simple_path_image_circle: + fixes a :: complex and \ :: "real \ 'a::t2_space" + assumes "simple_path \" and loop: "pathfinish \ = pathstart \" and "0 < r" + shows "(path_image \) homeomorphic sphere a r" +proof - + have "homotopic_loops (path_image \) \ \" + by (simp add: assms homotopic_loops_refl simple_path_imp_path) + then have hom: "homotopic_with_canon (\h. True) (sphere 0 1) (path_image \) + (\ \ (\z. Arg2pi z / (2*pi))) (\ \ (\z. Arg2pi z / (2*pi)))" + by (rule homotopic_loops_imp_homotopic_circlemaps) + have "\g. homeomorphism (sphere 0 1) (path_image \) (\ \ (\z. Arg2pi z / (2*pi))) g" + proof (rule homeomorphism_compact) + show "continuous_on (sphere 0 1) (\ \ (\z. Arg2pi z / (2*pi)))" + using hom homotopic_with_imp_continuous by blast + show "inj_on (\ \ (\z. Arg2pi z / (2*pi))) (sphere 0 1)" + proof + fix x y + assume xy: "x \ sphere 0 1" "y \ sphere 0 1" + and eq: "(\ \ (\z. Arg2pi z / (2*pi))) x = (\ \ (\z. Arg2pi z / (2*pi))) y" + then have "(Arg2pi x / (2*pi)) = (Arg2pi y / (2*pi))" + proof - + have "(Arg2pi x / (2*pi)) \ {0..1}" "(Arg2pi y / (2*pi)) \ {0..1}" + using Arg2pi_ge_0 Arg2pi_lt_2pi dual_order.strict_iff_order by fastforce+ + with eq show ?thesis + using \simple_path \\ Arg2pi_lt_2pi unfolding simple_path_def o_def + by (metis eq_divide_eq_1 not_less_iff_gr_or_eq) + qed + with xy show "x = y" + by (metis is_Arg_def Arg2pi Arg2pi_0 dist_0_norm divide_cancel_right dual_order.strict_iff_order mem_sphere) + qed + have "\z. cmod z = 1 \ \x\{0..1}. \ (Arg2pi z / (2*pi)) = \ x" + by (metis Arg2pi_ge_0 Arg2pi_lt_2pi atLeastAtMost_iff divide_less_eq_1 less_eq_real_def zero_less_mult_iff pi_gt_zero zero_le_divide_iff zero_less_numeral) + moreover have "\z\sphere 0 1. \ x = \ (Arg2pi z / (2*pi))" if "0 \ x" "x \ 1" for x + proof (cases "x=1") + case True + with Arg2pi_of_real [of 1] loop show ?thesis + by (rule_tac x=1 in bexI) (auto simp: pathfinish_def pathstart_def \0 \ x\) + next + case False + then have *: "(Arg2pi (exp (\*(2* of_real pi* of_real x))) / (2*pi)) = x" + using that by (auto simp: Arg2pi_exp field_split_simps) + show ?thesis + by (rule_tac x="exp(\ * of_real(2*pi*x))" in bexI) (auto simp: *) + qed + ultimately show "(\ \ (\z. Arg2pi z / (2*pi))) ` sphere 0 1 = path_image \" + by (auto simp: path_image_def image_iff) + qed auto + then have "path_image \ homeomorphic sphere (0::complex) 1" + using homeomorphic_def homeomorphic_sym by blast + also have "... homeomorphic sphere a r" + by (simp add: assms homeomorphic_spheres) + finally show ?thesis . +qed + +lemma homeomorphic_simple_path_images: + fixes \1 :: "real \ 'a::t2_space" and \2 :: "real \ 'b::t2_space" + assumes "simple_path \1" and loop: "pathfinish \1 = pathstart \1" + assumes "simple_path \2" and loop: "pathfinish \2 = pathstart \2" + shows "(path_image \1) homeomorphic (path_image \2)" + by (meson assms homeomorphic_simple_path_image_circle homeomorphic_sym homeomorphic_trans loop pi_gt_zero) + subsection\Dimension-based conditions for various homeomorphisms\ lemma homeomorphic_subspaces_eq: @@ -3637,7 +3887,7 @@ by (auto simp: homotopic_with_imp_continuous dest: homotopic_with_imp_subset1 homotopic_with_imp_subset2) next assume ?rhs then show ?lhs - by (force simp: elim: homotopic_with_eq dest: homotopic_with_sphere_times [where h=g])+ + by (force simp: elim: homotopic_with_eq dest: homotopic_with_sphere_times [where h=g]) qed then show ?thesis by (simp add: *)