[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Axiom-developer] 20081105.01.axj.patch (add reclos2.input)
From: |
daly |
Subject: |
[Axiom-developer] 20081105.01.axj.patch (add reclos2.input) |
Date: |
Thu, 6 Nov 2008 01:03:05 -0600 |
Add more test examples for the Real Closure domain
Add Alejandro Jakubi
=====================================================================
diff --git a/changelog b/changelog
index 1f920ab..fa810a4 100644
--- a/changelog
+++ b/changelog
@@ -1,3 +1,8 @@
+20081105 axj src/input/Makefile reclos2.input added
+20081105 axj src/input/reclos2.input added
+20081105 tpd src/interp/setq.lisp add Alejandro Jakubi
+20081105 tpd readme add Alejandro Jakubi
+20081105 axj Alejandro Jakubi <address@hidden>
20081101 tpd books/bookvol10.2 merge categories
20081101 tpd books/ps/v102squarematrixcategory.ps added
20081101 tpd books/ps/v102rectangularmatrixcategory.ps added
diff --git a/readme b/readme
index be93ed8..8b45ea8 100644
--- a/readme
+++ b/readme
@@ -212,7 +212,7 @@ at the axiom command prompt will prettyprint the list.
"Ralf Hemmecke Henderson Antoine Hersen"
"Gernot Hueber"
"Pietro Iglio"
-"Richard Jenks"
+"Alejandro Jakubi Richard Jenks"
"Kai Kaminski Grant Keady Tony Kennedy"
"Paul Kosinski Klaus Kusche Bernhard Kutzler"
"Larry Lambe Franz Lehner Frederic Lehobey"
diff --git a/src/input/Makefile.pamphlet b/src/input/Makefile.pamphlet
index 8f1549b..81a53b2 100644
--- a/src/input/Makefile.pamphlet
+++ b/src/input/Makefile.pamphlet
@@ -347,7 +347,7 @@ REGRES= algaggr.regress algbrbf.regress algfacob.regress
alist.regress \
poly1.regress polycoer.regress poly.regress psgenfcn.regress \
quat1.regress quat.regress r20abugs.regress r20bugs.regress \
r21bugsbig.regress r21bugs.regress radff.regress radix.regress \
- realclos.regress reclos.regress regset.regress \
+ realclos.regress reclos.regress reclos2.regress regset.regress \
repa6.regress robidoux.regress \
roman.regress roots.regress ruleset.regress rules.regress \
sae.regress \
@@ -636,7 +636,7 @@ FILES= ${OUT}/algaggr.input ${OUT}/algbrbf.input
${OUT}/algfacob.input \
${OUT}/r20bugs.input ${OUT}/r21bugsbig.input \
${OUT}/r21bugs.input \
${OUT}/radff.input ${OUT}/radix.input ${OUT}/realclos.input \
- ${OUT}/reclos.input ${OUT}/regset.input \
+ ${OUT}/reclos.input ${OUT}/reclos2.input ${OUT}/regset.input \
${OUT}/robidoux.input ${OUT}/roman.input ${OUT}/roots.input \
${OUT}/ruleset.input ${OUT}/rules.input ${OUT}/sae.input \
${OUT}/schaum1.input \
@@ -950,8 +950,8 @@ DOCFILES= \
${DOC}/r20bugs.input.dvi ${DOC}/r21bugsbig.input.dvi \
${DOC}/r21bugs.input.dvi ${DOC}/radff.input.dvi \
${DOC}/radix.input.dvi ${DOC}/realclos.input.dvi \
- ${DOC}/reclos.input.dvi ${DOC}/regset.input.dvi \
- ${DOC}/reductio.input.dvi \
+ ${DOC}/reclos.input.dvi ${DOC}/reclos2.input.dvi \
+ ${DOC}/regset.input.dvi ${DOC}/reductio.input.dvi \
${DOC}/regset.input.dvi ${DOC}/repa6.input.dvi \
${DOC}/ribbon.input.dvi ${DOC}/ribbons.input.dvi \
${DOC}/ribbonsnew.input.dvi ${DOC}/rk4draw.input.dvi \
diff --git a/src/input/reclos2.input.pamphlet b/src/input/reclos2.input.pamphlet
new file mode 100644
index 0000000..9d49052
--- /dev/null
+++ b/src/input/reclos2.input.pamphlet
@@ -0,0 +1,607 @@
+\documentclass{article}
+\usepackage{axiom}
+\begin{document}
+\title{\$SPAD/src/input reclos2.input}
+\author{Alejandro Jakubi, Francois Maltey, Martin Rubey and Bill Page}
+\maketitle
+\begin{abstract}
+\end{abstract}
+\eject
+\tableofcontents
+\eject
+<<*>>=
+)spool reclos2.output
+)set message test on
+)set message auto off
+)clear all
+--S 1 of 31
+LR:=radicalSolve(p^3-p+1/10=0,p)
+--R
+--R (1)
+--R +------------------+2
+--R | +-+ +-----+
+--R +---+ |- 3\|3 + \|- 373
+--R (- 3\|- 3 + 3) |------------------ - 2
+--R 3| +-+
+--R \| 60\|3
+--R [p= -----------------------------------------,
+--R +------------------+
+--R | +-+ +-----+
+--R +---+ |- 3\|3 + \|- 373
+--R (3\|- 3 + 3) |------------------
+--R 3| +-+
+--R \| 60\|3
+--R +------------------+2
+--R | +-+ +-----+
+--R +---+ |- 3\|3 + \|- 373
+--R (- 3\|- 3 - 3) |------------------ + 2
+--R 3| +-+
+--R \| 60\|3
+--R p= -----------------------------------------,
+--R +------------------+
+--R | +-+ +-----+
+--R +---+ |- 3\|3 + \|- 373
+--R (3\|- 3 - 3) |------------------
+--R 3| +-+
+--R \| 60\|3
+--R +------------------+2
+--R | +-+ +-----+
+--R |- 3\|3 + \|- 373
+--R 3 |------------------ + 1
+--R 3| +-+
+--R \| 60\|3
+--R p= ---------------------------]
+--R +------------------+
+--R | +-+ +-----+
+--R |- 3\|3 + \|- 373
+--R 3 |------------------
+--R 3| +-+
+--R \| 60\|3
+--R Type: List Equation Expression
Integer
+--E 1
+
+--S 2 of 31
+t2:=map(eq +-> (rhs eq)::Complex Float,LR)
+--R
+--R (2)
+--R [0.1010312578 8101081769 - 0.6 E -20 %i, - 1.0466805318 046022612,
+--R 0.9456492739 2359144347 + 0.3 E -20 %i]
+--R Type: List Complex
Float
+--E 2
+
+--S 3 of 31
+t3:=reduce('+, map (eq +-> (rhs eq)::Complex Float, LR))
+--R
+--R (3) 0.3 E -20 - 0.2 E -20 %i
+--R Type: Complex
Float
+--E 3
+
+--S 4 of 31
+t4:=reduce('*, map (eq +-> (rhs eq)::Complex Float, LR))
+--R
+--R (4) - 0.0999999999 9999999999 8 + 0.5405624429 3105340769 E -20 %i
+--R Type: Complex
Float
+--E 4
+
+--S 5 of 31
+t5:=map(eq +-> numeric real rhs eq, LR)
+--R
+--R (5)
+--R [- 0.9456492739 2359144347,- 0.1010312578 8101081769,1.0466805318
046022612]
+--R Type: List
Float
+--E 5
+
+--S 6 of 31
+t6:=map(eq +-> numeric imag rhs eq, LR)
+--R
+--R (6) [0.4890347001 0975238235 E -21,- 0.4890347001 0975238235 E -21,0.0]
+--R Type: List
Float
+--E 6
+
+--S 7 of 31
+t7:=numeric(sqrt(3)::Complex EXPR INT)
+--R
+--R (7) 1.7320508075 688772935
+--R Type:
Float
+--E 7
+
+--S 8 of 31
+t8:=discriminant(p^3-p+1/10)
+--R
+--R 373
+--R (8) ---
+--R 100
+--R Type: Fraction
Integer
+--E 8
+
+--S 9 of 31
+t9:=select(p+->rhs(p)::AlgebraicNumber > 0, radicalSolve(p^3-p+1/10=0,p))
+--R
+--R +------------------+2
+--R | +-+ +-----+
+--R +---+ |- 3\|3 + \|- 373
+--R (- 3\|- 3 - 3) |------------------ + 2
+--R 3| +-+
+--R \| 60\|3
+--R (9) [p= -----------------------------------------]
+--R +------------------+
+--R | +-+ +-----+
+--R +---+ |- 3\|3 + \|- 373
+--R (3\|- 3 - 3) |------------------
+--R 3| +-+
+--R \| 60\|3
+--R Type: List Equation Expression
Integer
+--E 9
+
+--S 10 of 31
+t10:=complexNumeric rhs t9.1
+--R
+--R (10) - 1.0466805318 046022612
+--R Type: Complex
Float
+--E 10
+
+@
+Note that the comparison relation in AlgebraicNumber is not
+based on numeric value but on hash values.
+<<*>>=
+--S 11 of 31
+t11:=select(p+->rhs(p)::AN < 0, radicalSolve(p^2-p+1/10=0,p))
+--R
+--R +--+
+--R - \|15 + 5
+--R (11) [p= -----------]
+--R 10
+--R Type: List Equation Expression
Integer
+--E 11
+
+--S 12 of 31
+t12:=p^3-p+1/10
+--R
+--R 3 1
+--R (12) p - p + --
+--R 10
+--R Type: Polynomial Fraction
Integer
+--E 12
+
+--S 13 of 31
+t13:=select(positive?,allRootsOf(t12)$RealClosure(Fraction Integer))
+--R
+--I (13) [%B2,%B3]
+--R Type: List RealClosure Fraction
Integer
+--E 13
+
+--S 14 of 31
+t14:=approximate(t13.1,1/10^20)::Float
+--R
+--R (14) 0.1010312578 8101081769
+--R Type:
Float
+--E 14
+
+--S 15 of 31
+t15:=eval(t12,p=t14)
+--R
+--R (15) 0.3 E -20
+--R Type: Polynomial
Float
+--E 15
+
+--S 16 of 31
+t16:=approximate(t13.2,1/10^20)::Float
+--R
+--R (16) 0.9456492739 2359144347
+--R Type:
Float
+--E 16
+
+--S 17 of 31
+t17:=eval(t12,p=t16)
+--R
+--R (17) 0.1 E -20
+--R Type: Polynomial
Float
+--E 17
+
+)clear all
+--S 18 of 31
+t1:=(x^3+x^2-4*x-4)/(2*x^2+7*x-4)
+--R
+--R 3 2
+--R x + x - 4x - 4
+--R (1) ----------------
+--R 2
+--R 2x + 7x - 4
+--R Type: Fraction Polynomial
Integer
+--E 18
+
+--S 19 of 31
+t2:=differentiate(t1,x)
+--R
+--R 4 3 2
+--R 2x + 14x + 3x + 8x + 44
+--R (2) ----------------------------
+--R 4 3 2
+--R 4x + 28x + 33x - 56x + 16
+--R Type: Fraction Polynomial
Integer
+--E 19
+
+--S 20 of 31
+t3:=allRootsOf(numer t2)$RealClosure(Fraction Integer)
+--R
+--I (3) [%B4,%B5]
+--R Type: List RealClosure Fraction
Integer
+--E 20
+
+--S 21 of 31
+t4:=approximate(t3.1,1/10^20)::Float
+--R
+--R (4) - 6.7957899636 620037966
+--R Type:
Float
+--E 21
+
+--S 22 of 31
+t5:=eval(t2,x=t4)
+--R
+--R (5) 0.3908839188 6520300529 E -20
+--R Type: Fraction Polynomial
Float
+--E 22
+
+--S 23 of 31
+t6:=approximate(t3.2,1/10^20)::Float
+--R
+--R (6) - 1.5241463459 294127043
+--R Type:
Float
+--E 23
+
+--S 24 of 31
+t7:=eval(t2,x=t6)
+--R
+--R (7) - 0.2158472497 0513415786 E -20
+--R Type: Fraction Polynomial
Float
+--E 24
+
+)clear all
+
+--S 25 of 31
+t1:=(x^3+x^2-4*x-4)/(2*x^2+7*x-4)
+--R
+--R 3 2
+--R x + x - 4x - 4
+--R (1) ----------------
+--R 2
+--R 2x + 7x - 4
+--R Type: Fraction Polynomial
Integer
+--E 25
+
+--S 26 of 31
+t2:=differentiate(t1,x)
+--R
+--R 4 3 2
+--R 2x + 14x + 3x + 8x + 44
+--R (2) ----------------------------
+--R 4 3 2
+--R 4x + 28x + 33x - 56x + 16
+--R Type: Fraction Polynomial
Integer
+--E 26
+
+--S 27 of 31
+t3:=allRootsOf(numer t2)$RealClosure(Fraction Integer)
+--R
+--I (3) [%B6,%B7]
+--R Type: List RealClosure Fraction
Integer
+--E 27
+
+--S 28 of 31
+t4:=radicalSolve(t2)
+--R
+--R (4)
+--R [
+--R x =
+--R -
+--R 2
+--R *
+--R ROOT
+--R +----------------+2 +----------------+
+--R 3| +---+ 3| +---+
+--R (- 2\|324\|145 + 3969 + 90\|324\|145 + 3969 -
162)
+--R *
+--R
+---------------------------------------------------+
+--R | +----------------+2 +----------------+
+--R | 3| +---+ 3| +---+
+--R |2\|324\|145 + 3969 + 45\|324\|145 + 3969 +
162
+--R
|---------------------------------------------------
+--R | +----------------+
+--R | 3| +---+
+--R \| 4\|324\|145 + 3969
+--R +
+--R +----------------+
+--R 3| +---+
+--R - 333\|324\|145 + 3969
+--R /
+--R +----------------+
+--R 3| +---+
+--R 4\|324\|145 + 3969
+--R *
+--R
+---------------------------------------------------+
+--R | +----------------+2 +----------------+
+--R | 3| +---+ 3| +---+
+--R |2\|324\|145 + 3969 + 45\|324\|145 + 3969 + 162
+--R |---------------------------------------------------
+--R | +----------------+
+--R | 3| +---+
+--R \| 4\|324\|145 + 3969
+--R +
+--R +---------------------------------------------------+
+--R | +----------------+2 +----------------+
+--R | 3| +---+ 3| +---+
+--R |2\|324\|145 + 3969 + 45\|324\|145 + 3969 + 162
+--R 2 |--------------------------------------------------- - 7
+--R | +----------------+
+--R | 3| +---+
+--R \| 4\|324\|145 + 3969
+--R /
+--R 4
+--R ,
+--R
+--R x =
+--R 2
+--R *
+--R ROOT
+--R +----------------+2 +----------------+
+--R 3| +---+ 3| +---+
+--R (- 2\|324\|145 + 3969 + 90\|324\|145 + 3969 -
162)
+--R *
+--R +---------------------------------------------------+
+--R | +----------------+2 +----------------+
+--R | 3| +---+ 3| +---+
+--R |2\|324\|145 + 3969 + 45\|324\|145 + 3969 + 162
+--R |---------------------------------------------------
+--R | +----------------+
+--R | 3| +---+
+--R \| 4\|324\|145 + 3969
+--R +
+--R +----------------+
+--R 3| +---+
+--R - 333\|324\|145 + 3969
+--R /
+--R +----------------+
+--R 3| +---+
+--R 4\|324\|145 + 3969
+--R *
+--R +---------------------------------------------------+
+--R | +----------------+2 +----------------+
+--R | 3| +---+ 3| +---+
+--R |2\|324\|145 + 3969 + 45\|324\|145 + 3969 + 162
+--R |---------------------------------------------------
+--R | +----------------+
+--R | 3| +---+
+--R \| 4\|324\|145 + 3969
+--R +
+--R +---------------------------------------------------+
+--R | +----------------+2 +----------------+
+--R | 3| +---+ 3| +---+
+--R |2\|324\|145 + 3969 + 45\|324\|145 + 3969 + 162
+--R 2 |--------------------------------------------------- - 7
+--R | +----------------+
+--R | 3| +---+
+--R \| 4\|324\|145 + 3969
+--R /
+--R 4
+--R ,
+--R
+--R x =
+--R -
+--R 2
+--R *
+--R ROOT
+--R +----------------+2 +----------------+
+--R 3| +---+ 3| +---+
+--R (- 2\|324\|145 + 3969 + 90\|324\|145 + 3969 -
162)
+--R *
+--R
+---------------------------------------------------+
+--R | +----------------+2 +----------------+
+--R | 3| +---+ 3| +---+
+--R |2\|324\|145 + 3969 + 45\|324\|145 + 3969 +
162
+--R
|---------------------------------------------------
+--R | +----------------+
+--R | 3| +---+
+--R \| 4\|324\|145 + 3969
+--R +
+--R +----------------+
+--R 3| +---+
+--R 333\|324\|145 + 3969
+--R /
+--R +----------------+
+--R 3| +---+
+--R 4\|324\|145 + 3969
+--R *
+--R
+---------------------------------------------------+
+--R | +----------------+2 +----------------+
+--R | 3| +---+ 3| +---+
+--R |2\|324\|145 + 3969 + 45\|324\|145 + 3969 + 162
+--R |---------------------------------------------------
+--R | +----------------+
+--R | 3| +---+
+--R \| 4\|324\|145 + 3969
+--R +
+--R +---------------------------------------------------+
+--R | +----------------+2 +----------------+
+--R | 3| +---+ 3| +---+
+--R |2\|324\|145 + 3969 + 45\|324\|145 + 3969 + 162
+--R - 2 |--------------------------------------------------- - 7
+--R | +----------------+
+--R | 3| +---+
+--R \| 4\|324\|145 + 3969
+--R /
+--R 4
+--R ,
+--R
+--R x =
+--R 2
+--R *
+--R ROOT
+--R +----------------+2 +----------------+
+--R 3| +---+ 3| +---+
+--R (- 2\|324\|145 + 3969 + 90\|324\|145 + 3969 -
162)
+--R *
+--R +---------------------------------------------------+
+--R | +----------------+2 +----------------+
+--R | 3| +---+ 3| +---+
+--R |2\|324\|145 + 3969 + 45\|324\|145 + 3969 + 162
+--R |---------------------------------------------------
+--R | +----------------+
+--R | 3| +---+
+--R \| 4\|324\|145 + 3969
+--R +
+--R +----------------+
+--R 3| +---+
+--R 333\|324\|145 + 3969
+--R /
+--R +----------------+
+--R 3| +---+
+--R 4\|324\|145 + 3969
+--R *
+--R +---------------------------------------------------+
+--R | +----------------+2 +----------------+
+--R | 3| +---+ 3| +---+
+--R |2\|324\|145 + 3969 + 45\|324\|145 + 3969 + 162
+--R |---------------------------------------------------
+--R | +----------------+
+--R | 3| +---+
+--R \| 4\|324\|145 + 3969
+--R +
+--R +---------------------------------------------------+
+--R | +----------------+2 +----------------+
+--R | 3| +---+ 3| +---+
+--R |2\|324\|145 + 3969 + 45\|324\|145 + 3969 + 162
+--R - 2 |--------------------------------------------------- - 7
+--R | +----------------+
+--R | 3| +---+
+--R \| 4\|324\|145 + 3969
+--R /
+--R 4
+--R ]
+--R Type: List Equation Expression
Integer
+--E 28
+
+--S 29 of 31
+bound?(x,s) == (a:=complexNumeric rhs x; imag a < 10^-digits() and real a >=
left(mainCharacterization s)::Float and real a < right(mainCharacterization
s)::Float)
+--R Type:
Void
+--E 29
+
+--S 30 of 31
+t6:=[ (B:=select(x+->bound?(x,s),t4); #B=1 => B.1; error "failed") for s in t3
]
+--R Compiling function bound? with type (Equation Expression Integer,
+--R RealClosure Fraction Integer) -> Boolean
+--R
+--R (6)
+--R [
+--R x =
+--R -
+--R 2
+--R *
+--R ROOT
+--R +----------------+2 +----------------+
+--R 3| +---+ 3| +---+
+--R (- 2\|324\|145 + 3969 + 90\|324\|145 + 3969 -
162)
+--R *
+--R
+---------------------------------------------------+
+--R | +----------------+2 +----------------+
+--R | 3| +---+ 3| +---+
+--R |2\|324\|145 + 3969 + 45\|324\|145 + 3969 +
162
+--R
|---------------------------------------------------
+--R | +----------------+
+--R | 3| +---+
+--R \| 4\|324\|145 + 3969
+--R +
+--R +----------------+
+--R 3| +---+
+--R 333\|324\|145 + 3969
+--R /
+--R +----------------+
+--R 3| +---+
+--R 4\|324\|145 + 3969
+--R *
+--R
+---------------------------------------------------+
+--R | +----------------+2 +----------------+
+--R | 3| +---+ 3| +---+
+--R |2\|324\|145 + 3969 + 45\|324\|145 + 3969 + 162
+--R |---------------------------------------------------
+--R | +----------------+
+--R | 3| +---+
+--R \| 4\|324\|145 + 3969
+--R +
+--R +---------------------------------------------------+
+--R | +----------------+2 +----------------+
+--R | 3| +---+ 3| +---+
+--R |2\|324\|145 + 3969 + 45\|324\|145 + 3969 + 162
+--R - 2 |--------------------------------------------------- - 7
+--R | +----------------+
+--R | 3| +---+
+--R \| 4\|324\|145 + 3969
+--R /
+--R 4
+--R ,
+--R
+--R x =
+--R 2
+--R *
+--R ROOT
+--R +----------------+2 +----------------+
+--R 3| +---+ 3| +---+
+--R (- 2\|324\|145 + 3969 + 90\|324\|145 + 3969 -
162)
+--R *
+--R +---------------------------------------------------+
+--R | +----------------+2 +----------------+
+--R | 3| +---+ 3| +---+
+--R |2\|324\|145 + 3969 + 45\|324\|145 + 3969 + 162
+--R |---------------------------------------------------
+--R | +----------------+
+--R | 3| +---+
+--R \| 4\|324\|145 + 3969
+--R +
+--R +----------------+
+--R 3| +---+
+--R 333\|324\|145 + 3969
+--R /
+--R +----------------+
+--R 3| +---+
+--R 4\|324\|145 + 3969
+--R *
+--R +---------------------------------------------------+
+--R | +----------------+2 +----------------+
+--R | 3| +---+ 3| +---+
+--R |2\|324\|145 + 3969 + 45\|324\|145 + 3969 + 162
+--R |---------------------------------------------------
+--R | +----------------+
+--R | 3| +---+
+--R \| 4\|324\|145 + 3969
+--R +
+--R +---------------------------------------------------+
+--R | +----------------+2 +----------------+
+--R | 3| +---+ 3| +---+
+--R |2\|324\|145 + 3969 + 45\|324\|145 + 3969 + 162
+--R - 2 |--------------------------------------------------- - 7
+--R | +----------------+
+--R | 3| +---+
+--R \| 4\|324\|145 + 3969
+--R /
+--R 4
+--R ]
+--R Type: List Equation Expression
Integer
+--E 30
+
+--S 31 of 31
+t7:=map(x+->real complexNumeric rhs x,t6)
+--R
+--R (7) [- 6.7957899636 620037966,- 1.5241463459 294127044]
+--R Type: List
Float
+--E 31
+
+)spool
+)lisp (bye)
+
+@
+\eject
+\begin{thebibliography}{99}
+\bibitem{1} nothing
+\end{thebibliography}
+\end{document}
+
+
diff --git a/src/interp/setq.lisp.pamphlet b/src/interp/setq.lisp.pamphlet
index 37b7fba..67675f2 100644
--- a/src/interp/setq.lisp.pamphlet
+++ b/src/interp/setq.lisp.pamphlet
@@ -623,7 +623,7 @@
"Ralf Hemmecke Henderson Antoine Hersen"
"Gernot Hueber"
"Pietro Iglio"
-"Richard Jenks"
+"Alejandro Jakubi Richard Jenks"
"Kai Kaminski Grant Keady Tony Kennedy"
"Paul Kosinski Klaus Kusche Bernhard Kutzler"
"Larry Lambe Franz Lehner Frederic Lehobey"
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Axiom-developer] 20081105.01.axj.patch (add reclos2.input),
daly <=