Does having a codimension-1 embedding of a closed manifold $M^n \subset \mathbb{R}^{n+1}$ require $M$ to be orientable? I'm trying to follow a proof about immersing/embedding $\mathbb{RP}^n$ into $\mathbb{R}^{n+1}$, which goes roughly as follows:
Write $\tau=T\mathbb{RP}^n$.  The normal bundle $\nu$ has rank 1, so its Steifel-Whitney class is $w(\nu)=1$ or $w(\nu)=1+x$.  In every case, we need $w(\nu)\cdot w(\tau) = w(\nu \oplus \tau) = w(\epsilon^{n+1})=1$.  If $w(\nu)=1$, then $w(\tau)=(1+x)^{n+1}=1$, so $n+1=2^r$.  If $w(\nu)=1+x$, then similarly $(1+x)^{n+2}=1$ so $n+2=2^r$.  If the immersion is an embedding, the former case must hold.
Why is this true?  I feel like there should be an easy reason, but none of the people I talked with were able to nail down anything precise.  This could be wrong, but it seems like this is tacitly saying that a codimension-1 embedding of a closed manifold must be in fact of an orientable manifold, which is the same as saying that the the normal line bundle has trivial $w_1$ (since line bundles are totally classified by their orientability, i.e. by $w_1$).  Is this true?
 A: Any compact, connected manifold $M$ of dimension $n$ embedded in $\mathbb{R}^{n+1}$ is orientable.
This follows from the fact that there exists a smooth function $f$ on $\mathbb{R}^{n+1}$ s.t. $M$ is the zero locus of $f$ and the derivative of $f$ does not vanish on $M$ (so the gradient of $f$ gives a smooth normal vector field).
This also proves Jordan-Brouwer's theorem ($M$ cuts $\mathbb{R}^{n+1}$ in two parts: $f>0$ and $f<0$).
The existence of $f$ is a "technical lemma" ;)
First, using compactness, you can show that there is an $\epsilon > 0$ and a covering $\left( V_x \right)_{x \in M}$ of $M$ such that $B=\left\{ y \in \mathbb{R}^{n+1}\ |\ d(y,M) \lt \epsilon \right\}$ is the disjoint union of the $\left\{ x + t n_x \ |\ -\epsilon \lt t \lt \epsilon \right\}$ ($n_x$ being a vector of norm one orthogonal to $T_x M$), and so $B$ is locally $V_x \times ]-\epsilon,\epsilon[$.
From there you can deduce that $\mathbb{R^{n+1}}$ has an open covering $\left(A_i\right)_i$ with smooth functions $f_i$ on $A_i$ s.t. whenever $A_i \cap A_j \neq \emptyset$, $f_i = \pm f_j$ locally on $A_i \cap A_j$, and $\cup_i f_i^{-1}(0) = M$ has empty interior (for this you need to take a smooth  non-decreasing function $\lambda : \mathbb{R} \rightarrow \mathbb{R}$ s.t. $f(x)=-1$ when $x \lt -\epsilon/2$, $f(x)=1$ when $x \gt \epsilon/2$, and $f$ is increasing inbetween. then for $(y,t) \in V_x \times ]-\epsilon,\epsilon[$, define $f_i(y,t)=\lambda(t)$, and take the $f_i$s to be $1$ outside the $\epsilon/2$-neighbourhood of $M$).
This, together with the simple connectedness of $\mathbb{R}^{n+1}$, gives a smooth function $f$ on $\mathbb{R}^{n+1}$ locally equal to the $\pm f_i$, and you are done.
Now you have a long exercise to solve your technical problem ;)
I'm sorry I couldn't just give you a reference, but the only one I have (and from which I took the above sketch of proof) is a french book: Thèmes d'analyse pour l'agrégation, Calcul différentiel by Stéphane Gonnord and Nicolas Tosel (p. 100).
EDIT: actually they give a reference: Elon L. Lima, The Jordan-Brouwer separation theorem for smooth hypersurfaces, American Mathematical Monthly, Volume 95 Issue 1, Jan. 1988
A: Here's a nice solution I just thought of, which may in fact be logically equivalent to Jim's (if it's even correct!).  I welcome comments addressing that.
Compactify $\mathbb{R}^{n+1}$ to $S^{n+1}$, so we consider $M \subset S^{n+1}$.  By Alexander duality, $$\tilde{H}_0(S^{n+1} \backslash M ; \mathbb{Z}/2) \cong \tilde{H}^{(n+1)-0-1}(M;\mathbb{Z}/2) = \tilde{H}^n(M;\mathbb{Z}/2)=\mathbb{Z}/2,$$ so $H_0(S^{n+1}\backslash M;\mathbb{Z}/2)=\mathbb{Z}/2 \oplus \mathbb{Z}/2$.  Hence $M$ separates $S^{n+1}$.
A: The normal bundle of a codimension 1 embedding of a compact closed manifold $M$ in $\mathbb R^{n+1}$ is indeed trivial. Otherwise, you could find a simple closed curve in $\mathbb R^{n+1}$ that intersects $M$ in a single point. This implies that both the curve and $M$ represent nontrivial mod $2$ homology classes in $\mathbb R^{n+1}$; this is because the intersection product is dual to the cup product and cannot be nonzero on trivial homology classes. However there are no nontrivial homology classes in $\mathbb R^{n+1}$ since it is contractible. So we get a contradiction.
Once the normal bundle is seen to be trivial, one can use the ambient orientation of $\mathbb R^{n+1}$ to locally orient the manifold, since there is a well defined positive normal direction.
