40 namespace Gecode {
namespace Int {
namespace Element {
44 return new (home)
Pair(home,*
this);
67 bool operator ()(
void)
const;
70 void operator ++(
void);
82 :
x(x0), xv(x0), yv(y0),
w(w0) {}
96 return xv.
val()+w*yv.
val();
108 d.set(static_cast<unsigned int>(
i.val() / w));
115 d(r,static_cast<unsigned int>((x2.max() / w)+1)),
116 m(r,static_cast<unsigned int>(w));
118 d.set(static_cast<unsigned int>(
i.val() / w));
119 m.set(static_cast<unsigned int>(
i.val() % w));
127 if (x0.assigned() && x1.assigned()) {
130 }
else if (x1.assigned()) {
133 ::
post(home(*
this),x0x1w,x2)));
#define GECODE_REWRITE(prop, post)
Rewrite propagator by executing post function.
PairValues(IntView x, IntView y, int w)
Initialize with views x and y and width w.
Binary domain consistent equality propagator.
ExecStatus ES_SUBSUMED(Propagator &p)
bool operator()(void) const
Test whether iterator is still at a value or done.
int val(void) const
Return current value.
int min(int i) const
Return minimum of range at position i.
int val(void) const
Return current value.
Value iterator for values in a bitset.
Gecode::IntArgs i(4, 1, 2, 3, 4)
virtual ExecStatus propagate(Space &home, const ModEventDelta &med)
Perform propagation.
Value iterator for pair of iterators.
Pair(Space &home, Pair &p)
Constructor for cloning p.
#define GECODE_ME_CHECK(me)
Check whether modification event me is failed, and forward failure.
void operator++(void)
Move iterator to next value (if possible)
Post propagator for SetVar SetOpType SetVar SetRelType r
Integer view for integer variables.
Post propagator for SetVar SetOpType SetVar y
Post propagator for SetVar x
Propagation has not computed fixpoint.
Gecode toplevel namespace
void init(const View &x)
Initialize with values x.
int ModEventDelta
Modification event deltas.
TFE post(PropagatorGroup g)
Only post functions (but not propagators) from g are considered.
virtual Actor * copy(Space &home)
Copy propagator during cloning.