In mathematics, de Moivre's formula (also known as de Moivre's theorem and de Moivre's identity) states that for any real number and integer it holds that

where is the imaginary unit (). The formula is named after Abraham de Moivre, although he never stated it in his works. The expression is sometimes abbreviated to .

De Moivre's formula

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 is real, it is possible to derive useful expressions for and in terms of and .

De Moivre's formula

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

De Moivre's formula

Example

For and , de Moivre's formula asserts that

or equivalently that

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

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

since Euler's formula implies that the left side is equal to while the right side is equal to

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 , call the following statement :

For , we proceed by mathematical induction. is clearly true. For our hypothesis, we assume is true for some natural . That is, we assume

Now, considering :

See angle sum and difference identities.

We deduce that implies . By the principle of mathematical induction it follows that the result is true for all natural numbers. Now, is clearly true since . Finally, for the negative integer cases, we consider an exponent of for natural .

The equation (*) is a result of the identity

for . Hence, holds for all integers .

Formulae for cosine and sine individually

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 , and therefore also and , 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:

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 , because both sides are entire (that is, holomorphic on the whole complex plane) functions of , and two such functions that coincide on the real axis necessarily coincide everywhere. Here are the concrete instances of these equations for and :

The right-hand side of the formula for is in fact the value of the Chebyshev polynomial at .

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 . 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 , de Moivre's formula gives the following results:

for the formula gives , and

for the formula gives .

This assigns two different values for the same expression , 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 and are complex numbers, then

is multi-valued while

is not. However, it is always the case that

is one of the values of

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 th roots of a complex number (equivalently, the power of ).

If is a complex number, written in polar form as

then the th roots of are given by

where varies over the integer values from 0 to .

This formula is also sometimes known as de Moivre's formula.

Analogues in other settings

Hyperbolic trigonometry

Since , an analog to de Moivre's formula also applies to the hyperbolic trigonometry. For all integers ,

If is a rational number (but not necessarily an integer), then will be one of the values of .