TITLE: How to build a smooth "transition function" explicitly?
QUESTION [19 upvotes]: It is easily shown that the function $$\begin{cases} \exp \left(\frac{1}{x^2-1} \right) & |x| < 1 \\ 0 & \text{otherwise} \\ \end{cases}$$
is smooth and has compact support in $\mathbb R$. I tried playing with it to find a function with the following properties:
a. $f(x)=0$ for $x \le 0$
b. $f(x)=1$ for $x \ge 1$
c. $f$ is monotonically increasing.
d. $f$ is smooth.
Is it possible to find an explicit formula for such $f$?

REPLY [5 votes]: I've found this other explicit construction of a transition function (I believe it's from Spivak's Calculus on Manifolds).

Let $$g(x)=\begin{cases} \exp \left( \frac{1}{x^2-1} \right) & |x|<1 \\ 0 & |x| \geq 1 \end{cases}$$
and let $A:=\int_{-\infty}^\infty g(x) \mathrm{d}x$.
The function $$f(x):=\frac{1}{A} \int_{-\infty}^x g(t) \mathrm{d} t$$ satisfies the requirements (up to a simple change of variables of the form $x \mapsto ax+b)$.