Tietze extension theorem in LCH spaces Let $X$ be a locally compact Hausdorff space and $K$ be a compact subset of $X$. Then any function $f\in C(K)$ can be extended to a function in $C(X)$ which vanishes outside a compact set. 
I have searched several books for the proof. It seems that the authors believe it is just an exercise-level proposition. Since $X$ is an LCH space, we can always find open set $V$ containing $K$ with compact closure $\overline{V}$ and we can extend $f$ to $\overline{V}$ by classical Tietze extension theorem. I also know the fact that $f\in C(K)$ implies that the the range of $f$ is contained in a closed interval $[a,b]$, but how do we define a $F \in C(X)$ satisfying the requirements?
 A: Extend $f$ to $\hat f:\operatorname{cl}V\to\Bbb R$ just as you’ve already done. If $V$ is clopen in $X$, let
$$f^*:X\to\Bbb R:x\mapsto\begin{cases}
\hat f(x),&\text{if }x\in V\\
0,&\text{otherwise}\;.
\end{cases}$$
Otherwise, apply Uryson’s lemma to the normal space $\operatorname{cl}V$ to get a continuous $g:\operatorname{cl}V\to[0,1]$ such that $g(x)=1$ for all $x\in K$, and $g(x)=0$ for all $x\in(\operatorname{cl}V)\setminus V$. Then define
$$f^*:X\to\Bbb R:x\mapsto\begin{cases}
g(x)\hat f(x),&\text{if }x\in\operatorname{cl}V\\
0,&\text{otherwise}\;.
\end{cases}$$
A: This can be done in few steps:


*

*First extend $f$ to $K\cup \partial V$, putting $0$ on $\partial V$.

*Then use Tietze to extend this to whole $\overline V$ (using the fact that it is compact Hausdorff, so normal).

*Finally put $0$ outside of $\overline V$, obtaining $\bar f\colon X\to {\bf R}$.


Check continuity by the definition (preimage of a closed set containing zero is the preimage by $\bar f$ restricted to $\overline V$ plus the entire $V^c$, while the preimage of any other closed set is just the preimage by $\bar f$ restricted to $\overline V$).
