Algorithm for inverting lidar returns.