summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/doc/generic/minifp
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2013-07-17 22:13:10 +0000
committerKarl Berry <karl@freefriends.org>2013-07-17 22:13:10 +0000
commiteec0a21648f82e9f409ed8151e1bc83f34bfec79 (patch)
treedd59250c0f9496a72010ad5b1097e0199888f06f /Master/texmf-dist/doc/generic/minifp
parentd9add100de8f268f2b408533a41cc5624ef1ee7a (diff)
minifp (17jul13)
git-svn-id: svn://tug.org/texlive/trunk@31221 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/doc/generic/minifp')
-rw-r--r--Master/texmf-dist/doc/generic/minifp/README36
-rw-r--r--Master/texmf-dist/doc/generic/minifp/minifp.pdfbin419173 -> 421610 bytes
-rw-r--r--Master/texmf-dist/doc/generic/minifp/test1.tex11
-rw-r--r--Master/texmf-dist/doc/generic/minifp/test2.tex59
4 files changed, 59 insertions, 47 deletions
diff --git a/Master/texmf-dist/doc/generic/minifp/README b/Master/texmf-dist/doc/generic/minifp/README
index eec67f09a9e..065bac29198 100644
--- a/Master/texmf-dist/doc/generic/minifp/README
+++ b/Master/texmf-dist/doc/generic/minifp/README
@@ -11,10 +11,11 @@ Purpose:
get additional operations (sine, cosine, angle, square root, log and
exp), the file mfpextra.tex is provided.
- Minifp should work in both latex and plaintex.
+ Minifp should work in both LaTeX and plainTeX.
- This is version 0.92. It should work reasonably well, barring any bugs,
- but I expect to spend some time fine-tuning it for version 1.0.
+ This is version 0.95. It should work reasonably well, barring any
+ bugs, but I expect to spend some time fine-tuning it before calling it
+ version 1.0.
License:
@@ -82,18 +83,23 @@ Manifest:
<http://comp.uark.edu/~luecking/tex/tex.html>.
History:
-
- Version 0.92 : Bugfixes: correct sign of floor and ceiling. Correct
- occasional minus sign in front of 0 for sin or cos.
- Version 0.9 : angle: near maximum accuracy, at some cost to speed.
- Version 0.8 : exp: now more accurate for many cases.
- Version 0.7 : sqrt: now exact when possible and much more accurate.
- Version 0.6 : Added angle to mfpextra. Changed package name to minifp.
- Version 0.5 : Added sqrt, deg, rad to mfpextra.
- Version 0.4 : Added log, exp, pow to mfpextra.
- Version 0.3 : Added mfpextra.tex, defines sin and cos.
- Version 0.2 : Added macros for printing, formatting the results.
- Version 0.1 : First working set of macros. Package named mfp.sty.
+ Version 0.95: More testing. Changed square root of negative from an
+ error to a warning. Documentation updated. Now mfpextra
+ checks for minifp.sty and inputs it if needed.
+ Version 0.94: Improved accuracy of log, sin and sqrt.
+ Version 0.93: Corrected mistyped data for logarithm.
+ Fixed bugs in degree/radian conversions.
+ Version 0.92: Corrected sign of floor and ceiling. Corrected
+ occasional minus sign in front of 0.0 for sin or cos.
+ Version 0.9 : angle: near maximum accuracy, at some cost to speed.
+ Version 0.8 : exp: now more accurate for many cases.
+ Version 0.7 : sqrt: now exact when possible and much more accurate.
+ Version 0.6 : Added angle to mfpextra. Changed package name to minifp.
+ Version 0.5 : Added sqrt, deg, rad to mfpextra.
+ Version 0.4 : Added log, exp, pow to mfpextra.
+ Version 0.3 : Added mfpextra.tex, defines sin and cos.
+ Version 0.2 : Added macros for printing, formatting the results.
+ Version 0.1 : First working set of macros. Package named mfp.sty.
--
Dan Luecking <luecking (at) uark (dot) edu>
diff --git a/Master/texmf-dist/doc/generic/minifp/minifp.pdf b/Master/texmf-dist/doc/generic/minifp/minifp.pdf
index baca0c62f24..d08a688cf76 100644
--- a/Master/texmf-dist/doc/generic/minifp/minifp.pdf
+++ b/Master/texmf-dist/doc/generic/minifp/minifp.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/generic/minifp/test1.tex b/Master/texmf-dist/doc/generic/minifp/test1.tex
index c08127eb8b9..2956afa3fe6 100644
--- a/Master/texmf-dist/doc/generic/minifp/test1.tex
+++ b/Master/texmf-dist/doc/generic/minifp/test1.tex
@@ -1,7 +1,10 @@
\errorcontextlines999\relax
%\def\MFPextra{}
-X\input minifp.sty\relax X
-X\MFPloadextra X
+%X\input minifp.sty\relax X
+%X\MFPloadextra X
+X\input mfpextra\relax X
+X\input mfpextra\relax X
+
\def\filbreak{\vskip 12pt plus 100pt\penalty 0 \vskip 0pt plus -100pt\relax}
\def\meaningless#1>{}
@@ -82,9 +85,7 @@ Square:\Rsq\y
\Rpop\X\Rpush{21.34}%
Inversion:\Rinv\y
\Rpop\X\Rpush{21.34}%
-\tracingmacros1
Floor:\Rfloor\y
-\tracingmacros0
\Rpop\X\Rpush{21.34}%
Ceiling:\Rceil\y
\Rpop\X\Rpush{21.34}%
@@ -381,7 +382,7 @@ large:^^J}
\filbreak
{\bf Extra tests of sqrt}\\
-\immediate\write16{^^J*** The following tests the error for a square root of a
+\immediate\write16{^^J*** The following tests the warning for a square root of a
negative:^^J}
Square root of $-1$:\MFPsqrt{-1}\Z\w
Square root of $0$:\MFPsqrt{0}\Z\w
diff --git a/Master/texmf-dist/doc/generic/minifp/test2.tex b/Master/texmf-dist/doc/generic/minifp/test2.tex
index 8cd7ab278c5..6d6398a8976 100644
--- a/Master/texmf-dist/doc/generic/minifp/test2.tex
+++ b/Master/texmf-dist/doc/generic/minifp/test2.tex
@@ -1,5 +1,9 @@
\errorcontextlines999\relax
-X\input minifp.sty\relax X\MFPloadextra X
+The various ``XX'' and ``xX'' pairs test whether there are errant spaces
+in the macros or the macro files.
+
+X\input mfpextra\relax X
+X\input mfpextra\relax X
\def\empty{}
\def\frac#1#2{{#1\over#2}}
@@ -83,44 +87,45 @@ probably each equivalent to a dozen or more multiplications. Counting
each such operation with the an estimated multiplicity, the tests
probably perform 400 thousand or more basic operations.
-Of the basic operations, multiplication is (by measurement) 4 times as
-lengthy as addition, and division is about twice as lengthy as
-multiplication. Actual times depend on the machine, but the ratios remain
-pretty much the same. Here is a summary of timings on my fastest
-machine; each operation is run 500 times in a loop:
+Of the basic operations, multiplication is (by measurement) 2--4 times
+as lengthy as addition, and division is 2--3 times as lengthy as
+multiplication. Actual times depend on the machine, but the ratios
+remain pretty much the same. Here is a summary of timings on my fastest
+machine; each operation is run 500 times in a loop. (A loop in which
+an input number is processed and a value returned, but no calculations are
+performed ({\tt\string\MFPzero}), times at $0.0\,$sec.) Timing obtained
+with {\tt\string\pdfelapsedtime}.
\medskip
\indent\vtop{\halign{\hfil$#$&\quad$#\,$sec\cr
\noalign{\hrule\smallskip}
-2.54321+22432.87654321 &0.015\cr
-2.54321\times22432.87654321 &0.06\cr
-22432.87654321/2.54321 &0.14\cr
-\sqrt{23456789.54321} &0.20\cr
-1.00001234^{8000} &0.73\cr
-\exp(2.54321) &0.41\cr
-\sin(2.54321) &0.45\cr
-\log(2.54321) &0.53\cr
-\mathop{\fam0 angle}(254.321,100) &1.17\cr
+2.54321+22432.87654321 &0.016\cr
+2.54321\times22432.87654321 &0.046\cr
+22432.87654321/2.54321 &0.11\cr
+\sqrt{23456789.54321} &0.172\cr
+1.00001234^{8000} &0.72\cr
+\exp(2.54321) &0.42\cr
+\sin(2.54321) &0.41\cr
+\log(2.54321) &0.73\cr
+\mathop{\fam0 angle}(254.321,100) &1.14\cr
\noalign{\smallskip\hrule}
}}
\medskip
-Originally, all the tests combined took 21 seconds on a 4-year-old
+Originally, all the tests below combined took 21 seconds on a 4-year-old
Windows XP under TeX Live 2011. But since then I have changed angle and
power computations so that they are considerably more accurate, but with
-a possible reduction in speed. Of course, some of the speed loss may be
-due to the operating system.
-
-On a Windows 7 machine, 64-bit, laptop, it takes 32 seconds to process
-this file. On another Win7, machine, 32-bit, desktop, it takes 10
-seconds.
-
-The difference could be explained partially by the fact that the second
-machine is newer and partially by the fact that TeX is a 32-bit program,
-and therefore a better match to the operating system of the second
-system.
+a possible reduction in speed. I cannot test the speed reduction, since
+I no longer have that machine.
+
+For my current machines: On a Windows 7 machine, 64-bit, laptop, it
+takes 32 seconds to process this file. On another Windows 7 machine,
+32-bit, desktop, it takes about 10 seconds. (This difference could be
+explained partly by the fact that the last machine is newer and partly
+by the fact that TeX is a 32-bit program and therefore a better match to
+the 32-bit hardware.)
\def\testi{% stack forms
\startMFPprogram