Hi, Ray,
I saw your comment on ration1 (in rat3e.lisp) wondering about the accuracy
of the float-to-rational conversion there.
Out of curiosity, I compared its results to results from
cf(rationalize(...)), which are the exact answers. A little experimentation
with random arguments shows that it is +/- 1 ULP off about 5% of the time,
and +/- 2 ULP off about 1% of the time. I didn't find examples of larger
errors, and I'm not sure how I'd construct cases which would cause them
(ideas?). Of course, this does not give us any real upper bound. But I'm
pretty confident that there is no problem with the default ratepsilon of
2e-8 (which was based on the PDP-10's 27-bit mantissa!).
That said, I thought we'd agreed in February 2005 that the default
ratepsilon should be much smaller, say 2.0e-15 (for IEEE doubles, which I
believe all Maxima implementations use).
And I think it would be logical that for ratepsilon = 0,
rat(x)=rationalize(x).
-s
ULP = unit in the last position