Given the function $f(x,y,z)= x^2+y^2 +\sin(z)$, I am asking to prove that $f$ is getting its golbal minima and global maxima on $\partial \mathcal{U}$, where $$\mathcal{U}=\left\{(x, y, z) \mid \frac{x^{2}}{a^{2}}+\frac{y^{2}}{b^{2}}<1, \frac{x^{2}}{b^{2}}+\frac{y^{2}}{a^{2}}<1\right\} \subset \mathbb{R}^{3}$$ and $$0<a<b.$$
What I did is first argue that $\partial \mathcal{U}$ closed but I do not know how to show that it is bounded and hence use Weierstrass theorem.
After that I defined $$\partial\mathcal{U}=\left\{(x, y, z) \mid \frac{x^{2}}{a^{2}}+\frac{y^{2}}{b^{2}}=1, \frac{x^{2}}{b^{2}}+\frac{y^{2}}{a^{2}}=1\right\} \subset \mathbb{R}^{3}$$ and by using Lagrange multipliers $$\phi \left(x,y,z,\lambda _1,\lambda _2\right)=x^2+y^2+\sin\left(z\right)+\lambda _1\left(\frac{x^2}{a^2}+\frac{y^2}{b^2}-1\right)+\lambda _2\:_{ }\left(\frac{x^2}{b^2}+\frac{y^2}{a^2}-1\right)$$ taking the $\nabla \phi=0$ and getting the folowing: $$2x+\frac{2x\lambda _1}{a^2}+\frac{2x\lambda \:_2}{b^2}=0$$ $$2x+\frac{2x\lambda _1}{b^2}+\frac{2y\lambda \:_2}{a^2}=0$$ $$\frac{x^2}{a^2}+\frac{y^2}{b^2}=1$$ $$\frac{x^2}{b^2}+\frac{y^2}{a^2}=1$$ $$\cos(z)=0$$
Is my method true? How should I procced from here?