I am practicing completing the square, in this example I needed to find the roots of the equation y=x^2+6x+9 and I used two different methods as part of my practice. I verified the equation in an online graphing calculator (attached as image). I spelled out each step a lot as I want to practice my understanding thoroughly.
Im asking for a review in my approach, can you verify I did everything correctly? Do you have any suggestions or critique? Thanks for the help!
Solve for x to find the roots of parabola y=x^2+6x+9.
METHOD 1:
y=x^2+6x+9
x^2+6x+9=0
x^2+6x=-9
PLUS:
x^2+3^2+6x=-9+(-3)^2
(a+b)^2=a^2+b^2+2ab
x^2+3^2+2*2*3x=0
(x+3)^2=0
sqrt((x+3)^2)=sqrt(0)
x+3=0
x=-3
MINUS:
x^2-3^2+6x=-9-(-3)^2
(a-b)^2=a^2+b^2-2ab
x^2+3^2-2*2*3x=-18
(x-3)^2=-18
NO SOLUTION FOR MINUS, SINCE SQUARE ROOT OF -18 IS NOT POSSIBLE
NOT POSSIBLE: sqrt((x-3)^2)=sqrt(-18)
Therefore x=-3 is the only solution to solve for x in y=x^2+6x+9, and therefore y=x^2+6x+9 has only one root (-3,0) which is also the coordinate of the vertex of the parabola y=x^2+6x+9
METHOD 2:
$ax^2+bx+c=0$
$x2+(b/a)x=-c/a$
$(x+b/(2a))^2=-c/a+b^2/(4a^2)$
-c/a+b^2/(4a^2)=(b^2-4ac)/(4a^2)
x+b/(2a)=+squareroot(b^2-4ac)/(2a)
PLUS: x=(-6+squareroot(b^2-4ac))/(2a)
MINUS: x=(-6-squareroot(b^2-4ac))/(2a)
PLUS:
x=(-6+squareroot(b^2-4ac))/(2a)
x^2+6x+9=0
x=(-6+squareroot(6^2-4*9))/2
x=(-6+squareroot(36-36))/2
x=-6/2
x=-3
MINUS:
x=(-6-squareroot(b^2-4ac))/(2a)
x^2+6x+9=0
x=(-6-squareroot(6^2-4*9))/2
x=(-6-squareroot(36-36))/2
x=-6/2
x=-3
Therefore x=-3 is the only solution to solve for x in y=x^2+6x+9, and therefore y=x^2+6x+9 has only one root (-3,0) which is also the coordinate of the vertex of the parabola y=x^2+6x+9