One-point compactification and embedding in a cube I am currently reading Folland's Real Analysis. On page 145 of his book, he claims the following:

Claim: If $X$ is a noncompact, locally compact Hausdorff space, then the closure of the image of the embedding $e:X\hookrightarrow I^\mathcal F$ associated to $\mathcal F=C_c(X)\cap C(X,I)$ is the one-point compactification of $X$.

A few remarks:


*

*The "associated embedding" refers to the map $X\to I^\mathcal F$ obtained by mapping $X\ni x\mapsto \hat x\in I^{\mathcal F}$, where $\hat x$ is given by $\hat x(f)=f(x)$ for $f\in \mathcal F$. 

*$C_c(X)$ is the set of all continuous, compactly supported, complex valued functions on $X$.

*$C(X,I)$ is the set of all continuous functions from $X$ to $I=[0,1]$.


I understand that this is indeed an embedding, because Urysohn's lemma guarantees that $\mathcal F$ separates points and closed sets and we know Theorem 1 below. I also understand that $\overline{e(X)}\setminus  X$ contains at least one point because $\overline {e(X)}$ is a compact space containing the noncompact subspace $X$. What I do not understand is that why $\overline {e(x)}\setminus X$ consists of precisely one point.
I managed to prove the above claim. (See below. Any comment on the proof is welcome.) But it's a bit lengthy. Folland states the above claim as if it's very trivial, so I must be missing something. Can someone help me? Thanks in advance.

Theorem 1: Let $X$ be a completely regular space, and suppose that $\mathcal F\subset C(X,I)$ is a collection that separates points and closed sets (that is, if $E\subset X$ is a closed set and $x\in X\setminus E$, then there is some $f\in \mathcal F$ such that $f(x)\not\in \overline{f(E)}$). Then the map $X\hookrightarrow I^{\mathcal F}$ defined as above is an embedding.

My attempt: 
I first proved the following:

Lemma 1: Let $X$ be a completely regular space, let $Y$ be a compact
  Hausdorff space, and let $\phi\in C(X,Y)$. Suppose that $\mathcal{F}\subset C(X,I)$ separates
  points and closed sets, and the collection
  $\mathcal{G}=(\phi^{*})^{-1}(\mathcal{F})\subset C(Y,I)$ also
  separates points and closed sets. Then $\phi$ has a
  unique continuous extension $\tilde{\phi}:\hat{X}\to Y$, where $\hat{X}$ is the compactification of $X$ associated to $\mathcal F$. If $\phi$
  is a compactification of $X$, then $\tilde{\phi}$ is a quotient map.

Here $\phi^*$ is the pullback $\phi^*(g)=g\circ \phi$.
(Proof of Lemma 1.)The map $\phi:X\to Y$ defines the pullback $\phi^{*}:\mathcal{G}\to\mathcal{F}$
given by $\phi^{*}(g)=g\circ\phi$, and then $\phi^{*}$ defines the
pullback $\Phi=\phi^{**}:I^{\mathcal{F}}\to I^{\mathcal{G}}$ given
by $\Phi(F)=F\circ\phi^{*}$. It is easy to check that the diagram
$$\require{AMScd}
\begin{CD}
X@>>>  I^{\mathcal F} \\
@VV\phi V & @V\Phi VV\\
Y@>>> I^{\mathcal G}
\end{CD}
$$commutes. (The horizontal maps are the embeddings.) For each $g\in\mathcal{G}$, the corresponding coordinate
function of $\Phi$ is given by $\pi_{g}\circ\Phi=\pi_{g\circ\phi}:I^{\mathcal{F}}\to I$.
Because $\pi_{g\circ\phi}$ just a projection, it follows that $\pi_{g}\circ\Phi$
is continuous. Therefore $\Phi$ is continuous.
Now by the closed map lemma, $Y$ is closed in $I^{\mathcal{G}}$,
so $Y=\overline{Y}$. Thus we have $\Phi(\hat{X})=\overline{\Phi(X)}\subset Y$,
where the equality follows again from the closed map lemma. So $\Phi$
restricts to a map $\tilde{\phi}:\overline{X}\to Y$ which extends
$\phi$. Because $X$ is dense in $\hat{X}$ and $Y$ is Hausdorff,
this is a unique extension. If $\phi$ is a compactification of $X$,
then $\overline{\Phi(X)}=Y$ , so $\tilde{\phi}$ is surjective and
hence is a quotient map by the closed map lemma.
 $\blacksquare $

