pub struct Pooled<T>{ /* private fields */ }
Expand description
The decision diagram in itself. This structure essentially keeps track of the nodes composing the diagram as well as the edges connecting these nodes in two vectors (enabling preallocation and good cache locality). In addition to that, it also keeps track of the path (root_pa) from the problem root to the root of this decision diagram (explores a sub problem). The prev_l comprises information about the nodes that are currently being expanded, next_l stores the information about the nodes from the next layer and cut-set stores an exact cut-set of the DD. Depending on the type of DD compiled, different cut-set types will be used:
- Exact: no cut-set is needed since the DD is exact
- Restricted: the last exact layer is used as cut-set
- Relaxed: either the last exact layer of the frontier cut-set can be chosen within the CompilationInput
Implementations§
source§impl<T> Pooled<T>
impl<T> Pooled<T>
sourcepub fn as_graphviz(&self, config: &VizConfig) -> String
pub fn as_graphviz(&self, config: &VizConfig) -> String
This is the method you will want to use in order to create the output image you would like. Note: the output is going to be a string of (not compiled) ‘dot’. This makes it easier for me to code and gives you the freedom to fiddle with the graph if needed.
Trait Implementations§
source§impl<T> DecisionDiagram for Pooled<T>
impl<T> DecisionDiagram for Pooled<T>
§type State = T
type State = T
State
type of the problems
that can be solved when using this DD.source§fn compile(
&mut self,
input: &CompilationInput<'_, Self::State>
) -> Result<Completion, Reason>
fn compile( &mut self, input: &CompilationInput<'_, Self::State> ) -> Result<Completion, Reason>
source§fn best_value(&self) -> Option<isize>
fn best_value(&self) -> Option<isize>
source§fn best_solution(&self) -> Option<Solution>
fn best_solution(&self) -> Option<Solution>
source§fn best_exact_value(&self) -> Option<isize>
fn best_exact_value(&self) -> Option<isize>
source§fn best_exact_solution(&self) -> Option<Solution>
fn best_exact_solution(&self) -> Option<Solution>
source§fn drain_cutset<F>(&mut self, func: F)
fn drain_cutset<F>(&mut self, func: F)
func
to each element of the
exact cut-set that was computed during DD compilation. Read more