What is a quartic equation?
A quartic equation is a polynomial equation of degree four, with the general form ax to the fourth plus bx cubed plus cx squared plus dx plus e equals zero. It is the highest-degree polynomial equation that has a general formula for its roots, found by Ferrari in the sixteenth century, but that formula is so long and complicated that nobody uses it by hand. In practice, quartic equations are solved numerically, by methods that find the roots to as many decimals as needed, which is what this calculator does.
This calculator finds the real roots of a quartic equation using the Durand-Kerner iteration, a numerical method that refines four guesses simultaneously until they converge on the four roots. It shows each real root to four decimals and counts how many real roots there are. For the simpler second-degree case, a quadratic equation calculator solves it exactly, while this page handles the fourth degree numerically.
No data leaves your device: the maths runs entirely in your browser, with no sign-up and no server round-trip. You can change a number, see the answer move, and change it back, all instantly. It is a private way to check a figure before you talk to a professional about it. The page has no tracking of the numbers you enter, and closing the tab leaves nothing behind.
How a quartic equation is solved
The Durand-Kerner method starts with four different complex guesses, one for each root, and improves them all at once. Each guess is corrected by dividing the value of the polynomial at that guess by the product of its differences from the other three guesses, which pushes it towards the nearest root. The process repeats, and the guesses converge on the four roots, whether they are real or complex. Roots whose imaginary part is smaller than a millionth are reported as real roots.
The five coefficients are the numbers a, b, c, d and e in the equation ax to the fourth plus bx cubed plus cx squared plus dx plus e equals zero. The coefficient a must not be zero, or the equation is not a quartic at all. The other coefficients can be zero, negative or fractional, and the calculator handles all of them. The roots are shown to four decimal places, which is enough for most practical purposes.
The four root rows show the real roots in increasing order, with a dash where a root is complex rather than real. A quartic always has four roots counting complex ones, but it can have four, two or zero real roots. The count row says how many of the four are real, which is the first thing to check: a count of 2 means the other two roots form a complex pair.
A dash in a result row means the value does not apply to the inputs you entered, not that the calculation failed. Some rows only make sense for certain methods or certain inputs, and the calculator leaves them blank rather than inventing a number. If every row shows a dash, check the inputs: a missing or zero value in a required field is the usual cause, and the field labels say which values are needed.
The number of real roots, explained
A quartic can have four, two or zero real roots, and the number depends on the shape of the graph. The graph of a quartic is a curve that can cross the x-axis up to four times, and each crossing is a real root. If the curve dips below the axis and comes back up, it crosses twice; if it stays above the axis, it crosses never. The calculator counts the crossings by finding all four roots and checking which ones are real.
Repeated roots are a special case: a root that appears twice counts as two roots, but the graph only touches the axis there instead of crossing it. The Durand-Kerner method converges more slowly for repeated roots, but it still finds them, and the calculator reports them as separate rows with the same value. If two rows show the same number, that root is repeated.
The count is what most users actually need. An engineer solving for a resonant frequency wants to know whether a real solution exists, and a student checking homework wants to know how many roots to look for. A count of zero means there is no real solution, which is a valid answer, not an error, and it means the equation can only be solved with complex numbers.
A worked example: x to the fourth minus 5x squared plus 4
Take the equation x to the fourth minus 5x squared plus 4 equals zero, which has a equal to 1, b equal to 0, c equal to minus 5, d equal to 0 and e equal to 4. This quartic is a quadratic in disguise, because it has no odd powers, so its roots can be checked by hand.
Substitute y for x squared, and the equation becomes y squared minus 5y plus 4 equals zero, which factors as (y minus 1)(y minus 4), giving y equal to 1 or 4. So x squared is 1 or 4, and x is plus or minus 1, or plus or minus 2. The calculator finds the same four roots: -2.00, -1.00, 1.00 and 2.00, and the count is 4 real roots.
Four real roots means the graph crosses the x-axis four times, at minus 2, minus 1, 1 and 2. The numerical method agrees exactly with the hand calculation, which confirms it is working correctly. For a quartic that is not a quadratic in disguise, the hand calculation is far harder, and the numerical method is the practical way to get the roots.
Who solves quartic equations
College algebra students meet quartics as the next step after cubics, and the main lesson is that there is a formula but it is too complicated to use, so numerical methods are the practical tool. The calculator lets students check their factoring and their numerical work, and it shows how many real roots to expect before they start.
Engineers meet quartics in vibration analysis, in control theory and in optics, where a fourth-degree equation often describes a resonance or a focus. The real roots are the physically meaningful solutions, and the complex roots describe damped oscillations. Knowing how many real roots there are decides whether a design has a real resonance to worry about.
Computer graphics uses quartics for ray tracing, where finding where a ray meets a surface often means solving a fourth-degree equation. The real roots are the intersection points, and the smallest positive root is the first surface the ray hits. A fraction calculator is the tool for the simpler equations that appear in the same problems.
No calculator replaces professional advice where money, safety or a legal obligation is involved. The figures here are computed correctly from the inputs and the formula shown, but the choice of formula, the choice of inputs and the decision that follows are yours. When the stakes are high, take the calculated figure to someone qualified and ask them to confirm it before you commit. For a related calculation, the triangle area calculator covers the next number most people need after this one.
Quartic vs quadratic equations
A quadratic equation has a short exact formula, the familiar minus b plus or minus the square root of b squared minus 4ac, all over 2a, and it can have at most two roots. A quartic equation has an exact formula too, found by Ferrari, but it fills a page and is never used by hand. The practical difference is that quadratics are solved exactly and quartics are solved numerically.
The two are related: a quartic with no odd powers is a quadratic in x squared, and it can be solved exactly by substitution, as in the worked example. A general quartic has no such shortcut, and the numerical method is the only practical route. The calculator handles both cases the same way, so you do not need to recognise the special form in advance.
Keep both tools in mind. The right choice is the one whose inputs match the numbers you actually have, not the one with the fancier name. When in doubt, run both and compare: the pair of answers is usually more useful than either one alone.
Common mistakes with quartic equations
The first is entering a equal to zero, which makes the equation cubic, not quartic, and the calculator returns no roots. The second is expecting four real roots always, when a quartic can have two or zero real roots, with the rest complex.
The third is confusing a repeated root with a single root, when it counts twice and appears in two rows with the same value. The fourth is trusting a root without checking it, when substituting it back into the equation is a quick verification.
Always verify a root by substituting it back into the equation: the result should be very close to zero. If it is not, the root is wrong, or the coefficients were entered wrongly. For the worked example, substituting 2 gives 16 minus 20 plus 4, which is zero, as it should be.
How to use this quartic equation calculator
To use it, enter a (coefficient of x⁴); enter b (coefficient of x³); enter c (coefficient of x²); enter d (coefficient of x), then read the results box at the top. The main result is highlighted, and the other rows give the supporting figures. If an answer looks wrong, check the inputs first: a misplaced decimal or a wrong unit is the usual cause, not the formula.
Enter the five coefficients a, b, c, d and e, with a not equal to zero, and read the real roots in increasing order. The count row tells you how many real roots there are, and a dash means that root is complex. Verify any root by substituting it back into the equation.
Everything on this page runs in your browser, so the numbers you type never leave your device. There is no sign-up, no upload and no waiting for a server. Change any input and the results update straight away, which makes it easy to test a few values side by side before you decide anything. You can also use it offline once the page has loaded, because the calculation needs no connection at all.