Let $a_1,a_2,\dotsb ,a_n$ be positive real numbers, and $m$ a positive even integer. For a real number $b$, let $S_b$ denote the set of solutions to the equation $a_1x_1^m + a_2x_2^m + \dotsb + a_nx_n^m = b$.
Prove that $S_b$ is a compact subset of $\mathbb{R}^n$. Is the conclusion true if the condition that $m$ be even is relaxed?
My attempt: We want to show that $S_b$ is compact, i.e. closed and bounded. Since the powers of $x_i$ are even, each term must be positive, and hence we can bound any component $x_j$ of the solution. For example,
$a_1x_1^m = b -a_2x_2^m -\dotsb -a_nx_n^m \leq b$
so $x_1 \leq (\frac{b}{a_1})^{1/m}$.
However, how do we show it is closed? My intuition says to use the fact that a preimage of a closed set is closed for a continuous function. Does that apply here?
Hint: I assume $a_i>0$. The set of solutions is closed since it is of the form $g^{-1}(b)$ where $g$ is continuous $g(x_1,...,x_n)=a_1x_n^m+...a_nx^m$.
It is bounded since if $a_1x_1^m+...+a_nx_n^m=b$ implies $a_ix_i^m\leq b$.
If $m$ is odd it is not true,$x_1+..+x_n=1$ is an hyperplane.