I'm familiar with the Weierstrass approximation theorem and some aspects of the Stone-Weierstrass theorem but I mainly only get it for closed intervals [a, b]. I am familiar with the proof that begins with showing f is continuous on $[0, 1]$ and going from there. I have a 3-d set which forms an ellipsoid and I'd like to show that any continuous function on that set can also be approximated by a polynomial. Is there a way to extend the proof of Weierstrass approximation theorem or is this way over my head.
For example, [this post] (Showing a continuous functions on a compact subset of $\mathbb{R}^3$ can be uniformly approximated by polynomials) has an example set but I can't really follow the answer. I only know introductory real analysis. I'm guessing there's a way to go from the $[0, 1]$ case to the unit cube case but I'm missing that leap.
The Stone-Weierstrass theorem says that any closed subalgebra of $C(S)$ (where $S$ is any compact Hausdorff space) that separates points, contains the constants and is closed under complex conjugation is all of $C(S)$. In this case your ellipsoid $S$ is a compact Hausdorff space. Let $A$ be the uniform closure in $C(S)$ of the polynomials in $x, y, z$. This satisfies all requirements of the Stone-Weierstrass theorem, so it is $C(S)$, i.e. every continuous function on $S$ can be uniformly approximated by polynomials.