%%  chapter-12.tex
%%  Approximation Theory: Chapter 12
%%  Neal L. Carothers
%%  Bowling Green State University
%%  Bowling Green, Ohio  43403
%%  carother@math.bgsu.edu
%%  http://www.bgsu.edu/~carother/


\input 680-setup.tex

\chaptertitle = {Stone-Weierstrass}

\centerline{\hfil\tf The Stone-Weierstrass Theorem\hfil}
\vskip-\baselineskip
\line{\sc Math 680 \hfil 8/1/94}

\noindent
To begin, an {\sl algebra} is a vector space $A$ on which 
there is a multiplication $(f,g)\mapsto fg$ (from $A\times A$ 
into $A$\/) satisfying 
{\itemitem{(i)} 
$(fg)h=f(gh)$, for all $f$, $g$, $h\in A$;}
{\itemitem{(ii)} 
$f(g+h)=fg+fh$ and $(f+g)h=fg+gh$, for all 
$f$, $g$, $h\in A$;}
{\itemitem{(iii)} 
{$\alpha(fg)=(\alpha f)g=f(\alpha g)$, for all
scalars $\alpha$ and all $f$, $g\in A$.\par}}
\noindent
In other words, an algebra is a {\sl ring\/} under vector
addition and multiplication, together with a
compatible scalar multiplication.  The algebra is {\sl commutative\/} if
{\itemitem{(iv)} 
{$fg=gf$, for all $f$,~$g\in A$.\par}}
\noindent
And we say that $A$ has an {\sl identity\/} element 
if there is a vector $e\in A$ such that
{\itemitem{(v)} 
{$fe=ef=f$, for all $f\in A$.\par}}
\noindent
In case $A$ is a normed vector space, we also require
that the norm satisfy
{\itemitem{(vi)} 
{$\Vert fg\Vert\le\Vert f\Vert\,\Vert g\Vert$\par}}
\noindent
(this simplifies things a bit), and in this case we 
refer to $A$ as a {\sl normed algebra}.  If a normed 
algebra is complete, we refer to it as a {\sl Banach algebra}.
Finally, a subset $B$ of an algebra $A$ is called a 
{\sl subalgebra\/} (of $A$\/) if $B$ is itself an 
algebra (under the same operations); that is, if $B$ 
is a (vector) subspace of $A$ which is closed under 
multiplication.

If $A$ is a normed algebra, then all of the various
operations on $A$ (or $A\times A$\/) are continuous.
For example, since
$$\Vert fg-hk\Vert \ = \ \Vert fg-fk+fk-hk\Vert
	\ \le \ \Vert f\Vert\,\Vert g-k\Vert + \Vert k\Vert\,\Vert f-h\Vert$$
it follows that multiplication is continuous. (How?)
In particular, if $B$ is a subspace (or subalgebra)
of $A$, then $\,\overline{\!B}$, the closure of $B$,
is also a subspace (or subalgebra) of $A$.

\noindent
{\bf Examples}

\item{\bf 1.}{%
If we define multiplication of vectors ``coordinatewise,'' 
then $\R^n$ is a commutative Banach algebra with identity
(the vector $(1,\ldots,1)$\/) when equipped with the norm 
$\Vert x\Vert_\infty=\Max_{\strut 1\le i\le n}|x_i|$.  
}

\item{\bf 2.}{%
It's not hard to identify the subalgebras of $\R^n$
among its subspaces.  For example, the subalgebras of
$\R^2$ are $\{(x,0):x\in\R\}$, $\{(0,y):y\in\R\}$, and
$\{(x,x):x\in\R\}$, along with $\{(0,0)\}$ and $\R^2$.
}

\item{\bf 3.}{%
Given a set $X$, we write $B(X)$ for the space of all 
bounded, real-valued functions on $X$.  If we endow $B(X)$ 
with the sup norm, and if we define arithmetic with functions
pointwise, then $B(X)$ is a commutative Banach algebra with 
identity (the constant $1$ function).  The constant functions 
in $B(X)$ form a subalgebra isomorphic (in every sense of
the word) to $\R$.
}

