On Wed, Mar 11, 2015 at 9:35 AM, Dima Pasechnik <[email protected]> wrote:
> On 2015-03-11, Nils Bruin <[email protected]> wrote:
>> On Wednesday, March 11, 2015 at 2:46:25 AM UTC-7, Dima Pasechnik wrote:
>>>
>>> I tried this integral directly in Maxima, and taking bfloat of it
>>> outputs nonsense.
>>>
>>
>> I have noticed before that bfloats aren't infectious enough: operations on
>> bfloats can easily result in a normal "double". I think there are ways to
>> convince maxima to use bfloats more pervasively. Perhaps a global precision
>> setting somewhere?
>>
>>
>>> I wish there was a more accessible full implementation of Risch
>>> algorithm...
>>>
>>
>> This is a rational function, so a first calculus course would already teach
>> you the relevant part of the Risch algorithm. It's a little more tricky to
>
> Risch, as implemented in Axiom, does not do factorisation (i.e. no
> partial fractions).
> In this example at least it produces much nicer looking antiderivative,
> no huge integers.
> http://axiom-wiki.newsynthesis.org/ExampleIntegration
>
> Dima

For what it's worth, here's how to mostly do that Axiom session, but
in a SageMathCloud worksheet...

   
https://cloud.sagemath.com/projects/4a5f0542-5873-4eed-a85c-a18c706e8bcd/files/support/2015-03-11-093745-axiom-integral.sagews

William

>
>> get an ostensibly real-valued function as an antiderivative. Anyway, sympy
>> produces a reasonable-looking antiderivative.
>>
>> Interestingly, we have:
>>
>> sage: I=integral(x/(x^3-x+1), x, 1, 2, algorithm='sympy')
>> sage: RIF(I)
>> TypeError: unable to simplify to a real interval approximation
>>
>> The offending subexpression seems to be:
>>
>> sage: A=(299838966359964800*69^(5/6)*2^(2/3) -
>> 11515081166050000*69^(2/3)*2^(1/3)*(25*sqrt(69) + 207)^(1/3) -
>> 99785894223312000*sqrt(69)*(25*sqrt(69) + 207)^(2/3) +
>> 2271318237097115625*69^(1/3)*2^(2/3) -
>> 99785894223312000*69^(1/6)*2^(1/3)*(25*sqrt(69) + 207)^(1/3) -
>> 497728835949744*9522^(1/3)*(25*sqrt(69) + 207)^(1/3) -
>> 828883890137982336*(25*sqrt(69) + 207)^(2/3) +
>> 219331275901257879*276^(1/3))^(QQ(-1))
>> sage: RIF(A)
>> TypeError: unable to simplify to a real interval approximation
>>
>> Note the *rational* exponent -1. If that's an integer there's no problem.
>> Using RealIntervalField(200) has the same problem. Using RealField(...)
>> seems to work fine.
>>
>
> --
> You received this message because you are subscribed to the Google Groups 
> "sage-support" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to [email protected].
> To post to this group, send email to [email protected].
> Visit this group at http://groups.google.com/group/sage-support.
> For more options, visit https://groups.google.com/d/optout.



-- 
William (http://wstein.org)

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.

Reply via email to