107 have "open (S - path_image \<gamma>)" using \<open>open S\<close> closed_valid_path_image \<gamma> by blast |
107 have "open (S - path_image \<gamma>)" using \<open>open S\<close> closed_valid_path_image \<gamma> by blast |
108 then obtain d where "d>0" and d: "ball w d \<subseteq> S - path_image \<gamma>" using w |
108 then obtain d where "d>0" and d: "ball w d \<subseteq> S - path_image \<gamma>" using w |
109 using open_contains_ball by blast |
109 using open_contains_ball by blast |
110 have [simp]: "\<And>n. cmod (1 + of_nat n) = 1 + of_nat n" |
110 have [simp]: "\<And>n. cmod (1 + of_nat n) = 1 + of_nat n" |
111 by (metis norm_of_nat of_nat_Suc) |
111 by (metis norm_of_nat of_nat_Suc) |
112 have cint: "\<And>x. \<lbrakk>x \<noteq> w; cmod (x - w) < d\<rbrakk> |
112 have cint: "(\<lambda>z. (f' z / (z - x) ^ k - f' z / (z - w) ^ k) / (x * k - w * k)) contour_integrable_on \<gamma>" |
113 \<Longrightarrow> (\<lambda>z. (f' z / (z - x) ^ k - f' z / (z - w) ^ k) / (x * k - w * k)) contour_integrable_on \<gamma>" |
113 if "x \<noteq> w" "cmod (x - w) < d" for x |
114 using int w d |
114 proof - |
115 apply (intro contour_integrable_div contour_integrable_diff has_contour_integral_integrable) |
115 have "x \<in> S - path_image \<gamma>" |
116 by (force simp: dist_norm norm_minus_commute) |
116 by (metis d dist_commute dist_norm mem_ball subsetD that(2)) |
|
117 then show ?thesis |
|
118 using contour_integrable_diff contour_integrable_div contour_integrable_on_def int w |
|
119 by meson |
|
120 qed |
117 have 1: "\<forall>\<^sub>F n in at w. (\<lambda>x. f' x * (inverse (x - n) ^ k - inverse (x - w) ^ k) / (n - w) / of_nat k) |
121 have 1: "\<forall>\<^sub>F n in at w. (\<lambda>x. f' x * (inverse (x - n) ^ k - inverse (x - w) ^ k) / (n - w) / of_nat k) |
118 contour_integrable_on \<gamma>" |
122 contour_integrable_on \<gamma>" |
119 unfolding eventually_at |
123 unfolding eventually_at |
120 apply (rule_tac x=d in exI) |
124 apply (rule_tac x=d in exI) |
121 apply (simp add: \<open>d > 0\<close> dist_norm field_simps cint) |
125 apply (simp add: \<open>d > 0\<close> dist_norm field_simps cint) |
1571 shows "(\<lambda>z. if z = a then deriv f a else (f z - f a)/(z - a)) holomorphic_on S" |
1575 shows "(\<lambda>z. if z = a then deriv f a else (f z - f a)/(z - a)) holomorphic_on S" |
1572 proof (cases "a \<in> S") |
1576 proof (cases "a \<in> S") |
1573 case True with assms interior_eq pole_lemma |
1577 case True with assms interior_eq pole_lemma |
1574 show ?thesis by fastforce |
1578 show ?thesis by fastforce |
1575 next |
1579 next |
1576 case False with assms show ?thesis |
1580 case False |
1577 apply (simp add: holomorphic_on_def field_differentiable_def [symmetric], clarify) |
1581 then have "(\<lambda>z. (f z - f a) / (z - a)) field_differentiable at x within S" |
1578 apply (rule field_differentiable_transform_within [where f = "\<lambda>z. (f z - f a)/(z - a)" and d = 1]) |
1582 if "x \<in> S" for x |
|
1583 using assms that |
|
1584 apply (simp add: holomorphic_on_def) |
1579 apply (rule derivative_intros | force)+ |
1585 apply (rule derivative_intros | force)+ |
1580 done |
1586 done |
|
1587 with False show ?thesis |
|
1588 using holomorphic_on_def holomorphic_transform by presburger |
1581 qed |
1589 qed |
1582 |
1590 |
1583 lemma pole_theorem_open: |
1591 lemma pole_theorem_open: |
1584 assumes holg: "g holomorphic_on S" and S: "open S" |
1592 assumes holg: "g holomorphic_on S" and S: "open S" |
1585 and eq: "\<And>z. z \<in> S - {a} \<Longrightarrow> g z = (z - a) * f z" |
1593 and eq: "\<And>z. z \<in> S - {a} \<Longrightarrow> g z = (z - a) * f z" |
1790 then have "((\<lambda>x. f z * (1 / (x - z))) has_contour_integral 0) \<gamma>" |
1798 then have "((\<lambda>x. f z * (1 / (x - z))) has_contour_integral 0) \<gamma>" |
1791 using has_contour_integral_lmul by fastforce |
1799 using has_contour_integral_lmul by fastforce |
1792 then have "((\<lambda>x. f z / (x - z)) has_contour_integral 0) \<gamma>" |
1800 then have "((\<lambda>x. f z / (x - z)) has_contour_integral 0) \<gamma>" |
1793 by (simp add: field_split_simps) |
1801 by (simp add: field_split_simps) |
1794 moreover have "((\<lambda>x. (f x - f z) / (x - z)) has_contour_integral contour_integral \<gamma> (d z)) \<gamma>" |
1802 moreover have "((\<lambda>x. (f x - f z) / (x - z)) has_contour_integral contour_integral \<gamma> (d z)) \<gamma>" |
1795 using z |
1803 by (metis (no_types, lifting) z cint_fxy contour_integral_eq d_def has_contour_integral_integral mem_Collect_eq v_def) |
1796 apply (simp add: v_def) |
|
1797 apply (metis (no_types, lifting) contour_integrable_eq d_def has_contour_integral_eq has_contour_integral_integral cint_fxy) |
|
1798 done |
|
1799 ultimately have *: "((\<lambda>x. f z / (x - z) + (f x - f z) / (x - z)) has_contour_integral (0 + contour_integral \<gamma> (d z))) \<gamma>" |
1804 ultimately have *: "((\<lambda>x. f z / (x - z) + (f x - f z) / (x - z)) has_contour_integral (0 + contour_integral \<gamma> (d z))) \<gamma>" |
1800 by (rule has_contour_integral_add) |
1805 by (rule has_contour_integral_add) |
1801 have "((\<lambda>w. f w / (w - z)) has_contour_integral contour_integral \<gamma> (d z)) \<gamma>" |
1806 have "((\<lambda>w. f w / (w - z)) has_contour_integral contour_integral \<gamma> (d z)) \<gamma>" |
1802 if "z \<in> U" |
1807 if "z \<in> U" |
1803 using * by (auto simp: divide_simps has_contour_integral_eq) |
1808 using * by (auto simp: divide_simps has_contour_integral_eq) |
1819 proof |
1824 proof |
1820 show "0 < d0 / 2" using \<open>0 < d0\<close> by auto |
1825 show "0 < d0 / 2" using \<open>0 < d0\<close> by auto |
1821 qed (use \<open>0 < d0\<close> d0 in \<open>force simp: dist_norm\<close>) |
1826 qed (use \<open>0 < d0\<close> d0 in \<open>force simp: dist_norm\<close>) |
1822 define T where "T \<equiv> {y + k |y k. y \<in> path_image \<gamma> \<and> k \<in> cball 0 (dd / 2)}" |
1827 define T where "T \<equiv> {y + k |y k. y \<in> path_image \<gamma> \<and> k \<in> cball 0 (dd / 2)}" |
1823 have "\<And>x x'. \<lbrakk>x \<in> path_image \<gamma>; dist x x' * 2 < dd\<rbrakk> \<Longrightarrow> \<exists>y k. x' = y + k \<and> y \<in> path_image \<gamma> \<and> dist 0 k * 2 \<le> dd" |
1828 have "\<And>x x'. \<lbrakk>x \<in> path_image \<gamma>; dist x x' * 2 < dd\<rbrakk> \<Longrightarrow> \<exists>y k. x' = y + k \<and> y \<in> path_image \<gamma> \<and> dist 0 k * 2 \<le> dd" |
1824 apply (rule_tac x=x in exI) |
1829 by (metis add.commute diff_add_cancel dist_0_norm dist_commute dist_norm less_eq_real_def) |
1825 apply (rule_tac x="x'-x" in exI) |
|
1826 apply (force simp: dist_norm) |
|
1827 done |
|
1828 then have subt: "path_image \<gamma> \<subseteq> interior T" |
1830 then have subt: "path_image \<gamma> \<subseteq> interior T" |
1829 using \<open>0 < dd\<close> |
1831 using \<open>0 < dd\<close> |
1830 apply (clarsimp simp add: mem_interior T_def) |
1832 apply (clarsimp simp add: mem_interior T_def) |
1831 apply (rule_tac x="dd/2" in exI, auto) |
1833 apply (rule_tac x="dd/2" in exI, auto) |
1832 done |
1834 done |