# How do I convert the equation #f(x)=x^2+6x+5# to vertex form?

##### 1 Answer

The answer is

To convert to vertex form, you must complete the square.

#f(x)=(x^2+6x+k)-k+5#

We add

#k=(b/2)^2=(6/2)^2=9#

Substitute

#f(x)=(x^2+6x+9)-9+5#

#=(x+3)^2-4#

You can derive a formula algebraically:

#f(x)=x^2+bx+c#

#=(x^2+bx+(b/2)^2)+c-(b/2)^2#

#=(x+b/2)^2+c-(b/2)^2#

It is a slightly more complicated if

#f(x)=ax^2+bx+c#

You must factor out

#f(x)=a(x^2+b/ax+k)+c-ak#

#=a(x^2+b/ax+(b/(2a))^2)+c-a(b/(2a))^2#

#=a(x+b/(2a))^2+c-(ab^2)/(4a^2)#

#=a(x+b/(2a))^2+c-(b^2)/(4a)#

With a little rearrangement, it should look very familiar:

#=a(x+b/(2a))^2-(b^2-4ac)/(4a)#

If you can complete the derivation yourself, you should have no trouble completing the square with any question. When using the formula, be very careful when

Here is another example: