still working on it

I've managed to make the algorithm for unifying segments that overlap
work.