src/HOL/Limits.thy
changeset 58729 e8ecc79aee43
parent 57512 cc97b347b301
child 58889 5b7a9633cfa8
equal deleted inserted replaced
58728:42398b610f86 58729:e8ecc79aee43
   542   fixes f :: "'a \<Rightarrow> 'b \<Rightarrow> 'c::real_normed_vector"
   542   fixes f :: "'a \<Rightarrow> 'b \<Rightarrow> 'c::real_normed_vector"
   543   assumes "\<And>i. i \<in> S \<Longrightarrow> (f i ---> a i) F"
   543   assumes "\<And>i. i \<in> S \<Longrightarrow> (f i ---> a i) F"
   544   shows "((\<lambda>x. \<Sum>i\<in>S. f i x) ---> (\<Sum>i\<in>S. a i)) F"
   544   shows "((\<lambda>x. \<Sum>i\<in>S. f i x) ---> (\<Sum>i\<in>S. a i)) F"
   545 proof (cases "finite S")
   545 proof (cases "finite S")
   546   assume "finite S" thus ?thesis using assms
   546   assume "finite S" thus ?thesis using assms
   547     by (induct, simp add: tendsto_const, simp add: tendsto_add)
   547     by (induct, simp, simp add: tendsto_add)
   548 next
   548 qed simp
   549   assume "\<not> finite S" thus ?thesis
       
   550     by (simp add: tendsto_const)
       
   551 qed
       
   552 
   549 
   553 lemma continuous_setsum [continuous_intros]:
   550 lemma continuous_setsum [continuous_intros]:
   554   fixes f :: "'a \<Rightarrow> 'b::t2_space \<Rightarrow> 'c::real_normed_vector"
   551   fixes f :: "'a \<Rightarrow> 'b::t2_space \<Rightarrow> 'c::real_normed_vector"
   555   shows "(\<And>i. i \<in> S \<Longrightarrow> continuous F (f i)) \<Longrightarrow> continuous F (\<lambda>x. \<Sum>i\<in>S. f i x)"
   552   shows "(\<And>i. i \<in> S \<Longrightarrow> continuous F (f i)) \<Longrightarrow> continuous F (\<lambda>x. \<Sum>i\<in>S. f i x)"
   556   unfolding continuous_def by (rule tendsto_setsum)
   553   unfolding continuous_def by (rule tendsto_setsum)
   644   bounded_bilinear.tendsto_right_zero [OF bounded_bilinear_mult]
   641   bounded_bilinear.tendsto_right_zero [OF bounded_bilinear_mult]
   645 
   642 
   646 lemma tendsto_power [tendsto_intros]:
   643 lemma tendsto_power [tendsto_intros]:
   647   fixes f :: "'a \<Rightarrow> 'b::{power,real_normed_algebra}"
   644   fixes f :: "'a \<Rightarrow> 'b::{power,real_normed_algebra}"
   648   shows "(f ---> a) F \<Longrightarrow> ((\<lambda>x. f x ^ n) ---> a ^ n) F"
   645   shows "(f ---> a) F \<Longrightarrow> ((\<lambda>x. f x ^ n) ---> a ^ n) F"
   649   by (induct n) (simp_all add: tendsto_const tendsto_mult)
   646   by (induct n) (simp_all add: tendsto_mult)
   650 
   647 
   651 lemma continuous_power [continuous_intros]:
   648 lemma continuous_power [continuous_intros]:
   652   fixes f :: "'a::t2_space \<Rightarrow> 'b::{power,real_normed_algebra}"
   649   fixes f :: "'a::t2_space \<Rightarrow> 'b::{power,real_normed_algebra}"
   653   shows "continuous F f \<Longrightarrow> continuous F (\<lambda>x. (f x)^n)"
   650   shows "continuous F f \<Longrightarrow> continuous F (\<lambda>x. (f x)^n)"
   654   unfolding continuous_def by (rule tendsto_power)
   651   unfolding continuous_def by (rule tendsto_power)
   662   fixes f :: "'a \<Rightarrow> 'b \<Rightarrow> 'c::{real_normed_algebra,comm_ring_1}"
   659   fixes f :: "'a \<Rightarrow> 'b \<Rightarrow> 'c::{real_normed_algebra,comm_ring_1}"
   663   assumes "\<And>i. i \<in> S \<Longrightarrow> (f i ---> L i) F"
   660   assumes "\<And>i. i \<in> S \<Longrightarrow> (f i ---> L i) F"
   664   shows "((\<lambda>x. \<Prod>i\<in>S. f i x) ---> (\<Prod>i\<in>S. L i)) F"
   661   shows "((\<lambda>x. \<Prod>i\<in>S. f i x) ---> (\<Prod>i\<in>S. L i)) F"
   665 proof (cases "finite S")
   662 proof (cases "finite S")
   666   assume "finite S" thus ?thesis using assms
   663   assume "finite S" thus ?thesis using assms
   667     by (induct, simp add: tendsto_const, simp add: tendsto_mult)
   664     by (induct, simp, simp add: tendsto_mult)
   668 next
   665 qed simp
   669   assume "\<not> finite S" thus ?thesis
       
   670     by (simp add: tendsto_const)
       
   671 qed
       
   672 
   666 
   673 lemma continuous_setprod [continuous_intros]:
   667 lemma continuous_setprod [continuous_intros]:
   674   fixes f :: "'a \<Rightarrow> 'b::t2_space \<Rightarrow> 'c::{real_normed_algebra,comm_ring_1}"
   668   fixes f :: "'a \<Rightarrow> 'b::t2_space \<Rightarrow> 'c::{real_normed_algebra,comm_ring_1}"
   675   shows "(\<And>i. i \<in> S \<Longrightarrow> continuous F (f i)) \<Longrightarrow> continuous F (\<lambda>x. \<Prod>i\<in>S. f i x)"
   669   shows "(\<And>i. i \<in> S \<Longrightarrow> continuous F (f i)) \<Longrightarrow> continuous F (\<lambda>x. \<Prod>i\<in>S. f i x)"
   676   unfolding continuous_def by (rule tendsto_setprod)
   670   unfolding continuous_def by (rule tendsto_setprod)
  1478   from x0 x1 have "1 < inverse x"
  1472   from x0 x1 have "1 < inverse x"
  1479     by (rule one_less_inverse)
  1473     by (rule one_less_inverse)
  1480   hence "(\<lambda>n. inverse (inverse x ^ n)) ----> 0"
  1474   hence "(\<lambda>n. inverse (inverse x ^ n)) ----> 0"
  1481     by (rule LIMSEQ_inverse_realpow_zero)
  1475     by (rule LIMSEQ_inverse_realpow_zero)
  1482   thus ?thesis by (simp add: power_inverse)
  1476   thus ?thesis by (simp add: power_inverse)
  1483 qed (rule LIMSEQ_imp_Suc, simp add: tendsto_const)
  1477 qed (rule LIMSEQ_imp_Suc, simp)
  1484 
  1478 
  1485 lemma LIMSEQ_power_zero:
  1479 lemma LIMSEQ_power_zero:
  1486   fixes x :: "'a::{real_normed_algebra_1}"
  1480   fixes x :: "'a::{real_normed_algebra_1}"
  1487   shows "norm x < 1 \<Longrightarrow> (\<lambda>n. x ^ n) ----> 0"
  1481   shows "norm x < 1 \<Longrightarrow> (\<lambda>n. x ^ n) ----> 0"
  1488 apply (drule LIMSEQ_realpow_zero [OF norm_ge_zero])
  1482 apply (drule LIMSEQ_realpow_zero [OF norm_ge_zero])