Cubic function
In algebra, a cubic function is a function of the form
where a is nonzero.
Setting f(x) = 0 produces a cubic equation of the form:
The solutions of this equation are called roots of the polynomial f(x). If all of the coefficients a, b, c, and d of the cubic equation are real numbers then there will be at least one real root (this is true for all odd degree polynomials). All of the roots of the cubic equation can be found algebraically. (This is also true of a quadratic or quartic (fourth degree) equation, but no higherdegree equation, by the Abel–Ruffini theorem). The roots can also be found trigonometrically. Alternatively, numerical approximations of the roots can be found using rootfinding algorithms like Newton's method.
The coefficients do not need to be complex numbers. Much of what is covered below is valid for coefficients of any field with characteristic 0 or greater than 3. The solutions of the cubic equation do not necessarily belong to the same field as the coefficients. For example, some cubic equations with rational coefficients have roots that are nonrational (and even nonreal) complex numbers.
History
Cubic equations were known to the ancient Babylonians, Greeks, Chinese, Indians, and Egyptians.^{[1]}^{[2]}^{[3]} Babylonian (20th to 16th centuries BC) cuneiform tablets have been found with tables for calculating cubes and cube roots.^{[4]}^{[5]} The Babylonians could have used the tables to solve cubic equations, but no evidence exists to confirm that they did.^{[6]} The problem of doubling the cube involves the simplest and oldest studied cubic equation, and one for which the ancient Egyptians did not believe a solution existed.^{[7]} In the 5th century BC, Hippocrates reduced this problem to that of finding two mean proportionals between one line and another of twice its length, but could not solve this with a compass and straightedge construction,^{[8]} a task which is now known to be impossible. Methods for solving cubic equations appear in The Nine Chapters on the Mathematical Art, a Chinese mathematical text compiled around the 2nd century BC and commented on by Liu Hui in the 3rd century.^{[2]} In the 3rd century, the Greek mathematician Diophantus found integer or rational solutions for some bivariate cubic equations (Diophantine equations).^{[3]}^{[9]} Hippocrates, Menaechmus and Archimedes are believed to have come close to solving the problem of doubling the cube using intersecting conic sections,^{[8]} though historians such as Reviel Netz dispute whether the Greeks were thinking about cubic equations or just problems that can lead to cubic equations. Some others like T. L. Heath, who translated all Archimedes' works, disagree, putting forward evidence that Archimedes really solved cubic equations using intersections of two conics, but also discussed the conditions where the roots are 0, 1 or 2.^{[10]}
In the 7th century, the Tang dynasty astronomer mathematician Wang Xiaotong in his mathematical treatise titled Jigu Suanjing systematically established and solved numerically 25 cubic equations of the form x^{3} + px^{2} + qx = N, 23 of them with p, q ≠ 0, and two of them with q = 0.^{[11]}
In the 11th century, the Persian poetmathematician, Omar Khayyám (1048–1131), made significant progress in the theory of cubic equations. In an early paper, he discovered that a cubic equation can have more than one solution and stated that it cannot be solved using compass and straightedge constructions. He also found a geometric solution.^{[12]}^{[13]} In his later work, the Treatise on Demonstration of Problems of Algebra, he wrote a complete classification of cubic equations with general geometric solutions found by means of intersecting conic sections.^{[14]}^{[15]}
In the 12th century, the Indian mathematician Bhaskara II attempted the solution of cubic equations without general success. However, he gave one example of a cubic equation: x^{3} + 12x = 6x^{2} + 35.^{[16]} In the 12th century, another Persian mathematician, Sharaf alDīn alTūsī (1135–1213), wrote the AlMuʿādalāt (Treatise on Equations), which dealt with eight types of cubic equations with positive solutions and five types of cubic equations which may not have positive solutions. He used what would later be known as the "RuffiniHorner method" to numerically approximate the root of a cubic equation. He also developed the concepts of a derivative function and the maxima and minima of curves in order to solve cubic equations which may not have positive solutions.^{[17]} He understood the importance of the discriminant of the cubic equation to find algebraic solutions to certain types of cubic equations.^{[18]}
Leonardo de Pisa, also known as Fibonacci (1170–1250), was able to closely approximate the positive solution to the cubic equation x^{3} + 2x^{2} + 10x = 20, using the Babylonian numerals. He gave the result as 1,22,7,42,33,4,40 (equivalent to 1 + 22/60 + 7/60^{2} + 42/60^{3} + 33/60^{4} + 4/60^{5} + 40/60^{6}),^{[19]} which differs from the correct value by only about three trillionths.
In the early 16th century, the Italian mathematician Scipione del Ferro (1465–1526) found a method for solving a class of cubic equations, namely those of the form x^{3} + mx = n. In fact, all cubic equations can be reduced to this form if we allow m and n to be negative, but negative numbers were not known to him at that time. Del Ferro kept his achievement secret until just before his death, when he told his student Antonio Fiore about it.
In 1530, Niccolò Tartaglia (1500–1557) received two problems in cubic equations from Zuanne da Coi and announced that he could solve them. He was soon challenged by Fiore, which led to a famous contest between the two. Each contestant had to put up a certain amount of money and to propose a number of problems for his rival to solve. Whoever solved more problems within 30 days would get all the money. Tartaglia received questions in the form x^{3} + mx = n, for which he had worked out a general method. Fiore received questions in the form x^{3} + mx^{2} = n, which proved to be too difficult for him to solve, and Tartaglia won the contest.
Later, Tartaglia was persuaded by Gerolamo Cardano (1501–1576) to reveal his secret for solving cubic equations. In 1539, Tartaglia did so only on the condition that Cardano would never reveal it and that if he did write a book about cubics, he would give Tartaglia time to publish. Some years later, Cardano learned about Ferro's prior work and published Ferro's method in his book Ars Magna in 1545, meaning Cardano gave Tartaglia six years to publish his results (with credit given to Tartaglia for an independent solution). Cardano's promise with Tartaglia stated that he not publish Tartaglia's work, and Cardano felt he was publishing del Ferro's, so as to get around the promise. Nevertheless, this led to a challenge to Cardano by Tartaglia, which Cardano denied. The challenge was eventually accepted by Cardano's student Lodovico Ferrari (1522–1565). Ferrari did better than Tartaglia in the competition, and Tartaglia lost both his prestige and income.^{[20]}
Cardano noticed that Tartaglia's method sometimes required him to extract the square root of a negative number. He even included a calculation with these complex numbers in Ars Magna, but he did not really understand it. Rafael Bombelli studied this issue in detail^{[21]} and is therefore often considered as the discoverer of complex numbers.
François Viète (1540–1603) independently derived the trigonometric solution for the cubic with three real roots, and René Descartes (1596–1650) extended the work of Viète.^{[22]}
Critical points and inflection point of a cubic function
The critical points of a function are those values of x where the slope of the function is zero. The critical points of a cubic function f defined by f(x) = ax^{3} + bx^{2} + cx + d, occur at values of x such that the first derivative of the cubic is zero:
The solutions of that equation are the critical points of the cubic equation and are given, using the quadratic formula, by
The expression inside of the square root,
 ,
