Complex Number Calculator
Work with complex numbers in rectangular and polar form. Add, subtract, multiply, divide, convert between forms, and compute magnitude, argument and conjugate – with clear numeric output and step-by-step explanation.
Interactive complex number calculator
You can enter decimals or scientific notation (e.g. -2.5e-3). The calculator formats results
with a reasonable number of significant figures for clarity.
What is a complex number?
A complex number is a number of the form
where \(a\) and \(b\) are real numbers and \(i\) is the imaginary unit with \(i^2 = -1\). The real part is \(\Re(z) = a\), and the imaginary part is \(\Im(z) = b\).
Complex numbers can be represented as points or arrows (vectors) on the complex plane: the horizontal axis corresponds to the real part, and the vertical axis corresponds to the imaginary part.
Rectangular form and polar form
The form \(z = a + bi\) is called rectangular (or Cartesian) form. For many operations, especially addition and subtraction, rectangular form is the most natural.
Complex numbers can also be written in polar form:
where the modulus (or magnitude) \(r = |z|\) and the argument \(\theta = \arg(z)\).
Using Euler's formula \(e^{i\theta} = \cos \theta + i \sin \theta\), we can also write
\[ z = r e^{i\theta}. \]Magnitude and argument
If \(z = a + bi\), then:
Here \(\operatorname{atan2}(b,a)\) is the two-argument arctangent that automatically selects the correct quadrant. The principal argument is usually taken in the interval \((-\pi, \pi]\) (in radians) or \((-180^\circ, 180^\circ]\) (in degrees).
For the special case \(z = 0\), we have \(|z| = 0\) and the argument is undefined, since the zero vector has no direction.
Basic operations with complex numbers
Addition and subtraction
For \(z_1 = a_1 + b_1 i\) and \(z_2 = a_2 + b_2 i\):
Geometrically, addition corresponds to vector addition in the complex plane.
Multiplication
In rectangular form:
In polar form, multiplication is especially simple. If \(z_1 = r_1 \angle \theta_1\) and \(z_2 = r_2 \angle \theta_2\), then
Division
For non-zero \(z_2\), division in rectangular form is:
In polar form:
again highlighting why polar form is natural for division and phasor calculations.
Complex conjugate
The complex conjugate of \(z = a + bi\) is
The product \(z \overline{z} = a^2 + b^2 = |z|^2\) is always real and non-negative, which is used in the formula for division and in many engineering derivations.
Worked example: rectangular to polar
Take \(z = -3 + 4i\).
- Compute the magnitude: \[ |z| = \sqrt{(-3)^2 + 4^2} = \sqrt{9 + 16} = 5. \]
- Compute the argument using \(\operatorname{atan2}\): \[ \theta = \operatorname{atan2}(4, -3) \approx 2.2143\ \text{rad} \approx 126.87^\circ. \]
- Write the polar form: \[ z = 5 \angle 126.87^\circ. \]
Good practice when using complex number calculators
- Always double-check the sign of the imaginary part when entering rectangular form.
- Be clear about whether angles are in radians or degrees; converting incorrectly is a common source of error.
- For engineering phasors, prefer degrees if that is the convention in your field, but radians in advanced mathematics and physics.
- When results matter for safety or design (e.g. control systems, power systems), validate with a second method or software package.
Related complex and algebra tools
For more advanced work with algebra and complex quantities, explore: