more precise cubic-quadratic distance approximation