Lemma 2:In the situation of lemma 1, if every function $f\in\mathcal{F}$ has a
  continuous extension to $Y$, then $\tilde{\phi}:\hat{X}\to Y$
  is a homeomorphism.

(Proof.) In view of the preceding proposition, it suffices to show that $\tilde{\phi}$
is injective. So suppose that $F,F'\in\hat{X}$ are distinct elements
of $\hat{X}$. Then there is some $f\in\mathcal{F}$ such that
$F(f)\neq F'(f)$. If $g:Y\to I$ denotes the continuous extension
of $f$, then $\tilde{\phi}(F)(g)=F(g\circ\phi)=F(f)$, and similarly,
$\tilde{\phi}(F')(g)=F'(f)$. Therefore $\tilde{\phi}(F)\neq\tilde{\phi}(F')$,
proving that $\tilde{\phi}$ is injective. $\blacksquare$
Now we can prove our claim. Suppose $X$ is a locally compact Hausdorff space, and let $\phi:X\to X^{*}=X\cup {\infty}$
be the one-point compactification of $X$. By the Urysohn's lemma,
the collection $\mathcal{F}=C_{c}(X,I)\cap C(X)$ separates points
and closed sets. The collection $\mathcal{G}=(\phi^{*})^{-1}(\mathcal{F})$
consists of continuous functions $g:X^{*}\to I$ with $\operatorname{supp}_{g}\subset X$.
Because $X^{*}$ is normal, given a point $x\in X^{*}$ and a closed
set $A\subset X^{*}$ disjoint from $X$, there exists a closed set
$B\subset X^{*}$ containing a neighborhood of $x$, and then the
Urysohn's lemma shows that there is some $g\in\mathcal{G}$ that is
equal to 0 on $A$ and $1$ on $B$. So $\mathcal{G}$ separates points
and closed sets. Moreover, any function in $\mathcal{F}$ extends
continuously to $X^{*}$ (by declaring ). Thus by above lemmas, $\hat{X}$ is homeomorphic to $X^{*}$.
 A: Your proof is correct, although you should explicitly define $\hat X$ is and restate lemma 1 as

Lemma 1: Let $X$ be a completely regular space, and let $Y$ be a compact
  Hausdorff space. Suppose that $\mathcal{F}\subset C(X,I)$ separates
  points and closed sets. Then any $\phi\in C(X,Y)$ such that the collection
  $\mathcal{G}=(\phi^{*})^{-1}(\mathcal{F})\subset C(Y,I)$ also
  separates points and closed sets, has a
  unique continuous extension $\tilde{\phi}:\hat{X}\to Y$. If $\phi$
  is a compactification of $X$, then $\tilde{\phi}$ is a quotient map.

However, your approach is too complicated. Let $X^+$ denote the one-point compactification of $X$ and write $X^+ \setminus X = \{\infty\}$. Then each $f \in C_c(X)$ has a (trivally unique) extension $f^+ : X^+ \to \mathbb C$ (take $f^+(\infty) = 0$). Clearly if $f \in C(X,I)$, then $f^+ \in C(X^+,I)$. Let $j : \mathcal F \to  C(X^+,I), j(f) = f^+$. If $i : X \to X^+$ denotes inclusion, then the diagram
$$\require{AMScd}
\begin{CD}
X@> \epsilon >>  I^{\mathcal F} \\
@VVi V @AA j^*A \\
X^+@>>\epsilon^+ > I^{\mathcal C(X^+,I)}
\end{CD}
$$
commutes because for $x \in X$ and $f \in \mathcal F$ we have
$$\big(j^*(\epsilon^+(i(x)))\big)(f) = \big(\epsilon^+(i(x))j\big)(f) = \epsilon^+(i(x))(j(f)) = \epsilon^+(i(x))(f^+) = f^+(i(x)) = f(x) =\epsilon(x)(f) .$$
$X' = (j^*\epsilon^+)(X^+)$ is compact, thus $\overline{\epsilon (X)} \subset X'$. But $X' = (j^*\epsilon^+)(X^+) = (j^*\epsilon^+)(X \cup \{\infty\}) = \epsilon(X) \cup \{ (j^*\epsilon^+)(\infty) \}$.
A: Simply use the fact mentioned in the preceding sentence (on p.145): Y consists of e(X) together with the single point of $I^{\mathcal{F}}$ all of whose coordinates are zero.
To prove the aforementioned fact, just observe that if $y \in Y \setminus e(X)$, then $y \notin K$ for all compact subsets $K \subseteq e(X)$.