\item{\bf 4.}{%
If $X$ is a metric (or topological) space, then we may consider
$C(X)$, the space of all continuous, real-valued functions on $X$.
If we again define arithmetic with functions pointwise, then
$C(X)$ is a commutative algebra with identity (the constant $1$ 
function).  The bounded, continuous functions on $X$, written
$C_b(X)=C(X)\cap B(X)$, form a closed subalgebra of $B(X)$.
If $X$ is compact, then $C_b(X)=C(X)$.  In other words, if
$X$ is compact, then $C(X)$
is itself a closed subalgebra of $B(X)$ and, in particular,
$C(X)$ is a Banach algebra with identity.
}

\item{\bf 5.}{%
The polynomials form a dense subalgebra of $C[\,a,b\,]$.
The trig polynomials form a dense subalgebra of $C^{2\pi}$.
These two sentences summarize Weierstrass's two classical
theorems in modern parlance and form the basis for Stone's
version of the theorem.  
}

Using this new language, we may restate
the classical Weierstrass theorem to read:
{\sl If a subalgebra $A$ of $C[\,a,b\,]$ 
contains the functions $e(x)=1$ and $f(x)=x$, then $A$ is
dense in $C[\,a,b\,]$.}  Any subalgebra of
$C[\,a,b\,]$ containing $1$ and $x$ actually contains
all the polynomials; thus, our restatement of 
Weierstrass's theorem amounts to the observation
that any subalgebra containing a dense set is itself
dense in $C[\,a,b\,]$.  

Our goal in this section is to prove an analogue
of this new version of the Weierstrass theorem for
subalgebras of $C(X)$, where $X$ is a compact metric
space.
In particular, we will want to extract the essence
of the functions $1$ and $x$ from this statement.
That is, we seek conditions on a subalgebra $A$
of $C(X)$ that will force $A$ to be dense in $C(X)$.  
The key role played by $1$ and $x$, in the case of $C[\,a,b\,]$, 
is that a subalgebra containing these two functions
must actually contain a much larger set of functions.
But since we can't be assured of anything remotely like
polynomials living in the more general $C(X)$ spaces,
we might want to change our point of view. What we
really need is some requirement on a subalgebra $A$
of $C(X)$ that will allow us to {\sl construct\/}
a wide variety of functions in $A$.  And, if $A$
contains a sufficiently rich variety of functions, 
it might just be possible to show that $A$ is dense.

Since the two replacement conditions we have in mind
make sense in any collection of real-valued functions,
we state them in some generality.  

Let $A$ be a 
collection of real-valued functions on some set $X$.
We say that $A$ {\sl separates points in\/}
$X$ if, given $x\ne y\in X$, there is some $f\in A$ such
that $f(x)\ne f(y)$.  We say that $A$ 
{\sl vanishes at no point of\/}
$X$ if, given $x\in X$, there is some $f\in A$ such 
that $f(x)\ne0$. 

\noindent
{\bf Examples}

\item{\bf 6.}{%
The single function $f(x)=x$ clearly separates points in $[\,a,b\,]$,
and the function $e(x)=1$ obviously vanishes at no point in
$[\,a,b\,]$.  Any subalgebra $A$ of $C[\,a,b\,]$ containing these
two functions will likewise separate points and vanish at no
point in $[\,a,b\,]$.
}

\item{\bf 7.}{%
The set $E$ of even functions in $C[-1,1\,]$ fails to separate 
points in $[-1,1\,]$;  indeed, $f(x)=f(-x)$ for any even function. 
However, since the constant functions are even, $E$ vanishes at 
no point of $[-1,1\,]$.  It's not hard to see that 
$E$ is a proper closed subalgebra of $C[-1,1\,]$.  The set of odd
functions will separate points (since $f(x)=x$ is odd), but the 
odd functions all vanish at $0$.  The set of odd functions is 
a proper closed subspace of $C[-1,1\,]$, although not a subalgebra.
}

