Ask Your Question

Revision history [back]

By default, Sage uses Maxima which indeed gets it wrong.

sage: integrate(log(1 + 1/(x**2 + 1)), x, -oo, oo, algorithm='maxima')
2*pi - 2*sqrt(2)*pi

Nonetheless, Sympy and Giac both get it right:

sage: integrate(log(1 + 1/(x**2 + 1)), x, -oo, oo, algorithm='sympy')
-2*pi + 2*sqrt(2)*pi
sage: integrate(log(1 + 1/(x**2 + 1)), x, -oo, oo, algorithm='giac')
2*pi*(sqrt(2) - 1)