determines what type of critical points the function has. If Δ_{0} > 0, then the cubic function has a local maximum and a local minimum. If Δ_{0} = 0, then the cubic's inflection point is the only critical point. If Δ_{0} < 0, then there are no critical points. In cases where Δ_{0} ≤ 0, the cubic function is strictly monotonic. The diagram to the right is an example of the case where Δ_{0} > 0. The other two cases do not have the local maximum or the local minimum but still have an inflection point.
The value of Δ_{0} also plays an important role in determining the nature of the roots of the cubic equation and in the calculation of those roots; see below.
The inflection point of a function is where that function changes concavity. The inflection point of our cubic function occurs at:
a value that is also important in solving the cubic equation. The cubic function has point symmetry about its inflection point.
All of the above assumes that the coefficients are real as well as the variable x.
General solution to the cubic equation with real coefficients
This section is about how to solve the cubic equation using various methods. For details and proofs see below. The general cubic equation has the form:

(1)
with a ≠ 0.
Algebraic solution
The algebraic solution of the cubic equation can be derived in a number of different ways. (See for example Cardano's method and Vieta's method below.)
The discriminant
The number and types of roots is determined by the discriminant of the cubic equation,
It turns out that:
 If Δ > 0, then the equation has three distinct real roots.
 If Δ = 0, then the equation has a multiple root and all its roots are real.
 If Δ < 0, then the equation has one real root and two nonreal complex conjugate roots.
General formula
The general solution of the cubic equation involves first calculating:
(If the discriminant Δ has already been calculated then the equality Δ_{1}^{2} − 4Δ_{0}^{3} = −27 a^{2}Δ, can be used to simplify the calculation of C.) There are three possible cube roots implied by the expression, of which at least two are nonreal complex numbers; any of these may be chosen when defining C. (In addition either sign in front of the square root may be chosen unless Δ_{0} = 0 in which case the sign must be chosen so that the two terms inside the cube root do not cancel.)
The general formula for one of the roots, in terms of the coefficients, is as follows:
Note that, while this equality is valid for all nonzero C, it is not the most convenient form for multiple roots (Δ = 0), which is covered in the next section. (The case when C = 0 only occurs when both Δ and Δ_{0} are equal to 0 and is also covered in the next section.)
The other two roots of the cubic equation can be determined using the same equality, using the other two choices for the cube root in the equation for C: denoting the first choice simply as C, the others can be written as (−1/2 + 1/2√3i) C and (−1/2 − 1/2√3i) C.
The above equality can be expressed compactly including all 3 roots as follows:
where ζ = −1/2 + 1/2√3i (which is a cube root of unity). In the case of three real roots, this solution expresses them in terms of nonreal complex terms (since any choice of C is nonreal) whose imaginary components offset each other but cannot be eliminated from the formula.
This formula for the three roots applies even when the coefficients in the cubic are nonreal, although the analysis of the sign of Δ does not hold since Δ is then not real in general.
Multiple roots, Δ = 0
If both Δ and Δ_{0} are equal to 0, then the equation has a single root (which is a triple root):
If Δ = 0 and Δ_{0} ≠ 0, then there are both a double root,
and a simple root,
Trigonometric and hyperbolic solutions
Reduction to a depressed cubic
Dividing ax^{3} + bx^{2} + cx + d = 0 by a and substituting t − b/3a for x we get the equation