\item{\bf 8.}{%
The set of all functions $f\in C[-1,1\,]$ for which $f(0)=0$
is a proper closed subalgebra of $C[-1,1\,]$.  In fact, this 
set is a maximal (in the sense of containment) proper closed
subalgebra of $C[-1,1\,]$.  Note,
however, that this set of functions does separate points in
$[-1,1\,]$ (again, because it contains $f(x)=x$).
}

\item{\bf 9.}{%
It's easy to construct examples of non-trivial closed subalgebras 
of $C(X)$.  Indeed, given any closed subset $X_0$ of $X$, the
set $A(X_0)=\{f\in C(X):f \ \hbox{vanishes on} \ X_0\}$ is 
a non-empty, proper subalgebra of $C(X)$.  It's closed in any 
reasonable topology on $C(X)$ because it's closed under pointwise 
limits.  Subalgebras of the type $A(X_0)$ are of interest because 
they're actually {\sl ideals\/} in the ring $C(X)$.  That is, if
$f\in C(X)$, and if $g\in A(X_0)$, then $fg\in A(X_0)$.
}

As these few examples illustrate, neither of our new conditions,
taken separately, is enough to force a subalgebra
of $C(X)$ to be dense.  But both conditions together turn out to
be sufficient.  In order to better appreciate the utility of
these new conditions, let's isolate the key computational tool
that they permit within an algebra of functions.

\proclaim Lemma.
Let $A$ be an algebra of real-valued functions on some set $X$,
and suppose that $A$ separates points in $X$ and vanishes at
no point of $X$.  Then, given $x\ne y\in X$ and $a$, $b\in\R$,
we can find an $f\in A$ with $f(x)=a$ and $f(y)=b$.

\proof
Given any pair of distinct
points $x\ne y\in X$, the set 
$\widetilde A=\{\bigl(f(x),f(y)\bigr):f\in A\}$
is a subalgebra of $\R^2$.    
If $A$ separates points in $X$, then $\widetilde A$ 
is evidently neither
$\{(0,0)\}$ nor $\{(x,x):x\in\R\}$.  If $A$ vanishes at no point,
then $\{(x,0):x\in\R\}$ and $\{(0,y):y\in\R\}$ are both excluded.
Thus $\widetilde A=\R^2$.  That is, for any
$a$, $b\in\R$, there is some $f\in A$ for which
$(f(x),f(y))=(a,b)$.~\qed

Now we can state Stone's version of the Weierstrass theorem
(for compact metric spaces).
It should be pointed out that the theorem, as stated, also
holds in $C(X)$ when $X$ is a compact Hausdorff topological 
space (with the same proof), but 
does not hold for algebras of complex-valued functions over $\C$.
More on this later.

\proclaim Stone-Weierstrass Theorem. {\rm(real scalars)} \ 
Let $X$ be a compact metric space, and let $A$ be a subalgebra
of $C(X)$.  If $A$ separates points in $X$ and vanishes at no
point of $X$, then $A$ is dense in $C(X)$.

What Cheney calls an ``embryonic'' version of this theorem
appeared in 1937, as a small part of a massive 106 page paper!
Later versions, appearing in 1948 and 1962, benefitted from
the work of the great Japanese mathematician Kakutani and 
were somewhat more palatable to the general mathematical public.  
But, no matter which version you consult, you'll find them
difficult to read.  For more details, I would recommend you 
first consult Folland's {\it Real Analysis}, or Simmons's 
{\it Topology and Modern Analysis}.

