Class for storing segment lists representing edges of a hypergraph.
More...
#include <cliq.hpp>
|
using | Ptr = std::shared_ptr< Clique > |
| shared_ptr alias declaration.
|
|
|
| Clique ()=default |
| Default construct an empty Clique.
|
|
| Clique (const CCtsp_lpclique &cc_cliq, const std::vector< int > &saved_tour, const std::vector< int > &saved_perm, const std::vector< int > ¤t_tour) |
| Construct a Clique from a Concorde clique.
|
|
| Clique (int start, int end, const std::vector< int > &saved_tour, const std::vector< int > &saved_perm, const std::vector< int > ¤t_tour) |
| Construct a Clique from start and end indices.
|
|
| Clique (const std::vector< int > &nodes, const std::vector< int > &perm, bool peserve_order) |
| Construct a Clique from a list of literal nodes. More...
|
|
int | seg_count () const |
| How many segments are used to represent the Clique.
|
|
const std::vector< Segment > & | seg_list () const |
| A constant reference to the list of segments in the Clique.
|
|
std::vector< int > | node_list (const std::vector< int > &saved_tour) const |
| A list of literal nodes represented by the Clique. More...
|
|
bool | operator== (const Clique &rhs) const |
| Equality operator.
|
|
bool | contains (const int index) const |
| Returns true iff the Clique contains index .
|
|
Class for storing segment lists representing edges of a hypergraph.
A Clique stores a subset of vertices as a list of CMR::Segment objects, where the start and endpoints indicate a range of nodes from a tour. Thus, a Clique is meaningless without a tour from which to be derefrenced.
CMR::Sep::Clique::Clique |
( |
const std::vector< int > & |
nodes, |
|
|
const std::vector< int > & |
perm, |
|
|
bool |
preserve_order |
|
) |
| |
Construct a Clique from a list of literal nodes.
- Parameters
-
[in] | nodes | a list of nodes in the graph as per some absolute order not dependent on the current tour. |
[in] | perm | the clique will be built using indices from perm, hence implicitly reprsented in terms of the tour corresponding to perm . |
vector< int > CMR::Sep::Clique::node_list |
( |
const std::vector< int > & |
saved_tour | ) |
const |
A list of literal nodes represented by the Clique.
- Parameters
-
[in] | saved_tour | the tour that was active when this Clique was constructed. |
- Returns
- a vector of the literal nodes obtained by dereferencing
saved_tour
for the ranges specified in the segment list.
The documentation for this class was generated from the following files: