[Ecls-list] log and overflow

Juan Jose Garcia-Ripoll juanjose.garciaripoll at googlemail.com
Mon Jan 19 16:03:07 UTC 2009


On Sat, Jan 17, 2009 at 2:10 AM, Gabriel Dos Reis <gdr at cs.tamu.edu> wrote:
> The log function in the form
>
>  (let ((a (expt 234 108)))
>    (and (< a most-positive-double-float)
>         (log a 10)))

That bignum cannot be represented as a floating point number and thus
it causes LOG to overflow. There are algorithms to handle these cases,
but you have to understand that the specification allows a floating
point operation to overflow in these cases. I take note, though and
will try to change the behavior for this particular function.

Juanjo

--
Instituto de Física Fundamental, CSIC
c/ Serrano, 113b, Madrid 28009 (Spain)
http://juanjose.garciaripoll.googlepages.com




More information about the ecl-devel mailing list