Go to the documentation of this file.
42 namespace Test {
namespace Set {
45 namespace RelOpConst {
67 template<
class I,
class J>
69 sol(I&
i, J& j)
const {
93 int intSet,
bool inverse0)
94 :
SetTest(
"RelOp::ConstSIS::"+str(sot0)+
"::"+str(srt0)+
"::"+
95 str(intSet)+(inverse0 ?
"i" :
""),2,ds_22,false)
96 , is(iss[intSet]), sot(sot0), srt(srt0), inverse(inverse0) {}
162 template<
class I,
class J>
164 sol(I&
i, J& j)
const {
189 :
SetTest(
"RelOp::ConstSSI::"+str(sot0)+
"::"+str(srt0)+
"::"+
190 str(intSet),2,ds_22,false)
191 , is(iss[intSet]), sot(sot0), srt(srt0) {}
249 template<
class I,
class J>
251 sol(I&
i, J& j)
const {
275 int intSet0,
int intSet1,
bool inverse0)
276 :
SetTest(
"RelOp::ConstISI::"+str(sot0)+
"::"+str(srt0)+
"::"+
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) {}
346 for (
int i=0;
i<=2;
i++) {
347 (void)
new RelSIS(sots.sot(),srts.srt(),
i,
false);
348 (void)
new RelSIS(sots.sot(),srts.srt(),
i,
true);
349 (void)
new RelSSI(sots.sot(),srts.srt(),
i);
350 (void)
new RelISI(sots.sot(),srts.srt(),
i,0,
false);
351 (void)
new RelISI(sots.sot(),srts.srt(),
i,1,
false);
352 (void)
new RelISI(sots.sot(),srts.srt(),
i,2,
false);
353 (void)
new RelISI(sots.sot(),srts.srt(),
i,0,
true);
354 (void)
new RelISI(sots.sot(),srts.srt(),
i,1,
true);
355 (void)
new RelISI(sots.sot(),srts.srt(),
i,2,
true);
Post propagator for SetVar x
bool solution(const SetAssignment &x) const
Test whether x is solution
Gecode::IntArgs i(4, 1, 2, 3, 4)
bool solution(const SetAssignment &x) const
Test whether x is solution
RelISI(Gecode::SetOpType sot0, Gecode::SetRelType srt0, int intSet0, int intSet1, bool inverse0)
Create and register test.
SetOpType
Common operations for sets.
bool subset(I &i, J &j)
Check whether range iterator i is subset of range iterator j.
void post(Space &home, SetVarArray &x, IntVarArray &)
Post constraint on x.
union Gecode::@579::NNF::@61 u
Union depending on nodetype t.
Range iterator for integer sets.
Generate all set assignments.
void post(Space &home, SetVarArray &x, IntVarArray &)
Post constraint on x.
Gecode toplevel namespace
A complement iterator spezialized for the BndSet limits.
Range iterator for computing intersection (binary)
RelSSI(Gecode::SetOpType sot0, Gecode::SetRelType srt0, int intSet)
Create and register test.
Range iterator for computing set difference.
bool solution(const SetAssignment &x) const
Test whether x is solution
Base class for tests with set constraints
bool equal(I &i, J &j)
Check whether range iterators i and j are equal.
SetRelType
Common relation types for sets.
Iterator for Boolean operation types.
#define GECODE_NEVER
Assert that this command is never executed.
Iterator for set relation types.
Create(void)
Perform creation and registration.
Range iterator for computing union (binary)
Test for set relation constraint with constants
@ SOT_DUNION
Disjoint union.
Test for set relation constraint with constants
void rel(Home home, FloatVar x0, FloatRelType frt, FloatVal n)
Propagates .
void post(Space &home, SetVarArray &x, IntVarArray &)
Post constraint on x.
Range iterator producing subsets of an IntSet.
Test for set relation constraint with constants
Help class to create and register tests.
RelSIS(Gecode::SetOpType sot0, Gecode::SetRelType srt0, int intSet, bool inverse0)
Create and register test.
SetExpr inter(const SetVarArgs &x)
Intersection of set variables.