Understanding the complex polar form and De Moivre calculator — concept and principle
Any complex number a + bi can be written in rectangular form (a, b) or in polar form r(cos θ + i sin θ), where r is the distance from the origin and θ is the angle from the positive real axis. This calculator converts a + bi to polar form, raises it to a power n with De Moivre's theorem and gives its principal square root. It is used for powers and roots of complex numbers, phasors in electrical engineering and rotations in the plane.
How it is calculated
- Modulus: r = √(a² + b²).
- Angle: θ = atan2(b, a), shown in degrees in the range −180° to 180°.
- Power (De Moivre): zⁿ = rⁿ(cos nθ + i sin nθ).
- Square root: √z = √r (cos θ/2 + i sin θ/2); the other root is its negative.
The inputs are plain numbers with no units; the angle is in degrees.
The principle
Multiplying two complex numbers multiplies their moduli and adds their angles. Multiplying z by itself n times therefore multiplies r by itself n times and adds θ to itself n times, which is exactly rⁿ and nθ. This is De Moivre's theorem, and it follows from Euler's formula e^(iθ) = cos θ + i sin θ, because (re^(iθ))ⁿ = rⁿe^(inθ). Going the other way, a square root halves the angle and takes the square root of the modulus. Because θ and θ + 360° describe the same point, halving gives two different answers, θ/2 and θ/2 + 180°, which are the two square roots, one the negative of the other.
Worked example
- Default inputs: a = 1, b = 1, n = 5.
- Modulus: r = √(1² + 1²) = √2 = 1.414213562.
- Angle: θ = atan2(1, 1) = 45°.
- Power: r⁵ = (√2)⁵ = 4√2 ≈ 5.656854, and 5θ = 225°. cos 225° = sin 225° = −√2/2, so z⁵ = 4√2 × (−√2/2)(1 + i) = −4 − 4i. The calculator shows -4 − 4i.
- Square root: √r = 2^(1/4) ≈ 1.189207, θ/2 = 22.5°. 1.189207 × cos 22.5° = 1.098684113 and 1.189207 × sin 22.5° = 0.4550898606, so the roots are ±(1.098684113 + 0.4550898606i).
| Real part | Modulus r |
|---|---|
| 0.25 | 1.030776406 |
| 0.5 | 1.118033989 |
| 0.75 | 1.25 |
| 1 | 1.414213562 |
| 1.25 | 1.600781059 |
| 1.5 | 1.802775638 |
| 2 | 2.236067977 |
How to read the result
If r > 1, powers grow quickly in size; if r < 1, they shrink toward 0; if r = 1, they stay on the unit circle and only rotate. The angle of zⁿ is nθ, which may exceed 360°; subtract multiples of 360° to bring it back. Tiny values such as 1e-15 in place of 0 are floating-point rounding.
Common mistakes
- Using arctan(b/a), which loses the quadrant when a is negative.
- Forgetting the second square root, the negative of the one shown.
- Mixing degrees and radians when working by hand.
- Applying the formula to non-integer n without remembering that it then gives only the principal value.
Frequently asked questions
How do I find all n-th roots of a complex number?
Use r^(1/n) and the angles (θ + 360°·k)/n for k = 0, 1, …, n − 1. The roots sit evenly spaced on a circle.
What is Euler's formula?
e^(iθ) = cos θ + i sin θ. It lets you write z = re^(iθ), which makes multiplication and powers simple.
Why does the angle 45° give z⁵ in the third quadrant?
5 × 45° = 225°, which lies between 180° and 270°, so both parts are negative.
Sources: NIST Digital Library of Mathematical Functions, §1.9 and §4.14 (dlmf.nist.gov) · Needham, T., Visual Complex Analysis, Oxford University Press