Education & Study

Quadratic equation solver

Discriminant, real or complex roots, exact form, vertex and graph.

  • Instant
  • Free
  • Private (processed locally)
  • No sign-up

Equation of the form ax² + bx + c = 0

Your equation x² − 3x + 2 = 0
Parabola Roots Vertex y-intercept
Step-by-step solution

ℹ️ Δ = b² − 4ac and x = (−b ± √Δ)/(2a). The exact form (simplified radicals, fractions) is given for integer or decimal coefficients. 100% local: nothing leaves your browser.

Solve any quadratic equation ax² + bx + c = 0 in seconds

A quadratic equation has the form ax² + bx + c = 0 with a ≠ 0. This solver computes the discriminant Δ, tells you how many solutions exist, gives the roots as decimals and in exact form (simplified radicals, reduced fractions, complex numbers), and draws the parabola with its roots and vertex.

Quadratic equations are a core topic in Algebra 1 and Algebra 2, GCSE and A-level maths: factoring, completing the square and the quadratic formula all lead to the same roots. Students use the tool to check homework, teachers to build answer keys, and physics, engineering or economics students to solve equations that come from real problems such as projectile motion, break-even points or areas.

  1. Enter a, b and c

    Type the coefficients into “a (coefficient of x²)”, “b (coefficient of x)” and “c (constant term)”. Decimals and negative numbers are accepted, and the “Your equation” line shows the equation exactly as it was read.

  2. Read Δ and the solutions

    The purple box shows the discriminant, what its sign means (two roots, a double root or complex roots), x₁ and x₂ rounded to 6 decimal places and the “Exact form”. The “Copy result” button puts everything on your clipboard.

  3. Use the cards and the graph

    The cards show the vertex (h, k), axis of symmetry, y-intercept, opening, sum and product of the roots, vertex form and factored form; the graph marks the roots, the vertex and the y-intercept.

  4. Open the step-by-step solution

    Expand “Step-by-step solution” to see Δ computed with your numbers, the quadratic formula with values substituted and the vertex calculation, ready to copy into your work.

The method: discriminant and quadratic formula

For ax² + bx + c = 0 (a ≠ 0), first compute Δ = b² − 4ac. If Δ > 0 the roots are x₁ = (−b − √Δ)/(2a) and x₂ = (−b + √Δ)/(2a); if Δ = 0 the double root is x = −b/(2a); if Δ < 0 there is no real root but two complex conjugate ones.

Completing the square gives the vertex form a(x − h)² + k with h = −b/(2a) and k = −Δ/(4a): the parabola is the graph of y = x² stretched vertically by a factor a (and flipped if a < 0), then shifted so that its vertex sits at (h, k). Under the hood, the sign of Δ is tested with exact integer arithmetic (so 0.1x² + 0.2x + 0.1 = 0 is correctly seen as a double root) and the roots use the numerically stable form of the formula, which avoids losing digits when b² is much larger than 4ac.

  • a, b, c: the coefficients; a multiplies x² and must be non-zero, b multiplies x, c is the constant term.
  • Δ (discriminant): its sign gives the number of real roots (2, 1 or 0); when Δ < 0 the roots are p ± qi with p = −b/(2a) and q = √(−Δ)/(2|a|).
  • ±: the minus sign gives one root, the plus sign the other; the whole numerator −b ± √Δ is divided by 2a.
  • Vertex (h, k): the minimum of the function if a > 0, the maximum if a < 0; the line x = h is the axis of symmetry.
  • Sum and product: x₁ + x₂ = −b/a and x₁ × x₂ = c/a (Vieta’s formulas), handy to check a result or spot an obvious root.
  • Exact form: √Δ is simplified by taking square factors out of the radical (√48 = 4√3), then the fraction is reduced by the GCD of its three terms.

Worked examples

EquationΔSolutionsVertex (h, k)
x² − 3x + 2 = 01x₁ = 1, x₂ = 2(1.5, −0.25)
x² − 2x + 1 = 00x₁ = x₂ = 1 (double root)(1, 0)
2x² − 7x + 3 = 025x₁ = 1/2 = 0.5, x₂ = 3(1.75, −3.125)
x² − 3x + 1 = 05x = (3 ± √5)/2: x₁ ≈ 0.381966, x₂ ≈ 2.618034(1.5, −1.25)
x² + 4x − 8 = 048x = −2 ± 2√3: x₁ ≈ −5.464102, x₂ ≈ 1.464102(−2, −12)
2x² + 4x + 5 = 0−24x = (−2 ± i√6)/2 ≈ −1 ± 1.224745i(−1, 3)

