Ease In, Out: The Sigmoid Factory
medium.com
medium.com
0.5-0.5cos(pit/T)
to a function which has a nonzero derivative at the start at the end.
cos(...)
you could use pow( cos(...), a )
where a can be used to adjust the steepness.I can't plot it right now and I think I'm missing something, but you get the general idea of using the power of a function which goes form 0 to 1 to adjust steepness.
Another solution would be a 2-piece function kind of
0.5*pow( 2*t/T, a ) for t < T/2
and 1-0.5*pow( 2*(1-t/T), a ) for t > T/2
which makes a similar slope as the cosine but is easier to calculate.