1. Maths Calculators
  2. Quadratic Formula Calculator

Quadratic Formula Calculator

Solve any quadratic equation ax²+bx+c=0 instantly. Enter the coefficients a, b, and c to find real or complex roots, the discriminant, vertex coordinates, and full step-by-step working. Covers all cases: two roots, double root, and complex roots.

Enter the coefficients for ax² + bx + c = 0

Use negative values for negative coefficients (e.g. b = −5). The coefficient a must not be zero.

The Quadratic Formula

The quadratic formula is one of the most important tools in algebra. It solves any quadratic equation of the form ax² + bx + c = 0, where a ≠ 0. The formula is:

Quadratic Formula
x = (−b ± √(b² − 4ac)) / (2a)

Where Δ = b² − 4ac is the discriminant

The ± symbol means there are generally two solutions: one with the + sign (x₁) and one with the − sign (x₂). Whether these are real or complex depends on the discriminant.

Deriving the Formula by Completing the Square

The quadratic formula is not arbitrary — it is derived from the technique of completing the square. Here is the derivation from ax² + bx + c = 0:

Derivation of the Quadratic Formula

Step 1: Divide all terms by a:

x² + (b/a)x + (c/a) = 0

Step 2: Move the constant to the right:

x² + (b/a)x = −c/a

Step 3: Complete the square — add (b/2a)² to both sides:

x² + (b/a)x + (b/2a)² = (b/2a)² − c/a

Step 4: Left side is a perfect square trinomial:

(x + b/2a)² = (b² − 4ac) / (4a²)

Step 5: Take the square root:

x + b/2a = ± √(b² − 4ac) / (2a)

Step 6: Solve for x:

x = (−b ± √(b² − 4ac)) / (2a)

The Discriminant: Δ = b² − 4ac

Before solving, calculate the discriminant Δ = b² − 4ac. Its value tells you the nature of the roots:

Discriminant ΔNumber of Real RootsGraphical MeaningRoot Type
Δ > 0Two distinct real rootsParabola crosses x-axis at 2 pointsReal, different
Δ = 0One repeated root (double root)Parabola touches x-axis at 1 pointReal, equal
Δ < 0No real rootsParabola does not cross x-axisComplex conjugates

Three Methods for Solving Quadratics

There are three main methods. Knowing when to use each saves time in exams:

MethodBest Used WhenAlways Works?
FactoringSmall integer roots, equation factors neatlyNo (only when factorable over integers)
Completing the SquareFinding vertex form, deriving the formulaYes (but algebraically intensive)
Quadratic FormulaAny quadratic, especially non-integer rootsYes — always works for any quadratic

Worked Examples: All Three Cases

Example 1: Two Distinct Real Roots — x² − 5x + 6 = 0

a = 1, b = −5, c = 6

Step 1 — Discriminant:

Δ = (−5)² − 4(1)(6) = 25 − 24 = 1 > 0

Step 2 — Apply formula:

x = (5 ± √1) / 2 = (5 ± 1) / 2

Step 3 — Two solutions:

x₁ = (5 + 1) / 2 = 3    x₂ = (5 − 1) / 2 = 2

Factored form: (x − 3)(x − 2) = 0. Check: 3² − 5(3) + 6 = 9 − 15 + 6 = 0 ✓

Example 2: Double Root — x² − 6x + 9 = 0

a = 1, b = −6, c = 9

Δ = (−6)² − 4(1)(9) = 36 − 36 = 0
x = −(−6) / (2 × 1) = 6/2 = 3 (double root)

Factored form: (x − 3)² = 0. The parabola is tangent to the x-axis at x = 3.

Example 3: Complex Roots — x² + x + 1 = 0

a = 1, b = 1, c = 1

Δ = 1² − 4(1)(1) = 1 − 4 = −3 < 0
x = (−1 ± √(−3)) / 2 = −1/2 ± i√3/2

Roots: x = −0.5 + 0.866i and x = −0.5 − 0.866i. These are complex conjugates. The parabola does not cross the x-axis.

Vertex Form and the Parabola

Every quadratic equation y = ax² + bx + c describes a parabola. The vertex (turning point) is the minimum point when a > 0 (opens upward) or maximum when a < 0 (opens downward).

Vertex: x = −b/(2a),   y = f(−b/2a)

The x-coordinate of the vertex is the axis of symmetry; the y-coordinate is the minimum or maximum value

The vertex form of a quadratic is y = a(x − h)² + k, where (h, k) is the vertex. Converting to vertex form is equivalent to completing the square.

Vieta’s Formulas: Sum and Product of Roots

For the quadratic ax² + bx + c = 0 with roots x₁ and x₂, Vieta’s formulas give:

  • Sum of roots: x₁ + x₂ = −b/a
  • Product of roots: x₁ × x₂ = c/a

These are useful for checking answers and for quickly finding quadratics with given roots. For example, to find the quadratic with roots 3 and 2: sum = 5 so b/a = −5; product = 6 so c/a = 6 → x² − 5x + 6 = 0.

Applications of Quadratics

Example 4: Projectile Motion

A ball is thrown upward with initial velocity 20 m/s from a height of 2 m. When does it hit the ground?

Using h(t) = −5t² + 20t + 2 = 0 (using g = 10 m/s²):

a = −5, b = 20, c = 2. Δ = 400 + 40 = 440

t = (−20 ± √440) / (−10) = (−20 ± 20.976) / (−10)

