I am studying for the math GRE subject test, and my practice exam has a problem that goes as follows:
Find the minimum distance from the origin to the curve $3x^2 + 4xy + 3y^2=20$.
Apparently I was supposed to solve this using Largrange multipliers, and I will make sure to try that as well. But I didn't do that because when I looked at the problem I saw what I thought would be a simpler method of solving it. I noticed that
$3x^2 + 4xy + 3y^2 = 20 = x^2+y^2 + 2(y+x)^2 = D^2 + 2(y+x)^2$
Therefore, in order to minimize the distance, which is equivalent to minimiziong $D^2$, we can simply minimize $f(x,y) = 20 - 2(y+x)^2$. When I take $f_x=0$ and $f_y=0$, I get the same 2 equations: $-4(x+y) = 0$, which implies that $x=-y$.
However, it turns out that after plugging this in, this is not the answer. In fact, when you do it with lagrange multipliers, you get that not only is $x=-y$ is a critical point, but also $x=y$. It turns out that x=y is the one that actually yields the minimum.
So my question is, where did I go wrong? Why does my solution method leave out one of the critical points?
Any help is greatly appreciated.
Best,
Paul
Edit: I have found the problem with my method, and as Nick points out below it is that there are in fact two different ways to complete the square. I have a feeling that something slightly deep is going on here, and if anyone could illuminate further I would really appreciate it.

I apologize if this answer is not detailed enough as I do not have a thorough solution to your problem myself. But I do believe that you leave out one critical point because the way you create the square is somewhat arbitrary. For example, you could have written
$3x^2 + 4xy + 3y^2 = 20 = 5(x^2 + y^2) - 2(x-y)^2=5D^2 - 2(x-y)^2$
so then you need to minimize $f(x,y) = 20 + 2(x-y)^2$, which gives you $x=y$. That is your second critical point.