implemented find_long_intersection algorithm