Go to the documentation of this file.
38 namespace Test {
namespace Int {
41 namespace MiniModelCount {
60 class IntInt :
public Test {
68 :
Test(
"MiniModel::"+
expand(irt0)+
"::Int::Int",4,-2,2),
irt(irt0) {}
72 for (
int i=
x.size();
i--; )
99 :
Test(
"MiniModel::"+
expand(irt0)+
"::Int::Var",5,-2,2),
irt(irt0) {}
103 for (
int i=0;
i<4;
i++)
111 for (
int i=0;
i<4;
i++)
133 :
Test(
"MiniModel::"+
expand(irt0)+
"::Var::Var",5,-2,2),
irt(irt0) {}
137 for (
int i=0;
i<3;
i++)
145 for (
int i=0;
i<3;
i++)
167 :
Test(
"MiniModel::"+
expand(irt0)+
"::Var::Int",4,-2,2),
irt(irt0) {}
171 for (
int i=0;
i<3;
i++)
179 for (
int i=0;
i<3;
i++)
203 :
Test(
"MiniModel::"+
expand(irt0)+
"::IntArray::Int",5,-2,2),
208 for (
int i=0;
i<4;
i++)
216 for (
int i=0;
i<4;
i++)
238 :
Test(
"MiniModel::"+
expand(irt0)+
"::IntArray::Var",5,-2,2),
243 for (
int i=0;
i<4;
i++)
251 for (
int i=0;
i<4;
i++)
274 (void)
new IntInt(irts.irt());
275 (void)
new IntVar(irts.irt());
276 (void)
new VarVar(irts.irt());
277 (void)
new VarInt(irts.irt());
virtual void post(Gecode::Space &home, Gecode::IntVarArray &x)
Post constraint on x.
IntRelType
Relation types for integers.
Iterator for integer relation types.
Post propagator for SetVar SetOpType SetVar y
virtual bool solution(const Assignment &x) const
Test whether x is solution
VarVar(Gecode::IntRelType irt0)
Create and register test.
@ IRT_GQ
Greater or equal ( )
Test number of equal integers equal to integer
Passing integer variables.
void atleast(Home home, const IntVarArgs &x, int n, int m, IntPropLevel ipl)
Post constraint .
IntArrayInt(Gecode::IntRelType irt0)
Create and register test.
void exactly(Home home, const IntVarArgs &x, int n, int m, IntPropLevel ipl)
Post constraint .
Gecode::IntArgs ints({1, 0, 3, 2})
Gecode::IntRelType irt
Integer relation type to propagate.
static bool cmp(T x, Gecode::IntRelType r, T y)
Compare x and y with respect to r.
std::string expand(Gecode::IntRelType irt)
Expand relation to abbreviation.
void atmost(Home home, const IntVarArgs &x, int n, int m, IntPropLevel ipl)
Post constraint .
IntInt(Gecode::IntRelType irt0)
Create and register test.
virtual bool solution(const Assignment &x) const
Test whether x is solution
virtual void post(Gecode::Space &home, Gecode::IntVarArray &x)
Post constraint on x.
Test number of equal integers equal to integer variable
virtual bool solution(const Assignment &x) const
Test whether x is solution
Gecode::IntRelType irt
Integer relation type to propagate.
Node * x
Pointer to corresponding Boolean expression node.
Gecode::IntRelType irt
Integer relation type to propagate.
VarInt(Gecode::IntRelType irt0)
Create and register test.
virtual bool solution(const Assignment &x) const
Test whether x is solution
virtual void post(Gecode::Space &home, Gecode::IntVarArray &x)
Post constraint on x.
Test number of equal variables equal to integer
virtual void post(Gecode::Space &home, Gecode::IntVarArray &x)
Post constraint on x.
Gecode::IntRelType irt
Integer relation type to propagate.
#define GECODE_NEVER
Assert that this command is never executed.
Test number of equal variables equal to integer variable
Base class for assignments
Help class to create and register tests.
IntArrayVar(Gecode::IntRelType irt0)
Create and register test.
Test number of several equal integers equal to integer variable
virtual bool solution(const Assignment &x) const
Test whether x is solution
virtual void post(Gecode::Space &home, Gecode::IntVarArray &x)
Post constraint on x.
Gecode::IntRelType irt
Integer relation type to propagate.
Gecode::IntRelType irt
Integer relation type to propagate.
Passing integer arguments.
Test number of several equal integers equal to integer
Gecode::IntArgs i({1, 2, 3, 4})
virtual bool solution(const Assignment &x) const
Test whether x is solution
virtual void post(Gecode::Space &home, Gecode::IntVarArray &x)
Post constraint on x.
Create(void)
Perform creation and registration.
@ IRT_LQ
Less or equal ( )
IntVar(Gecode::IntRelType irt0)
Create and register test.