On 10/11/08, Robert Marik <marik at mendelu.cz> wrote:
> Dear Maxima users, the functions romberg and quad_qags have problems with
> integrating log(x)/(1+x^2) from 1/10 to 10.
>
> Replacing 1/10 by 10/99 or 10/101 we get some (probably correct) answer.
> Why integration from 1/10 to 10 fails? What is special in this case?
If I'm not mistaken, a change of variable shows that the integral
from 1/10 to 1 is the negative of the integral from 1 to 10,
so the result is exactly zero.
I get error code = 2 from quad_qags. The documentation for quad_qags
says that indicates "excessive roundoff error is detected".
That's often the case for integrals which are exactly zero.
FWIW, I recommend the Quadpack functions over romberg every time.
best
Robert Dodier