From topology I know the Urysohn lemma.
My question is if there is some sort of Urysohn lemma for smooth manifolds.
To be more precise:
Let M be a smooth manifold and suppose $A$ and $B$ are two disjoint closed subsets of $M$.
Then there is a smooth function $f$ on $M$ so that $0 \leq f(x) \leq 1$ for all $x \in M$ and $f_{|A}=0$ and $f_{|B}=1$.
I am interested in the proof of this statement (or books where this is proven).
Best Answer
This is a classic application of partitions of unity (which you can look up in any decent textbook: e.g Spivak, Lee).
To prove this, consider the open cover $\{U,B^c\}$ of $M$. There is then a smooth partition of unity $\{f,g\}$ subordinate to the above open cover, i.e $f,g:M\to\Bbb{R}$ are $C^{\infty}$ functions, $\text{supp}(f)\subset U$ and $\text{supp}(g)\subset B^c$, and $f+g=1$ on all of $M$. Now, note that for any $x\in B$, we have $1=f(x)+g(x)=f(x)+0=f(x)$, since $\text{supp}(g)\subset B^c$. Thus, $f$ is identically $1$ on $B$ and has support contained in $U$.
Let $U:=A^c$; this is open since $A$ is closed, and it contains $B$ since $A,B$ are disjoint. Take $f$ from the above lemma; then $f|_B=1$ as desired, and $\text{supp}(f)\subset U=A^c$ implies that $f|_A=0$.
In fact, our conclusion of $\text{supp}(f)\subset A^c$ is stronger than simply having $f|_A=0$, so we actually get more in the process.