Search All of the Math Forum:

Views expressed in these public forums are not endorsed by NCTM or The Math Forum.

Notice: We are no longer accepting new posts, but the forums will continue to be readable.

Topic: Trig identity for linear combination of sines
Replies: 3   Last Post: Aug 16, 2013 3:09 AM

 Messages: [ Previous | Next ]
 Kevin J. McCann Posts: 147 Registered: 12/7/04
Re: Trig identity for linear combination of sines
Posted: Aug 16, 2013 3:09 AM

Expand the sin(x+alpha)=sin(x)cos(alpha)+cos(x)sin(alpha) terms in the
first expression. Find the coefficients of sin(x) and cos(x). Then
equate these to the corresponding expressions in the second expansion.
Solve for A and z. It is not a simple result.

Here is the code:

rule1 = Sin[m_ + n_] -> Sin[m] Cos[n] + Cos[m] Sin[n]
expr = a Sin[x + q] + b Sin[x + r] + c Sin[x + t] /. rule1 // Expand
eq1 = Coefficient[expr, Sin[x]] == A Cos[z]
eq2 = Coefficient[expr, Cos[x]] == A Sin[z]
result=Solve[{eq1, eq2}, {A, z}] // Simplify

Note that there is a ConditionalExpression that results from the
periodicity of the trig functions.

You can check it out by choosing some numbers. In addition, I set the
constant C[1] in the result to zero:

a = 12.7; b = 2.2; c = 4.7;
q = 85.4 .1; r = 27.9; t = 16.14;
x = 75.031;
{a Sin[x + q] + b Sin[x + r] + c Sin[x + t],A Sin[x + z] /. result /.
C[1] -> 0}

A Sin[x + z] /. result /. C[1] -> 0

Kevin

On 8/15/2013 1:14 AM, orenpedatzur@gmail.com wrote:
> On Monday, June 15, 2009 2:07:21 AM UTC+3, Chelly wrote:
>> Hi:
>>
>> I have a function which is a linear combination of sines, of the form
>>
>> y = a*sin(x+q) + b*sin(x+r) + c*sin(x+t)
>>
>> and I am looking for a trignometric identity that would reduce the above to the form
>>
>> y = A*sin(x+Z)
>>
>> I would also like to find out how to implement this rule in Mathematica.
>>
>> Thanks
>> Chelly

>
> Hi Chelly
>
> This kind of linear combination of sines is covered in wikipedia article on trigonometric identities:
>
> http://en.wikipedia.org/wiki/List_of_trigonometric_identities
>
> I would also like to know how to implement this in mathematica.
>
> bye!
>
> Oren P
>

Date Subject Author
6/14/09 Chelly
6/15/09 Ray Koopman
8/15/13 orenpedatzur@gmail.com
8/16/13 Kevin J. McCann