Go to the documentation of this file.
42 namespace Test {
namespace Int {
62 xoff(xoff0), yoff(yoff0) {
67 for (
int i=0;
i<4;
i++)
76 for (
int i=4;
i--; ) {
78 IntVar xo(home, xoff, 3+xoff);
85 IntVar yo(home, yoff, 3+yoff);
106 for (
int i=0;
i<6;
i++)
107 for (
int j=
i+1; j<6; j++)
116 for (
int i=0;
i<6;
i++)
117 for (
int j=0; j<6; j++) {
136 for (
int i=0;
i<6;
i++)
153 :
Test(
"Channel::Bool::Single",2,-1,2) {
158 return ((
x[0]==0) || (
x[0]==1)) && (
x[0]==
x[1]);
176 :
Test(
"Channel::Bool::Multi::"+s,7,
min,
max), o(o0) {
182 if ((
x[
i] != 0) && (
x[
i] != 1))
187 for (
int i=0;
i<k;
i++)
190 for (
int i=k+1;
i<
n;
i++)
ChannelLinkSingle(void)
Construct and register test.
virtual void post(Gecode::Space &home, Gecode::IntVarArray &x)
Post constraint on x.
ChannelLinkMulti clmb("B", 1, 6, 1)
Post propagator for SetVar SetOpType SetVar y
ChannelFull cfd35(3, 5, Gecode::IPL_DOM)
ConTestLevel contest
Whether to test for certain consistency.
virtual void post(Gecode::Space &home, Gecode::IntVarArray &x)
Post constraint on x.
virtual bool solution(const Assignment &x) const
Check whether x is solution.
Gecode::IntPropLevel ipl
Propagation level.
Passing integer variables.
ChannelShared(Gecode::IntPropLevel ipl)
Construct and register test.
@ CTL_NONE
No consistency-test.
Gecode::IntArgs i(4, 1, 2, 3, 4)
Test channel between integer and Boolean variable
@ IPL_VAL
Value propagation.
const FloatNum min
Smallest allowed float value.
IntPropLevel
Propagation levels for integer propagators.
ChannelShared csd(Gecode::IPL_DOM)
Simple test for channel (testing single set of variables)
virtual bool solution(const Assignment &x) const
Check whether x is solution.
ChannelFull cfd11(1, 1, Gecode::IPL_DOM)
Gecode toplevel namespace
ChannelHalf chd(Gecode::IPL_DOM)
Node * x
Pointer to corresponding Boolean expression node.
virtual void post(Gecode::Space &home, Gecode::IntVarArray &x)
Post constraint on x.
Passing Boolean variables.
struct Gecode::@579::NNF::@61::@62 b
For binary nodes (and, or, eqv)
ChannelLinkMulti clmc("C",-1, 4,-1)
ChannelLinkMulti(const std::string &s, int min, int max, int o0)
Construct and register test.
Boolean integer variables.
@ IPL_DOM
Domain propagation Preferences: prefer speed or memory.
Simple test for channel (testing all variables)
virtual bool solution(const Assignment &x) const
Check whether x is solution.
ChannelFull cfv35(3, 5, Gecode::IPL_VAL)
Test channel with shared variables
ChannelFull cfv11(1, 1, Gecode::IPL_VAL)
ChannelHalf chv(Gecode::IPL_VAL)
ChannelShared csv(Gecode::IPL_VAL)
Base class for assignments
ChannelHalf(Gecode::IntPropLevel ipl)
Construct and register test.
void rel(Home home, FloatVar x0, FloatRelType frt, FloatVal n)
Propagates .
Test channel between integer variable and array of Boolean variables
virtual bool solution(const Assignment &x) const
Check whether x is solution.
virtual void post(Gecode::Space &home, Gecode::IntVarArray &x)
Post constraint on x.
ChannelFull(int xoff0, int yoff0, Gecode::IntPropLevel ipl)
Construct and register test.
ChannelFull cfd(0, 0, 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 on x.
int n
Number of negative literals for node type.
const FloatNum max
Largest allowed float value.
ChannelLinkMulti clma("A", 0, 5, 0)
ChannelFull cfv(0, 0, Gecode::IPL_VAL)
void channel(Home home, const SetVarArgs &x, const SetVarArgs &y)
Gecode::IntSet dom
Domain of variables.
static std::string str(Gecode::IntPropLevel ipl)
Map integer propagation level to string.