Complex Number Calculator (Polar ↔ Rectangular Form)

A complex number can be written in rectangular form a + bi or in polar form r∠θ, where r is the magnitude and θ the angle from the real axis. This complex number calculator converts either way — the same conversion used for phasors when working with impedance and reactance in AC circuits.

calculated
calculated
Type in any field to change it. Press × on a value to calculate that field instead.

How to use the complex number calculator

To convert rectangular to polar, enter the real part a and imaginary part b; the calculator returns the magnitude r and the angle θ. To convert polar to rectangular, clear a and b and enter r and θ instead. The angle can be shown in degrees, radians or other units.

Complex number conversion formulas

r = √(a² + b²)  ·  θ = atan2(b, a)  ·  a = r cos θ  ·  b = r sin θ

In exponential form, a + bi = r eiθ (Euler’s formula).

Example

z = 3 + 4i:

  • r = √(3² + 4²) = 5
  • θ = atan2(4, 3) = 53.13° (0.9273 rad)
  • So 3 + 4i = 5∠53.13°

Unit phasors (r = 1)

Angle θ Real part cos θ Imaginary part sin θ
0° 1.0000 0.0000
30° 0.8660 0.5000
45° 0.7071 0.7071
60° 0.5000 0.8660
90° 0.0000 1.0000
120° -0.5000 0.8660
135° -0.7071 0.7071
150° -0.8660 0.5000
180° -1.0000 0.0000
-90° 0.0000 -1.0000
-45° 0.7071 -0.7071

Notes

  • An angle and that angle ± 360° describe the same complex number.
  • In electrical work, an impedance Z = R + jX has magnitude |Z| = √(R² + X²) and phase angle θ = atan(X/R); cos θ is the power factor — see the kVA to kW calculator.

Frequently asked questions

How do I convert a complex number to polar form?

r = √(a² + b²) and θ = atan2(b, a). For 3 + 4i, r = 5 and θ = 53.13°, so 3 + 4i = 5∠53.13°.

How do I convert polar form to rectangular form?

a = r cos θ and b = r sin θ. In this calculator, clear the real and imaginary parts and enter r and θ instead.

Why use atan2 instead of arctan(b/a)?

arctan(b/a) cannot tell 1 + i from −1 − i, because both give b/a = 1. atan2 uses the signs of both parts and returns the angle in the correct quadrant, from −180° to +180°.

Where are polar complex numbers used?

In AC circuit analysis, voltages, currents and impedances are phasors — a magnitude and a phase angle. Multiplying and dividing is easiest in polar form (multiply magnitudes, add angles), adding is easiest in rectangular form.

Embed this calculator

Free to use on your website or blog. Copy this code: