|
|
| DisjointSetsWithSize (size_t n) |
| |
|
void | init (size_t n) |
| |
|
void | clear () |
| |
|
IndexType | size_of (IndexType i) |
| |
|
IndexType | merge (IndexType i, IndexType j) |
| |
|
| DisjointSets ()=default |
| | Initialize an empty disjoint sets.
|
| |
| | DisjointSets (size_t n) |
| | Initialize disjoint sets that contains n entries.
|
| |
| void | init (size_t n) |
| | Initialize disjoint sets that contains n entries.
|
| |
|
size_t | size () const |
| | Get the number of entries in total.
|
| |
|
void | clear () |
| | Clear all entries in the disjoint sets.
|
| |
| IndexType | find (IndexType i) |
| | Find the root index corresponding to index i.
|
| |
| IndexType | merge (IndexType i, IndexType j) |
| | Merge the disjoint set containing entry i and the disjoint set containing entry j.
|
| |
| std::vector< std::vector< IndexType > > | extract_disjoint_sets () |
| | Extract disjoint sets.
|
| |
| size_t | extract_disjoint_set_indices (std::vector< IndexType > &index_map) |
| | Assign all elements their disjoint set index.
|
| |
| size_t | extract_disjoint_set_indices (span< IndexType > index_map) |
| | Assign all elements their disjoint set index.
|
| |
|
|
std::vector< IndexType > | m_size |
| |
|
std::vector< IndexType > | m_parent |
| |
The documentation for this class was generated from the following file: