Hint: $$\mathcal{L}(x,y,\lambda)=f(x,y)+\lambda g(x,y)=(x-1)^2+(y-1)^2+\lambda \left(\frac{x^2}{9}+\frac{y^2}{4}-1\right) $$
Then:
$\frac{\partial \mathcal{L}}{\partial x}=2(x-1)+\frac{2x\lambda}{9}=0 \implies x=\frac{9}{9+\lambda}$
$\frac{\partial \mathcal{L}}{\partial y}=2(y-1)+\frac{\lambda y}{2}=0 \implies y=\frac{4}{4+\lambda}$
$\frac{\partial \mathcal{L}}{\partial \lambda}= \frac{x^2}{9}+\frac{y^2}{4}-1=0$
so $\implies \frac{\left(\frac{9}{9+\lambda}\right)^2}{9}+\frac{\left(\frac{4}{4+\lambda}\right)^2}{4}=1$
$\implies \frac{9}{(9+\lambda)^2}+\frac{4}{(4+\lambda)^2}=1$
Then solve for $\lambda$ (not easy) then plug in value to obtain $x=\frac{9}{9+\lambda}$ and $y=\frac{4}{4+\lambda}$ that are required
Minimizing the squared distance,
$$\begin{array}{ll} \text{minimize} & x^2 + y^2 + (z-c)^2\\ \text{subject to} & z^2 = x^2 + 4 y^2\end{array}$$
Let the Lagrangian be
$$\mathcal L (x,y,z,\lambda) := x^2 + y^2 + (z-c)^2 + \lambda (x^2 + 4 y^2 - z^2)$$
Taking the partial derivatives and finding where they vanish, we obtain
$$\begin{array}{rl} (1 + \lambda) \, x &= 0\\ (1 + 4\lambda) \, y &= 0\\ (1 - \lambda) \, z &= c\\ x^2 + 4 y^2 - z^2 &= 0\\\end{array}$$
We have two cases to consider.
$\color{blue}{\boxed{\lambda = -1}}$
In this case, $y = 0$ and $z = \frac c2$. The value of $x$ is given by
$$x = \pm \sqrt{ z^2 - 4 y^2 } = \pm \frac c2$$
Hence, we have the two points
$$(x,y,z) = \left( \pm \frac c2, 0, \frac c2 \right)$$
whose squared distance from $(0,0,c)$ is $\frac{c^2}{2}$.
$\color{blue}{\boxed{\lambda = - \frac 14}}$
In this case, $x = 0$ and $z = \frac{4c}{5}$. The value of $y$ is given by
$$y = \pm \frac 12 \sqrt{ z^2 - x^2 } = \pm \frac{2c}{5}$$
Hence, we have the two points
$$(x,y,z) = \left( 0, \pm \frac{2c}{5}, \frac{4c}{5} \right)$$
whose squared distance from $(0,0,c)$ is $\frac{c^2}{5} < \frac{c^2}{2}$. This is the minimal squared distance.
Example
Let $c = 5$. Hence, the points on the cone closest to $(0,0,5)$ are $(x,y,z) = ( 0, \pm 2, 4 )$. Here is a plot of the cone and the line segment whose endpoints are $(0,0,5)$ and $( 0, 2, 4)$
The length of the line segment is $\sqrt 5$.
Best Answer
This can actually be done using the distance function $$ d^2(x,y,z,w) \;\; =\;\; x^2 + \left (y-\sqrt{2}\right )^2 + \left (z - \sqrt{2}\right )^2 + w^2. $$
Now, for whatever reason the method of Lagrange multipliers doesn't seem to work if we use the constraints given in the prompt, though we can reformulate them to come up with another constraint. If we can solve $y^2 + z^2 = 2-x^2$ and plug this into the other equation we get the constraint $$ w^2 - x^2 \;\; =\;\; 1. $$
While I can't speak as to why using the original two constraints won't work here, they will work for the constraint given above and one of the original two. Let's take $f(x,y,z,w) = w^2-x^2-1$ and $g(x,y,z,w) = x^2 +y^2 + z^2 - 2$ and use the minimization problem on the following Lagrangian: $$ L(x,y,z,w) \;\; =\;\; d^2(x,y,z,w) + \lambda\left (w^2-x^2-1 \right ) + \mu\left (x^2+y^2+z^2-2 \right ). $$
Solving for our gradients: \begin{eqnarray*} 2x & = & -2\lambda x + 2\mu x \\ 2\left (y-\sqrt{2}\right ) & = & 2\mu y \\ 2\left (z-\sqrt{2}\right ) & = & 2\mu z \\ 2w & = & 2\lambda w. \end{eqnarray*}
Taking the ratio of the second and third equations we can uncover that $y=z$. The last equation gives us that $\lambda=1$. We can plug this into our first equation and find out that $2x = \mu x$. Rather than solving for $\mu$ we can take the ratio of this equation and the second equation to find
$$ \frac{2x}{y-\sqrt{2}} \;\; =\;\; \frac{x}{y} \hspace{2pc} \Longrightarrow \hspace{2pc}x\left (y+\sqrt{2}\right ) \;\; =\;\; 0. $$
This last equation tells us that either $y = z = -\sqrt{2}$ or that $x=0$. Now if $y=z=-\sqrt{2}$, then this will not satisfy our original constraints defining our manifold, so we have to discard these as a possibility. Taking $x=0$, we find that $w^2 = 1$ and $w = \pm 1$. This tells us that $$ x^2 + y^2 + z^2 = 2\hspace{2pc} \Longrightarrow \hspace{2pc} 2y^2 = 2 $$ thus $y = \pm1$ and $z=\pm1$. This gives us all of our possibilities for points on the manifold that will work, namely the eight possibilities $(0,\pm1,\pm1,\pm1)$. To minimize the distance given above we want to take $y=z=1$, but this leaves our value for $w$ ambiguous. We therefore conclude there are two minimizing points: $$ (0,1,1,1) \hspace{2pc}\text{and} \hspace{2pc} (0,1,1,-1). $$