Figure 4: Testing two segments for intersection