3 /* exponentials, hyperbolic functions, and trig functions may
4 often be converted to the required form by using the multiple-argument
5 formulas together with equality constraints such as the sum of the
6 squares of the sine and cosine equals 1. For example: */
7 trigexpand: exptsubst: true ;
8 cos(2*x) + sin(x)*exp(2*y) - exp(y);
9 subst([sin(x)=s, cos(x)=c, %e**y=e], %);
10 stapoints(%, [], s**2+c**2-1) ;
11 /* For any of the above answers, we may use LOG(E) or ?ATAN(S,C)
12 to compute the corresponding values of the original decision
13 variables, where E, S, or C are the right-hand-sides of the
14 appropriate components of the chosen component of STAPTS.