The a e (calc-simplify-extended
) [esimplify
] command
is like a s
except that it applies some additional simplifications which are not
"safe" in all cases. Use this only if you know the values in your
formula lie in the restricted ranges for which these simplifications
are valid. The symbolic integrator uses a e;
one effect of this is that the integrator's results must be used with
caution. Where an integral table will often attach conditions like
"for positive a only," Calc (like most other symbolic
integration programs) will simply produce an unqualified result.
Because a e's simplifications are unsafe, it is sometimes better to type C-u -3 a v, which does extended simplification only on the top level of the formula without affecting the sub-formulas. In fact, C-u -3 j v allows you to target extended simplification to any specific part of a formula.
The variable ExtSimpRules
contains rewrites to be applied by
the a e command. These are applied in addition to
EvalRules
and AlgSimpRules
. (The a r AlgSimpRules
step described above is simply followed by an a r ExtSimpRules step.)
Following is a complete list of "unsafe" simplifications performed by a e.
Inverse trigonometric or hyperbolic functions, called with their corresponding non-inverse functions as arguments, are simplified by a e. For example, arcsin(sin(x)) changes to x. Also, arcsin(cos(x)) and arccos(sin(x)) both change to pi/2 - x. These simplifications are unsafe because they are valid only for values of x in a certain range; outside that range, values are folded down to the 360-degree range that the inverse trigonometric functions always produce.
Powers of powers (x^a)^b are simplified to @c{$x^{a b}$} x^(a b) for all a and b. These results will be valid only in a restricted range of x; for example, in @c{$(x^2)^{1:2}$} (x^2)^1:2 the powers cancel to get x, which is valid for positive values of x but not for negative or complex values.
Similarly, sqrt(x^a) and sqrt(x)^a are both simplified (possibly unsafely) to @c{$x^{a/2}$} x^(a/2).
Forms like sqrt(1 - sin(x)^2) are simplified to, e.g.,
cos(x). Calc has identities of this sort for sin
,
cos
, tan
, sinh
, and cosh
.
Arguments of square roots are partially factored to look for squared terms that can be extracted. For example, sqrt(a^2 b^3 + a^3 b^2) simplifies to a b sqrt(a+b).
The simplifications of ln(exp(x)), ln(e^x), and log10(10^x) to x are also unsafe because of problems with principal values (although these simplifications are safe if x is known to be real).
Common factors are cancelled from products on both sides of an equation, even if those factors may be zero: a x / b x to a / b. Such factors are never cancelled from inequalities: Even a e is not bold enough to reduce a x < b x to a < b (or a > b, depending on whether you believe x is positive or negative). The a M / command can be used to divide a factor out of both sides of an inequality.