Setting
f
=
cg
+
dgh
we have
f
∈ A
,
f
(
p
) =
a
,
f
(
q
) =
b
.
•
Step 2.
A
is an algebra. Same proof as in Stone Weierstrass. Left as a new exercise. I also leave as an exercise
(trivial one) that all functions of
¯
A
vanish on
Z
; it satisfies all the properties of
A
.
•
Step 3. If
f
∈ A
, then

f
 ∈
¯
A
. Let
f
∈ A
and let
² >
0 be given. Consider the function
φ
: [
k
f
k
,
k
f
k
] defined
by
φ
(
x
) =

x

. This function is continuous and satisfies
φ
(0) = 0; by Theorem 1 there exists a polynomial without
constant term
p
such that

p
(
x
)
 
x

< ²
for all
x
∈
[
k
f
k
,
k
f
k
]. Because
p
has no constant term,
p
◦
f
∈ A
and
we have

p
(
f
(
p
))
 
f
(
p
)

< ²
for all
p
∈
X
.
•
Step 4. If
f, g
∈ A
, then max(
f, g
), min(
f, g
)
∈
¯
A
. This is again the same as before:
max(
f, g
) =
1
2
(
f
+
g
+

f

g

)
,
min(
f, g
) =
1
2
(
f
+
g
 
f

g

)
.
•
Step 5. Assume now given
f
∈
C
(
X
),
f

Z
= 0, and
² >
0. To complete the proof we must show there exists
g
∈ A
,
or in
¯
A
, such that

f
(
p
)

g
(
p
)

< ²
for all
p
∈
X
.
Fix for a moment
p
∈
X
. For every
q
∈
X
let
h
pq
∈ A
be such that
h
pq
(
p
) =
f
(
p
),
h
pq
(
q
) =
f
(
q
). This can be done
by Step 1: If both
p, q
∈
Z
, any element of
A
will do. If only one of
p, q
∈
Z
, one only needs to match the value
of
f
at the point not in
Z
, the value at the point in
Z
, which is 0, being matched automatically. If neither
p, q
is
in
Z
, Step 1 applies directly. By continuity, there is an open set
V
pq
of
X
such that
q
∈
V
pq
and
h
pq
(
r
)
> f
(
r
)

²
for all
r
∈
V
pq
. The family
{
V
pq
}
q
∈
X
is an open covering of the compact space
X
, thus there exist
q
1
, . . . , q
n
∈
X
such that
X
=
S
n
j
=1
V
pq
j
. By Step 4 (and induction),
h
p
= max(
h
pq
1
, . . . , h
pq
n
)
is in
¯
A
and clearly satisfies:
h
p
(
p
) =
f
(
p
),
h
p
(
r
)
> f
(
r
)

²
for all
r
∈
X
.
•
Step 6. Time to move
p
. For each
p
∈
X
we have
h
p
∈
¯
sA
as above. By continuity, for every
p
∈
X
there is
an open set
W
p
such that
p
∈
W
p
and
h
p
(
r
)
< f
(
r
) +
²
for all
r
∈
W
p
.
As before we use compactness to get
W
p
1
, . . . , W
p
m
covering
X
. Then
g
= min(
h
p
1
, . . . , h
p
m
)
is in
¯
A
by Step 4 applied to the closed algebra
¯
A
rather than to
A
; this gives that
g
is in the closure of the closure
of
A
. But the closure of a closure is still just the closure. (If you close it once, and close it well, you don’t need
to close it anymore.) It is clear that
f
(
r
)

² < g
(
r
)
< f
(
r
) +
²
for all
r
∈
X
and we are done.
5. Let
f
(
x
) = cos
x
. Provide an explanation, based on fixed point theorems seen in class (or, equivalently, the proposition
on page 172 of Rosenlicht) of why starting with an
arbitrary
x
0
∈
R
, the sequence defined by
x
n
+1
=
f
(
x
n
) will
converge to the unique fixed point of cos. Notice that
f
0
(
x
) = sin
x
can equal 1.
Solution.
Wherever
x
0
∈
R
might be,
cosx
0
∈
[

1
,
1] and every further application of the cosine function results in
values in that interval. That is, we may start with
x
1
= cos
x
0
instead of
x
0
and then we consider cos as a map from
the complete metric space [

1
,
1] into itself. Now [

1
,
1]
⊂
(

π/
2
, π/
2) and sine increases from sin(

1) =

sin
1 to
sin
1 in that interval, thus for all
x
∈
[

1
,
1]

f
0
(
x
)

=

sin
x
 ≤
sin
1
<
1
.