(log (ash 1 100000))
*** - floating point overflow
it would appear that a simple method
of discarding unnecessary digits and returning
(+ (* N (log 2)) (log (ash X (- N))))
for large X and appropriate N would solve this problem.
Bruno Haible
2004-08-11
Logged In: YES
user_id=5923
Agreed. The only thing to be careful about is that (log 2) needs
to be computed in extended precision, because by multiplying
with N any round-off errors in computing (log 2) is multiplied with
|N|.
Sam Steingold
2004-08-11
Logged In: YES
user_id=5735
R_ln_R() already computes (log 2)
with the (presumably) correct precision.
all that remains to be determined is
how many integer digits are needed
for the specific float output.
i.e., the exponent of the appropriate float epsilon.
Sam Steingold
2005-09-30
Logged In: YES
user_id=5735
maybe related
[ 1246248 ] (LOG INTERNAL-TIME-UNITS-PER-SECOND) -> error:
http://sourceforge.net/tracker/index.php?func=detail&aid=1246248&group_id=1355&atid=101355
Sam Steingold
2009-01-18
Sam Steingold
2009-01-18
thank you for your bug report.
the bug has been fixed in the CVS tree.
you can either wait for the next release (recommended)
or check out the current CVS tree (see http://clisp.cons.org\)
and build CLISP from the sources (be advised that between
releases the CVS tree is very unstable and may not even build
on your platform).