96 #include <boost/graph/bipartite.hpp>
126 std::string
structures_to_graphml(std::vector<std::string> structures, std::string constraints,
bool decompose,
unsigned long seed);
191 template <
typename R>
201 DependencyGraph(std::vector<std::string> structures, std::string constraints, R rand);
209 DependencyGraph(std::vector<std::string> structures, std::string constraints,
unsigned long seed);
332 SolutionSizeType
sample(
int start,
int end);
448 detail::DependencyGraph<R> *
g;
Dependency Graph which holds all structural constraints.
detail::DependencyGraph< R > * g
Pointer to the internal dependency graph object.
SolutionSizeType sample(int start, int end)
Resets only the smallest subgraph(s) possible containing the vertices from position start to end.
SolutionSizeType set_sequence(std::string sequence)
Allows you to set a initial sequence as starting point for your optimization.
std::string get_sequence()
Get the current RNA sequence as a string.
DependencyGraph(std::vector< std::string > structures, std::string constraints, unsigned long seed)
constructor for the Dependency graph using a predefined random number generator with the given seed.
SolutionSizeType sample_clocal(int min_num_pos, int max_num_pos)
Randomly chooses a connected component with the given size and samples a new sequence for the whole c...
SolutionSizeType number_of_sequences()
Returns the amount of solutions given the dependency graph and sequence constraints.
DependencyGraph(std::vector< std::string > structures)
constructor for the Dependency graph using a predefined random number generator with a clock generate...
SolutionSizeType number_of_sequences(int connected_component_ID)
Returns the amount of solutions for the connected component with the given ID.
SolutionSizeType sample_clocal()
Takes a random connected component and samples a new sequence for the whole component.
SolutionSizeType sample(int position)
Resets and samples only the smallest subgraph(s) possible containing the vertex at the given position...
SolutionSizeType sample()
Resets all bases in the whole dependency graph and samples a new sequence randomly.
~DependencyGraph()
Destructor for the dependency graph object.
std::vector< int > component_vertices(int connected_component_ID)
Returns a vector with all the vertices in this component of the given ID.
SolutionSizeType sample_clocal(int connected_component_ID)
Takes the connected component with the specified ID and samples a new sequence for the whole componen...
DependencyGraph(const DependencyGraph ©)
Copy constructor which sets a new random seed in the copy sampled from the old generator.
std::vector< std::string > get_history()
Returns the history of previous sampled sequences at this point.
void set_history_size(unsigned int size)
Set the maximum number of previous sampled sequences to memorize (Default: 100).
DependencyGraph(std::vector< std::string > structures, std::string constraints)
constructor for the Dependency graph using a predefined random number generator with a clock generate...
std::vector< int > articulation_vertices(int connected_component_ID)
Returns a list of vertices in the specified connected component specified as articulation vertices.
unsigned int max_number_of_dimensions()
Returns the maximal number of dimensions of all dynamic programming tables.
std::vector< int > articulation_vertices()
Returns a list of vertices specified as articulation vertices.
std::string get_graphml()
Returns the root graph in GraphML format as a string.
int number_of_connected_components()
Returns the number of connected components into which the dependency graph was decomposed.
bool revert_sequence()
Reverts the sequence to the previous one.
bool revert_sequence(unsigned int jump)
Reverts the sequence to a previous one being (jump) steps in the history;.
std::string get_graphml(int connected_component_ID)
Returns the connected component graph with the connected_component_ID in GraphML format as a string.
SolutionSizeType sample_plocal()
Randomly chooses one path (either top-level a connected component, or within a block,...
DependencyGraph(std::vector< std::string > structures, std::string constraints, R rand)
Constructor for the Dependency graph.
SolutionSizeType sample_plocal(int min_num_pos, int max_num_pos)
Randomly chooses one path (either top-level a connected component, or within a block,...
DependencyGraph(std::vector< std::string > structures, R rand)
constructor for the Dependency graph without any sequence constraints.
This file holds all global includes, definitions and variables.
This file holds the functions to decompose the dependency graph into its subgraphs.
This file holds the class definitions for the internal representation of the DependencyGraph.
All classes and functions for the RNA design library are under the design namespace.
bool graph_is_bipartite(std::vector< std::string > structures)
Returns whether the dependency graph built from the given input structures is bipartite.
void initialize_library(bool debug)
Initialize the Libraries global variables.
bool sequence_structure_compatible(std::string sequence, std::vector< std::string > structures)
Returns whether the the given sequence is compatible to all the given structures.
std::vector< int > incompatible_sequence_positions(std::string sequence, std::string structure)
Returns whether the the given sequence is compatible to all the given structures.
std::string structures_to_graphml(std::vector< std::string > structures, std::string constraints, bool decompose, unsigned long seed)
Generate a graphml representation of structural and sequence constraints.
This file holds the functions to parse a dot-bracket representation to a boost graph and set the sequ...