Same values as displayed by the tool (6 decimals, simplified exact form).

What is a quadratic equation solver used for?

  • Homework and exams: check Δ, the roots and the vertex form of an exercise, step by step.
  • Physics: a ball thrown straight up at 20 m/s from a height of 1.5 m follows h(t) = −4.9t² + 20t + 1.5. Solving h(t) = 0 gives t ≈ 4.155303 s (the other, negative root is rejected), and the vertex gives a maximum height of about 21.908163 m at t ≈ 2.040816 s.
  • Geometry: a rectangle with perimeter 20 and area 21 has sides that are the roots of x² − 10x + 21 = 0, namely 3 and 7.
  • Business: a profit P(q) = −2q² + 40q − 150 is zero at q = 5 and q = 15 and peaks at 50 for q = 10, read straight from the vertex.
  • Teaching: build examples with integer roots and show in class how a, b and c reshape the parabola.

Common mistakes

  • Dropping the sign of b: in x² − 3x + 2, b = −3, so −b = 3 and b² = (−3)² = 9, not −9.
  • Dividing only part of the numerator by 2a: the whole −b ± √Δ is divided, not just √Δ.
  • Reading a, b, c before rearranging: 2x² = 7x − 3 must first become 2x² − 7x + 3 = 0.
  • Saying “no solution” when Δ < 0: there is no real solution, but there are two complex conjugate ones.

Everything is computed locally in your browser: no data is sent anywhere. Decimal results are rounded to 6 decimal places; the exact form is shown as long as the absolute value of the discriminant, computed with the coefficients scaled to integers, stays below 253 ≈ 9 × 1015. Non-zero coefficients must lie between 10−100 and 10100 in absolute value.

Frequently asked questions

How does the discriminant tell me the number of solutions?

Compute Δ = b² − 4ac. For x² − 3x + 2 = 0, Δ = 9 − 8 = 1 > 0, so there are two real roots, x₁ = 1 and x₂ = 2. If Δ = 0 (x² − 2x + 1 = 0) there is one double root x = 1; if Δ < 0 (2x² + 4x + 5 = 0, Δ = −24) there is no real root.

What does the solver show when Δ is negative?

It gives the two complex conjugate roots p ± qi, where p = −b/(2a) and q = √(−Δ)/(2|a|). For 2x² + 4x + 5 = 0 that is x ≈ −1 ± 1.224745i, or (−2 ± i√6)/2 in exact form. Over the reals there is no solution and the parabola never touches the x-axis.

How is the exact form simplified?

The tool pulls square factors out of the radical (√48 = √(16 × 3) = 4√3), then divides the numerator terms and the denominator by their greatest common divisor. So x² + 4x − 8 = 0 gives (−4 ± 4√3)/2 = −2 ± 2√3. Decimal coefficients work too: x² + 0.5x − 1 = 0 gives (−1 ± √17)/4.

What happens if a = 0?

The equation is then linear, bx + c = 0, so x = −c/b. With a = 0, b = −3 and c = 2 the tool returns x = 2/3 ≈ 0.666667. If b is also 0, there is either no solution (c ≠ 0) or infinitely many (c = 0).

How do I find the vertex and the vertex form?

The vertex is (h, k) with h = −b/(2a) and k = −Δ/(4a). For x² − 3x + 2 it is (1.5, −0.25), so the vertex form is y = (x − 1.5)² − 0.25. When a < 0 the vertex is a maximum: −x² + 2x + 3 peaks at 4 when x = 1.

How can I check the roots with Vieta’s formulas?

The roots always satisfy x₁ + x₂ = −b/a and x₁ × x₂ = c/a. For 2x² − 7x + 3 = 0 the roots are 1/2 and 3: their sum is 3.5 = 7/2 and their product 1.5 = 3/2. The solver shows both values so you can check a hand calculation instantly.