# How do you solve an equation by completing the square?

Mar 9, 2015

(This is going to take a minute or two.)

Completing incomplete squares:

Background:
The square of an expression of the form $x + n$ or $x - n$ is:
${\left(x + n\right)}^{2} = {x}^{2} + 2 n x + {n}^{2}$ or
${\left(x - n\right)}^{2} = {x}^{2} - 2 n x + {n}^{2}$.
Notice: the sign on the middle term matches the sign in the middle of the binomial on the left AND the last term is positive in both.
Also notice that if we allow $n$ to be negative, we only need to write and think about ${\left(x + n\right)}^{2} = {x}^{2} + 2 n x + {n}^{2}$ (The sign in the midde will match the sign of $n$.)

Completing the square:
An expression like ${x}^{2} + 6 x$ may be thought of as an "incomplete" square. To make it complete, we'd need to add ${n}^{2}$ to the expression. We can figure out what to use for $n$ by realizing that the $6 x$ in the middle need to be $2 n x$. So, we want $n = 3$ and ${n}^{2} = 9$.

Of course you can's just add a number to an expression without changing the value of the expression, so if we want to keep the same value we'll have to make up for adding $9$.
We do this by also subtracting $9$. That doesn't change the value of ${x}^{2} + 6 x$, but it does change the way it's written.

We write ${x}^{2} + 6 x + 9 - 9$ If we group it this way: $\left({x}^{2} + 6 x + 9\right) - 9$ then we have a perfect square minus $9$

And $\left({x}^{2} + 6 x + 9\right) - 9 = {\left(x + 3\right)}^{2} - 9$

Solving an equation by completing the square:

Solve: ${x}^{2} + 6 x - 16 = 0$ (by completing the square)

Each of the following equations is equivalent (has exactly the same solutions) as the lines before it.

${x}^{2} + 6 x - 16 = 0$
${x}^{2} + 6 x = 16$
${x}^{2} + 6 x + 9 - 9 = 16$.
${x}^{2} + 6 x + 9 = 16 + 9$. So the first equation is equivalent to
${\left(x + 3\right)}^{2} = 25$

And the last equation above is satisfied exactly when:
$x + 3 = - 5$ or $x + 3 = 5$. So $x = - 8$ or $x = 2$.

The solution set to the first equation is: $\left\{- 8 , 2\right\}$.

I'll post another (more challenging) example too.

Mar 9, 2015

Second Example

(You should probably read the first one first.)

Solve by completing the square:

$3 {x}^{2} - 7 x + 3 = 0$. This is equivalent to:

$3 {x}^{2} - 7 x = - 3$. Which is true if and only if

$3 \left({x}^{2} - \frac{7}{3} x\right) = - 3$.

Do you see what we did there? We factored out a $3$. But, since $7$ is not divisible by $3$, we just wrote $\frac{7}{3}$.

Now we will complete the square inside the parentheses.

The middle term is $\frac{7}{3} x$ Recall that the middle term of ${\left(x + n\right)}^{2}$ is $2 n x$.
So we must have $2 n = \frac{7}{3}$ and $n = \frac{1}{2} \cdot \frac{7}{3}$ or $n = \frac{7}{6}$. To make the expression in parehtheses inc lude a complete square, we need to add ${\left(\frac{7}{6}\right)}^{2}$ which is $\frac{49}{36}$. To avoid changing the number (not just the way it's written) we'll also subtracting.

$3 \left({x}^{2} - \frac{7}{3} x + \frac{49}{36} - \frac{49}{36}\right) = - 3$.

Keeping the perfect square together, we re-write this as:

$3 \left({x}^{2} - \frac{7}{3} x + \frac{49}{36}\right) - 3 \left(\frac{49}{36}\right) = - 3$.

$3 {\left(x - \frac{7}{6}\right)}^{2} - \frac{49}{12} = - 3$.
(Note the signs in the middle and the return of the $\frac{7}{6}$ that we squared earlier.)

$3 {\left(x - \frac{7}{6}\right)}^{2} = \frac{49}{12} - 3$.

$3 {\left(x - \frac{7}{6}\right)}^{2} = = \frac{49}{12} - \frac{36}{12}$.

$3 {\left(x - \frac{7}{6}\right)}^{2} = \frac{13}{12}$. Now get the square alone on the left:

${\left(x - \frac{7}{6}\right)}^{2} = \frac{13}{36}$.

This will be true exactly when:
$x - \frac{7}{6} = \pm \sqrt{\frac{13}{36}}$

$x - \frac{7}{6} = \pm \frac{\sqrt{13}}{\sqrt{36}}$

$x - \frac{7}{6} = \pm \frac{\sqrt{13}}{6}$ And, finally, we see that

$x = \frac{7}{6} \pm \frac{\sqrt{13}}{6}$

Or, better yet: $x = \frac{7 \pm \sqrt{13}}{6}$.