(%i1) q1: T*cos(theta) = F*cos(alpha)$
(%i2) q2: M = T*sin(theta)+F*sin(alpha)$
(%i3) eqs:[q1,q2]$
(%i4) eqs1: subst([alpha=asin(sinalpha),theta=asin(sintheta)],eqs);
(%o4) [sqrt(1-sintheta^2)*T = sqrt(1-sinalpha^2)*F,M =
sintheta*T+sinalpha*F]
(%i5) load(to_poly_solver)$
(%i6) to_poly_solve(eqs1,[sintheta,sinalpha]);
(%o6) %union(%if(?%and(-%pi/2 <
parg(-sqrt(-T+M+F)*sqrt(T-M+F)*sqrt(T+M-F)*sqrt(T+M+F)/(2*M*T)),-%pi/2 <
parg(-sqrt(-T^4+(2*M^2+2*F^2)*T^2-M^4+2*F^2*M^2-F^4)/(2*F*M)),
parg(-sqrt(-T+M+F)*sqrt(T-M+F)*sqrt(T+M-F)*sqrt(T+M+F)/(2*M*T)) <=
%pi/2,parg(-sqrt(-T^4+(2*M^2+2*F^2)*T^2-M^4+2*F^2*M^2-F^4)/(2*F*M)) <=
%pi/2),
[sinalpha = -(T^2-M^2-F^2)/(2*F*M),sintheta =
(T^2+M^2-F^2)/(2*M*T)],%union()),
%if(?%and(-%pi/2 <
parg(sqrt(-T+M+F)*sqrt(T-M+F)*sqrt(T+M-F)*sqrt(T+M+F)/(M*T)),-%pi/2 <
parg(sqrt(-T^4+(2*M^2+2*F^2)*T^2-M^4+2*F^2*M^2-F^4)/(F*M)),
parg(sqrt(-T+M+F)*sqrt(T-M+F)*sqrt(T+M-F)*sqrt(T+M+F)/(M*T)) <=
%pi/2,parg(sqrt(-T^4+(2*M^2+2*F^2)*T^2-M^4+2*F^2*M^2-F^4)/(F*M)) <= %pi/2),
[sinalpha = -(T^2-M^2-F^2)/(2*F*M),sintheta =
(T^2+M^2-F^2)/(2*M*T)],%union()))
Note that most of the length of the result comes from the *conditions*
around the variables, which you can probably ignore, especially since the
first two cases have the same value....
(%i7) part(%o6,1,2);
(%o7) [sinalpha = -(T^2-M^2-F^2)/(2*F*M),sintheta = (T^2+M^2-F^2)/(2*M*T)]
(%i8) part(%o6,2,2);
(%o8) [sinalpha = -(T^2-M^2-F^2)/(2*F*M),sintheta = (T^2+M^2-F^2)/(2*M*T)]
-s
On Sat, Nov 19, 2011 at 14:34, Ether Jones <maxima at etherjones.us> wrote:
> q2: M = T*sin(theta)+F*sin(alpha);