Splitting the middle term is quick when the numbers are friendly, but many quadratics cannot be split using whole numbers at all. Try finding two integers with product − 5 -5 − 5 and sum − 7 -7 − 7 for x 2 − 7 x − 5 x^2 - 7x - 5 x 2 − 7 x − 5 : there are none. For every quadratic equation, friendly or not, there is a formula that gives the roots directly. In this lesson we prove that formula, meet the discriminant, and use both methods side by side.
The result#
The roots of a x 2 + b x + c = 0 ax^2 + bx + c = 0 a x 2 + b x + c = 0 , where a ≠ 0 a \neq 0 a = 0 , are
x = − b ± b 2 − 4 a c 2 a = − b ± Δ 2 a \displaystyle x = \frac{-b \pm \sqrt{b^2 - 4ac}}{2a} = \frac{-b \pm \sqrt{\Delta}}{2a} x = 2 a − b ± b 2 − 4 a c = 2 a − b ± Δ
where Δ = b 2 − 4 a c \Delta = b^2 - 4ac Δ = b 2 − 4 a c . The number Δ \Delta Δ (the Greek letter delta) is called the discriminant .
The sign ± \pm ± means we get two roots: one using + + + and one using − - − .
Proof by completing the square#
The idea is to turn the left side into a perfect square, ( x + something ) 2 (x + \text{something})^2 ( x + something ) 2 , and then take square roots. We use one fact: if x 2 = k x^2 = k x 2 = k , then x = ± k x = \pm\sqrt{k} x = ± k .
Start with the equation and divide every term by a a a (allowed, since a ≠ 0 a \neq 0 a = 0 ):
a x 2 + b x + c = 0 x 2 + b a x + c a = 0 x 2 + b a x = − c a x 2 + 2 ( x ) ( b 2 a ) = − c a \displaystyle \begin{aligned} ax^2 + bx + c &= 0 \\ x^2 + \frac{b}{a}x + \frac{c}{a} &= 0 \\ x^2 + \frac{b}{a}x &= -\frac{c}{a} \\ x^2 + 2(x)\left(\frac{b}{2a}\right) &= -\frac{c}{a} \end{aligned} a x 2 + b x + c x 2 + a b x + a c x 2 + a b x x 2 + 2 ( x ) ( 2 a b ) = 0 = 0 = − a c = − a c
The last line writes the middle term as 2 × x × b 2 a \displaystyle 2 \times x \times \frac{b}{2a} 2 × x × 2 a b , which looks like the middle of ( x + b 2 a ) 2 \displaystyle (x + \frac{b}{2a})^2 ( x + 2 a b ) 2 . To complete the square, add ( b 2 a ) 2 \displaystyle \left(\frac{b}{2a}\right)^2 ( 2 a b ) 2 to both sides:
x 2 + 2 ( x ) ( b 2 a ) + ( b 2 a ) 2 = − c a + ( b 2 a ) 2 ( x + b 2 a ) 2 = − c a + b 2 4 a 2 ( x + b 2 a ) 2 = b 2 − 4 a c 4 a 2 \displaystyle \begin{aligned} x^2 + 2(x)\left(\frac{b}{2a}\right) + \left(\frac{b}{2a}\right)^2 &= -\frac{c}{a} + \left(\frac{b}{2a}\right)^2 \\ \left(x + \frac{b}{2a}\right)^2 &= -\frac{c}{a} + \frac{b^2}{4a^2} \\ \left(x + \frac{b}{2a}\right)^2 &= \frac{b^2 - 4ac}{4a^2} \end{aligned} x 2 + 2 ( x ) ( 2 a b ) + ( 2 a b ) 2 ( x + 2 a b ) 2 ( x + 2 a b ) 2 = − a c + ( 2 a b ) 2 = − a c + 4 a 2 b 2 = 4 a 2 b 2 − 4 a c
Now take the square root of both sides:
x + b 2 a = ± b 2 − 4 a c 4 a 2 = ± b 2 − 4 a c 2 a x = − b 2 a ± b 2 − 4 a c 2 a x = − b ± b 2 − 4 a c 2 a \displaystyle \begin{aligned} x + \frac{b}{2a} &= \pm\sqrt{\frac{b^2 - 4ac}{4a^2}} = \pm\frac{\sqrt{b^2 - 4ac}}{2a} \\ x &= -\frac{b}{2a} \pm \frac{\sqrt{b^2 - 4ac}}{2a} \\ x &= \frac{-b \pm \sqrt{b^2 - 4ac}}{2a} \end{aligned} x + 2 a b x x = ± 4 a 2 b 2 − 4 a c = ± 2 a b 2 − 4 a c = − 2 a b ± 2 a b 2 − 4 a c = 2 a − b ± b 2 − 4 a c
That is the formula.
Always do it in three steps: write the equation in the form a x 2 + b x + c = 0 ax^2 + bx + c = 0 a x 2 + b x + c = 0 , read off a a a , b b b and c c c with their signs, then substitute.
Example 1#
Find the roots of x 2 − 3 x + 2 = 0 x^2 - 3x + 2 = 0 x 2 − 3 x + 2 = 0 .
Here a = 1 a = 1 a = 1 , b = − 3 b = -3 b = − 3 , c = 2 c = 2 c = 2 .
x = − b ± b 2 − 4 a c 2 a = 3 ± 9 − 4 ( 1 ) ( 2 ) 2 ( 1 ) = 3 ± 1 2 = 3 ± 1 2 \displaystyle \begin{aligned} x &= \frac{-b \pm \sqrt{b^2 - 4ac}}{2a} \\ &= \frac{3 \pm \sqrt{9 - 4(1)(2)}}{2(1)} \\ &= \frac{3 \pm \sqrt{1}}{2} = \frac{3 \pm 1}{2} \end{aligned} x = 2 a − b ± b 2 − 4 a c = 2 ( 1 ) 3 ± 9 − 4 ( 1 ) ( 2 ) = 2 3 ± 1 = 2 3 ± 1
So x = 3 − 1 2 = 1 \displaystyle x = \frac{3 - 1}{2} = 1 x = 2 3 − 1 = 1 or x = 3 + 1 2 = 2 \displaystyle x = \frac{3 + 1}{2} = 2 x = 2 3 + 1 = 2 .
Check by splitting the middle term: x 2 − x − 2 x + 2 = x ( x − 1 ) − 2 ( x − 1 ) = ( x − 1 ) ( x − 2 ) x^2 - x - 2x + 2 = x(x - 1) - 2(x - 1) = (x - 1)(x - 2) x 2 − x − 2 x + 2 = x ( x − 1 ) − 2 ( x − 1 ) = ( x − 1 ) ( x − 2 ) , which gives the same roots 1 1 1 and 2 2 2 .
Notice that − b = − ( − 3 ) = 3 -b = -(-3) = 3 − b = − ( − 3 ) = 3 . Getting the sign of − b -b − b wrong is the most common error with this formula.
Example 2#
Find the roots of x 2 − 7 x − 5 = 0 x^2 - 7x - 5 = 0 x 2 − 7 x − 5 = 0 .
Here a = 1 a = 1 a = 1 , b = − 7 b = -7 b = − 7 , c = − 5 c = -5 c = − 5 .
x = 7 ± 49 − 4 ( 1 ) ( − 5 ) 2 ( 1 ) = 7 ± 49 + 20 2 = 7 ± 69 2 \displaystyle \begin{aligned} x &= \frac{7 \pm \sqrt{49 - 4(1)(-5)}}{2(1)} \\ &= \frac{7 \pm \sqrt{49 + 20}}{2} \\ &= \frac{7 \pm \sqrt{69}}{2} \end{aligned} x = 2 ( 1 ) 7 ± 49 − 4 ( 1 ) ( − 5 ) = 2 7 ± 49 + 20 = 2 7 ± 69
So the roots are 7 − 69 2 \displaystyle \frac{7 - \sqrt{69}}{2} 2 7 − 69 and 7 + 69 2 \displaystyle \frac{7 + \sqrt{69}}{2} 2 7 + 69 . Since 69 69 69 is not a perfect square, the roots are irrational, which is exactly why splitting the middle term could not work.
The discriminant#
The number under the root, Δ = b 2 − 4 a c \Delta = b^2 - 4ac Δ = b 2 − 4 a c , tells us what kind of roots to expect before we finish the working. For an equation whose coefficients a a a , b b b , c c c are integers:
If Δ \Delta Δ is a perfect square (as in Example 1, Δ = 1 \Delta = 1 Δ = 1 ), the roots are rational and the quadratic can be split using rational numbers.
If Δ \Delta Δ is positive but not a perfect square (as in Example 2, Δ = 69 \Delta = 69 Δ = 69 ), the roots are irrational.
If Δ \Delta Δ is negative, there is no real square root, so the equation has no real roots. You will study this case fully with quadratic equations.
Splitting with a leading coefficient#
When a a a is not 1 1 1 , splitting still works: look for two numbers whose product is a × c a \times c a × c and whose sum is b b b .
Example 3#
Solve 6 x 2 − 13 x + 6 = 0 6x^2 - 13x + 6 = 0 6 x 2 − 13 x + 6 = 0 .
Product 6 × 6 = 36 6 \times 6 = 36 6 × 6 = 36 , sum − 13 -13 − 13 . The factor pairs of 36 36 36 are 1 × 36 1 \times 36 1 × 36 , 2 × 18 2 \times 18 2 × 18 , 3 × 12 3 \times 12 3 × 12 , 4 × 9 4 \times 9 4 × 9 , and 4 + 9 = 13 4 + 9 = 13 4 + 9 = 13 , so we use − 4 -4 − 4 and − 9 -9 − 9 .
6 x 2 − 4 x − 9 x + 6 = 0 2 x ( 3 x − 2 ) − 3 ( 3 x − 2 ) = 0 ( 3 x − 2 ) ( 2 x − 3 ) = 0 \begin{aligned} 6x^2 - 4x - 9x + 6 &= 0 \\ 2x(3x - 2) - 3(3x - 2) &= 0 \\ (3x - 2)(2x - 3) &= 0 \end{aligned} 6 x 2 − 4 x − 9 x + 6 2 x ( 3 x − 2 ) − 3 ( 3 x − 2 ) ( 3 x − 2 ) ( 2 x − 3 ) = 0 = 0 = 0
So x = 2 3 \displaystyle x = \frac{2}{3} x = 3 2 or x = 3 2 \displaystyle x = \frac{3}{2} x = 2 3 .
By the formula, Δ = 169 − 144 = 25 \Delta = 169 - 144 = 25 Δ = 169 − 144 = 25 and x = 13 ± 5 12 \displaystyle x = \frac{13 \pm 5}{12} x = 12 13 ± 5 , which gives 18 12 = 3 2 \displaystyle \frac{18}{12} = \frac{3}{2} 12 18 = 2 3 and 8 12 = 2 3 \displaystyle \frac{8}{12} = \frac{2}{3} 12 8 = 3 2 . Both methods agree.
Example 4#
Solve x 2 − 5 x − 24 = 0 x^2 - 5x - 24 = 0 x 2 − 5 x − 24 = 0 .
Product − 24 -24 − 24 , sum − 5 -5 − 5 . A negative product means one number is negative: − 8 × 3 = − 24 -8 \times 3 = -24 − 8 × 3 = − 24 and − 8 + 3 = − 5 -8 + 3 = -5 − 8 + 3 = − 5 .
x 2 − 8 x + 3 x − 24 = 0 x ( x − 8 ) + 3 ( x − 8 ) = 0 ( x + 3 ) ( x − 8 ) = 0 \begin{aligned} x^2 - 8x + 3x - 24 &= 0 \\ x(x - 8) + 3(x - 8) &= 0 \\ (x + 3)(x - 8) &= 0 \end{aligned} x 2 − 8 x + 3 x − 24 x ( x − 8 ) + 3 ( x − 8 ) ( x + 3 ) ( x − 8 ) = 0 = 0 = 0
So x = − 3 x = -3 x = − 3 or x = 8 x = 8 x = 8 .
Practice#
Find the discriminant of 2 x 2 − 7 x + 3 2x^2 - 7x + 3 2 x 2 − 7 x + 3 .
Solve x 2 − 6 x + 5 = 0 x^2 - 6x + 5 = 0 x 2 − 6 x + 5 = 0 using the formula.
Solve 2 x 2 − x − 6 = 0 2x^2 - x - 6 = 0 2 x 2 − x − 6 = 0 using the formula.
Solve 2 x 2 + 7 x + 3 = 0 2x^2 + 7x + 3 = 0 2 x 2 + 7 x + 3 = 0 using the formula.
Solve x 2 + 4 x − 1 = 0 x^2 + 4x - 1 = 0 x 2 + 4 x − 1 = 0 .
Solve 3 x 2 + 5 x − 2 = 0 3x^2 + 5x - 2 = 0 3 x 2 + 5 x − 2 = 0 by splitting the middle term, and check with the formula.
Which of the following are quadratic equations? (i) 2 x 2 − 5 = 0 2x^2 - 5 = 0 2 x 2 − 5 = 0 (ii) x 2 − 1 x 2 = 5 \displaystyle x^2 - \frac{1}{x^2} = 5 x 2 − x 2 1 = 5 (iii) 2 x 2 + 7 x + 5 2 = 0 \sqrt{2}x^2 + 7x + 5\sqrt{2} = 0 2 x 2 + 7 x + 5 2 = 0
If x = − 1 2 \displaystyle x = -\frac{1}{2} x = − 2 1 is a zero of p ( x ) = 8 x 3 − a x 2 − x + 2 p(x) = 8x^3 - ax^2 - x + 2 p ( x ) = 8 x 3 − a x 2 − x + 2 , find a a a .
Solve 44 x 2 + 65 x + 24 = 0 44x^2 + 65x + 24 = 0 44 x 2 + 65 x + 24 = 0 .
Answers#
Show answers
Δ = 49 − 4 ( 2 ) ( 3 ) = 49 − 24 = 25 \Delta = 49 - 4(2)(3) = 49 - 24 = 25 Δ = 49 − 4 ( 2 ) ( 3 ) = 49 − 24 = 25
Δ = 36 − 20 = 16 \Delta = 36 - 20 = 16 Δ = 36 − 20 = 16 , x = 6 ± 4 2 \displaystyle x = \frac{6 \pm 4}{2} x = 2 6 ± 4 , so x = 5 x = 5 x = 5 or x = 1 x = 1 x = 1 .
Δ = 1 + 48 = 49 \Delta = 1 + 48 = 49 Δ = 1 + 48 = 49 , x = 1 ± 7 4 \displaystyle x = \frac{1 \pm 7}{4} x = 4 1 ± 7 , so x = 2 x = 2 x = 2 or x = − 3 2 \displaystyle x = -\frac{3}{2} x = − 2 3 .
Δ = 49 − 24 = 25 \Delta = 49 - 24 = 25 Δ = 49 − 24 = 25 , x = − 7 ± 5 4 \displaystyle x = \frac{-7 \pm 5}{4} x = 4 − 7 ± 5 , so x = − 1 2 \displaystyle x = -\frac{1}{2} x = − 2 1 or x = − 3 x = -3 x = − 3 .
Δ = 16 + 4 = 20 \Delta = 16 + 4 = 20 Δ = 16 + 4 = 20 , x = − 4 ± 20 2 = − 4 ± 2 5 2 = − 2 ± 5 \displaystyle x = \frac{-4 \pm \sqrt{20}}{2} = \frac{-4 \pm 2\sqrt{5}}{2} = -2 \pm \sqrt{5} x = 2 − 4 ± 20 = 2 − 4 ± 2 5 = − 2 ± 5 .
Product − 6 -6 − 6 , sum 5 5 5 : use 6 6 6 and − 1 -1 − 1 . 3 x 2 + 6 x − x − 2 = 3 x ( x + 2 ) − 1 ( x + 2 ) = ( 3 x − 1 ) ( x + 2 ) 3x^2 + 6x - x - 2 = 3x(x + 2) - 1(x + 2) = (3x - 1)(x + 2) 3 x 2 + 6 x − x − 2 = 3 x ( x + 2 ) − 1 ( x + 2 ) = ( 3 x − 1 ) ( x + 2 ) , so x = 1 3 \displaystyle x = \frac{1}{3} x = 3 1 or x = − 2 x = -2 x = − 2 . Formula: Δ = 25 + 24 = 49 \Delta = 25 + 24 = 49 Δ = 25 + 24 = 49 , x = − 5 ± 7 6 \displaystyle x = \frac{-5 \pm 7}{6} x = 6 − 5 ± 7 gives the same two roots.
(i) and (iii). In (ii) the term 1 x 2 = x − 2 \displaystyle \frac{1}{x^2} = x^{-2} x 2 1 = x − 2 has a negative power.
p ( − 1 2 ) = 8 ( − 1 8 ) − a 4 + 1 2 + 2 = − 1 − a 4 + 5 2 = 0 \displaystyle p\left(-\frac{1}{2}\right) = 8\left(-\frac{1}{8}\right) - \frac{a}{4} + \frac{1}{2} + 2 = -1 - \frac{a}{4} + \frac{5}{2} = 0 p ( − 2 1 ) = 8 ( − 8 1 ) − 4 a + 2 1 + 2 = − 1 − 4 a + 2 5 = 0 , so a 4 = 3 2 \displaystyle \frac{a}{4} = \frac{3}{2} 4 a = 2 3 and a = 6 a = 6 a = 6 .
Δ = 65 2 − 4 ( 44 ) ( 24 ) = 4225 − 4224 = 1 \Delta = 65^2 - 4(44)(24) = 4225 - 4224 = 1 Δ = 6 5 2 − 4 ( 44 ) ( 24 ) = 4225 − 4224 = 1 , x = − 65 ± 1 88 \displaystyle x = \frac{-65 \pm 1}{88} x = 88 − 65 ± 1 , so x = − 64 88 = − 8 11 \displaystyle x = -\frac{64}{88} = -\frac{8}{11} x = − 88 64 = − 11 8 or x = − 66 88 = − 3 4 \displaystyle x = -\frac{66}{88} = -\frac{3}{4} x = − 88 66 = − 4 3 .