Expansion of Sine and Cosine

With the Pythagoras derived by rotational dynamics from the last post, it is natural to think of sines and cosines as they are both related to rotation more so directly.  

1 Definitions

A big difference about sines and cosines is that they depend on angles rather than side lengths. So what is an angle? Well it is nothing but the length of the arc swiped counterclockwise by a line segment that equals to 1, 



here OA rotates about the origin O then become OC, and the length of arc AC is the definition of an angle(in radian), let us call this angle α. Now in a 2-D coordinate system, an angle is defined w.r.t. the positive x-axis. For example, let us put this model in a 2-D coordinate, where O is the origin, A is at (1,0), then OA would be at a angle 0 as it overlaps with the positive x-axis and OC would be at an angle α. Now to define sine and cosine, sinα is defined to be the y-coordinate of C(or vertical component of OC) and cosα is defined to be the x-coordinate of C(or horizontal component of OC).  

2 Setup

Now sine and cosine of an angle are defined, but they are only definitions, we want to actually calculate them. We will look at a situation where OC is already at an angle α w.r.t. the horizon, and from there it rotates an angle β to become OE

And of course the radius is always 1, that is OA=OC=OE=1, and remember we say angles but angles are really just arc lengths. α is really just the length of arc AC and the angle β is just the length of the arc EC. Our goal is to find the coordinate of the end point E, whose y-coordinate(or vertical components of OE) correspond to sinα+β, and x-coordinate(or horizontal and components of OE) correspond to cosα+β. The reason not let the rotation start from the horizon but rather from a non-zero angle α will become clear at the end of this article. 

3 Discrete rotation 

The approach we use is very similar to the one we used in the derivation of Pythagoras, a rotation can be approximated by discrete linear movements, 

i.e. OC is the starting point and OC=1, it takes 4 linear segments(or call them tangent movements) CP, PQ, QR, RE to become OE, and of course the direction of motion is always perpendicular to the "radius" at that point so

 PCOC    QPOP    RQOQ    EROR 

and every linear movement is equal in length,

 PC=QP=RQ=ER

so this time for each step it moves the same distance, rather than moving the same height as in the Pythagoras case. Now let us get into action and calculate how the horizontal component and the vertical component evolve in this 4-step-rotation. For simplicity, we will use HC and VC as short hands for horizontal component and vertical component.

The first step,


the starting position is at C, it has coordinate (a,b) and OC=1. The first tangent movement is C to P where PCOC and PC=ΔPM and MC represent the changes in HC and VC, by similar triangles, 

PM=Δb 

MC=Δa

so after the first step at the new point P, its coordinate becomes 

(a-Δb,b+Δa)

let us call it (a',b') for simplicity. Now the second step,

again, QPPO and QP=Δ, this time OP does not equal to 1 anymore, but in the limiting case when each tangent movement or Δ is infinitesimally small, then it becomes a proper rotation and radius is preserved. So let us just pretend Δ is small and radius is still 1 in this case. Again by similar triangle 

QN=Δb'

NP=Δa'

so after the second step at the new point Q, its coordinate becomes 

(a'-Δb',b'+Δa') 

call it (a'',b''). The third step,

again, RQQO and RQ=Δ, and the new point R would have coordinate (a''-Δb'',b''+Δa'')

Needless to do more steps, the pattern is quite neat. HC is always reduced by Δ*VC at that point, and VC is always increased by Δ*HC at that point, if we write the ith step of HC and VC as HCi and VCi, then, 

HCi+1=HCi-Δ·VCi.

VCi+1=VCi+Δ·HCi.

 Now let us write the expressions out in terms of the original a and b and try to find some pattern. Spoiler alert, the terms will look exactly like binomial coefficients but with interchanging signs. The trick is to look at terms of different orders one by one, namely coefficients of Δ0, Δ1, Δ2... First the terms without Δ, so they are the original a and b, at each step, they remain unchanged as whatever is added or subtracted is multiplied by a factor of Δ, so the added or subtracted terms are at least of order Δ1, so a and b remain unchanged for any steps. Now the Δ1 term, because a and b are always in every step, when they are multiplied by Delta and added or substracted to VC or HC, there is always an Δ·a or Δ·b picked up by VC or HC in every step, from the 1st step onward, namely:

