author | ballarin |
Fri, 17 Mar 2006 10:04:27 +0100 | |
changeset 19279 | 48b527d0331b |
parent 18585 | 5d379fe2eb74 |
child 19765 | dfe940911617 |
permissions | -rw-r--r-- |
12196 | 1 |
(* Title : Transcendental.thy |
2 |
Author : Jacques D. Fleuriot |
|
3 |
Copyright : 1998,1999 University of Cambridge |
|
13958
c1c67582c9b5
New material on integration, etc. Moving Hyperreal/ex
paulson
parents:
12196
diff
changeset
|
4 |
1999,2001 University of Edinburgh |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
5 |
Conversion to Isar and new proofs by Lawrence C Paulson, 2004 |
12196 | 6 |
*) |
7 |
||
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
8 |
header{*Power Series, Transcendental Functions etc.*} |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
9 |
|
15131 | 10 |
theory Transcendental |
15140 | 11 |
imports NthRoot Fact HSeries EvenOdd Lim |
15131 | 12 |
begin |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
13 |
|
12196 | 14 |
constdefs |
15013 | 15 |
root :: "[nat,real] => real" |
12196 | 16 |
"root n x == (@u. ((0::real) < x --> 0 < u) & (u ^ n = x))" |
17 |
||
15013 | 18 |
sqrt :: "real => real" |
12196 | 19 |
"sqrt x == root 2 x" |
20 |
||
15013 | 21 |
exp :: "real => real" |
15546 | 22 |
"exp x == \<Sum>n. inverse(real (fact n)) * (x ^ n)" |
12196 | 23 |
|
15013 | 24 |
sin :: "real => real" |
15546 | 25 |
"sin x == \<Sum>n. (if even(n) then 0 else |
26 |
((- 1) ^ ((n - Suc 0) div 2))/(real (fact n))) * x ^ n" |
|
12196 | 27 |
|
15013 | 28 |
diffs :: "(nat => real) => nat => real" |
12196 | 29 |
"diffs c == (%n. real (Suc n) * c(Suc n))" |
30 |
||
15013 | 31 |
cos :: "real => real" |
15546 | 32 |
"cos x == \<Sum>n. (if even(n) then ((- 1) ^ (n div 2))/(real (fact n)) |
33 |
else 0) * x ^ n" |
|
12196 | 34 |
|
15013 | 35 |
ln :: "real => real" |
12196 | 36 |
"ln x == (@u. exp u = x)" |
37 |
||
15013 | 38 |
pi :: "real" |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
39 |
"pi == 2 * (@x. 0 \<le> (x::real) & x \<le> 2 & cos x = 0)" |
12196 | 40 |
|
15013 | 41 |
tan :: "real => real" |
12196 | 42 |
"tan x == (sin x)/(cos x)" |
43 |
||
15013 | 44 |
arcsin :: "real => real" |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
45 |
"arcsin y == (@x. -(pi/2) \<le> x & x \<le> pi/2 & sin x = y)" |
12196 | 46 |
|
15013 | 47 |
arcos :: "real => real" |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
48 |
"arcos y == (@x. 0 \<le> x & x \<le> pi & cos x = y)" |
12196 | 49 |
|
15013 | 50 |
arctan :: "real => real" |
12196 | 51 |
"arctan y == (@x. -(pi/2) < x & x < pi/2 & tan x = y)" |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
52 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
53 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
54 |
lemma real_root_zero [simp]: "root (Suc n) 0 = 0" |
15229 | 55 |
apply (simp add: root_def) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
56 |
apply (safe intro!: some_equality power_0_Suc elim!: realpow_zero_zero) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
57 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
58 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
59 |
lemma real_root_pow_pos: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
60 |
"0 < x ==> (root(Suc n) x) ^ (Suc n) = x" |
15229 | 61 |
apply (simp add: root_def) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
62 |
apply (drule_tac n = n in realpow_pos_nth2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
63 |
apply (auto intro: someI2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
64 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
65 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
66 |
lemma real_root_pow_pos2: "0 \<le> x ==> (root(Suc n) x) ^ (Suc n) = x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
67 |
by (auto dest!: real_le_imp_less_or_eq dest: real_root_pow_pos) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
68 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
69 |
lemma real_root_pos: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
70 |
"0 < x ==> root(Suc n) (x ^ (Suc n)) = x" |
15229 | 71 |
apply (simp add: root_def) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
72 |
apply (rule some_equality) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
73 |
apply (frule_tac [2] n = n in zero_less_power) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
74 |
apply (auto simp add: zero_less_mult_iff) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
75 |
apply (rule_tac x = u and y = x in linorder_cases) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
76 |
apply (drule_tac n1 = n and x = u in zero_less_Suc [THEN [3] realpow_less]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
77 |
apply (drule_tac [4] n1 = n and x = x in zero_less_Suc [THEN [3] realpow_less]) |
15539 | 78 |
apply (auto) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
79 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
80 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
81 |
lemma real_root_pos2: "0 \<le> x ==> root(Suc n) (x ^ (Suc n)) = x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
82 |
by (auto dest!: real_le_imp_less_or_eq real_root_pos) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
83 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
84 |
lemma real_root_pos_pos: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
85 |
"0 < x ==> 0 \<le> root(Suc n) x" |
15229 | 86 |
apply (simp add: root_def) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
87 |
apply (drule_tac n = n in realpow_pos_nth2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
88 |
apply (safe, rule someI2) |
15229 | 89 |
apply (auto intro!: order_less_imp_le dest: zero_less_power |
90 |
simp add: zero_less_mult_iff) |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
91 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
92 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
93 |
lemma real_root_pos_pos_le: "0 \<le> x ==> 0 \<le> root(Suc n) x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
94 |
by (auto dest!: real_le_imp_less_or_eq dest: real_root_pos_pos) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
95 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
96 |
lemma real_root_one [simp]: "root (Suc n) 1 = 1" |
15229 | 97 |
apply (simp add: root_def) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
98 |
apply (rule some_equality, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
99 |
apply (rule ccontr) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
100 |
apply (rule_tac x = u and y = 1 in linorder_cases) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
101 |
apply (drule_tac n = n in realpow_Suc_less_one) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
102 |
apply (drule_tac [4] n = n in power_gt1_lemma) |
15539 | 103 |
apply (auto) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
104 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
105 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
106 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
107 |
subsection{*Square Root*} |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
108 |
|
15229 | 109 |
text{*needed because 2 is a binary numeral!*} |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
110 |
lemma root_2_eq [simp]: "root 2 = root (Suc (Suc 0))" |
15229 | 111 |
by (simp del: nat_numeral_0_eq_0 nat_numeral_1_eq_1 |
112 |
add: nat_numeral_0_eq_0 [symmetric]) |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
113 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
114 |
lemma real_sqrt_zero [simp]: "sqrt 0 = 0" |
15229 | 115 |
by (simp add: sqrt_def) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
116 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
117 |
lemma real_sqrt_one [simp]: "sqrt 1 = 1" |
15229 | 118 |
by (simp add: sqrt_def) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
119 |
|
15539 | 120 |
lemma real_sqrt_pow2_iff [iff]: "((sqrt x)\<twosuperior> = x) = (0 \<le> x)" |
15229 | 121 |
apply (simp add: sqrt_def) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
122 |
apply (rule iffI) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
123 |
apply (cut_tac r = "root 2 x" in realpow_two_le) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
124 |
apply (simp add: numeral_2_eq_2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
125 |
apply (subst numeral_2_eq_2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
126 |
apply (erule real_root_pow_pos2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
127 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
128 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
129 |
lemma [simp]: "(sqrt(u2\<twosuperior> + v2\<twosuperior>))\<twosuperior> = u2\<twosuperior> + v2\<twosuperior>" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
130 |
by (rule realpow_two_le_add_order [THEN real_sqrt_pow2_iff [THEN iffD2]]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
131 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
132 |
lemma real_sqrt_pow2 [simp]: "0 \<le> x ==> (sqrt x)\<twosuperior> = x" |
15539 | 133 |
by (simp) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
134 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
135 |
lemma real_sqrt_abs_abs [simp]: "sqrt\<bar>x\<bar> ^ 2 = \<bar>x\<bar>" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
136 |
by (rule real_sqrt_pow2_iff [THEN iffD2], arith) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
137 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
138 |
lemma real_pow_sqrt_eq_sqrt_pow: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
139 |
"0 \<le> x ==> (sqrt x)\<twosuperior> = sqrt(x\<twosuperior>)" |
15229 | 140 |
apply (simp add: sqrt_def) |
15481 | 141 |
apply (simp only: numeral_2_eq_2 real_root_pow_pos2 real_root_pos2) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
142 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
143 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
144 |
lemma real_pow_sqrt_eq_sqrt_abs_pow2: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
145 |
"0 \<le> x ==> (sqrt x)\<twosuperior> = sqrt(\<bar>x\<bar> ^ 2)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
146 |
by (simp add: real_pow_sqrt_eq_sqrt_pow [symmetric]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
147 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
148 |
lemma real_sqrt_pow_abs: "0 \<le> x ==> (sqrt x)\<twosuperior> = \<bar>x\<bar>" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
149 |
apply (rule real_sqrt_abs_abs [THEN subst]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
150 |
apply (rule_tac x1 = x in real_pow_sqrt_eq_sqrt_abs_pow2 [THEN ssubst]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
151 |
apply (rule_tac [2] real_pow_sqrt_eq_sqrt_pow [symmetric]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
152 |
apply (assumption, arith) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
153 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
154 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
155 |
lemma not_real_square_gt_zero [simp]: "(~ (0::real) < x*x) = (x = 0)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
156 |
apply auto |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
157 |
apply (cut_tac x = x and y = 0 in linorder_less_linear) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
158 |
apply (simp add: zero_less_mult_iff) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
159 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
160 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
161 |
lemma real_sqrt_gt_zero: "0 < x ==> 0 < sqrt(x)" |
15229 | 162 |
apply (simp add: sqrt_def root_def) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
163 |
apply (drule realpow_pos_nth2 [where n=1], safe) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
164 |
apply (rule someI2, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
165 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
166 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
167 |
lemma real_sqrt_ge_zero: "0 \<le> x ==> 0 \<le> sqrt(x)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
168 |
by (auto intro: real_sqrt_gt_zero simp add: order_le_less) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
169 |
|
15228 | 170 |
lemma real_sqrt_mult_self_sum_ge_zero [simp]: "0 \<le> sqrt(x*x + y*y)" |
171 |
by (rule real_sqrt_ge_zero [OF real_mult_self_sum_ge_zero]) |
|
172 |
||
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
173 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
174 |
(*we need to prove something like this: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
175 |
lemma "[|r ^ n = a; 0<n; 0 < a \<longrightarrow> 0 < r|] ==> root n a = r" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
176 |
apply (case_tac n, simp) |
15229 | 177 |
apply (simp add: root_def) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
178 |
apply (rule someI2 [of _ r], safe) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
179 |
apply (auto simp del: realpow_Suc dest: power_inject_base) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
180 |
*) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
181 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
182 |
lemma sqrt_eqI: "[|r\<twosuperior> = a; 0 \<le> r|] ==> sqrt a = r" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
183 |
apply (unfold sqrt_def root_def) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
184 |
apply (rule someI2 [of _ r], auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
185 |
apply (auto simp add: numeral_2_eq_2 simp del: realpow_Suc |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
186 |
dest: power_inject_base) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
187 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
188 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
189 |
lemma real_sqrt_mult_distrib: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
190 |
"[| 0 \<le> x; 0 \<le> y |] ==> sqrt(x*y) = sqrt(x) * sqrt(y)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
191 |
apply (rule sqrt_eqI) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
192 |
apply (simp add: power_mult_distrib) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
193 |
apply (simp add: zero_le_mult_iff real_sqrt_ge_zero) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
194 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
195 |
|
15229 | 196 |
lemma real_sqrt_mult_distrib2: |
197 |
"[|0\<le>x; 0\<le>y |] ==> sqrt(x*y) = sqrt(x) * sqrt(y)" |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
198 |
by (auto intro: real_sqrt_mult_distrib simp add: order_le_less) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
199 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
200 |
lemma real_sqrt_sum_squares_ge_zero [simp]: "0 \<le> sqrt (x\<twosuperior> + y\<twosuperior>)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
201 |
by (auto intro!: real_sqrt_ge_zero) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
202 |
|
15229 | 203 |
lemma real_sqrt_sum_squares_mult_ge_zero [simp]: |
204 |
"0 \<le> sqrt ((x\<twosuperior> + y\<twosuperior>)*(xa\<twosuperior> + ya\<twosuperior>))" |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
205 |
by (auto intro!: real_sqrt_ge_zero simp add: zero_le_mult_iff) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
206 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
207 |
lemma real_sqrt_sum_squares_mult_squared_eq [simp]: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
208 |
"sqrt ((x\<twosuperior> + y\<twosuperior>) * (xa\<twosuperior> + ya\<twosuperior>)) ^ 2 = (x\<twosuperior> + y\<twosuperior>) * (xa\<twosuperior> + ya\<twosuperior>)" |
15539 | 209 |
by (auto simp add: zero_le_mult_iff simp del: realpow_Suc) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
210 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
211 |
lemma real_sqrt_abs [simp]: "sqrt(x\<twosuperior>) = \<bar>x\<bar>" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
212 |
apply (rule abs_realpow_two [THEN subst]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
213 |
apply (rule real_sqrt_abs_abs [THEN subst]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
214 |
apply (subst real_pow_sqrt_eq_sqrt_pow) |
15539 | 215 |
apply (auto simp add: numeral_2_eq_2) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
216 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
217 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
218 |
lemma real_sqrt_abs2 [simp]: "sqrt(x*x) = \<bar>x\<bar>" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
219 |
apply (rule realpow_two [THEN subst]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
220 |
apply (subst numeral_2_eq_2 [symmetric]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
221 |
apply (rule real_sqrt_abs) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
222 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
223 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
224 |
lemma real_sqrt_pow2_gt_zero: "0 < x ==> 0 < (sqrt x)\<twosuperior>" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
225 |
by simp |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
226 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
227 |
lemma real_sqrt_not_eq_zero: "0 < x ==> sqrt x \<noteq> 0" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
228 |
apply (frule real_sqrt_pow2_gt_zero) |
15539 | 229 |
apply (auto simp add: numeral_2_eq_2) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
230 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
231 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
232 |
lemma real_inv_sqrt_pow2: "0 < x ==> inverse (sqrt(x)) ^ 2 = inverse x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
233 |
by (cut_tac n1 = 2 and a1 = "sqrt x" in power_inverse [symmetric], auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
234 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
235 |
lemma real_sqrt_eq_zero_cancel: "[| 0 \<le> x; sqrt(x) = 0|] ==> x = 0" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
236 |
apply (drule real_le_imp_less_or_eq) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
237 |
apply (auto dest: real_sqrt_not_eq_zero) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
238 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
239 |
|
15229 | 240 |
lemma real_sqrt_eq_zero_cancel_iff [simp]: "0 \<le> x ==> ((sqrt x = 0) = (x=0))" |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
241 |
by (auto simp add: real_sqrt_eq_zero_cancel) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
242 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
243 |
lemma real_sqrt_sum_squares_ge1 [simp]: "x \<le> sqrt(x\<twosuperior> + y\<twosuperior>)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
244 |
apply (subgoal_tac "x \<le> 0 | 0 \<le> x", safe) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
245 |
apply (rule real_le_trans) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
246 |
apply (auto simp del: realpow_Suc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
247 |
apply (rule_tac n = 1 in realpow_increasing) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
248 |
apply (auto simp add: numeral_2_eq_2 [symmetric] simp del: realpow_Suc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
249 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
250 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
251 |
lemma real_sqrt_sum_squares_ge2 [simp]: "y \<le> sqrt(z\<twosuperior> + y\<twosuperior>)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
252 |
apply (simp (no_asm) add: real_add_commute del: realpow_Suc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
253 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
254 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
255 |
lemma real_sqrt_ge_one: "1 \<le> x ==> 1 \<le> sqrt x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
256 |
apply (rule_tac n = 1 in realpow_increasing) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
257 |
apply (auto simp add: numeral_2_eq_2 [symmetric] real_sqrt_ge_zero simp |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
258 |
del: realpow_Suc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
259 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
260 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
261 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
262 |
subsection{*Exponential Function*} |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
263 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
264 |
lemma summable_exp: "summable (%n. inverse (real (fact n)) * x ^ n)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
265 |
apply (cut_tac 'a = real in zero_less_one [THEN dense], safe) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
266 |
apply (cut_tac x = r in reals_Archimedean3, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
267 |
apply (drule_tac x = "\<bar>x\<bar>" in spec, safe) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
268 |
apply (rule_tac N = n and c = r in ratio_test) |
16924 | 269 |
apply (auto simp add: abs_mult mult_assoc [symmetric] simp del: fact_Suc) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
270 |
apply (rule mult_right_mono) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
271 |
apply (rule_tac b1 = "\<bar>x\<bar>" in mult_commute [THEN ssubst]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
272 |
apply (subst fact_Suc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
273 |
apply (subst real_of_nat_mult) |
15539 | 274 |
apply (auto) |
15229 | 275 |
apply (auto simp add: mult_assoc [symmetric] positive_imp_inverse_positive) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
276 |
apply (rule order_less_imp_le) |
15229 | 277 |
apply (rule_tac z1 = "real (Suc na)" in real_mult_less_iff1 [THEN iffD1]) |
15539 | 278 |
apply (auto simp add: real_not_refl2 [THEN not_sym] mult_assoc) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
279 |
apply (erule order_less_trans) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
280 |
apply (auto simp add: mult_less_cancel_left mult_ac) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
281 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
282 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
283 |
lemma summable_sin: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
284 |
"summable (%n. |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
285 |
(if even n then 0 |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
286 |
else (- 1) ^ ((n - Suc 0) div 2)/(real (fact n))) * |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
287 |
x ^ n)" |
15229 | 288 |
apply (rule_tac g = "(%n. inverse (real (fact n)) * \<bar>x\<bar> ^ n)" in summable_comparison_test) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
289 |
apply (rule_tac [2] summable_exp) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
290 |
apply (rule_tac x = 0 in exI) |
16924 | 291 |
apply (auto simp add: divide_inverse abs_mult power_abs [symmetric] zero_le_mult_iff) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
292 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
293 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
294 |
lemma summable_cos: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
295 |
"summable (%n. |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
296 |
(if even n then |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
297 |
(- 1) ^ (n div 2)/(real (fact n)) else 0) * x ^ n)" |
15229 | 298 |
apply (rule_tac g = "(%n. inverse (real (fact n)) * \<bar>x\<bar> ^ n)" in summable_comparison_test) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
299 |
apply (rule_tac [2] summable_exp) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
300 |
apply (rule_tac x = 0 in exI) |
16924 | 301 |
apply (auto simp add: divide_inverse abs_mult power_abs [symmetric] zero_le_mult_iff) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
302 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
303 |
|
15229 | 304 |
lemma lemma_STAR_sin [simp]: |
305 |
"(if even n then 0 |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
306 |
else (- 1) ^ ((n - Suc 0) div 2)/(real (fact n))) * 0 ^ n = 0" |
15251 | 307 |
by (induct "n", auto) |
15229 | 308 |
|
309 |
lemma lemma_STAR_cos [simp]: |
|
310 |
"0 < n --> |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
311 |
(- 1) ^ (n div 2)/(real (fact n)) * 0 ^ n = 0" |
15251 | 312 |
by (induct "n", auto) |
15229 | 313 |
|
314 |
lemma lemma_STAR_cos1 [simp]: |
|
315 |
"0 < n --> |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
316 |
(-1) ^ (n div 2)/(real (fact n)) * 0 ^ n = 0" |
15251 | 317 |
by (induct "n", auto) |
15229 | 318 |
|
319 |
lemma lemma_STAR_cos2 [simp]: |
|
15539 | 320 |
"(\<Sum>n=1..<n. if even n then (- 1) ^ (n div 2)/(real (fact n)) * 0 ^ n |
321 |
else 0) = 0" |
|
15251 | 322 |
apply (induct "n") |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
323 |
apply (case_tac [2] "n", auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
324 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
325 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
326 |
lemma exp_converges: "(%n. inverse (real (fact n)) * x ^ n) sums exp(x)" |
15229 | 327 |
apply (simp add: exp_def) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
328 |
apply (rule summable_exp [THEN summable_sums]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
329 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
330 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
331 |
lemma sin_converges: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
332 |
"(%n. (if even n then 0 |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
333 |
else (- 1) ^ ((n - Suc 0) div 2)/(real (fact n))) * |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
334 |
x ^ n) sums sin(x)" |
15229 | 335 |
apply (simp add: sin_def) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
336 |
apply (rule summable_sin [THEN summable_sums]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
337 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
338 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
339 |
lemma cos_converges: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
340 |
"(%n. (if even n then |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
341 |
(- 1) ^ (n div 2)/(real (fact n)) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
342 |
else 0) * x ^ n) sums cos(x)" |
15229 | 343 |
apply (simp add: cos_def) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
344 |
apply (rule summable_cos [THEN summable_sums]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
345 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
346 |
|
15229 | 347 |
lemma lemma_realpow_diff [rule_format (no_asm)]: |
348 |
"p \<le> n --> y ^ (Suc n - p) = ((y::real) ^ (n - p)) * y" |
|
15251 | 349 |
apply (induct "n", auto) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
350 |
apply (subgoal_tac "p = Suc n") |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
351 |
apply (simp (no_asm_simp), auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
352 |
apply (drule sym) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
353 |
apply (simp add: Suc_diff_le mult_commute realpow_Suc [symmetric] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
354 |
del: realpow_Suc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
355 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
356 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
357 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
358 |
subsection{*Properties of Power Series*} |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
359 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
360 |
lemma lemma_realpow_diff_sumr: |
15539 | 361 |
"(\<Sum>p=0..<Suc n. (x ^ p) * y ^ ((Suc n) - p)) = |
362 |
y * (\<Sum>p=0..<Suc n. (x ^ p) * (y ^ (n - p))::real)" |
|
19279 | 363 |
by (auto simp add: setsum_right_distrib lemma_realpow_diff mult_ac |
16641
fce796ad9c2b
Simplified some proofs (thanks to strong_setsum_cong).
berghofe
parents:
15561
diff
changeset
|
364 |
simp del: setsum_op_ivl_Suc cong: strong_setsum_cong) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
365 |
|
15229 | 366 |
lemma lemma_realpow_diff_sumr2: |
367 |
"x ^ (Suc n) - y ^ (Suc n) = |
|
15539 | 368 |
(x - y) * (\<Sum>p=0..<Suc n. (x ^ p) * (y ^(n - p))::real)" |
15251 | 369 |
apply (induct "n", simp) |
15561 | 370 |
apply (auto simp del: setsum_op_ivl_Suc) |
371 |
apply (subst setsum_op_ivl_Suc) |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
372 |
apply (drule sym) |
15561 | 373 |
apply (auto simp add: lemma_realpow_diff_sumr right_distrib diff_minus mult_ac simp del: setsum_op_ivl_Suc) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
374 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
375 |
|
15229 | 376 |
lemma lemma_realpow_rev_sumr: |
15539 | 377 |
"(\<Sum>p=0..<Suc n. (x ^ p) * (y ^ (n - p))) = |
378 |
(\<Sum>p=0..<Suc n. (x ^ (n - p)) * (y ^ p)::real)" |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
379 |
apply (case_tac "x = y") |
15561 | 380 |
apply (auto simp add: mult_commute power_add [symmetric] simp del: setsum_op_ivl_Suc) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
381 |
apply (rule_tac c1 = "x - y" in real_mult_left_cancel [THEN iffD1]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
382 |
apply (rule_tac [2] minus_minus [THEN subst], simp) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
383 |
apply (subst minus_mult_left) |
15561 | 384 |
apply (simp add: lemma_realpow_diff_sumr2 [symmetric] del: setsum_op_ivl_Suc) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
385 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
386 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
387 |
text{*Power series has a `circle` of convergence, i.e. if it sums for @{term |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
388 |
x}, then it sums absolutely for @{term z} with @{term "\<bar>z\<bar> < \<bar>x\<bar>"}.*} |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
389 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
390 |
lemma powser_insidea: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
391 |
"[| summable (%n. f(n) * (x ^ n)); \<bar>z\<bar> < \<bar>x\<bar> |] |
15081 | 392 |
==> summable (%n. \<bar>f(n)\<bar> * (z ^ n))" |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
393 |
apply (drule summable_LIMSEQ_zero) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
394 |
apply (drule convergentI) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
395 |
apply (simp add: Cauchy_convergent_iff [symmetric]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
396 |
apply (drule Cauchy_Bseq) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
397 |
apply (simp add: Bseq_def, safe) |
15081 | 398 |
apply (rule_tac g = "%n. K * \<bar>z ^ n\<bar> * inverse (\<bar>x ^ n\<bar>)" in summable_comparison_test) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
399 |
apply (rule_tac x = 0 in exI, safe) |
15081 | 400 |
apply (subgoal_tac "0 < \<bar>x ^ n\<bar> ") |
401 |
apply (rule_tac c="\<bar>x ^ n\<bar>" in mult_right_le_imp_le) |
|
16924 | 402 |
apply (auto simp add: mult_assoc power_abs abs_mult) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
403 |
prefer 2 |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
404 |
apply (drule_tac x = 0 in spec, force) |
15539 | 405 |
apply (auto simp add: power_abs mult_ac) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
406 |
apply (rule_tac a2 = "z ^ n" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
407 |
in abs_ge_zero [THEN real_le_imp_less_or_eq, THEN disjE]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
408 |
apply (auto intro!: mult_right_mono simp add: mult_assoc [symmetric] power_abs summable_def power_0_left) |
15229 | 409 |
apply (rule_tac x = "K * inverse (1 - (\<bar>z\<bar> * inverse (\<bar>x\<bar>)))" in exI) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
410 |
apply (auto intro!: sums_mult simp add: mult_assoc) |
15081 | 411 |
apply (subgoal_tac "\<bar>z ^ n\<bar> * inverse (\<bar>x\<bar> ^ n) = (\<bar>z\<bar> * inverse (\<bar>x\<bar>)) ^ n") |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
412 |
apply (auto simp add: power_abs [symmetric]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
413 |
apply (subgoal_tac "x \<noteq> 0") |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
414 |
apply (subgoal_tac [3] "x \<noteq> 0") |
16924 | 415 |
apply (auto simp del: abs_inverse |
416 |
simp add: abs_inverse [symmetric] realpow_not_zero |
|
417 |
abs_mult [symmetric] power_inverse power_mult_distrib [symmetric]) |
|
15539 | 418 |
apply (auto intro!: geometric_sums simp add: power_abs inverse_eq_divide) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
419 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
420 |
|
15229 | 421 |
lemma powser_inside: |
422 |
"[| summable (%n. f(n) * (x ^ n)); \<bar>z\<bar> < \<bar>x\<bar> |] |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
423 |
==> summable (%n. f(n) * (z ^ n))" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
424 |
apply (drule_tac z = "\<bar>z\<bar>" in powser_insidea) |
16924 | 425 |
apply (auto intro: summable_rabs_cancel simp add: abs_mult power_abs [symmetric]) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
426 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
427 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
428 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
429 |
subsection{*Differentiation of Power Series*} |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
430 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
431 |
text{*Lemma about distributing negation over it*} |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
432 |
lemma diffs_minus: "diffs (%n. - c n) = (%n. - diffs c n)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
433 |
by (simp add: diffs_def) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
434 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
435 |
text{*Show that we can shift the terms down one*} |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
436 |
lemma lemma_diffs: |
15539 | 437 |
"(\<Sum>n=0..<n. (diffs c)(n) * (x ^ n)) = |
438 |
(\<Sum>n=0..<n. real n * c(n) * (x ^ (n - Suc 0))) + |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
439 |
(real n * c(n) * x ^ (n - Suc 0))" |
15251 | 440 |
apply (induct "n") |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
441 |
apply (auto simp add: mult_assoc add_assoc [symmetric] diffs_def) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
442 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
443 |
|
15229 | 444 |
lemma lemma_diffs2: |
15539 | 445 |
"(\<Sum>n=0..<n. real n * c(n) * (x ^ (n - Suc 0))) = |
446 |
(\<Sum>n=0..<n. (diffs c)(n) * (x ^ n)) - |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
447 |
(real n * c(n) * x ^ (n - Suc 0))" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
448 |
by (auto simp add: lemma_diffs) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
449 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
450 |
|
15229 | 451 |
lemma diffs_equiv: |
452 |
"summable (%n. (diffs c)(n) * (x ^ n)) ==> |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
453 |
(%n. real n * c(n) * (x ^ (n - Suc 0))) sums |
15546 | 454 |
(\<Sum>n. (diffs c)(n) * (x ^ n))" |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
455 |
apply (subgoal_tac " (%n. real n * c (n) * (x ^ (n - Suc 0))) ----> 0") |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
456 |
apply (rule_tac [2] LIMSEQ_imp_Suc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
457 |
apply (drule summable_sums) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
458 |
apply (auto simp add: sums_def) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
459 |
apply (drule_tac X="(\<lambda>n. \<Sum>n = 0..<n. diffs c n * x ^ n)" in LIMSEQ_diff) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
460 |
apply (auto simp add: lemma_diffs2 [symmetric] diffs_def [symmetric]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
461 |
apply (simp add: diffs_def summable_LIMSEQ_zero) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
462 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
463 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
464 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
465 |
subsection{*Term-by-Term Differentiability of Power Series*} |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
466 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
467 |
lemma lemma_termdiff1: |
15539 | 468 |
"(\<Sum>p=0..<m. (((z + h) ^ (m - p)) * (z ^ p)) - (z ^ m)) = |
469 |
(\<Sum>p=0..<m. (z ^ p) * (((z + h) ^ (m - p)) - (z ^ (m - p)))::real)" |
|
16641
fce796ad9c2b
Simplified some proofs (thanks to strong_setsum_cong).
berghofe
parents:
15561
diff
changeset
|
470 |
by (auto simp add: right_distrib diff_minus power_add [symmetric] mult_ac |
fce796ad9c2b
Simplified some proofs (thanks to strong_setsum_cong).
berghofe
parents:
15561
diff
changeset
|
471 |
cong: strong_setsum_cong) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
472 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
473 |
lemma less_add_one: "m < n ==> (\<exists>d. n = m + d + Suc 0)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
474 |
by (simp add: less_iff_Suc_add) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
475 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
476 |
lemma sumdiff: "a + b - (c + d) = a - c + b - (d::real)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
477 |
by arith |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
478 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
479 |
|
15229 | 480 |
lemma lemma_termdiff2: |
15539 | 481 |
"h \<noteq> 0 ==> |
482 |
(((z + h) ^ n) - (z ^ n)) * inverse h - real n * (z ^ (n - Suc 0)) = |
|
483 |
h * (\<Sum>p=0..< n - Suc 0. (z ^ p) * |
|
484 |
(\<Sum>q=0..< (n - Suc 0) - p. ((z + h) ^ q) * (z ^ (((n - 2) - p) - q))))" |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
485 |
apply (rule real_mult_left_cancel [THEN iffD1], simp (no_asm_simp)) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
486 |
apply (simp add: right_diff_distrib mult_ac) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
487 |
apply (simp add: mult_assoc [symmetric]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
488 |
apply (case_tac "n") |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
489 |
apply (auto simp add: lemma_realpow_diff_sumr2 |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
490 |
right_diff_distrib [symmetric] mult_assoc |
15561 | 491 |
simp del: realpow_Suc setsum_op_ivl_Suc) |
492 |
apply (auto simp add: lemma_realpow_rev_sumr simp del: setsum_op_ivl_Suc) |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
493 |
apply (auto simp add: real_of_nat_Suc sumr_diff_mult_const left_distrib |
19279 | 494 |
sumdiff lemma_termdiff1 setsum_right_distrib) |
15539 | 495 |
apply (auto intro!: setsum_cong[OF refl] simp add: diff_minus real_add_assoc) |
496 |
apply (simp add: diff_minus [symmetric] less_iff_Suc_add) |
|
19279 | 497 |
apply (auto simp add: setsum_right_distrib lemma_realpow_diff_sumr2 mult_ac simp |
15561 | 498 |
del: setsum_op_ivl_Suc realpow_Suc) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
499 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
500 |
|
15229 | 501 |
lemma lemma_termdiff3: |
502 |
"[| h \<noteq> 0; \<bar>z\<bar> \<le> K; \<bar>z + h\<bar> \<le> K |] |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
503 |
==> abs (((z + h) ^ n - z ^ n) * inverse h - real n * z ^ (n - Suc 0)) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
504 |
\<le> real n * real (n - Suc 0) * K ^ (n - 2) * \<bar>h\<bar>" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
505 |
apply (subst lemma_termdiff2, assumption) |
16924 | 506 |
apply (simp add: mult_commute abs_mult) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
507 |
apply (simp add: mult_commute [of _ "K ^ (n - 2)"]) |
15536 | 508 |
apply (rule setsum_abs [THEN real_le_trans]) |
16924 | 509 |
apply (simp add: mult_assoc [symmetric] abs_mult) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
510 |
apply (simp add: mult_commute [of _ "real (n - Suc 0)"]) |
15542 | 511 |
apply (auto intro!: real_setsum_nat_ivl_bounded) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
512 |
apply (case_tac "n", auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
513 |
apply (drule less_add_one) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
514 |
(*CLAIM_SIMP " (a * b * c = a * (c * (b::real))" mult_ac]*) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
515 |
apply clarify |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
516 |
apply (subgoal_tac "K ^ p * K ^ d * real (Suc (Suc (p + d))) = |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
517 |
K ^ p * (real (Suc (Suc (p + d))) * K ^ d)") |
15561 | 518 |
apply (simp (no_asm_simp) add: power_add del: setsum_op_ivl_Suc) |
519 |
apply (auto intro!: mult_mono simp del: setsum_op_ivl_Suc) |
|
16924 | 520 |
apply (auto intro!: power_mono simp add: power_abs |
521 |
simp del: setsum_op_ivl_Suc) |
|
15229 | 522 |
apply (rule_tac j = "real (Suc d) * (K ^ d)" in real_le_trans) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
523 |
apply (subgoal_tac [2] "0 \<le> K") |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
524 |
apply (drule_tac [2] n = d in zero_le_power) |
15561 | 525 |
apply (auto simp del: setsum_op_ivl_Suc) |
15536 | 526 |
apply (rule setsum_abs [THEN real_le_trans]) |
16924 | 527 |
apply (rule real_setsum_nat_ivl_bounded) |
528 |
apply (auto dest!: less_add_one intro!: mult_mono simp add: power_add abs_mult) |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
529 |
apply (auto intro!: power_mono zero_le_power simp add: power_abs, arith+) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
530 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
531 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
532 |
lemma lemma_termdiff4: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
533 |
"[| 0 < k; |
15081 | 534 |
(\<forall>h. 0 < \<bar>h\<bar> & \<bar>h\<bar> < k --> \<bar>f h\<bar> \<le> K * \<bar>h\<bar>) |] |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
535 |
==> f -- 0 --> 0" |
15229 | 536 |
apply (simp add: LIM_def, auto) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
537 |
apply (subgoal_tac "0 \<le> K") |
15229 | 538 |
prefer 2 |
539 |
apply (drule_tac x = "k/2" in spec) |
|
540 |
apply (simp add: ); |
|
541 |
apply (subgoal_tac "0 \<le> K*k", simp add: zero_le_mult_iff) |
|
542 |
apply (force intro: order_trans [of _ "\<bar>f (k / 2)\<bar> * 2"]) |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
543 |
apply (drule real_le_imp_less_or_eq, auto) |
15229 | 544 |
apply (subgoal_tac "0 < (r * inverse K) / 2") |
545 |
apply (drule_tac ?d1.0 = "(r * inverse K) / 2" and ?d2.0 = k in real_lbound_gt_zero) |
|
546 |
apply (auto simp add: positive_imp_inverse_positive zero_less_mult_iff zero_less_divide_iff) |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
547 |
apply (rule_tac x = e in exI, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
548 |
apply (rule_tac y = "K * \<bar>x\<bar>" in order_le_less_trans) |
15229 | 549 |
apply (force ); |
550 |
apply (rule_tac y = "K * e" in order_less_trans) |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
551 |
apply (simp add: mult_less_cancel_left) |
15229 | 552 |
apply (rule_tac c = "inverse K" in mult_right_less_imp_less) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
553 |
apply (auto simp add: mult_ac) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
554 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
555 |
|
15229 | 556 |
lemma lemma_termdiff5: |
557 |
"[| 0 < k; |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
558 |
summable f; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
559 |
\<forall>h. 0 < \<bar>h\<bar> & \<bar>h\<bar> < k --> |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
560 |
(\<forall>n. abs(g(h) (n::nat)) \<le> (f(n) * \<bar>h\<bar>)) |] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
561 |
==> (%h. suminf(g h)) -- 0 --> 0" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
562 |
apply (drule summable_sums) |
15081 | 563 |
apply (subgoal_tac "\<forall>h. 0 < \<bar>h\<bar> & \<bar>h\<bar> < k --> \<bar>suminf (g h)\<bar> \<le> suminf f * \<bar>h\<bar>") |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
564 |
apply (auto intro!: lemma_termdiff4 simp add: sums_summable [THEN suminf_mult, symmetric]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
565 |
apply (subgoal_tac "summable (%n. f n * \<bar>h\<bar>) ") |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
566 |
prefer 2 |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
567 |
apply (simp add: summable_def) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
568 |
apply (rule_tac x = "suminf f * \<bar>h\<bar>" in exI) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
569 |
apply (drule_tac c = "\<bar>h\<bar>" in sums_mult) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
570 |
apply (simp add: mult_ac) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
571 |
apply (subgoal_tac "summable (%n. abs (g (h::real) (n::nat))) ") |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
572 |
apply (rule_tac [2] g = "%n. f n * \<bar>h\<bar>" in summable_comparison_test) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
573 |
apply (rule_tac [2] x = 0 in exI, auto) |
15546 | 574 |
apply (rule_tac j = "\<Sum>n. \<bar>g h n\<bar>" in real_le_trans) |
16819 | 575 |
apply (auto intro: summable_rabs summable_le simp add: sums_summable [THEN suminf_mult2]) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
576 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
577 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
578 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
579 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
580 |
text{* FIXME: Long proofs*} |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
581 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
582 |
lemma termdiffs_aux: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
583 |
"[|summable (\<lambda>n. diffs (diffs c) n * K ^ n); \<bar>x\<bar> < \<bar>K\<bar> |] |
15546 | 584 |
==> (\<lambda>h. \<Sum>n. c n * |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
585 |
(((x + h) ^ n - x ^ n) * inverse h - |
15546 | 586 |
real n * x ^ (n - Suc 0))) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
587 |
-- 0 --> 0" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
588 |
apply (drule dense, safe) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
589 |
apply (frule real_less_sum_gt_zero) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
590 |
apply (drule_tac |
15081 | 591 |
f = "%n. \<bar>c n\<bar> * real n * real (n - Suc 0) * (r ^ (n - 2))" |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
592 |
and g = "%h n. c (n) * ((( ((x + h) ^ n) - (x ^ n)) * inverse h) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
593 |
- (real n * (x ^ (n - Suc 0))))" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
594 |
in lemma_termdiff5) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
595 |
apply (auto simp add: add_commute) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
596 |
apply (subgoal_tac "summable (%n. \<bar>diffs (diffs c) n\<bar> * (r ^ n))") |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
597 |
apply (rule_tac [2] x = K in powser_insidea, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
598 |
apply (subgoal_tac [2] "\<bar>r\<bar> = r", auto) |
16775
c1b87ef4a1c3
added lemmas to OrderedGroup.thy (reasoning about signs, absolute value, triangle inequalities)
avigad
parents:
16641
diff
changeset
|
599 |
apply (rule_tac [2] y1 = "\<bar>x\<bar>" in order_trans [THEN abs_of_nonneg], auto) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
600 |
apply (simp add: diffs_def mult_assoc [symmetric]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
601 |
apply (subgoal_tac |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
602 |
"\<forall>n. real (Suc n) * real (Suc (Suc n)) * \<bar>c (Suc (Suc n))\<bar> * (r ^ n) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
603 |
= diffs (diffs (%n. \<bar>c n\<bar>)) n * (r ^ n) ") |
16924 | 604 |
apply (auto simp add: abs_mult) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
605 |
apply (drule diffs_equiv) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
606 |
apply (drule sums_summable) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
607 |
apply (simp_all add: diffs_def) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
608 |
apply (simp add: diffs_def mult_ac) |
15081 | 609 |
apply (subgoal_tac " (%n. real n * (real (Suc n) * (\<bar>c (Suc n)\<bar> * (r ^ (n - Suc 0))))) = (%n. diffs (%m. real (m - Suc 0) * \<bar>c m\<bar> * inverse r) n * (r ^ n))") |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
610 |
apply auto |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
611 |
prefer 2 |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
612 |
apply (rule ext) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
613 |
apply (simp add: diffs_def) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
614 |
apply (case_tac "n", auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
615 |
txt{*23*} |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
616 |
apply (drule abs_ge_zero [THEN order_le_less_trans]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
617 |
apply (simp add: mult_ac) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
618 |
apply (drule abs_ge_zero [THEN order_le_less_trans]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
619 |
apply (simp add: mult_ac) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
620 |
apply (drule diffs_equiv) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
621 |
apply (drule sums_summable) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
622 |
apply (subgoal_tac |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
623 |
"summable |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
624 |
(\<lambda>n. real n * (real (n - Suc 0) * \<bar>c n\<bar> * inverse r) * |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
625 |
r ^ (n - Suc 0)) = |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
626 |
summable |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
627 |
(\<lambda>n. real n * (\<bar>c n\<bar> * (real (n - Suc 0) * r ^ (n - 2))))") |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
628 |
apply simp |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
629 |
apply (rule_tac f = summable in arg_cong, rule ext) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
630 |
txt{*33*} |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
631 |
apply (case_tac "n", auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
632 |
apply (case_tac "nat", auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
633 |
apply (drule abs_ge_zero [THEN order_le_less_trans], auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
634 |
apply (drule abs_ge_zero [THEN order_le_less_trans]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
635 |
apply (simp add: mult_assoc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
636 |
apply (rule mult_left_mono) |
15229 | 637 |
prefer 2 apply arith |
638 |
apply (subst add_commute) |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
639 |
apply (simp (no_asm) add: mult_assoc [symmetric]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
640 |
apply (rule lemma_termdiff3) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
641 |
apply (auto intro: abs_triangle_ineq [THEN order_trans], arith) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
642 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
643 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
644 |
lemma termdiffs: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
645 |
"[| summable(%n. c(n) * (K ^ n)); |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
646 |
summable(%n. (diffs c)(n) * (K ^ n)); |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
647 |
summable(%n. (diffs(diffs c))(n) * (K ^ n)); |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
648 |
\<bar>x\<bar> < \<bar>K\<bar> |] |
15546 | 649 |
==> DERIV (%x. \<Sum>n. c(n) * (x ^ n)) x :> |
650 |
(\<Sum>n. (diffs c)(n) * (x ^ n))" |
|
15229 | 651 |
apply (simp add: deriv_def) |
15546 | 652 |
apply (rule_tac g = "%h. \<Sum>n. ((c (n) * ( (x + h) ^ n)) - (c (n) * (x ^ n))) * inverse h" in LIM_trans) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
653 |
apply (simp add: LIM_def, safe) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
654 |
apply (rule_tac x = "\<bar>K\<bar> - \<bar>x\<bar>" in exI) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
655 |
apply (auto simp add: less_diff_eq) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
656 |
apply (drule abs_triangle_ineq [THEN order_le_less_trans]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
657 |
apply (rule_tac y = 0 in order_le_less_trans, auto) |
15546 | 658 |
apply (subgoal_tac " (%n. (c n) * (x ^ n)) sums (\<Sum>n. (c n) * (x ^ n)) & (%n. (c n) * ((x + xa) ^ n)) sums (\<Sum>n. (c n) * ( (x + xa) ^ n))") |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
659 |
apply (auto intro!: summable_sums) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
660 |
apply (rule_tac [2] powser_inside, rule_tac [4] powser_inside) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
661 |
apply (auto simp add: add_commute) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
662 |
apply (drule_tac x="(\<lambda>n. c n * (xa + x) ^ n)" in sums_diff, assumption) |
16819 | 663 |
apply (drule_tac f = "(%n. c n * (xa + x) ^ n - c n * x ^ n) " and c = "inverse xa" in sums_mult) |
15085
5693a977a767
removed some [iff] declarations from RealDef.thy, concerning inequalities
paulson
parents:
15081
diff
changeset
|
664 |
apply (rule sums_unique) |
15079
2ef899e4526d
conversion of Hyperreal/MacLaurin_lemmas to Isar script
paulson
parents:
15077
diff
changeset
|
665 |
apply (simp add: diff_def divide_inverse add_ac mult_ac) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
666 |
apply (rule LIM_zero_cancel) |
15546 | 667 |
apply (rule_tac g = "%h. \<Sum>n. c (n) * ((( ((x + h) ^ n) - (x ^ n)) * inverse h) - (real n * (x ^ (n - Suc 0))))" in LIM_trans) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
668 |
prefer 2 apply (blast intro: termdiffs_aux) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
669 |
apply (simp add: LIM_def, safe) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
670 |
apply (rule_tac x = "\<bar>K\<bar> - \<bar>x\<bar>" in exI) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
671 |
apply (auto simp add: less_diff_eq) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
672 |
apply (drule abs_triangle_ineq [THEN order_le_less_trans]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
673 |
apply (rule_tac y = 0 in order_le_less_trans, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
674 |
apply (subgoal_tac "summable (%n. (diffs c) (n) * (x ^ n))") |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
675 |
apply (rule_tac [2] powser_inside, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
676 |
apply (drule_tac c = c and x = x in diffs_equiv) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
677 |
apply (frule sums_unique, auto) |
15546 | 678 |
apply (subgoal_tac " (%n. (c n) * (x ^ n)) sums (\<Sum>n. (c n) * (x ^ n)) & (%n. (c n) * ((x + xa) ^ n)) sums (\<Sum>n. (c n) * ( (x + xa) ^ n))") |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
679 |
apply safe |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
680 |
apply (auto intro!: summable_sums) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
681 |
apply (rule_tac [2] powser_inside, rule_tac [4] powser_inside) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
682 |
apply (auto simp add: add_commute) |
15229 | 683 |
apply (frule_tac x = "(%n. c n * (xa + x) ^ n) " and y = "(%n. c n * x ^ n)" in sums_diff, assumption) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
684 |
apply (simp add: suminf_diff [OF sums_summable sums_summable] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
685 |
right_diff_distrib [symmetric]) |
16819 | 686 |
apply (subst suminf_diff) |
687 |
apply (rule summable_mult2) |
|
688 |
apply (erule sums_summable) |
|
689 |
apply (erule sums_summable) |
|
690 |
apply (simp add: ring_eq_simps) |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
691 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
692 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
693 |
subsection{*Formal Derivatives of Exp, Sin, and Cos Series*} |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
694 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
695 |
lemma exp_fdiffs: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
696 |
"diffs (%n. inverse(real (fact n))) = (%n. inverse(real (fact n)))" |
15229 | 697 |
by (simp add: diffs_def mult_assoc [symmetric] del: mult_Suc) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
698 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
699 |
lemma sin_fdiffs: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
700 |
"diffs(%n. if even n then 0 |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
701 |
else (- 1) ^ ((n - Suc 0) div 2)/(real (fact n))) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
702 |
= (%n. if even n then |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
703 |
(- 1) ^ (n div 2)/(real (fact n)) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
704 |
else 0)" |
15229 | 705 |
by (auto intro!: ext |
706 |
simp add: diffs_def divide_inverse simp del: mult_Suc) |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
707 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
708 |
lemma sin_fdiffs2: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
709 |
"diffs(%n. if even n then 0 |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
710 |
else (- 1) ^ ((n - Suc 0) div 2)/(real (fact n))) n |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
711 |
= (if even n then |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
712 |
(- 1) ^ (n div 2)/(real (fact n)) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
713 |
else 0)" |
15229 | 714 |
by (auto intro!: ext |
715 |
simp add: diffs_def divide_inverse simp del: mult_Suc) |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
716 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
717 |
lemma cos_fdiffs: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
718 |
"diffs(%n. if even n then |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
719 |
(- 1) ^ (n div 2)/(real (fact n)) else 0) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
720 |
= (%n. - (if even n then 0 |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
721 |
else (- 1) ^ ((n - Suc 0)div 2)/(real (fact n))))" |
15229 | 722 |
by (auto intro!: ext |
723 |
simp add: diffs_def divide_inverse odd_Suc_mult_two_ex |
|
724 |
simp del: mult_Suc) |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
725 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
726 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
727 |
lemma cos_fdiffs2: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
728 |
"diffs(%n. if even n then |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
729 |
(- 1) ^ (n div 2)/(real (fact n)) else 0) n |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
730 |
= - (if even n then 0 |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
731 |
else (- 1) ^ ((n - Suc 0)div 2)/(real (fact n)))" |
15229 | 732 |
by (auto intro!: ext |
733 |
simp add: diffs_def divide_inverse odd_Suc_mult_two_ex |
|
734 |
simp del: mult_Suc) |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
735 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
736 |
text{*Now at last we can get the derivatives of exp, sin and cos*} |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
737 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
738 |
lemma lemma_sin_minus: |
15546 | 739 |
"- sin x = (\<Sum>n. - ((if even n then 0 |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
740 |
else (- 1) ^ ((n - Suc 0) div 2)/(real (fact n))) * x ^ n))" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
741 |
by (auto intro!: sums_unique sums_minus sin_converges) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
742 |
|
15546 | 743 |
lemma lemma_exp_ext: "exp = (%x. \<Sum>n. inverse (real (fact n)) * x ^ n)" |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
744 |
by (auto intro!: ext simp add: exp_def) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
745 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
746 |
lemma DERIV_exp [simp]: "DERIV exp x :> exp(x)" |
15229 | 747 |
apply (simp add: exp_def) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
748 |
apply (subst lemma_exp_ext) |
15546 | 749 |
apply (subgoal_tac "DERIV (%u. \<Sum>n. inverse (real (fact n)) * u ^ n) x :> (\<Sum>n. diffs (%n. inverse (real (fact n))) n * x ^ n)") |
15229 | 750 |
apply (rule_tac [2] K = "1 + \<bar>x\<bar>" in termdiffs) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
751 |
apply (auto intro: exp_converges [THEN sums_summable] simp add: exp_fdiffs, arith) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
752 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
753 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
754 |
lemma lemma_sin_ext: |
15546 | 755 |
"sin = (%x. \<Sum>n. |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
756 |
(if even n then 0 |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
757 |
else (- 1) ^ ((n - Suc 0) div 2)/(real (fact n))) * |
15546 | 758 |
x ^ n)" |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
759 |
by (auto intro!: ext simp add: sin_def) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
760 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
761 |
lemma lemma_cos_ext: |
15546 | 762 |
"cos = (%x. \<Sum>n. |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
763 |
(if even n then (- 1) ^ (n div 2)/(real (fact n)) else 0) * |
15546 | 764 |
x ^ n)" |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
765 |
by (auto intro!: ext simp add: cos_def) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
766 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
767 |
lemma DERIV_sin [simp]: "DERIV sin x :> cos(x)" |
15229 | 768 |
apply (simp add: cos_def) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
769 |
apply (subst lemma_sin_ext) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
770 |
apply (auto simp add: sin_fdiffs2 [symmetric]) |
15229 | 771 |
apply (rule_tac K = "1 + \<bar>x\<bar>" in termdiffs) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
772 |
apply (auto intro: sin_converges cos_converges sums_summable intro!: sums_minus [THEN sums_summable] simp add: cos_fdiffs sin_fdiffs, arith) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
773 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
774 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
775 |
lemma DERIV_cos [simp]: "DERIV cos x :> -sin(x)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
776 |
apply (subst lemma_cos_ext) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
777 |
apply (auto simp add: lemma_sin_minus cos_fdiffs2 [symmetric] minus_mult_left) |
15229 | 778 |
apply (rule_tac K = "1 + \<bar>x\<bar>" in termdiffs) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
779 |
apply (auto intro: sin_converges cos_converges sums_summable intro!: sums_minus [THEN sums_summable] simp add: cos_fdiffs sin_fdiffs diffs_minus, arith) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
780 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
781 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
782 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
783 |
subsection{*Properties of the Exponential Function*} |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
784 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
785 |
lemma exp_zero [simp]: "exp 0 = 1" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
786 |
proof - |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
787 |
have "(\<Sum>n = 0..<1. inverse (real (fact n)) * 0 ^ n) = |
15546 | 788 |
(\<Sum>n. inverse (real (fact n)) * 0 ^ n)" |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
789 |
by (rule series_zero [rule_format, THEN sums_unique], |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
790 |
case_tac "m", auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
791 |
thus ?thesis by (simp add: exp_def) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
792 |
qed |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
793 |
|
17014
ad5ceb90877d
renamed exp_ge_add_one_self to exp_ge_add_one_self_aux
avigad
parents:
16924
diff
changeset
|
794 |
lemma exp_ge_add_one_self_aux: "0 \<le> x ==> (1 + x) \<le> exp(x)" |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
795 |
apply (drule real_le_imp_less_or_eq, auto) |
15229 | 796 |
apply (simp add: exp_def) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
797 |
apply (rule real_le_trans) |
15229 | 798 |
apply (rule_tac [2] n = 2 and f = "(%n. inverse (real (fact n)) * x ^ n)" in series_pos_le) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
799 |
apply (auto intro: summable_exp simp add: numeral_2_eq_2 zero_le_power zero_le_mult_iff) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
800 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
801 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
802 |
lemma exp_gt_one [simp]: "0 < x ==> 1 < exp x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
803 |
apply (rule order_less_le_trans) |
17014
ad5ceb90877d
renamed exp_ge_add_one_self to exp_ge_add_one_self_aux
avigad
parents:
16924
diff
changeset
|
804 |
apply (rule_tac [2] exp_ge_add_one_self_aux, auto) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
805 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
806 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
807 |
lemma DERIV_exp_add_const: "DERIV (%x. exp (x + y)) x :> exp(x + y)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
808 |
proof - |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
809 |
have "DERIV (exp \<circ> (\<lambda>x. x + y)) x :> exp (x + y) * (1+0)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
810 |
by (fast intro: DERIV_chain DERIV_add DERIV_exp DERIV_Id DERIV_const) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
811 |
thus ?thesis by (simp add: o_def) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
812 |
qed |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
813 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
814 |
lemma DERIV_exp_minus [simp]: "DERIV (%x. exp (-x)) x :> - exp(-x)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
815 |
proof - |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
816 |
have "DERIV (exp \<circ> uminus) x :> exp (- x) * - 1" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
817 |
by (fast intro: DERIV_chain DERIV_minus DERIV_exp DERIV_Id) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
818 |
thus ?thesis by (simp add: o_def) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
819 |
qed |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
820 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
821 |
lemma DERIV_exp_exp_zero [simp]: "DERIV (%x. exp (x + y) * exp (- x)) x :> 0" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
822 |
proof - |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
823 |
have "DERIV (\<lambda>x. exp (x + y) * exp (- x)) x |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
824 |
:> exp (x + y) * exp (- x) + - exp (- x) * exp (x + y)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
825 |
by (fast intro: DERIV_exp_add_const DERIV_exp_minus DERIV_mult) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
826 |
thus ?thesis by simp |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
827 |
qed |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
828 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
829 |
lemma exp_add_mult_minus [simp]: "exp(x + y)*exp(-x) = exp(y)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
830 |
proof - |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
831 |
have "\<forall>x. DERIV (%x. exp (x + y) * exp (- x)) x :> 0" by simp |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
832 |
hence "exp (x + y) * exp (- x) = exp (0 + y) * exp (- 0)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
833 |
by (rule DERIV_isconst_all) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
834 |
thus ?thesis by simp |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
835 |
qed |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
836 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
837 |
lemma exp_mult_minus [simp]: "exp x * exp(-x) = 1" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
838 |
proof - |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
839 |
have "exp (x + 0) * exp (- x) = exp 0" by (rule exp_add_mult_minus) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
840 |
thus ?thesis by simp |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
841 |
qed |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
842 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
843 |
lemma exp_mult_minus2 [simp]: "exp(-x)*exp(x) = 1" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
844 |
by (simp add: mult_commute) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
845 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
846 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
847 |
lemma exp_minus: "exp(-x) = inverse(exp(x))" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
848 |
by (auto intro: inverse_unique [symmetric]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
849 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
850 |
lemma exp_add: "exp(x + y) = exp(x) * exp(y)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
851 |
proof - |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
852 |
have "exp x * exp y = exp x * (exp (x + y) * exp (- x))" by simp |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
853 |
thus ?thesis by (simp (no_asm_simp) add: mult_ac) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
854 |
qed |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
855 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
856 |
text{*Proof: because every exponential can be seen as a square.*} |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
857 |
lemma exp_ge_zero [simp]: "0 \<le> exp x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
858 |
apply (rule_tac t = x in real_sum_of_halves [THEN subst]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
859 |
apply (subst exp_add, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
860 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
861 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
862 |
lemma exp_not_eq_zero [simp]: "exp x \<noteq> 0" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
863 |
apply (cut_tac x = x in exp_mult_minus2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
864 |
apply (auto simp del: exp_mult_minus2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
865 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
866 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
867 |
lemma exp_gt_zero [simp]: "0 < exp x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
868 |
by (simp add: order_less_le) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
869 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
870 |
lemma inv_exp_gt_zero [simp]: "0 < inverse(exp x)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
871 |
by (auto intro: positive_imp_inverse_positive) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
872 |
|
15081 | 873 |
lemma abs_exp_cancel [simp]: "\<bar>exp x\<bar> = exp x" |
15229 | 874 |
by auto |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
875 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
876 |
lemma exp_real_of_nat_mult: "exp(real n * x) = exp(x) ^ n" |
15251 | 877 |
apply (induct "n") |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
878 |
apply (auto simp add: real_of_nat_Suc right_distrib exp_add mult_commute) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
879 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
880 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
881 |
lemma exp_diff: "exp(x - y) = exp(x)/(exp y)" |
15229 | 882 |
apply (simp add: diff_minus divide_inverse) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
883 |
apply (simp (no_asm) add: exp_add exp_minus) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
884 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
885 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
886 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
887 |
lemma exp_less_mono: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
888 |
assumes xy: "x < y" shows "exp x < exp y" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
889 |
proof - |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
890 |
have "1 < exp (y + - x)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
891 |
by (rule real_less_sum_gt_zero [THEN exp_gt_one]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
892 |
hence "exp x * inverse (exp x) < exp y * inverse (exp x)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
893 |
by (auto simp add: exp_add exp_minus) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
894 |
thus ?thesis |
15539 | 895 |
by (simp add: divide_inverse [symmetric] pos_less_divide_eq |
15228 | 896 |
del: divide_self_if) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
897 |
qed |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
898 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
899 |
lemma exp_less_cancel: "exp x < exp y ==> x < y" |
15228 | 900 |
apply (simp add: linorder_not_le [symmetric]) |
901 |
apply (auto simp add: order_le_less exp_less_mono) |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
902 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
903 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
904 |
lemma exp_less_cancel_iff [iff]: "(exp(x) < exp(y)) = (x < y)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
905 |
by (auto intro: exp_less_mono exp_less_cancel) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
906 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
907 |
lemma exp_le_cancel_iff [iff]: "(exp(x) \<le> exp(y)) = (x \<le> y)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
908 |
by (auto simp add: linorder_not_less [symmetric]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
909 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
910 |
lemma exp_inj_iff [iff]: "(exp x = exp y) = (x = y)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
911 |
by (simp add: order_eq_iff) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
912 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
913 |
lemma lemma_exp_total: "1 \<le> y ==> \<exists>x. 0 \<le> x & x \<le> y - 1 & exp(x) = y" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
914 |
apply (rule IVT) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
915 |
apply (auto intro: DERIV_exp [THEN DERIV_isCont] simp add: le_diff_eq) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
916 |
apply (subgoal_tac "1 + (y - 1) \<le> exp (y - 1)") |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
917 |
apply simp |
17014
ad5ceb90877d
renamed exp_ge_add_one_self to exp_ge_add_one_self_aux
avigad
parents:
16924
diff
changeset
|
918 |
apply (rule exp_ge_add_one_self_aux, simp) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
919 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
920 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
921 |
lemma exp_total: "0 < y ==> \<exists>x. exp x = y" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
922 |
apply (rule_tac x = 1 and y = y in linorder_cases) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
923 |
apply (drule order_less_imp_le [THEN lemma_exp_total]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
924 |
apply (rule_tac [2] x = 0 in exI) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
925 |
apply (frule_tac [3] real_inverse_gt_one) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
926 |
apply (drule_tac [4] order_less_imp_le [THEN lemma_exp_total], auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
927 |
apply (rule_tac x = "-x" in exI) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
928 |
apply (simp add: exp_minus) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
929 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
930 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
931 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
932 |
subsection{*Properties of the Logarithmic Function*} |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
933 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
934 |
lemma ln_exp[simp]: "ln(exp x) = x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
935 |
by (simp add: ln_def) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
936 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
937 |
lemma exp_ln_iff[simp]: "(exp(ln x) = x) = (0 < x)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
938 |
apply (auto dest: exp_total) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
939 |
apply (erule subst, simp) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
940 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
941 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
942 |
lemma ln_mult: "[| 0 < x; 0 < y |] ==> ln(x * y) = ln(x) + ln(y)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
943 |
apply (rule exp_inj_iff [THEN iffD1]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
944 |
apply (frule real_mult_order) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
945 |
apply (auto simp add: exp_add exp_ln_iff [symmetric] simp del: exp_inj_iff exp_ln_iff) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
946 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
947 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
948 |
lemma ln_inj_iff[simp]: "[| 0 < x; 0 < y |] ==> (ln x = ln y) = (x = y)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
949 |
apply (simp only: exp_ln_iff [symmetric]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
950 |
apply (erule subst)+ |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
951 |
apply simp |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
952 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
953 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
954 |
lemma ln_one[simp]: "ln 1 = 0" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
955 |
by (rule exp_inj_iff [THEN iffD1], auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
956 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
957 |
lemma ln_inverse: "0 < x ==> ln(inverse x) = - ln x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
958 |
apply (rule_tac a1 = "ln x" in add_left_cancel [THEN iffD1]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
959 |
apply (auto simp add: positive_imp_inverse_positive ln_mult [symmetric]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
960 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
961 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
962 |
lemma ln_div: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
963 |
"[|0 < x; 0 < y|] ==> ln(x/y) = ln x - ln y" |
15229 | 964 |
apply (simp add: divide_inverse) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
965 |
apply (auto simp add: positive_imp_inverse_positive ln_mult ln_inverse) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
966 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
967 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
968 |
lemma ln_less_cancel_iff[simp]: "[| 0 < x; 0 < y|] ==> (ln x < ln y) = (x < y)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
969 |
apply (simp only: exp_ln_iff [symmetric]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
970 |
apply (erule subst)+ |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
971 |
apply simp |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
972 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
973 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
974 |
lemma ln_le_cancel_iff[simp]: "[| 0 < x; 0 < y|] ==> (ln x \<le> ln y) = (x \<le> y)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
975 |
by (auto simp add: linorder_not_less [symmetric]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
976 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
977 |
lemma ln_realpow: "0 < x ==> ln(x ^ n) = real n * ln(x)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
978 |
by (auto dest!: exp_total simp add: exp_real_of_nat_mult [symmetric]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
979 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
980 |
lemma ln_add_one_self_le_self [simp]: "0 \<le> x ==> ln(1 + x) \<le> x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
981 |
apply (rule ln_exp [THEN subst]) |
17014
ad5ceb90877d
renamed exp_ge_add_one_self to exp_ge_add_one_self_aux
avigad
parents:
16924
diff
changeset
|
982 |
apply (rule ln_le_cancel_iff [THEN iffD2]) |
ad5ceb90877d
renamed exp_ge_add_one_self to exp_ge_add_one_self_aux
avigad
parents:
16924
diff
changeset
|
983 |
apply (auto simp add: exp_ge_add_one_self_aux) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
984 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
985 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
986 |
lemma ln_less_self [simp]: "0 < x ==> ln x < x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
987 |
apply (rule order_less_le_trans) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
988 |
apply (rule_tac [2] ln_add_one_self_le_self) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
989 |
apply (rule ln_less_cancel_iff [THEN iffD2], auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
990 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
991 |
|
15234
ec91a90c604e
simplification tweaks for better arithmetic reasoning
paulson
parents:
15229
diff
changeset
|
992 |
lemma ln_ge_zero [simp]: |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
993 |
assumes x: "1 \<le> x" shows "0 \<le> ln x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
994 |
proof - |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
995 |
have "0 < x" using x by arith |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
996 |
hence "exp 0 \<le> exp (ln x)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
997 |
by (simp add: x exp_ln_iff [symmetric] del: exp_ln_iff) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
998 |
thus ?thesis by (simp only: exp_le_cancel_iff) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
999 |
qed |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1000 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1001 |
lemma ln_ge_zero_imp_ge_one: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1002 |
assumes ln: "0 \<le> ln x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1003 |
and x: "0 < x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1004 |
shows "1 \<le> x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1005 |
proof - |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1006 |
from ln have "ln 1 \<le> ln x" by simp |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1007 |
thus ?thesis by (simp add: x del: ln_one) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1008 |
qed |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1009 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1010 |
lemma ln_ge_zero_iff [simp]: "0 < x ==> (0 \<le> ln x) = (1 \<le> x)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1011 |
by (blast intro: ln_ge_zero ln_ge_zero_imp_ge_one) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1012 |
|
15234
ec91a90c604e
simplification tweaks for better arithmetic reasoning
paulson
parents:
15229
diff
changeset
|
1013 |
lemma ln_less_zero_iff [simp]: "0 < x ==> (ln x < 0) = (x < 1)" |
ec91a90c604e
simplification tweaks for better arithmetic reasoning
paulson
parents:
15229
diff
changeset
|
1014 |
by (insert ln_ge_zero_iff [of x], arith) |
ec91a90c604e
simplification tweaks for better arithmetic reasoning
paulson
parents:
15229
diff
changeset
|
1015 |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1016 |
lemma ln_gt_zero: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1017 |
assumes x: "1 < x" shows "0 < ln x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1018 |
proof - |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1019 |
have "0 < x" using x by arith |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1020 |
hence "exp 0 < exp (ln x)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1021 |
by (simp add: x exp_ln_iff [symmetric] del: exp_ln_iff) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1022 |
thus ?thesis by (simp only: exp_less_cancel_iff) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1023 |
qed |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1024 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1025 |
lemma ln_gt_zero_imp_gt_one: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1026 |
assumes ln: "0 < ln x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1027 |
and x: "0 < x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1028 |
shows "1 < x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1029 |
proof - |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1030 |
from ln have "ln 1 < ln x" by simp |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1031 |
thus ?thesis by (simp add: x del: ln_one) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1032 |
qed |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1033 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1034 |
lemma ln_gt_zero_iff [simp]: "0 < x ==> (0 < ln x) = (1 < x)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1035 |
by (blast intro: ln_gt_zero ln_gt_zero_imp_gt_one) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1036 |
|
15234
ec91a90c604e
simplification tweaks for better arithmetic reasoning
paulson
parents:
15229
diff
changeset
|
1037 |
lemma ln_eq_zero_iff [simp]: "0 < x ==> (ln x = 0) = (x = 1)" |
ec91a90c604e
simplification tweaks for better arithmetic reasoning
paulson
parents:
15229
diff
changeset
|
1038 |
by (insert ln_less_zero_iff [of x] ln_gt_zero_iff [of x], arith) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1039 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1040 |
lemma ln_less_zero: "[| 0 < x; x < 1 |] ==> ln x < 0" |
15234
ec91a90c604e
simplification tweaks for better arithmetic reasoning
paulson
parents:
15229
diff
changeset
|
1041 |
by simp |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1042 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1043 |
lemma exp_ln_eq: "exp u = x ==> ln x = u" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1044 |
by auto |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1045 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1046 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1047 |
subsection{*Basic Properties of the Trigonometric Functions*} |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1048 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1049 |
lemma sin_zero [simp]: "sin 0 = 0" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1050 |
by (auto intro!: sums_unique [symmetric] LIMSEQ_const |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1051 |
simp add: sin_def sums_def simp del: power_0_left) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1052 |
|
15539 | 1053 |
lemma lemma_series_zero2: |
1054 |
"(\<forall>m. n \<le> m --> f m = 0) --> f sums setsum f {0..<n}" |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1055 |
by (auto intro: series_zero) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1056 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1057 |
lemma cos_zero [simp]: "cos 0 = 1" |
15229 | 1058 |
apply (simp add: cos_def) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1059 |
apply (rule sums_unique [symmetric]) |
15229 | 1060 |
apply (cut_tac n = 1 and f = "(%n. (if even n then (- 1) ^ (n div 2) / (real (fact n)) else 0) * 0 ^ n)" in lemma_series_zero2) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1061 |
apply auto |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1062 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1063 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1064 |
lemma DERIV_sin_sin_mult [simp]: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1065 |
"DERIV (%x. sin(x)*sin(x)) x :> cos(x) * sin(x) + cos(x) * sin(x)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1066 |
by (rule DERIV_mult, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1067 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1068 |
lemma DERIV_sin_sin_mult2 [simp]: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1069 |
"DERIV (%x. sin(x)*sin(x)) x :> 2 * cos(x) * sin(x)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1070 |
apply (cut_tac x = x in DERIV_sin_sin_mult) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1071 |
apply (auto simp add: mult_assoc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1072 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1073 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1074 |
lemma DERIV_sin_realpow2 [simp]: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1075 |
"DERIV (%x. (sin x)\<twosuperior>) x :> cos(x) * sin(x) + cos(x) * sin(x)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1076 |
by (auto simp add: numeral_2_eq_2 real_mult_assoc [symmetric]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1077 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1078 |
lemma DERIV_sin_realpow2a [simp]: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1079 |
"DERIV (%x. (sin x)\<twosuperior>) x :> 2 * cos(x) * sin(x)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1080 |
by (auto simp add: numeral_2_eq_2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1081 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1082 |
lemma DERIV_cos_cos_mult [simp]: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1083 |
"DERIV (%x. cos(x)*cos(x)) x :> -sin(x) * cos(x) + -sin(x) * cos(x)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1084 |
by (rule DERIV_mult, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1085 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1086 |
lemma DERIV_cos_cos_mult2 [simp]: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1087 |
"DERIV (%x. cos(x)*cos(x)) x :> -2 * cos(x) * sin(x)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1088 |
apply (cut_tac x = x in DERIV_cos_cos_mult) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1089 |
apply (auto simp add: mult_ac) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1090 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1091 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1092 |
lemma DERIV_cos_realpow2 [simp]: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1093 |
"DERIV (%x. (cos x)\<twosuperior>) x :> -sin(x) * cos(x) + -sin(x) * cos(x)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1094 |
by (auto simp add: numeral_2_eq_2 real_mult_assoc [symmetric]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1095 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1096 |
lemma DERIV_cos_realpow2a [simp]: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1097 |
"DERIV (%x. (cos x)\<twosuperior>) x :> -2 * cos(x) * sin(x)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1098 |
by (auto simp add: numeral_2_eq_2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1099 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1100 |
lemma lemma_DERIV_subst: "[| DERIV f x :> D; D = E |] ==> DERIV f x :> E" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1101 |
by auto |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1102 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1103 |
lemma DERIV_cos_realpow2b: "DERIV (%x. (cos x)\<twosuperior>) x :> -(2 * cos(x) * sin(x))" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1104 |
apply (rule lemma_DERIV_subst) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1105 |
apply (rule DERIV_cos_realpow2a, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1106 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1107 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1108 |
(* most useful *) |
15229 | 1109 |
lemma DERIV_cos_cos_mult3 [simp]: |
1110 |
"DERIV (%x. cos(x)*cos(x)) x :> -(2 * cos(x) * sin(x))" |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1111 |
apply (rule lemma_DERIV_subst) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1112 |
apply (rule DERIV_cos_cos_mult2, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1113 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1114 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1115 |
lemma DERIV_sin_circle_all: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1116 |
"\<forall>x. DERIV (%x. (sin x)\<twosuperior> + (cos x)\<twosuperior>) x :> |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1117 |
(2*cos(x)*sin(x) - 2*cos(x)*sin(x))" |
15229 | 1118 |
apply (simp only: diff_minus, safe) |
1119 |
apply (rule DERIV_add) |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1120 |
apply (auto simp add: numeral_2_eq_2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1121 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1122 |
|
15229 | 1123 |
lemma DERIV_sin_circle_all_zero [simp]: |
1124 |
"\<forall>x. DERIV (%x. (sin x)\<twosuperior> + (cos x)\<twosuperior>) x :> 0" |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1125 |
by (cut_tac DERIV_sin_circle_all, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1126 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1127 |
lemma sin_cos_squared_add [simp]: "((sin x)\<twosuperior>) + ((cos x)\<twosuperior>) = 1" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1128 |
apply (cut_tac x = x and y = 0 in DERIV_sin_circle_all_zero [THEN DERIV_isconst_all]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1129 |
apply (auto simp add: numeral_2_eq_2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1130 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1131 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1132 |
lemma sin_cos_squared_add2 [simp]: "((cos x)\<twosuperior>) + ((sin x)\<twosuperior>) = 1" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1133 |
apply (subst real_add_commute) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1134 |
apply (simp (no_asm) del: realpow_Suc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1135 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1136 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1137 |
lemma sin_cos_squared_add3 [simp]: "cos x * cos x + sin x * sin x = 1" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1138 |
apply (cut_tac x = x in sin_cos_squared_add2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1139 |
apply (auto simp add: numeral_2_eq_2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1140 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1141 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1142 |
lemma sin_squared_eq: "(sin x)\<twosuperior> = 1 - (cos x)\<twosuperior>" |
15229 | 1143 |
apply (rule_tac a1 = "(cos x)\<twosuperior>" in add_right_cancel [THEN iffD1]) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1144 |
apply (simp del: realpow_Suc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1145 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1146 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1147 |
lemma cos_squared_eq: "(cos x)\<twosuperior> = 1 - (sin x)\<twosuperior>" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1148 |
apply (rule_tac a1 = "(sin x)\<twosuperior>" in add_right_cancel [THEN iffD1]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1149 |
apply (simp del: realpow_Suc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1150 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1151 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1152 |
lemma real_gt_one_ge_zero_add_less: "[| 1 < x; 0 \<le> y |] ==> 1 < x + (y::real)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1153 |
by arith |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1154 |
|
15081 | 1155 |
lemma abs_sin_le_one [simp]: "\<bar>sin x\<bar> \<le> 1" |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1156 |
apply (auto simp add: linorder_not_less [symmetric]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1157 |
apply (drule_tac n = "Suc 0" in power_gt1) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1158 |
apply (auto simp del: realpow_Suc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1159 |
apply (drule_tac r1 = "cos x" in realpow_two_le [THEN [2] real_gt_one_ge_zero_add_less]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1160 |
apply (simp add: numeral_2_eq_2 [symmetric] del: realpow_Suc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1161 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1162 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1163 |
lemma sin_ge_minus_one [simp]: "-1 \<le> sin x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1164 |
apply (insert abs_sin_le_one [of x]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1165 |
apply (simp add: abs_le_interval_iff del: abs_sin_le_one) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1166 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1167 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1168 |
lemma sin_le_one [simp]: "sin x \<le> 1" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1169 |
apply (insert abs_sin_le_one [of x]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1170 |
apply (simp add: abs_le_interval_iff del: abs_sin_le_one) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1171 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1172 |
|
15081 | 1173 |
lemma abs_cos_le_one [simp]: "\<bar>cos x\<bar> \<le> 1" |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1174 |
apply (auto simp add: linorder_not_less [symmetric]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1175 |
apply (drule_tac n = "Suc 0" in power_gt1) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1176 |
apply (auto simp del: realpow_Suc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1177 |
apply (drule_tac r1 = "sin x" in realpow_two_le [THEN [2] real_gt_one_ge_zero_add_less]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1178 |
apply (simp add: numeral_2_eq_2 [symmetric] del: realpow_Suc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1179 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1180 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1181 |
lemma cos_ge_minus_one [simp]: "-1 \<le> cos x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1182 |
apply (insert abs_cos_le_one [of x]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1183 |
apply (simp add: abs_le_interval_iff del: abs_cos_le_one) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1184 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1185 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1186 |
lemma cos_le_one [simp]: "cos x \<le> 1" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1187 |
apply (insert abs_cos_le_one [of x]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1188 |
apply (simp add: abs_le_interval_iff del: abs_cos_le_one) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1189 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1190 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1191 |
lemma DERIV_fun_pow: "DERIV g x :> m ==> |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1192 |
DERIV (%x. (g x) ^ n) x :> real n * (g x) ^ (n - 1) * m" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1193 |
apply (rule lemma_DERIV_subst) |
15229 | 1194 |
apply (rule_tac f = "(%x. x ^ n)" in DERIV_chain2) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1195 |
apply (rule DERIV_pow, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1196 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1197 |
|
15229 | 1198 |
lemma DERIV_fun_exp: |
1199 |
"DERIV g x :> m ==> DERIV (%x. exp(g x)) x :> exp(g x) * m" |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1200 |
apply (rule lemma_DERIV_subst) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1201 |
apply (rule_tac f = exp in DERIV_chain2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1202 |
apply (rule DERIV_exp, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1203 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1204 |
|
15229 | 1205 |
lemma DERIV_fun_sin: |
1206 |
"DERIV g x :> m ==> DERIV (%x. sin(g x)) x :> cos(g x) * m" |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1207 |
apply (rule lemma_DERIV_subst) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1208 |
apply (rule_tac f = sin in DERIV_chain2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1209 |
apply (rule DERIV_sin, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1210 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1211 |
|
15229 | 1212 |
lemma DERIV_fun_cos: |
1213 |
"DERIV g x :> m ==> DERIV (%x. cos(g x)) x :> -sin(g x) * m" |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1214 |
apply (rule lemma_DERIV_subst) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1215 |
apply (rule_tac f = cos in DERIV_chain2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1216 |
apply (rule DERIV_cos, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1217 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1218 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1219 |
lemmas DERIV_intros = DERIV_Id DERIV_const DERIV_cos DERIV_cmult |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1220 |
DERIV_sin DERIV_exp DERIV_inverse DERIV_pow |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1221 |
DERIV_add DERIV_diff DERIV_mult DERIV_minus |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1222 |
DERIV_inverse_fun DERIV_quotient DERIV_fun_pow |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1223 |
DERIV_fun_exp DERIV_fun_sin DERIV_fun_cos |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1224 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1225 |
(* lemma *) |
15229 | 1226 |
lemma lemma_DERIV_sin_cos_add: |
1227 |
"\<forall>x. |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1228 |
DERIV (%x. (sin (x + y) - (sin x * cos y + cos x * sin y)) ^ 2 + |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1229 |
(cos (x + y) - (cos x * cos y - sin x * sin y)) ^ 2) x :> 0" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1230 |
apply (safe, rule lemma_DERIV_subst) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1231 |
apply (best intro!: DERIV_intros intro: DERIV_chain2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1232 |
--{*replaces the old @{text DERIV_tac}*} |
15229 | 1233 |
apply (auto simp add: diff_minus left_distrib right_distrib mult_ac add_ac) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1234 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1235 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1236 |
lemma sin_cos_add [simp]: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1237 |
"(sin (x + y) - (sin x * cos y + cos x * sin y)) ^ 2 + |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1238 |
(cos (x + y) - (cos x * cos y - sin x * sin y)) ^ 2 = 0" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1239 |
apply (cut_tac y = 0 and x = x and y7 = y |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1240 |
in lemma_DERIV_sin_cos_add [THEN DERIV_isconst_all]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1241 |
apply (auto simp add: numeral_2_eq_2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1242 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1243 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1244 |
lemma sin_add: "sin (x + y) = sin x * cos y + cos x * sin y" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1245 |
apply (cut_tac x = x and y = y in sin_cos_add) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1246 |
apply (auto dest!: real_sum_squares_cancel_a |
15085
5693a977a767
removed some [iff] declarations from RealDef.thy, concerning inequalities
paulson
parents:
15081
diff
changeset
|
1247 |
simp add: numeral_2_eq_2 real_add_eq_0_iff simp del: sin_cos_add) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1248 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1249 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1250 |
lemma cos_add: "cos (x + y) = cos x * cos y - sin x * sin y" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1251 |
apply (cut_tac x = x and y = y in sin_cos_add) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1252 |
apply (auto dest!: real_sum_squares_cancel_a |
15085
5693a977a767
removed some [iff] declarations from RealDef.thy, concerning inequalities
paulson
parents:
15081
diff
changeset
|
1253 |
simp add: numeral_2_eq_2 real_add_eq_0_iff simp del: sin_cos_add) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1254 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1255 |
|
15085
5693a977a767
removed some [iff] declarations from RealDef.thy, concerning inequalities
paulson
parents:
15081
diff
changeset
|
1256 |
lemma lemma_DERIV_sin_cos_minus: |
5693a977a767
removed some [iff] declarations from RealDef.thy, concerning inequalities
paulson
parents:
15081
diff
changeset
|
1257 |
"\<forall>x. DERIV (%x. (sin(-x) + (sin x)) ^ 2 + (cos(-x) - (cos x)) ^ 2) x :> 0" |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1258 |
apply (safe, rule lemma_DERIV_subst) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1259 |
apply (best intro!: DERIV_intros intro: DERIV_chain2) |
15229 | 1260 |
apply (auto simp add: diff_minus left_distrib right_distrib mult_ac add_ac) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1261 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1262 |
|
15085
5693a977a767
removed some [iff] declarations from RealDef.thy, concerning inequalities
paulson
parents:
15081
diff
changeset
|
1263 |
lemma sin_cos_minus [simp]: |
5693a977a767
removed some [iff] declarations from RealDef.thy, concerning inequalities
paulson
parents:
15081
diff
changeset
|
1264 |
"(sin(-x) + (sin x)) ^ 2 + (cos(-x) - (cos x)) ^ 2 = 0" |
5693a977a767
removed some [iff] declarations from RealDef.thy, concerning inequalities
paulson
parents:
15081
diff
changeset
|
1265 |
apply (cut_tac y = 0 and x = x |
5693a977a767
removed some [iff] declarations from RealDef.thy, concerning inequalities
paulson
parents:
15081
diff
changeset
|
1266 |
in lemma_DERIV_sin_cos_minus [THEN DERIV_isconst_all]) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1267 |
apply (auto simp add: numeral_2_eq_2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1268 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1269 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1270 |
lemma sin_minus [simp]: "sin (-x) = -sin(x)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1271 |
apply (cut_tac x = x in sin_cos_minus) |
15085
5693a977a767
removed some [iff] declarations from RealDef.thy, concerning inequalities
paulson
parents:
15081
diff
changeset
|
1272 |
apply (auto dest!: real_sum_squares_cancel_a |
5693a977a767
removed some [iff] declarations from RealDef.thy, concerning inequalities
paulson
parents:
15081
diff
changeset
|
1273 |
simp add: numeral_2_eq_2 real_add_eq_0_iff simp del: sin_cos_minus) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1274 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1275 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1276 |
lemma cos_minus [simp]: "cos (-x) = cos(x)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1277 |
apply (cut_tac x = x in sin_cos_minus) |
15085
5693a977a767
removed some [iff] declarations from RealDef.thy, concerning inequalities
paulson
parents:
15081
diff
changeset
|
1278 |
apply (auto dest!: real_sum_squares_cancel_a |
5693a977a767
removed some [iff] declarations from RealDef.thy, concerning inequalities
paulson
parents:
15081
diff
changeset
|
1279 |
simp add: numeral_2_eq_2 simp del: sin_cos_minus) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1280 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1281 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1282 |
lemma sin_diff: "sin (x - y) = sin x * cos y - cos x * sin y" |
15229 | 1283 |
apply (simp add: diff_minus) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1284 |
apply (simp (no_asm) add: sin_add) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1285 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1286 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1287 |
lemma sin_diff2: "sin (x - y) = cos y * sin x - sin y * cos x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1288 |
by (simp add: sin_diff mult_commute) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1289 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1290 |
lemma cos_diff: "cos (x - y) = cos x * cos y + sin x * sin y" |
15229 | 1291 |
apply (simp add: diff_minus) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1292 |
apply (simp (no_asm) add: cos_add) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1293 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1294 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1295 |
lemma cos_diff2: "cos (x - y) = cos y * cos x + sin y * sin x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1296 |
by (simp add: cos_diff mult_commute) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1297 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1298 |
lemma sin_double [simp]: "sin(2 * x) = 2* sin x * cos x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1299 |
by (cut_tac x = x and y = x in sin_add, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1300 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1301 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1302 |
lemma cos_double: "cos(2* x) = ((cos x)\<twosuperior>) - ((sin x)\<twosuperior>)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1303 |
apply (cut_tac x = x and y = x in cos_add) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1304 |
apply (auto simp add: numeral_2_eq_2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1305 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1306 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1307 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1308 |
subsection{*The Constant Pi*} |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1309 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1310 |
text{*Show that there's a least positive @{term x} with @{term "cos(x) = 0"}; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1311 |
hence define pi.*} |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1312 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1313 |
lemma sin_paired: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1314 |
"(%n. (- 1) ^ n /(real (fact (2 * n + 1))) * x ^ (2 * n + 1)) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1315 |
sums sin x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1316 |
proof - |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1317 |
have "(\<lambda>n. \<Sum>k = n * 2..<n * 2 + 2. |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1318 |
(if even k then 0 |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1319 |
else (- 1) ^ ((k - Suc 0) div 2) / real (fact k)) * |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1320 |
x ^ k) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1321 |
sums |
15546 | 1322 |
(\<Sum>n. (if even n then 0 |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1323 |
else (- 1) ^ ((n - Suc 0) div 2) / real (fact n)) * |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1324 |
x ^ n)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1325 |
by (rule sin_converges [THEN sums_summable, THEN sums_group], simp) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1326 |
thus ?thesis by (simp add: mult_ac sin_def) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1327 |
qed |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1328 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1329 |
lemma sin_gt_zero: "[|0 < x; x < 2 |] ==> 0 < sin x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1330 |
apply (subgoal_tac |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1331 |
"(\<lambda>n. \<Sum>k = n * 2..<n * 2 + 2. |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1332 |
(- 1) ^ k / real (fact (2 * k + 1)) * x ^ (2 * k + 1)) |
15546 | 1333 |
sums (\<Sum>n. (- 1) ^ n / real (fact (2 * n + 1)) * x ^ (2 * n + 1))") |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1334 |
prefer 2 |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1335 |
apply (rule sin_paired [THEN sums_summable, THEN sums_group], simp) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1336 |
apply (rotate_tac 2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1337 |
apply (drule sin_paired [THEN sums_unique, THEN ssubst]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1338 |
apply (auto simp del: fact_Suc realpow_Suc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1339 |
apply (frule sums_unique) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1340 |
apply (auto simp del: fact_Suc realpow_Suc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1341 |
apply (rule_tac n1 = 0 in series_pos_less [THEN [2] order_le_less_trans]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1342 |
apply (auto simp del: fact_Suc realpow_Suc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1343 |
apply (erule sums_summable) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1344 |
apply (case_tac "m=0") |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1345 |
apply (simp (no_asm_simp)) |
15234
ec91a90c604e
simplification tweaks for better arithmetic reasoning
paulson
parents:
15229
diff
changeset
|
1346 |
apply (subgoal_tac "6 * (x * (x * x) / real (Suc (Suc (Suc (Suc (Suc (Suc 0))))))) < 6 * x") |
15539 | 1347 |
apply (simp only: mult_less_cancel_left, simp) |
1348 |
apply (simp (no_asm_simp) add: numeral_2_eq_2 [symmetric] mult_assoc [symmetric]) |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1349 |
apply (subgoal_tac "x*x < 2*3", simp) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1350 |
apply (rule mult_strict_mono) |
15085
5693a977a767
removed some [iff] declarations from RealDef.thy, concerning inequalities
paulson
parents:
15081
diff
changeset
|
1351 |
apply (auto simp add: real_0_less_add_iff real_of_nat_Suc simp del: fact_Suc) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1352 |
apply (subst fact_Suc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1353 |
apply (subst fact_Suc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1354 |
apply (subst fact_Suc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1355 |
apply (subst fact_Suc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1356 |
apply (subst real_of_nat_mult) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1357 |
apply (subst real_of_nat_mult) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1358 |
apply (subst real_of_nat_mult) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1359 |
apply (subst real_of_nat_mult) |
15539 | 1360 |
apply (simp (no_asm) add: divide_inverse del: fact_Suc) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1361 |
apply (auto simp add: mult_assoc [symmetric] simp del: fact_Suc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1362 |
apply (rule_tac c="real (Suc (Suc (4*m)))" in mult_less_imp_less_right) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1363 |
apply (auto simp add: mult_assoc simp del: fact_Suc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1364 |
apply (rule_tac c="real (Suc (Suc (Suc (4*m))))" in mult_less_imp_less_right) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1365 |
apply (auto simp add: mult_assoc mult_less_cancel_left simp del: fact_Suc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1366 |
apply (subgoal_tac "x * (x * x ^ (4*m)) = (x ^ (4*m)) * (x * x)") |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1367 |
apply (erule ssubst)+ |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1368 |
apply (auto simp del: fact_Suc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1369 |
apply (subgoal_tac "0 < x ^ (4 * m) ") |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1370 |
prefer 2 apply (simp only: zero_less_power) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1371 |
apply (simp (no_asm_simp) add: mult_less_cancel_left) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1372 |
apply (rule mult_strict_mono) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1373 |
apply (simp_all (no_asm_simp)) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1374 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1375 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1376 |
lemma sin_gt_zero1: "[|0 < x; x < 2 |] ==> 0 < sin x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1377 |
by (auto intro: sin_gt_zero) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1378 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1379 |
lemma cos_double_less_one: "[| 0 < x; x < 2 |] ==> cos (2 * x) < 1" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1380 |
apply (cut_tac x = x in sin_gt_zero1) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1381 |
apply (auto simp add: cos_squared_eq cos_double) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1382 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1383 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1384 |
lemma cos_paired: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1385 |
"(%n. (- 1) ^ n /(real (fact (2 * n))) * x ^ (2 * n)) sums cos x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1386 |
proof - |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1387 |
have "(\<lambda>n. \<Sum>k = n * 2..<n * 2 + 2. |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1388 |
(if even k then (- 1) ^ (k div 2) / real (fact k) else 0) * |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1389 |
x ^ k) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1390 |
sums |
15546 | 1391 |
(\<Sum>n. (if even n then (- 1) ^ (n div 2) / real (fact n) else 0) * |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1392 |
x ^ n)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1393 |
by (rule cos_converges [THEN sums_summable, THEN sums_group], simp) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1394 |
thus ?thesis by (simp add: mult_ac cos_def) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1395 |
qed |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1396 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1397 |
declare zero_less_power [simp] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1398 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1399 |
lemma fact_lemma: "real (n::nat) * 4 = real (4 * n)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1400 |
by simp |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1401 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1402 |
lemma cos_two_less_zero: "cos (2) < 0" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1403 |
apply (cut_tac x = 2 in cos_paired) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1404 |
apply (drule sums_minus) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1405 |
apply (rule neg_less_iff_less [THEN iffD1]) |
15539 | 1406 |
apply (frule sums_unique, auto) |
1407 |
apply (rule_tac y = |
|
1408 |
"\<Sum>n=0..< Suc(Suc(Suc 0)). - ((- 1) ^ n / (real(fact (2*n))) * 2 ^ (2*n))" |
|
15481 | 1409 |
in order_less_trans) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1410 |
apply (simp (no_asm) add: fact_num_eq_if realpow_num_eq_if del: fact_Suc realpow_Suc) |
15561 | 1411 |
apply (simp (no_asm) add: mult_assoc del: setsum_op_ivl_Suc) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1412 |
apply (rule sumr_pos_lt_pair) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1413 |
apply (erule sums_summable, safe) |
15085
5693a977a767
removed some [iff] declarations from RealDef.thy, concerning inequalities
paulson
parents:
15081
diff
changeset
|
1414 |
apply (simp (no_asm) add: divide_inverse real_0_less_add_iff mult_assoc [symmetric] |
5693a977a767
removed some [iff] declarations from RealDef.thy, concerning inequalities
paulson
parents:
15081
diff
changeset
|
1415 |
del: fact_Suc) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1416 |
apply (rule real_mult_inverse_cancel2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1417 |
apply (rule real_of_nat_fact_gt_zero)+ |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1418 |
apply (simp (no_asm) add: mult_assoc [symmetric] del: fact_Suc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1419 |
apply (subst fact_lemma) |
15481 | 1420 |
apply (subst fact_Suc [of "Suc (Suc (Suc (Suc (Suc (Suc (Suc (4 * d)))))))"]) |
1421 |
apply (simp only: real_of_nat_mult) |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1422 |
apply (rule real_mult_less_mono, force) |
15481 | 1423 |
apply (rule_tac [3] real_of_nat_fact_gt_zero) |
1424 |
prefer 2 apply force |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1425 |
apply (rule real_of_nat_less_iff [THEN iffD2]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1426 |
apply (rule fact_less_mono, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1427 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1428 |
declare cos_two_less_zero [simp] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1429 |
declare cos_two_less_zero [THEN real_not_refl2, simp] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1430 |
declare cos_two_less_zero [THEN order_less_imp_le, simp] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1431 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1432 |
lemma cos_is_zero: "EX! x. 0 \<le> x & x \<le> 2 & cos x = 0" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1433 |
apply (subgoal_tac "\<exists>x. 0 \<le> x & x \<le> 2 & cos x = 0") |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1434 |
apply (rule_tac [2] IVT2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1435 |
apply (auto intro: DERIV_isCont DERIV_cos) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1436 |
apply (cut_tac x = xa and y = y in linorder_less_linear) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1437 |
apply (rule ccontr) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1438 |
apply (subgoal_tac " (\<forall>x. cos differentiable x) & (\<forall>x. isCont cos x) ") |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1439 |
apply (auto intro: DERIV_cos DERIV_isCont simp add: differentiable_def) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1440 |
apply (drule_tac f = cos in Rolle) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1441 |
apply (drule_tac [5] f = cos in Rolle) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1442 |
apply (auto dest!: DERIV_cos [THEN DERIV_unique] simp add: differentiable_def) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1443 |
apply (drule_tac y1 = xa in order_le_less_trans [THEN sin_gt_zero]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1444 |
apply (assumption, rule_tac y=y in order_less_le_trans, simp_all) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1445 |
apply (drule_tac y1 = y in order_le_less_trans [THEN sin_gt_zero], assumption, simp_all) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1446 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1447 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1448 |
lemma pi_half: "pi/2 = (@x. 0 \<le> x & x \<le> 2 & cos x = 0)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1449 |
by (simp add: pi_def) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1450 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1451 |
lemma cos_pi_half [simp]: "cos (pi / 2) = 0" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1452 |
apply (rule cos_is_zero [THEN ex1E]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1453 |
apply (auto intro!: someI2 simp add: pi_half) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1454 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1455 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1456 |
lemma pi_half_gt_zero: "0 < pi / 2" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1457 |
apply (rule cos_is_zero [THEN ex1E]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1458 |
apply (auto simp add: pi_half) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1459 |
apply (rule someI2, blast, safe) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1460 |
apply (drule_tac y = xa in real_le_imp_less_or_eq) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1461 |
apply (safe, simp) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1462 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1463 |
declare pi_half_gt_zero [simp] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1464 |
declare pi_half_gt_zero [THEN real_not_refl2, THEN not_sym, simp] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1465 |
declare pi_half_gt_zero [THEN order_less_imp_le, simp] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1466 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1467 |
lemma pi_half_less_two: "pi / 2 < 2" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1468 |
apply (rule cos_is_zero [THEN ex1E]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1469 |
apply (auto simp add: pi_half) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1470 |
apply (rule someI2, blast, safe) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1471 |
apply (drule_tac x = xa in order_le_imp_less_or_eq) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1472 |
apply (safe, simp) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1473 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1474 |
declare pi_half_less_two [simp] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1475 |
declare pi_half_less_two [THEN real_not_refl2, simp] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1476 |
declare pi_half_less_two [THEN order_less_imp_le, simp] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1477 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1478 |
lemma pi_gt_zero [simp]: "0 < pi" |
15229 | 1479 |
apply (insert pi_half_gt_zero) |
1480 |
apply (simp add: ); |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1481 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1482 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1483 |
lemma pi_neq_zero [simp]: "pi \<noteq> 0" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1484 |
by (rule pi_gt_zero [THEN real_not_refl2, THEN not_sym]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1485 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1486 |
lemma pi_not_less_zero [simp]: "~ (pi < 0)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1487 |
apply (insert pi_gt_zero) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1488 |
apply (blast elim: order_less_asym) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1489 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1490 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1491 |
lemma pi_ge_zero [simp]: "0 \<le> pi" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1492 |
by (auto intro: order_less_imp_le) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1493 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1494 |
lemma minus_pi_half_less_zero [simp]: "-(pi/2) < 0" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1495 |
by auto |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1496 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1497 |
lemma sin_pi_half [simp]: "sin(pi/2) = 1" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1498 |
apply (cut_tac x = "pi/2" in sin_cos_squared_add2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1499 |
apply (cut_tac sin_gt_zero [OF pi_half_gt_zero pi_half_less_two]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1500 |
apply (auto simp add: numeral_2_eq_2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1501 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1502 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1503 |
lemma cos_pi [simp]: "cos pi = -1" |
15539 | 1504 |
by (cut_tac x = "pi/2" and y = "pi/2" in cos_add, simp) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1505 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1506 |
lemma sin_pi [simp]: "sin pi = 0" |
15539 | 1507 |
by (cut_tac x = "pi/2" and y = "pi/2" in sin_add, simp) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1508 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1509 |
lemma sin_cos_eq: "sin x = cos (pi/2 - x)" |
15229 | 1510 |
by (simp add: diff_minus cos_add) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1511 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1512 |
lemma minus_sin_cos_eq: "-sin x = cos (x + pi/2)" |
15229 | 1513 |
by (simp add: cos_add) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1514 |
declare minus_sin_cos_eq [symmetric, simp] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1515 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1516 |
lemma cos_sin_eq: "cos x = sin (pi/2 - x)" |
15229 | 1517 |
by (simp add: diff_minus sin_add) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1518 |
declare sin_cos_eq [symmetric, simp] cos_sin_eq [symmetric, simp] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1519 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1520 |
lemma sin_periodic_pi [simp]: "sin (x + pi) = - sin x" |
15229 | 1521 |
by (simp add: sin_add) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1522 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1523 |
lemma sin_periodic_pi2 [simp]: "sin (pi + x) = - sin x" |
15229 | 1524 |
by (simp add: sin_add) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1525 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1526 |
lemma cos_periodic_pi [simp]: "cos (x + pi) = - cos x" |
15229 | 1527 |
by (simp add: cos_add) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1528 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1529 |
lemma sin_periodic [simp]: "sin (x + 2*pi) = sin x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1530 |
by (simp add: sin_add cos_double) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1531 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1532 |
lemma cos_periodic [simp]: "cos (x + 2*pi) = cos x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1533 |
by (simp add: cos_add cos_double) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1534 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1535 |
lemma cos_npi [simp]: "cos (real n * pi) = -1 ^ n" |
15251 | 1536 |
apply (induct "n") |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1537 |
apply (auto simp add: real_of_nat_Suc left_distrib) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1538 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1539 |
|
15383 | 1540 |
lemma cos_npi2 [simp]: "cos (pi * real n) = -1 ^ n" |
1541 |
proof - |
|
1542 |
have "cos (pi * real n) = cos (real n * pi)" by (simp only: mult_commute) |
|
1543 |
also have "... = -1 ^ n" by (rule cos_npi) |
|
1544 |
finally show ?thesis . |
|
1545 |
qed |
|
1546 |
||
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1547 |
lemma sin_npi [simp]: "sin (real (n::nat) * pi) = 0" |
15251 | 1548 |
apply (induct "n") |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1549 |
apply (auto simp add: real_of_nat_Suc left_distrib) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1550 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1551 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1552 |
lemma sin_npi2 [simp]: "sin (pi * real (n::nat)) = 0" |
15383 | 1553 |
by (simp add: mult_commute [of pi]) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1554 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1555 |
lemma cos_two_pi [simp]: "cos (2 * pi) = 1" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1556 |
by (simp add: cos_double) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1557 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1558 |
lemma sin_two_pi [simp]: "sin (2 * pi) = 0" |
15229 | 1559 |
by simp |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1560 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1561 |
lemma sin_gt_zero2: "[| 0 < x; x < pi/2 |] ==> 0 < sin x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1562 |
apply (rule sin_gt_zero, assumption) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1563 |
apply (rule order_less_trans, assumption) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1564 |
apply (rule pi_half_less_two) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1565 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1566 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1567 |
lemma sin_less_zero: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1568 |
assumes lb: "- pi/2 < x" and "x < 0" shows "sin x < 0" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1569 |
proof - |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1570 |
have "0 < sin (- x)" using prems by (simp only: sin_gt_zero2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1571 |
thus ?thesis by simp |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1572 |
qed |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1573 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1574 |
lemma pi_less_4: "pi < 4" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1575 |
by (cut_tac pi_half_less_two, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1576 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1577 |
lemma cos_gt_zero: "[| 0 < x; x < pi/2 |] ==> 0 < cos x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1578 |
apply (cut_tac pi_less_4) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1579 |
apply (cut_tac f = cos and a = 0 and b = x and y = 0 in IVT2_objl, safe, simp_all) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1580 |
apply (force intro: DERIV_isCont DERIV_cos) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1581 |
apply (cut_tac cos_is_zero, safe) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1582 |
apply (rename_tac y z) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1583 |
apply (drule_tac x = y in spec) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1584 |
apply (drule_tac x = "pi/2" in spec, simp) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1585 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1586 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1587 |
lemma cos_gt_zero_pi: "[| -(pi/2) < x; x < pi/2 |] ==> 0 < cos x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1588 |
apply (rule_tac x = x and y = 0 in linorder_cases) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1589 |
apply (rule cos_minus [THEN subst]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1590 |
apply (rule cos_gt_zero) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1591 |
apply (auto intro: cos_gt_zero) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1592 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1593 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1594 |
lemma cos_ge_zero: "[| -(pi/2) \<le> x; x \<le> pi/2 |] ==> 0 \<le> cos x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1595 |
apply (auto simp add: order_le_less cos_gt_zero_pi) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1596 |
apply (subgoal_tac "x = pi/2", auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1597 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1598 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1599 |
lemma sin_gt_zero_pi: "[| 0 < x; x < pi |] ==> 0 < sin x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1600 |
apply (subst sin_cos_eq) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1601 |
apply (rotate_tac 1) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1602 |
apply (drule real_sum_of_halves [THEN ssubst]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1603 |
apply (auto intro!: cos_gt_zero_pi simp del: sin_cos_eq [symmetric]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1604 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1605 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1606 |
lemma sin_ge_zero: "[| 0 \<le> x; x \<le> pi |] ==> 0 \<le> sin x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1607 |
by (auto simp add: order_le_less sin_gt_zero_pi) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1608 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1609 |
lemma cos_total: "[| -1 \<le> y; y \<le> 1 |] ==> EX! x. 0 \<le> x & x \<le> pi & (cos x = y)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1610 |
apply (subgoal_tac "\<exists>x. 0 \<le> x & x \<le> pi & cos x = y") |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1611 |
apply (rule_tac [2] IVT2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1612 |
apply (auto intro: order_less_imp_le DERIV_isCont DERIV_cos) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1613 |
apply (cut_tac x = xa and y = y in linorder_less_linear) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1614 |
apply (rule ccontr, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1615 |
apply (drule_tac f = cos in Rolle) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1616 |
apply (drule_tac [5] f = cos in Rolle) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1617 |
apply (auto intro: order_less_imp_le DERIV_isCont DERIV_cos |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1618 |
dest!: DERIV_cos [THEN DERIV_unique] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1619 |
simp add: differentiable_def) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1620 |
apply (auto dest: sin_gt_zero_pi [OF order_le_less_trans order_less_le_trans]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1621 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1622 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1623 |
lemma sin_total: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1624 |
"[| -1 \<le> y; y \<le> 1 |] ==> EX! x. -(pi/2) \<le> x & x \<le> pi/2 & (sin x = y)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1625 |
apply (rule ccontr) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1626 |
apply (subgoal_tac "\<forall>x. (- (pi/2) \<le> x & x \<le> pi/2 & (sin x = y)) = (0 \<le> (x + pi/2) & (x + pi/2) \<le> pi & (cos (x + pi/2) = -y))") |
18585 | 1627 |
apply (erule contrapos_np) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1628 |
apply (simp del: minus_sin_cos_eq [symmetric]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1629 |
apply (cut_tac y="-y" in cos_total, simp) apply simp |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1630 |
apply (erule ex1E) |
15229 | 1631 |
apply (rule_tac a = "x - (pi/2)" in ex1I) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1632 |
apply (simp (no_asm) add: real_add_assoc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1633 |
apply (rotate_tac 3) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1634 |
apply (drule_tac x = "xa + pi/2" in spec, safe, simp_all) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1635 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1636 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1637 |
lemma reals_Archimedean4: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1638 |
"[| 0 < y; 0 \<le> x |] ==> \<exists>n. real n * y \<le> x & x < real (Suc n) * y" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1639 |
apply (auto dest!: reals_Archimedean3) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1640 |
apply (drule_tac x = x in spec, clarify) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1641 |
apply (subgoal_tac "x < real(LEAST m::nat. x < real m * y) * y") |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1642 |
prefer 2 apply (erule LeastI) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1643 |
apply (case_tac "LEAST m::nat. x < real m * y", simp) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1644 |
apply (subgoal_tac "~ x < real nat * y") |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1645 |
prefer 2 apply (rule not_less_Least, simp, force) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1646 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1647 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1648 |
(* Pre Isabelle99-2 proof was simpler- numerals arithmetic |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1649 |
now causes some unwanted re-arrangements of literals! *) |
15229 | 1650 |
lemma cos_zero_lemma: |
1651 |
"[| 0 \<le> x; cos x = 0 |] ==> |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1652 |
\<exists>n::nat. ~even n & x = real n * (pi/2)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1653 |
apply (drule pi_gt_zero [THEN reals_Archimedean4], safe) |
15086 | 1654 |
apply (subgoal_tac "0 \<le> x - real n * pi & |
1655 |
(x - real n * pi) \<le> pi & (cos (x - real n * pi) = 0) ") |
|
1656 |
apply (auto simp add: compare_rls) |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1657 |
prefer 3 apply (simp add: cos_diff) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1658 |
prefer 2 apply (simp add: real_of_nat_Suc left_distrib) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1659 |
apply (simp add: cos_diff) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1660 |
apply (subgoal_tac "EX! x. 0 \<le> x & x \<le> pi & cos x = 0") |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1661 |
apply (rule_tac [2] cos_total, safe) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1662 |
apply (drule_tac x = "x - real n * pi" in spec) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1663 |
apply (drule_tac x = "pi/2" in spec) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1664 |
apply (simp add: cos_diff) |
15229 | 1665 |
apply (rule_tac x = "Suc (2 * n)" in exI) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1666 |
apply (simp add: real_of_nat_Suc left_distrib, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1667 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1668 |
|
15229 | 1669 |
lemma sin_zero_lemma: |
1670 |
"[| 0 \<le> x; sin x = 0 |] ==> |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1671 |
\<exists>n::nat. even n & x = real n * (pi/2)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1672 |
apply (subgoal_tac "\<exists>n::nat. ~ even n & x + pi/2 = real n * (pi/2) ") |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1673 |
apply (clarify, rule_tac x = "n - 1" in exI) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1674 |
apply (force simp add: odd_Suc_mult_two_ex real_of_nat_Suc left_distrib) |
15085
5693a977a767
removed some [iff] declarations from RealDef.thy, concerning inequalities
paulson
parents:
15081
diff
changeset
|
1675 |
apply (rule cos_zero_lemma) |
5693a977a767
removed some [iff] declarations from RealDef.thy, concerning inequalities
paulson
parents:
15081
diff
changeset
|
1676 |
apply (simp_all add: add_increasing) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1677 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1678 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1679 |
|
15229 | 1680 |
lemma cos_zero_iff: |
1681 |
"(cos x = 0) = |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1682 |
((\<exists>n::nat. ~even n & (x = real n * (pi/2))) | |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1683 |
(\<exists>n::nat. ~even n & (x = -(real n * (pi/2)))))" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1684 |
apply (rule iffI) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1685 |
apply (cut_tac linorder_linear [of 0 x], safe) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1686 |
apply (drule cos_zero_lemma, assumption+) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1687 |
apply (cut_tac x="-x" in cos_zero_lemma, simp, simp) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1688 |
apply (force simp add: minus_equation_iff [of x]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1689 |
apply (auto simp only: odd_Suc_mult_two_ex real_of_nat_Suc left_distrib) |
15539 | 1690 |
apply (auto simp add: cos_add) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1691 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1692 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1693 |
(* ditto: but to a lesser extent *) |
15229 | 1694 |
lemma sin_zero_iff: |
1695 |
"(sin x = 0) = |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1696 |
((\<exists>n::nat. even n & (x = real n * (pi/2))) | |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1697 |
(\<exists>n::nat. even n & (x = -(real n * (pi/2)))))" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1698 |
apply (rule iffI) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1699 |
apply (cut_tac linorder_linear [of 0 x], safe) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1700 |
apply (drule sin_zero_lemma, assumption+) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1701 |
apply (cut_tac x="-x" in sin_zero_lemma, simp, simp, safe) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1702 |
apply (force simp add: minus_equation_iff [of x]) |
15539 | 1703 |
apply (auto simp add: even_mult_two_ex) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1704 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1705 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1706 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1707 |
subsection{*Tangent*} |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1708 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1709 |
lemma tan_zero [simp]: "tan 0 = 0" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1710 |
by (simp add: tan_def) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1711 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1712 |
lemma tan_pi [simp]: "tan pi = 0" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1713 |
by (simp add: tan_def) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1714 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1715 |
lemma tan_npi [simp]: "tan (real (n::nat) * pi) = 0" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1716 |
by (simp add: tan_def) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1717 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1718 |
lemma tan_minus [simp]: "tan (-x) = - tan x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1719 |
by (simp add: tan_def minus_mult_left) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1720 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1721 |
lemma tan_periodic [simp]: "tan (x + 2*pi) = tan x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1722 |
by (simp add: tan_def) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1723 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1724 |
lemma lemma_tan_add1: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1725 |
"[| cos x \<noteq> 0; cos y \<noteq> 0 |] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1726 |
==> 1 - tan(x)*tan(y) = cos (x + y)/(cos x * cos y)" |
15229 | 1727 |
apply (simp add: tan_def divide_inverse) |
1728 |
apply (auto simp del: inverse_mult_distrib |
|
1729 |
simp add: inverse_mult_distrib [symmetric] mult_ac) |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1730 |
apply (rule_tac c1 = "cos x * cos y" in real_mult_right_cancel [THEN subst]) |
15229 | 1731 |
apply (auto simp del: inverse_mult_distrib |
1732 |
simp add: mult_assoc left_diff_distrib cos_add) |
|
15234
ec91a90c604e
simplification tweaks for better arithmetic reasoning
paulson
parents:
15229
diff
changeset
|
1733 |
done |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1734 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1735 |
lemma add_tan_eq: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1736 |
"[| cos x \<noteq> 0; cos y \<noteq> 0 |] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1737 |
==> tan x + tan y = sin(x + y)/(cos x * cos y)" |
15229 | 1738 |
apply (simp add: tan_def) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1739 |
apply (rule_tac c1 = "cos x * cos y" in real_mult_right_cancel [THEN subst]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1740 |
apply (auto simp add: mult_assoc left_distrib) |
15539 | 1741 |
apply (simp add: sin_add) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1742 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1743 |
|
15229 | 1744 |
lemma tan_add: |
1745 |
"[| cos x \<noteq> 0; cos y \<noteq> 0; cos (x + y) \<noteq> 0 |] |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1746 |
==> tan(x + y) = (tan(x) + tan(y))/(1 - tan(x) * tan(y))" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1747 |
apply (simp (no_asm_simp) add: add_tan_eq lemma_tan_add1) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1748 |
apply (simp add: tan_def) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1749 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1750 |
|
15229 | 1751 |
lemma tan_double: |
1752 |
"[| cos x \<noteq> 0; cos (2 * x) \<noteq> 0 |] |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1753 |
==> tan (2 * x) = (2 * tan x)/(1 - (tan(x) ^ 2))" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1754 |
apply (insert tan_add [of x x]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1755 |
apply (simp add: mult_2 [symmetric]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1756 |
apply (auto simp add: numeral_2_eq_2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1757 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1758 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1759 |
lemma tan_gt_zero: "[| 0 < x; x < pi/2 |] ==> 0 < tan x" |
15229 | 1760 |
by (simp add: tan_def zero_less_divide_iff sin_gt_zero2 cos_gt_zero_pi) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1761 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1762 |
lemma tan_less_zero: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1763 |
assumes lb: "- pi/2 < x" and "x < 0" shows "tan x < 0" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1764 |
proof - |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1765 |
have "0 < tan (- x)" using prems by (simp only: tan_gt_zero) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1766 |
thus ?thesis by simp |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1767 |
qed |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1768 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1769 |
lemma lemma_DERIV_tan: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1770 |
"cos x \<noteq> 0 ==> DERIV (%x. sin(x)/cos(x)) x :> inverse((cos x)\<twosuperior>)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1771 |
apply (rule lemma_DERIV_subst) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1772 |
apply (best intro!: DERIV_intros intro: DERIV_chain2) |
15079
2ef899e4526d
conversion of Hyperreal/MacLaurin_lemmas to Isar script
paulson
parents:
15077
diff
changeset
|
1773 |
apply (auto simp add: divide_inverse numeral_2_eq_2) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1774 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1775 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1776 |
lemma DERIV_tan [simp]: "cos x \<noteq> 0 ==> DERIV tan x :> inverse((cos x)\<twosuperior>)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1777 |
by (auto dest: lemma_DERIV_tan simp add: tan_def [symmetric]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1778 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1779 |
lemma LIM_cos_div_sin [simp]: "(%x. cos(x)/sin(x)) -- pi/2 --> 0" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1780 |
apply (subgoal_tac "(\<lambda>x. cos x * inverse (sin x)) -- pi * inverse 2 --> 0*1") |
15229 | 1781 |
apply (simp add: divide_inverse [symmetric]) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1782 |
apply (rule LIM_mult2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1783 |
apply (rule_tac [2] inverse_1 [THEN subst]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1784 |
apply (rule_tac [2] LIM_inverse) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1785 |
apply (simp_all add: divide_inverse [symmetric]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1786 |
apply (simp_all only: isCont_def [symmetric] cos_pi_half [symmetric] sin_pi_half [symmetric]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1787 |
apply (blast intro!: DERIV_isCont DERIV_sin DERIV_cos)+ |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1788 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1789 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1790 |
lemma lemma_tan_total: "0 < y ==> \<exists>x. 0 < x & x < pi/2 & y < tan x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1791 |
apply (cut_tac LIM_cos_div_sin) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1792 |
apply (simp only: LIM_def) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1793 |
apply (drule_tac x = "inverse y" in spec, safe, force) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1794 |
apply (drule_tac ?d1.0 = s in pi_half_gt_zero [THEN [2] real_lbound_gt_zero], safe) |
15229 | 1795 |
apply (rule_tac x = "(pi/2) - e" in exI) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1796 |
apply (simp (no_asm_simp)) |
15229 | 1797 |
apply (drule_tac x = "(pi/2) - e" in spec) |
1798 |
apply (auto simp add: tan_def) |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1799 |
apply (rule inverse_less_iff_less [THEN iffD1]) |
15079
2ef899e4526d
conversion of Hyperreal/MacLaurin_lemmas to Isar script
paulson
parents:
15077
diff
changeset
|
1800 |
apply (auto simp add: divide_inverse) |
15229 | 1801 |
apply (rule real_mult_order) |
1802 |
apply (subgoal_tac [3] "0 < sin e & 0 < cos e") |
|
1803 |
apply (auto intro: cos_gt_zero sin_gt_zero2 simp add: mult_commute) |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1804 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1805 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1806 |
lemma tan_total_pos: "0 \<le> y ==> \<exists>x. 0 \<le> x & x < pi/2 & tan x = y" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1807 |
apply (frule real_le_imp_less_or_eq, safe) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1808 |
prefer 2 apply force |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1809 |
apply (drule lemma_tan_total, safe) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1810 |
apply (cut_tac f = tan and a = 0 and b = x and y = y in IVT_objl) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1811 |
apply (auto intro!: DERIV_tan [THEN DERIV_isCont]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1812 |
apply (drule_tac y = xa in order_le_imp_less_or_eq) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1813 |
apply (auto dest: cos_gt_zero) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1814 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1815 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1816 |
lemma lemma_tan_total1: "\<exists>x. -(pi/2) < x & x < (pi/2) & tan x = y" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1817 |
apply (cut_tac linorder_linear [of 0 y], safe) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1818 |
apply (drule tan_total_pos) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1819 |
apply (cut_tac [2] y="-y" in tan_total_pos, safe) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1820 |
apply (rule_tac [3] x = "-x" in exI) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1821 |
apply (auto intro!: exI) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1822 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1823 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1824 |
lemma tan_total: "EX! x. -(pi/2) < x & x < (pi/2) & tan x = y" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1825 |
apply (cut_tac y = y in lemma_tan_total1, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1826 |
apply (cut_tac x = xa and y = y in linorder_less_linear, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1827 |
apply (subgoal_tac [2] "\<exists>z. y < z & z < xa & DERIV tan z :> 0") |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1828 |
apply (subgoal_tac "\<exists>z. xa < z & z < y & DERIV tan z :> 0") |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1829 |
apply (rule_tac [4] Rolle) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1830 |
apply (rule_tac [2] Rolle) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1831 |
apply (auto intro!: DERIV_tan DERIV_isCont exI |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1832 |
simp add: differentiable_def) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1833 |
txt{*Now, simulate TRYALL*} |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1834 |
apply (rule_tac [!] DERIV_tan asm_rl) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1835 |
apply (auto dest!: DERIV_unique [OF _ DERIV_tan] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1836 |
simp add: cos_gt_zero_pi [THEN real_not_refl2, THEN not_sym]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1837 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1838 |
|
15229 | 1839 |
lemma arcsin_pi: |
1840 |
"[| -1 \<le> y; y \<le> 1 |] |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1841 |
==> -(pi/2) \<le> arcsin y & arcsin y \<le> pi & sin(arcsin y) = y" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1842 |
apply (drule sin_total, assumption) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1843 |
apply (erule ex1E) |
15229 | 1844 |
apply (simp add: arcsin_def) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1845 |
apply (rule someI2, blast) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1846 |
apply (force intro: order_trans) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1847 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1848 |
|
15229 | 1849 |
lemma arcsin: |
1850 |
"[| -1 \<le> y; y \<le> 1 |] |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1851 |
==> -(pi/2) \<le> arcsin y & |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1852 |
arcsin y \<le> pi/2 & sin(arcsin y) = y" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1853 |
apply (unfold arcsin_def) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1854 |
apply (drule sin_total, assumption) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1855 |
apply (fast intro: someI2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1856 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1857 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1858 |
lemma sin_arcsin [simp]: "[| -1 \<le> y; y \<le> 1 |] ==> sin(arcsin y) = y" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1859 |
by (blast dest: arcsin) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1860 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1861 |
lemma arcsin_bounded: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1862 |
"[| -1 \<le> y; y \<le> 1 |] ==> -(pi/2) \<le> arcsin y & arcsin y \<le> pi/2" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1863 |
by (blast dest: arcsin) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1864 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1865 |
lemma arcsin_lbound: "[| -1 \<le> y; y \<le> 1 |] ==> -(pi/2) \<le> arcsin y" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1866 |
by (blast dest: arcsin) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1867 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1868 |
lemma arcsin_ubound: "[| -1 \<le> y; y \<le> 1 |] ==> arcsin y \<le> pi/2" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1869 |
by (blast dest: arcsin) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1870 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1871 |
lemma arcsin_lt_bounded: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1872 |
"[| -1 < y; y < 1 |] ==> -(pi/2) < arcsin y & arcsin y < pi/2" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1873 |
apply (frule order_less_imp_le) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1874 |
apply (frule_tac y = y in order_less_imp_le) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1875 |
apply (frule arcsin_bounded) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1876 |
apply (safe, simp) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1877 |
apply (drule_tac y = "arcsin y" in order_le_imp_less_or_eq) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1878 |
apply (drule_tac [2] y = "pi/2" in order_le_imp_less_or_eq, safe) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1879 |
apply (drule_tac [!] f = sin in arg_cong, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1880 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1881 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1882 |
lemma arcsin_sin: "[|-(pi/2) \<le> x; x \<le> pi/2 |] ==> arcsin(sin x) = x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1883 |
apply (unfold arcsin_def) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1884 |
apply (rule some1_equality) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1885 |
apply (rule sin_total, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1886 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1887 |
|
15229 | 1888 |
lemma arcos: |
1889 |
"[| -1 \<le> y; y \<le> 1 |] |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1890 |
==> 0 \<le> arcos y & arcos y \<le> pi & cos(arcos y) = y" |
15229 | 1891 |
apply (simp add: arcos_def) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1892 |
apply (drule cos_total, assumption) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1893 |
apply (fast intro: someI2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1894 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1895 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1896 |
lemma cos_arcos [simp]: "[| -1 \<le> y; y \<le> 1 |] ==> cos(arcos y) = y" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1897 |
by (blast dest: arcos) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1898 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1899 |
lemma arcos_bounded: "[| -1 \<le> y; y \<le> 1 |] ==> 0 \<le> arcos y & arcos y \<le> pi" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1900 |
by (blast dest: arcos) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1901 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1902 |
lemma arcos_lbound: "[| -1 \<le> y; y \<le> 1 |] ==> 0 \<le> arcos y" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1903 |
by (blast dest: arcos) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1904 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1905 |
lemma arcos_ubound: "[| -1 \<le> y; y \<le> 1 |] ==> arcos y \<le> pi" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1906 |
by (blast dest: arcos) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1907 |
|
15229 | 1908 |
lemma arcos_lt_bounded: |
1909 |
"[| -1 < y; y < 1 |] |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1910 |
==> 0 < arcos y & arcos y < pi" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1911 |
apply (frule order_less_imp_le) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1912 |
apply (frule_tac y = y in order_less_imp_le) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1913 |
apply (frule arcos_bounded, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1914 |
apply (drule_tac y = "arcos y" in order_le_imp_less_or_eq) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1915 |
apply (drule_tac [2] y = pi in order_le_imp_less_or_eq, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1916 |
apply (drule_tac [!] f = cos in arg_cong, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1917 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1918 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1919 |
lemma arcos_cos: "[|0 \<le> x; x \<le> pi |] ==> arcos(cos x) = x" |
15229 | 1920 |
apply (simp add: arcos_def) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1921 |
apply (auto intro!: some1_equality cos_total) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1922 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1923 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1924 |
lemma arcos_cos2: "[|x \<le> 0; -pi \<le> x |] ==> arcos(cos x) = -x" |
15229 | 1925 |
apply (simp add: arcos_def) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1926 |
apply (auto intro!: some1_equality cos_total) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1927 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1928 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1929 |
lemma arctan [simp]: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1930 |
"- (pi/2) < arctan y & arctan y < pi/2 & tan (arctan y) = y" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1931 |
apply (cut_tac y = y in tan_total) |
15229 | 1932 |
apply (simp add: arctan_def) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1933 |
apply (fast intro: someI2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1934 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1935 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1936 |
lemma tan_arctan: "tan(arctan y) = y" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1937 |
by auto |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1938 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1939 |
lemma arctan_bounded: "- (pi/2) < arctan y & arctan y < pi/2" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1940 |
by (auto simp only: arctan) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1941 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1942 |
lemma arctan_lbound: "- (pi/2) < arctan y" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1943 |
by auto |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1944 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1945 |
lemma arctan_ubound: "arctan y < pi/2" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1946 |
by (auto simp only: arctan) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1947 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1948 |
lemma arctan_tan: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1949 |
"[|-(pi/2) < x; x < pi/2 |] ==> arctan(tan x) = x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1950 |
apply (unfold arctan_def) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1951 |
apply (rule some1_equality) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1952 |
apply (rule tan_total, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1953 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1954 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1955 |
lemma arctan_zero_zero [simp]: "arctan 0 = 0" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1956 |
by (insert arctan_tan [of 0], simp) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1957 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1958 |
lemma cos_arctan_not_zero [simp]: "cos(arctan x) \<noteq> 0" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1959 |
apply (auto simp add: cos_zero_iff) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1960 |
apply (case_tac "n") |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1961 |
apply (case_tac [3] "n") |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1962 |
apply (cut_tac [2] y = x in arctan_ubound) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1963 |
apply (cut_tac [4] y = x in arctan_lbound) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1964 |
apply (auto simp add: real_of_nat_Suc left_distrib mult_less_0_iff) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1965 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1966 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1967 |
lemma tan_sec: "cos x \<noteq> 0 ==> 1 + tan(x) ^ 2 = inverse(cos x) ^ 2" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1968 |
apply (rule power_inverse [THEN subst]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1969 |
apply (rule_tac c1 = "(cos x)\<twosuperior>" in real_mult_right_cancel [THEN iffD1]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1970 |
apply (auto dest: realpow_not_zero |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1971 |
simp add: power_mult_distrib left_distrib realpow_divide tan_def |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1972 |
mult_assoc power_inverse [symmetric] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1973 |
simp del: realpow_Suc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1974 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1975 |
|
15085
5693a977a767
removed some [iff] declarations from RealDef.thy, concerning inequalities
paulson
parents:
15081
diff
changeset
|
1976 |
text{*NEEDED??*} |
15229 | 1977 |
lemma [simp]: |
1978 |
"sin (x + 1 / 2 * real (Suc m) * pi) = |
|
1979 |
cos (x + 1 / 2 * real (m) * pi)" |
|
1980 |
by (simp only: cos_add sin_add real_of_nat_Suc left_distrib right_distrib, auto) |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1981 |
|
15085
5693a977a767
removed some [iff] declarations from RealDef.thy, concerning inequalities
paulson
parents:
15081
diff
changeset
|
1982 |
text{*NEEDED??*} |
15229 | 1983 |
lemma [simp]: |
1984 |
"sin (x + real (Suc m) * pi / 2) = |
|
1985 |
cos (x + real (m) * pi / 2)" |
|
1986 |
by (simp only: cos_add sin_add real_of_nat_Suc add_divide_distrib left_distrib, auto) |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1987 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1988 |
lemma DERIV_sin_add [simp]: "DERIV (%x. sin (x + k)) xa :> cos (xa + k)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1989 |
apply (rule lemma_DERIV_subst) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1990 |
apply (rule_tac f = sin and g = "%x. x + k" in DERIV_chain2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1991 |
apply (best intro!: DERIV_intros intro: DERIV_chain2)+ |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1992 |
apply (simp (no_asm)) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1993 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
1994 |
|
15383 | 1995 |
lemma sin_cos_npi [simp]: "sin (real (Suc (2 * n)) * pi / 2) = (-1) ^ n" |
1996 |
proof - |
|
1997 |
have "sin ((real n + 1/2) * pi) = cos (real n * pi)" |
|
1998 |
by (auto simp add: right_distrib sin_add left_distrib mult_ac) |
|
1999 |
thus ?thesis |
|
2000 |
by (simp add: real_of_nat_Suc left_distrib add_divide_distrib |
|
2001 |
mult_commute [of pi]) |
|
2002 |
qed |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2003 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2004 |
lemma cos_2npi [simp]: "cos (2 * real (n::nat) * pi) = 1" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2005 |
by (simp add: cos_double mult_assoc power_add [symmetric] numeral_2_eq_2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2006 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2007 |
lemma cos_3over2_pi [simp]: "cos (3 / 2 * pi) = 0" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2008 |
apply (subgoal_tac "3/2 = (1+1 / 2::real)") |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2009 |
apply (simp only: left_distrib) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2010 |
apply (auto simp add: cos_add mult_ac) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2011 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2012 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2013 |
lemma sin_2npi [simp]: "sin (2 * real (n::nat) * pi) = 0" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2014 |
by (auto simp add: mult_assoc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2015 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2016 |
lemma sin_3over2_pi [simp]: "sin (3 / 2 * pi) = - 1" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2017 |
apply (subgoal_tac "3/2 = (1+1 / 2::real)") |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2018 |
apply (simp only: left_distrib) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2019 |
apply (auto simp add: sin_add mult_ac) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2020 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2021 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2022 |
(*NEEDED??*) |
15229 | 2023 |
lemma [simp]: |
2024 |
"cos(x + 1 / 2 * real(Suc m) * pi) = -sin (x + 1 / 2 * real m * pi)" |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2025 |
apply (simp only: cos_add sin_add real_of_nat_Suc right_distrib left_distrib minus_mult_right, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2026 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2027 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2028 |
(*NEEDED??*) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2029 |
lemma [simp]: "cos (x + real(Suc m) * pi / 2) = -sin (x + real m * pi / 2)" |
15229 | 2030 |
by (simp only: cos_add sin_add real_of_nat_Suc left_distrib add_divide_distrib, auto) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2031 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2032 |
lemma cos_pi_eq_zero [simp]: "cos (pi * real (Suc (2 * m)) / 2) = 0" |
15229 | 2033 |
by (simp only: cos_add sin_add real_of_nat_Suc left_distrib right_distrib add_divide_distrib, auto) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2034 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2035 |
lemma DERIV_cos_add [simp]: "DERIV (%x. cos (x + k)) xa :> - sin (xa + k)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2036 |
apply (rule lemma_DERIV_subst) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2037 |
apply (rule_tac f = cos and g = "%x. x + k" in DERIV_chain2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2038 |
apply (best intro!: DERIV_intros intro: DERIV_chain2)+ |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2039 |
apply (simp (no_asm)) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2040 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2041 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2042 |
lemma isCont_cos [simp]: "isCont cos x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2043 |
by (rule DERIV_cos [THEN DERIV_isCont]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2044 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2045 |
lemma isCont_sin [simp]: "isCont sin x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2046 |
by (rule DERIV_sin [THEN DERIV_isCont]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2047 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2048 |
lemma isCont_exp [simp]: "isCont exp x" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2049 |
by (rule DERIV_exp [THEN DERIV_isCont]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2050 |
|
15081 | 2051 |
lemma sin_zero_abs_cos_one: "sin x = 0 ==> \<bar>cos x\<bar> = 1" |
15539 | 2052 |
by (auto simp add: sin_zero_iff even_mult_two_ex) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2053 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2054 |
lemma exp_eq_one_iff [simp]: "(exp x = 1) = (x = 0)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2055 |
apply auto |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2056 |
apply (drule_tac f = ln in arg_cong, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2057 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2058 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2059 |
lemma cos_one_sin_zero: "cos x = 1 ==> sin x = 0" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2060 |
by (cut_tac x = x in sin_cos_squared_add3, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2061 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2062 |
|
15229 | 2063 |
lemma real_root_less_mono: |
2064 |
"[| 0 \<le> x; x < y |] ==> root(Suc n) x < root(Suc n) y" |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2065 |
apply (frule order_le_less_trans, assumption) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2066 |
apply (frule_tac n1 = n in real_root_pow_pos2 [THEN ssubst]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2067 |
apply (rotate_tac 1, assumption) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2068 |
apply (frule_tac n1 = n in real_root_pow_pos [THEN ssubst]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2069 |
apply (rotate_tac 3, assumption) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2070 |
apply (drule_tac y = "root (Suc n) y ^ Suc n" in order_less_imp_le) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2071 |
apply (frule_tac n = n in real_root_pos_pos_le) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2072 |
apply (frule_tac n = n in real_root_pos_pos) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2073 |
apply (drule_tac x = "root (Suc n) x" and y = "root (Suc n) y" in realpow_increasing) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2074 |
apply (assumption, assumption) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2075 |
apply (drule_tac x = "root (Suc n) x" in order_le_imp_less_or_eq) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2076 |
apply auto |
15229 | 2077 |
apply (drule_tac f = "%x. x ^ (Suc n)" in arg_cong) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2078 |
apply (auto simp add: real_root_pow_pos2 simp del: realpow_Suc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2079 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2080 |
|
15229 | 2081 |
lemma real_root_le_mono: |
2082 |
"[| 0 \<le> x; x \<le> y |] ==> root(Suc n) x \<le> root(Suc n) y" |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2083 |
apply (drule_tac y = y in order_le_imp_less_or_eq) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2084 |
apply (auto dest: real_root_less_mono intro: order_less_imp_le) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2085 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2086 |
|
15229 | 2087 |
lemma real_root_less_iff [simp]: |
2088 |
"[| 0 \<le> x; 0 \<le> y |] ==> (root(Suc n) x < root(Suc n) y) = (x < y)" |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2089 |
apply (auto intro: real_root_less_mono) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2090 |
apply (rule ccontr, drule linorder_not_less [THEN iffD1]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2091 |
apply (drule_tac x = y and n = n in real_root_le_mono, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2092 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2093 |
|
15229 | 2094 |
lemma real_root_le_iff [simp]: |
2095 |
"[| 0 \<le> x; 0 \<le> y |] ==> (root(Suc n) x \<le> root(Suc n) y) = (x \<le> y)" |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2096 |
apply (auto intro: real_root_le_mono) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2097 |
apply (simp (no_asm) add: linorder_not_less [symmetric]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2098 |
apply auto |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2099 |
apply (drule_tac x = y and n = n in real_root_less_mono, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2100 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2101 |
|
15229 | 2102 |
lemma real_root_eq_iff [simp]: |
2103 |
"[| 0 \<le> x; 0 \<le> y |] ==> (root(Suc n) x = root(Suc n) y) = (x = y)" |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2104 |
apply (auto intro!: order_antisym) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2105 |
apply (rule_tac n1 = n in real_root_le_iff [THEN iffD1]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2106 |
apply (rule_tac [4] n1 = n in real_root_le_iff [THEN iffD1], auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2107 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2108 |
|
15229 | 2109 |
lemma real_root_pos_unique: |
2110 |
"[| 0 \<le> x; 0 \<le> y; y ^ (Suc n) = x |] ==> root (Suc n) x = y" |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2111 |
by (auto dest: real_root_pos2 simp del: realpow_Suc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2112 |
|
15229 | 2113 |
lemma real_root_mult: |
2114 |
"[| 0 \<le> x; 0 \<le> y |] |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2115 |
==> root(Suc n) (x * y) = root(Suc n) x * root(Suc n) y" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2116 |
apply (rule real_root_pos_unique) |
15234
ec91a90c604e
simplification tweaks for better arithmetic reasoning
paulson
parents:
15229
diff
changeset
|
2117 |
apply (auto intro!: real_root_pos_pos_le |
ec91a90c604e
simplification tweaks for better arithmetic reasoning
paulson
parents:
15229
diff
changeset
|
2118 |
simp add: power_mult_distrib zero_le_mult_iff real_root_pow_pos2 |
ec91a90c604e
simplification tweaks for better arithmetic reasoning
paulson
parents:
15229
diff
changeset
|
2119 |
simp del: realpow_Suc) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2120 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2121 |
|
15229 | 2122 |
lemma real_root_inverse: |
2123 |
"0 \<le> x ==> (root(Suc n) (inverse x) = inverse(root(Suc n) x))" |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2124 |
apply (rule real_root_pos_unique) |
15234
ec91a90c604e
simplification tweaks for better arithmetic reasoning
paulson
parents:
15229
diff
changeset
|
2125 |
apply (auto intro: real_root_pos_pos_le |
ec91a90c604e
simplification tweaks for better arithmetic reasoning
paulson
parents:
15229
diff
changeset
|
2126 |
simp add: power_inverse [symmetric] real_root_pow_pos2 |
ec91a90c604e
simplification tweaks for better arithmetic reasoning
paulson
parents:
15229
diff
changeset
|
2127 |
simp del: realpow_Suc) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2128 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2129 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2130 |
lemma real_root_divide: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2131 |
"[| 0 \<le> x; 0 \<le> y |] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2132 |
==> (root(Suc n) (x / y) = root(Suc n) x / root(Suc n) y)" |
15229 | 2133 |
apply (simp add: divide_inverse) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2134 |
apply (auto simp add: real_root_mult real_root_inverse) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2135 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2136 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2137 |
lemma real_sqrt_less_mono: "[| 0 \<le> x; x < y |] ==> sqrt(x) < sqrt(y)" |
15229 | 2138 |
by (simp add: sqrt_def) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2139 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2140 |
lemma real_sqrt_le_mono: "[| 0 \<le> x; x \<le> y |] ==> sqrt(x) \<le> sqrt(y)" |
15229 | 2141 |
by (simp add: sqrt_def) |
2142 |
||
2143 |
lemma real_sqrt_less_iff [simp]: |
|
2144 |
"[| 0 \<le> x; 0 \<le> y |] ==> (sqrt(x) < sqrt(y)) = (x < y)" |
|
2145 |
by (simp add: sqrt_def) |
|
2146 |
||
2147 |
lemma real_sqrt_le_iff [simp]: |
|
2148 |
"[| 0 \<le> x; 0 \<le> y |] ==> (sqrt(x) \<le> sqrt(y)) = (x \<le> y)" |
|
2149 |
by (simp add: sqrt_def) |
|
2150 |
||
2151 |
lemma real_sqrt_eq_iff [simp]: |
|
2152 |
"[| 0 \<le> x; 0 \<le> y |] ==> (sqrt(x) = sqrt(y)) = (x = y)" |
|
2153 |
by (simp add: sqrt_def) |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2154 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2155 |
lemma real_sqrt_sos_less_one_iff [simp]: "(sqrt(x\<twosuperior> + y\<twosuperior>) < 1) = (x\<twosuperior> + y\<twosuperior> < 1)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2156 |
apply (rule real_sqrt_one [THEN subst], safe) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2157 |
apply (rule_tac [2] real_sqrt_less_mono) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2158 |
apply (drule real_sqrt_less_iff [THEN [2] rev_iffD1], auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2159 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2160 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2161 |
lemma real_sqrt_sos_eq_one_iff [simp]: "(sqrt(x\<twosuperior> + y\<twosuperior>) = 1) = (x\<twosuperior> + y\<twosuperior> = 1)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2162 |
apply (rule real_sqrt_one [THEN subst], safe) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2163 |
apply (drule real_sqrt_eq_iff [THEN [2] rev_iffD1], auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2164 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2165 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2166 |
lemma real_divide_square_eq [simp]: "(((r::real) * a) / (r * r)) = a / r" |
15229 | 2167 |
apply (simp add: divide_inverse) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2168 |
apply (case_tac "r=0") |
15539 | 2169 |
apply (auto simp add: mult_ac) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2170 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2171 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2172 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2173 |
subsection{*Theorems About Sqrt, Transcendental Functions for Complex*} |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2174 |
|
15228 | 2175 |
lemma le_real_sqrt_sumsq [simp]: "x \<le> sqrt (x * x + y * y)" |
2176 |
proof (rule order_trans) |
|
2177 |
show "x \<le> sqrt(x*x)" by (simp add: abs_if) |
|
2178 |
show "sqrt (x * x) \<le> sqrt (x * x + y * y)" |
|
2179 |
by (rule real_sqrt_le_mono, auto) |
|
2180 |
qed |
|
2181 |
||
2182 |
lemma minus_le_real_sqrt_sumsq [simp]: "-x \<le> sqrt (x * x + y * y)" |
|
2183 |
proof (rule order_trans) |
|
2184 |
show "-x \<le> sqrt(x*x)" by (simp add: abs_if) |
|
2185 |
show "sqrt (x * x) \<le> sqrt (x * x + y * y)" |
|
2186 |
by (rule real_sqrt_le_mono, auto) |
|
2187 |
qed |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2188 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2189 |
lemma lemma_real_divide_sqrt_ge_minus_one: |
15228 | 2190 |
"0 < x ==> -1 \<le> x/(sqrt (x * x + y * y))" |
2191 |
by (simp add: divide_const_simps linorder_not_le [symmetric]) |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2192 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2193 |
lemma real_sqrt_sum_squares_gt_zero1: "x < 0 ==> 0 < sqrt (x * x + y * y)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2194 |
apply (rule real_sqrt_gt_zero) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2195 |
apply (subgoal_tac "0 < x*x & 0 \<le> y*y", arith) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2196 |
apply (auto simp add: zero_less_mult_iff) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2197 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2198 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2199 |
lemma real_sqrt_sum_squares_gt_zero2: "0 < x ==> 0 < sqrt (x * x + y * y)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2200 |
apply (rule real_sqrt_gt_zero) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2201 |
apply (subgoal_tac "0 < x*x & 0 \<le> y*y", arith) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2202 |
apply (auto simp add: zero_less_mult_iff) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2203 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2204 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2205 |
lemma real_sqrt_sum_squares_gt_zero3: "x \<noteq> 0 ==> 0 < sqrt(x\<twosuperior> + y\<twosuperior>)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2206 |
apply (cut_tac x = x and y = 0 in linorder_less_linear) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2207 |
apply (auto intro: real_sqrt_sum_squares_gt_zero2 real_sqrt_sum_squares_gt_zero1 simp add: numeral_2_eq_2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2208 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2209 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2210 |
lemma real_sqrt_sum_squares_gt_zero3a: "y \<noteq> 0 ==> 0 < sqrt(x\<twosuperior> + y\<twosuperior>)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2211 |
apply (drule_tac y = x in real_sqrt_sum_squares_gt_zero3) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2212 |
apply (auto simp add: real_add_commute) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2213 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2214 |
|
15544 | 2215 |
lemma real_sqrt_sum_squares_eq_cancel: "sqrt(x\<twosuperior> + y\<twosuperior>) = x ==> y = 0" |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2216 |
by (drule_tac f = "%x. x\<twosuperior>" in arg_cong, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2217 |
|
15544 | 2218 |
lemma real_sqrt_sum_squares_eq_cancel2: "sqrt(x\<twosuperior> + y\<twosuperior>) = y ==> x = 0" |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2219 |
apply (rule_tac x = y in real_sqrt_sum_squares_eq_cancel) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2220 |
apply (simp add: real_add_commute) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2221 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2222 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2223 |
lemma lemma_real_divide_sqrt_le_one: "x < 0 ==> x/(sqrt (x * x + y * y)) \<le> 1" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2224 |
by (insert lemma_real_divide_sqrt_ge_minus_one [of "-x" y], simp) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2225 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2226 |
lemma lemma_real_divide_sqrt_ge_minus_one2: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2227 |
"x < 0 ==> -1 \<le> x/(sqrt (x * x + y * y))" |
15229 | 2228 |
apply (simp add: divide_const_simps) |
2229 |
apply (insert minus_le_real_sqrt_sumsq [of x y], arith) |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2230 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2231 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2232 |
lemma lemma_real_divide_sqrt_le_one2: "0 < x ==> x/(sqrt (x * x + y * y)) \<le> 1" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2233 |
by (cut_tac x = "-x" and y = y in lemma_real_divide_sqrt_ge_minus_one2, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2234 |
|
15228 | 2235 |
lemma minus_sqrt_le: "- sqrt (x * x + y * y) \<le> x" |
2236 |
by (insert minus_le_real_sqrt_sumsq [of x y], arith) |
|
2237 |
||
2238 |
lemma minus_sqrt_le2: "- sqrt (x * x + y * y) \<le> y" |
|
2239 |
by (subst add_commute, simp add: minus_sqrt_le) |
|
2240 |
||
2241 |
lemma not_neg_sqrt_sumsq: "~ sqrt (x * x + y * y) < 0" |
|
2242 |
by (simp add: linorder_not_less) |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2243 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2244 |
lemma cos_x_y_ge_minus_one: "-1 \<le> x / sqrt (x * x + y * y)" |
15229 | 2245 |
by (simp add: minus_sqrt_le not_neg_sqrt_sumsq divide_const_simps) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2246 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2247 |
lemma cos_x_y_ge_minus_one1a [simp]: "-1 \<le> y / sqrt (x * x + y * y)" |
15229 | 2248 |
by (subst add_commute, simp add: cos_x_y_ge_minus_one) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2249 |
|
15228 | 2250 |
lemma cos_x_y_le_one [simp]: "x / sqrt (x * x + y * y) \<le> 1" |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2251 |
apply (cut_tac x = x and y = 0 in linorder_less_linear, safe) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2252 |
apply (rule lemma_real_divide_sqrt_le_one) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2253 |
apply (rule_tac [3] lemma_real_divide_sqrt_le_one2, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2254 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2255 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2256 |
lemma cos_x_y_le_one2 [simp]: "y / sqrt (x * x + y * y) \<le> 1" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2257 |
apply (cut_tac x = y and y = x in cos_x_y_le_one) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2258 |
apply (simp add: real_add_commute) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2259 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2260 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2261 |
declare cos_arcos [OF cos_x_y_ge_minus_one cos_x_y_le_one, simp] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2262 |
declare arcos_bounded [OF cos_x_y_ge_minus_one cos_x_y_le_one, simp] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2263 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2264 |
declare cos_arcos [OF cos_x_y_ge_minus_one1a cos_x_y_le_one2, simp] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2265 |
declare arcos_bounded [OF cos_x_y_ge_minus_one1a cos_x_y_le_one2, simp] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2266 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2267 |
lemma cos_abs_x_y_ge_minus_one [simp]: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2268 |
"-1 \<le> \<bar>x\<bar> / sqrt (x * x + y * y)" |
15228 | 2269 |
by (auto simp add: divide_const_simps abs_if linorder_not_le [symmetric]) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2270 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2271 |
lemma cos_abs_x_y_le_one [simp]: "\<bar>x\<bar> / sqrt (x * x + y * y) \<le> 1" |
15228 | 2272 |
apply (insert minus_le_real_sqrt_sumsq [of x y] le_real_sqrt_sumsq [of x y]) |
2273 |
apply (auto simp add: divide_const_simps abs_if linorder_neq_iff) |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2274 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2275 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2276 |
declare cos_arcos [OF cos_abs_x_y_ge_minus_one cos_abs_x_y_le_one, simp] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2277 |
declare arcos_bounded [OF cos_abs_x_y_ge_minus_one cos_abs_x_y_le_one, simp] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2278 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2279 |
lemma minus_pi_less_zero: "-pi < 0" |
15228 | 2280 |
by simp |
2281 |
||
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2282 |
declare minus_pi_less_zero [simp] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2283 |
declare minus_pi_less_zero [THEN order_less_imp_le, simp] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2284 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2285 |
lemma arcos_ge_minus_pi: "[| -1 \<le> y; y \<le> 1 |] ==> -pi \<le> arcos y" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2286 |
apply (rule real_le_trans) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2287 |
apply (rule_tac [2] arcos_lbound, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2288 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2289 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2290 |
declare arcos_ge_minus_pi [OF cos_x_y_ge_minus_one cos_x_y_le_one, simp] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2291 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2292 |
(* How tedious! *) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2293 |
lemma lemma_divide_rearrange: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2294 |
"[| x + (y::real) \<noteq> 0; 1 - z = x/(x + y) |] ==> z = y/(x + y)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2295 |
apply (rule_tac c1 = "x + y" in real_mult_right_cancel [THEN iffD1]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2296 |
apply (frule_tac [2] c1 = "x + y" in real_mult_right_cancel [THEN iffD2]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2297 |
prefer 2 apply assumption |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2298 |
apply (rotate_tac [2] 2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2299 |
apply (drule_tac [2] mult_assoc [THEN subst]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2300 |
apply (rotate_tac [2] 2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2301 |
apply (frule_tac [2] left_inverse [THEN subst]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2302 |
prefer 2 apply assumption |
15229 | 2303 |
apply (erule_tac [2] V = "(1 - z) * (x + y) = x / (x + y) * (x + y)" in thin_rl) |
2304 |
apply (erule_tac [2] V = "1 - z = x / (x + y)" in thin_rl) |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2305 |
apply (auto simp add: mult_assoc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2306 |
apply (auto simp add: right_distrib left_diff_distrib) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2307 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2308 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2309 |
lemma lemma_cos_sin_eq: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2310 |
"[| 0 < x * x + y * y; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2311 |
1 - (sin xa)\<twosuperior> = (x / sqrt (x * x + y * y)) ^ 2 |] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2312 |
==> (sin xa)\<twosuperior> = (y / sqrt (x * x + y * y)) ^ 2" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2313 |
by (auto intro: lemma_divide_rearrange |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2314 |
simp add: realpow_divide power2_eq_square [symmetric]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2315 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2316 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2317 |
lemma lemma_sin_cos_eq: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2318 |
"[| 0 < x * x + y * y; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2319 |
1 - (cos xa)\<twosuperior> = (y / sqrt (x * x + y * y)) ^ 2 |] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2320 |
==> (cos xa)\<twosuperior> = (x / sqrt (x * x + y * y)) ^ 2" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2321 |
apply (auto simp add: realpow_divide power2_eq_square [symmetric]) |
15085
5693a977a767
removed some [iff] declarations from RealDef.thy, concerning inequalities
paulson
parents:
15081
diff
changeset
|
2322 |
apply (subst add_commute) |
5693a977a767
removed some [iff] declarations from RealDef.thy, concerning inequalities
paulson
parents:
15081
diff
changeset
|
2323 |
apply (rule lemma_divide_rearrange, simp add: real_add_eq_0_iff) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2324 |
apply (simp add: add_commute) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2325 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2326 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2327 |
lemma sin_x_y_disj: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2328 |
"[| x \<noteq> 0; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2329 |
cos xa = x / sqrt (x * x + y * y) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2330 |
|] ==> sin xa = y / sqrt (x * x + y * y) | |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2331 |
sin xa = - y / sqrt (x * x + y * y)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2332 |
apply (drule_tac f = "%x. x\<twosuperior>" in arg_cong) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2333 |
apply (frule_tac y = y in real_sum_square_gt_zero) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2334 |
apply (simp add: cos_squared_eq) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2335 |
apply (subgoal_tac "(sin xa)\<twosuperior> = (y / sqrt (x * x + y * y)) ^ 2") |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2336 |
apply (rule_tac [2] lemma_cos_sin_eq) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2337 |
apply (auto simp add: realpow_two_disj numeral_2_eq_2 simp del: realpow_Suc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2338 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2339 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2340 |
lemma lemma_cos_not_eq_zero: "x \<noteq> 0 ==> x / sqrt (x * x + y * y) \<noteq> 0" |
15229 | 2341 |
apply (simp add: divide_inverse) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2342 |
apply (frule_tac y3 = y in real_sqrt_sum_squares_gt_zero3 [THEN real_not_refl2, THEN not_sym, THEN nonzero_imp_inverse_nonzero]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2343 |
apply (auto simp add: power2_eq_square) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2344 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2345 |
|
15229 | 2346 |
lemma cos_x_y_disj: |
2347 |
"[| x \<noteq> 0; |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2348 |
sin xa = y / sqrt (x * x + y * y) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2349 |
|] ==> cos xa = x / sqrt (x * x + y * y) | |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2350 |
cos xa = - x / sqrt (x * x + y * y)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2351 |
apply (drule_tac f = "%x. x\<twosuperior>" in arg_cong) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2352 |
apply (frule_tac y = y in real_sum_square_gt_zero) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2353 |
apply (simp add: sin_squared_eq del: realpow_Suc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2354 |
apply (subgoal_tac "(cos xa)\<twosuperior> = (x / sqrt (x * x + y * y)) ^ 2") |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2355 |
apply (rule_tac [2] lemma_sin_cos_eq) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2356 |
apply (auto simp add: realpow_two_disj numeral_2_eq_2 simp del: realpow_Suc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2357 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2358 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2359 |
lemma real_sqrt_divide_less_zero: "0 < y ==> - y / sqrt (x * x + y * y) < 0" |
15229 | 2360 |
apply (case_tac "x = 0", auto) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2361 |
apply (drule_tac y = y in real_sqrt_sum_squares_gt_zero3) |
15079
2ef899e4526d
conversion of Hyperreal/MacLaurin_lemmas to Isar script
paulson
parents:
15077
diff
changeset
|
2362 |
apply (auto simp add: zero_less_mult_iff divide_inverse power2_eq_square) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2363 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2364 |
|
15229 | 2365 |
lemma polar_ex1: |
2366 |
"[| x \<noteq> 0; 0 < y |] ==> \<exists>r a. x = r * cos a & y = r * sin a" |
|
2367 |
apply (rule_tac x = "sqrt (x\<twosuperior> + y\<twosuperior>)" in exI) |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2368 |
apply (rule_tac x = "arcos (x / sqrt (x * x + y * y))" in exI) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2369 |
apply auto |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2370 |
apply (drule_tac y2 = y in real_sqrt_sum_squares_gt_zero3 [THEN real_not_refl2, THEN not_sym]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2371 |
apply (auto simp add: power2_eq_square) |
15229 | 2372 |
apply (simp add: arcos_def) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2373 |
apply (cut_tac x1 = x and y1 = y |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2374 |
in cos_total [OF cos_x_y_ge_minus_one cos_x_y_le_one]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2375 |
apply (rule someI2_ex, blast) |
15229 | 2376 |
apply (erule_tac V = "EX! xa. 0 \<le> xa & xa \<le> pi & cos xa = x / sqrt (x * x + y * y)" in thin_rl) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2377 |
apply (frule sin_x_y_disj, blast) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2378 |
apply (drule_tac y2 = y in real_sqrt_sum_squares_gt_zero3 [THEN real_not_refl2, THEN not_sym]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2379 |
apply (auto simp add: power2_eq_square) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2380 |
apply (drule sin_ge_zero, assumption) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2381 |
apply (drule_tac x = x in real_sqrt_divide_less_zero, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2382 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2383 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2384 |
lemma real_sum_squares_cancel2a: "x * x = -(y * y) ==> y = (0::real)" |
15085
5693a977a767
removed some [iff] declarations from RealDef.thy, concerning inequalities
paulson
parents:
15081
diff
changeset
|
2385 |
by (auto intro: real_sum_squares_cancel iff: real_add_eq_0_iff) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2386 |
|
15229 | 2387 |
lemma polar_ex2: |
2388 |
"[| x \<noteq> 0; y < 0 |] ==> \<exists>r a. x = r * cos a & y = r * sin a" |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2389 |
apply (cut_tac x = 0 and y = x in linorder_less_linear, auto) |
15228 | 2390 |
apply (rule_tac x = "sqrt (x\<twosuperior> + y\<twosuperior>)" in exI) |
2391 |
apply (rule_tac x = "arcsin (y / sqrt (x * x + y * y))" in exI) |
|
15085
5693a977a767
removed some [iff] declarations from RealDef.thy, concerning inequalities
paulson
parents:
15081
diff
changeset
|
2392 |
apply (auto dest: real_sum_squares_cancel2a |
5693a977a767
removed some [iff] declarations from RealDef.thy, concerning inequalities
paulson
parents:
15081
diff
changeset
|
2393 |
simp add: power2_eq_square real_0_le_add_iff real_add_eq_0_iff) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2394 |
apply (unfold arcsin_def) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2395 |
apply (cut_tac x1 = x and y1 = y |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2396 |
in sin_total [OF cos_x_y_ge_minus_one1a cos_x_y_le_one2]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2397 |
apply (rule someI2_ex, blast) |
15228 | 2398 |
apply (erule_tac V = "EX! v. ?P v" in thin_rl) |
15085
5693a977a767
removed some [iff] declarations from RealDef.thy, concerning inequalities
paulson
parents:
15081
diff
changeset
|
2399 |
apply (cut_tac x=x and y=y in cos_x_y_disj, simp, blast) |
5693a977a767
removed some [iff] declarations from RealDef.thy, concerning inequalities
paulson
parents:
15081
diff
changeset
|
2400 |
apply (auto simp add: real_0_le_add_iff real_add_eq_0_iff) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2401 |
apply (drule cos_ge_zero, force) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2402 |
apply (drule_tac x = y in real_sqrt_divide_less_zero) |
15085
5693a977a767
removed some [iff] declarations from RealDef.thy, concerning inequalities
paulson
parents:
15081
diff
changeset
|
2403 |
apply (auto simp add: add_commute) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2404 |
apply (insert polar_ex1 [of x "-y"], simp, clarify) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2405 |
apply (rule_tac x = r in exI) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2406 |
apply (rule_tac x = "-a" in exI, simp) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2407 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2408 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2409 |
lemma polar_Ex: "\<exists>r a. x = r * cos a & y = r * sin a" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2410 |
apply (case_tac "x = 0", auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2411 |
apply (rule_tac x = y in exI) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2412 |
apply (rule_tac x = "pi/2" in exI, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2413 |
apply (cut_tac x = 0 and y = y in linorder_less_linear, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2414 |
apply (rule_tac [2] x = x in exI) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2415 |
apply (rule_tac [2] x = 0 in exI, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2416 |
apply (blast intro: polar_ex1 polar_ex2)+ |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2417 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2418 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2419 |
lemma real_sqrt_ge_abs1 [simp]: "\<bar>x\<bar> \<le> sqrt (x\<twosuperior> + y\<twosuperior>)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2420 |
apply (rule_tac n = 1 in realpow_increasing) |
16775
c1b87ef4a1c3
added lemmas to OrderedGroup.thy (reasoning about signs, absolute value, triangle inequalities)
avigad
parents:
16641
diff
changeset
|
2421 |
apply (auto simp add: numeral_2_eq_2 [symmetric] power2_abs) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2422 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2423 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2424 |
lemma real_sqrt_ge_abs2 [simp]: "\<bar>y\<bar> \<le> sqrt (x\<twosuperior> + y\<twosuperior>)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2425 |
apply (rule real_add_commute [THEN subst]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2426 |
apply (rule real_sqrt_ge_abs1) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2427 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2428 |
declare real_sqrt_ge_abs1 [simp] real_sqrt_ge_abs2 [simp] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2429 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2430 |
lemma real_sqrt_two_gt_zero [simp]: "0 < sqrt 2" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2431 |
by (auto intro: real_sqrt_gt_zero) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2432 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2433 |
lemma real_sqrt_two_ge_zero [simp]: "0 \<le> sqrt 2" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2434 |
by (auto intro: real_sqrt_ge_zero) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2435 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2436 |
lemma real_sqrt_two_gt_one [simp]: "1 < sqrt 2" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2437 |
apply (rule order_less_le_trans [of _ "7/5"], simp) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2438 |
apply (rule_tac n = 1 in realpow_increasing) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2439 |
prefer 3 apply (simp add: numeral_2_eq_2 [symmetric] del: realpow_Suc) |
15539 | 2440 |
apply (simp_all add: numeral_2_eq_2) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2441 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2442 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2443 |
lemma lemma_real_divide_sqrt_less: "0 < u ==> u / sqrt 2 < u" |
15234
ec91a90c604e
simplification tweaks for better arithmetic reasoning
paulson
parents:
15229
diff
changeset
|
2444 |
by (simp add: divide_less_eq mult_compare_simps) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2445 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2446 |
lemma four_x_squared: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2447 |
fixes x::real |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2448 |
shows "4 * x\<twosuperior> = (2 * x)\<twosuperior>" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2449 |
by (simp add: power2_eq_square) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2450 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2451 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2452 |
text{*Needed for the infinitely close relation over the nonstandard |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2453 |
complex numbers*} |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2454 |
lemma lemma_sqrt_hcomplex_capprox: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2455 |
"[| 0 < u; x < u/2; y < u/2; 0 \<le> x; 0 \<le> y |] ==> sqrt (x\<twosuperior> + y\<twosuperior>) < u" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2456 |
apply (rule_tac y = "u/sqrt 2" in order_le_less_trans) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2457 |
apply (erule_tac [2] lemma_real_divide_sqrt_less) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2458 |
apply (rule_tac n = 1 in realpow_increasing) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2459 |
apply (auto simp add: real_0_le_divide_iff realpow_divide numeral_2_eq_2 [symmetric] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2460 |
simp del: realpow_Suc) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2461 |
apply (rule_tac t = "u\<twosuperior>" in real_sum_of_halves [THEN subst]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2462 |
apply (rule add_mono) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2463 |
apply (auto simp add: four_x_squared simp del: realpow_Suc intro: power_mono) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2464 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2465 |
|
16775
c1b87ef4a1c3
added lemmas to OrderedGroup.thy (reasoning about signs, absolute value, triangle inequalities)
avigad
parents:
16641
diff
changeset
|
2466 |
declare real_sqrt_sum_squares_ge_zero [THEN abs_of_nonneg, simp] |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2467 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2468 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2469 |
subsection{*A Few Theorems Involving Ln, Derivatives, etc.*} |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2470 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2471 |
lemma lemma_DERIV_ln: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2472 |
"DERIV ln z :> l ==> DERIV (%x. exp (ln x)) z :> exp (ln z) * l" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2473 |
by (erule DERIV_fun_exp) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2474 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2475 |
lemma STAR_exp_ln: "0 < z ==> ( *f* (%x. exp (ln x))) z = z" |
17318
bc1c75855f3d
starfun, starset, and other functions on NS types are now polymorphic;
huffman
parents:
17298
diff
changeset
|
2476 |
apply (cases z) |
bc1c75855f3d
starfun, starset, and other functions on NS types are now polymorphic;
huffman
parents:
17298
diff
changeset
|
2477 |
apply (auto simp add: starfun star_n_zero_num star_n_less star_n_eq_iff) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2478 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2479 |
|
15229 | 2480 |
lemma hypreal_add_Infinitesimal_gt_zero: |
2481 |
"[|e : Infinitesimal; 0 < x |] ==> 0 < hypreal_of_real x + e" |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2482 |
apply (rule_tac c1 = "-e" in add_less_cancel_right [THEN iffD1]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2483 |
apply (auto intro: Infinitesimal_less_SReal) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2484 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2485 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2486 |
lemma NSDERIV_exp_ln_one: "0 < z ==> NSDERIV (%x. exp (ln x)) z :> 1" |
15229 | 2487 |
apply (simp add: nsderiv_def NSLIM_def, auto) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2488 |
apply (rule ccontr) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2489 |
apply (subgoal_tac "0 < hypreal_of_real z + h") |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2490 |
apply (drule STAR_exp_ln) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2491 |
apply (rule_tac [2] hypreal_add_Infinitesimal_gt_zero) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2492 |
apply (subgoal_tac "h/h = 1") |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2493 |
apply (auto simp add: exp_ln_iff [symmetric] simp del: exp_ln_iff) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2494 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2495 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2496 |
lemma DERIV_exp_ln_one: "0 < z ==> DERIV (%x. exp (ln x)) z :> 1" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2497 |
by (auto intro: NSDERIV_exp_ln_one simp add: NSDERIV_DERIV_iff [symmetric]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2498 |
|
15229 | 2499 |
lemma lemma_DERIV_ln2: |
2500 |
"[| 0 < z; DERIV ln z :> l |] ==> exp (ln z) * l = 1" |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2501 |
apply (rule DERIV_unique) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2502 |
apply (rule lemma_DERIV_ln) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2503 |
apply (rule_tac [2] DERIV_exp_ln_one, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2504 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2505 |
|
15229 | 2506 |
lemma lemma_DERIV_ln3: |
2507 |
"[| 0 < z; DERIV ln z :> l |] ==> l = 1/(exp (ln z))" |
|
2508 |
apply (rule_tac c1 = "exp (ln z)" in real_mult_left_cancel [THEN iffD1]) |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2509 |
apply (auto intro: lemma_DERIV_ln2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2510 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2511 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2512 |
lemma lemma_DERIV_ln4: "[| 0 < z; DERIV ln z :> l |] ==> l = 1/z" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2513 |
apply (rule_tac t = z in exp_ln_iff [THEN iffD2, THEN subst]) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2514 |
apply (auto intro: lemma_DERIV_ln3) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2515 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2516 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2517 |
(* need to rename second isCont_inverse *) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2518 |
|
15229 | 2519 |
lemma isCont_inv_fun: |
2520 |
"[| 0 < d; \<forall>z. \<bar>z - x\<bar> \<le> d --> g(f(z)) = z; |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2521 |
\<forall>z. \<bar>z - x\<bar> \<le> d --> isCont f z |] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2522 |
==> isCont g (f x)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2523 |
apply (simp (no_asm) add: isCont_iff LIM_def) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2524 |
apply safe |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2525 |
apply (drule_tac ?d1.0 = r in real_lbound_gt_zero) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2526 |
apply (assumption, safe) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2527 |
apply (subgoal_tac "\<forall>z. \<bar>z - x\<bar> \<le> e --> (g (f z) = z) ") |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2528 |
prefer 2 apply force |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2529 |
apply (subgoal_tac "\<forall>z. \<bar>z - x\<bar> \<le> e --> isCont f z") |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2530 |
prefer 2 apply force |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2531 |
apply (drule_tac d = e in isCont_inj_range) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2532 |
prefer 2 apply (assumption, assumption, safe) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2533 |
apply (rule_tac x = ea in exI, auto) |
15085
5693a977a767
removed some [iff] declarations from RealDef.thy, concerning inequalities
paulson
parents:
15081
diff
changeset
|
2534 |
apply (drule_tac x = "f (x) + xa" and P = "%y. \<bar>y - f x\<bar> \<le> ea \<longrightarrow> (\<exists>z. \<bar>z - x\<bar> \<le> e \<and> f z = y)" in spec) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2535 |
apply auto |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2536 |
apply (drule sym, auto, arith) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2537 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2538 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2539 |
lemma isCont_inv_fun_inv: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2540 |
"[| 0 < d; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2541 |
\<forall>z. \<bar>z - x\<bar> \<le> d --> g(f(z)) = z; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2542 |
\<forall>z. \<bar>z - x\<bar> \<le> d --> isCont f z |] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2543 |
==> \<exists>e. 0 < e & |
15081 | 2544 |
(\<forall>y. 0 < \<bar>y - f(x)\<bar> & \<bar>y - f(x)\<bar> < e --> f(g(y)) = y)" |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2545 |
apply (drule isCont_inj_range) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2546 |
prefer 2 apply (assumption, assumption, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2547 |
apply (rule_tac x = e in exI, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2548 |
apply (rotate_tac 2) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2549 |
apply (drule_tac x = y in spec, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2550 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2551 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2552 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2553 |
text{*Bartle/Sherbert: Introduction to Real Analysis, Theorem 4.2.9, p. 110*} |
15229 | 2554 |
lemma LIM_fun_gt_zero: |
2555 |
"[| f -- c --> l; 0 < l |] |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2556 |
==> \<exists>r. 0 < r & (\<forall>x. x \<noteq> c & \<bar>c - x\<bar> < r --> 0 < f x)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2557 |
apply (auto simp add: LIM_def) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2558 |
apply (drule_tac x = "l/2" in spec, safe, force) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2559 |
apply (rule_tac x = s in exI) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2560 |
apply (auto simp only: abs_interval_iff) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2561 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2562 |
|
15229 | 2563 |
lemma LIM_fun_less_zero: |
2564 |
"[| f -- c --> l; l < 0 |] |
|
2565 |
==> \<exists>r. 0 < r & (\<forall>x. x \<noteq> c & \<bar>c - x\<bar> < r --> f x < 0)" |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2566 |
apply (auto simp add: LIM_def) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2567 |
apply (drule_tac x = "-l/2" in spec, safe, force) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2568 |
apply (rule_tac x = s in exI) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2569 |
apply (auto simp only: abs_interval_iff) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2570 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2571 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2572 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2573 |
lemma LIM_fun_not_zero: |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2574 |
"[| f -- c --> l; l \<noteq> 0 |] |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2575 |
==> \<exists>r. 0 < r & (\<forall>x. x \<noteq> c & \<bar>c - x\<bar> < r --> f x \<noteq> 0)" |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2576 |
apply (cut_tac x = l and y = 0 in linorder_less_linear, auto) |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2577 |
apply (drule LIM_fun_less_zero) |
15241 | 2578 |
apply (drule_tac [3] LIM_fun_gt_zero) |
2579 |
apply force+ |
|
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2580 |
done |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2581 |
|
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2582 |
ML |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2583 |
{* |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2584 |
val inverse_unique = thm "inverse_unique"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2585 |
val real_root_zero = thm "real_root_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2586 |
val real_root_pow_pos = thm "real_root_pow_pos"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2587 |
val real_root_pow_pos2 = thm "real_root_pow_pos2"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2588 |
val real_root_pos = thm "real_root_pos"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2589 |
val real_root_pos2 = thm "real_root_pos2"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2590 |
val real_root_pos_pos = thm "real_root_pos_pos"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2591 |
val real_root_pos_pos_le = thm "real_root_pos_pos_le"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2592 |
val real_root_one = thm "real_root_one"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2593 |
val root_2_eq = thm "root_2_eq"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2594 |
val real_sqrt_zero = thm "real_sqrt_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2595 |
val real_sqrt_one = thm "real_sqrt_one"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2596 |
val real_sqrt_pow2_iff = thm "real_sqrt_pow2_iff"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2597 |
val real_sqrt_pow2 = thm "real_sqrt_pow2"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2598 |
val real_sqrt_abs_abs = thm "real_sqrt_abs_abs"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2599 |
val real_pow_sqrt_eq_sqrt_pow = thm "real_pow_sqrt_eq_sqrt_pow"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2600 |
val real_pow_sqrt_eq_sqrt_abs_pow2 = thm "real_pow_sqrt_eq_sqrt_abs_pow2"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2601 |
val real_sqrt_pow_abs = thm "real_sqrt_pow_abs"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2602 |
val not_real_square_gt_zero = thm "not_real_square_gt_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2603 |
val real_sqrt_gt_zero = thm "real_sqrt_gt_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2604 |
val real_sqrt_ge_zero = thm "real_sqrt_ge_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2605 |
val sqrt_eqI = thm "sqrt_eqI"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2606 |
val real_sqrt_mult_distrib = thm "real_sqrt_mult_distrib"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2607 |
val real_sqrt_mult_distrib2 = thm "real_sqrt_mult_distrib2"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2608 |
val real_sqrt_sum_squares_ge_zero = thm "real_sqrt_sum_squares_ge_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2609 |
val real_sqrt_sum_squares_mult_ge_zero = thm "real_sqrt_sum_squares_mult_ge_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2610 |
val real_sqrt_sum_squares_mult_squared_eq = thm "real_sqrt_sum_squares_mult_squared_eq"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2611 |
val real_sqrt_abs = thm "real_sqrt_abs"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2612 |
val real_sqrt_abs2 = thm "real_sqrt_abs2"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2613 |
val real_sqrt_pow2_gt_zero = thm "real_sqrt_pow2_gt_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2614 |
val real_sqrt_not_eq_zero = thm "real_sqrt_not_eq_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2615 |
val real_inv_sqrt_pow2 = thm "real_inv_sqrt_pow2"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2616 |
val real_sqrt_eq_zero_cancel = thm "real_sqrt_eq_zero_cancel"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2617 |
val real_sqrt_eq_zero_cancel_iff = thm "real_sqrt_eq_zero_cancel_iff"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2618 |
val real_sqrt_sum_squares_ge1 = thm "real_sqrt_sum_squares_ge1"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2619 |
val real_sqrt_sum_squares_ge2 = thm "real_sqrt_sum_squares_ge2"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2620 |
val real_sqrt_ge_one = thm "real_sqrt_ge_one"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2621 |
val summable_exp = thm "summable_exp"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2622 |
val summable_sin = thm "summable_sin"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2623 |
val summable_cos = thm "summable_cos"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2624 |
val exp_converges = thm "exp_converges"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2625 |
val sin_converges = thm "sin_converges"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2626 |
val cos_converges = thm "cos_converges"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2627 |
val powser_insidea = thm "powser_insidea"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2628 |
val powser_inside = thm "powser_inside"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2629 |
val diffs_minus = thm "diffs_minus"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2630 |
val diffs_equiv = thm "diffs_equiv"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2631 |
val less_add_one = thm "less_add_one"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2632 |
val termdiffs_aux = thm "termdiffs_aux"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2633 |
val termdiffs = thm "termdiffs"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2634 |
val exp_fdiffs = thm "exp_fdiffs"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2635 |
val sin_fdiffs = thm "sin_fdiffs"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2636 |
val sin_fdiffs2 = thm "sin_fdiffs2"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2637 |
val cos_fdiffs = thm "cos_fdiffs"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2638 |
val cos_fdiffs2 = thm "cos_fdiffs2"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2639 |
val DERIV_exp = thm "DERIV_exp"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2640 |
val DERIV_sin = thm "DERIV_sin"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2641 |
val DERIV_cos = thm "DERIV_cos"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2642 |
val exp_zero = thm "exp_zero"; |
17014
ad5ceb90877d
renamed exp_ge_add_one_self to exp_ge_add_one_self_aux
avigad
parents:
16924
diff
changeset
|
2643 |
(* val exp_ge_add_one_self = thm "exp_ge_add_one_self"; *) |
15077
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2644 |
val exp_gt_one = thm "exp_gt_one"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2645 |
val DERIV_exp_add_const = thm "DERIV_exp_add_const"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2646 |
val DERIV_exp_minus = thm "DERIV_exp_minus"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2647 |
val DERIV_exp_exp_zero = thm "DERIV_exp_exp_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2648 |
val exp_add_mult_minus = thm "exp_add_mult_minus"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2649 |
val exp_mult_minus = thm "exp_mult_minus"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2650 |
val exp_mult_minus2 = thm "exp_mult_minus2"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2651 |
val exp_minus = thm "exp_minus"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2652 |
val exp_add = thm "exp_add"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2653 |
val exp_ge_zero = thm "exp_ge_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2654 |
val exp_not_eq_zero = thm "exp_not_eq_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2655 |
val exp_gt_zero = thm "exp_gt_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2656 |
val inv_exp_gt_zero = thm "inv_exp_gt_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2657 |
val abs_exp_cancel = thm "abs_exp_cancel"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2658 |
val exp_real_of_nat_mult = thm "exp_real_of_nat_mult"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2659 |
val exp_diff = thm "exp_diff"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2660 |
val exp_less_mono = thm "exp_less_mono"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2661 |
val exp_less_cancel = thm "exp_less_cancel"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2662 |
val exp_less_cancel_iff = thm "exp_less_cancel_iff"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2663 |
val exp_le_cancel_iff = thm "exp_le_cancel_iff"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2664 |
val exp_inj_iff = thm "exp_inj_iff"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2665 |
val exp_total = thm "exp_total"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2666 |
val ln_exp = thm "ln_exp"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2667 |
val exp_ln_iff = thm "exp_ln_iff"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2668 |
val ln_mult = thm "ln_mult"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2669 |
val ln_inj_iff = thm "ln_inj_iff"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2670 |
val ln_one = thm "ln_one"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2671 |
val ln_inverse = thm "ln_inverse"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2672 |
val ln_div = thm "ln_div"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2673 |
val ln_less_cancel_iff = thm "ln_less_cancel_iff"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2674 |
val ln_le_cancel_iff = thm "ln_le_cancel_iff"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2675 |
val ln_realpow = thm "ln_realpow"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2676 |
val ln_add_one_self_le_self = thm "ln_add_one_self_le_self"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2677 |
val ln_less_self = thm "ln_less_self"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2678 |
val ln_ge_zero = thm "ln_ge_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2679 |
val ln_gt_zero = thm "ln_gt_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2680 |
val ln_less_zero = thm "ln_less_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2681 |
val exp_ln_eq = thm "exp_ln_eq"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2682 |
val sin_zero = thm "sin_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2683 |
val cos_zero = thm "cos_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2684 |
val DERIV_sin_sin_mult = thm "DERIV_sin_sin_mult"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2685 |
val DERIV_sin_sin_mult2 = thm "DERIV_sin_sin_mult2"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2686 |
val DERIV_sin_realpow2 = thm "DERIV_sin_realpow2"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2687 |
val DERIV_sin_realpow2a = thm "DERIV_sin_realpow2a"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2688 |
val DERIV_cos_cos_mult = thm "DERIV_cos_cos_mult"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2689 |
val DERIV_cos_cos_mult2 = thm "DERIV_cos_cos_mult2"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2690 |
val DERIV_cos_realpow2 = thm "DERIV_cos_realpow2"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2691 |
val DERIV_cos_realpow2a = thm "DERIV_cos_realpow2a"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2692 |
val DERIV_cos_realpow2b = thm "DERIV_cos_realpow2b"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2693 |
val DERIV_cos_cos_mult3 = thm "DERIV_cos_cos_mult3"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2694 |
val DERIV_sin_circle_all = thm "DERIV_sin_circle_all"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2695 |
val DERIV_sin_circle_all_zero = thm "DERIV_sin_circle_all_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2696 |
val sin_cos_squared_add = thm "sin_cos_squared_add"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2697 |
val sin_cos_squared_add2 = thm "sin_cos_squared_add2"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2698 |
val sin_cos_squared_add3 = thm "sin_cos_squared_add3"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2699 |
val sin_squared_eq = thm "sin_squared_eq"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2700 |
val cos_squared_eq = thm "cos_squared_eq"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2701 |
val real_gt_one_ge_zero_add_less = thm "real_gt_one_ge_zero_add_less"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2702 |
val abs_sin_le_one = thm "abs_sin_le_one"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2703 |
val sin_ge_minus_one = thm "sin_ge_minus_one"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2704 |
val sin_le_one = thm "sin_le_one"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2705 |
val abs_cos_le_one = thm "abs_cos_le_one"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2706 |
val cos_ge_minus_one = thm "cos_ge_minus_one"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2707 |
val cos_le_one = thm "cos_le_one"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2708 |
val DERIV_fun_pow = thm "DERIV_fun_pow"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2709 |
val DERIV_fun_exp = thm "DERIV_fun_exp"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2710 |
val DERIV_fun_sin = thm "DERIV_fun_sin"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2711 |
val DERIV_fun_cos = thm "DERIV_fun_cos"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2712 |
val DERIV_intros = thms "DERIV_intros"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2713 |
val sin_cos_add = thm "sin_cos_add"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2714 |
val sin_add = thm "sin_add"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2715 |
val cos_add = thm "cos_add"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2716 |
val sin_cos_minus = thm "sin_cos_minus"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2717 |
val sin_minus = thm "sin_minus"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2718 |
val cos_minus = thm "cos_minus"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2719 |
val sin_diff = thm "sin_diff"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2720 |
val sin_diff2 = thm "sin_diff2"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2721 |
val cos_diff = thm "cos_diff"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2722 |
val cos_diff2 = thm "cos_diff2"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2723 |
val sin_double = thm "sin_double"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2724 |
val cos_double = thm "cos_double"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2725 |
val sin_paired = thm "sin_paired"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2726 |
val sin_gt_zero = thm "sin_gt_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2727 |
val sin_gt_zero1 = thm "sin_gt_zero1"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2728 |
val cos_double_less_one = thm "cos_double_less_one"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2729 |
val cos_paired = thm "cos_paired"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2730 |
val cos_two_less_zero = thm "cos_two_less_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2731 |
val cos_is_zero = thm "cos_is_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2732 |
val pi_half = thm "pi_half"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2733 |
val cos_pi_half = thm "cos_pi_half"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2734 |
val pi_half_gt_zero = thm "pi_half_gt_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2735 |
val pi_half_less_two = thm "pi_half_less_two"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2736 |
val pi_gt_zero = thm "pi_gt_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2737 |
val pi_neq_zero = thm "pi_neq_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2738 |
val pi_not_less_zero = thm "pi_not_less_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2739 |
val pi_ge_zero = thm "pi_ge_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2740 |
val minus_pi_half_less_zero = thm "minus_pi_half_less_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2741 |
val sin_pi_half = thm "sin_pi_half"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2742 |
val cos_pi = thm "cos_pi"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2743 |
val sin_pi = thm "sin_pi"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2744 |
val sin_cos_eq = thm "sin_cos_eq"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2745 |
val minus_sin_cos_eq = thm "minus_sin_cos_eq"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2746 |
val cos_sin_eq = thm "cos_sin_eq"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2747 |
val sin_periodic_pi = thm "sin_periodic_pi"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2748 |
val sin_periodic_pi2 = thm "sin_periodic_pi2"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2749 |
val cos_periodic_pi = thm "cos_periodic_pi"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2750 |
val sin_periodic = thm "sin_periodic"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2751 |
val cos_periodic = thm "cos_periodic"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2752 |
val cos_npi = thm "cos_npi"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2753 |
val sin_npi = thm "sin_npi"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2754 |
val sin_npi2 = thm "sin_npi2"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2755 |
val cos_two_pi = thm "cos_two_pi"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2756 |
val sin_two_pi = thm "sin_two_pi"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2757 |
val sin_gt_zero2 = thm "sin_gt_zero2"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2758 |
val sin_less_zero = thm "sin_less_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2759 |
val pi_less_4 = thm "pi_less_4"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2760 |
val cos_gt_zero = thm "cos_gt_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2761 |
val cos_gt_zero_pi = thm "cos_gt_zero_pi"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2762 |
val cos_ge_zero = thm "cos_ge_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2763 |
val sin_gt_zero_pi = thm "sin_gt_zero_pi"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2764 |
val sin_ge_zero = thm "sin_ge_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2765 |
val cos_total = thm "cos_total"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2766 |
val sin_total = thm "sin_total"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2767 |
val reals_Archimedean4 = thm "reals_Archimedean4"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2768 |
val cos_zero_lemma = thm "cos_zero_lemma"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2769 |
val sin_zero_lemma = thm "sin_zero_lemma"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2770 |
val cos_zero_iff = thm "cos_zero_iff"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2771 |
val sin_zero_iff = thm "sin_zero_iff"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2772 |
val tan_zero = thm "tan_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2773 |
val tan_pi = thm "tan_pi"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2774 |
val tan_npi = thm "tan_npi"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2775 |
val tan_minus = thm "tan_minus"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2776 |
val tan_periodic = thm "tan_periodic"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2777 |
val add_tan_eq = thm "add_tan_eq"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2778 |
val tan_add = thm "tan_add"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2779 |
val tan_double = thm "tan_double"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2780 |
val tan_gt_zero = thm "tan_gt_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2781 |
val tan_less_zero = thm "tan_less_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2782 |
val DERIV_tan = thm "DERIV_tan"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2783 |
val LIM_cos_div_sin = thm "LIM_cos_div_sin"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2784 |
val tan_total_pos = thm "tan_total_pos"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2785 |
val tan_total = thm "tan_total"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2786 |
val arcsin_pi = thm "arcsin_pi"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2787 |
val arcsin = thm "arcsin"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2788 |
val sin_arcsin = thm "sin_arcsin"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2789 |
val arcsin_bounded = thm "arcsin_bounded"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2790 |
val arcsin_lbound = thm "arcsin_lbound"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2791 |
val arcsin_ubound = thm "arcsin_ubound"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2792 |
val arcsin_lt_bounded = thm "arcsin_lt_bounded"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2793 |
val arcsin_sin = thm "arcsin_sin"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2794 |
val arcos = thm "arcos"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2795 |
val cos_arcos = thm "cos_arcos"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2796 |
val arcos_bounded = thm "arcos_bounded"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2797 |
val arcos_lbound = thm "arcos_lbound"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2798 |
val arcos_ubound = thm "arcos_ubound"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2799 |
val arcos_lt_bounded = thm "arcos_lt_bounded"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2800 |
val arcos_cos = thm "arcos_cos"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2801 |
val arcos_cos2 = thm "arcos_cos2"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2802 |
val arctan = thm "arctan"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2803 |
val tan_arctan = thm "tan_arctan"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2804 |
val arctan_bounded = thm "arctan_bounded"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2805 |
val arctan_lbound = thm "arctan_lbound"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2806 |
val arctan_ubound = thm "arctan_ubound"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2807 |
val arctan_tan = thm "arctan_tan"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2808 |
val arctan_zero_zero = thm "arctan_zero_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2809 |
val cos_arctan_not_zero = thm "cos_arctan_not_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2810 |
val tan_sec = thm "tan_sec"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2811 |
val DERIV_sin_add = thm "DERIV_sin_add"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2812 |
val cos_2npi = thm "cos_2npi"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2813 |
val cos_3over2_pi = thm "cos_3over2_pi"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2814 |
val sin_2npi = thm "sin_2npi"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2815 |
val sin_3over2_pi = thm "sin_3over2_pi"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2816 |
val cos_pi_eq_zero = thm "cos_pi_eq_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2817 |
val DERIV_cos_add = thm "DERIV_cos_add"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2818 |
val isCont_cos = thm "isCont_cos"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2819 |
val isCont_sin = thm "isCont_sin"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2820 |
val isCont_exp = thm "isCont_exp"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2821 |
val sin_zero_abs_cos_one = thm "sin_zero_abs_cos_one"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2822 |
val exp_eq_one_iff = thm "exp_eq_one_iff"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2823 |
val cos_one_sin_zero = thm "cos_one_sin_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2824 |
val real_root_less_mono = thm "real_root_less_mono"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2825 |
val real_root_le_mono = thm "real_root_le_mono"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2826 |
val real_root_less_iff = thm "real_root_less_iff"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2827 |
val real_root_le_iff = thm "real_root_le_iff"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2828 |
val real_root_eq_iff = thm "real_root_eq_iff"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2829 |
val real_root_pos_unique = thm "real_root_pos_unique"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2830 |
val real_root_mult = thm "real_root_mult"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2831 |
val real_root_inverse = thm "real_root_inverse"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2832 |
val real_root_divide = thm "real_root_divide"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2833 |
val real_sqrt_less_mono = thm "real_sqrt_less_mono"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2834 |
val real_sqrt_le_mono = thm "real_sqrt_le_mono"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2835 |
val real_sqrt_less_iff = thm "real_sqrt_less_iff"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2836 |
val real_sqrt_le_iff = thm "real_sqrt_le_iff"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2837 |
val real_sqrt_eq_iff = thm "real_sqrt_eq_iff"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2838 |
val real_sqrt_sos_less_one_iff = thm "real_sqrt_sos_less_one_iff"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2839 |
val real_sqrt_sos_eq_one_iff = thm "real_sqrt_sos_eq_one_iff"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2840 |
val real_divide_square_eq = thm "real_divide_square_eq"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2841 |
val real_sqrt_sum_squares_gt_zero1 = thm "real_sqrt_sum_squares_gt_zero1"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2842 |
val real_sqrt_sum_squares_gt_zero2 = thm "real_sqrt_sum_squares_gt_zero2"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2843 |
val real_sqrt_sum_squares_gt_zero3 = thm "real_sqrt_sum_squares_gt_zero3"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2844 |
val real_sqrt_sum_squares_gt_zero3a = thm "real_sqrt_sum_squares_gt_zero3a"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2845 |
val cos_x_y_ge_minus_one = thm "cos_x_y_ge_minus_one"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2846 |
val cos_x_y_ge_minus_one1a = thm "cos_x_y_ge_minus_one1a"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2847 |
val cos_x_y_le_one = thm "cos_x_y_le_one"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2848 |
val cos_x_y_le_one2 = thm "cos_x_y_le_one2"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2849 |
val cos_abs_x_y_ge_minus_one = thm "cos_abs_x_y_ge_minus_one"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2850 |
val cos_abs_x_y_le_one = thm "cos_abs_x_y_le_one"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2851 |
val minus_pi_less_zero = thm "minus_pi_less_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2852 |
val arcos_ge_minus_pi = thm "arcos_ge_minus_pi"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2853 |
val sin_x_y_disj = thm "sin_x_y_disj"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2854 |
val cos_x_y_disj = thm "cos_x_y_disj"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2855 |
val real_sqrt_divide_less_zero = thm "real_sqrt_divide_less_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2856 |
val polar_ex1 = thm "polar_ex1"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2857 |
val polar_ex2 = thm "polar_ex2"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2858 |
val polar_Ex = thm "polar_Ex"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2859 |
val real_sqrt_ge_abs1 = thm "real_sqrt_ge_abs1"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2860 |
val real_sqrt_ge_abs2 = thm "real_sqrt_ge_abs2"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2861 |
val real_sqrt_two_gt_zero = thm "real_sqrt_two_gt_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2862 |
val real_sqrt_two_ge_zero = thm "real_sqrt_two_ge_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2863 |
val real_sqrt_two_gt_one = thm "real_sqrt_two_gt_one"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2864 |
val STAR_exp_ln = thm "STAR_exp_ln"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2865 |
val hypreal_add_Infinitesimal_gt_zero = thm "hypreal_add_Infinitesimal_gt_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2866 |
val NSDERIV_exp_ln_one = thm "NSDERIV_exp_ln_one"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2867 |
val DERIV_exp_ln_one = thm "DERIV_exp_ln_one"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2868 |
val isCont_inv_fun = thm "isCont_inv_fun"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2869 |
val isCont_inv_fun_inv = thm "isCont_inv_fun_inv"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2870 |
val LIM_fun_gt_zero = thm "LIM_fun_gt_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2871 |
val LIM_fun_less_zero = thm "LIM_fun_less_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2872 |
val LIM_fun_not_zero = thm "LIM_fun_not_zero"; |
89840837108e
converting Hyperreal/Transcendental to Isar script
paulson
parents:
15013
diff
changeset
|
2873 |
*} |
12196 | 2874 |
|
2875 |
end |