This calculator finds the roots of a complex number and expresses each result in standard a + bi form, where a is the real part and b is the imaginary part. You enter a complex number (as a + bi or a + bj), choose the root degree (square, cube, fourth, etc.), and the calculator returns all distinct roots, each shown as a + bi with values rounded to your chosen precision. The roots are also displayed in polar form, and the first root is given as the principal root.
Formula
For a complex number written as z = a + bi, the n-th roots are given by the formula:
zk = r1/n [ cos( (θ + 2πk) / n ) + i sin( (θ + 2πk) / n ) ]
for k = 0, 1, 2, …, n−1.
- r = √(a² + b²) is the modulus (magnitude) of the complex number.
- θ = atan2(b, a) is the argument (angle) in radians, measured from the positive real axis.
- n is the root degree (e.g., 2 for square root, 3 for cube root).
- r1/n is the principal n-th root of the modulus (a real number).
- The term (θ + 2πk)/n gives the angles of the n distinct roots, equally spaced around the circle.
Each root is then converted to a + bi form using Euler’s formula: cos φ + i sin φ = eiφ.
Worked Example
Using the default values: z = 1 + 2i, n = 3 (cube root).
- Compute the modulus: r = √(1² + 2²) = √5 ≈ 2.23607
- Compute the argument: θ = atan2(2, 1) ≈ 1.10715 radians (63.435°)
- Principal cube root of modulus: r1/3 = (√5)1/3 ≈ 1.30766
- For k = 0: angle = 1.10715/3 ≈ 0.36905 rad; root = 1.30766 (cos 0.36905 + i sin 0.36905) ≈ 1.2206 + 0.4719i
- For k = 1: angle = (1.10715 + 2π)/3 ≈ 2.46323 rad; root ≈ −1.0522 + 0.7759i
- For k = 2: angle = (1.10715 + 4π)/3 ≈ 4.55741 rad; root ≈ −0.1684 − 1.2478i
Thus the three cube roots of 1+2i are approximately 1.2206+0.4719i, −1.0522+0.7759i, and −0.1684−1.2478i. The calculator’s first output (principal root) is 1.2206+0.4719i, matching the k=0 result.
How to Use the Calculator
Enter the complex number in the first field. You can type it in standard form like 3+4i, 2-5j, or just a real number like -7 (the imaginary part is then 0). The calculator accepts ‘i’ or ‘j’ as the imaginary unit. Then enter the root degree n (a positive integer between 2 and 12). The calculator will return:
- Principal root – the root for k=0, which is the one you get from the standard formula.
- All roots – a list of all n distinct roots in a+bi form, separated by semicolons.
You can adjust the number of decimal places (0–6) for the output. The default is 4 decimals, which is enough for most purposes.
Why Roots of Complex Numbers Matter
Finding roots of complex numbers is not just an abstract exercise. It appears in:
- Solving polynomial equations – every polynomial of degree n has exactly n complex roots (Fundamental Theorem of Algebra), and those roots often come in complex conjugate pairs.
- Signal processing – roots of unity (solutions to zn = 1) are used in the Fast Fourier Transform (FFT) and digital filter design.
- Control theory – the poles of a transfer function are roots of the characteristic equation; their positions in the complex plane determine system stability.
- Fractals – the Mandelbrot set and Julia sets are generated by iterating complex functions, and root-finding is used in some fractal rendering algorithms.
- Physics and engineering – AC circuit analysis, quantum mechanics, and fluid dynamics all use complex numbers, and roots appear when solving differential equations.
Common Mistakes and Pitfalls
Here are the most frequent errors people make when computing complex roots by hand or using a calculator:
- Forgetting the modulus root – you must take the n-th root of the modulus, not just divide the angle. For example, the cube root of 8 is 2, not 8/3.
- Using degrees instead of radians – the formula works in radians. If you use degrees, you must convert: 180° = π radians.
- Ignoring the 2πk term – without it, you only get one root. The 2πk term adds full rotations to the angle, giving all n distinct roots.
- Mixing up the sign of the imaginary part – always use atan2(b, a) to get the correct quadrant. A common mistake is to use arctan(b/a) which fails for negative real parts.
- Rounding too early – if you round intermediate values, the final roots can be noticeably off. Keep full precision until the end.
How to Verify Your Results
After computing the roots, you can check them by raising each root to the n-th power. For example, if you found a cube root of 1+2i, then (root)³ should equal 1+2i exactly (up to rounding). Many calculators and software packages (like Python’s cmath or MATLAB) have built-in functions for this, but you can also do it manually using the binomial expansion or polar form.
Another quick check: the sum of all n roots of a complex number is 0 (for n ≥ 2). This is a consequence of the roots being equally spaced around a circle centered at the origin. If your roots don’t sum to zero, you’ve made an error.
Limitations and Accuracy
This calculator uses double-precision floating-point arithmetic, which gives about 15–16 significant decimal digits. For most practical purposes, that is more than enough. However, for very large or very small numbers (e.g., 1030 or 10-30), rounding errors can accumulate. Also, if the real or imaginary part is extremely close to zero, the output may show a tiny nonzero value like 1e-15 instead of exactly 0; this is a normal artifact of floating-point math.
The calculator assumes the principal argument θ is in the range (−π, π]. This is the standard convention used by most calculators and programming languages (atan2). If you need the argument in [0, 2π), you can add 2π to negative results.
Frequently Asked Questions
How do I enter a complex number like 3 – 4i?
Simply type 3-4i or 3-4j in the input field. The calculator accepts both ‘i’ and ‘j’ as the imaginary unit. Spaces are ignored, so you can type 3 - 4i if you prefer.
What is the principal root?
The principal root is the root obtained by taking the principal argument (the angle in (−π, π]) and dividing it by n. It corresponds to k=0 in the formula. For positive real numbers, the principal root is the usual positive root. For complex numbers, it’s the root with the smallest positive angle (or the one closest to the positive real axis).
Can I find the square root of a negative number?
Yes. For example, the square root of -4 is 2i and -2i. In the calculator, enter -4+0i (or just -4) and set n=2. The principal root is 0+2i, which is the conventional square root of -4.
Why are there n roots, not just one?
Because the equation zn = w has exactly n solutions in the complex plane. This is a consequence of the Fundamental Theorem of Algebra. Geometrically, the n roots are points equally spaced on a circle of radius r1/n, starting at angle θ/n and then adding 2π/n each time.
What if I get a result like 1.0000+0.0000i?
That’s normal. Due to rounding, a root that should be exactly 1 (like the cube root of 1) may show as 1.0000+0.0000i. The tiny imaginary part is just a rounding artifact; you can treat it as 0.
Can this calculator handle roots of unity?
Yes. To find the n-th roots of unity, enter 1+0i (or just 1) as the complex number and set the root degree to n. The calculator will return all n roots, which are equally spaced on the unit circle.
Related
Formula used
in z | Complex number | - | 1+2i | - | - in n | Root degree | - | 3 | 2 | 12 out r | Principal root | a+bi | ... | 4 out all | All roots | a+bi | ... | 4
Each line is one input (in, sel, list) or one result (out: label, unit, formula, decimals). How the calculators work
Method: the standard formula for this calculation, rounded as each result states. See how the calculators work or report an error.
- Days Since Last Quarter: How to Calculate It
- Days Since 0 in R: Date Arithmetic Explained
- Days Remaining Countdown: How to Calculate
- Days in Each Quarter of the Year
- Days After B/L Date: Meaning & Shipping Timeline
- Days Remaining in Year Calculator