Navigation   Home   Search   Site map

# document.write (document.title)

 Contact Graeme   Home   Email   Twitter
 Math Help > Basic Algebra > Factoring > Solving cubic, quartic, higher degree > Cubic Formula - Cardano's method of solving a depressed cubic

### Cardano's method of solving a depressed cubic

All cubic equations have a real root.  Why?  Because when x is very big and positive, x³ "takes over" and makes the polynomial's value big enough to stay on one side of the x-axis.  When x is very big and negative, x³ "takes over" again, and makes the polynomial's value big enough to stay on the other side of the x-axis.  Somewhere in between, the polynomial's value must cross the x-axis, and at this point it is zero.  This is true because polynomial functions are continuous.  So the trick is to find one real root, r, then divide the cubic equation by (x-r) to reduce the equation to a quadratic, and then it is easy to find the other two roots.

A warning: If there are three different real roots, this formula won't work.  (That is, it won't work without using complex numbers.)  But there is a very interesting fact about the tangent lines of the cubic function.

Now, let's get started: Let the cubic equation be

 ax³+bx²+cx+d=0

Now we eliminate the second-order term by letting x=y-b/(3a). That changes the equation to this:

y³ + (c/a-b²/(3a²))y + (d/a+2b³/(27a³)-bc/(3a²)) = 0

Now let

 A=c/a-b²/(3a²)

and let

 B=d/a+2b³/(27a³)-bc/(3a²)

This is a "depressed cubic" of the form y³+Ay+B=0.

Now if you let A=3st and B=t³-s³ then y=s-t will be a solution of the depressed cubic.  To see that's true, just substitute 3st in place of A, and substitute s-t in place of y, and simplify the equation:

y³+Ay+B=0
(s-t)³+3st(s-t)+B=0
s³-3s²t+3st²-t³+3s²t-3st²+B=0
s³-t³+B=0
B=t³-s³

Now you just need to find two numbers such that three times their product is equal to A and the difference of their cubes is B.

3st=A
t³-s³=B

Solve this for s by substituting

t=1/(3s)

into the second equation:

(A/(3s))³ - s³ = B

Multiply through by 27s³ and move all the terms to the left side of the equation to get

27s6+27Bs3-A3=0

Here we can use the quadratic formula to solve for s³

s³ = -27B/54 ± sqrt(27²B²+4*27*A³)/54
s³ = -B/2 ± sqrt(B²+4A³/27)/2
s³ = -B/2 ± sqrt(B²/4+A³/27)

Now t³=s³+B, so

t³ = B/2 ± sqrt(B²/4+A³/27)

Remember y=s-t, so

y=cuberoot(-B/2 + sqrt(B²/4+A³/27)) - cuberoot(B/2 + sqrt(B²/4+A³/27))

or

y=cuberoot(-B/2 - sqrt(B²/4+A³/27)) - cuberoot(B/2 - sqrt(B²/4+A³/27))

You should notice these two values of y are actually the same, because cuberoot(-x)=-cuberoot(x), and x-y=(-y)-(-x).  So

y=cuberoot(-B/2 + sqrt(B²/4+A³/27)) - cuberoot(B/2 + sqrt(B²/4+A³/27))

Remember x=y-b/(3a)

 x=cuberoot(-B/2 + sqrt(B²/4+A³/27)) - cuberoot(B/2 + sqrt(B²/4+A³/27))-b/(3a)

Now, let me summarize:

 ax³+bx²+cx+d=0
 A=c/a-b²/(3a²)
 B=d/a+2b³/(27a³)-bc/(3a²)
 x=cuberoot(-B/2 + sqrt(B²/4+A³/27)) - cuberoot(B/2 + sqrt(B²/4+A³/27))-b/(3a)

Now let r be this root. The other roots can be found by dividing ax³+bx²+cx+d by (x-r), and solving the resulting quadratic using the quadratic formula.

Now, as I indicated, cubic equations that have three different real roots can't be solved by this method.  When you try, you'll see the quadratic equation you solve to get s³ and t³ has no real roots.

### Example:

Here's some more bad news, or perhaps it's just a bit odd.  I'll illustrate this odd thing with an example:

x³-15x²+81x-175=0

a = 1
b = -15
c = 81
d = -175

A=c/a-b²/(3a²)
A=81-225/3
A=81-75
A=6

B=d/a+2b³/(27a³)-bc/(3a²)
B=-175-2*15^3/27+15*81/3
B=-175-2*5^3+15*27
B=-175-250+405
B=-20

x=cuberoot(-B/2  + sqrt(B�/4+A³/27)) -  cuberoot(B/2  +  sqrt(B²/4+A³/27))-b/(3a)
x=cuberoot(20/2  + sqrt(400/4+216/27)) - cuberoot(-20/2  + sqrt(400/4+216/27))+15/3
x=cuberoot(10  + sqrt(100+8)) - cuberoot(-10  + sqrt(100+8))+5
x=cuberoot(10  + sqrt(108)) - cuberoot(-10  + sqrt(108))+5

It looks as if this is as far as this expression can be simplified, but looks can be deceiving.  If you use a calculator to figure this out, you'll see it's exactly 7, to whatever precision you calculate it!

This is the odd thing that can make this procedure difficult to use.  Here is some examples of similar relations:

1 = cuberoot(sqrt(5)+2) - cuberoot(sqrt(5)-2)
2 = cuberoot(sqrt(108)+10) - cuberoot(sqrt(108)-10)
3 = cuberoot(sqrt(756)+27) - cuberoot(sqrt(756)-27)
4 = cuberoot(sqrt(3200)+56) - cuberoot(sqrt(3200)-56)
5 = cuberoot(sqrt(10125)+100) - cuberoot(sqrt(10125)-100)

In general, for any value of x, if you let A=(x³+3x²)/2, and B=A²+x³, then

x = cuberoot(sqrt(B)+A) - cuberoot(sqrt(B)-A)

### Internet references

Wikipedia: Cubic_function — Cardano's method

Maths.org: Cardano's method of solving cubic polynomials

Ken Ward's math pages: Cardano's Method Examples

### Related pages in this website

Click here for more information about this curious phenomenon.

Quadratic formula

Quartic formula - Ferrari's method of solving a quartic equation

Trig Functions of Special Angles, part 2 -- in this page, we look at a fun problem involving cos 40�, cos 80�, and cos 160�.  It turns out these three cosines are the roots of 8x³-6x+1=0.  Since these three roots are all real, the cubic formula doesn't work without complex numbers, but it does work, and it finds all three roots.

The webmaster and author of this Math Help site is Graeme McRae.