In my problem, I have a bunch of Elements (Class Element). Say I have 1000 Elements. These Elements are initially un-associated which means they are in their own sets.
Later I need to use the union operation to merge some of these sets based of my program flow. I plan to use the boost library's disjoint_set (http://www.boost.org/doc/libs/1_57_0/libs/disjoint_sets/disjoint_sets.html)
My question is how is it possible to list the Elements in a set given the representative of the set.
Is disjoint_set the best data structure for such a task. So should I look into using something else?