diff options
author | dos-reis <gdr@axiomatics.org> | 2007-08-14 05:14:52 +0000 |
---|---|---|
committer | dos-reis <gdr@axiomatics.org> | 2007-08-14 05:14:52 +0000 |
commit | ab8cc85adde879fb963c94d15675783f2cf4b183 (patch) | |
tree | c202482327f474583b750b2c45dedfc4e4312b1d /src/input/algfacob.input.pamphlet | |
download | open-axiom-ab8cc85adde879fb963c94d15675783f2cf4b183.tar.gz |
Initial population.
Diffstat (limited to 'src/input/algfacob.input.pamphlet')
-rw-r--r-- | src/input/algfacob.input.pamphlet | 75 |
1 files changed, 75 insertions, 0 deletions
diff --git a/src/input/algfacob.input.pamphlet b/src/input/algfacob.input.pamphlet new file mode 100644 index 00000000..5700a359 --- /dev/null +++ b/src/input/algfacob.input.pamphlet @@ -0,0 +1,75 @@ +\documentclass{article} +\usepackage{axiom} +\begin{document} +\title{\$SPAD/src/input algfacob.input} +\author{The Axiom Team} +\maketitle +\begin{abstract} +\end{abstract} +\eject +\tableofcontents +\eject +\section{License} +<<license>>= +--Copyright The Numerical Algorithms Group Limited 1991. +@ +<<*>>= +<<license>> + +-- Examples used in Algebra document: ALGFACOB SCRIPT +)set history on +)clear all + +-- The Algebra of Factored Integers + +(w,x,y,z): FR INT +x := 2**8 * 78**7 * 111**3 * 74534 +y := nilFactor(2,10) * nilFactor(3,20) * nilFactor(5,30) +x*y +w := x+y +expand w +f := x/y +g := (x**9)/y +f*g +h := (f*g)/(g*nilFactor(2,200)) +)clear all + +-- The Algebra of Factored Polynomials + +(u,v,w) : FR POLY INT +u := factor (x**4 - y**4) +v := nilFactor(x-y,2) * nilFactor(x+y,2) * nilFactor(x**2 + y**2,1) +w := factor(x**2 + 2*x*y + 2*x + 2*y + y**2 + 1) * nilFactor(x-y,2) +nthFactor(u,1) +nthFactor(u,2) +nthFactor(u,3) +nthFactor(u,4) +gcd(u,v) +u + v +lcm(u,v) +u * v * w +expand % +u/w +w/(u*v) +%%(-1) * %%(-2) +%%(-1) + %%(-2) +)clear all + +-- Some Notes on Using Factored Objects + +f : FR INT := 144000 +nthFactor(f,1) +nthExponent(f,1) +nthFlag(f,1) +nthFlag(nilFactor(20,4),1) +nthFlag(primeFactor(7,9),1) +factors f +numberOfFactors f +f +reduce(*,[nthFactor(f,i) :: (FR INT) for i in 1..numberOfFactors(f)]) +@ +\eject +\begin{thebibliography}{99} +\bibitem{1} nothing +\end{thebibliography} +\end{document} |