0
$\begingroup$

Suppose I have the following sum of integrals:

(Integrate[E^K[1]*(f2[K[1]] + x1[K[1]]), {K[1], 1, t}] - 
    Integrate[E^K[1]*(f2[K[1]] + x1[K[1]]), {K[1], 1, t0}])/
  E^t // TraditionalForm

Clearly, the sum can be simplified by interchanging the limits of the second integral with an additional minus and then rewrite it as a single integral (for t0<1).

Mathematica, however, doesn't do it automatically with Simplify or FullSimplify. I tried to invoke it with manual rules like

intRule1 = Integrate[a_, {b_, c_, d_}] :> -Integrate[a, {b, d, c}];
intRule2 = 
  Integrate[a_, {b_, c_, d_}] + Integrate[a_, {b_, d_, e_}] :> 
   Integrate[a, {b, c, e}];

But this is mostly inconvenient since I need to apply the rule manually wherever I need it. Is there a better way to make this simplification mostly automatically?

$\endgroup$
3
  • $\begingroup$ This is related, if not a dupe. $\endgroup$ Commented Mar 9, 2018 at 8:18
  • $\begingroup$ Thanks, wasn't aware of this. Then it seems you really need to force Mathematica do it. I was hoping for some assumption settings or so... $\endgroup$
    – NeverMind
    Commented Mar 9, 2018 at 8:34
  • $\begingroup$ try working with TransformationFunctions (not mentioned in the linked dup but search, there may be another related question ) $\endgroup$
    – george2079
    Commented Mar 9, 2018 at 12:47

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.