Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
src/sage/symbolic/integration: help libgiac handle infinite endpoints
When integrating to/from plus/minus infinity, Giac can get stuck: sage: integral(1/max_symbolic(x, 1)**2, x, 0, oo, algorithm='giac') ... RuntimeError: Unable to check sign: 1>Infinity This is apparently due to the type of infinity that is used for integration. There are (at least?) two kinds: sage: from sage.libs.giac import libgiac sage: libgiac(Infinity) Infinity sage: libgiac(Infinity._giac_()) +infinity And, for integration, I guess we want the second kind, because it allows the integration to proceed with a warning. This commit calls _giac_() on the endpoints of a definite integral before passing them to libgiac.integrate(). It fixes the example above, and we update the corresponding doctest.
- Loading branch information