calc_vel to get rid of blinks