As a first step in attacking the proof of Stone's theorem, 
notice that
if $A$ satisfies the conditions of the theorem, then
so does its closure $\,\overline{\!A}$. (Why?)  Thus,
we may assume that $A$ is actually a {\sl closed\/}
subalgebra of $C(X)$ and prove, instead, that $A=C(X)$.
Now the closed subalgebras of $C(X)$ inherit more 
structure than you might first imagine.  

\proclaim Theorem.
If $A$ is a subalgebra of $C(X)$, and if $f\in A$,
then $|f|\in\,\overline{\!A}$.  Consequently,
$\,\overline{\!A}$ is a sublattice of $C(X)$.

\proof
Let $\eps>0$, and consider the function $|t|$ on the interval 
$\bigl[-\Vert f\Vert,\Vert f\Vert\,\bigr]$.  By the Weierstrass 
theorem, there is a polynomial $p(t)=\sum_{k=0}^na_kt^k$ such that 
$\bigl|\,|t|-p(t)\,\bigr|<\eps$ for all $|t|\le\Vert f\Vert$. 
In particular, notice that $|p(0)|=|a_0|<\eps$.  

Now, since $|f(x)|\le\Vert f\Vert$ for all $x\in X$, it follows that 
$\bigl|\,|f(x)|-p(f(x))\,\bigr|<\eps$ for all $x\in X$.  But 
$p(f(x))=(p(f))(x)$, where $p(f)=a_0{\bf 1}+a_1f+\cdots+a_nf^n$,
and the function $g=a_1f+\cdots+a_nf^n\in A$, since $A$ is an algebra.
Thus, $\bigl|\,|f(x)|-g(x)\,\bigr|\le|a_0|+\eps<2\eps$ for all
$x\in X$.  In other words, for each $\eps>0$, we can supply an
element $g\in A$ such that $\Vert\,|f|-g\Vert<2\eps$.
That is, $|f|\in\,\overline{\!A}$.

The statement that $\,\overline{\!A}$ is a sublattice of $C(X)$
means that if we're given $f$, $g\in\,\overline{\!A}$, then 
$\max\{f,g\}\in\,\overline{\!A}$ and $\min\{f,g\}\in\,\overline{\!A}$,
too.  But this is actually just a statement about real numbers.
Indeed, since
$$2\max\{a,b\}=a+b+|a-b|\qquad\hbox{and}\qquad
	2\min\{a,b\}=a+b-|a-b|$$
it follows that a {\sl subspace\/} of $C(X)$ is a sublattice
precisely when it contains the absolute values of all its 
elements.~\qed

The point to our last result is that if we're given a closed 
subalgebra $A$ of $C(X)$, then $A$ is ``closed'' in every sense 
of the word: Sums, products, absolute values, max's, and min's of
elements from $A$, and even limits of sequences of these, are 
all back in $A$.  This is precisely the sort of freedom we'll
need if we hope to show that $A=C(X)$.

Please notice that we could have avoided our appeal to the
Weierstrass theorem in this last result.  Indeed, we really 
only need to supply polynomial approximations for the single 
function $|x|$ on $[-1,1\,]$, and this can be done directly.
For example, we could appeal instead to the binomial theorem,
using $|x|=\sqrt{1-(1-x^2)}$; the resulting series
can be shown to converge uniformly on $[-1,1\,]$.  By 
side-stepping the classical Weierstrass theorem, it becomes 
a corollary to Stone's version (rather than the other way around).  

Now we're ready for the proof of the Stone-Weierstrass
theorem.  As we've already pointed out, we may assume that
we're given a closed subalgebra (subspace, and sublattice) 
$A$ of $C(X)$ and we want to show that $A=C(X)$.  
We'll break the remainder of the proof into two steps:

{\noindent\hangindent=50 true pt\hangafter=1%
\underbar{Step 1}: \ Given $f\in C(X)$, $x\in X$, and $\eps>0$,
there is an element $g_x\in A$ with $g_x(x)=f(x)$ and 
$g_x(y)>f(y)-\eps$ for all $y\in X$.\par}

