# Solving the Cubic Equation for Dummies

[Total: 6    Average: 3.7/5]

Everybody learns the “quadratic formula” for solving equations of the form $A x^2 + B x + C = 0$, even though you don’t really need such a formula, because you can solve for $x$ through the technique of “completing the square”. What you need a formula for is the solution to the cubic equation: $Ax^3 + Bx^2 + Cx + D = 0$. There is no obvious way that “completing the cube” makes the solution into a matter of just taking cube roots in the same way that “completing the square” solves the quadratic in terms of square roots. So how could we derive such a cubic formula? Let’s see if I can convince you that you could derive it, if you thought about it hard enough, in the right way.

We’re given $A x^3 + B x^2 + C x + D = 0$. Let’s assume that $A=1$, so we’re interested in solving an equation of the form $x^3 + B x^2 + Cx + D = 0$. (A moment’s thought will show you that if you can solve that case, you can solve the general case). So by finding a “cubic formula”, we mean finding a function $f(B,C,D)$ that gives the solution. However, in general, a cubic equation has three solutions. So such a function must be multi-valued, with three possible values.

In the quadratic case, the solution is $x = \frac{-b \pm \sqrt{b^2 – 4ac}}{2a}$. We can rewrite this in the following form:
$x = \frac{-b}{2a} + r \frac{\sqrt{b^2 – 4ac}}{2a}$, where $r$ is either plus or minus 1, that is, one of the two solutions of $r^2 = 1$.

Generalizing from the quadratic case, let’s assume that the multi-valuedness comes from the three branches of the cube root function. In other words, let’s look for a function of the form:

$f(B,C,D,r)$

such that you get a solution whenever the parameter $r$ is one of the cube-roots of 1. Let’s fix $B,C,D$ and consider $f$ as a function of $r$. The simplest possible non-constant functions are polynomials. So let’s assume that $f$ has the form: $f(r) = \alpha + \beta r + \gamma r^2$ (where $\alpha, \beta, \gamma$ are implicitly dependent on the coefficients $B,C, D$ of the original cubic equaion.) Since we ultimately want $r$ to be a cube-root of 1, we don’t need to consider terms of the form $r^3$ or higher-order, because those terms are reducible to lower-order terms if $r^3 = 1$

A few facts about the cube roots of 1. There are three cube roots, and they can be written in the form $e^{\frac{2n\pi i}{3}}$. Concretely,

$r_1 = \frac{-1}{2} + \frac{\sqrt{3}}{2} i$

$r_2 = \frac{-1}{2} – \frac{\sqrt{3}}{2} i$

$r_3 = 1$ corresponding to $n = 1, 2, 3$

We can see that $r_2$ is just the square of $r_1$, so we can just write the three solutions as:

$r_1 = q$

$r_2 = q^2$

$r_3 = 1$

where $q$ is $e^{\frac{2 \pi i}{3}}$. Another interesting fact about the solutions is that

$r_1 + r_2 + r_3 = 0$

a fact that can be proved by substitution, or geometrically, by representing the cube roots of 1 as vectors in 2-D complex space. So we know that $1+q+q^2 = 0$ where $q$ is as defined.

So in terms of our function $f(r)$, we want the three solutions to our cubic equation to be: $f(q), f(q^2), f(1)$. Using our polynomial for $f$, this means that we want the three solutions to be:

$x_1 = \alpha + \beta q + \gamma q^2$

$x_2 = \alpha + \beta q^2 + \gamma q^4 = \alpha + \beta q^2 + \gamma q$

$x_3 = \alpha + \beta + \gamma$

Let’s work out a few symmetric combinations of these solutions that will be needed:

$x_1 + x_2 + x_3 = 3 \alpha$ (All other terms vanish, when we use the fact that $1+q+q^2 = 0)$
$x_1 x_2 + x_1 x_3 + x_2 x_3 = 3 (\alpha^2 – \beta \gamma)$ (Again, we used $1+q+q^2 = 0$ to get this).
$x_1 x_2 x_3 = \alpha^3 + \beta^3 + \gamma^3 – 3 \alpha \beta \gamma$

The significance of these combinations is that zeros of a polynomial can be used to factor the polynomial: If $x_1, x_2, x_3$ are the three solutions of $x^3 + Bx^2 + Cx + D = 0$, then we can write:

$x^3 + Bx^2 + Cx + D = (x-x_1)(x-x_2)(x-x_3) = x^3 – (x_1 + x_2 + x_3)x^2 + (x_1 x_2 + x_1 x_3 + x_2 x_3)x – (x_1 x_2 x_3)$

Comparing coefficients tells us that

$(x_1 + x_2 + x_3) = -B$
$(x_1 x_2 + x_1 x_3 + x_2 x_3) = C$
$(x_1 x_2 x_3) = -D$

So using our previous results for those combinations of solutions, we find:

$3 \alpha = -B$. So $\alpha = \frac{-B}{3}$
$3 (\alpha^2 – \beta \gamma) = C$. So $\gamma = \frac{\frac{B^2}{9} – \frac{C}{3}}{\beta}$
$\alpha^3 + \beta^3 + \gamma^3 – 3 \alpha \beta \gamma = -D$.

In the last equation, we can substitute for $\alpha$ and $\gamma$ to get:

$-\frac{B^3}{27} + D + B (\frac{B^2}{9} – \frac{C}{3}) + \beta^3 + \frac{(\frac{B^2}{9} – \frac{C}{3})^3}{\beta^3} = 0$

We can multiply by $\beta^3$ to get:

$\beta^6 +(-\frac{B^3}{27} + D + B (\frac{B^2}{9} – \frac{C}{3})) \beta^3 + (\frac{B^2}{9} – \frac{C}{3})^3)= 0$

Oh no! After all that work to find the solution to a 3rd degree equation, we end up with a 6th degree equation for the coefficient $\beta$. Is that progress? Well, yes it is. Because it’s only a quadratic equation in $\beta^3$:

$(\beta^3)^2 +(-\frac{B^3}{27} + D + B (\frac{B^2}{9} – \frac{C}{3})) \beta^3 + (\frac{B^2}{9} – \frac{C}{3})^3)= 0$

So we can solve this equation for $\beta^3$, take the cube root of the result to get $\beta$ (any cube root will do), and then use the previously derived relationship between $\beta$ and $\gamma$ to find $\gamma$. We already solved for $\alpha$. So then we know all three coefficients in our function.

Then in terms of these values for $\alpha, \beta, \gamma$, we can find our three solutions to the original cubic equation:
$x_1 = \alpha + \beta q + \gamma q^2$
$x_2 = \alpha + \beta q^2 + \gamma q$
$x_3 = \alpha + \beta + \gamma$
(where, remember, q is one of the complex cube roots of 1)

I’m not going to go to the trouble of writing out the explicit solutions in terms of the coefficients of the original cubic equation. The point here is to convince you that you could compute them yourself, if forced to at gunpoint.

Obviously, this general strategy for solving a polynomial equation generalizes to any degree. However, the last stroke of luck, that the 6th degree polynomial equation for one of the coefficients can be rewritten as a quadratic equation, was unexpected. There is no reason to think that such luck will hold out for higher-degree polynomials. As a matter of fact, the French mathematician Evariste Galois, who tragically died in a duel, proved that techniques along the lines of those used here can’t be used to solve a general 5th order (or higher order) equation.

5 replies
1. 2. Greg Bernhardt says:

Great first Insight!

3. 4. 