Go to the documentation of this file.
36 namespace Gecode {
namespace Int {
namespace Arithmetic {
101 View x0, View x1, View x2)
114 if ((x0.max() <= x1.min()) || (x0.max() < x2.min()))
116 if ((x1.max() <= x0.min()) || (x1.max() < x2.min()))
118 return x0.assigned() && x1.assigned() && x2.assigned() ?
135 assert(
x.size() > 0);
143 for (
int i=1;
i<
x.size();
i++) {
151 for (
int i=0;
i<
x.size();
i++)
186 assert(
x.size() > 0);
187 int maxmax =
x[0].max();
188 int maxmin =
x[0].min();
189 for (
int i=1;
i<
x.size();
i++) {
198 for (
int i=
x.size();
i--; ) {
204 if (
x[
i].
max() < maxmin) {
205 x.move_lst(
i,home,
p,pc);
263 View x0, View x1, View x2)
284 if ((x0.max() <= x1.min()) || (x0.max() < x2.min()))
286 if ((x1.max() <= x0.min()) || (x1.max() < x2.min()))
288 return x0.assigned() && x1.assigned() && x2.assigned() ?
319 assert(
x.size() > 0);
327 for (
int i=0;
i<
x.size();
i++) {
335 for (
int i=0;
i<
x.size();
i++)
379 for (
int i=0;
i<
x.size();
i++) {
384 for (
int i =
x.size();
i--; )
389 assert(
x.size() > 0);
Post propagator for SetVar x
Post propagator for SetVar SetOpType SetVar y
Less or equal propagator.
bool me_failed(ModEvent me)
Check whether modification event me is failed.
void max(Home home, FloatVar x0, FloatVar x1, FloatVar x2)
Post propagator for .
ExecStatus ES_SUBSUMED(Propagator &p)
const Gecode::ModEvent ME_INT_FAILED
Domain operation has resulted in failure.
virtual Actor * copy(Space &home)
Copy propagator during cloning.
virtual ExecStatus propagate(Space &home, const ModEventDelta &med)
Perform propagation.
MaxPropStatus
Status of propagation for nary max.
bool assigned(View x, int v)
Whether x is assigned to value v.
ExecStatus prop_nary_max_bnd(Space &home, Propagator &p, ViewArray< View > &x, View y, PropCond pc)
static ExecStatus post(Home home, View0 x0, View1 x1)
Post domain consistent propagator .
static PropCost linear(PropCost::Mod m, unsigned int n)
Linear complexity for modifier pcm and size measure n.
ExecStatus ES_NOFIX_PARTIAL(Propagator &p, const ModEventDelta &med)
Propagator p has not computed partial fixpoint
virtual Actor * copy(Space &home)
Copy propagator during cloning.
Base-class for both propagators and branchers.
static ExecStatus post(Home home, V0 x0, V1 x1)
Post propagator .
bool assigned(void) const
Test whether view is assigned.
static ExecStatus post(Home home, ViewArray< View > &x, View y)
Post propagator .
static ExecStatus post(Home home, View x0, View x1, View x2)
Post propagator .
RelTest rtest_nq_dom(VX x, VY y)
Test whether views x and y are different (use full domain information)
union Gecode::@602::NNF::@65 u
Union depending on nodetype t.
Gecode toplevel namespace
Base-class for propagators.
static ExecStatus post(Home home, View x0, View x1, View x2)
Post propagator .
Range iterator for integer views.
static ExecStatus post(Home home, View0 x0, View1 x1)
Post bounds consistent propagator .
Binary domain consistent equality propagator.
#define GECODE_ES_CHECK(es)
Check whether execution status es is failed or subsumed, and forward failure or subsumption.
Home class for posting propagators
Telling has found a new upper bound.
Domain consistent n-ary maximum propagator.
Bounds consistent ternary maximum propagator.
Post propagator for SetVar SetOpType SetVar SetRelType r
virtual ExecStatus propagate(Space &home, const ModEventDelta &med)
Perform propagation.
MaxDom(Space &home, MaxDom &p)
Constructor for cloning p.
Domain consistent ternary maximum propagator.
virtual Actor * copy(Space &home)
Copy propagator during cloning.
Range iterator for union of iterators.
MaxBnd(Space &home, MaxBnd &p)
Constructor for cloning p.
const Gecode::PropCond PC_INT_BND
Propagate when minimum or maximum of a view changes.
NaryMaxBnd(Space &home, NaryMaxBnd &p)
Constructor for cloning p.
int ModEvent
Type for modification events.
Range iterator for computing union (binary)
int PropCond
Type for propagation conditions.
static ExecStatus post(Home home, ViewArray< View > &x, View y)
Post propagator .
static PropCost ternary(PropCost::Mod m)
Three variables for modifier pcm.
void mod(Home home, IntVar x0, IntVar x1, IntVar x2, IntPropLevel ipl)
Post propagator for .
Propagation has computed fixpoint.
Binary bounds consistent equality propagator.
ExecStatus prop_max_bnd(Space &home, View x0, View x1, View x2)
Bounds consistent n-ary maximum propagator.
#define GECODE_ME_CHECK(me)
Check whether modification event me is failed, and forward failure.
virtual ExecStatus propagate(Space &home, const ModEventDelta &med)
Perform propagation.
void min(Home home, FloatVar x0, FloatVar x1, FloatVar x2)
Post propagator for .
bool me_modified(ModEvent me)
Check whether modification event me describes variable modification.
virtual Actor * copy(Space &home)
Copy propagator during cloning.
virtual PropCost cost(const Space &home, const ModEventDelta &med) const
Cost function.
NaryMaxDom(Space &home, NaryMaxDom &p)
Constructor for cloning p.
Execution has resulted in failure.
ExecStatus ES_FIX_PARTIAL(Propagator &p, const ModEventDelta &med)
Propagator p has computed partial fixpoint
const Gecode::PropCond PC_INT_DOM
Propagate when domain changes.
int ModEventDelta
Modification event deltas.
Propagation has not computed fixpoint.
Gecode::IntArgs i({1, 2, 3, 4})
const Gecode::ModEvent ME_INT_DOM
Domain operation has changed the domain.
#define GECODE_REWRITE(prop, post)
Rewrite propagator by executing post function.
int p
Number of positive literals for node type.
const FloatNum max
Largest allowed float value.
virtual PropCost cost(const Space &home, const ModEventDelta &med) const
Cost function.
virtual ExecStatus propagate(Space &home, const ModEventDelta &med)
Perform propagation.