\smallskip

From our ``computational'' Lemma, we know that for
each $y\in X$, $y\ne x$, we can find an $h_y\in A$ so that 
$h_y(x)=f(x)$ and $h_y(y)=f(y)$.  
Since $h_y-f$ is continuous and vanishes at both
$x$ and $y$, the set $U_y=\{t\in X:h_y(t)>f(t)-\eps\}$ is open and
contains both $x$ and $y$.  Thus, the sets $(U_y)_{y\ne x}$ form
an open cover for $X$.  Since $X$ is compact, finitely many $U_y$'s
suffice, say $X=U_{y_1}\cup\cdots\cup U_{y_n}$.  Now set
$g_x=\max\{h_{y_1},\ldots,h_{y_n}\}$.  Because $A$ is a lattice,
we have $g_x\in A$.  Note that $g_x(x)=f(x)$ since each $h_{y_i}$ 
agrees with $f$ at $x$.  And $g_x>f-\eps$ since, given $y\ne x$, 
we have $y\in U_{y_i}$ for some $i$, and hence 
$g_x(y)\ge h_{y_i}(y)>f(y)-\eps$. 

\smallskip

\noindent
\underbar{Step 2}: \ Given $f\in C(X)$ and $\eps>0$, there is
an $h\in A$ with $\Vert f-h\Vert<\eps$.  

\smallskip

From Step~1, for each $x\in X$ we can find some $g_x\in A$ such
that $g_x(x)=f(x)$ and $g_x(y)>f(y)-\eps$ for all $y\in X$.
And now we reverse the process used in Step~1:  For each
$x$, the set $V_x=\{y\in X:g_x(y)<f(y)+\eps\}$ is open and
contains $x$.  Again, since $X$ is compact, 
$X=V_{x_1}\cup\cdots V_{x_m}$ for some $x_1,\ldots,x_m$.  
This time, set $h=\min\{g_{x_1},\ldots,g_{x_m}\}\in A$. 
As before,
$h(y)>f(y)-\eps$ for all $y$, since each $g_{x_i}$ does so,
and $h(y)<f(y)+\eps$ for all $y$, since at least one $g_{x_i}$
does so.

The conclusion of Step~2 is that $A$ is dense in $C(X)$;
but, since $A$ is closed, this means that $A=C(X)$.~\qed

\proclaim Corollary.
If $X$ and $Y$ are compact metric spaces, then the 
subspace of $C(X\times Y)$ spanned by the functions of
the form $f(x,y)=g(x)\,h(y)$, $g\in C(X)$, $h\in C(Y)$,
is dense in $C(X\times Y)$.

\proclaim Corollary.
If $K$ is a compact subset of\/ $\R^n$, then the 
polynomials {\rm(}in $n$-variables\/{\rm)} 
are dense in $C(K)$.

\noindent
{\bf Applications to $C^{2\pi}$}

\noindent
In many texts, the Stone-Weierstrass theorem is used to 
show that the trig polynomials are dense in $C^{2\pi}$.
One approach here might be to identify $C^{2\pi}$ with
the closed subalgebra of $C[\,0,2\pi\,]$ consisting of
those functions $f$ satisfying $f(0)=f(2\pi)$.  Probably
easier, though, is to identify $C^{2\pi}$ with the 
continuous functions on the unit circle 
${\T}=\{e^{i\theta}:\theta\in\R\}=\{z\in \C:|z|=1\}$
in the complex plane using the identification
$$f\in C^{2\pi} \quad \longleftrightarrow \quad 
	g\in C({\T}), \  \hbox{ where } \ g(e^{it})=f(t).$$
Under this correspondence, the trig polynomials in $C^{2\pi}$
match up with (certain) polynomials in $z=e^{it}$ and 
$\overline{z}=e^{-it}$.  But, as we've seen,
even if we start with real-valued trig polynomials, we'll
end up with polynomials in $z$ and $\overline{z}$ having
complex coefficients. 

