Go to the documentation of this file.
42 namespace Test {
namespace Int {
66 class BinXYZ :
public Test {
74 :
Test(
"Bool::Bin::XYZ::"+
str(op0),3,0,1),
op(op0) {}
96 :
Test(
"Bool::Bin::XXY::"+
str(op0),2,0,1),
op(op0) {}
117 :
Test(
"Bool::Bin::XYX::"+
str(op0),2,0,1),
op(op0) {}
138 :
Test(
"Bool::Bin::XYY::"+
str(op0),2,0,1),
op(op0) {}
159 :
Test(
"Bool::Bin::XXX::"+
str(op0),1,0,1),
op(op0) {}
182 :
Test(
"Bool::Bin::XY::"+
str(op0)+
"::"+
str(c0),2,0,1),
205 :
Test(
"Bool::Bin::XX::"+
str(op0)+
"::"+
str(c0),1,0,1),
232 for (
int i=0;
i<
n-2;
i++)
240 for (
int i=
x.size()-1;
i--; )
254 :
Test(
"Bool::Nary::Shared::"+
str(op0)+
"::"+
str(
n),
n,0,1),
263 for (
int i=0;
i<
n-2;
i++)
271 for (
int i=
x.size();
i--; )
293 for (
int i=0;
i<
n-2;
i++)
301 for (
int i=
x.size();
i--; )
316 :
Test(
"Bool::Clause::XYZ::"+
str(op0)+
"::"+
str(
n),
n+1,0,1),
op(op0) {}
319 int n = (
x.size()-1) / 2;
325 for (
int i=1;
i<
n;
i++)
328 return b ==
x[
x.size()-1];
333 int n = (
x.size()-1) / 2;
335 for (
int i=
n;
i--; ) {
351 :
Test(
"Bool::Clause::XXYYX::"+
str(op0)+
"::"+
str(
n),
n,0,1),
355 int n =
x.size() / 2;
361 for (
int i=1;
i<
n;
i++)
369 int n =
x.size() / 2;
371 for (
int i=
n;
i--; ) {
387 :
Test(
"Bool::Clause::XXY::"+
str(op0)+
"::"+
str(
n),
n,0,1),
396 int n =
x.size() / 2;
398 for (
int i=
n;
i--; ) {
420 int n =
x.size() / 2;
426 for (
int i=1;
i<
n;
i++)
434 int n =
x.size() / 2;
436 for (
int i=
n;
i--; ) {
452 if ((
x[0] < 0) || (
x[0] > 1))
474 :
Test(
"ITE::Bool",4,0,1,false) {}
497 (void)
new BinXYZ(bots.bot());
498 (void)
new BinXXY(bots.bot());
499 (void)
new BinXYX(bots.bot());
500 (void)
new BinXYY(bots.bot());
501 (void)
new BinXXX(bots.bot());
506 (void)
new Nary(bots.bot(),2);
507 (void)
new Nary(bots.bot(),6);
508 (void)
new Nary(bots.bot(),10);
Test for binary Boolean operation with shared variables and constant
BinConstXX(Gecode::BoolOpType op0, int c0)
Construct and register test.
virtual bool solution(const Assignment &x) const
Check whether x is solution.
ITEBool(void)
Construct and register test.
Test for Nary Boolean operation
virtual bool solution(const Assignment &x) const
Check whether x is solution.
int check(int x0, Gecode::BoolOpType op, int x1)
ClauseXXY(Gecode::BoolOpType op0, int n)
Construct and register test.
virtual void post(Gecode::Space &home, Gecode::IntVarArray &x)
Post constraint.
Gecode::BoolOpType op
Boolean operation type for test.
Gecode::IntPropLevel ipl
Propagation level.
virtual void post(Gecode::Space &home, Gecode::IntVarArray &x)
Post constraint.
virtual bool solution(const Assignment &x) const
Check whether x is solution.
virtual bool solution(const Assignment &x) const
Check whether x is solution.
ClauseXXYYX(Gecode::BoolOpType op0, int n)
Construct and register test.
Gecode::IntArgs i(4, 1, 2, 3, 4)
virtual void post(Gecode::Space &home, Gecode::IntVarArray &x)
Post constraint.
BinXYX(Gecode::BoolOpType op0)
Construct and register test.
Help class to create and register tests.
virtual bool solution(const Assignment &x) const
Check whether x is solution.
IntPropLevel
Propagation levels for integer propagators.
Test for binary Boolean operation with shared variables
Gecode::BoolOpType op
Boolean operation type for test.
Test for binary Boolean operation with shared variables
virtual bool solution(const Assignment &x) const
Check whether x is solution.
static Gecode::Support::RandomGenerator rand
Random number generator.
Create(void)
Perform creation and registration.
virtual bool solution(const Assignment &x) const
Check whether x is solution.
Gecode::BoolOpType op
Boolean operation type for test.
Test for Clause Boolean operation with constant
void rel(Home home, BoolOpType o, const BoolVarArgs &x, int n, IntPropLevel)
Post domain consistent propagator for Boolean operation on x.
BinXYZ(Gecode::BoolOpType op0)
Construct and register test.
Test for binary Boolean operation with constant
Test for Clause Boolean operation
Gecode toplevel namespace
bool testfix
Whether to perform fixpoint test.
virtual void post(Gecode::Space &home, Gecode::IntVarArray &x)
Post constraint.
Iterator for Boolean operation types.
ITEInt itedom(Gecode::IPL_DOM)
virtual bool solution(const Assignment &x) const
Check whether x is solution.
virtual void post(Gecode::Space &home, Gecode::IntVarArray &x)
Post constraint.
Test for Nary Boolean operation
Node * x
Pointer to corresponding Boolean expression node.
BoolOpType
Operation types for Booleans.
Gecode::BoolOpType op
Boolean operation type for test.
ITEInt itebnd(Gecode::IPL_BND)
NaryShared(Gecode::BoolOpType op0, int n)
Construct and register test.
Passing Boolean variables.
struct Gecode::@579::NNF::@61::@63 a
For atomic nodes.
virtual bool solution(const Assignment &x) const
Check whether x is solution.
struct Gecode::@579::NNF::@61::@62 b
For binary nodes (and, or, eqv)
Test for if-then-else-constraint
BinXYY(Gecode::BoolOpType op0)
Construct and register test.
Gecode::BoolOpType op
Boolean operation type for test.
virtual void post(Gecode::Space &home, Gecode::IntVarArray &x)
Post constraint.
Boolean integer variables.
@ IPL_DOM
Domain propagation Preferences: prefer speed or memory.
BinXXY(Gecode::BoolOpType op0)
Construct and register test.
Gecode::BoolOpType op
Boolean operation type for test.
Gecode::BoolOpType op
Boolean operation type for test.
Test for if-then-else-constraint
ClauseXYZ(Gecode::BoolOpType op0, int n)
Construct and register test.
virtual void post(Gecode::Space &home, Gecode::IntVarArray &x)
Post constraint.
ITEInt(Gecode::IntPropLevel ipl)
Construct and register test.
virtual void post(Gecode::Space &home, Gecode::IntVarArray &x)
Post constraint.
virtual void post(Gecode::Space &home, Gecode::IntVarArray &x)
Post constraint.
Test for binary Boolean operation with shared variables
@ IPL_BND
Bounds propagation.
#define GECODE_NEVER
Assert that this command is never executed.
Nary(Gecode::BoolOpType op0, int n)
Construct and register test.
virtual void post(Gecode::Space &home, Gecode::IntVarArray &x)
Post constraint.
Base class for assignments
virtual void post(Gecode::Space &home, Gecode::IntVarArray &x)
Post constraint.
virtual bool solution(const Assignment &x) const
Check whether x is solution.
Gecode::BoolOpType op
Boolean operation type for test.
Gecode::BoolOpType op
Boolean operation type for test.
virtual void post(Gecode::Space &home, Gecode::IntVarArray &x)
Post constraint.
void channel(Home home, FloatVar x0, IntVar x1)
Post propagator for channeling a float and an integer variable .
Gecode::BoolOpType op
Boolean operation type for test.
Gecode::BoolOpType op
Boolean operation type for test.
virtual void post(Gecode::Space &home, Gecode::IntVarArray &x)
Post constraint.
virtual bool solution(const Assignment &x) const
Check whether x is solution.
BinXXX(Gecode::BoolOpType op0)
Construct and register test.
Gecode::BoolOpType op
Boolean operation type for test.
Gecode::BoolOpType op
Boolean operation type for test.
Test for Nary Boolean operation with constant
virtual bool solution(const Assignment &x) const
Check whether x is solution.
virtual bool solution(const Assignment &x) const
Check whether x is solution.
Post propagator for SetVar SetOpType op
virtual void post(Gecode::Space &home, Gecode::IntVarArray &x)
Post constraint.
void ite(Home home, BoolVar b, SetVar x, SetVar y, SetVar z)
Post propagator for if-then-else constraint.
virtual bool solution(const Assignment &x) const
Check whether x is solution.
ClauseConst(Gecode::BoolOpType op0, int n, int c0)
Construct and register test.
void clause(Home home, BoolOpType o, const BoolVarArgs &x, const BoolVarArgs &y, BoolVar z, IntPropLevel)
Post domain consistent propagator for Boolean clause with positive variables x and negative variables...
virtual bool solution(const Assignment &x) const
Check whether x is solution.
NaryConst(Gecode::BoolOpType op0, int n, int c0)
Construct and register test.
int n
Number of negative literals for node type.
Test for binary Boolean operation with shared variables
Test for Clause Boolean operation
Test for Clause Boolean operation
BinConstXY(Gecode::BoolOpType op0, int c0)
Construct and register test.
virtual void post(Gecode::Space &home, Gecode::IntVarArray &x)
Post constraint.
Gecode::BoolOpType op
Boolean operation type for test.
virtual void post(Gecode::Space &home, Gecode::IntVarArray &x)
Post constraint.
static std::string str(Gecode::IntPropLevel ipl)
Map integer propagation level to string.
virtual bool solution(const Assignment &x) const
Check whether x is solution.