Move intersection logic into Interval.
Remove unnecessary helper functions.