src/HOL/Transcendental.thy
changeset 80621 6c369fec315a
parent 80612 e65eed943bee
child 80653 b98f1057da0e
equal deleted inserted replaced
80620:ee77d9d40be6 80621:6c369fec315a
  1492 
  1492 
  1493 lemma exp_le_cancel_iff [iff]: "exp x \<le> exp y \<longleftrightarrow> x \<le> y"
  1493 lemma exp_le_cancel_iff [iff]: "exp x \<le> exp y \<longleftrightarrow> x \<le> y"
  1494   for x y :: real
  1494   for x y :: real
  1495   by (auto simp: linorder_not_less [symmetric])
  1495   by (auto simp: linorder_not_less [symmetric])
  1496 
  1496 
       
  1497 lemma exp_mono:
       
  1498   fixes x y :: real
       
  1499   assumes "x \<le> y"
       
  1500   shows "exp x \<le> exp y"
       
  1501   using assms exp_le_cancel_iff by fastforce
       
  1502 
       
  1503 lemma exp_minus': "exp (-x) = 1 / (exp x)"
       
  1504   for x :: "'a::{real_normed_field,banach}"
       
  1505   by (simp add: exp_minus inverse_eq_divide)
       
  1506 
  1497 lemma exp_inj_iff [iff]: "exp x = exp y \<longleftrightarrow> x = y"
  1507 lemma exp_inj_iff [iff]: "exp x = exp y \<longleftrightarrow> x = y"
  1498   for x y :: real
  1508   for x y :: real
  1499   by (simp add: order_eq_iff)
  1509   by (simp add: order_eq_iff)
  1500 
  1510 
  1501 text \<open>Comparisons of \<^term>\<open>exp x\<close> with one.\<close>
  1511 text \<open>Comparisons of \<^term>\<open>exp x\<close> with one.\<close>
  1666 
  1676 
  1667 lemma ln_le_cancel_iff [simp]: "0 < x \<Longrightarrow> 0 < y \<Longrightarrow> ln x \<le> ln y \<longleftrightarrow> x \<le> y"
  1677 lemma ln_le_cancel_iff [simp]: "0 < x \<Longrightarrow> 0 < y \<Longrightarrow> ln x \<le> ln y \<longleftrightarrow> x \<le> y"
  1668   for x :: real
  1678   for x :: real
  1669   by (simp add: linorder_not_less [symmetric])
  1679   by (simp add: linorder_not_less [symmetric])
  1670 
  1680 
  1671 lemma ln_mono: "\<And>x::real. \<lbrakk>x \<le> y; 0 < x; 0 < y\<rbrakk> \<Longrightarrow> ln x \<le> ln y"
  1681 lemma ln_mono: "\<And>x::real. \<lbrakk>x \<le> y; 0 < x\<rbrakk> \<Longrightarrow> ln x \<le> ln y"
  1672   using ln_le_cancel_iff by presburger
  1682   by simp
       
  1683 
       
  1684 lemma ln_strict_mono: "\<And>x::real. \<lbrakk>x < y; 0 < x\<rbrakk> \<Longrightarrow> ln x < ln y"
       
  1685   by simp
  1673 
  1686 
  1674 lemma ln_inj_iff [simp]: "0 < x \<Longrightarrow> 0 < y \<Longrightarrow> ln x = ln y \<longleftrightarrow> x = y"
  1687 lemma ln_inj_iff [simp]: "0 < x \<Longrightarrow> 0 < y \<Longrightarrow> ln x = ln y \<longleftrightarrow> x = y"
  1675   for x :: real
  1688   for x :: real
  1676   by (simp add: order_eq_iff)
  1689   by (simp add: order_eq_iff)
  1677 
  1690 
  2324 subsection\<open>The general logarithm\<close>
  2337 subsection\<open>The general logarithm\<close>
  2325 
  2338 
  2326 definition log :: "real \<Rightarrow> real \<Rightarrow> real"
  2339 definition log :: "real \<Rightarrow> real \<Rightarrow> real"
  2327   \<comment> \<open>logarithm of \<^term>\<open>x\<close> to base \<^term>\<open>a\<close>\<close>
  2340   \<comment> \<open>logarithm of \<^term>\<open>x\<close> to base \<^term>\<open>a\<close>\<close>
  2328   where "log a x = ln x / ln a"
  2341   where "log a x = ln x / ln a"
       
  2342 
       
  2343 lemma log_exp [simp]: "log b (exp x) = x / ln b"
       
  2344   by (simp add: log_def)
  2329 
  2345 
  2330 lemma tendsto_log [tendsto_intros]:
  2346 lemma tendsto_log [tendsto_intros]:
  2331   "(f \<longlongrightarrow> a) F \<Longrightarrow> (g \<longlongrightarrow> b) F \<Longrightarrow> 0 < a \<Longrightarrow> a \<noteq> 1 \<Longrightarrow> b\<noteq>0 \<Longrightarrow>
  2347   "(f \<longlongrightarrow> a) F \<Longrightarrow> (g \<longlongrightarrow> b) F \<Longrightarrow> 0 < a \<Longrightarrow> a \<noteq> 1 \<Longrightarrow> b\<noteq>0 \<Longrightarrow>
  2332     ((\<lambda>x. log (f x) (g x)) \<longlongrightarrow> log a b) F"
  2348     ((\<lambda>x. log (f x) (g x)) \<longlongrightarrow> log a b) F"
  2333   unfolding log_def by (intro tendsto_intros) auto
  2349   unfolding log_def by (intro tendsto_intros) auto