emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Elisp manual, node "Comparison of Numbers"


From: Lennart Borgman
Subject: Re: Elisp manual, node "Comparison of Numbers"
Date: Mon, 29 May 2006 16:18:32 +0200
User-agent: Thunderbird 1.5.0.2 (Windows/20060308)

David Kastrup wrote:
The problem here is that fuzz is a _relative_ measure of equality, and
you employ it as an absolute measure here.  I don't think it a good
idea at all that 1e-12 and 0.995e-12 are considered different, while
1e-8 and 0.0 are considered equal.
Agree!
Hm. It is the relative distance from 0.

It is merely the distance from 0, not the "relative distance".
Yes, in a sense you are right. I should have expressed my self a bit differently, but I am afraid you missed the point. The crucial thing is that you divide the difference with the "distance" from 0 to construct the number you compare to the fuzz factor.

It seems reasonable to me but breaks down in the special case where one of the numbers are 0 (and the other is not).

Or am I missing something?




reply via email to

[Prev in Thread] Current Thread [Next in Thread]