ASKSAGE: Sage Q&A Forum - Latest question feedhttps://ask.sagemath.org/questions/Q&A Forum for SageenCopyright Sage, 2010. Some rights reserved under creative commons license.Thu, 16 Aug 2018 11:54:20 -0500Sage could be even more clever - How to force the use of 'sympy' backend for simplifying symbolic integrals?https://ask.sagemath.org/question/43392/sage-could-be-even-more-clever-how-to-force-the-use-of-sympy-backend-for-simplifying-symbolic-integrals/Hi there,
I have noticed the following problem:
sage: f = function('f')(x)
sage: var('h')
sage: integrate(exp(h)*exp(x)*f(x),x)
integrate(e^(h + x)*f(x), x)
The workaround seems to be using the `sympy` backend for symbolic integration
sage: integrate(exp(h)*exp(x)*f(x),x,algorithm='sympy')
e^h*integrate(e^x*f(x), x)
which always seems to be a good idea as I learned from @Emmanuel Charpentier over
[here](https://ask.sagemath.org/question/43287/solved-why-does-integratepsiyfyy-return-an-error-but-integratepsityftyy-works/?answer=43297#post-id-43297).
Now I would like to force the use of `algorith='sympy'` for simplifying these `integrate(...)` expressions globally.
Unfortunately, the `simplify()` command does not allow to set this option.
sage: integrate(exp(h)*exp(x)*f(x),x)
integrate(e^(h + x)*f(x), x)
sage: _.simplify()
integrate(e^(h + x)*f(x), x)
**TL;DR** How can I force sage to pull out these type of exponential constants from the integral with the `simplify()` command?
hausdorffThu, 16 Aug 2018 11:54:20 -0500https://ask.sagemath.org/question/43392/