34 #ifndef __GECODE_INT_LDSB_HH__ 35 #define __GECODE_INT_LDSB_HH__ 43 namespace Gecode {
namespace Int {
namespace LDSB {
79 findVar(
int *indices,
unsigned int n_values,
unsigned int seq_size,
int index);
104 namespace Gecode {
namespace Int {
namespace LDSB {
171 virtual size_t dispose(
Space& home) = 0;
175 static void*
operator new(
size_t s,
Space& home);
177 static void operator delete(
void*,
Space&);
179 static void operator delete(
void*);
182 template <
class View>
193 virtual size_t dispose(
Space& home);
202 template <
class View>
213 virtual size_t dispose(
Space& home);
222 template <
class View>
255 virtual size_t dispose(
Space& home);
264 template <
class View>
289 virtual size_t dispose(
Space& home);
304 const Literal *
const _literals;
306 const int _nliterals;
311 const Literal* literals,
int nliterals);
315 const Literal* literals(
void)
const;
317 int nliterals(
void)
const;
319 virtual void archive(
Archive& e)
const;
330 template<
class View,
int n,
class Val,
unsigned int a,
331 class Filter,
class Print>
362 virtual size_t dispose(
Space& home);
375 template<
class View,
int n,
class Val,
unsigned int a>
Int::LDSB::Literal ValueType
VarImpBase ** xs
Array of variables in symmetry.
unsigned int n_indices
Total number of indices (n_seqs * seq_size)
void sequence(Home home, const IntVarArgs &x, const IntSet &s, int q, int l, int u, IntPropLevel)
Post propagator for .
IntSet values
Set of symmetric values.
A Literal is a pair of variable index and value.
unsigned int lookup_size
Size of lookup.
IntArgs values
Array of values in symmetry.
std::pair< int, int > findVar(int *indices, unsigned int n_values, unsigned int seq_size, int index)
Find the location of an integer in a collection of sequences.
View::VarType Var
The corresponding variable.
Implementation of a value symmetry at the modelling level.
Implementation of a value sequence symmetry at the modelling level.
std::function< void(const Space &home, const Brancher &b, unsigned int a, Var x, int i, const Val &m, std::ostream &o)> VarValPrint
Function type for printing variable and value selection.
void postldsbbrancher(Home home, ViewArray< View > &x, ViewSel< View > *vs[n], ValSelCommitBase< View, Val > *vsc, SymmetryImp< View > **syms, int nsyms, BranchFilter< typename View::VarType > bf, VarValPrint< typename View::VarType, Val > vvp)
Post LDSB brancher.
int ModEvent
Type for modification events.
Implementation of a symmetry at the modelling level.
Implementation of a variable sequence symmetry.
Support::BitSetOffset< Space > values
Symmetric values.
int * lookup
Map from variable's index to its sequence and position.
int _value
The value of the literal. For int and bool variables, this is the value itself; for set variables...
Base-class for variable implementations.
int _variable
Variable index. The ViewArray that the index is meant for is assumed to be known by context...
Base-class for both propagators and branchers.
int nxs
Number of variables in symmetry.
ArgArray< Int::LDSB::Literal > LiteralArgs
An array of literals.
bool operator<(const Literal &rhs) const
Less than. The ordering is the lexicographical order on the (variable,value) pair.
Gecode::FloatVal c(-8, 8)
int p
Number of positive literals for node type.
Choice storing position and value, and symmetric literals to be excluded on the right branch...
Base-class for branchers.
int n
Number of negative literals for node type.
unsigned int n_seqs
Number of sequences in symmetry.
Argument array for non-primitive types.
unsigned int * indices
Array of variable indices.
Generic brancher by view and value selection.
Literal(void)
Constructor for an empty literal.
ModEvent prune(Space &home, View x, int v)
Exclude value from variable view .
Implementation of a variable symmetry at the modelling level.
Implementation of a value symmetry.
std::function< bool(const Space &home, Var x, int i)> BranchFilter
Function type for branch filter functions.
struct Gecode::@593::NNF::@62::@63 b
For binary nodes (and, or, eqv)
unsigned int seq_size
Size of each sequence in symmetry.
ArgArray< VarImpBase * > ArgsType
int nxs
Number of variables in symmetry.
Support::BitSet< Space > dead_sequences
Which sequences are dead.
int seq_size
Size of each sequence in symmetry.
Symmetry-breaking brancher with generic view and value selection.
Implementation of a variable sequence symmetry at the modelling level.
Support::BitSetOffset< Space > indices
Symmetric variable indices.
VarImpBase ** xs
Array of variables in symmetry.
int seq_size
Size of each sequence in symmetry.
Passing integer arguments.
unsigned int seq_size
Size of each sequence in symmetry.
double position(const Space &home, IntVar x, int i)
unsigned int n_values
Total number of values (n_seqs * seq_size)
Implementation of a single symmetry.
Choice for performing commit
Implementation of a variable symmetry.
Implementation of a value sequence symmetry.
Post propagator for SetVar x
int _nsyms
Number of symmetry implementations.
SymmetryImp< View > ** _syms
Array of symmetry implementations.
Traits of arrays in Gecode.
unsigned int n_seqs
Number of sequences in symmetry.
Gecode toplevel namespace
#define GECODE_VTABLE_EXPORT
#define GECODE_INT_EXPORT
ArgArray< VarImpBase * > StorageType
Home class for posting propagators
Choice storing position and value
int nrefs
Number of references that point to this symmetry object.
void update(IntSet &y, Space &home, IntSet &py)
struct Gecode::@593::NNF::@62::@64 a
For atomic nodes.
Bitsets with index offset.
TFE post(PropagatorGroup g)
Only post functions (but not propagators) from g are considered.
int * values
Set of sequences.