(2)
where
The left hand side of equation (2) is a monic trinomial called a depressed cubic, because the quadratic term has coefficient 0.
Any formula for the roots of a depressed cubic may be transformed into a formula for the roots of equation (1) by substituting the above values for p and q and using the relation x = t − b/3a.
Therefore, only equation (2) is considered in the following.
Trigonometric solution for three real roots
When a cubic equation has three real roots, the formulas expressing these roots in terms of radicals involve complex numbers. It has been proved that when none of the three real roots is rational—the casus irreducibilis— one cannot express the roots in terms of real radicals. Nevertheless, purely real expressions of the solutions may be obtained using hypergeometric functions,^{[23]} or more elementarily in terms of trigonometric functions, specifically in terms of the cosine and arccosine functions.
]
The formulas which follow, due to François Viète,^{[22]} are true in general (except when p = 0), and are purely real when the equation has three real roots, but involve complex cosines and arccosines when there is only one real root.
Starting from equation (2), t^{3} + pt + q = 0, let us set t = u cos θ. The idea is to choose u to make equation (2) coincide with the identity
In fact, choosing and dividing equation (2) by we get
Combining with the above identity, we get
and thus the roots are^{[24]}
This formula involves only real terms if p < 0 and the argument of the arccosine is between −1 and 1. The last condition is equivalent to 4p^{3} + 27q^{2} ≤ 0, which itself implies p < 0. Thus the above formula for the roots involves only real terms if and only if the three roots are real.
Denoting by C( p, q) the above value of t_{0}, and using the inequalities 0 ≤ arccos(u) ≤ π for a real number u such that −1 ≤ u ≤ 1, the three roots may also be expressed as
If the three roots are real, we have t_{0} ≥ t_{1} ≥ t_{2}. All these formulas may be straightforwardly transformed into formulas for the roots of the general cubic equation (1), using the back substitution described above.
Hyperbolic solution for one real root
When there is only one real root (and p ≠ 0), it may be similarly represented using hyperbolic functions, as^{[25]}^{[26]}
If p ≠ 0 and the inequalities on the right are not satisfied (the case of three real roots), the formulas remain valid but involve complex quantities.
When p = ±3, the above values of t_{0} are sometimes called the Chebyshev cube root.^{[27]} More precisely, the values involving cosines and hyperbolic cosines define, when p = −3, the same analytic function denoted C_{1/3}(q), which is the proper Chebyshev cube root. The value involving hyperbolic sines is similarly denoted S_{1/3}(q), when p = −3.
Factorization
If the cubic equation ax^{3} + bx^{2} + cx + d = 0 with integer coefficients has a rational root, it can be found using the rational root test: If the root r = ^{m}⁄_{n} is fully reduced, then m is a factor of d and n is a factor of a, so all possible combinations of values for m and n (both positive and negative for one of them) can be checked for whether they satisfy the cubic equation.
The rational root test may also be used for a cubic equation with rational coefficients: by multiplication by the lowest common denominator of the coefficients, one gets an equation with integer coefficients which has exactly the same roots.
The rational root test is particularly useful when there are three real roots because the algebraic solution unhelpfully expresses the real roots in terms of complex entities; if the test yields a rational root, it can be factored out and the remaining roots can be found by solving a quadratic. The rational root test is also helpful in the presence of one real and two complex roots because again, if it yields a rational root, it allows all of the roots to be written without the use of cube roots: If r is any root of the cubic, then we may factor out x − r using polynomial long division to obtain
Hence if we know one root, perhaps from the rational root test, we can find the other two by using the quadratic formula to find the roots of the quadratic ax^{2} + (b + ar)x + c + br + ar^{2}, giving
for the other two roots.
Geometric solutions
Omar Khayyám's solution
As shown in this graph, to solve the thirddegree equation x^{3} + m^{2}x = n where n > 0, Omar Khayyám constructed the parabola y = x^{2}/m, the circle which has as a diameter the line segment [0, n/m^{2}] on the positive xaxis, and a vertical line through the point above the xaxis where the circle and parabola intersect. The solution is given by the length of the horizontal line segment from the origin to the intersection of the vertical line and the xaxis.
A simple modern proof of the method is the following: multiplying the equation by x and regrouping the terms gives
The lefthand side is the value of y^{2} on the parabola. The equation of the circle being y^{2} + x(x − ^{n}⁄_{m2}) = 0, the right hand side is the value of y^{2} on the circle.
Solution with angle trisector
A cubic equation with real coefficients can be solved geometrically using compass, straightedge, and an angle trisector if and only if it has three real roots.^{[28]}^{:Thm. 1}
Nature of the roots in the case of real coefficients
Algebraic nature of the roots
Every cubic equation (1), ax^{3} + bx^{2} + cx +d = 0, with real coefficients and a ≠ 0, has three solutions (some of which may equal each other if they are real, and two of which may be complex nonreal numbers) and at least one real solution r_{1}, this last assertion being a consequence of the intermediate value theorem. If x − r_{1} is factored out of the cubic polynomial, what remains is a quadratic polynomial whose roots r_{2} and r_{3} are roots of the cubic; by the quadratic formula, these roots are either both real (giving a total of three real roots for the cubic) or are complex conjugates, in which case the cubic has one real and two nonreal roots.
It was explained above how to use the sign of the discriminant in order to distinguish between these cases. In fact,

(3)
because a straightforward computation shows that
and, by Vieta's formulas, the right hand side of this equality is equal to
The equality (3) shows that Δ = 0 if and only if the equation has a multiple root. This cannot possibly be the case when r_{2} and r_{3} are nonreal complex numbers, because the fact that r_{1} is real assures that r_{1} is different from r_{2} and from r_{3} and, on the other hand, the fact that r_{2} and r_{3} are nonreal and that each of them is the conjugate of the other one assures that r_{2} ≠ r_{3}.
If r_{2} and r_{3} are nonreal, then
Since this is the product of a nonzero real number by i, its square is a real number less than 0 and therefore Δ < 0. Finally, if the numbers r_{1}, r_{2}, and r_{3} are three distinct real numbers, then the product (r_{1} − r_{2})(r_{1} − r_{3})(r_{2} − r_{3}) is a nonzero real number, and so Δ > 0.
Geometric interpretation of the roots
Three real roots
Viète's trigonometric expression of the roots in the threerealroots case lends itself to a geometric interpretation in terms of a circle.^{[22]}^{[29]} When the cubic is written in depressed form (2), t^{3} + pt + q = 0, as shown above, the solution can be expressed as
Here is an angle in the unit circle; taking 1/3 of that angle corresponds to taking a cube root of a complex number; adding −k2π/3 for k = 1, 2 finds the other cube roots; and multiplying the cosines of these resulting angles by corrects for scale.
For the nondepressed case (1) (shown in the accompanying graph), the depressed case as indicated previously is obtained by defining t such that x = t − b/3a so t = x + b/3a. Graphically this corresponds to simply shifting the graph horizontally when changing between the variables t and x, without changing the angle relationships. This shift moves the point of inflection and the centre of the circle onto the yaxis. Consequently, the roots of the equation in t sum to zero.
One real and two complex roots
In the Cartesian plane
If a cubic is plotted in the Cartesian plane, the real root can be seen graphically as the horizontal intercept of the curve. But further,^{[30]}^{[31]}^{[32]} if the complex conjugate roots are written as g ± hi then g is the abscissa (the positive or negative horizontal distance from the origin) of the tangency point of a line that is tangent to the cubic curve and intersects the horizontal axis at the same place as does the cubic curve; and h is the square root of the tangent of the angle between this line and the horizontal axis.
In the complex plane
With one real and two complex roots, the three roots can be represented as points in the complex plane, as can the two roots of the cubic's derivative. There is an interesting geometrical relationship among all these roots.
The points in the complex plane representing the three roots serve as the vertices of an isosceles triangle. (The triangle is isosceles because one root is on the horizontal (real) axis and the other two roots, being complex conjugates, appear symmetrically above and below the real axis.) Marden's Theorem says that the points representing the roots of the derivative of the cubic are the foci of the Steiner inellipse of the triangle—the unique ellipse that is tangent to the triangle at the midpoints of its sides. If the angle at the vertex on the real axis is less than π/3 then the major axis of the ellipse lies on the real axis, as do its foci and hence the roots of the derivative. If that angle is greater than π/3, the major axis is vertical and its foci, the roots of the derivative, are complex conjugates. And if that angle is π/3, the triangle is equilateral, the Steiner inellipse is simply the triangle's incircle, its foci coincide with each other at the incenter, which lies on the real axis, and hence the derivative has duplicate real roots.
Derivation of the roots
Cardano's method
The solutions can be found with the following method due to Scipione del Ferro and Tartaglia, published by Gerolamo Cardano in 1545 in his book Ars Magna. This method applies to the depressed cubic (2), t^{3} + pt + q = 0. We introduce two variables u and v linked by the condition u + v = t and substitute this in the depressed cubic (2), giving
At this point Cardano imposed a second condition for the variables u and v: 3uv + p = 0. As the first parenthesis vanishes in previous equality, we get u^{3} + v^{3} = −q and u^{3}v^{3} = − p^{3}/27. The combination of these two equations leads to a quadratic equation (since they are the sum and the product of u^{3} and v^{3}). Thus u^{3} and v^{3} are the two roots of the quadratic equation z^{2} + qz − p^{3}/27 = 0. Cardano assumed that q^{2}/4 + p^{3}/27 ≥ 0. He suggested that his readers consult another of his books, De Regula Aliza, which was published only in 1570, for the case in which q^{2}/4 + p^{3}/27 < 0.^{[33]} Solving this quadratic equation and using the fact that u and v may be exchanged, we find
 and
