42 namespace Gecode {
namespace Int {
namespace Extensional {
49 template<
class View,
bool shared>
56 template<
class View,
bool shared>
61 for (
int i =
x.size();
i--; ) {
69 template<
class View,
bool shared>
72 :
Base<View>(home,share,
p) {
75 template<
class View,
bool shared>
84 template<
class View,
bool shared>
90 template<
class View,
bool shared>
102 for (
int i =
x.size();
i--; )
103 has_support[
i].init(home, ts()->domsize);
112 for (
int i =
x.size();
i--; ) {
115 int val = vv.val() - ts()->min;
116 if (!has_support[
i].get(static_cast<unsigned int>(val))) {
126 for (
int j =
i; j--; ) {
127 has_support[j].
set(static_cast<unsigned int>(
l[j]- ts()->
min));
128 assert(has_support[j].get(
l[j] - ts()->
min));
139 for (
int i =
x.size();
i--; )
void push(const T &x)
Push element x on top of stack.
static PropCost quadratic(PropCost::Mod m, unsigned int n)
Quadratic complexity for modifier m and size measure n.
ExecStatus ES_SUBSUMED(Propagator &p)
void dom(Home home, FloatVar x, FloatVal n)
Propagates .
bool empty(void) const
Test whether stack is empty.
Value iterator for integer views.
Propagation has computed fixpoint.
virtual Actor * copy(Space &home, bool share)
Copy propagator during cloning.
Base-class for both propagators and branchers.
virtual PropCost cost(const Space &home, const ModEventDelta &med) const
Cost function.
virtual ExecStatus propagate(Space &home, const ModEventDelta &med)
Perform propagation.
int p
Number of positive literals for node type.
Gecode::IntArgs i(4, 1, 2, 3, 4)
Domain consistent extensional propagator.
const Gecode::ModEvent ME_INT_VAL
Domain operation has resulted in a value (assigned variable)
void set(unsigned int i)
Set bit i.
#define GECODE_ME_CHECK(me)
Check whether modification event me is failed, and forward failure.
void min(Home home, FloatVar x0, FloatVar x1, FloatVar x2)
Post propagator for .
Class represeting a set of tuples.
static ExecStatus post(Home home, ViewArray< View > &x, const TupleSet &t)
Post propagator for views x.
static PropCost cubic(PropCost::Mod m, unsigned int n)
Cubic complexity for modifier m and size measure n.
Node * x
Pointer to corresponding Boolean expression node.
Basic(Space &home, bool share, Basic< View, shared > &p)
Constructor for cloning p.
bool assigned(View x, int v)
Whether x is assigned to value v.
Stack with fixed number of elements.
T pop(void)
Pop topmost element from stack and return it.
Propagation has not computed fixpoint.
bool shared(const ConstView< ViewA > &, const ConstView< ViewB > &)
Test whether views share same variable.
Base for domain consistent extensional propagation
Gecode toplevel namespace
int ModEventDelta
Modification event deltas.
Home class for posting propagators