⬜ Completing the Square

OCR FSMQ Additional Maths · Algebra (AL5)

Level 3 · Ages 15–16

← Back to topic overview
1 The Identity
AL5 — as the specification writes it
$ax^2 + bx + c \equiv a(x+p)^2 + q$
Completing the square rewrites a quadratic so the variable appears only once. That single change unlocks three things at once: the vertex, the maximum or minimum value, and an exact solution without the formula.
It is an identity, not an equation. The specification uses $\equiv$. You are not solving anything — you are rewriting. Do not add "$=0$".
2 The Simple Case: $a = 1$
The shortcut
$x^2 + bx + c \equiv \left(x + \tfrac{b}{2}\right)^2 - \left(\tfrac{b}{2}\right)^2 + c$
Worked Example 1 — A positive middle term

Express $x^2 + 8x + 3$ in completed-square form.

Half of $8$ is $4$, so start with $(x+4)^2$.
$(x+4)^2 = x^2 + 8x + 16$ — that is $16$ too much.
$x^2 + 8x + 3 \equiv (x+4)^2 - 16 + 3$
$\equiv (x+4)^2 - 13$
Always check by expanding: $(x+4)^2 - 13 = x^2 + 8x + 16 - 13 = x^2 + 8x + 3$ ✓
Worked Example 2 — A negative middle term

Express $x^2 - 10x + 21$ in completed-square form.

Half of $-10$ is $-5$, giving $(x-5)^2$.
$(x-5)^2 = x^2 - 10x + 25$, so subtract $25$.
$\equiv (x-5)^2 - 25 + 21 = (x-5)^2 - 4$
The number inside the bracket keeps the same sign as $\tfrac{b}{2}$. Here $b$ is negative, so the bracket is $(x-5)$.
3 When $a \neq 1$
Worked Example 3 — Positive $a$

Express $2x^2 + 12x + 5$ in the form $a(x+p)^2 + q$.

$2x^2 + 12x + 5 = 2\left(x^2 + 6x\right) + 5$
Inside: $x^2 + 6x = (x+3)^2 - 9$
$= 2\left[(x+3)^2 - 9\right] + 5$
$= 2(x+3)^2 - 18 + 5$
$\equiv 2(x+3)^2 - 13$
The commonest error: forgetting to multiply the $-9$ by the $2$. It becomes $-18$, not $-9$.
Worked Example 4 — Negative $a$

Express $5 - 4x - x^2$ in the form $q - (x+p)^2$.

Rearrange and factor out $-1$: $-\left(x^2 + 4x\right) + 5$
Inside: $x^2 + 4x = (x+2)^2 - 4$
$= -\left[(x+2)^2 - 4\right] + 5$
$= -(x+2)^2 + 4 + 5$
$\equiv 9 - (x+2)^2$
Because $a$ is negative this parabola opens downwards, so $9$ is a maximum, reached at $x = -2$.
4 Reading Off the Answers
From $y = a(x+p)^2 + q$
Vertex at $(-p,\; q)$  ·  line of symmetry $x = -p$
If $a > 0$: minimum $y = q$. If $a < 0$: maximum $y = q$.
x y (−p, q) line of symmetry x = −p
Worked Example 5 — Vertex and minimum

Find the coordinates of the vertex of $y = x^2 - 6x + 11$ and state the minimum value of $y$.

$x^2 - 6x + 11 \equiv (x-3)^2 - 9 + 11 = (x-3)^2 + 2$
Here $p = -3$ and $q = 2$, so the vertex is $(3,\, 2)$.
$(x-3)^2 \geqslant 0$ always, so $y \geqslant 2$. The minimum value of $y$ is $2$ at $x = 3$.
This is also a neat proof that the curve never crosses the $x$-axis: $y$ can never reach $0$. Confirm with the discriminant: $36 - 44 = -8 < 0$ ✓
5 Solving by Completing the Square

Because the variable appears once, you can undo the operations one at a time to get an exact answer.

Worked Example 6 — An exact solution

Solve $x^2 + 6x - 2 = 0$, giving your answers in surd form.

$x^2 + 6x - 2 \equiv (x+3)^2 - 9 - 2 = (x+3)^2 - 11$
$(x+3)^2 - 11 = 0$, so $(x+3)^2 = 11$
$x + 3 = \pm\sqrt{11}$
$x = -3 \pm \sqrt{11}$
Never lose the $\pm$. Square-rooting both sides of an equation always gives two possibilities.
Worked Example 7 — Proving the quadratic formula

Completing the square on the general quadratic gives the formula itself.

$ax^2 + bx + c = 0 \;\Rightarrow\; a\left[\left(x + \tfrac{b}{2a}\right)^2 - \tfrac{b^2}{4a^2}\right] + c = 0$
$\left(x + \tfrac{b}{2a}\right)^2 = \tfrac{b^2}{4a^2} - \tfrac{c}{a} = \tfrac{b^2 - 4ac}{4a^2}$
$x + \tfrac{b}{2a} = \pm\dfrac{\sqrt{b^2-4ac}}{2a}$
$x = \dfrac{-b \pm \sqrt{b^2-4ac}}{2a}$
This is why $b^2 - 4ac$ decides everything: it is the number you are square-rooting. Negative means no real solutions.
6 Quick Reference

The form

$ax^2+bx+c \equiv a(x+p)^2+q$.

Finding $p$

$p = \tfrac{b}{2a}$ — half the middle coefficient after factoring out $a$.

Finding $q$

Subtract $ap^2$, then add $c$.

Vertex

$(-p,\, q)$ — the sign flips.

Symmetry

