De Moivre's theorem states that eix= cos(x) + isin(x) or that ei5x= cos(5x)+ isin(5x). If the real components of both sides of this equation is taken we can see that : cos(5x) = Re[ei5x ] where Re means take the real component of
Also ei5x= eix*5 =(cos(x) + isin(x))5 using laws of index multiplication.
Therefore cos(5x) = Re[(cos(x) + isin(x))5 ]For easy of writing let us use notation c= cos(x) and s= sin(x). We can thus write cos(5x) =Re[(c+is)5]
Expanding the bracket using binomial theorem cos(5x) = c5-10c3s2+5cs4
Pythagoras's identity states sin2x + cos2x =1Rearranging we can write s2=1-c2
Substituting this expression for s2 we get cos(5x) = c5-10c3(1-c2)+5c(1-c2)2Expanding the brackets and gathering like powers of cos xwe get cos(5x)= 16c5-20c3+5cChanging back notation we can writecos(5x)= 16cos5(x)-20cos3(x)+5cos(x)