rounding problems
Rebecca and Rowland
rebecca@astrid.u-net.com
Sat, 3 Oct 1998 12:17:59 +0100
> > What amazes me about TeX is that someone like Knuth could write something
> > that's as bad at arithmetic as TeX is.
>
>Wow. Have you tried to think back to all the forms of floating-point
>representation that were there in the late 70's.
I was thinking more of the user interface to the arithmetic functions that
TeX offers. I've recently had to jump through hoops in order to calculate
what dimen1/dimen2 is, for example. I trust the underlying mechanism for
actually performing the calculations: I wasn't trying to imply that I
thought there was anything wrong with that.
[snip]
>You sometimes have to cascade calculations to avoid overflow, but at
>the speed of present-day processors, so what?
Not all of us have access to present-day processors, you know.
> I do calculations to three
>and four decimal places in TeX, and it sometimes means taking four steps
>for something that a floating point processor would do in one. But I know
>that the four decimal places will be the same on every processor if I
>accept that slight extra effort.
If only the extra effort were always slight.
Rowland.