

Show HN: Dynamic graph connectivity data structure - 33a
https://github.com/mikolalysenko/dynamic-forest

======
iandanforth
I'd like to know more about the use-case and advantages here. Anyone have
professional experience with the cost/difficulty of maintaining spanning
forests?

~~~
33a
The advantage of using the library is that you would be able to answer
connectivity queries and traverse the connected components of the graph
efficiently.

EDIT: If you want an example application, suppose you have a physics
simulation with a bunch of connected rigid bodies. You would like to be able
to quickly test if two boxes are connected by links to the same body or to
detect if after breaking a joint the resulting body becomes disconnected into
two different pieces. Using a data structure like this would be faster than
brute force searching over the graph of all bodies every time you change a
link by connecting/disconnecting two bodies.

