The tangent of 1/2 angle substitution was one of the original methods in
Moses' integration program to reduce rational functions in sin(u) and
cos(u) to rational functions of t.
There are lots of possible transformations and ways of applying
"identities" to get neat results. Unfortunately it is difficult to
figure out which to use, and for large expressions this can be wasteful.
There is a method that works more generally, which is to convert to
complex exponentials. In this case,
exponentialize(A*sin(x)*B*cos(x))
gives
((%e^(%i*x)+%e^(-%i*x))*B)/2-(%i*(%e^(%i*x)-%e^(-%i*x))*A)/2=C
and solving for x gives
[x=-%i*log(sqrt(C^2-B^2-A^2)/(B-%i*A)+C/(B-%i*A)),x=-%i*log(C/(B-%i*A)-sqrt(C^2-B^2-A^2)/(B-%i*A))]
This method also works for sin(2*x)+sin(x)+1=0, which would not work for
tan(x/2) substitution.
If there is a clear way of determining when to do this exponentialize,
it could be put into the solve program.
RJF
Sam Steingold wrote:
> Sam Steingold wrote:
>
>> Richard Fateman wrote:
>>
>>> There is no method available in Maxima's solve program for this equation.
>>> If you know of a way to solve it, perhaps you can describe it and it can
>>> be added to Maxima.
>>>
>>>
>>>> (%i1) solve(A*sin(x)+B*cos(x)=C,x);
>>>> cos(x) B - C
>>>> (%o1) [sin(x) = - ------------]
>>>> A
>>>>
>> the method to solve this equation:
>> let D=sqrt(A^2+B^2) and let E be such that
>> cos(E) = A/D
>> sin(E) = B/D
>> then the original eq can be rewritten as sin(x+Z)=C/D.
>>
>
> while this method works just fine in this specific case,
> there is a more general way, using the universal substitution,
> to convert a trigonometric eq to an algebraic one:
>
> let t=tan(x/2) then
> sin(x) = 2t/(1+t^2)
> cos(x) = (1-t^2)/(1+t^2)
> and the equation becomes
> A*t+B-B*t^2=C+C*t^2
> which is a quadratic equation in t.
>
>
> _______________________________________________
> Maxima mailing list
> Maxima at math.utexas.edu
> http://www.math.utexas.edu/mailman/listinfo/maxima
>