|
From: | Raymond Toy |
Subject: | [Gcl-devel] Re: GCL bugs (decode-float, rationalize, expt) |
Date: | Sat, 04 Jan 2003 15:34:13 -0500 |
User-agent: | Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.3b) Gecko/20021219 |
Stavros Macrakis wrote:
Incorrect. (rationalize 1.0e-320) should be 1/x, where x is somewhere near 10^320, and (float (rationalize 1.0e-320) should be
FWIW, clisp has a good implementation of rational (or was that rationalize?) I believe cmucl has a lisp implementation of the same algorithm.
(decode-float 1.0e-320)0.50000000000022471 -1022 1.0Incorrect. 0.5 * 2^-1022 = 1.1e-308, not 1.0e-320. Correct answer is roughly .49, -1062, 1.0
FWIW, cmucl says 0.98828125d0, -1063 Ray
[Prev in Thread] | Current Thread | [Next in Thread] |