The line $x = -p$.

$a>0$

$q$ is the minimum value.

$a<0$

$q$ is the maximum value.

Solving

Isolate the bracket, square-root with $\pm$.

No real roots

If $a>0$ and $q>0$, the curve misses the axis.

Always check

Expand your answer back out.

7 Practice Questions
Question 1

Express $x^2 + 4x + 9$ in the form $(x+p)^2 + q$.

▶ Show solution

Half of $4$ is $2$: $(x+2)^2 = x^2 + 4x + 4$.

$\equiv (x+2)^2 - 4 + 9 = (x+2)^2 + 5$

Question 2

Express $x^2 - 12x + 40$ in completed-square form and write down the minimum value.

▶ Show solution

$\equiv (x-6)^2 - 36 + 40 = (x-6)^2 + 4$

Minimum value $4$, at $x = 6$.

Question 3

Express $x^2 + 5x + 1$ in the form $(x+p)^2 + q$.

▶ Show solution

Half of $5$ is $\tfrac52$: $\left(x + \tfrac52\right)^2 = x^2 + 5x + \tfrac{25}{4}$.

$\equiv \left(x + \dfrac{5}{2}\right)^2 - \dfrac{25}{4} + 1 = \left(x + \dfrac{5}{2}\right)^2 - \dfrac{21}{4}$

Question 4

Express $3x^2 - 6x + 7$ in the form $a(x+p)^2 + q$.

▶ Show solution

$3\left(x^2 - 2x\right) + 7$

$x^2 - 2x = (x-1)^2 - 1$

$3\left[(x-1)^2 - 1\right] + 7 = 3(x-1)^2 - 3 + 7$

$= 3(x-1)^2 + 4$

Question 5

Find the coordinates of the vertex of $y = 2x^2 + 8x + 3$.

▶ Show solution

$2\left(x^2 + 4x\right) + 3 = 2\left[(x+2)^2 - 4\right] + 3$

$= 2(x+2)^2 - 8 + 3 = 2(x+2)^2 - 5$

Vertex at $(-2,\, -5)$.

Question 6

Express $7 - 6x - x^2$ in the form $q - (x+p)^2$ and state the maximum value.

▶ Show solution

$-\left(x^2 + 6x\right) + 7 = -\left[(x+3)^2 - 9\right] + 7$

$= -(x+3)^2 + 9 + 7 = 16 - (x+3)^2$

Maximum value $16$, at $x = -3$.

Question 7

Solve $x^2 - 4x - 6 = 0$ by completing the square, giving exact answers.

▶ Show solution

$(x-2)^2 - 4 - 6 = 0$

$(x-2)^2 = 10$

$x - 2 = \pm\sqrt{10}$

$x = 2 \pm \sqrt{10}$

Question 8

Show that $x^2 + 2x + 5$ is positive for all real $x$.

▶ Show solution

$x^2 + 2x + 5 \equiv (x+1)^2 - 1 + 5 = (x+1)^2 + 4$

$(x+1)^2 \geqslant 0$ for every real $x$, so the expression is at least $4$.

Since $4 > 0$, the expression is always positive.

Question 9

The curve $y = x^2 + kx + 9$ touches the $x$-axis. Use completing the square to find the two possible values of $k$.

▶ Show solution

$x^2 + kx + 9 \equiv \left(x + \dfrac{k}{2}\right)^2 - \dfrac{k^2}{4} + 9$

Touching the axis means the minimum value is exactly $0$:

$9 - \dfrac{k^2}{4} = 0 \;\Rightarrow\; k^2 = 36 \;\Rightarrow\; k = \pm 6$

Check with the discriminant: $k^2 - 36 = 0$ gives the same answer ✓

Question 10

A ball is thrown so that its height in metres after $t$ seconds is $h = 1 + 14t - 5t^2$.

(a) Express $h$ in completed-square form.   (b) Find the greatest height and when it occurs.   (c) Find, to 2 d.p., when the ball hits the ground.   (d) Explain why only one of the two algebraic solutions in (c) is used.

▶ Show solution

(a) $h = -5t^2 + 14t + 1 = -5\left(t^2 - \dfrac{14}{5}t\right) + 1$

Half of $-\tfrac{14}{5}$ is $-\tfrac{7}{5}$, and $\left(\tfrac{7}{5}\right)^2 = \tfrac{49}{25}$:

$= -5\left[\left(t - \dfrac{7}{5}\right)^2 - \dfrac{49}{25}\right] + 1 = -5\left(t - \dfrac{7}{5}\right)^2 + \dfrac{49}{5} + 1$

$h = \dfrac{54}{5} - 5\left(t - \dfrac{7}{5}\right)^2$

(b) The squared term is subtracted, so $h$ is greatest when it is zero, at $t = \tfrac75 = 1.4$ s.

Greatest height $= \tfrac{54}{5} = 10.8$ m.

(c) Ground level is $h = 0$:

$5\left(t - \dfrac{7}{5}\right)^2 = \dfrac{54}{5} \;\Rightarrow\; \left(t - 1.4\right)^2 = \dfrac{54}{25} = 2.16$

$t - 1.4 = \pm\sqrt{2.16} = \pm 1.4697\ldots$

$t = 2.8697\ldots$ or $t = -0.0697\ldots$

The ball lands at $t = 2.87$ s (2 d.p.).

(d) The negative root corresponds to a time before the ball was thrown. The model only applies for $t \geqslant 0$, so $t = -0.07$ is rejected as physically meaningless — though it is a genuine root of the quadratic.

Completing the Square (AL5) · OCR FSMQ Additional Maths · Created with MathJax