Distance method of the Ray corrected.