Therefore, u + v is equal to:

(Cardano's formula)
In his book L'Algebra, published in 1572, Rafael Bombelli explained that what was done above still works, with a small difference, when q^{2}/4 + p^{3}/27 < 0, as long as one knows how to use complex numbers.^{[21]} The small difference is due to the fact that a nonzero complex number has 3 cube roots and not just one. Therefore, although the equality uv = − p/3 implies that u^{3}v^{3} = − p^{3}/27, this is not an equivalence. So, we do not simply take any cube root of

(4)
and add it to any cube root of

(5)
(unless one of them is 0); besides, that would provide 9 solutions to equation (2). Instead, since we want to have 3uv = −p, Cardano's formula means the sum of a cube root u of (4) with −p/3u (or, if (4) is equal to 0, the sum of a cube root v of (5) with −p/3v). This only fails if both numbers (4) and (5) are equal to 0, in which case p = q = 0 and Cardano's formula simply means t = ^{3}√0 + ^{3}√0 (= 0), which is compatible with the fact that, since p = q = 0, (2) simplifies to t^{3} = 0.
Actually, it is not necessary to compute the three cube roots of (4). To see why, let ξ = −1/2 + 1/2√3i. Then ξ and ξ (= −1/2 − 1/2√3i = ξ^{2}) are the nonreal cube roots of 1. If u is a cube root of (4), and v is a cube root of (5) such that 3uv = −p, then the roots of (2) are u + v, ξu + ξv, and ξu + ξv, since, in each case, we have the sum of a cube root of (4) with a cube root (5) and moreover the product of these two roots is, in each case, equal to − p/3.
Note that ξ^{3} = 1 and that ξ^{4} = ξ. Thus Cardano's formula, written unambiguously to give the three roots, is
where the cube roots expressed as radicals are defined to be any pair of cube roots whose product is − p/3. If p and q are real and q^{2}/4 + p^{3}/27 < 0, this is the same thing as requiring that the cube roots be complex conjugates, while if p and q are real and q^{2}/4 + p^{3}/27 ≥ 0, the real cube roots can be chosen.
Cardano's formula, interpreted in this way, is equivalent to the general solution given earlier when the coefficient of the quadratic term is 0.
We will examine certain particular cases. Before that, it is convenient to note that, if u is a cube root of (4), if v is a cube root of (5), and if both numbers p and u×v are real, then it is automatically true that u×v = − p/3. This is so because
 (u×v)^{3} = u^{3}×v^{3} = q^{2}/4 − (q^{2}/4 + p^{3}/27) = − p^{3}/27 = (− p/3)^{3}.
Let us now see the particular cases.
 If p and q are real numbers and q^{2}/4 + p^{3}/27 > 0, let u be the real cube root of (4) and let v be the real cube root of (5). Then u×v = − p/3, because u×v is real. So, the roots of the equation (2) are u + v (which is a real number), ξu + ξv, and ξu + ξv. Each of the second and the third roots is the conjugate of the other one. This can be used to prove that they are nonreal. Indeed, two real numbers are the conjugates of each other if and only if they are the same real number. But
 ξu + ξv = ξu + ξv ⇔ (ξ − ξ)(u − v) = 0,
 and this last assertion is false, since ξ ≠ ξ and u ≠ v (because u and v are real numbers whose cubes are distinct).
 If p and q are real numbers and q^{2}/4 + p^{3}/27 < 0, then the numbers (4) and (5) are complex numbers each of which is the conjugate of the other one. Let u be a cube root of (4) and let v be the conjugate of u. Then v^{3} is the conjugate of u^{3} and this proves that v^{3} is equal to (5). So, again, since u×v is real we have u×v = − p/3, and therefore the roots of the equation (2) are u + u, ξu + ξu, and ξu + ξu. In this case all roots are real, since each one of them is the sum of a complex number with its conjugate.
 If p = 0, then the roots of the equation (2) are the cube roots of −q. This is compatible with Cardano's formula, because one of (4) or (5) is 0 and the other is −q.
 If q = 0, then the roots of (2) are 0 and the square roots of −p. Again, this is compatible with Cardano's formula, because if u is a square root of ^{p}⁄_{3}, then u^{3} is a square root of p^{3}/27, and this square root is equal to (4) or to (5), since we are assuming that q = 0. If v is the other square root of ^{p}⁄_{3} then, by the same reason, v^{3} is equal to (4) or to (5) and furthermore if u is equal to (4) then v is equal to (5) and vice versa. But then v = −u and so u + v = u − u = 0. On the other hand, ξu + ξv = (ξ − ξ)×u and so (ξu + ξv)^{2} = (ξ − ξ)^{2}×u^{2} = (−3)×p/3 = −p, which means that ξu + ξv is a square root of −p. Finally, ξu + ξv = (ξ − ξ)×u = −(ξu + ξv), and so it must be the other square root of −p.
 If q^{2}/4 + p^{3}/27 = 0 (but p and q are not 0), then (2) has a simple root, which is 3q/p, and a double root, which is −3q/2p. Again, this is compatible with Cardano's formula. To see why, note that asserting that q^{2}/4 + p^{3}/27 = 0 is equivalent to asserting that 27q^{2}/4p^{3} = −1. If u = v = 3q/2p, then u^{3} = v^{3} = 27q^{3}/8p^{2} = −q/2 and 3uv = 27q^{2}/4p^{2} = −p. Thus, Cardano's formula says that the roots of (2) are u + v = 2u = 3q/p, ξu + ξv = (ξ + ξ)×u = −3q/2p, and ξu + ξv = (ξ + ξ)×u = −3q/2p.
In this last case (that is, when q^{2}/4 + p^{3}/27 = 0 but p and q are not 0), although the computions made above do suggest that 3q/p is a simple root of (2) whereas −3q/2p is a double root (having been obtained in two different ways), they don't really prove it. However, this can be easily confirmed. Just note that
since 27q^{2}/4p^{3} = −1.
The numbers provided by Cardano's formula are solutions of the equation (2), but there might be other solutions besides these. However, this does not occur. Let u and v be numbers such that u^{3} + v^{3} = −q and 3uv = −p. In order to see that u + v, ξu + ξv, and ξu + ξv are the only roots of the polynomial t^{3} + pt + q, it is enough to notice that
Therefore, t^{3} + pt + q = 0 if and only if t = u + v, t = ξu + ξv or t = ξu + ξv.
Vieta's substitution
Starting from the depressed cubic (2), t^{3} + pt + q = 0, we make the substitution t = w − p/3w, known as Vieta's substitution. This results in the equation
Multiplying by w^{3}, it becomes a sextic equation in w, which is in fact a quadratic equation in w^{3}:

(6)
The quadratic formula allows equation (6) to be solved for w^{3}. If w_{1}, w_{2} and w_{3} are the three cube roots of one of the solutions in w^{3}, then the roots of the original depressed cubic are w_{1} − p/3w_{1}, w_{2} − p/3w_{2}, and w_{3} − p/3w_{3}. Another way of expressing the roots is to take ξ = −1/2 + 1/2√3i; then the roots of the original depressed cubic are w_{1} − p/3w_{1}, ξw_{1} − p/3ξw_{1}, and, ξ^{2}w_{1} − p/3ξ^{2}w_{1}. This method only fails when both roots of the equation (6) are equal to 0, but this only happens when p = q = 0, in which case the only solution of equation (2) is 0.
Actually, the substitution originally used by Vieta (in a text published posthumously in 1615) was t = p/3w − w, but it leads to similar computations.^{[34]} More precisely, Vieta introduced a new variable w and he imposed the condition w(t + w) = p/3.
As far as formulae are concerned, Vieta's approach leads to the same result as Cardano's method. However, it is theoretically simpler, for two reasons:
 Each root of the equation (2) is expressed from the start by an expression that involves a single cube root. Therefore, there is no ambiguity as in Cardano's formula.
 It is nearly trivial that there are no other roots besides the ones obtained by this method. This follows from the fact that any complex number can be written as w − p/3w for some other complex number w.
Lagrange's method
In his paper Réflexions sur la résolution algébrique des équations ("Thoughts on the algebraic solving of equations"),^{[35]} Joseph Louis Lagrange introduced a new method to solve equations of low degree.
This method works well for cubic and quartic equations, but Lagrange did not succeed in applying it to a quintic equation, because it requires solving a resolvent polynomial of degree at least six.^{[36]}^{[37]}^{[38]} This is explained by the Abel–Ruffini theorem, which proves that such polynomials cannot be solved by radicals. Nevertheless, the modern methods for solving solvable quintic equations are mainly based on Lagrange's method.^{[38]}
In the case of cubic equations, Lagrange's method gives the same solution as Cardano's. By drawing attention to a geometrical problem that involves two cubes of different size Cardano explains in his book Ars Magna how he arrived at the idea of considering the unknown of the cubic equation as a sum of two other quantities. Lagrange's method may also be applied directly to the general cubic equation (1), ax^{3} + bx^{2} + cx + d = 0, without using the reduction to the depressed cubic equation (2), t^{3} + pt + q = 0. Nevertheless, the computation is much easier with this reduced equation.
Suppose that x_{0}, x_{1} and x_{2} are the roots of equation (1) or (2), and define ξ = −1/2 + 1/2√3i (a complex cube root of 1, i.e. a primitive third root of unity) which satisfies the relation ξ^{2} + ξ + 1 = 0. We now set
This is the discrete Fourier transform of the roots: observe that while the coefficients of the polynomial are symmetric in the roots, in this formula an order has been chosen on the roots, so these are not symmetric in the roots. The roots may then be recovered from the three s_{i} by inverting the above linear transformation via the inverse discrete Fourier transform, giving
The polynomial s_{0} is equal, by Vieta's formulas, to −b/a in case of equation (1) and to 0 in case of equation (2), so we only need to seek values for the other two.
The polynomials s_{1} and s_{2} are not symmetric functions of the roots: s_{0} is invariant, while the two nontrivial cyclic permutations of the roots send s_{1} to ξ s_{1} and s_{2} to ξ^{2}s_{2}, or s_{1} to ξ^{2}s_{1} and s_{2} to ξ s_{2} (depending on which permutation), while transposing x_{1} and x_{2} switches s_{1} and s_{2}; other transpositions switch these roots and multiply them by a power of ξ.
Thus s_{1}^{3}, s_{2}^{3} and s_{1}s_{2} are left invariant by the cyclic permutations of the roots, which multiply them by ξ^{3} = 1. Also s_{1}s_{2} and s_{1}^{3} + s_{2}^{3} are left invariant by the transposition of x_{1} and x_{2} which exchanges s_{1} and s_{2}. As the permutation group S_{3} of the roots is generated by these permutations, it follows that s_{1}^{3} + s_{2}^{3} and s_{1}s_{2} are symmetric functions of the roots and may thus be written as polynomials in the elementary symmetric polynomials and thus as rational functions of the coefficients of the equation. Let s_{1}^{3} + s_{2}^{3} = A and s_{1}s_{2} = B in these expressions, which will be explicitly computed below.
We have that s_{1}^{3} and s_{2}^{3} are the two roots of the quadratic equation z^{2} − Az + B^{3} = 0. Thus the resolution of the equation may be finished exactly as described for Cardano's method, with s_{1} and s_{2} in place of u and v.
Computation of A and B
Setting E_{1} = x_{0} + x_{1} + x_{2}, E_{2} = x_{0} x_{1} + x_{1} x_{2} + x_{2} x_{0} and E_{3} = x_{0} x_{1} x_{2}, the elementary symmetric polynomials, we have, using that ξ^{3} = 1:
The expression for s_{2}^{3} is the same with ξ and ξ^{2} exchanged. Thus, using ξ^{2} + ξ = −1 we get
and a straightforward computation gives
Similarly we have
When solving equation (1) we have E_{1} = −b/a, E_{2} = c/a and E_{3} = −d/a. With equation (2), we have E_{1} = 0, E_{2} = p and E_{3} = −q and thus A = −27q and B = −3p.
Note that with equation (2), we have x_{0} = 1/3(s_{1} + s_{2}) and s_{1}s_{2} = −3p, while in Cardano's method we have set x_{0} = u + v and uv = −1/3p. Thus we have, up to the exchange of u and v, s_{1} = 3u and s_{2} = 3v . In other words, in this case, Cardano's method and Lagrange's method compute exactly the same things, up to a factor of three in the auxiliary variables, the main difference being that Lagrange's method explains why these auxiliary variables appear in the problem.
General solution to the cubic equation with arbitrary coefficients
If we are dealing with a cubic equation whose coefficients belong to some field k (whose characteristic is either 0 or greater than 3), then what was done above algebraically still works, with one exception: the results concerning the sign of the discriminant, since they make no sense for general fields, although the fact that the equation has a multiple root if and only if Δ = 0 is still true (and for the same reason). In this more general case, we work with an extension K of k in which every nonzero element has two square roots and three cube roots. For instance, if k = Q, we can take K = Q, the field of algebraic numbers.
In particular, all that was done above algebraically still works if k = K = C. Therefore, every cubic equation with complex coefficients has some complex root, which is a particular case of the fundamental theorem of algebra.
In this general context, the formulae for roots in the case in which Δ = 0 show that these roots also belong to the field k.
In a field k whose characteristic is either 2 or 3, this approach does not work because then the formulae for the roots became meaningless, since they involve division by 2 and 3.
Galois groups of irreducible cubics
The Galois group of an irreducible separable polynomial of degree n is a transitive subgroup of S_{n}. In particular, the Galois group of an irreducible separable cubic is a transitive subgroup of S_{3} and there are only two such subgroups: S_{3} and A_{3}. There is a simple way of determining the Galois group of a concrete irreducible cubic f(x) over a field k: it is A_{3} if the discriminant of the cubic is the square of an element of k and S_{3} otherwise. Indeed, if Δ is not the square of an element of k, then k[√Δ] is an extension of degree 2 of k. On the other hand, if r_{1}, r_{2}, and r_{3} are the roots of f(x), then, since the equality (3) holds, that is, since Δ = (a^{2}(r_{1} − r_{2})(r_{1} − r_{3})(r_{2} − r_{3}))^{2}, k[√Δ] ⊂ k[r_{1}, r_{2}, r_{3}], and so, by the multiplicativity formula for degrees, the degree of k[r_{1}, r_{2}, r_{3}] over k (that is, the order of the Galois group of f(x)) must be a multiple of the degree of k[√Δ], which is 2. Therefore, it must be an even number, and so the Galois group can only be S_{3}.
On the other hand, if Δ is the square of an element of k, then, again by the equality (3), we have (r_{1} − r_{2})(r_{1} − r_{3})(r_{2} − r_{3}) ∈ k. Therefore, if σ belongs to the Galois group of f(x), then σ maps (r_{1} − r_{2})(r_{1} − r_{3})(r_{2} − r_{3}) into itself. But then σ cannot act on the set {r_{1}, r_{2}, r_{3}} as the transposition that exchanges r_{1} and r_{2} and leaves r_{3} fixed, because then σ would map (r_{1} − r_{2})(r_{1} − r_{3})(r_{2} − r_{3}) into −(r_{1} − r_{2})(r_{1} − r_{3})(r_{2} − r_{3}). So, in this case, the Galois group of f(x) is not S_{3} and therefore it must be A_{3}.
It is clear from this criterion that, if we are working over the field Q, the Galois group of most irreducible cubic polynomials is S_{3}. An example of an irreducible cubic polynomial with rational coefficients whose Galois group is A_{3} is p(x) = x^{3} − 3x − 1, whose discriminant is 81 = 9^{2}. The polynomial p(x) is used in the standard proof of the impossibility of trisecting arbitrary angles using straightedge and compass only.
Collinearities
The tangent lines to a cubic at three collinear points intercept the cubic again at collinear points.^{[39]} This can be seen as follows. If the cubic is defined by f(x) = ax^{3} + bx^{2} + cx + d and if α is a real number, then the tangent to the graph of f at the point (α, f(α)) is the line
 {(x, f(α) + (x − α)f ′(α)) : x ∈ R}.
So, the intersection point between this line and the graph of f can be obtained solving the equation f(x) = f(α) + (x − α)f ′(α). This is a cubic equation, but it is clear that α is a root, and in fact a double root, since the line is tangent to the graph. The remaining root is −b/a − 2α. So, the other intersection point between the tangent line and the graph of f is the point
Therefore, if P is a point of the graph of f, the other intersection point between the tangent line at P and the graph is the point A(P), where A is the map defined by
Since A is an affine map, if P_{1}, P_{2}, and P_{3} are collinear, then so are the points A(P_{1}), A(P_{2}), and A(P_{3}).
Symmetry
The graph of a cubic function has 180° rotational or point symmetry about its inflection point. The inflection point of a general cubic polynomial,
occurs at a point (x_{0}, f(x_{0})) such that f ′′(x_{0}) = 0. Since f ′′(x) = 6ax + 2b, the inflection point is (−b/3a, 2b^{3}/27a^{2} − bc/3a + d ). Translating the function so that the inflection point is at the origin, one obtains the function f_{T} defined by:
As all terms are odd powers of x, f_{T} (−x) = −f_{T} (x) proving that all cubic functions are rotationally symmetrical about their inflection points.^{[40]}
Applications
Cubic equations arise in various other contexts.
Marden's theorem states that the foci of the Steiner inellipse of any triangle can be found by using the cubic function whose roots are the coordinates in the complex plane of the triangle's three vertices. The roots of the first derivative of this cubic are the complex coordinates of those foci.
The area of a regular heptagon can be expressed in terms of the roots of a cubic. Further, the ratios of the long diagonal to the side, the side to the short diagonal, and the negative of the short diagonal to the long diagonal all satisfy a particular cubic equation. In addition, the ratio of the inradius to the circumradius of a heptagonal triangle is one of the solutions of a cubic equation.
Given the cosine (or other trigonometric function) of an arbitrary angle, the cosine of onethird of that angle is one of the roots of a cubic.
The solution of the general quartic equation relies on the solution of its resolvent cubic.
The eigenvalues of a 3×3 matrix are the roots of a cubic polynomial which is the characteristic polynomial of the matrix.
The characteristic equation of a thirdorder linear difference equation or differential equation is a cubic equation.
In analytical chemistry, the Charlot equation, which can be used to find the pH of buffer solutions, can be solved using a cubic equation.
In chemical engineering and thermodynamics, cubic equations of state are used to model the PVT (pressure, volume, temperature) behavior of substances.
Kinematic equations involving changing rates of acceleration are cubic.
See also
Notes
 ↑ Høyrup, Jens (1992), "The Babylonian Cellar Text BM 85200 + VAT 6599 Retranslation and Analysis", Amphora: Festschrift for Hans Wussing on the Occasion of his 65th Birthday, Birkhäuser, pp. 315–358, doi:10.1007/9783034885997_16, ISBN 9783034885997
 1 2 Crossley, John; W.C. Lun, Anthony (1999). The Nine Chapters on the Mathematical Art: Companion and Commentary. Oxford University Press. p. 176. ISBN 9780198539360.
 1 2 Van der Waerden, Geometry and Algebra of Ancient Civilizations, chapter 4, Zurich 1983 ISBN 0387121595
 ↑ Cooke, Roger (8 November 2012). The History of Mathematics. John Wiley & Sons. p. 63. ISBN 9781118460290.
 ↑ NemetNejat, Karen Rhea (1998). Daily Life in Ancient Mesopotamia. Greenwood Publishing Group. p. 306. ISBN 9780313294976.
 ↑ Cooke, Roger (2008). Classical Algebra: Its Nature, Origins, and Uses. John Wiley & Sons. p. 64. ISBN 9780470277973.
 ↑ Guilbeau (1930, p. 8) states that "the Egyptians considered the solution impossible, but the Greeks came nearer to a solution."
 1 2 Guilbeau (1930, pp. 8–9)
 ↑ Heath, Thomas L. (April 30, 2009). Diophantus of Alexandria: A Study in the History of Greek Algebra. Martino Pub. pp. 87–91. ISBN 9781578987542.
 ↑ Archimedes (October 8, 2007). The works of Archimedes. Translation by T. L. Heath. Rough Draft Printing. ISBN 9781603860512.
 ↑ Mikami, Yoshio (1974) [1913], "Chapter 8 Wang HsiaoTung and Cubic Equations", The Development of Mathematics in China and Japan (2nd ed.), New York: Chelsea Publishing Co., pp. 53–56, ISBN 9780828401494
 ↑ A paper of Omar Khayyam, Scripta Math. 26 (1963), pages 323–337
 ↑ In O'Connor, John J.; Robertson, Edmund F., "Omar Khayyam", MacTutor History of Mathematics archive, University of St Andrews. one may read This problem in turn led Khayyam to solve the cubic equation x^{3} + 200x = 20x^{2} + 2000 and he found a positive root of this cubic by considering the intersection of a rectangular hyperbola and a circle. An approximate numerical solution was then found by interpolation in trigonometric tables. The then in the last assertion is erroneous and should, at least, be replaced by also. The geometric construction was perfectly suitable for Omar Khayyam, as it occurs for solving a problem of geometric construction. At the end of his article he says only that, for this geometrical problem, if approximations are sufficient, then a simpler solution may be obtained by consulting trigonometric tables. Textually: If the seeker is satisfied with an estimate, it is up to him to look into the table of chords of Almagest, or the table of sines and versed sines of Mothmed Observatory. This is followed by a short description of this alternate method (seven lines).
 ↑ J. J. O'Connor and E. F. Robertson (1999), Omar Khayyam, MacTutor History of Mathematics archive, states, "Khayyam himself seems to have been the first to conceive a general theory of cubic equations."
 ↑ Guilbeau (1930, p. 9) states, "Omar Al Hay of Chorassan, about 1079 AD did most to elevate to a method the solution of the algebraic equations by intersecting conics."
 ↑ Datta, Bibhutibhushan; Singh, Avadhesh Narayan (2004), "Equation of Higher Degree", History of Hindu Mathematics: A Source Book, 2, Delhi, India: Bharattya Kala Prakashan, p. 76, ISBN 8186050868
 ↑ O'Connor, John J.; Robertson, Edmund F., "Sharaf alDin alMuzaffar alTusi", MacTutor History of Mathematics archive, University of St Andrews.
 ↑ Berggren, J. L. (1990), "Innovation and Tradition in Sharaf alDīn alṬūsī's Muʿādalāt", Journal of the American Oriental Society, 110 (2): 304–309, doi:10.2307/604533, JSTOR 604533
 ↑ R. N. Knott and the Plus Team (November 4, 2013), "The life and numbers of Fibonacci", Plus Magazine
 ↑ Katz, Victor (2004). A History of Mathematics. Boston: Addison Wesley. p. 220. ISBN 9780321016188.
 1 2 La Nave, Federica; Mazur, Barry (2002), "Reading Bombelli", The Mathematical Intelligencer, 24 (1): 12–21, doi:10.1007/BF03025306
 1 2 3 Nickalls, R. W. D. (July 2006), "Viète, Descartes and the cubic equation" (PDF), Mathematical Gazette, 90: 203–208
 ↑ Zucker, I. J., "The cubic equation — a new look at the irreducible case", Mathematical Gazette 92, July 2008, 264–268.
 ↑ Shelbey, Samuel (1975), CRC Standard Mathematical Tables, CRC Press, ISBN 0878196226
 ↑ These are Formulas (80) and (83) of Weisstein, Eric W. 'Cubic Formula'. From MathWorld—A Wolfram Web Resource. http://mathworld.wolfram.com/CubicFormula.html, rewritten for having a coherent notation.
 ↑ Holmes, G. C., "The use of hyperbolic cosines in solving cubic polynomials", Mathematical Gazette 86. November 2002, 473–477.
 ↑ Abramowitz, Milton; Stegun, Irene A., eds. Handbook of Mathematical Functions with Formulas, Graphs, and Mathematical Tables, Dover (1965), chap. 22 p. 773
 ↑ Gleason, Andrew Mattei (March 1988). "Angle trisection, the heptagon, and the triskaidecagon" (PDF). The American Mathematical Monthly. 95 (3): 185–194. doi:10.2307/2323624. Archived from the original (PDF) on 20151219.
 ↑ Nickalls, R. W. D. (November 1993), "A new approach to solving the cubic: Cardan's solution revealed" (PDF), The Mathematical Gazette, 77 (480): 354–359, doi:10.2307/3619777, ISSN 00255572, JSTOR 3619777 See esp. Fig. 2.
 ↑ Henriquez, Garcia (June–July 1935), "The graphical interpretation of the complex roots of cubic equations", American Mathematical Monthly, 42 (6): 383–384, doi:10.2307/2301359
 ↑ Barr, C. F. (1918), "Discussions: Relating to the Graph of a Cubic Equation Having Complex Roots", American Mathematical Monthly, 25: 268, doi:10.2307/2972885
 ↑ Barr, C. F. (1917), "Some Properties of Polynomial Curves.", Annals of Mathematics, 19: 157, doi:10.2307/1967772
 ↑ Confalonieri, Sara (2015), "The casus irreducibilis in Cardano's Ars Magna and De Regula Aliza", Archive for History of Exact Sciences, 69 (3), doi:10.1007/s0040701501499
 ↑ van der Waerden, Bartel Leenert (1985), "From Viète to Descartes", A History of Algebra: From alKhwārizmī to Emmy Noether, SpringerVerlag, ISBN 354013610X
 ↑ Lagrange, JosephLouis (1869) [1771], "Réflexions sur la résolution algébrique des équations", in Serret, JosephAlfred, Œuvres de Lagrange, III, GauthierVillars, pp. 205–421
 ↑ Prasolov, Viktor; Solovyev, Yuri (1997), Elliptic functions and elliptic integrals, AMS Bookstore, ISBN 9780821805879, §6.2, p. 134
 ↑ Kline, Morris (1990), Mathematical Thought from Ancient to Modern Times, Oxford University Press US, ISBN 9780195061369, Algebra in the Eighteenth Century: The Theory of Equations
 1 2 Daniel Lazard, "Solving quintics in radicals", in Olav Arnfinn Laudal, Ragni Piene, The Legacy of Niels Henrik Abel, pp. 207–225, Berlin, 2004,. ISBN 3540438262
 ↑ Whitworth, William Allen (1866), "Equations of the third degree", Trilinear Coordinates and Other Methods of Modern Analytical Geometry of Two Dimensions (PDF), Cambridge: Deighton, Bell, and Co., p. 425, retrieved June 17, 2016
 ↑ de Villiers, Michael (2004), "All cubic polynomials are point symmetric" (PDF), Learning & Teaching Mathematics, 1: 12–15, retrieved 14 December 2015
References
 Anglin, W. S.; Lambek, Joachim (1995), "Mathematics in the Renaissance", The Heritage of Thales, Springers, pp. 125–131, ISBN 9780387945446 Ch. 24.
 Dence, T. (November 1997), "Cubics, chaos and Newton's method", Mathematical Gazette, Mathematical Association, 81: 403–408, doi:10.2307/3619617, ISSN 00255572
 Dunnett, R. (November 1994), "Newton–Raphson and the cubic", Mathematical Gazette, Mathematical Association, 78: 347–348, doi:10.2307/3620218, ISSN 00255572
 Guilbeau, Lucye (1930), "The History of the Solution of the Cubic Equation", Mathematics News Letter, 5 (4): 8–12, doi:10.2307/3027812, JSTOR 3027812
 Jacobson, Nathan (2009), Basic algebra, 1 (2nd ed.), Dover, ISBN 9780486471891
 Mitchell, D. W. (November 2007), "Solving cubics by solving triangles", Mathematical Gazette, Mathematical Association, 91: 514–516, ISSN 00255572
 Mitchell, D. W. (November 2009), "Powers of φ as roots of cubics", Mathematical Gazette, Mathematical Association, 93: ???, ISSN 00255572
 Press, WH; Teukolsky, SA; Vetterling, WT; Flannery, BP (2007), "Section 5.6 Quadratic and Cubic Equations", Numerical Recipes: The Art of Scientific Computing (3rd ed.), New York: Cambridge University Press, ISBN 9780521880688
 Rechtschaffen, Edgar (July 2008), "Real roots of cubics: Explicit formula for quasisolutions", Mathematical Gazette, Mathematical Association, 92: 268–276, ISSN 00255572
 Zucker, I. J. (July 2008), "The cubic equation – a new look at the irreducible case", Mathematical Gazette, Mathematical Association, 92: 264–268, ISSN 00255572
External links
Wikimedia Commons has media related to Cubic polynomials. 
 Hazewinkel, Michiel, ed. (2001), "Cardano formula", Encyclopedia of Mathematics, Springer, ISBN 9781556080104
 History of quadratic, cubic and quartic equations on MacTutor archive.