Motion with constant acceleration and deceleration