40 #ifndef __GECODE_TEST_SET_HH__ 41 #define __GECODE_TEST_SET_HH__ 86 : dv(d0), cur(cur0), i(1) {
107 }
while (! (i & cur) && i<cur);
152 void operator++(
void);
178 void operator++(
void);
181 assert((i>=0) && (i<n));
298 :
Base(
"Set::"+s), arity(a), lub(d), reified(
r), withInt(w) {}
308 virtual bool run(
void);
317 static std::string str(
int i);
337 void operator++(
void);
355 void operator++(
void);
virtual void post(Gecode::Space &, Gecode::SetVarArray &, Gecode::IntVarArray &, Gecode::Reify)
Post reified propagator.
Iterator for Boolean operation types.
CountableSetRanges(const Gecode::IntSet &d, int cur)
Initialize with set d0 and bit-pattern cur0.
SetRelType
Common relation types for sets.
int size(void) const
Return arity.
Iterator for set relation types.
void operator++(void)
Move to next value.
Gecode::Reify r
Reification information.
void post(Home home, Term *t, int n, FloatRelType frt, FloatVal c)
Post propagator for linear constraint over floats.
void log(Home home, FloatVar x0, FloatVar x1)
Post propagator for .
Gecode::SetVarArray x
Set variables to be tested.
int val(void) const
Return current subset.
bool operator()(void) const
Test whether all assignments have been iterated.
CountableSet(void)
Default constructor.
SetOpType
Common operations for sets.
CountableSetRanges(void)
Default constructor.
int operator[](int i) const
Return value for variable i.
ExecStatus prune(Space &home, ViewArray< VX > &x, ConstIntView)
SetTest(const std::string &s, int a, const Gecode::IntSet &d, bool r=false, int w=0)
Constructor.
bool failed(void) const
Check whether space is failed.
void init(const Gecode::IntSet &d, int cur)
Initialize with set d0 and bit-pattern cur0.
bool reified
Whether the test is for a reified propagator.
Gecode::IntArgs i(4, 1, 2, 3, 4)
int n
Number of negative literals for node type.
bool operator()(void) const
Check if still subsets left.
IntRelType
Relation types for integers.
const Test::Int::Assignment & ints(void) const
Return assignment for integer variables.
void init(I &i)
Initialize with value iterator i.
Range iterator from value iterator.
Reification specification.
Base class for all tests to be run
struct Gecode::@519::NNF::@60::@62 a
For atomic nodes.
Gecode::IntSet lub
The common superset for all domains.
int val(void) const
Return current value.
CountableSetValues(void)
Default constructor.
Value iterator producing subsets of an IntSet.
Passing integer arguments.
std::basic_ostream< Char, Traits > & operator<<(std::basic_ostream< Char, Traits > &os, const Dictionary &d)
Print statistics summary.
virtual Gecode::Space * copy(bool share)
Faked copy function.
Gecode::IntSet d
Initial domain.
LinIntExpr cardinality(const SetExpr &e)
Cardinality of set expression.
int intval(void) const
Return value for first integer variable.
int withInt
How many integer variables to iterate.
BrancherHandle assign(Home home, const FloatVarArgs &x, FloatAssign fa, FloatBranchFilter bf, FloatVarValPrint vvp)
Assign all x with value selection vals.
FakeSpace(void)
Faked constructor.
bool operator()(void) const
Test if finished.
Node * x
Pointer to corresponding Boolean expression node.
Home operator()(Propagator &p)
Return a home for this space with the information that p is being rewritten.
Base class for tests with set constraints
Generate all set assignments.
Base class for assignments
bool assigned(View x, int v)
Whether x is assigned to value v.
void rel(Home home, FloatVar x0, FloatRelType frt, FloatVal n)
Propagates .
Gecode::IntVarArray y
Int variables to be tested.
~SetAssignment(void)
Destructor.
Value iterator for integer sets.
Range iterator producing subsets of an IntSet.
int withInt
How many integer variables are used by the test.
CountableSetValues(const Gecode::IntSet &d0, int cur0)
Initialize with set d0 and bit-pattern cur0.
int val(void) const
Return current value.
void init(const Gecode::IntSet &d0, int cur0)
Initialize with set d0 and bit-pattern cur0.
SetTest * test
The test currently run.
Space for executing set tests.
Iterate all subsets of a given set.
ReifyMode
Mode for reification.
Generate all assignments.