TITLE: Ease-in-out function
QUESTION [15 upvotes]: I am trying to create a nice ease-in-out function that given values from 0 - 1 produces an output of 0 - 1 which accelerates slowly up to full speed then slows down again as it nears 1. 
I currently have a function using sine, in the form...
$$y = (\sin(πx/2))^2$$
This works ok, and gives me results in the range I require however it is too quick to reach the terminal velocity, I am looking for something which has a more gradual start / end and a steeper center (if that makes sense).
Any help would be appreciated!

REPLY [28 votes]: Something to try would be the parametrized function
$$
f_\alpha(x)=\frac{x^\alpha}{x^\alpha+(1-x)^\alpha}
$$
$f_1(x)=x$ and $f_2(x)$ looks like this
$\hspace{5cm}$
As $\alpha$ gets bigger, the slope in the middle becomes greater and the ends at $x=0$ and $x=1$ become flatter. As $\alpha\to\infty$, the curve tends toward a step function.
These functions have the nice property that $f_a\circ f_b=f_{ab}$. Thus, $f_a$ and $f_{1/a}$ are inverses.