Ad Space — Top Banner

De Moivre's Theorem Calculator

Raise a complex number to any integer power and find all nth roots.
Polar and rectangular outputs with the root pattern plotted on the plane.

Power and Roots

De Moivre’s theorem turns a brutal calculation (raising a complex number to a high power) into a clean trig operation. Abraham de Moivre published it in 1722, and it remains the fastest way to compute powers and roots of complex numbers by hand.

The theorem:

[r(cos θ + i sin θ)]ⁿ = rⁿ · (cos(nθ) + i sin(nθ))

Raising to the power n multiplies the magnitude by itself n times and multiplies the angle by n. That’s it. Compare this to trying (3 + 4i)⁵ by repeated multiplication: it works, but it is painful and error-prone. In polar form, (5∠53.13°)⁵ = 3125∠265.65°. Two lines of arithmetic.

Why it works (the one-line version): Multiplying complex numbers in polar form multiplies magnitudes and adds angles. Raising to a power is repeated multiplication, so magnitudes get exponentiated and angles get multiplied. That’s De Moivre.

Finding all nth roots: The theorem extends to roots by allowing fractional exponents. The n nth-roots of r·(cos θ + i sin θ) are:

z_k = r^(1/n) · (cos((θ + 360°k) / n) + i sin((θ + 360°k) / n)), k = 0, 1, 2, …, n−1

Every complex number has exactly n nth-roots, and they sit equally spaced on a circle of radius r^(1/n). This single fact is the reason the n nth-roots of 1 form a regular n-gon in the complex plane, and the reason any polynomial of degree n has exactly n roots in the complex numbers (the Fundamental Theorem of Algebra is essentially this geometric picture).

Worked example, raising to a power: Compute (1 + i)⁸.

Convert to polar: r = √(1² + 1²) = √2, θ = 45°.

Apply De Moivre: (√2)⁸ · (cos(8·45°) + i sin(8·45°)) = 16 · (cos 360° + i sin 360°) = 16 · 1 = 16.

That is much faster than expanding (1+i)⁸ by the binomial theorem.

Worked example, finding cube roots: Find the three cube roots of −8.

In polar form: −8 = 8∠180°. Cube-root magnitude: 8^(1/3) = 2.

  • k = 0: 2∠(180°/3) = 2∠60° = 1 + i√3 ≈ 1 + 1.732i
  • k = 1: 2∠((180° + 360°)/3) = 2∠180° = −2
  • k = 2: 2∠((180° + 720°)/3) = 2∠300° = 1 − i√3 ≈ 1 − 1.732i

The three roots sit at the corners of an equilateral triangle on the circle of radius 2 in the complex plane.

Where this shows up:

  • AC circuit analysis (phasors). Impedance, current, and voltage are all complex numbers in polar form. Finding a steady-state response means raising phasors to powers and adding them, exactly what De Moivre is for.
  • Signal processing. The discrete Fourier transform decomposes a signal into complex exponentials, and computing powers of those exponentials is De Moivre at the implementation level.
  • Quantum mechanics. Wavefunctions in position-momentum representation involve complex exponentials whose powers describe time evolution.
  • Pure math. Deriving multiple-angle formulas (cos 3θ, sin 5θ, etc.) by expanding (cos θ + i sin θ)ⁿ with the binomial theorem and matching real and imaginary parts.

Roots of unity: The n nth-roots of 1 are special. Setting r = 1 and θ = 0, the roots become e^(2πik/n) for k = 0 to n−1. These are the vertices of a regular n-gon inscribed in the unit circle, starting at z = 1. Roots of unity appear in number theory (cyclotomic polynomials), signal processing (DFT basis), and cryptography (algebraic structures behind elliptic-curve methods).

Degrees vs radians: The formulas work in either, as long as you stay consistent. Computer implementations use radians internally because that is how sin and cos are defined in the standard library; the converter below accepts degrees for input convenience and shows both.

Note on negative and non-integer powers: De Moivre extends naturally to negative integers (z⁻¹ = (1/r)·(cos(−θ) + i sin(−θ))) and to rational powers (z^(p/q) gives q roots, of which the first p that you usually want is z^p taken q-th root). Non-rational real powers (like z^π) are well-defined but produce a continuous spiral rather than a discrete set of points.


Ad Space — Bottom Banner

Embed This Calculator

Copy the code below and paste it into your website or blog.
The calculator will work directly on your page.