Intersection of line segments