# De Moivre's formula

De Moivre's formula In mathematics, de Moivre's formula (also known as de Moivre's theorem and de Moivre's identity) states that for any real number x and integer n it holds that {displaystyle {big (}cos x+isin x{big )}^{n}=cos nx+isin nx,} where i is the imaginary unit (i2 = −1). The formula is named after Abraham de Moivre, although he never stated it in his works. The expression cos x + i sin x is sometimes abbreviated to cis x.

The formula is important because it connects complex numbers and trigonometry. By expanding the left hand side and then comparing the real and imaginary parts under the assumption that x is real, it is possible to derive useful expressions for cos nx and sin nx in terms of cos x and sin x.

As written, the formula is not valid for non-integer powers n. However, there are generalizations of this formula valid for other exponents. These can be used to give explicit expressions for the nth roots of unity, that is, complex numbers z such that zn = 1.

Contents 1 Example 2 Relation to Euler's formula 3 Proof by induction 4 Formulae for cosine and sine individually 5 Failure for non-integer powers, and generalization 5.1 Roots of complex numbers 6 Analogues in other settings 6.1 Hyperbolic trigonometry 6.2 Extension to complex numbers 6.3 Quaternions 6.3.1 Example 6.4 2×2 matrices 7 References 8 External links Example For {displaystyle x=30^{circ }} and {displaystyle n=2} , de Moivre's formula asserts that {displaystyle left(cos(30^{circ })+isin(30^{circ })right)^{2}=cos(2cdot 30^{circ })+isin(2cdot 30^{circ }),} or equivalently that {displaystyle left({frac {sqrt {3}}{2}}+{frac {i}{2}}right)^{2}={frac {1}{2}}+{frac {i{sqrt {3}}}{2}}.} In this example, it is easy to check the validity of the equation by multiplying out the left side.

Relation to Euler's formula De Moivre's formula is a precursor to Euler's formula {displaystyle e^{ix}=cos x+isin x,} which establishes the fundamental relationship between the trigonometric functions and the complex exponential function.

One can derive de Moivre's formula using Euler's formula and the exponential law for integer powers {displaystyle left(e^{ix}right)^{n}=e^{inx},} since Euler's formula implies that the left side is equal to {displaystyle left(cos x+isin xright)^{n}} while the right side is equal to {displaystyle e^{inx}=cos nx+isin nx.} Proof by induction The truth of de Moivre's theorem can be established by using mathematical induction for natural numbers, and extended to all integers from there. For an integer n, call the following statement S(n): {displaystyle (cos x+isin x)^{n}=cos nx+isin nx.} For n > 0, we proceed by mathematical induction. S(1) is clearly true. For our hypothesis, we assume S(k) is true for some natural k. That is, we assume {displaystyle left(cos x+isin xright)^{k}=cos kx+isin kx.} Now, considering S(k + 1): {displaystyle {begin{alignedat}{2}left(cos x+isin xright)^{k+1}&=left(cos x+isin xright)^{k}left(cos x+isin xright)\&=left(cos kx+isin kxright)left(cos x+isin xright)&&qquad {text{by the induction hypothesis}}\&=cos kxcos x-sin kxsin x+ileft(cos kxsin x+sin kxcos xright)\&=cos((k+1)x)+isin((k+1)x)&&qquad {text{by the trigonometric identities}}end{alignedat}}} See angle sum and difference identities.

We deduce that S(k) implies S(k + 1). By the principle of mathematical induction it follows that the result is true for all natural numbers. Now, S(0) is clearly true since cos(0x) + i sin(0x) = 1 + 0i = 1. Finally, for the negative integer cases, we consider an exponent of −n for natural n.

{displaystyle {begin{aligned}left(cos x+isin xright)^{-n}&={big (}left(cos x+isin xright)^{n}{big )}^{-1}\&=left(cos nx+isin nxright)^{-1}\&=cos(-nx)+isin(-nx).qquad (*)\end{aligned}}} The equation (*) is a result of the identity {displaystyle z^{-1}={frac {bar {z}}{|z|^{2}}},} for z = cos nx + i sin nx. Hence, S(n) holds for all integers n.

Formulae for cosine and sine individually See also: List of trigonometric identities For an equality of complex numbers, one necessarily has equality both of the real parts and of the imaginary parts of both members of the equation. If x, and therefore also cos x and sin x, are real numbers, then the identity of these parts can be written using binomial coefficients. This formula was given by 16th century French mathematician François Viète: {displaystyle {begin{aligned}sin nx&=sum _{k=0}^{n}{binom {n}{k}}(cos x)^{k},(sin x)^{n-k},sin {frac {(n-k)pi }{2}}\cos nx&=sum _{k=0}^{n}{binom {n}{k}}(cos x)^{k},(sin x)^{n-k},cos {frac {(n-k)pi }{2}}.end{aligned}}} In each of these two equations, the final trigonometric function equals one or minus one or zero, thus removing half the entries in each of the sums. These equations are in fact valid even for complex values of x, because both sides are entire (that is, holomorphic on the whole complex plane) functions of x, and two such functions that coincide on the real axis necessarily coincide everywhere. Here are the concrete instances of these equations for n = 2 and n = 3: {displaystyle {begin{alignedat}{2}cos 2x&=left(cos xright)^{2}+left(left(cos xright)^{2}-1right)&{}={}&2left(cos xright)^{2}-1\sin 2x&=2left(sin xright)left(cos xright)&&\cos 3x&=left(cos xright)^{3}+3cos xleft(left(cos xright)^{2}-1right)&{}={}&4left(cos xright)^{3}-3cos x\sin 3x&=3left(cos xright)^{2}left(sin xright)-left(sin xright)^{3}&{}={}&3sin x-4left(sin xright)^{3}.end{alignedat}}} The right-hand side of the formula for cos nx is in fact the value Tn(cos x) of the Chebyshev polynomial Tn at cos x.

Failure for non-integer powers, and generalization De Moivre's formula does not hold for non-integer powers. The derivation of de Moivre's formula above involves a complex number raised to the integer power n. If a complex number is raised to a non-integer power, the result is multiple-valued (see failure of power and logarithm identities). For example, when n = 1 / 2 , de Moivre's formula gives the following results: for x = 0 the formula gives 11/2 = 1, and for x = 2π the formula gives 11/2 = −1.

This assigns two different values for the same expression 11/2, so the formula is not consistent in this case.

On the other hand, the values 1 and −1 are both square roots of 1. More generally, if z and w are complex numbers, then {displaystyle left(cos z+isin zright)^{w}} is multi-valued while {displaystyle cos wz+isin wz} is not. However, it is always the case that {displaystyle cos wz+isin wz} is one of the values of {displaystyle left(cos z+isin zright)^{w}.} Roots of complex numbers A modest extension of the version of de Moivre's formula given in this article can be used to find the nth roots of a complex number (equivalently, the power of 1 / n ).

If z is a complex number, written in polar form as {displaystyle z=rleft(cos x+isin xright),} then the n nth roots of z are given by {displaystyle r^{frac {1}{n}}left(cos {frac {x+2pi k}{n}}+isin {frac {x+2pi k}{n}}right)} where k varies over the integer values from 0 to n − 1.