Theorem (Stone-Weierstrass)
Let $K$ be a compact topological space.
-
If $A$ is a subalgebra of $C^\R(K)$ that strongly separates points of $K$, then $A$ is dense in $C^\R(K)$.
-
If $A$ is a subalgebra of $C^\C(K)$ that strongly separates points of $K$ and is closed under complex conjugation (i.e. if $f\in A$, then $\bar f\in A$), then $A$ is dense in $C^\C(K)$.