Profiling showed much of is_closest_ray method needed to be moved to its
parent detect_eigenrays method of wave_queue.