cats-collections icon indicating copy to clipboard operation
cats-collections copied to clipboard

convert Diet into a balanced tree.

Open anicolaspp opened this issue 9 years ago • 2 comments

I found that Scalaz Diev has lower inserts/deletions than our Diet, but is quite faster in searches. We can balance Diet so we improve search, yet, it might compromise inserts/deletions.

The original Diet paper doesn't talk about balancing it out, but will it be something we should consider?

anicolaspp avatar Feb 16 '16 04:02 anicolaspp

I was wrong, it is the other way around. Still, it might be a good idea to balance Diet?

anicolaspp avatar Feb 16 '16 23:02 anicolaspp

I have an implementation of a Diet in Haskell here: https://github.com/j-mie6/rangeset

It has the balancing property, and also implements a faster union and intersection than the one Diet uses. Perhaps some of the ideas can be ported over? (I'd be willing to work on this if so). I have a draft paper that describes the implementation.

j-mie6 avatar Sep 13 '23 11:09 j-mie6