Taking the positive root: t = (−20 − 20.976) / (−10) ≈ 4.10 seconds

Example 5: Area Problem

A rectangular garden has a length 3 metres more than its width. The area is 40 m². Find the dimensions.

Let width = x. Then length = x + 3 and area = x(x + 3) = 40 → x² + 3x − 40 = 0

Δ = 9 + 160 = 169. x = (−3 ± 13) / 2

x = 5 (taking positive root). Width = 5m, length = 8m. Check: 5 × 8 = 40 ✓

Completing the Square: Step-by-Step

Completing the square is used to solve quadratics, convert to vertex form, and understand graphical properties:

Example 6: Complete the square for x² + 6x + 5 = 0

Step 1: Move constant: x² + 6x = −5

Step 2: Add (6/2)² = 9 to both sides: x² + 6x + 9 = 4

Step 3: Factor left: (x + 3)² = 4

Step 4: Take square root: x + 3 = ±2

Solutions: x = −3 + 2 = −1 or x = −3 − 2 = −5. Vertex is at (−3, −4).

Quadratic Equations in GCSE and A-Level Maths

At GCSE (Higher tier), quadratic equation questions require:

  • Solving by factoring (for factorable quadratics)
  • Applying the quadratic formula to non-integer solutions (usually to 2 or 3 s.f.)
  • Completing the square to find vertex or solve

At A-Level, quadratics appear in more advanced contexts:

  • Quadratics in disguise: e.g. substituting u = sin x to get 2u² − 3u + 1 = 0
  • Quadratic inequalities: solving ax² + bx + c > 0 by finding roots and using sign diagrams
  • Discriminant conditions: for what range of k does kx² − 3x + 2 = 0 have real roots?

Example 7 (A-Level): Find the range of k for which x² + kx + 4 = 0 has real roots

For real roots, Δ ≥ 0:

k² − 4(1)(4) ≥ 0 → k² ≥ 16 → k ≥ 4 or k ≤ −4

Example 8: Quadratic in disguise — Solve 2sin²x − sin x − 1 = 0, 0 ≤ x ≤ 360°

Let u = sin x: 2u² − u − 1 = 0 → (2u + 1)(u − 1) = 0

u = −1/2 or u = 1 → sin x = −0.5 or sin x = 1

Solutions: x = 210°, 330°, 90°

Frequently Asked Questions

What is the quadratic formula?

The quadratic formula is x = (−b ± √(b² − 4ac)) / (2a). It solves any quadratic equation ax² + bx + c = 0, where a ≠ 0. The formula gives two solutions because of the ± sign. These can be two real numbers (when the discriminant Δ = b² − 4ac > 0), one repeated number (when Δ = 0), or two complex numbers (when Δ < 0). The formula was known to ancient Babylonian and Greek mathematicians, though the modern algebraic form was developed by Islamic mathematician Al-Khwarizmi around 820 AD.

What is the discriminant and what does it tell you?

The discriminant Δ = b² − 4ac is the expression under the square root in the quadratic formula. It tells you the nature of the roots before you solve: if Δ > 0 there are two distinct real roots; if Δ = 0 there is exactly one repeated root (the parabola touches the x-axis); if Δ < 0 there are no real roots (only complex roots). At A-Level, you often need to set conditions on the discriminant: for example, "for what values of k does the equation have no real solutions?" requires Δ < 0.

When should you use the quadratic formula vs factoring?

Use factoring when the equation factors neatly with small integers (e.g. x² + 5x + 6 = (x+2)(x+3)). It is faster when it works. Use the quadratic formula when: the discriminant is not a perfect square, the roots are decimals or fractions, or the equation resists obvious factoring. Use completing the square when you need the vertex form y = a(x−h)² + k. The quadratic formula always works and is the safest method under time pressure.

How do you complete the square?

For ax² + bx + c = 0: (1) Divide all terms by a. (2) Move the constant to the right. (3) Add (b/2a)² to both sides to create a perfect square on the left. (4) The left side is (x + b/2a)². (5) Take the square root and solve for x. For example, x² + 4x + 1 = 0 → x² + 4x = −1 → (x+2)² = 3 → x = −2 ± √3 ≈ 0.732 or −3.732.

What is a double root?

A double root (or repeated root) occurs when the discriminant Δ = 0. Both solutions of the quadratic formula give the same value: x = −b/(2a). This means the quadratic can be written as a(x − r)² = 0, where r is the repeated root. Graphically, the parabola is tangent to the x-axis: it just touches the x-axis at exactly one point without crossing it. Example: x² − 4x + 4 = (x−2)² = 0 has a double root at x = 2.

Can a quadratic have no real solutions?

Yes — when Δ = b² − 4ac < 0. The square root of a negative number is imaginary, so the roots are complex: x = −b/(2a) ± i√|Δ|/(2a), where i = √(−1). For example, x² + 2x + 5 = 0 has Δ = 4−20 = −16, giving roots x = −1 ± 2i. On a graph, the parabola lies entirely above the x-axis (if a > 0) and never crosses it. At A-Level, complex roots always come in conjugate pairs (a+bi and a−bi).

MB

Written by Mustafa Bilgic — UK Maths Specialist

Mustafa specialises in algebra, GCSE and A-Level mathematics, and quantitative tools for UK audiences. This calculator and guide are aligned with Edexcel, AQA, and OCR GCSE and A-Level Mathematics specifications. For curriculum details, see Edexcel A-Level Mathematics.