so at ith step we always have a plus or minus i·Δ term in VC or HC. By the same logic, these Δ1 terms will also be multiplied by a Δ then added or subtracted to VC or HC, in every step from the second step onward, so there will always be a (i-1)·Δ2  term added or subtracted at the ith step:
now we find the Δ2 term for the ith step would be [1+2+3+...(i-1)]. By the same logic, this Δ2 term will be multiplied by a Δ then added or subtracted back. So from the 3rd step onward, there will be a Δ3 term with coefficient [1+(1+2)+(1+2+3)+...+(1+2+3+...+i-2)] added or subtracted, for any ith step. Now the pattern should become clear, needless to do the Δ4 terms in specific. The result of first 6 steps look like,
And again they look exactly like binomial expansion but with interchanging signs, so all of the coefficients are binomial coefficients as well. Now instead of just using the binomial coefficients and proceed, let us invent a new set of summation expressions, where it is equivalent to binomial coefficients.


a general formula would be:

nm=1m-1+2m-1+3m-1+...+nm-1

with some integers m and n. To calculate any nm, one can use the definition above add its way up to get a result, but one can also use the multiplication form to get the result quicker,

nm=n(n+1)(n+2)...(n+m-1)m!

and this addition formula is equivalent to the binomial coefficient, related by:

nm=n+m-1m 

hopefully it is obvious to see what the summation expression represent, and of course, as for why, like how it is related to binomial coefficient, how summing up numbers have an equivalent multiplication form, if it has generalizations to non-integers and so on, these questions deserve another blog purely for summation form and binomial coefficients, our main goal here is about sine and cosine. One more thing about the reason we introduce this summation form rather than just using the binomial coefficients, is because the summation form is defined from summing up numbers which is exactly what is going on in the evolution of HC and VC in our case, while binomial coefficient is defined from combinations and permutations, not as directly related. 

Now, using the summation form as coefficients, HC and VC after 6 steps would look like:

HC=a-61Δb-52Δ2a+43Δ3b+34Δ4a-25Δ5b+16Δ6a

VC=b+61Δa-52Δ2b-43Δ3a+34Δ4b+25Δ5a-16Δ6b

and the result after n steps would be:

HC=a-n1Δb-n-12Δ2a+n-23Δ3b+n-34Δ4a-···1nΔna

VC=b+n1Δa-n-12Δ2b-n-23Δ3a+n-34Δ4b+···1nΔnb

use the equivalent multiplication form as coefficients:

HC=a-n1!Δb-(n-1)n2!Δ2a+(n-2)(n-1)n3!Δ3b+(n-3)(n-2)(n-1)n4!Δ4a-...1×2×3···nn!Δna

VC=b+n1!Δa-(n-1)n2!Δ2b-(n-2)(n-1)n3!Δ3a+(n-3)(n-2)(n-1)n4!Δ4b+...1×2×3···nn!Δnb

Going back to our setup, OC rotates an angle β to become OE, on the other hand, in the limiting case of our discrete rotation model, it would take infinite steps to complete the discrete rotation, let us call the number of steps N(even though N is infinite). Now in the limiting case, the rotation becomes perfect, the path that the tangent movements swiped through is exactly equal to the angle β, or the arc length β, so we have:

β=NΔ

Δ=βN

now try to substitute N and β into HC:
 
HC=a-N1!βNb-(N-1)N2!(βN)2a+(N-2)(N-1)N3!(βN)3b+(N-3)(N-2)(N-1)N4!(βN)4a-··· 

but as N is infinite, the N-1, N-2 or N minus any finite number term would cancel out with an N on the denominator, so we have

HC=a-βb-β2a+β3b+β4a-···

VC=b+βa-β2b-β3a+β4b+···

now all of the terms have an a or b, rearrange the equations by a and b we get

HC=a(1-β2+β4-β6+···)-b(β-β3+β5-β7+···)

VC=b(1-β2+β4-β6+···)+a(β-β3+β5-β7+···)

remember in our setup, HC is nothing but cosα+β and VC is just sinα+β, so

cosα+β=a(1-β2+β4-β6+···)-b(β-β3+β5-β7+···)

sinα+β=b(1-β2+β4-β6+···)+a(β-β3+β5-β7+···)

now let the angle α be 0, such that the rotation actually starts from the horizon or the positive x-axis, then we have b=0 and a=1,

cosβ=1-β2+β4-β6+···

sinβ=β-β3+β5-β7+···

there we have it, the sine and cosine expansion in terms of angle(or arc length). 
Now coming back to the equations where α0, one might have noticed that we accidentally derived the angle addition formulae for sine and cosine on the way of deriving sine and cosine expansion, as a is just cosα and b is just sinα according to definition also using the sine and cosine expansion as we discovered,

cosα+β=cosαcosβ-sinαsinβ

sinα+β=sinαcosβ+cosαsinβ

Comments

Popular posts from this blog

Two visualizing proofs of the Pythagorean theorem