diff --git a/books/bookvol10.3.pamphlet b/books/bookvol10.3.pamphlet index c06b626..86a4b55 100644 --- a/books/bookvol10.3.pamphlet +++ b/books/bookvol10.3.pamphlet @@ -141977,10 +141977,10 @@ o )show U32Vector ++ is 0 based, there is no bound checking (unless provided by ++ lower level). U32Vector() : OneDimensionalArrayAggregate Integer == add - Qsize ==> QV32LEN$Lisp - Qelt ==> ELT32$Lisp - Qsetelt ==> SETELT32$Lisp - Qnew ==> MAKE_-ARRAY32$Lisp + Qsize ==> QVLENU32$Lisp + Qelt ==> ELTU32$Lisp + Qsetelt ==> SETELTU32$Lisp + Qnew ==> GETREFVU32$Lisp #x == Qsize x minIndex x == 0 diff --git a/books/bookvol5.pamphlet b/books/bookvol5.pamphlet index 3d91d00..531af95 100644 --- a/books/bookvol5.pamphlet +++ b/books/bookvol5.pamphlet @@ -39281,27 +39281,33 @@ Given a form, $u$, we try to recover the input line that created it. \end{chunk} -\defmacro{qv32len} -\begin{chunk}{defmacro qv32len} -(defmacro qv32len (v) +\defmacro{qvlenU32} +\begin{chunk}{defmacro qvlenU32} +(defmacro qvlenU32 (v) `(length (the (simple-array (unsigned-byte 32) (*)) ,v))) \end{chunk} -\defmacro{elt32} -\begin{chunk}{defmacro elt32} -(defmacro elt32 (v i) +\defmacro{eltU32} +\begin{chunk}{defmacro eltU32} +(defmacro eltU32 (v i) `(aref (the (simple-array (unsigned-byte 32) (*)) ,v) ,i)) \end{chunk} -\defmacro{setelt32} -\begin{chunk}{defmacro setelt32} -(defmacro setelt32 (v i s) +\defmacro{seteltU32} +\begin{chunk}{defmacro seteltU32} +(defmacro seteltU32 (v i s) `(setf (aref (the (simple-array (unsigned-byte 32) (*)) ,v) ,i), s)) \end{chunk} +\defun{getRefvU32}{getRefvU32} +\begin{chunk}{defun getRefvU32} +(defun getRefvU32 (x n) + (make-array n :initial-element x :element-type '(unsigned-byte 32))) +\end{chunk} + \section{DirectProduct} \defun{vec2list}{vec2list} \begin{chunk}{defun vec2list} @@ -43845,7 +43851,7 @@ This needs to work off the internal exposure list, not the file. \getchunk{defmacro dlen} \getchunk{defmacro dsetaref2} \getchunk{defmacro dsetelt} -\getchunk{defmacro elt32} +\getchunk{defmacro eltU32} \getchunk{defmacro funfind} \getchunk{defmacro hget} \getchunk{defmacro make-cdouble-matrix} @@ -43854,10 +43860,10 @@ This needs to work off the internal exposure list, not the file. \getchunk{defmacro make-double-matrix1} \getchunk{defmacro make-double-vector} \getchunk{defmacro make-double-vector1} -\getchunk{defmacro qv32len} +\getchunk{defmacro qvlenU32} \getchunk{defmacro Rest} \getchunk{defmacro startsId?} -\getchunk{defmacro setelt32} +\getchunk{defmacro seteltU32} \getchunk{defmacro trapNumericErrors} \getchunk{defmacro truth-to-bit} \getchunk{defmacro while} @@ -44512,6 +44518,7 @@ This needs to work off the internal exposure list, not the file. \getchunk{defun mac0SubstituteOuter} \getchunk{defun make-appendstream} \getchunk{defun make-databases} +\getchunk{defun getRefvU32} \getchunk{defun makeFullNamestring} \getchunk{defun makeHistFileName} \getchunk{defun makeInputFilename} diff --git a/changelog b/changelog index 1e20baf..188ef85 100644 --- a/changelog +++ b/changelog @@ -1,3 +1,8 @@ +20130221 tpd src/axiom-website/patches.html 20130221.01.tpd.patch +20130221 tpd src/input/Makefile add machinearithmetic.input +20130221 tpd books/bookvol5 support macros for U32Vector +20130221 tpd books/bookvol10.3 update U32Vector domain +20130221 tpd src/input/machinearithmetic.input unit test fast accessors 20130216 tpd src/axiom-website/patches.html 20130216.02.tpd.patch 20130216 tpd src/algebra/Makefile compile MAGCDOC 20130216 tpd books/bookvol5 expose MAGCDOC diff --git a/src/axiom-website/patches.html b/src/axiom-website/patches.html index 3c75a15..040e547 100644 --- a/src/axiom-website/patches.html +++ b/src/axiom-website/patches.html @@ -3975,5 +3975,7 @@ src/input/rsa.input added books/bookvol10.2 add matrix initializer function 20130216.02.tpd.patch books/bookvol10.2 add MAGCDOC +20130221.01.tpd.patch +books/bookvol10.3 update U32Vector domain, add machinearithmetic diff --git a/src/input/Makefile.pamphlet b/src/input/Makefile.pamphlet index 5161f80..593c53b 100644 --- a/src/input/Makefile.pamphlet +++ b/src/input/Makefile.pamphlet @@ -358,6 +358,7 @@ REGRESSTESTS= ackermann.regress \ lodo2.regress lodo3.regress lodof.regress lodo.regress \ log.regress \ lpoly.regress lupfact.regress lword.regress macbug.regress \ + machinearithmetic.regress \ macros.regress magma.regress manuel.regress mapleok.regress \ matbug.regress mathml.regress \ matrix1.regress matrix22.regress matrix.regress \ @@ -730,6 +731,7 @@ FILES= ${OUT}/ackermann.input \ ${OUT}/lodo.input ${OUT}/lodo3.input ${OUT}/log.input \ ${OUT}/lpoly.input ${OUT}/lump.input \ ${OUT}/lupfact.input ${OUT}/lword.input ${OUT}/macbug.input \ + ${OUT}/machinearithmetic.input \ ${OUT}/macros.input ${OUT}/marcbench.input ${OUT}/magma.input \ ${OUT}/manuel.input ${OUT}/mapleok.input ${OUT}/matbug.input \ ${OUT}/mathml.input \ @@ -1111,6 +1113,7 @@ DOCFILES= \ ${DOC}/loop.input.dvi ${DOC}/lpoly.input.dvi \ ${DOC}/lump.input.dvi ${DOC}/lupfact.input.dvi \ ${DOC}/lword.input.dvi ${DOC}/macbug.input.dvi \ + ${DOC}/machinearithmetic.input.dvi \ ${DOC}/macros.input.dvi ${DOC}/magma.input.dvi \ ${DOC}/manuel.input.dvi ${DOC}/mapleok.input.dvi \ ${DOC}/marcbench.input.dvi ${DOC}/matbug.input.dvi \ diff --git a/src/input/machinearithmetic.input.pamphlet b/src/input/machinearithmetic.input.pamphlet new file mode 100644 index 0000000..48af66e --- /dev/null +++ b/src/input/machinearithmetic.input.pamphlet @@ -0,0 +1,106 @@ +\documentclass{article} +\usepackage{axiom} +\setlength{\textwidth}{400pt} +\begin{document} +\title{\$SPAD/src/input machinearithmetic.input} +\author{Timothy Daly} +\maketitle +\begin{abstract} +\end{abstract} +\eject +\tableofcontents +\eject +\begin{chunk}{*} +)set break resume +)sys rm -f machinearithmetic.output +)spool machinearithmetic.output +)set message test on +)set message auto off +)clear all + +--S 1 of 11 +t1:=empty()$U32Vector +--R +--R (1) [] +--R Type: U32Vector +--E 1 + +--S 2 of 11 +t2:=new(10,10)$U32Vector +--R +--R (2) [10,10,10,10,10,10,10,10,10,10] +--R Type: U32Vector +--E 2 + +--S 3 of 11 +t3:=qelt(t2,2) +--R +--R (3) 10 +--R Type: PositiveInteger +--E 3 + +--S 4 of 11 +t4:=elt(t2,2) +--R +--R (4) 10 +--R Type: PositiveInteger +--E 4 + +--S 5 of 11 +t5:=t2.2 +--R +--R (5) 10 +--R Type: PositiveInteger +--E 5 + +--S 6 of 11 +t6:=qsetelt!(t2,2,5) +--R +--R (6) 5 +--R Type: PositiveInteger +--E 6 + +--S 7 of 11 +t2.2 +--R +--R (7) 5 +--R Type: PositiveInteger +--E 7 + +--S 8 of 11 +t7:=setelt(t2,3,6) +--R +--R (8) 6 +--R Type: PositiveInteger +--E 8 + +--S 9 of 11 +t2.3 +--R +--R (9) 6 +--R Type: PositiveInteger +--E 9 + +--S 10 of 11 +#t2 +--R +--R (10) 10 +--R Type: PositiveInteger +--E 10 + +--S 11 of 11 +t8:=fill!(t2,7) +--R +--R (11) [7,7,7,7,7,7,7,7,7,7] +--R Type: U32Vector +--E 11 + +)spool +)lisp (bye) + +\end{chunk} +\eject +\begin{thebibliography}{99} +\bibitem{1} nothing +\end{thebibliography} +\end{document}