# HG changeset patch # User desharna # Date 1743146647 -3600 # Node ID 7fee9141da5e5cc6e9bbe874a7c1eec658fc8f95 # Parent 5af097d05e99a6726217e6c6612b039e3ebc11a4# Parent 35a219e372b02f8c9e37a1f88db6b164a27bba3f merged diff -r 5af097d05e99 -r 7fee9141da5e src/HOL/Analysis/Infinite_Products.thy --- a/src/HOL/Analysis/Infinite_Products.thy Thu Mar 27 16:35:41 2025 +0100 +++ b/src/HOL/Analysis/Infinite_Products.thy Fri Mar 28 08:24:07 2025 +0100 @@ -211,6 +211,74 @@ by (metis \a = 0\ \f i = 0\ has_prod_0_iff norm_zero) qed +lemma raw_has_prod_imp_nonzero: + assumes "raw_has_prod f N P" "n \ N" + shows "f n \ 0" +proof + assume "f n = 0" + from assms(1) have lim: "(\m. (\k\m. f (k + N))) \ P" and "P \ 0" + unfolding raw_has_prod_def by blast+ + have "eventually (\m. m \ n - N) at_top" + by (rule eventually_ge_at_top) + hence "eventually (\m. (\k\m. f (k + N)) = 0) at_top" + proof eventually_elim + case (elim m) + have "f ((n - N) + N) = 0" "n - N \ {..m}" "finite {..m}" + using \n \ N\ \f n = 0\ elim by auto + thus "(\k\m. f (k + N)) = 0" + using prod_zero[of "{..m}" "\k. f (k + N)"] by blast + qed + with lim have "P = 0" + by (simp add: LIMSEQ_const_iff tendsto_cong) + thus False + using \P \ 0\ by contradiction +qed + +lemma has_prod_imp_tendsto: + fixes f :: "nat \ 'a :: {semidom, t2_space}" + assumes "f has_prod P" + shows "(\n. \k\n. f k) \ P" +proof (cases "P = 0") + case False + with assms show ?thesis + by (auto simp: has_prod_def raw_has_prod_def) +next + case True + with assms obtain N P' where "f N = 0" "raw_has_prod f (Suc N) P'" + by (auto simp: has_prod_def) + thus ?thesis + using LIMSEQ_prod_0 True \f N = 0\ by blast +qed + +lemma has_prod_imp_tendsto': + fixes f :: "nat \ 'a :: {semidom, t2_space}" + assumes "f has_prod P" + shows "(\n. \k P" + using has_prod_imp_tendsto[OF assms] LIMSEQ_lessThan_iff_atMost by blast + +lemma has_prod_nonneg: + assumes "f has_prod P" "\n. f n \ (0::real)" + shows "P \ 0" +proof (rule tendsto_le) + show "((\n. \i\n. f i)) \ P" + using assms(1) by (rule has_prod_imp_tendsto) + show "(\n. 0::real) \ 0" + by auto +qed (use assms in \auto intro!: always_eventually prod_nonneg\) + +lemma has_prod_pos: + assumes "f has_prod P" "\n. f n > (0::real)" + shows "P > 0" +proof - + have "P \ 0" + by (rule has_prod_nonneg[OF assms(1)]) (auto intro!: less_imp_le assms(2)) + moreover have "f n \ 0" for n + using assms(2)[of n] by auto + hence "P \ 0" + using has_prod_0_iff[of f] assms by auto + ultimately show ?thesis + by linarith +qed subsection\Absolutely convergent products\ @@ -986,6 +1054,11 @@ shows "prodinf f = (\n\N. f n)" using has_prod_finite[OF assms, THEN has_prod_unique] by simp +lemma convergent_prod_tendsto_imp_has_prod: + assumes "convergent_prod f" "(\n. (\i\n. f i)) \ P" + shows "f has_prod P" + using assms by (metis convergent_prod_imp_has_prod has_prod_imp_tendsto limI) + end subsection\<^marker>\tag unimportant\ \Infinite products on ordered topological monoids\ @@ -1520,6 +1593,61 @@ end +lemma prod_ge_prodinf: + fixes f :: "nat \ 'a::{linordered_idom,linorder_topology}" + assumes "f has_prod a" "\i. 0 \ f i" "\i. i \ n \ f i \ 1" + shows "prod f {.. prodinf f" +proof (rule has_prod_le; (intro conjI)?) + show "f has_prod prodinf f" + using assms(1) has_prod_unique by blast + show "(\r. if r \ {.. 0" + by (rule assms) + show "f i \ (if i \ {..n. 0 < f n" and le: "\n. f n \ g n" + shows "F < G" +proof - + define F' G' where "F' = (\nn 0" "g n \ 0" for n + using pos[of n] le[of n] by auto + have [simp]: "F' \ 0" "G' \ 0" + by (auto simp: F'_def G'_def) + have f': "(\n. f (n + Suc m)) has_prod (F / F')" + unfolding F'_def using f + by (intro has_prod_split_initial_segment) auto + have g': "(\n. g (n + Suc m)) has_prod (G / G')" + unfolding G'_def using g + by (intro has_prod_split_initial_segment) auto + have "F' * (F / F') < G' * (F / F')" + proof (rule mult_strict_right_mono) + show "F' < G'" + unfolding F'_def G'_def + by (rule prod_mono_strict[of m]) + (auto intro: le less_imp_le[OF pos] less_le_trans[OF pos le] less) + show "F / F' > 0" + using f' by (rule has_prod_pos) (use pos in auto) + qed + also have "\ \ G' * (G / G')" + proof (rule mult_left_mono) + show "F / F' \ G / G'" + using f' g' by (rule has_prod_le) (auto intro: less_imp_le[OF pos] le) + show "G' \ 0" + unfolding G'_def by (intro prod_nonneg order.trans[OF less_imp_le[OF pos] le]) + qed + finally show ?thesis + by simp +qed + subsection\Exponentials and logarithms\ @@ -1905,4 +2033,364 @@ by (fastforce simp: prod_defs simp flip: of_real_prod) qed +subsection \Convergence criteria: especially uniform convergence of infinite products\ + +text \ + Cauchy's criterion for the convergence of infinite products, adapted to proving + uniform convergence: let $f_k(x)$ be a sequence of functions such that + + \<^enum> $f_k(x)$ has uniformly bounded partial products, i.e.\ there exists a constant \C\ + such that $\prod_{k=0}^m f_k(x) \leq C$ for all $m$ and $x\in A$. + + \<^enum> For any $\varepsilon > 0$ there exists a number $M \in \mathbb{N}$ such that, for any + $m, n \geq M$ and all $x\in A$ we have $|(\prod_{k=m}^n f_k(x)) - 1| < \varepsilon$ + + Then $\prod_{k=0}^n f_k(x)$ converges to $\prod_{k=0}^\infty f_k(x)$ uniformly for all + $x \in A$. +\ +lemma uniformly_convergent_prod_Cauchy: + fixes f :: "nat \ 'a :: topological_space \ 'b :: {real_normed_div_algebra, comm_ring_1, banach}" + assumes C: "\x m. x \ A \ norm (\k C" + assumes "\e. e > 0 \ \M. \x\A. \m\M. \n\m. dist (\k=m..n. f k x) 1 < e" + shows "uniformly_convergent_on A (\N x. \n :: real assume \: "\ > 0" + define C' where "C' = max C 1" + have C': "C' > 0" + by (auto simp: C'_def) + define \ where "\ = Min {2 / 3 * \ / C', 1 / 2}" + from \ have "\ > 0" + using \C' > 0\ by (auto simp: \_def) + obtain M where M: "\x m n. x \ A \ m \ M \ n \ m \ dist (\k=m..n. f k x) 1 < \" + using \\ > 0\ assms by fast + + show "\M. \x\A. \m\M. \n>m. dist (\kk" + proof (rule exI, intro ballI allI impI) + fix x m n + assume x: "x \ A" and mn: "M + 1 \ m" "m < n" + show "dist (\kk" + proof (cases "\kkk by simp + next + case False + have *: "{.. {m..n-1}" + using mn by auto + have "dist (\kkkk=m..n-1. f k x) - 1))" + unfolding * by (subst prod.union_disjoint) + (use mn in \auto simp: dist_norm algebra_simps norm_minus_commute\) + also have "\ = (\kk=m..n-1. f k x) 1" + by (simp add: norm_mult dist_norm prod_norm) + also have "\ < (\k / C')" + proof (rule mult_strict_left_mono) + show "dist (\k = m..n - 1. f k x) 1 < 2 / 3 * \ / C'" + using M[of x m "n-1"] x mn unfolding \_def by fastforce + qed (use False in \auto intro!: prod_pos\) + also have "(\kkk=M.. {M..k=M.. 3 / 2" + proof - + have "dist (\k=M..m-1. f k x) 1 < \" + using M[of x M "m-1"] x mn \\ > 0\ by auto + also have "\ \ 1 / 2" + by (simp add: \_def) + also have "{M..m-1} = {M..k=M.. norm (1 :: 'b) + 1 / 2" + by norm + thus ?thesis + by simp + qed + hence "(\kk = M.. / C') \ + (\k / C')" + using \ C' by (intro mult_left_mono mult_right_mono prod_nonneg) auto + also have "\ \ C' * (3 / 2) * (2 / 3 * \ / C')" + proof (intro mult_right_mono) + have "(\k C" + using C[of x M] x by (simp add: prod_norm) + also have "\ \ C'" + by (simp add: C'_def) + finally show "(\k C'" . + qed (use \ C' in auto) + finally show "dist (\kk" + using \C' > 0\ by (simp add: field_simps) + qed + qed +qed + +text \ + By instantiating the set $A$ in this result with a singleton set, we obtain the ``normal'' + Cauchy criterion for infinite products: +\ +lemma convergent_prod_Cauchy_sufficient: + fixes f :: "nat \ 'b :: {real_normed_div_algebra, comm_ring_1, banach}" + assumes "\e. e > 0 \ \M. \m n. M \ m \ m \ n \ dist (\k=m..n. f k) 1 < e" + shows "convergent_prod f" +proof - + obtain M where M: "\m n. m \ M \ n \ m \ dist (prod f {m..n}) 1 < 1 / 2" + using assms(1)[of "1 / 2"] by auto + have nz: "f m \ 0" if "m \ M" for m + using M[of m m] that by auto + + have M': "dist (prod (\k. f (k + M)) {m..k. f (k + M)) {m..k. k + M" "\k. k - M"]) (use True in auto) + finally show ?thesis . + qed auto + + have "uniformly_convergent_on {0::'b} (\N x. \nk=0..k 3 / 2" + by (simp add: atLeast0LessThan) + next + fix e :: real assume e: "e > 0" + obtain M' where M': "\m n. M' \ m \ m \ n \ dist (\k=m..n. f k) 1 < e" + using assms e by blast + show "\M'. \x\{0}. \m\M'. \n\m. dist (\k=m..n. f (k + M)) 1 < e" + proof (rule exI[of _ M'], intro ballI impI allI) + fix m n :: nat assume "M' \ m" "m \ n" + thus "dist (\k=m..n. f (k + M)) 1 < e" + using M' by (metis add.commute add_left_mono prod.shift_bounds_cl_nat_ivl trans_le_add1) + qed + qed + hence "convergent (\N. \nN. \n L" + unfolding convergent_def by blast + + show ?thesis + unfolding convergent_prod_altdef + proof (rule exI[of _ M], rule exI[of _ L], intro conjI) + show "\n\M. f n \ 0" + using nz by auto + next + show "(\n. \i\n. f (i + M)) \ L" + using LIMSEQ_Suc[OF L] by (subst (asm) lessThan_Suc_atMost) + next + have "norm L \ 1 / 2" + proof (rule tendsto_lowerbound) + show "(\n. norm (\i norm L" + by (intro tendsto_intros L) + show "\\<^sub>F n in sequentially. 1 / 2 \ norm (\ik=0.. norm (1 :: 'b) - 1 / 2" + using M'[of 0 m] by norm + thus "norm (\k 1 / 2" + by (simp add: atLeast0LessThan) + qed + qed auto + thus "L \ 0" + by auto + qed +qed + + +text \ + We now prove that the Cauchy criterion for pointwise convergence is both necessary + and sufficient. +\ +lemma convergent_prod_Cauchy_necessary: + fixes f :: "nat \ 'b :: {real_normed_field, banach}" + assumes "convergent_prod f" "e > 0" + shows "\M. \m n. M \ m \ m \ n \ dist (\k=m..n. f k) 1 < e" +proof - + have *: "\M. \m n. M \ m \ m \ n \ dist (\k=m..n. f k) 1 < e" + if f: "convergent_prod f" "0 \ range f" and e: "e > 0" + for f :: "nat \ 'b" and e :: real + proof - + have *: "(\n. norm (\k norm (\k. f k)" + using has_prod_imp_tendsto' f(1) by (intro tendsto_norm) blast + from f(1,2) have [simp]: "(\k. f k) \ 0" + using prodinf_nonzero by fastforce + obtain M' where M': "norm (\k norm (\k. f k) / 2" if "m \ M'" for m + using order_tendstoD(1)[OF *, of "norm (\k. f k) / 2"] + by (auto simp: eventually_at_top_linorder) + define M where "M = Min (insert (norm (\k. f k) / 2) ((\m. norm (\k 0" + unfolding M_def using f(2) by (subst Min_gr_iff) auto + have norm_ge: "norm (\k M" for m + proof (cases "m \ M'") + case True + have "M \ norm (\k. f k) / 2" + unfolding M_def by (intro Min.coboundedI) auto + also from True have "norm (\k norm (\k. f k) / 2" + by (intro M') + finally show ?thesis by linarith + next + case False + thus ?thesis + unfolding M_def + by (intro Min.coboundedI) auto + qed + + have "convergent (\n. \kn. \k 0" + using e \M > 0\ by auto + ultimately obtain N where N: "dist (\kk N" "n \ N" for m n + unfolding Cauchy_def by fast + + show "\M. \m n. M \ m \ m \ n \ dist (prod f {m..n}) 1 < e" + proof (rule exI[of _ N], intro allI impI, goal_cases) + case (1 m n) + have "dist (\kkkkkkkk\{..{m..n}. f k)" + using 1 by (intro prod.cong) auto + also have "\ = (\k\{..k\{m..n}. f k)" + by (subst prod.union_disjoint) auto + also have "\ - (\kkk\{m..n}. f k) - 1)" + by (simp add: algebra_simps) + finally have "norm (prod f {m..n} - 1) < e * M / norm (prod f {.. \ e * M / M" + using e \M > 0\ f(2) by (intro divide_left_mono norm_ge mult_pos_pos) auto + also have "\ = e" + using \M > 0\ by simp + finally show ?case + by (simp add: dist_norm) + qed + qed + + obtain M where M: "f m \ 0" if "m \ M" for m + using convergent_prod_imp_ev_nonzero[OF assms(1)] + by (auto simp: eventually_at_top_linorder) + + have "\M'. \m n. M' \ m \ m \ n \ dist (\k=m..n. f (k + M)) 1 < e" + by (rule *) (use assms M in auto) + then obtain M' where M': "dist (\k=m..n. f (k + M)) 1 < e" if "M' \ m" "m \ n" for m n + by blast + + show "\M. \m n. M \ m \ m \ n \ dist (prod f {m..n}) 1 < e" + proof (rule exI[of _ "M + M'"], safe, goal_cases) + case (1 m n) + have "dist (\k=m-M..n-M. f (k + M)) 1 < e" + by (rule M') (use 1 in auto) + also have "(\k=m-M..n-M. f (k + M)) = (\k=m..n. f k)" + using 1 by (intro prod.reindex_bij_witness[of _ "\k. k - M" "\k. k + M"]) auto + finally show ?case . + qed +qed + +lemma convergent_prod_Cauchy_iff: + fixes f :: "nat \ 'b :: {real_normed_field, banach}" + shows "convergent_prod f \ (\e>0. \M. \m n. M \ m \ m \ n \ dist (\k=m..n. f k) 1 < e)" + using convergent_prod_Cauchy_necessary[of f] convergent_prod_Cauchy_sufficient[of f] + by blast + +lemma uniformly_convergent_on_prod: + fixes f :: "nat \ 'a :: topological_space \ 'b :: {real_normed_div_algebra, comm_ring_1, banach}" + assumes cont: "\n. continuous_on A (f n)" + assumes A: "compact A" + assumes conv_sum: "uniformly_convergent_on A (\N x. \nN x. \nn x. \kx. \k. norm (f k x)) sequentially" + by (rule uniform_limit_suminf) fact + have cont': "\\<^sub>F n in sequentially. continuous_on A (\x. \kx. \k. norm (f k x))" + by (rule uniform_limit_theorem[OF cont' lim]) auto + hence "compact ((\x. \k. norm (f k x)) ` A)" + by (intro compact_continuous_image A) + hence "bounded ((\x. \k. norm (f k x)) ` A)" + by (rule compact_imp_bounded) + then obtain C where C: "norm (\k. norm (f k x)) \ C" if "x \ A" for x + unfolding bounded_iff by blast + show ?thesis + proof (rule uniformly_convergent_prod_Cauchy) + fix x :: 'a and m :: nat + assume x: "x \ A" + have "norm (\kk \ (\k = (\k \ exp (\kk (\k. norm (f k x))" + proof (rule sum_le_suminf) + have "(\n. \k (\k. norm (f k x))" + by (rule tendsto_uniform_limitI[OF lim]) fact + thus "summable (\k. norm (f k x))" + using sums_def sums_iff by blast + qed auto + also have "exp (\k. norm (f k x)) \ exp (norm (\k. norm (f k x)))" + by simp + also have "norm (\k. norm (f k x)) \ C" + by (rule C) fact + finally show "norm (\k exp C" + by - simp_all + next + fix \ :: real assume \: "\ > 0" + have "uniformly_Cauchy_on A (\N x. \n) > 0" + using \ by simp + ultimately obtain M where M: "\m n x. x \ A \ M \ m \ M \ n \ + dist (\kk)" + using \ unfolding uniformly_Cauchy_on_def by metis + + show "\M. \x\A. \m\M. \n\m. dist (\k = m..n. 1 + f k x) 1 < \" + proof (rule exI, intro ballI allI impI) + fix x m n + assume x: "x \ A" and mn: "M \ m" "m \ n" + have "dist (\kk)" + by (rule M) (use x mn in auto) + also have "dist (\kk\k\{.." + using mn by (subst sum_diff) (auto simp: dist_norm) + also have "{..\k=m..n. norm (f k x)\ = (\k=m..n. norm (f k x))" + by (intro abs_of_nonneg sum_nonneg) auto + finally have *: "(\k=m..n. norm (f k x)) < ln (1 + \)" . + + have "dist (\k=m..n. 1 + f k x) 1 = norm ((\k=m..n. 1 + f k x) - 1)" + by (simp add: dist_norm) + also have "norm ((\k=m..n. 1 + f k x) - 1) \ (\n=m..n. 1 + norm (f n x)) - 1" + by (rule norm_prod_minus1_le_prod_minus1) + also have "(\n=m..n. 1 + norm (f n x)) \ exp (\k=m..n. norm (f k x))" + by (rule prod_le_exp_sum) auto + also note * + finally show "dist (\k = m..n. 1 + f k x) 1 < \" + using \ by - simp_all + qed + qed +qed + +lemma uniformly_convergent_on_prod': + fixes f :: "nat \ 'a :: topological_space \ 'b :: {real_normed_div_algebra, comm_ring_1, banach}" + assumes cont: "\n. continuous_on A (f n)" + assumes A: "compact A" + assumes conv_sum: "uniformly_convergent_on A (\N x. \nN x. \nN x. \nauto intro!: continuous_intros\) + thus ?thesis + by simp +qed + end diff -r 5af097d05e99 -r 7fee9141da5e src/HOL/Analysis/Uniform_Limit.thy --- a/src/HOL/Analysis/Uniform_Limit.thy Thu Mar 27 16:35:41 2025 +0100 +++ b/src/HOL/Analysis/Uniform_Limit.thy Fri Mar 28 08:24:07 2025 +0100 @@ -41,6 +41,22 @@ "(\e. e > 0 \ \\<^sub>F n in F. \x\S. dist (f n x) (l x) < e) \ uniform_limit S f l F" by (simp add: uniform_limit_iff) +lemma uniform_limit_on_subset: + "uniform_limit J f g F \ I \ J \ uniform_limit I f g F" + by (auto intro!: uniform_limitI dest!: uniform_limitD intro: eventually_mono) + +lemma uniformly_convergent_on_subset: + assumes "uniformly_convergent_on A f" "B \ A" + shows "uniformly_convergent_on B f" + using assms by (meson uniform_limit_on_subset uniformly_convergent_on_def) + +lemma uniform_limit_singleton [simp]: "uniform_limit {x} f g F \ ((\n. f n x) \ g x) F" + by (simp add: uniform_limit_iff tendsto_iff) + +lemma uniformly_convergent_on_singleton: + "uniformly_convergent_on {x} f \ convergent (\n. f n x)" + by (auto simp: uniformly_convergent_on_def convergent_def) + lemma uniform_limit_sequentially_iff: "uniform_limit S f l sequentially \ (\e>0. \N. \n\N. \x \ S. dist (f n x) (l x) < e)" unfolding uniform_limit_iff eventually_sequentially .. @@ -71,6 +87,19 @@ by eventually_elim (use \ l in blast) qed +lemma uniform_limit_compose': + assumes "uniform_limit A f g F" and "h \ B \ A" + shows "uniform_limit B (\n x. f n (h x)) (\x. g (h x)) F" + unfolding uniform_limit_iff +proof (intro strip) + fix e :: real + assume e: "e > 0" + with assms(1) have "\\<^sub>F n in F. \x\A. dist (f n x) (g x) < e" + by (auto simp: uniform_limit_iff) + thus "\\<^sub>F n in F. \x\B. dist (f n (h x)) (g (h x)) < e" + by eventually_elim (use assms(2) in blast) +qed + lemma metric_uniform_limit_imp_uniform_limit: assumes f: "uniform_limit S f a F" assumes le: "eventually (\x. \y\S. dist (g x y) (b y) \ dist (f x y) (a y)) F" @@ -378,7 +407,7 @@ qed (metis uniformly_convergent_on_sum_E) lemma uniform_limit_suminf: - fixes f:: "nat \ 'a::{metric_space, comm_monoid_add} \ 'a" + fixes f:: "nat \ 'a :: topological_space \ 'b::{metric_space, comm_monoid_add}" assumes "uniformly_convergent_on X (\n x. \kn x. \kx. \k. f k x) sequentially" proof - @@ -913,10 +942,6 @@ shows "uniform_limit (Union I) f g F" by (metis SUP_identity_eq assms uniform_limit_on_UNION) -lemma uniform_limit_on_subset: - "uniform_limit J f g F \ I \ J \ uniform_limit I f g F" - by (auto intro!: uniform_limitI dest!: uniform_limitD intro: eventually_mono) - lemma uniform_limit_bounded: fixes f::"'i \ 'a::topological_space \ 'b::metric_space" assumes l: "uniform_limit S f l F" @@ -982,7 +1007,7 @@ shows "continuous_on (cball \ r) (\x. suminf (\i. a i * (x - \) ^ i))" apply (rule uniform_limit_theorem [OF _ powser_uniform_limit]) apply (rule eventuallyI continuous_intros assms)+ -apply (simp add:) +apply auto done lemma powser_continuous_sums: diff -r 5af097d05e99 -r 7fee9141da5e src/HOL/Complex_Analysis/Great_Picard.thy --- a/src/HOL/Complex_Analysis/Great_Picard.thy Thu Mar 27 16:35:41 2025 +0100 +++ b/src/HOL/Complex_Analysis/Great_Picard.thy Fri Mar 28 08:24:07 2025 +0100 @@ -1178,8 +1178,7 @@ have "(\z. g z - g z1) holomorphic_on S" by (intro holomorphic_intros holg) then obtain r where "0 < r" "ball z2 r \ S" "\z. dist z2 z < r \ z \ z2 \ g z \ g z1" - apply (rule isolated_zeros [of "\z. g z - g z1" S z2 z0]) - using S \z0 \ S\ z0 z12 by auto + using isolated_zeros [of "\z. g z - g z1" S z2 z0] S \z0 \ S\ z0 z12 by auto have "g z2 - g z1 \ 0" proof (rule Hurwitz_no_zeros [of "S - {z1}" "\n z. \ n z - \ n z1" "\z. g z - g z1"]) show "open (S - {z1})" @@ -1200,13 +1199,13 @@ then have K: "\\<^sub>F n in sequentially. \x \ K. dist (\ n x) (g x) < e/2" using \0 < e\ by (force simp: intro!: uniform_limitD) have "uniform_limit {z1} \ g sequentially" - by (simp add: ul_g z12) + by (intro ul_g) (auto simp: z12) then have "\\<^sub>F n in sequentially. \x \ {z1}. dist (\ n x) (g x) < e/2" using \0 < e\ by (force simp: intro!: uniform_limitD) then have z1: "\\<^sub>F n in sequentially. dist (\ n z1) (g z1) < e/2" by simp show "\\<^sub>F n in sequentially. \x\K. dist (\ n x - \ n z1) (g x - g z1) < e" - apply (rule eventually_mono [OF eventually_conj [OF K z1]]) + apply (intro eventually_mono [OF eventually_conj [OF K z1]]) by (metis (no_types, opaque_lifting) diff_add_eq diff_diff_eq2 dist_commute dist_norm dist_triangle_add_half) qed show "\ (\z. g z - g z1) constant_on S - {z1}" diff -r 5af097d05e99 -r 7fee9141da5e src/Pure/Build/build_manager.scala --- a/src/Pure/Build/build_manager.scala Thu Mar 27 16:35:41 2025 +0100 +++ b/src/Pure/Build/build_manager.scala Fri Mar 28 08:24:07 2025 +0100 @@ -871,7 +871,10 @@ val rsync_context = Rsync.Context() private def sync(repository: Mercurial.Repository, rev: String, target: Path): String = { - repository.pull() + val pull_result = Exn.capture(repository.pull()) + if (Exn.is_exn(pull_result)) { + echo_error_message("Could not read from repository: " + Exn.the_exn(pull_result).getMessage) + } if (rev.nonEmpty) repository.sync(rsync_context, target, rev = rev)