100 if (home.
failed())
return;
102 for (
int i=x.
size();
i--; )
117 if (home.
failed())
return;
130 if (home.
failed())
return;
135 t[0].a = 1;
t[0].x = prod;
136 t[1].a = 1;
t[1].x = x3;
142 t[2].a=-1;
t[2].x=x0;
144 if (home.
failed())
return;
154 if (home.
failed())
return;
163 if (home.
failed())
return;
165 divmod(home, x0, x1, _div, x2, icl);
171 if (home.
failed())
return;
175 ::
post(home,x0,x1,ops));
178 ::
post(home,x0,x1,ops));
185 if (home.
failed())
return;
189 ::
post(home,x0,x1,ops));
192 ::
post(home,x0,x1,ops));
200 if (home.
failed())
return;
202 sqr(home, x0, x1, icl);
208 ::
post(home,x0,x1,ops));
211 ::
post(home,x0,x1,ops));
219 if (home.
failed())
return;
221 sqrt(home, x0, x1, icl);
227 ::
post(home,x0,x1,ops));
230 ::
post(home,x0,x1,ops));
bool failed(void) const
Check whether corresponding space is failed.
Integer division/modulo propagator.
IntConLevel
Consistency levels for integer propagators.
void mult(Home home, FloatVar x0, FloatVar x1, FloatVar x2)
Post propagator for .
void mod(Home home, IntVar x0, IntVar x1, IntVar x2, IntConLevel icl)
Post propagator for .
void post(Home home, Term *t, int n, FloatRelType frt, FloatVal c)
Post propagator for linear constraint over floats.
Domain consistent ternary maximum propagator.
Domain consistent n-th root propagator.
int size(void) const
Return size of array (number of elements)
void post(Home home, Term< BoolView > *t, int n, IntRelType irt, IntView x, int c, IntConLevel)
Post propagator for linear constraint over Booleans.
Domain consistent n-ary maximum propagator.
void max(Home home, FloatVar x0, FloatVar x1, FloatVar x2)
Post propagator for .
void abs(Home home, FloatVar x0, FloatVar x1)
Post propagator for .
void nroot(Home home, FloatVar x0, int n, FloatVar x1)
Post propagator for for $n 0$.
void pow(Home home, FloatVar x0, int n, FloatVar x1)
Post propagator for for $n 0$.
Exception: Too few arguments available in argument array
void nonnegative(int n, const char *l)
Check whether n is in range and nonnegative, otherwise throw out of limits with information l...
Bounds consistent power propagator.
static ExecStatus post(Home home, IntView x0, IntView x1, IntView x2)
Post propagator .
const int max
Largest allowed integer value.
const int min
Smallest allowed integer value.
Bounds consistent absolute value propagator.
Gecode::IntArgs i(4, 1, 2, 3, 4)
int n
Number of negative literals for node type.
Domain consistent absolute value propagator.
ModEvent lq(Space &home, int n)
Restrict domain values to be less or equal than n.
void sqr(Home home, FloatVar x0, FloatVar x1)
Post propagator for .
void sqrt(Home home, FloatVar x0, FloatVar x1)
Post propagator for .
Operations for square and square-root propagators.
Bounds consistent n-ary maximum propagator.
Passing integer variables.
Bounds consistent division propagator.
void divmod(Home home, IntVar x0, IntVar x1, IntVar x2, IntVar x3, IntConLevel)
Post propagator for .
Domain consistent power propagator.
void min(Home home, FloatVar x0, FloatVar x1, FloatVar x2)
Post propagator for .
Integer view for integer variables.
void div(Home home, FloatVar x0, FloatVar x1, FloatVar x2)
Post propagator for .
Node * x
Pointer to corresponding Boolean expression node.
static ExecStatus post(Home home, IntView x0, IntView x1, IntView x2)
Post propagator .
Operations for power and nroot propagators.
Bounds consistent ternary maximum propagator.
void estimate(Term< View > *t, int n, int c, int &l, int &u)
Estimate lower and upper bounds.
ModEvent gq(Space &home, int n)
Restrict domain values to be greater or equal than n.
#define GECODE_ME_FAIL(me)
Check whether modification event me is failed, and fail space home.
Class for describing linear term .
Home class for posting propagators
#define GECODE_ES_FAIL(es)
Check whether execution status es is failed, and fail space home.
Bounds consistent n-th root propagator.
void positive(int n, const char *l)
Check whether n is in range and strictly positive, otherwise throw out of limits with information l...
Domain propagation or consistency.