Find the point on the paraboloid $z=\frac{x^2}{4}+\frac{y^2}{25}$ that is closest to $(3,0,0)$.
So what i did was let (x,y,z) be a point on the paraboloid and let $d(x,y,z)=\sqrt{(x-3)^2+y^2+z^2}$ $$d^2_{min}\implies d_{min}$$ Hence i would consider $d^2$
Let $f(x,y,z)=d^2(x,y,z)$ for easy notation and the constraint function $g(x,y,z)=\frac{x^2}{4}+\frac{y^2}{25}-z$
Next i'm gonna apply the Lagrange multiplier equation $\nabla f=\lambda\nabla g$ $$\nabla f=<2x-6,2y,2z>$$ $$\nabla g=<\frac{x}{2},\frac{2y}{25},-1>$$
This leads me to $2x-6=\frac{\lambda x}{2}$, $2y=\frac{2y}{25}$, $2z=-\lambda$
And now i'm stuck. how do i proceed?
Note that the equations you've got, already gives you, $y=0,4x-12+xz=0$. Then, using the constraint, you get $$(12-4x)=x^3/4\implies x^3+16x-48=0$$ The only real solution to this equation is at $x\approx 2.26945\cdots$. The corresponding $z$ can be calculated from the constraint with $y=0$. Then, the minimum distance is the objective function evaluated at that point.