I have a certain amount of intervals, from which I have constructed an interval tree
https://en.wikipedia.org/wiki/Interval_tree
The interval tree is particularly useful for finding an interval overlapping with another certain interval, actually it can do that in O(log N) time.
Now I want to do something more: I want to divide the set of all intervals into a series of disjoint subsets. In every subset each element overlaps with at least another element. An element in a subset does not overlap with an element in a different subset. I call each of these subsets a cluster.
I know a O(N log N) solution, following this nice answer
Possible Interview Question: How to Find All Overlapping Intervals
but I am wondering if, having already created an interval tree, I can use this data structure to create clusters faster.