src/HOL/Transcendental.thy
changeset 72219 0f38c96a0a74
parent 72211 a6cbf8ce979e
child 72220 bb29e4eb938d
equal deleted inserted replaced
72211:a6cbf8ce979e 72219:0f38c96a0a74
   741   ultimately have 3: "summable (\<lambda>n. norm (g h n))"
   741   ultimately have 3: "summable (\<lambda>n. norm (g h n))"
   742     by (rule summable_comparison_test)
   742     by (rule summable_comparison_test)
   743   then have "norm (suminf (g h)) \<le> (\<Sum>n. norm (g h n))"
   743   then have "norm (suminf (g h)) \<le> (\<Sum>n. norm (g h n))"
   744     by (rule summable_norm)
   744     by (rule summable_norm)
   745   also from 1 3 2 have "(\<Sum>n. norm (g h n)) \<le> (\<Sum>n. f n * norm h)"
   745   also from 1 3 2 have "(\<Sum>n. norm (g h n)) \<le> (\<Sum>n. f n * norm h)"
   746     by (rule suminf_le)
   746     by (simp add: suminf_le)
   747   also from f have "(\<Sum>n. f n * norm h) = suminf f * norm h"
   747   also from f have "(\<Sum>n. f n * norm h) = suminf f * norm h"
   748     by (rule suminf_mult2 [symmetric])
   748     by (rule suminf_mult2 [symmetric])
   749   finally show "norm (suminf (g h)) \<le> suminf f * norm h" .
   749   finally show "norm (suminf (g h)) \<le> suminf f * norm h" .
   750 qed
   750 qed
   751 
   751 
  1001   shows "(f \<longlongrightarrow> a 0) (at 0)"
  1001   shows "(f \<longlongrightarrow> a 0) (at 0)"
  1002 proof -
  1002 proof -
  1003   have *: "((\<lambda>x. if x = 0 then a 0 else f x) \<longlongrightarrow> a 0) (at 0)"
  1003   have *: "((\<lambda>x. if x = 0 then a 0 else f x) \<longlongrightarrow> a 0) (at 0)"
  1004     by (rule powser_limit_0 [OF s]) (auto simp: powser_sums_zero sm)
  1004     by (rule powser_limit_0 [OF s]) (auto simp: powser_sums_zero sm)
  1005   show ?thesis
  1005   show ?thesis
  1006     by (simp add: * LIM_equal [where g = "(\<lambda>x. if x = 0 then a 0 else f x)"])
  1006     using "*" by auto
  1007 qed
  1007 qed
  1008 
  1008 
  1009 
  1009 
  1010 subsection \<open>Derivability of power series\<close>
  1010 subsection \<open>Derivability of power series\<close>
  1011 
  1011 
  1572 proof
  1572 proof
  1573   assume "0 < x"
  1573   assume "0 < x"
  1574   have "1 + x \<le> (\<Sum>n<2. inverse (fact n) * x^n)"
  1574   have "1 + x \<le> (\<Sum>n<2. inverse (fact n) * x^n)"
  1575     by (auto simp: numeral_2_eq_2)
  1575     by (auto simp: numeral_2_eq_2)
  1576   also have "\<dots> \<le> (\<Sum>n. inverse (fact n) * x^n)"
  1576   also have "\<dots> \<le> (\<Sum>n. inverse (fact n) * x^n)"
  1577   proof (rule sum_le_suminf [OF summable_exp])
  1577     using \<open>0 < x\<close> by (auto  simp add: zero_le_mult_iff intro: sum_le_suminf [OF summable_exp])
  1578     show "\<forall>m\<in>- {..<2}. 0 \<le> inverse (fact m) * x ^ m"
       
  1579       using \<open>0 < x\<close> by (auto  simp add: zero_le_mult_iff)
       
  1580   qed auto
       
  1581   finally show "1 + x \<le> exp x"
  1578   finally show "1 + x \<le> exp x"
  1582     by (simp add: exp_def)
  1579     by (simp add: exp_def)
  1583 qed auto
  1580 qed auto
  1584 
  1581 
  1585 lemma exp_gt_one: "0 < x \<Longrightarrow> 1 < exp x"
  1582 lemma exp_gt_one: "0 < x \<Longrightarrow> 1 < exp x"
  3641       by (simp add: ac_simps divide_less_eq)
  3638       by (simp add: ac_simps divide_less_eq)
  3642 qed
  3639 qed
  3643   have sums: "?f sums sin x"
  3640   have sums: "?f sums sin x"
  3644     by (rule sin_paired [THEN sums_group]) simp
  3641     by (rule sin_paired [THEN sums_group]) simp
  3645   show "0 < sin x"
  3642   show "0 < sin x"
  3646     unfolding sums_unique [OF sums]
  3643     unfolding sums_unique [OF sums] using sums_summable [OF sums] pos by (simp add: suminf_pos)
  3647     using sums_summable [OF sums] pos
       
  3648     by (rule suminf_pos)
       
  3649 qed
  3644 qed
  3650 
  3645 
  3651 lemma cos_double_less_one: "0 < x \<Longrightarrow> x < 2 \<Longrightarrow> cos (2 * x) < 1"
  3646 lemma cos_double_less_one: "0 < x \<Longrightarrow> x < 2 \<Longrightarrow> cos (2 * x) < 1"
  3652   for x :: real
  3647   for x :: real
  3653   using sin_gt_zero_02 [where x = x] by (auto simp: cos_squared_eq cos_double)
  3648   using sin_gt_zero_02 [where x = x] by (auto simp: cos_squared_eq cos_double)