48#include <lal/graphs/rooted_tree.hpp>
49#include <lal/generate/rand_lab_free_trees.hpp>
115 inline void init(uint32_t seed = 0) noexcept {
Uniformly random generation of labelled free trees.
Definition rand_lab_free_trees.hpp:68
graphs::free_tree get_tree() noexcept
Returns a labelled free tree chosen uniformly at random.
std::uniform_int_distribution< uint32_t > m_unif
Distribution of the numbers.
Definition rand_lab_free_trees.hpp:116
void init(uint32_t seed=0) noexcept
Sets the size of the labelled trees to generate.
std::mt19937 m_gen
Random number generator.
Definition rand_lab_free_trees.hpp:114
Uniformly random generation of labelled rooted trees.
Definition rand_lab_rooted_trees.hpp:67
_rand_lab_rooted_trees(uint32_t n, uint32_t seed=0) noexcept
Constructor with size of tree and seed for the random number generator.
Definition rand_lab_rooted_trees.hpp:78
_rand_lab_rooted_trees(_rand_lab_rooted_trees &&Gen)=default
Move constructor.
~_rand_lab_rooted_trees()=default
Default destructor.
void init(uint32_t seed=0) noexcept
Sets the size of the labelled trees to generate.
Definition rand_lab_rooted_trees.hpp:115
graphs::rooted_tree get_tree() noexcept
Generates uniformly at random a labelled rooted tree.
Definition rand_lab_rooted_trees.hpp:102
_rand_lab_rooted_trees(const _rand_lab_rooted_trees &Gen)=default
Copy constructor.
Base class for tree generators.
Definition tree_generator.hpp:87
tree_type_t get_tree() noexcept
Definition tree_generator.hpp:146
Uniformly random generation of labelled rooted trees.
Definition rand_lab_rooted_trees.hpp:144
rand_lab_rooted_trees(const rand_lab_rooted_trees &Gen)=default
Copy constructor.
rand_lab_rooted_trees(rand_lab_rooted_trees &&Gen)=default
Move constructor.
~rand_lab_rooted_trees()=default
Default destructor.
graphs::rooted_tree yield_tree() noexcept
Yields a tree, advancing the generator if necessary.
Definition rand_lab_rooted_trees.hpp:173
_rand_lab_rooted_trees m_Gen
See _rand_lab_rooted_trees for details.
Definition rand_lab_rooted_trees.hpp:188
graphs::rooted_tree __get_tree() noexcept
Returns a labelled rooted tree chosen uniformly at random.
Definition rand_lab_rooted_trees.hpp:184
rand_lab_rooted_trees(uint32_t n, uint32_t seed=0) noexcept
Constructor with size of tree and seed for the random number generator.
Definition rand_lab_rooted_trees.hpp:156
Free tree graph class.
Definition free_tree.hpp:59
Rooted tree graph class.
Definition rooted_tree.hpp:107
Main namespace of the library.
Definition definitions.hpp:48
uint32_t node
Node type.
Definition definitions.hpp:51