Sub topic 6
Solving quadratics by factorisation
This chapter assumes you can expand brackets such as (x + 2)(x − 3), apply sign rules to products and sums, and rewrite an equation in the standard form ax² + bx + c = 0 with a ≠ 0. You should also know that a root is a value of x that makes the equation true.
Why factorisation works
Factorisation rests on one fact, the zero-product property. If a product of two numbers is zero, at least one of them is zero.
So if ax² + bx + c = 0 can be rewritten as (x − p)(x − q) = 0, then x − p = 0 or x − q = 0. The roots are x = p and x = q.
The property only works when the product equals zero. If the product equals 6, knowing that (x − 2)(x − 3) = 6 tells you nothing about the individual brackets. Always move every term to one side before factorising.
The method has four steps:
- Rewrite the equation as ax² + bx + c = 0.
- Factorise the left side into two brackets.
- Set each bracket equal to zero.
- Solve the two linear equations, then check the roots.
Case 1: a = 1 (monic quadratics)
For x² + bx + c, look for two numbers p and q with p + q = b and p × q = c. Then x² + bx + c = (x + p)(x + q), and the roots are −p and −q.
This works because (x + p)(x + q) = x² + (p + q)x + pq. Matching coefficients gives the two conditions.
Start with the sign of c, because it tells you whether the two numbers share a sign.
| Sign of c | Sign of b | Signs of p and q |
|---|---|---|
| positive | positive | both positive |
| positive | negative | both negative |
| negative | any | opposite signs; the larger in absolute value takes the sign of b |
Example 1. Solve x² − 5x + 6 = 0. Here c is positive and b is negative, so both numbers are negative. The pair −2 and −3 has product 6 and sum −5. So (x − 2)(x − 3) = 0, and x = 2 or x = 3.
Example 2. Solve x² + 2x − 15 = 0. Here c is negative, so the signs differ. The pair 5 and −3 has product −15 and sum 2. So (x + 5)(x − 3) = 0, and x = −5 or x = 3.
Notice that the roots are the negatives of the numbers inside the brackets. Forgetting this flip is the most common sign error.
The following function automates the search. It is a good way to check your hand work.
def factor_monic(b, c):
"""Return (p, q) with p + q = b and p * q = c, or None if no integer pair exists."""
if c == 0:
return (0, b) # x^2 + bx = x(x + b)
for p in range(-abs(c), abs(c) + 1):
if p != 0 and c % p == 0:
q = c // p
if p + q == b:
return (p, q)
return None
for b, c in [(-5, 6), (1, -12), (1, 1)]:
pair = factor_monic(b, c)
if pair is None:
print(f"x^2 + {b}x + {c}: no integer factors, use the formula")
else:
p, q = pair
print(f"x^2 + {b}x + {c} = (x + {p})(x + {q}); roots {sorted([-p, -q])}")The last case, x² + x + 1, returns None. That is a signal to switch methods. The next chapter covers the quadratic formula.
Case 2: a ≠ 1 (splitting the middle term)
For ax² + bx + c, find two numbers whose sum is b and whose product is a × c. Use them to split the middle term, then group.
Example 3. Solve 6x² + x − 12 = 0.
- Compute a × c = 6 × (−12) = −72.
- Find two numbers with product −72 and sum 1. The pair 9 and −8 works.
- Split the middle term: 6x² + 9x − 8x − 12 = 0.
- Group: 3x(2x + 3) − 4(2x + 3) = 0.
- Factor out the common bracket: (2x + 3)(3x − 4) = 0.
- The roots are x = −3/2 and x = 4/3.
Check x = 4/3: 6 × 16/9 = 32/3, and 32/3 + 4/3 = 12, so 12 − 12 = 0. ✓
The grouping step only works if both groups produce the same bracket. If they don't match, an arithmetic slip happened earlier, often in the sign of one of the two split numbers. Try swapping the order of the two split terms before you start over.
Special patterns worth recognising
Some quadratics factor on sight. Spotting these saves the search for a pair.
| Pattern | Factorised form | Example |
|---|---|---|
| Difference of squares: x² − k² | (x − k)(x + k) | x² − 49 = 0 gives x = ±7 |
| Perfect square: x² + 2kx + k² | (x + k)² | x² + 6x + 9 = 0 gives x = −3 |
| Perfect square: x² − 2kx + k² | (x − k)² | x² − 10x + 25 = 0 gives x = 5 |
| No constant term: ax² + bx | x(ax + b) | 3x² − 12x = 0 gives x = 0 or x = 4 |
A perfect square gives a repeated root. The equation x² − 10x + 25 = 0 has one distinct solution, x = 5, though it counts as a root twice. You will see in a later chapter that this corresponds to a discriminant of zero.
Edge cases and common errors
Dividing by x loses a root. Consider x² = 5x. Dividing both sides by x gives x = 5, but x = 0 also satisfies the equation. The safe route is to move everything to one side: x² − 5x = 0, so x(x − 5) = 0, and x = 0 or x = 5.
Setting a product equal to a non-zero number. Consider x(x − 4) = 12. It is wrong to say x = 12 or x − 4 = 12. Expand instead: x² − 4x − 12 = 0, so (x − 6)(x + 2) = 0, and x = 6 or x = −2. Check: 6 × 2 = 12 ✓, and (−2)(−6) = 12 ✓.
Not rearranging when the leading coefficient is negative. For −x² + 3x + 10 = 0, multiply the whole equation by −1 to get x² − 3x − 10 = 0. This gives (x − 5)(x + 2) = 0, so x = 5 or x = −2. Multiplying by −1 does not change the roots, but it makes the factor search easier.
Common factors in all terms. For 2x² − 10x + 12 = 0, divide by 2 first. You get x² − 5x + 6 = 0, which is Example 1. Removing a common factor shrinks the numbers and reduces the chance of error.
Non-integer roots. Not every quadratic factors over the integers. The equation x² − 2x − 1 = 0 has roots 1 ± √2, and no integer pair has product −1 and sum −2. If your search finds nothing after a short, systematic list of factor pairs, switch to the formula.
Mixing up the two possible sign patterns. When c is negative, both (p, q) = (5, −3) and (−5, 3) have the same product. Only one has the correct sum. Check the sum before you write the brackets.
A quick verification habit
After finding roots, confirm them using the relationships between roots and coefficients. For x² − 5x + 6 = 0 with roots 2 and 3, the sum should be −b/a = 5 and the product should be c/a = 6.
a, b, c = 1, -5, 6
roots = [2, 3]
assert sum(roots) == -b / a
assert roots[0] * roots[1] == c / a
print("sum =", sum(roots), "product =", roots[0] * roots[1])This check takes a few seconds and catches most sign errors. A later chapter develops these relationships fully.
Practice
Exercise
Solve 2x² − 5x − 3 = 0 by splitting the middle term.
Show answer
a × c = −6, and the numbers with product −6 and sum −5 are −6 and 1. Then 2x² − 6x + x − 3 = 2x(x − 3) + 1(x − 3) = (x − 3)(2x + 1). The roots are x = 3 and x = −1/2.
Exercise
Solve x(x − 4) = 12. Why is "x = 12 or x − 4 = 12" wrong?
Show answer
The zero-product property needs the product to equal 0, not 12. Expand to x² − 4x − 12 = 0, then factorise as (x − 6)(x + 2) = 0. The roots are x = 6 and x = −2.
Exercise
A student solves x² = 7x by dividing both sides by x and gets x = 7. What did the student miss, and what is the full solution?
Show answer
Dividing by x discards the root x = 0. Writing x² − 7x = 0 gives x(x − 7) = 0, so x = 0 or x = 7.