Given this, it might make more sense
to consider the complex-valued continuous functions on 
${\T}$.  We'll write $C_\C({\T})$ to denote the 
complex-valued continuous functions on ${\T}$, and
$C_\R({\T})$ to denote the real-valued continuous 
functions on ${\T}$.  Similarly, $C^{2\pi}_\C$ is the
space of complex-valued, $2\pi$-periodic functions on $\R$,
while $C^{2\pi}_\R$ stands for the real-valued, $2\pi$-periodic
functions on $\R$.  Now, under the identification we made
earlier, we have $C_\C({\T})=C^{2\pi}_\C$ and 
$C_\R({\T})=C^{2\pi}_\R$.  The complex-valued trig
polynomials in $C^{2\pi}_\C$ now match up with the full
set of polynomials, with complex coefficients, in $z=e^{it}$
and $\overline{z}=e^{-it}$.  We'll use the Stone-Weierstrass
theorem to show that these polynomials are dense in $C_\C({\T})$.

Now the polynomials in $z$ obviously separate points in ${\T}$
and vanish at no point of ${\T}$. Nevertheless, the polynomials
in $z$ alone are not dense in $C_\C({\T})$.  
To see this, here's a proof that $f(z)=\overline{z}$ cannot be 
uniformly approximated by polynomials in $z$.  First, suppose
that we're given some polynomial $p(z)=\sum_{k=0}^n c_kz^k$. 
Then,  
$$\int_0^{2\pi} \overline{f(e^{it})}\,p(e^{it})\,dt 
	\ = \ \int_0^{2\pi} e^{it}\,p(e^{it})\,dt
	\ = \ \sum_{k=0}^nc_k\int_0^{2\pi} e^{i(k+1)t}\,dt \ = \ 0,$$
and so
$$2\pi \ = \ \int_0^{2\pi} \overline{f(e^{it})}\,f(e^{it})\,dt \ 
= \ \int_0^{2\pi} \overline{f(e^{it})}\,\bigl[f(e^{it})-p(e^{it})\bigr]\,dt,$$
because $\overline{f(z)}\,f(z)=|f(z)|^2=1$.  
Now, taking absolute values, we get
$$2\pi \ \le \ \int_0^{2\pi} \bigl|f(e^{it})-p(e^{it})\bigr|\,dt \ 
	\le \ 2\pi\Vert f-p\Vert.$$
That is, $\Vert f-p\Vert\ge 1$ for any polynomial $p$.

We might as well proceed in some generality: Given a compact
metric space $X$, we'll write $C_\C(X)$ for the set of all
continuous, complex-valued functions $f:X\to\C$, and we norm
$C_\C(X)$ by $\Vert f\Vert = \Max_{x\in X}|f(x)|$ 
(where $|f(x)|$ is the modulus of the complex number $f(x)$,
of course).  $C_\C(X)$ is a Banach algebra over $\C$.
In order to make it clear
which field of scalars is involved, we'll write $C_\R(X)$ for 
the real-valued members of $C_\C(X)$.  Notice, though, that
$C_\R(X)$ is nothing other than $C(X)$ with a
new name.

More generally, we'll write $A_\C$ to denote an
algebra, over $\C$, of complex-valued functions and $A_\R$ to
denote the real-valued members of $A_\C$.  It's not hard to
see that $A_\R$ is then an algebra, over $\R$, of real-valued
functions.  

Now if $f$ is in $C_\C(X)$, then so is the function
$\,\overline{\!f}(x)=\overline{f(x)}$ (the complex-conjugate 
of $f(x)$\/).  This puts
$${\rm Re} f = {1\over2}\bigl(f+\,\overline{\!f}\,\bigr)
	 \quad \hbox{ and } \quad
{\rm Im} f = {1\over{2i}}\bigl(f-\,\overline{\!f}\,\bigr),$$
the real and imaginary parts of $f$, in $C_\R(X)$ too.  
Conversely, if $g$, $h\in C_\R(X)$, then $g+ih\in C_\C(X)$.

