Subject: Maxima gives incorrect results with ceiling
From: van Nek
Date: Fri, 07 Dec 2007 19:21:23 +0100
Hello Mike,
I think, with floating point numbers every system will give an incorrect answer. The precision
is just 16, nothing more. Try bigfloats:
(%i1) fpprec:100$
(%i2) ceiling(factorial(50)/bfloat(%e));
(%o2) 11188719610782480504630258070757734324011354208865721592720336801
Volker van Nek
Am 6 Dec 2007 um 18:58 hat Mike Hansen geschrieben:
> Hello,
>
> When working with large numbers and floating point arithmetic, maxima
> gives incorrect answers. For example,
>
> (%i5) ceiling(factorial(50)/exp(1));
> (%o5) 11188719610782480421414879249141773426630319613740326700720324608
>
> The correct result should be
> 11188719610782480504630258070757734324011354208865721592720336801 .
> What is the best way to go about fixing this issue?
>
> Thanks,
> Mike
> _______________________________________________
> Maxima mailing list
> Maxima at math.utexas.edu
> http://www.math.utexas.edu/mailman/listinfo/maxima