Flick a list of items and have it keep going?

So you know how on lets say an iPod touch, or any iOS device now, when your scrolling down your music list, or even when your scrolling down web page. You can flick it and have it keep going. So like if you swipe your finger up to scroll up and lift your finger up during the movement, it keeps scrolling up without your finger on it, but it begins to slow down.

Has anyone replicated this?

I am trying to do it right now, and I have the code working. A very simple implementation where your finger movement defines the move delta and the move delta gets reduced by X amount of time each frame, so that it slowly slows down when your finger lifts. And then it is set so that if your finger touches down again while its moving, it instantly stops. And this works. But it doesnt feel right. Like sometimes when your finger is swiping a direction and you lift your finger up in what appears to be a situation where it should keep going, somehow it registers a movement delta of 0 so it abruptly stops.

Does anyone know what exactly kind of mechanic this systems uses on iOS itself? I do believe there doing a few extra checks for things here and there over what it appears to simply be.

I’ve done it by having a “force” value, that goes down in a logarithmic sort of curve (sharply decreasing initially then slowly decreasing) and only is multiplied with the delta when the finger is lifted. So if you flick a short distance, it’ll give a burst, flick very far very fast will give the most burst, but any sort of drags will only cause a tiny glide.

After that it’s just modifying the curves, really.