I am having hard time understanding why Maple does this.
I have an integral, which maple could not integrate. So it returns int(....,x). Which is all fine. Then I used subsindets to force all terms in form e^(ln()+ln()+...) to expand in order to simplify the integrand, just for display purposes.
subsindets returns back the integral unevaluated (as expected) but with integrand a little simpler, again as expected.
All is well so far.
Then I find to my surprise, if I type the result back one more type, now the the integral actually evaluates.
I have 2 questions on this.
1) If the original integral did not evaluate, why simplifying e^(ln()+ln()+...) makes it now evaluate? Did not Maple know this allready?
2) Why result back from subsindets remained unevaluated integral, and I had to type it again to see it now evaluates?
I found this after long time debugging, since this was done in code, not looking at screen.
What happened is this: I store the result of subsindets in a variable, and when I look at it in the debugger, I see int() still there, as expected.
I call a function to return back this result. I now see int() is gone! So the act of just returning the result back, caused it to evaluate. Even though the orginal variable still had int() in it as. So returning the expression back, was equivalent to typing it again on the screen in the example below, which caused it to evaluate.
Please see worksheet below.
Another simpler example, is just doing assignment to new variable. This causes evaluation.
expr:=subsindets(expr,'specfunc( anything, exp )',f->(`if`(has(op(1,f),'ln'),expand(f),f)));
#the above still has int() in it.
#this assignment, also causes evaluation