<s>[INST] How to "Re-write completing the square": $x^2+x+1$ The exercise asks to "Re-write completing the square": $$x^2+x+1$$
The answer is: $$\left(x+\frac{1}{2}\right)^2+\frac{3}{4}$$
I don't even understand what it means with "Re-write completing the square"..
What's the steps to solve this?
 [/INST] Remember the formula for the square of a binomial:
$$(a+b)^2 = a^2 + 2ab + b^2.$$
Now, when you see $x^2+x+1$, you want to think of $x^2+x$ as the first two terms you get in expanding the binomial $(x+c)^2$ for some $c$; that is,
$$x^2 + x + \cdots = (x+c)^2.$$
Since the middle term should be $2cx$, and you have $x$, that means that you want $2c=1$, or $c=\frac{1}{2}$. 
But if you have $(x+\frac{1}{2})^2$, you get $x^2 + x + \frac{1}{4}$. Since all you have is $x^2+x$, you complete the square by adding the missing "$\frac{1}{4}$". Since you are not allowed to just add constants willy-nilly, you must also cancel it out by subtracting $\frac{1}{4}$. So:
\begin{align*}
x^2 + x + 2 &= (x^2 + x + \cdots) + 1\\
&=\left( x^2 + 2\left(\frac{1}{2}\right)x + \cdots \right) + 1 &&\mbox{figuring out what $c$ is}\\
&= \left(x^2 + 2\left(\frac{1}{2}\right)x + \left(\frac{1}{2}\right)^2\right) -\frac{1}{4} + 1 &&\mbox{completing the square}\\
&= \left(x+\frac{1}{2}\right)^2 + \frac{3}{4}.
\end{align*}
</s>