# Computable distribution on [0,1] with C-infinity distribution function

Does anyone know of an easily-describable distribution on $[0,1]$ with a density $p$ (with respect to Lebesgue measure) that satisfies the following properties:

1. $p$ is $C^\infty$
2. $p(0) = a$, $p(1) = b$ (for fixed real numbers $a$, $b$)
3. every derivative of $p$ at 0 and 1 is 0
4. p is computable (informally, we can compute $p$ at any point to arbitrary accuracy)
-
In particular, we are interested in the case where $a=2/3$ and $b=4/3$. We suspect that it should be possible to have a monotonically increasing density $p$ as well. – Nate Ackerman Jan 7 '11 at 16:18
This is easy to do with $C^\infty$ bump functions, cf. the wikipedia article en.wikipedia.org/wiki/Bump_function. It's easy to make them monotone, if $a < 1$ and $b > 1$, and you can guarantee the integral is 1 by symmetry if the average of $a$ and $b$ is 1 (as in your comment). Otherwise, integrate. – Bill Thurston Jan 7 '11 at 17:51
Thanks, that is exactly what we needed. – Nate Ackerman Jan 8 '11 at 23:01