[Maxima] floating point test suite
willisb at unk.edu
Sat Aug 8 13:55:57 CDT 2009
I think Knuth (Section 4.2.2 of Seminumerical Algorithms (3rd edition)) has
algorithm for floating point comparison. Next time I visit the library,
look it up.
-----maxima-bounces at math.utexas.edu wrote: -----
>On 8/7/09, Barton Willis <willisb at unk.edu> wrote:
>> ;; Return true if $float converts both a and b to floats and
>> ;; |a - b| <= float_approx_equal_tolerance * min(|a|, |b|).
>> ;; In all other cases, return false.
>Incidentally this definition is, I believe, unnecessarily strict for
>quantities near zero. There are some tests which fail for some
>Lisp implementations because e.g. 1e-16 isn't close enough to
>1.1e-16 where these numbers are residual errors of some kind
>(i.e. computed by subtracting much larger numbers which are
>Maxima mailing list
>Maxima at math.utexas.edu
More information about the Maxima