audio read-through Quadratic Functions and the Completing the Square Technique (Part 2)

(This page is Part 2. Click here for Part 1.)

Caution! Completing the Square Changes the Expression!

Be careful—when you add $\,{(\frac{b}{2})}^2\,$ to complete the square, you are changing the expression that you started with!

In other words, the expression you started with (which wasn't a perfect square) and the expression you end up with (which is a perfect square) are different.

Sometimes you just want to rename an expression in a form that involves a perfect square; you don't want to change the original expression. In this situation, when you add $\,{(\frac{b}{2})}^2\,,$ you also have to subtract it at the same time. This is illustrated in the next example.

Example (Renaming as an Expression Involving a Perfect Square Trinomial)

Question: Rename $\ x^2+6x\ $ as an expression involving a perfect square trinomial.

Solution: Note that $\,(\frac{6}{2})^2 = 3^2 = 9\,.$

$x^2+6x\,$ starting expression
$\ \ =x^2+6x+9-9$ add zero in an appropriate form
$\ \ =(x^2+6x+9)-9$ regroup
$\ \ =(x+3)^2-9$ rename the perfect square

The technique of completing the square only works when the coefficient of the $\,x^2\,$ term is $\,1\,.$ Any other coefficient must be factored out before completing the square, as shown next.

Going From Standard Form to Vertex Form

In what follows, the completing the square technique is applied to the standard form, $\,ax^2+bx+c\,,$ to change it to vertex form, $\,a{(x-h)}^2+k\,$:

          (original expression)
$\quad = (ax^2+bx)+c$
          (group first two terms)
$\quad =a(x^2+\frac{b}{a}x)+c$
          (factor $\,a\ne 0\,$ out of the first two terms)
$ \quad =a\color{red}{\bigl(}x^2+\frac{b}{a}x \color{blue}{+(\frac{b}{2a})^2 - (\frac{b}{2a})^2} \color{red}{\bigr)}+c $
          (add zero in an appropriate form
          inside the parentheses;
          note that $ \frac{b}{a}\div 2 =\frac{b}{a}\cdot \frac{1}{2} =\frac{b}{2a} $)
$ \quad =a\left(x^2+\frac{b}{a}x+{(\frac{b}{2a})}^2 \right) - a{(\frac{b}{2a})}^2 + c $
          (distributive law)
$\quad =a{(x+\frac{b}{2a})}^2 + \text{stuff}$
          (rename as a perfect square)

Notice that the $x$-value of the vertex is $\,-\frac{b}{2a}\,.$ This is worth recording and memorizing.

Don't bother memorizing the yucky formula for the $\,y$-value of the vertex. Once you have the $x$-value, it's easy to compute the corresponding $y$-value.


Let $\,a\ne 0\,.$

The vertex of the parabola $\ y=ax^2+bx+c\ $ has $x$-value equal to $\displaystyle\,-\frac{b}{2a}\,.$

In this context, the expression $\,-\frac{b}{2a}\,$ is often called the vertex formula.

To conclude, we look at two different methods for going from standard form to vertex form:

Example (Going from Standard Form to Vertex Form)

Question: Write $\,y=5x^2+3x-1\,$ in vertex form and give the coordinates of the vertex.
First Solution: Use the technique of completing the square to put the function in vertex form: $$ \begin{align} \cssId{s57}{y}\ &\cssId{s58}{= 5x^2+3x-1}\cr\cr &\cssId{s59}{= 5(x^2 +\frac{3}{5}x) - 1}\cr\cr &\cssId{s60}{= 5\left(x^2 +\frac{3}{5}x+(\frac{3}{10})^2 - (\frac{3}{10})^2\right)-1}\cr\cr &\cssId{s61}{= 5\bigl(x +\frac{3}{10}\bigr)^2-5\cdot \frac{9}{100}-1}\cr\cr &\cssId{s62}{= 5\bigl(x+\frac{3}{10}\bigr)^2 - \frac{29}{20}} \end{align} $$ Thus, the vertex is $\,\bigl(-\frac{3}{10},-\frac{29}{20}\bigr)\,.$

Second Solution: Use the vertex formula to find the $x$-value of the vertex:

$$\cssId{s66}{-\frac{b}{2a} = -\frac{3}{2(5)} = -\frac{3}{10}}$$
Find the corresponding $y$-value:
$$ \begin{align} y &= \,5(-\frac{3}{10})^2+3(-\frac{3}{10})-1\cr\cr &= -\frac{29}{20} \end{align} $$

Substitute the values of $\,a\,,$ $\,h\,$ and $\,k\,$ into $\ y = a(x-h)^2 + k\,.$

With $\,h = -\frac{3}{10}\,,$ $\,k = -\frac{29}{20}\,,$ and $\,a = 5\,,$ vertex form is:

$$y=5\bigl(x +\frac{3}{10}\bigr)^2 -\frac{29}{20}$$

Finally, you could zip up to WolframAlpha and type in:

vertex of y = 5x^2 + 3x - 1

Using the coordinates of the vertex, it's then easy to write the vertex form yourself!

Concept Practice