```Date: Sep 6, 2013 12:52 PM
Author: clicliclic@freenet.de
Subject: Re: The integration test suites for Sage.

peter.luschny@gmail.com schrieb:> > M> Your numbers 21, 23, 49 are shown as done while Albert's are not.> M> And your number 43 is shown as wrong whereas Albert records > M> a success.> > Albert used Maxima 5.28 whereas I used Sage 5.10. I do not know which> Maxima version Sage 5.10 uses. They might be different.> The Maxima integrator would be undergoing noticeable development then. Apleasant surprise.> So let's check by the output given on my page:> > Charlwood_problem(43)> integrand : tan(x)/sqrt(tan(x)^4 + 1)> antideriv : -1/4*sqrt(2)*arctanh(-1/2*(tan(x)^2 - 1)*sqrt(2)/sqrt(tan(x)^4 + 1))> maxima    : -1/4*sqrt(2)*arcsinh(2*sin(x)^2 - 1)> > Looks like 'antideriv' - 'solution' = 0. Is this ok?> Thus 43 is indeed a success. Wouldn't Maxima's result in this> case not be the 'better' antiderivative for Albert's "Book"?Hum. Plotting the antiderivatives along the real axis reveals thatSage/Maxima got the overall sign wrong while Albert got it right. Aftersign inversion the Maxima result appears to be correct on the real axis.But the ATANH antiderivative holds on the entire complex plane, whilethe (corrected) ASINH result doesn't: with the Derive definitionASINH(z) = -#i*ASIN(#i*z) = -LN(SQRT(1+z^2)-z), it differentiates backto a function that differs from the integrand in large parts of theplane. But then Maxima doesn't claim to deliver antiderivatives for theentire complex plane, or does it?Anyway, number 43 must be counted as a failure.> > Charlwood_problem(21)> integrand : x^3*arcsin(x)/sqrt(-x^4 + 1)> antideriv : 1/4*sqrt(x^2 + 1)*x - 1/2*sqrt(-x^4 + 1)*arcsin(x) + 1/4*arcsinh(x)> maxima    : 1/4*sqrt(x^2 + 1)*x - 1/2*sqrt(-x^4 + 1)*arcsin(x) + 1/4*arcsinh(x)> > That's easy to judge.Yes, they are identical. Perhaps Albert made a mistake here?> > Charlwood_problem(23)> integrand : x*log(x + sqrt(x^2 + 1))*arctan(x)/sqrt(x^2 + 1)> antideriv : sqrt(x^2 + 1)*log(x + sqrt(x^2 + 1))*arctan(x) - x*arctan(x) - 1/2*log(x + sqrt(x^2 + 1))^2 + 1/2*log(x^2 + 1)> maxima    : (sqrt(x^2 + 1)*log(x + sqrt(x^2 + 1)) - x)*arctan(x) + 1/2*log(x + sqrt(x^2 + 1))^2 - log(x + sqrt(x^2 + 1))*arcsinh(x) + 1/2*log(x^2 + 1)> > What did I overlook?Apparently nothing. On Derive, for complex x and with some manualassistance, the Sage/Maxima result differentiates back tox*ATAN(x)*LN(SQRT(x^2 + 1) + x)/SQRT(x^2 + 1) + (LN(SQRT(x^2 + 1) - x) + LN(SQRT(x^2 + 1) + x))/SQRT(x^2 + 1)and the second term vanishes identically over the complex plane. Sonumber 23 must be counted as a full success. Perhaps Albert made amistake here too?> > Charlwood_problem(49)> integrand : arcsin(x/sqrt(-x^2 + 1))> antideriv : x*arcsin(x/sqrt(-x^2 + 1)) + arctan(sqrt(-2*x^2 + 1))> maxima    : x*arcsin(x/sqrt(-x^2 + 1)) - 1/2*(-2*I*x^2 + I)/sqrt(2*x^2 - 1) - 1/2*I*sqrt(2*x^2 - 1) - 1/2*I*log(sqrt(2*x^2 - 1) - 1)+ 1/2*I*log(sqrt(2*x^2 - 1) + 1)> > Maxima uses 'I' here. I think Albert rates this as an error. And he> is right. Charlwood demanded only real solutions, if I remember right.> So I will classify this as deficient.The Sage/Maxima result is more than just deficient: it is incorrect for-1/SQRT(2) < x < 1/SQRT(2) on the real axis. For complex x and with somemanual assistance on Derive it differentiates back toASIN(x/SQRT(1 - x^2)) + x/(1 - x^2)*(1/SQRT(1 - 2*x^2) + #i/SQRT(2*x^2 - 1))and the second term does not vanish here; it is nonzero in two entirequadrants of the complex plane. So Albert got this one right, and number49 must indeed be counted as a failure.Martin.
```