The class for solving the Steiner Tree problem using Iterative Rounding. More...
#include <steiner_tree.hpp>
Public Types | |
using | MT = data_structures::metric_traits< OrigMetric > |
using | Vertex = typename MT::VertexType |
using | Vertices = std::vector< Vertex > |
using | Dist = typename MT::DistanceType |
using | Edge = typename std::pair< Vertex, Vertex > |
using | Compare = utils::compare< double > |
using | VertexIndex = data_structures::bimap< Vertex > |
using | MetricIdx = data_structures::array_metric< Dist > |
using | Metric = data_structures::metric_on_idx< MetricIdx &, const VertexIndex &, data_structures::read_values_tag > |
Public Member Functions | |
steiner_tree (const OrigMetric &metric, const Terminals &terminals, const Terminals &steiner_vertices, Result result, const Strategy &strategy=Strategy{}, Oracle oracle=Oracle{}) | |
template<typename LP > | |
auto | get_find_violation (LP &lp) |
void | gen_components () |
const steiner_components < Vertex, Dist > & | get_components () const |
const Terminals & | get_terminals () const |
auto | get_terminal_idx (Vertex v) const -> decltype(m_terminals_index.get_idx(v)) |
void | add_column_lp (int id, lp::col_id col) |
lp::col_id | find_column_lp (int id) const |
void | add_to_solution (const std::vector< Vertex > &steiner_elements) |
void | set_solution () |
void | update_graph (const steiner_component< Vertex, Dist > &selected) |
utils::compare< double > | get_compare () const |
The class for solving the Steiner Tree problem using Iterative Rounding.
OrigMetric | |
Terminals | |
Result | |
Strategy | |
Oracle | separation oracle |
Definition at line 67 of file steiner_tree.hpp.
|
inline |
Constructor.
Definition at line 106 of file steiner_tree.hpp.
|
inline |
Adds map entry from component id to LP lp::col_id.
Definition at line 164 of file steiner_tree.hpp.
|
inline |
Adds elements to solution.
Definition at line 177 of file steiner_tree.hpp.
|
inline |
Finds LP lp::col_id based on component id.
Definition at line 172 of file steiner_tree.hpp.
|
inline |
Generates all the components using specified strategy.
Definition at line 137 of file steiner_tree.hpp.
|
inline |
Gets comparison method.
Definition at line 212 of file steiner_tree.hpp.
|
inline |
Gets reference to all the components.
Definition at line 145 of file steiner_tree.hpp.
|
inline |
|
inline |
Returns the index of a terminal.
Definition at line 157 of file steiner_tree.hpp.
|
inline |
Gets reference to all the terminals.
Definition at line 152 of file steiner_tree.hpp.
|
inline |
Removes duplicates and sets the final solution.
Definition at line 184 of file steiner_tree.hpp.
|
inline |
Merges a component into its sink.
Definition at line 192 of file steiner_tree.hpp.