Re: -0.0 versus 0.0

Andrea Fedeli <[email protected]> Sun, 22 Feb 2009 17:42:48 +0100
Newsgroups gmane.comp.gnu.prolog.bugs
Message-ID <[email protected]>
Dave Sworin wrote:


> ?- R is 0, THETA is 3.1415, X is R * cos(THETA).


> R = 0

> THETA = 3.1415000000000002

> X = -0.0

A .5 cents worth comment: curiously, the exact same behavior is exposed 
by SWI 5.6.50 and Ciao 1.10p8, at least on my machine/OS combination 
(Athlon XP 2800+/OpenSuse 11.0). It very roughly seems like something 
related either to a shared library or to a common portion of source code.

cheers,

    Andrea.

-- 
Andrea Fedeli

Dawn, n.:
	The time when men of reason go to bed.
		-- Ambrose Bierce, "The Devil's Dictionary"