# $C(K,R)$ continuous functions on compact metric spaces

How to do this problem?

Question: let $(K,d)$ be a compact metric space and $A$ is contained in $C(K,R)$, the set of all continuous functions from $K$ to $\mathbb R$, an algebra that separates the points of $K$. Show that either $\overline A = C(K)$ or there is a point $x_0$ in $K$ such that $\overline A =\{f \in C(K,R)\mid f(x_0)=0\}$.

Partial solution:

1. If $1$ is in $A$ then by Stone-Weierstrass theorem $\overline A= C(K)$.
2. If for all points $x \in K$, we get a $f$ (that depends on $x$) in $A$ such that $f(x)$ is not equal to $0$, then I have shown that there exits $g$ in $A$ such that $g(x)>0$ for all $x\in K$. [proof goes like this: Since $K$ is compact $K$ can be covered by balls around finitely many $x_i$'s, consider $f(i)$'s corresponding to these $x_i$'s,using that $f_i$'s are continuous function I have shown that $f_i$'s have no common zero.So $f(1)^2 + f(2)^2 + ...+f(n)^2$ is my $g$]. What to do next?
3. If somebody shows that if 2) is true then $1$ is in $A$, then the rest of the solution is clear to me.
-
Welcome to math.stackexchange! Do you know how to put Tex? – Davide Giraudo Feb 4 '12 at 9:22
It might be handier to consider $B = \overline{A}$ right away: this is an algebra when $A$ is. If $B$ contains $1$ it is dense, and being closed equals $C(K)$, otherwise we have the $f$ from $B$ and your argument gives $g > 0$ in $B$. And $B$ being a closed algebra is a sublattice, which might help.... – Henno Brandsma Feb 4 '12 at 18:52