This simple observation gives us a hint as to how we might
apply the Stone-Weierstrass theorem to subalgebras of $C_\C(X)$.  
Given a subalgebra $A_\C$ of $C_\C(X)$, suppose that we could 
prove that $A_\R$ is dense in $C_\R(X)$.  Then, given any 
$f\in C_\C(X)$, we could approximate ${\rm Re} f$ and ${\rm Im} f$
by elements $g$, $h\in A_\R$.  But since $A_\R\subset A_\C$, 
this means that $g+ih\in A_\C$, and $g+ih$ approximates $f$.
That is, $A_\C$ is dense in $C_\C(X)$.  Great!  And what did
we really use here?  Well, we need $A_\R$ to contain the real
and imaginary parts of ``most'' functions in $C_\C(X)$.  
If we insist that $A_\C$ separate points and vanish at no point,
then $A_\R$ will contain ``most'' of $C_\R(X)$.  
And, to be sure that we get both the
real and imaginary parts of each element of $A_\C$, we'll insist 
that $A_\C$ contain the conjugates of each of its members:
$\,\overline{\!f}\in A_\C$ whenever $f\in A_\C$.  That is, we'll
require that $A_\C$ be {\sl self-conjugate\/}
(or, as some authors say, {\sl self-adjoint\/}). 

\proclaim Stone-Weierstrass Theorem. {\rm(complex scalars)} \ 
Let $X$ be a compact metric space, and let $A_\C$ be a
subalgebra, over $\C$, of $C_\C(X)$.  If $A_\C$ separates
points in $X$, vanishes at no point of $X$, and is
self-conjugate, then $A_\C$ is dense in $C_\C(X)$.

\proof
Again, write $A_\R$ for the set of real-valued members of $A_\C$. 
Since $A_\C$ is self-conjugate, $A_\R$ contains the real and
imaginary parts of every  $f\in A_\C$;
$${\rm Re} f = {1\over2}\bigl(f+\,\overline{\!f}\,\bigr)\in A_\R
	 \quad \hbox{ and } \quad
{\rm Im} f = {1\over{2i}}\bigl(f-\,\overline{\!f}\,\bigr)\in A_\R.$$
Moreover, $A_\R$ is a subalgebra, over $\R$, of $C_\R(X)$.
In addition, $A_\R$ separates points in $X$ and vanishes at
no point of $X$.  Indeed, given $x\ne y\in X$ and $f\in A_\C$
with $f(x)\ne f(y)$, we must have at least one of 
${\rm Re}f(x)\ne {\rm Re}f(y)$ or ${\rm Im}f(x)\ne {\rm Im}f(y)$.
Similarly, $f(x)\ne 0$ means that at least one of ${\rm Re}f(x)\ne 0$
or ${\rm Im}f(x)\ne 0$ holds.  That is, $A_\R$ satisfies the
hypotheses of the real-scalar version of the Stone-Weierstrass
theorem.  Consequently, $A_\R$ is dense in $C_\R(X)$.

Now, given $f\in C_\C(X)$ and $\eps>0$, take $g$, $h\in A_\R$ with
$\Vert g-{\rm Re}f\Vert<\eps/2$ and 
$\Vert h-{\rm Im}f\Vert<\eps/2$.  Then, $g+ih\in A_\C$
and $\Vert f-(g+ih)\Vert<\eps$.  Thus, $A_\C$ is
dense in $C_\C(X)$.~\qed

\proclaim Corollary.
The polynomials, with complex coefficients, in $z$
and $\overline{z}$ are dense in $C_\C({\T})$.
In other words, the complex trig polynomials are
dense in $C_\C^{2\pi}$.

