Question: automatic replacements of exp(x)^n by exp(x*n) ?

sometimes I get intermediate expressions generated from other operations that contain terms such as exp(x)^n in them. As an example, exp(x)^3.  In Mathematica, it automatically replaces these by exp(3*x). But in Maple I need to force this change.

For purposes of Latex only, I like to change these terms to exp(3*x) before converting the whole expression to Latex, as it is looks much better that way.


                \left({\rm e}^{x}\right)^{3}


                {\rm e}^{3 x}

I found that doing simplify(expr,exp)  does the trick. It changes exp(x)^n to exp(n*x). But I am worried about applying this whole simplification command to the whole expression, which can be very large, and do not want to change it all yet.

I just want to change any occurance of exp() there, and nothing more.

I tried using subsindent to do that, but it does not work on terms in denominator


I tried


and it did not work.

I am still not good at subsindent. How to make it change all exp(x)^n to exp(n*x) everywhere?

Please Wait...