I'm trying to write an interpolator for a translate animation, and I'm stuck. The animation passes a single value to the function. This value maps a value representing the elapsed fraction of an animation to a value that represents the interpolated fraction. The value starts at 0 and goes to 1 when the animation completes. So for instance, if I wanted a linear translation (constant velocity) my function would look like:
function(input) {
return input
}
What I need is for the velocity to remain constant for half the animation, then decelerate rapidly to zero. What this essentially means is that the input values I return must be the same as the output values for half the animation (until 0.5), then the values must increase from 0.5 to 1.0 at a slower rate of change between calls than the input value change between calls.
EDIT (straight from the Android docs):
The following table represents the approximate values that are calculated by example interpolators for an animation that lasts 1000ms:

As the table shows, the LinearInterpolator changes the values at the same speed, .2 for every 200ms that passes. The AccelerateDecelerateInterpolator changes the values faster than LinearInterpolator between 200ms and 600ms and slower between 600ms and 1000ms.
EDIT 2:
I thought I should provide an example of something that works, just not the way I want it to. The function for a decelerate interpolation provided with the Android framework is exactly:
function(input) {
return (1 - (1 - input) * (1 - input))
}

This answers a problem motivated by your description, but it may not be the problem you want to solve. We assume constant velocity $k$ for $0\le t\le 0.5$. Then we have constant deceleration, so that at time $t=1$ velocity reaches $0$.
Under these conditions, you may want the net displacement at time $t$.
Our velocity at $t=0.5$ is $k$. It has to reach $0$ at time $1$, so the velocity at time $t$, for $0.5\le t\le 1$, is $k-\frac{k}{1-0.5}(t-0.5)=2k-2kt$.
Our net displacement $s(t)$ at time $t$ is $kt$ for $0\le t\le 0.5$.
For $0.5\lt t\le 1$, the net displacement is $(0.5)k +\int_{0.5}^t (2k-2kt)\,dt$. This simplifies to $2kt-kt^2-0.25k$.
Thus a formula for the net displacement $s(t)$ at time $t$ is $s(t)=kt$ for $0\le t\le 0.5$, and $s(t)=2kt -kt^2-0.25k$ for $0.5\lt t\le 1$.