-
Notifications
You must be signed in to change notification settings - Fork 2
/
transcendental.m
55 lines (25 loc) · 1000 Bytes
/
transcendental.m
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
(* Copyright E.M.Clarke and Xudong Zhao, Jan 22, 1991 *)
(* RULES FOR TRANSCENDENTAL FUNCTIONS *)
(* Cos and Sin are everywhere continuous functions. *)
ContinuousFunction[Sin] = True;
ContinuousFunction[Cos] = True;
(* They are also uniformly continuous. *)
UniformlyContinuous[Sin] = True;
UniformlyContinuous[Cos] = True;
(* Cos and Sin are bounded functions *)
Bounded[Cos] = Bounded[Sin] = True;
Bound[Cos] = Bound[Sin] = 1;
(* Simplify argument of function if possible. *)
Unprotect[Cos, Sin];
Cos[x_] := Cos[Factor[x]]/; Factor[x] =!= x;
Sin[x_] := Sin[Factor[x]]/; Factor[x] =!= x;
Protect[Sin, Cos];
inverse[delta[Cos]][a_] := a;
(* Rules for the logarithm function. *)
Unprotect[Log];
Log/: (Log[a_] == Log[b_]) := and[0 < a, a == b];
Log/: (Log[a_] < Log[b_]) := and[0 < a, a < b];
Log/: (Log[a_] <= Log[b_]) := and[0 < a, a <= b];
Log[a_ b_] := Log[a] + Log[b] /; WeakSimplify[and[a>0, b>0]];
Log[a_ ^ b_] := b Log[a] /; WeakSimplify[a>0];
Protect[Log];