blob: 626cb51b7d19b53b5c25b53717af6c85d40d2daa (
plain)
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
|
\documentclass{article}
\usepackage{axiom}
\begin{document}
\title{\$SPAD/src/input ruleset.input}
\author{The Axiom Team}
\maketitle
\begin{abstract}
\end{abstract}
\eject
\tableofcontents
\eject
\section{License}
<<license>>=
--Copyright The Numerical Algorithms Group Limited 1991.
@
<<*>>=
<<license>>
)cl all
-- This is the example from "Programming in Mathematica", p.139
TrigLinearRules := rule
sin(x) * sin(y) == cos(x-y)/2 - cos(x+y)/2
cos(x) * cos(y) == cos(x+y)/2 + cos(x-y)/2
sin(x) * cos(y) == sin(x+y)/2 + sin(x-y)/2
sin(x)**(n | integer? n and n > 0) == (1-cos(2*x))/2 * sin(x)**(n-2)
cos(x)**(n | integer? n and n > 0) == (1+cos(2*x))/2 * cos(x)**(n-2)
sin(a)*cos(b) + sin(a)*cos(a) + cos(2*a)*cos(3*a)
TrigLinearRules %
sin(a) * sin(2*a) * sin(3*a) * sin(4*a)
TrigLinearRules %
-- Defining an operator to be linear w.r.t. its 2nd argument
f := operator 'f
FLinearRules := rule
f(a + b, x) == f(a, x) + f(b, x)
f(c * a, x | freeOf?(c, x)) == c * f(a, x)
f(2*x + a * log(x) + x * log(x), x)
FLinearRules %
@
\eject
\begin{thebibliography}{99}
\bibitem{1} nothing
\end{thebibliography}
\end{document}
|