Google OR-Tools v9.11
a fast and portable software suite for combinatorial optimization
|
#include <hamiltonian_path.h>
Public Types | |
typedef SetRange::SetType | SetType |
Make the parameter types visible to SetRangeWithCardinality. | |
typedef SetType::IntegerType | IntegerType |
Public Member Functions | |
SetRangeIterator (const SetType set) | |
SetType | operator* () const |
STL iterator-related methods. | |
bool | operator!= (const SetRangeIterator &other) const |
const SetRangeIterator & | operator++ () |
An iterator for sets of increasing corresponding values that have the same cardinality. For example, the sets with cardinality 3 will be listed as ...00111, ...01011, ...01101, ...1110, etc...
Definition at line 222 of file hamiltonian_path.h.
SetType::IntegerType operations_research::SetRangeIterator< SetRange >::IntegerType |
Definition at line 226 of file hamiltonian_path.h.
SetRange::SetType operations_research::SetRangeIterator< SetRange >::SetType |
Make the parameter types visible to SetRangeWithCardinality.
Definition at line 225 of file hamiltonian_path.h.
|
inlineexplicit |
Definition at line 228 of file hamiltonian_path.h.
|
inline |
Definition at line 232 of file hamiltonian_path.h.
|
inline |
STL iterator-related methods.
Definition at line 231 of file hamiltonian_path.h.
|
inline |
Computes the next set with the same cardinality using Gosper's hack. ftp://publications.ai.mit.edu/ai-publications/pdf/AIM-239.pdf ITEM 175 Also translated in C https://www.cl.cam.ac.uk/~am21/hakmemc.html
Dividing by c as in HAKMEMC can be avoided by taking into account that c is the smallest singleton of current_set_, and using a shift.
Definition at line 239 of file hamiltonian_path.h.