How can I write a function that would complete the square in a quadratic polynomial expression such that, for example,
In[1]:= CompleteTheSquare[5 x^2 + 27 x - 5, x]
Out[1]= -(829/20) + 5 (27/10 + x)^2
? evaluates to
-(829/20) + 5 (27/10 + x)^2