Forgot : I have graphically checked the numerical quasi-equality of the 
symbolical integral given by Mathematica and the numerical integral given 
by Sage.

Le mardi 25 octobre 2022 à 15:46:13 UTC+2, Emmanuel Charpentier a écrit :

> Essentially correct, bit it’s a tad less simpler :
>
> sage: f(x) = x^2*(log(x))^4/((x+1)*(1+x^2)) 
> sage: list(map(lambda u:u.integrate(x, 0, 1), 
> f(x).partial_fraction_decomposition()))
> [-5/128*pi^5 + 45/64*zeta(5), 45/4*zeta(5)]
> sage: list(map(lambda u:mathematica.Integrate(u, (x, 0, 1)).sage(), 
> f(x).partial_fraction_decomposition()))
> [-5/128*pi^5 + 45/128*zeta(5), 45/4*zeta(5)]
>
> HTH
> ​
> Le lundi 24 octobre 2022 à 21:33:41 UTC+2, Frédéric Chapoton a écrit :
>
>> where we can see that there is a factor 2 between the wrong symbolic 
>> value and the correct numeric value
>>
>> This should be filed as a bug in maxima.
>>
>> Le lundi 24 octobre 2022 à 21:24:30 UTC+2, Frédéric Chapoton a écrit :
>>
>>> and one more step :
>>>
>>> sage: integrate(x*log(x)^4/(x^2 + 1), x,0,1).n()
>>> 1.45817965567036
>>> sage: (x*log(x)^4/(x^2 + 1)).nintegral(x,0,1)
>>> (0.7290898278351722, 2.48288156701193e-09, 357, 0)
>>> sage: integrate(-log(x)^4/(x^2 + 1), x,0,1).n()
>>> -23.9077878738501
>>> sage: (-log(x)^4/(x^2 + 1)).nintegral(x,0,1)
>>> (-23.90778787384685, 1.267767046897461e-08, 483, 0)
>>>
>>>
>>> Le lundi 24 octobre 2022 à 21:19:46 UTC+2, Frédéric Chapoton a écrit :
>>>
>>>> more study of the bug (coming from maxima)
>>>>
>>>> sage: C=x^2*(log(x))^4/((x+1)*(1+x^2))
>>>> sage: aa,bb=C.partial_fraction_decomposition()
>>>> sage: integral(aa,x,0,1)
>>>> -5/128*pi^5 + 45/64*zeta(5)
>>>> sage: integral(bb,x,0,1)
>>>> 45/4*zeta(5)
>>>> sage: _+__
>>>> -5/128*pi^5 + 765/64*zeta(5)
>>>> sage: _.n()
>>>> 0.440633136273039
>>>> sage: aa.nintegral(x,0,1)
>>>> (-11.58934902297507, 5.068708119893017e-08, 525, 0)
>>>> sage: bb.nintegral(x,0,1)
>>>> (11.66543724536065, 4.943314557692702e-08, 525, 0)
>>>> sage: integral(aa,x,0,1).n()
>>>> -11.2248041090899
>>>> sage: integral(bb,x,0,1).n()
>>>> 11.6654372453629
>>>>
>>>>
>>>>
>>>> Le lundi 24 octobre 2022 à 00:14:09 UTC+2, pvit...@gmail.com a écrit :
>>>>
>>>>> I am using Sage 9.7 running in Arch linux over WSL2
>>>>>
>>>>> I get different results for an integral using numerical integration 
>>>>> (which seems to agree with Mathematica) and symbolic integration:
>>>>>
>>>>> numerical_integral(x^2*(log(x))^4/((x+1)*(1+x^2)),0,1)
>>>>> (0.07608822217400527, 1.981757967172001e-07)
>>>>>
>>>>> integral(x^2*(log(x))^4/((x+1)*(1+x^2)),x,0,1)
>>>>> 6*I*polylog(5, I) - 6*I*polylog(5, -I) + 765/64*zeta(5)
>>>>> integral(x^2*(log(x))^4/((x+1)*(1+x^2)),x,0,1).n()
>>>>> 0.440633136273036
>>>>>
>>>>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-devel/ef60dab8-dd47-4c82-a274-50b3222bd41an%40googlegroups.com.

Reply via email to