Complex cube roots calculator
A nonzero complex number has exactly three distinct cube roots, separated evenly around a circle in the complex plane.
Run — free
This calculator finds all three with De Moivre's formula and reports every result in both polar and rectangular form. Enter the real and imaginary components of the original number to see its magnitude and principal argument, followed by each root's magnitude, angle in radians and degrees, and real and imaginary components. Zero is handled explicitly and returns three coincident zero roots.
Enter the complex number in rectangular form
Describe the number as a + bi by placing a in the real field and b in the imaginary field. Both entries may be positive, negative, or zero, but they must be finite numbers. For example, 8 + 0i is entered as real 8 and imaginary 0, while -8i is entered as real 0 and imaginary -8. The calculator first converts this pair to polar form. Its magnitude is the distance from the origin, computed as the square root of a squared plus b squared. Its principal argument is found with the two-argument arctangent, which preserves the correct quadrant instead of losing sign information. The reported input angle lies on the usual principal branch from negative pi through positive pi. Supplying rectangular components avoids ambiguity about angle conventions and makes values on either axis straightforward. If both components are zero, the argument is conventionally reported as zero for this calculation, even though the geometric argument of zero is otherwise undefined. The three requested cube-root entries then all represent zero.
How De Moivre's formula produces three roots
Write the input as r times the exponential of i theta, where r is its magnitude and theta is its principal argument. De Moivre's formula says that each cube root has magnitude equal to the real cube root of r. Its possible angles are theta divided by three, theta plus two pi divided by three, and theta plus four pi divided by three. Equivalently, the calculator uses (theta + 2 pi k) / 3 for k equal to 0, 1, and 2. Adding another full turn before dividing creates roots spaced by 120 degrees, which is why there are three distinct answers whenever the input is nonzero. Cubing any one of those roots multiplies its angle by three; the extra full turns disappear, returning the same original complex number. The result labels each root with index k and gives its polar magnitude and angle in both radians and degrees. Angles need not be forced into a single preferred interval because coterminal angles describe the same point, and the displayed sequence makes the direct De Moivre construction especially clear.
Read and verify the rectangular results
Each polar root rho at angle phi is also converted to rectangular form with real part rho cosine phi and imaginary part rho sine phi. This lets you use the answers immediately in algebra that expects x + yi, while retaining the polar values that expose the symmetry of the roots. Small floating-point remnants near zero are normalized, and displayed numbers are rounded deterministically to twelve decimal places. That presentation keeps familiar answers readable, such as zero rather than an extremely small trigonometric artifact, without changing the underlying De Moivre method. To check an answer, cube the rectangular complex value using complex multiplication or cube its polar form by raising the magnitude to the third power and tripling the angle. You should recover the supplied real and imaginary components within ordinary floating-point precision. You can also compare the three outputs visually: their magnitudes must match, and successive angles must differ by 120 degrees. The service is deterministic, uses no network or random values, and charges $0.002 per API item while the page version can run the same calculation directly.
What you can do with it
Check complex algebra homework
Compare a hand-derived De Moivre solution with all three roots in two standard representations.
Prepare roots for plotting
Use rectangular coordinates for points while using polar angles to understand their 120-degree symmetry.
Supply numerical calculations
Copy stable real and imaginary components into engineering, signal-processing, or mathematics workflows.
FAQ
Why are there three answers?
For every nonzero complex number, adding full turns before dividing the argument by three produces three distinct angles separated by 120 degrees.
What happens when the input is zero?
All three listed roots coincide at 0 + 0i. The calculator reports angle zero as a practical convention for that special case.
Which angle units are returned?
Every polar result includes both radians and degrees, so no input angle-unit selection is required.
Why can a root angle be greater than 180 degrees?
The roots follow the direct De Moivre sequence for k = 0, 1, and 2. Coterminal angles identify the same complex point, so the value remains correct.
How much does the API calculation cost?
Each API item costs $0.002. The calculation is also available free in the browser on this page.
For developers — API access
Everything on this page is available programmatically. This section is for teams who want to wire it into their own systems; everyone else can just use the tool above.
API endpoint
Prefer to automate it? One authenticated POST creates the task; the result comes back by webhook or a signed link. The same capability also runs here on the web, by email and from Telegram — and soon from our app too.
Call it from your stack
curl -X POST https://api.kit.forhosting.com/algebra/complex-cube-roots \
-H "Authorization: Bearer $KIT_KEY" \
-H "Content-Type: application/json" \
-d '{"real":8,"imaginary":0}'const res = await fetch("https://api.kit.forhosting.com/algebra/complex-cube-roots", {
method: "POST",
headers: {
"Authorization": `Bearer ${process.env.KIT_KEY}`,
"Content-Type": "application/json"
},
body: JSON.stringify({
"real": 8,
"imaginary": 0
})
});
const { task_id } = await res.json();import os, requests
res = requests.post(
"https://api.kit.forhosting.com/algebra/complex-cube-roots",
headers={"Authorization": f"Bearer {os.environ['KIT_KEY']}"},
json={
"real": 8,
"imaginary": 0
},
)
task_id = res.json()["task_id"]<?php
$res = file_get_contents("https://api.kit.forhosting.com/algebra/complex-cube-roots", false, stream_context_create([
"http" => [
"method" => "POST",
"header" => "Authorization: Bearer " . getenv("KIT_KEY") . "\r\nContent-Type: application/json",
"content" => '{"real":8,"imaginary":0}',
],
]));
$task = json_decode($res, true);body := bytes.NewBufferString(`{"real":8,"imaginary":0}`)
req, _ := http.NewRequest("POST", "https://api.kit.forhosting.com/algebra/complex-cube-roots", body)
req.Header.Set("Authorization", "Bearer "+os.Getenv("KIT_KEY"))
req.Header.Set("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)Example request
{
"real": 8,
"imaginary": 0
}Example response
{
"task_id": "tsk_a1b2c3d4e5f6a1b2c3d4e5f6",
"type": "algebra.complex_cube_roots",
"status": "queued",
"_links": {
"result": "/tasks/tsk_…/result"
}
}The API is asynchronous: the call returns a task_id immediately and the result arrives by webhook. Polling is capped at 1 req/s per task.
Pricing
Published price — no tokens, no invented credits. A failed task is never charged.
Errors
| HTTP | Code | Meaning |
|---|---|---|
401 | unauthorized | Missing or invalid API key. |
402 | insufficient_balance | Your balance doesn't cover the task price. |
404 | unknown_type | That task type doesn't exist. |
429 | rate_limited | Too many requests. Use the webhook instead of polling. |