diff -r 97a11357485c -r 830597d13d6d src/HOL/Complex_Analysis/Complex_Singularities.thy --- a/src/HOL/Complex_Analysis/Complex_Singularities.thy Wed Jan 04 17:46:27 2023 +0000 +++ b/src/HOL/Complex_Analysis/Complex_Singularities.thy Wed Jan 04 19:06:16 2023 +0000 @@ -1156,40 +1156,40 @@ then have "?gg holomorphic_on ball z r-{z}" using \g holomorphic_on s\ r by (auto intro!: holomorphic_intros) then have "f holomorphic_on ball z r - {z}" - apply (elim holomorphic_transform) - using fg_eq \ball z r-{z} \ s\ by auto + by (smt (verit, best) DiffD2 \ball z r-{z} \ s\ fg_eq holomorphic_cong singleton_iff subset_iff) then show "isolated_singularity_at f z" unfolding isolated_singularity_at_def using analytic_on_open open_delete r(1) by blast 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 + by (meson \continuous_on s g\ assms 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" unfolding filterlim_at by (auto intro:tendsto_eq_intros) 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) + assms 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] - by (metis dist_commute mem_ball openE subsetCE) + moreover + have "\\<^sub>F w in at z. g w * (w - z) powr n = f w" + unfolding eventually_at_topological using assms fg_eq by force + ultimately show "not_essential f z" + using not_essential_transform by blast show "\\<^sub>F w in at z. f w \ 0" unfolding frequently_at - proof (rule,rule) + proof (intro strip) fix d::real assume "0 < d" - define z' where "z'=z+min d r / 2" + define z' where "z' \ z+min d r / 2" have "z' \ z" " dist z' z < d " - unfolding z'_def using \d>0\ \r>0\ - by (auto simp add:dist_norm) + unfolding z'_def using \d>0\ \r>0\ by (auto simp add:dist_norm) 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) + 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" - using P_def \P n g r\ \z' \ cball z r\ calculation(1) by auto + using P_def \P n g r\ \z' \ cball z r\ \z' \ z\ by auto qed ultimately show "\x\UNIV. x \ z \ dist x z < d \ f x \ 0" by auto qed @@ -1203,7 +1203,7 @@ assumes "open s" "z \ s" "g holomorphic_on s" "g z \ 0" assumes "\w. w \ s \ f w = g w * (w - z)" shows "zorder f z = 1" - using assms(1-4) by (rule zorder_eqI) (use assms(5) in auto) + using assms zorder_eqI by force lemma higher_deriv_power: shows "(deriv ^^ j) (\w. (w - z) ^ n) w = @@ -1245,9 +1245,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 - apply (rule_tac x="ball z r" in exI) - by auto + using open_ball \0 < r\ centre_in_ball eventually_nhds by blast then have "(deriv ^^ nat n) f z = (deriv ^^ nat n) (\_. 0) z" by (intro higher_deriv_cong_ev) auto also have "(deriv ^^ nat n) (\_. 0) z = 0" @@ -1266,19 +1264,16 @@ from that zorder_exist_zero[of f "ball z r" z,simplified,OF this nz',folded zn_def g_def] show ?thesis by blast qed - from this(1,2,5) have "zn\0" "g z\0" - subgoal by (auto split:if_splits) - subgoal using \0 < e\ ball_subset_cball centre_in_ball e_fac by blast - done + then obtain "zn \ 0" "g z\0" + by (metis centre_in_cball less_le_not_le order_refl) - define A where "A = (\i. of_nat (i choose (nat zn)) * fact (nat zn) * (deriv ^^ (i - nat zn)) g z)" + define A where "A \ (\i. of_nat (i choose (nat zn)) * fact (nat zn) * (deriv ^^ (i - nat zn)) g z)" have deriv_A:"(deriv ^^ i) f z = (if zn \ int i then A i else 0)" for i proof - 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 - by (use e_fac in auto) + using e_fac eventually_mono by fastforce 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) * @@ -1360,11 +1355,9 @@ qed lemma zorder_nonzero_div_power: - assumes "open s" "z \ s" "f holomorphic_on s" "f z \ 0" "n > 0" + assumes sz: "open s" "z \ s" "f holomorphic_on s" "f z \ 0" and "n > 0" shows "zorder (\w. f w / (w - z) ^ n) z = - n" - apply (rule zorder_eqI[OF \open s\ \z\s\ \f holomorphic_on s\ \f z\0\]) - apply (subst powr_of_int) - using \n>0\ by (auto simp add:field_simps) + using zorder_eqI [OF sz] by (simp add: powr_minus_divide) lemma zor_poly_eq: assumes "isolated_singularity_at f z" "not_essential f z" "\\<^sub>F w in at z. f w \ 0"