Equation Solver

    Equation Solver Features

    Linear through cubic

    Four modes cover ax+b=0, quadratics, cubics and 2x2 systems without switching between separate pages

    Discriminant and root types

    Quadratics show d = b^2-4ac and distinguish two real roots, a repeated root and conjugate complex roots, with an explanation for each

    All real cubic roots

    The cubic is reduced to t^3+pt+q=0, then Cardano or the trigonometric method yields one, two or three distinct real roots depending on the discriminant

    Cramer rule for systems

    Computes the coefficient determinant D plus Dx and Dy; when D is zero it further separates parallel lines (no solution) from coincident lines (infinitely many)

    Step-by-step working

    From the initial equation through the discriminant, the formula and back-substitution, so homework can be checked line by line

    Fraction-friendly coefficients

    Inputs accept 1/2, -3, 2.5 and similar values, and a zero leading coefficient produces a clear message

    How to Use the Equation Solver

    1

    Choose an equation type

    Pick linear, quadratic, cubic or a 2x2 system from the four tabs at the top.

    2

    Enter coefficients

    Fill a, b, c, d or the six coefficients of the two equations; integers, decimals and forms like 1/2 are accepted.

    3

    Read the result and working

    The result panel shows the roots or solution, and the step list shows the equation, discriminant, formula and back-substitution.

    4

    Try the examples

    Load a typical equation with one click, for example x^2+2x+5=0 to see how conjugate complex roots are written.

    Where an Equation Solver Helps

    School and college algebra

    Check factoring, completing the square and the quadratic formula against a line-by-line derivation

    Marking algebra homework

    Verify the number and type of roots for many coefficient sets, especially near-zero discriminants

    Engineering estimates

    Turn a fitted curve or small eigenvalue problem into a low-degree polynomial and get starting values quickly

    Function plotting

    Find the zeros before drawing a curve to confirm how many times it crosses the x axis

    Structural force balance

    Write two equilibrium conditions as a 2x2 system and solve both unknowns with Cramer rule

    Worksheet and lecture prep

    Generate examples with complete working without hand-solving a three-root cubic

    Equation Solving Explained

    Why the discriminant matters

    For ax^2+bx+c=0, d = b^2-4ac determines the roots: d>0 gives two distinct real roots, d=0 a repeated root, d<0 a conjugate complex pair. It is exactly the expression under the square root in the quadratic formula.

    Writing complex roots

    When d<0 the square root becomes i*sqrt(|d|), so the roots are -b/(2a) +/- i*sqrt(|d|)/(2a). They share a real part and have opposite imaginary parts, which is why they are called conjugate roots; this tool writes them as a +/- bi.

    The depressed cubic

    Divide ax^3+bx^2+cx+d=0 by a and substitute x = t - B/(3A) to remove the quadratic term, giving t^3+pt+q=0. Then d = (q/2)^2+(p/3)^3: d>0 means one real root, d=0 repeated roots, d<0 three real roots obtainable from the cosine triple-angle formula.

    Cramer rule and determinants

    For a 2x2 system the coefficient determinant is D = a1*b2 - a2*b1. When D is non-zero, x = Dx/D and y = Dy/D; when D is zero the lines have no unique intersection, and Dx and Dy decide whether they are parallel or coincident.

    Floating point and borderline cases

    A discriminant is rarely exactly zero in binary floating point, so this tool uses a small threshold, and near-equal roots of a cubic are de-duplicated to avoid showing a repeated root as two almost identical numbers.

    Typical Equations and Their Solutions

    EquationRoot typeResult
    2x - 6 = 0One real rootx = 3
    x^2 - 5x + 6 = 0Two distinct rootsx = 2, 3
    x^2 - 4x + 4 = 0Repeated rootx = 2
    x^2 + 2x + 5 = 0Complex pair-1 +/- 2i
    x^3 - 6x^2 + 11x - 6 = 0Three real rootsx = 1, 2, 3
    2x+3y=7, x-y=1Unique solutionx = 2, y = 1
    Complex roots use the a +/- bi form; cubics list real roots only and do not expand the complex pair numerically.

    Equation Solver FAQ

    Q: Can the leading coefficient be zero?
    A: No. If a is zero for a quadratic or cubic, the equation really has a lower degree; the tool asks you to switch to the matching mode instead of returning a misleading answer.
    Q: Can coefficients be fractions?
    A: Yes. Values like 1/2 and -3/4 are parsed into numbers and solved numerically, so results are shown to six decimal places.
    Q: Why does a quadratic have no real root?
    A: When d = b^2-4ac is negative, the square root in the formula is imaginary; there is no real solution but there is a conjugate complex pair, written here as a +/- bi.
    Q: Why does a cubic show at most three roots?
    A: A cubic polynomial has at most three roots. This tool returns real roots only; when the discriminant is positive the other two are a complex pair and the page says so rather than expanding them.
    Q: What do no solution and infinitely many solutions mean?
    A: When the determinant D is zero the two lines have no unique intersection: if the equations are proportional they are the same line (infinitely many solutions), otherwise they are parallel (no solution).
    Q: How accurate are the results?
    A: Numeric results keep six decimal places with trailing zeros removed. Cubic roots come from analytic formulas and are back-substituted; near-duplicate roots are removed and tiny residuals are treated as zero.
    Q: Why is a near-zero discriminant treated as a repeated root?
    A: Binary floating point cannot represent many radicals exactly, so comparing to literal zero would misclassify a repeated root as two nearby roots. A threshold around 1e-9 is used, and near-equal cubic roots are de-duplicated.