<s>[INST] Formula for completing the square? My math teacher said that this was the formula for completing the square.
Original function: $$ax^2 + bx + c$$
Completed square: $$a\left(x + \frac{b}{2a}\right)^2 - \frac{b^2}{4a} + c$$
However, using this formula I'm not getting the same answers that I would get just by determining the stuff myself.  Is this correct?
 [/INST] Let me derive it for you,
$$ax^2+bx+c= a \left( x^2+\frac{b}{a} x +\frac ca \right) = a\left(x^2+2\frac{b}{2a} x + \left( \frac b{2a} \right) ^2 - \left( \frac b{2a} \right) ^2+\frac ca \right)$$ 
$$ = a \left\{ \left(x+\frac{b}{a}\right)^2 - \frac{(b^2-4ac)}{4a^2} \right\} = a\left(x + \frac{b}{2a}\right)^2 - \frac{b^2}{4a} + c $$
Btw how are you applying this?
</s>