Note that it follows from the complex-scalar proof
that the real parts of the polynomials in 
$z$ and $\overline{z}$,
that is, the real trig polynomials, 
are dense in $C_\R({\T})=C^{2\pi}_\R$. 

\proclaim Corollary.
The real trig polynomials are dense in $C^{2\pi}_\R$.

\noindent
{\bf Application: Lipschitz Functions}

\noindent
In most Real Analysis courses, the classical Weierstrass 
theorem is used to prove that
$C[\,a,b\,]$ is separable.  Likewise, the Stone-Weierstrass
theorem can be used to show that $C(X)$ is separable,
where $X$ is a compact metric space.  While we won't
have anything quite so convenient as polynomials at our
disposal, we do, at least, have a familiar collection of 
functions to work with.  

Given a metric space $(X,d\,)$, and $0\le K<\infty$,
we'll write ${\rm lip}_K(X)$
to denote the collection of all real-valued
Lipschitz functions on $X$ with constant at most $K$;  
that is, $f:X\to\R$ is in ${\rm lip}_K(X)$ if 
$|f(x)-f(y)|\le Kd(x,y)$ for all $x$,~$y\in X$.
And we'll write ${\rm lip}(X)$ to denote the set of
functions that are in ${\rm lip}_K(X)$ for some $K$;
in other words, 
${\rm lip}(X)=\bigcup_{K=1}^\infty{\rm lip}_K(X)$.
It's easy to see that ${\rm lip}(X)$ is a subspace
of $C(X)$; in fact, if $X$ is compact, then ${\rm lip}(X)$ 
is even a subalgebra of $C(X)$.  Indeed, given  
$f\in{\rm lip}_K(X)$ and $g\in{\rm lip}_M(X)$, we have
$$\eqalign{
|f(x)g(x)-f(y)g(y)| \ &\le \ |f(x)g(x)-f(y)g(x)| + |f(y)g(x)-f(y)g(y)|\cr
	&\le \ K\Vert g\Vert\,|x-y| + M\Vert f\Vert\,|x-y|.\cr
}$$

\proclaim Lemma.
If $X$ is a compact metric space, then ${\rm lip}(X)$ is dense in $C(X)$.

\proof
Clearly, ${\rm lip}(X)$ contains the constant functions
and so vanishes at no point of $X$.
To see that ${\rm lip}(X)$ separates point in $X$,
we use the fact that the metric $d$ is Lipschitz:  Given
$x_0\ne y_0\in X$, the function $f(x)=d(x,y_0)$ satisfies
$f(x_0)>0=f(y_0)$; moreover, $f\in{\rm lip}_1(X)$ since
$$|f(x)-f(y)| \ = \ |d(x,y_0)-d(y,y_0)| \ \le \ d(x,y).$$
Thus, by the Stone-Weierstrass Theorem, ${\rm lip}(X)$ 
is dense in $C(X)$.~\qed 

\proclaim Theorem.
If $X$ is a compact metric space, then $C(X)$ is separable.

\proof
It suffices to show that ${\rm lip}(X)$ is separable. (Why?)
To see this, first notice that 
${\rm lip}(X)=\bigcup_{K=1}^\infty E_K$, where
$$E_K=\{f\in C(X):\Vert f\Vert\le K \ \hbox{and} \ 
	f\in {\rm lip}_K(X)\}.$$
(Why?)  The sets $E_K$ are (uniformly) bounded and equicontinuous.
Hence, by the Arzel\`a-Ascoli theorem, each $E_K$ is compact
in $C(X)$.  Since compact sets are separable, as are countable
unions of compact sets, it follows that ${\rm lip}(X)$ is 
separable.~\qed

As it happens, the converse is also true (which is why this
is interesting); see Folland's {\it Real Analysis\/} for
more details.

\proclaim Theorem.
If\/ $C(X)$ is separable, where $X$ is a compact Hausdorff 
topological space, then $X$ is metrizable.



\bye


%%  end of chapter-12.tex


