LAL: Linear Arrangement Library 23.01.00
A library focused on algorithms on linear arrangements of graphs.
|
Generation of different classes of objects. More...
Classes | |
class | _rand_lab_free_trees |
Uniformly random generation of labelled free trees. More... | |
class | _rand_lab_rooted_trees |
Uniformly random generation of labelled rooted trees. More... | |
class | _rand_ulab_free_trees |
Uniformly random generation of unlabelled free trees. More... | |
class | _rand_ulab_rooted_trees |
Uniformly random generation of unlabelled rooted trees. More... | |
class | _tree_generator |
Base class for tree generators. More... | |
class | all_arrangements |
Exhaustive enumeration of arrangements of any graph. More... | |
class | all_lab_free_trees |
Exhaustive enumeration of labelled free trees. More... | |
class | all_lab_rooted_trees |
Exhaustive enumeration of labelled rooted trees. More... | |
class | all_planar_arrangements |
Exhaustive enumeration of planar arrangements of a labeled free tree. More... | |
class | all_projective_arrangements |
Exhaustive enumeration of projective arrangements of a labeled rooted tree. More... | |
class | all_ulab_free_trees |
Exhaustive enumeration of unlabelled free trees. More... | |
class | all_ulab_rooted_trees |
Exhaustive enumeration of unlabelled rooted trees. More... | |
struct | exhaustive_random_type |
Shorthand to get one of exhaustive_t or random_t. More... | |
struct | exhaustive_t |
Type for exhasutive enumeration of trees. More... | |
struct | labelled_t |
Type for labelled tree generation. More... | |
struct | labelled_unlabelled_type |
Shorthand to get one of labelled_t or unlabelled_t. More... | |
class | rand_arrangements |
Random generation of arrangements of any graph. More... | |
class | rand_lab_free_trees |
Uniformly random generation of labelled free trees. More... | |
class | rand_lab_rooted_trees |
Uniformly random generation of labelled rooted trees. More... | |
class | rand_planar_arrangements |
Uniformly random generation of planar arrangements of a labeled rooted tree. More... | |
class | rand_projective_arrangements |
Uniformly random generation of projective arrangements of a labeled rooted tree. More... | |
class | rand_ulab_free_trees |
Uniformly random generation of unlabelled free trees. More... | |
class | rand_ulab_rooted_trees |
Uniformly random generation of unlabelled rooted trees. More... | |
struct | random_t |
Type for random generation of trees. More... | |
struct | tree_generator_type |
Automatic tree generator type generator. More... | |
struct | unlabelled_t |
Type for unlabelled tree generation. More... | |
Typedefs | |
template<bool is_exhaustive> | |
using | exhaustive_random_type_t = typename exhaustive_random_type< is_exhaustive >::type |
Shorthand of exhaustive_random_type. | |
template<bool is_labelled> | |
using | labelled_unlabelled_type_t = typename labelled_unlabelled_type< is_labelled >::type |
Shorthand of labelled_unlabelled_type. | |
template<typename exhaustive_random , typename labelled_unlabelled , class tree_t > | |
using | tree_generator_type_t = typename tree_generator_type< exhaustive_random, labelled_unlabelled, tree_t >::type |
Typedef of tree_generator_type. | |
Generation of different classes of objects.
This namespace contains algorithms for the generation of trees and of arrangements.
The classes that generate trees have a self-explanatory format:
1_2_3_trees
The numbers are placeholders for the following:
Therefore, the class lal::generate::rand_lab_rooted_trees generates random labelled rooted trees uniformly at random, and the class lal::generate::all_ulab_free_trees should be used to enumerate all unlabelled free trees.
All classes for tree generation return trees that are preprocessed. This preprocessing varies depending on whether the tree is rooted or free. The full preprocessing details can be checked in class lal::generate::_tree_generator, from which all these classes inherit.
Using these classes is straightforward. To generate trees uniformly at random:
To enumerate all trees:
Alternatively,
And even,
(remember to replace the numbers in the actual code!).
This namespace contains classes for the generation of arrangements of a given tree. Depending on the type of arrangements, the given tree should be free or rooted accordingly. Again, the names for these classes are also self-explanatory:
1_2_arrangement
The numbers are placeholders for the following:
Therefore,
Similary,
Using these classes is straightforward. To generate trees uniformly at random:
To enumerate all arrangements:
Alternatively,
And even,
(remember to replace the numbers in the actual code!).