Here's my first attempt using a sungle point model (which is not really good enough for an extended flexible vehicle, but is a starting step).
The profile I get before the vehicle comes to a halt (actually, starts sliding backwards) is as follows:
I've yet to look at Fred's solution, which I'll do now.
Alan