Gecode::CpltSet::CpltSetVarImp Class Reference
[Other available functionality]
Detailed Description
Finite integer set variable implementation using a complete domain representation.Definition at line 136 of file var-imp.icc.
Set bounds update by value | |
ModEvent | exclude (Space *home, int v) |
Exclude value v from lub. | |
GECODE_CPLTSET_EXPORT ModEvent | exclude (Space *home, int a, int b) |
Exclude range from. | |
ModEvent | include (Space *home, int v) |
Include value v in glb. | |
GECODE_CPLTSET_EXPORT ModEvent | include (Space *home, int a, int b) |
Include range in glb. | |
ModEvent | intersect (Space *home, int i) |
Intersect domain with singleton set . | |
GECODE_CPLTSET_EXPORT ModEvent | intersect (Space *home, int a, int b) |
Intersect domain with range . | |
Set bounds update by range iterator | |
template<class I> | |
ModEvent | intersectI (Space *home, I &i) |
Intersect domain with range sequence described by i. | |
template<class I> | |
ModEvent | excludeI (Space *home, I &i) |
Exclude set described by range sequence i from lub. | |
template<class I> | |
ModEvent | includeI (Space *home, I &i) |
Include set described by range list i in glb. | |
Set cardinality update | |
GECODE_CPLTSET_EXPORT ModEvent | cardinality (Space *home, int l, int u) |
Restrict cardinality to be at least l and at most u. | |
ModEvent | cardMin (Space *home, unsigned int n) |
Restrict cardinality to be at least n. | |
ModEvent | cardMax (Space *home, unsigned int n) |
Restrict cardinality to be at most n. | |
Set domain update by value | |
ModEvent | nq (Space *home, int v) |
Restrict domain values to be different from singleton set . | |
GECODE_CPLTSET_EXPORT ModEvent | nq (Space *home, int a, int b) |
Restrict domain values to be different from range . | |
ModEvent | eq (Space *home, int v) |
Restrict domain to be equal to singleton set . | |
GECODE_CPLTSET_EXPORT ModEvent | eq (Space *home, int a, int b) |
Restrict domain to be equal to range . | |
Set domain update by range iterator | |
template<class I> | |
ModEvent | nqI (Space *home, I &i) |
Restrict domain values to be different from set described by i. | |
template<class I> | |
ModEvent | eqI (Space *home, I &i) |
Restrict domain to be equal to the range sequence i. | |
Set domain update by bdd | |
GECODE_CPLTSET_EXPORT ModEvent | intersect (Space *home, bdd &d) |
Intersect domain with the domain represented by d. | |
Value access | |
unsigned int | cardMin (void) const |
Return current cardinality minimum. | |
unsigned int | cardMax (void) const |
Return current cardinality maximum. | |
GECODE_CPLTSET_EXPORT int | glbMin (void) const |
Return minimum of the greatest lower bound. | |
GECODE_CPLTSET_EXPORT int | glbMax (void) const |
Return maximum of the greatest lower bound. | |
GECODE_CPLTSET_EXPORT unsigned int | glbSize (void) const |
Return the size of the greatest lower bound. | |
GECODE_CPLTSET_EXPORT int | lubMin (void) const |
Return minimum of the least upper bound. | |
GECODE_CPLTSET_EXPORT int | lubMax (void) const |
Return maximum of the least upper bound. | |
GECODE_CPLTSET_EXPORT unsigned int | lubSize (void) const |
Return the size of the least upper bound. | |
GECODE_CPLTSET_EXPORT int | lubMinN (int n) const |
Return n -th smallest element in the least upper bound. | |
GECODE_CPLTSET_EXPORT int | lubMaxN (int n) const |
Return n -th largest element in the least upper bound. | |
GECODE_CPLTSET_EXPORT int | unknownMin (void) const |
Return minimum of the difference between the greatest lower and the least upper bound. | |
GECODE_CPLTSET_EXPORT int | unknownMax (void) const |
Return maximum of the difference between the greatest lower and the least upper bound. | |
GECODE_CPLTSET_EXPORT unsigned int | unknownSize (void) const |
Return the size of the difference between the greatest lower and the least upper bound. | |
Bdd information | |
int | initialLubMin (void) const |
Return the initial minimum of the least upper bound. | |
int | initialLubMax (void) const |
Return the initial maximum of the least upper bound. | |
unsigned int | tableWidth (void) const |
Return the number of bdd variables allocated for this variable (initialLubMax-initialLubMin). | |
unsigned int | offset (void) const |
Return the offset in the global bdd table where the variable's domain starts. | |
bdd | element (int i) const |
Return bdd for the i -th element of this variable (counting from initialLubMin). | |
bdd | elementNeg (int i) const |
Return negated bdd for the i -th element of this variable (counting from initialLubMin). | |
bdd | dom (void) const |
Return the bdd representing the current domain. | |
Domain tests | |
GECODE_CPLTSET_EXPORT bool | assigned (void) |
Test whether variable is assigned. | |
GECODE_CPLTSET_EXPORT bool | knownIn (int i) const |
Test whether i is contained in the greatest lower bound. | |
GECODE_CPLTSET_EXPORT bool | knownOut (int i) const |
Test whether i is not contained in the least upper bound. | |
bool | range (void) const |
Test whether domain is a range. | |
Dependencies | |
void | subscribe (Space *home, Propagator *p, PropCond pc, bool process=true) |
Subscribe propagator p with propagation condition pc to variable. | |
void | cancel (Space *home, Propagator *p, PropCond pc) |
Cancel subscription of propagator p with propagation condition pc. | |
Cloning | |
CpltSetVarImp * | copy (Space *home, bool share) |
Return copy of this variable. | |
Reflection | |
GECODE_CPLTSET_EXPORT Reflection::Arg * | spec (const Space *home, Reflection::VarMap &m) const |
Delta information for advisors | |
static ModEvent | modevent (const Delta *d) |
Return modification event. | |
Public Member Functions | |
void | printdom (void) const |
GECODE_CPLTSET_EXPORT | CpltSetVarImp (Space *home, int glbMin, int glbMax, int lubMin, int lubMax, unsigned int cardMin, unsigned int cardMax) |
Construct variable with given domain. | |
GECODE_CPLTSET_EXPORT | CpltSetVarImp (Space *home, const IntSet &glbD, int lubMin, int lubMax, unsigned int cardMin, unsigned int cardMax) |
Construct variable with given domain. | |
GECODE_CPLTSET_EXPORT | CpltSetVarImp (Space *home, int glbMin, int glbMax, const IntSet &lubD, unsigned int cardMin, unsigned int cardMax) |
Construct variable with given domain. | |
GECODE_CPLTSET_EXPORT | CpltSetVarImp (Space *home, const IntSet &glbD, const IntSet &lubD, unsigned int cardMin, unsigned int cardMax) |
Construct variable with given domain. | |
GECODE_CPLTSET_EXPORT void | dispose (Space *home) |
Static Public Attributes | |
static const int | MAX_OF_EMPTY = Gecode::Set::Limits::min-1 |
Returned by empty sets when asked for their maximum element. | |
static const int | MIN_OF_EMPTY = Gecode::Set::Limits::max+1 |
Returned by empty sets when asked for their minimum element. | |
Protected Member Functions | |
GECODE_CPLTSET_EXPORT | CpltSetVarImp (Space *home, bool share, CpltSetVarImp &x) |
Constructor for cloning x. | |
template<class I> | |
bdd | iterToBdd (I &i) |
Produce bdd representing i for this variable. |
Constructor & Destructor Documentation
Gecode::CpltSet::CpltSetVarImp::CpltSetVarImp | ( | Space * | home, | |
bool | share, | |||
CpltSetVarImp & | x | |||
) | [protected] |
Gecode::CpltSet::CpltSetVarImp::CpltSetVarImp | ( | Space * | home, | |
int | glbMin, | |||
int | glbMax, | |||
int | lubMin, | |||
int | lubMax, | |||
unsigned int | cardMin, | |||
unsigned int | cardMax | |||
) |
Member Function Documentation
void Gecode::CpltSet::CpltSetVarImp::printdom | ( | void | ) | const [inline] |
Definition at line 41 of file cpltset.icc.
bdd Gecode::CpltSet::CpltSetVarImp::iterToBdd | ( | I & | i | ) | [inline, protected] |
void Gecode::CpltSet::CpltSetVarImp::dispose | ( | Space * | home | ) | [inline] |
Definition at line 188 of file cpltset.cc.
Restrict domain values to be different from singleton set .
Definition at line 150 of file cpltset.icc.
Restrict domain values to be different from set described by i.
Definition at line 154 of file cpltset.icc.
unsigned int Gecode::CpltSet::CpltSetVarImp::cardMin | ( | void | ) | const [inline] |
unsigned int Gecode::CpltSet::CpltSetVarImp::cardMax | ( | void | ) | const [inline] |
int Gecode::CpltSet::CpltSetVarImp::glbMin | ( | void | ) | const |
int Gecode::CpltSet::CpltSetVarImp::glbMax | ( | void | ) | const |
unsigned int Gecode::CpltSet::CpltSetVarImp::glbSize | ( | void | ) | const |
int Gecode::CpltSet::CpltSetVarImp::lubMin | ( | void | ) | const |
int Gecode::CpltSet::CpltSetVarImp::lubMax | ( | void | ) | const |
unsigned int Gecode::CpltSet::CpltSetVarImp::lubSize | ( | void | ) | const |
int Gecode::CpltSet::CpltSetVarImp::lubMinN | ( | int | n | ) | const |
int Gecode::CpltSet::CpltSetVarImp::lubMaxN | ( | int | n | ) | const [inline] |
int Gecode::CpltSet::CpltSetVarImp::unknownMin | ( | void | ) | const |
Return minimum of the difference between the greatest lower and the least upper bound.
Definition at line 440 of file cpltset.cc.
int Gecode::CpltSet::CpltSetVarImp::unknownMax | ( | void | ) | const |
Return maximum of the difference between the greatest lower and the least upper bound.
Definition at line 455 of file cpltset.cc.
unsigned int Gecode::CpltSet::CpltSetVarImp::unknownSize | ( | void | ) | const |
Return the size of the difference between the greatest lower and the least upper bound.
Definition at line 473 of file cpltset.cc.
int Gecode::CpltSet::CpltSetVarImp::initialLubMin | ( | void | ) | const [inline] |
int Gecode::CpltSet::CpltSetVarImp::initialLubMax | ( | void | ) | const [inline] |
unsigned int Gecode::CpltSet::CpltSetVarImp::tableWidth | ( | void | ) | const [inline] |
Return the number of bdd variables allocated for this variable (initialLubMax-initialLubMin).
Definition at line 46 of file cpltset.icc.
unsigned int Gecode::CpltSet::CpltSetVarImp::offset | ( | void | ) | const [inline] |
Return the offset in the global bdd table where the variable's domain starts.
Definition at line 65 of file cpltset.icc.
bdd Gecode::CpltSet::CpltSetVarImp::element | ( | int | i | ) | const [inline] |
Return bdd for the i -th element of this variable (counting from initialLubMin).
Definition at line 49 of file cpltset.icc.
bdd Gecode::CpltSet::CpltSetVarImp::elementNeg | ( | int | i | ) | const [inline] |
Return negated bdd for the i -th element of this variable (counting from initialLubMin).
Definition at line 54 of file cpltset.icc.
bdd Gecode::CpltSet::CpltSetVarImp::dom | ( | void | ) | const [inline] |
bool Gecode::CpltSet::CpltSetVarImp::assigned | ( | void | ) |
bool Gecode::CpltSet::CpltSetVarImp::knownIn | ( | int | i | ) | const |
bool Gecode::CpltSet::CpltSetVarImp::knownOut | ( | int | i | ) | const |
Test whether i is not contained in the least upper bound.
Definition at line 343 of file cpltset.cc.
bool Gecode::CpltSet::CpltSetVarImp::range | ( | void | ) | const [inline] |
void Gecode::CpltSet::CpltSetVarImp::subscribe | ( | Space * | home, | |
Propagator * | p, | |||
PropCond | pc, | |||
bool | process = true | |||
) | [inline] |
Subscribe propagator p with propagation condition pc to variable.
Definition at line 246 of file cpltset.icc.
void Gecode::CpltSet::CpltSetVarImp::cancel | ( | Space * | home, | |
Propagator * | p, | |||
PropCond | pc | |||
) | [inline] |
Cancel subscription of propagator p with propagation condition pc.
Definition at line 252 of file cpltset.icc.
CpltSetVarImp * Gecode::CpltSet::CpltSetVarImp::copy | ( | Space * | home, | |
bool | share | |||
) | [inline] |
Reflection::Arg * Gecode::CpltSet::CpltSetVarImp::spec | ( | const Space * | home, | |
Reflection::VarMap & | m | |||
) | const |
Definition at line 206 of file cpltset.cc.
Member Data Documentation
const int Gecode::CpltSet::CpltSetVarImp::MAX_OF_EMPTY = Gecode::Set::Limits::min-1 [static] |
Returned by empty sets when asked for their maximum element.
Definition at line 146 of file var-imp.icc.
const int Gecode::CpltSet::CpltSetVarImp::MIN_OF_EMPTY = Gecode::Set::Limits::max+1 [static] |
Returned by empty sets when asked for their minimum element.
Definition at line 148 of file var-imp.icc.
The documentation for this class was generated from the following files:
- gecode/cpltset/var-imp.icc (Revision: 6327)
- gecode/cpltset/var-imp/cpltset.cc (Revision: 6102)
- gecode/cpltset/var-imp/cpltset.icc (Revision: 6102)