David Harvey wrote: > Begin forwarded message: > >> *From: *Andrzej Chrzęszczyk <[EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]>> >> *Date: *March 5, 2008 6:23:53 PM EST >> *To: [EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]> >> *Subject: **sage-devel "exact" numerical integration* >> >> Dear David >> Try >> >> sage: maxima_console() >> (%i1) integrate(%e^(-x^2),x,0,0.1); >> ................................... >> `rat' replaced .05623145800914245 by 2066/36741 = .05623145804414686 >> 2066 sqrt(%pi) >> (%o1) -------------- >> 36741 >> >> then you will see that (behind the scene) >> maxima replaces more accurate result .05623145804414686 sqrt(%pi) >> by the less accurate one: 2066 sqrt(%pi)/36741 (default maxima behaviour) >>
According to http://www.ma.utexas.edu/maxima/maxima_11.html Function: RAT (exp, v1, ..., vn) converts exp to CRE form by expanding and combining all terms over a common denominator and cancelling out the greatest common divisor of the numerator and denominator as well as converting floating point numbers to rational numbers within a tolerance of RATEPSILON[2.0E-8]. and KEEPFLOAT[FALSE] if TRUE prevents floating point numbers from being converted to rational numbers. Maybe we should set the keepfloat thing or set ratepsilon to a much smaller value? Jason --~--~---------~--~----~------------~-------~--~----~ To post to this group, send email to sage-devel@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/sage-devel URLs: http://www.sagemath.org -~----------~----~----~----~------~----~------~--~---