63 template<
class I,
class J>
65 sol(I& i, J& j)
const {
89 int intSet,
bool inverse0)
91 str(intSet)+(inverse0 ?
"i" :
""),2,ds_22,false)
92 , is(iss[intSet]), sot(sot0), srt(srt0), inverse(inverse0) {}
159 template<
class I,
class J>
161 sol(I& i, J& j)
const {
188 str(intSet),2,ds_22,false)
189 , is(iss[intSet]), sot(sot0), srt(srt0) {}
248 template<
class I,
class J>
250 sol(I& i, J& j)
const {
275 int intSet0,
int intSet1,
bool inverse0)
277 str(intSet0)+
"::"+
str(intSet1)+
278 (inverse0 ?
"i" :
""),1,ds_33,false)
279 , is0(iss[intSet0]), is1(iss[intSet1]), sot(sot0), srt(srt0)
280 , inverse(inverse0) {}
347 for (
int i=0; i<=2; i++) {
348 (void)
new RelSIS(sots.sot(),srts.srt(),i,
false);
349 (void)
new RelSIS(sots.sot(),srts.srt(),i,
true);
350 (void)
new RelSSI(sots.sot(),srts.srt(),i);
351 (void)
new RelISI(sots.sot(),srts.srt(),i,0,
false);
352 (void)
new RelISI(sots.sot(),srts.srt(),i,1,
false);
353 (void)
new RelISI(sots.sot(),srts.srt(),i,2,
false);
354 (void)
new RelISI(sots.sot(),srts.srt(),i,0,
true);
355 (void)
new RelISI(sots.sot(),srts.srt(),i,1,
true);
356 (void)
new RelISI(sots.sot(),srts.srt(),i,2,
true);
Range iterator for integer sets.
Range iterator for computing set difference.
Range iterator for computing intersection (binary)
Range iterator for computing union (binary)
A complement iterator spezialized for the BndSet limits.
Range iterator producing subsets of an IntSet.
Help class to create and register tests.
Create(void)
Perform creation and registration.
Test for set relation constraint with constants
RelISI(Gecode::SetOpType sot0, Gecode::SetRelType srt0, int intSet0, int intSet1, bool inverse0)
Create and register test.
bool solution(const SetAssignment &x) const
Test whether x is solution
void post(Space &home, SetVarArray &x, IntVarArray &)
Post constraint on x.
Test for set relation constraint with constants
RelSIS(Gecode::SetOpType sot0, Gecode::SetRelType srt0, int intSet, bool inverse0)
Create and register test.
bool solution(const SetAssignment &x) const
Test whether x is solution
void post(Space &home, SetVarArray &x, IntVarArray &)
Post constraint on x.
Test for set relation constraint with constants
bool solution(const SetAssignment &x) const
Test whether x is solution
RelSSI(Gecode::SetOpType sot0, Gecode::SetRelType srt0, int intSet)
Create and register test.
void post(Space &home, SetVarArray &x, IntVarArray &)
Post constraint on x.
Generate all set assignments.
Iterator for Boolean operation types.
Iterator for set relation types.
static std::string str(Gecode::SetRelType srt)
Map set relation to string.
SetTest(const std::string &s, int a, const Gecode::IntSet &d, bool r=false, int w=0)
Constructor.
void rel(Home home, FloatVar x0, FloatRelType frt, FloatVar x1)
Post propagator for .
SetOpType
Common operations for sets.
SetRelType
Common relation types for sets.
@ SOT_DUNION
Disjoint union.
bool subset(I &i, J &j)
Check whether range iterator i is subset of range iterator j.
bool equal(I &i, J &j)
Check whether range iterators i and j are equal.
Gecode toplevel namespace
SetExpr inter(const SetVarArgs &)
Intersection of set variables.
Post propagator for SetVar x
Tests for relation/operation constraints with constants
#define GECODE_NEVER
Assert that this command is never executed.