Math

Cubic Function Graph (y = ax³ + bx² + cx + d)

Enter coefficients a–d to plot the cubic function y = ax³ + bx² + cx + d. Automatically finds the inflection point and local extrema (local max/min).

Tips

  • The cubic coefficient a determines the overall direction of the graph. If a > 0, the curve rises from lower-left to upper-right; if a < 0, it falls from upper-left to lower-right.
  • The inflection point is where the concavity of the graph changes. Its x-coordinate is x = −b ÷ (3a), and it is shown on the graph as an orange diamond.
  • Local extrema are found by solving dy/dx = 3ax² + 2bx + c = 0. Local maxima appear as green dots, local minima as purple dots. If the discriminant of this quadratic is ≤ 0, there are no local extrema and the function is monotone.
  • The default is y = x³ − 3x (a=1, b=0, c=−3, d=0), a classic cubic with a local maximum at (−1, 2) and a local minimum at (1, −2).

FAQ

An inflection point is where the concavity (direction of curvature) of the graph changes. For y = ax³ + bx² + cx + d, set the second derivative d²y/dx² = 6ax + 2b = 0 to get x = −b ÷ (3a). At this point, the graph switches from "curving downward" to "curving upward" (or vice versa).

A local maximum is a point where y is higher than nearby points (a local peak); a local minimum is where y is lower (a local valley). They are found by solving dy/dx = 3ax² + 2bx + c = 0 and checking the sign of the second derivative at each solution (negative → local max, positive → local min). If the derivative's discriminant is ≤ 0, no local extrema exist and the function is monotone.

Yes. The equation ax³ + bx² + cx + d = 0 always has at least one real root (for real coefficients). By the intermediate value theorem, since y → +∞ as x → +∞ and y → −∞ as x → −∞ (when a > 0), the graph must cross zero at least once.

The direction of the graph is reversed: instead of rising from lower-left to upper-right, it falls from upper-left to lower-right. Local max and min still occur at the same x-coordinates, but at any x the y-value is the sign-reversed counterpart of the a > 0 case.

Side Note — The Rivalry Behind the Cubic Formula

The general solution for cubic equations (Cardano's formula) was the subject of a bitter feud among 16th-century Italian mathematicians. Niccolò Tartaglia discovered a method for solving cubic equations and shared it with Gerolamo Cardano under a sworn promise of secrecy. In 1545, however, Cardano published the formula in his book Ars Magna, triggering a fierce dispute with Tartaglia, who accused him of plagiarism.

Remarkably, solving cubic equations helped spark the invention of complex numbers. Even when a cubic equation has only real roots, Cardano's formula may require taking the square root of a negative number during intermediate steps. Rafael Bombelli showed that by treating these "imaginary" numbers formally, the correct real solutions could be obtained — planting the seeds of complex number theory.