44 namespace Gecode {
namespace Set {
namespace Rel {
46 template<
class View0,
class View1>
52 template<
class View0,
class View1>
58 template<
class View0,
class View1>
60 (void)
new (home)
Subset(home,x,y);
64 template<
class View0,
class View1>
67 return new (home)
Subset(home,share,*
this);
70 template<
class View0,
class View1>
73 bool oneassigned =
x0.assigned() ||
x1.assigned();
74 unsigned int x0glbsize;
80 x0glbsize =
x0.glbSize();
83 }
while (
x0.glbSize() > x0glbsize);
85 if (
x0.cardMin() ==
x1.cardMax())
const Gecode::PropCond PC_SET_CLUB
Propagate when the cardinality or the least upper bound of a view changes.
#define GECODE_REWRITE(prop, post)
Rewrite propagator by executing post function.
ExecStatus ES_SUBSUMED(Propagator &p)
View0 x0
View of type View0.
Propagator for the subset constraint
Range iterator for the greatest lower bound.
Propagation has computed fixpoint.
View1 x1
View of type View1.
Range iterator for the least upper bound.
Base-class for both propagators and branchers.
static ExecStatus post(Home home, View0 x, View1 y)
Post propagator .
int p
Number of positive literals for node type.
virtual ExecStatus propagate(Space &home, const ModEventDelta &med)
Perform propagation.
#define GECODE_ME_CHECK(me)
Check whether modification event me is failed, and forward failure.
Node * x
Pointer to corresponding Boolean expression node.
virtual Actor * copy(Space &home, bool share)
Copy propagator during cloning.
const Gecode::PropCond PC_SET_CGLB
Propagate when the cardinality or the greatest lower bound of a view changes.
Propagator for set equality
Subset(Space &home, bool share, Subset &p)
Constructor for cloning p.
Propagation has not computed fixpoint.
bool shared(const ConstView< ViewA > &, const ConstView< ViewB > &)
Test whether views share same variable.
Gecode toplevel namespace
int ModEventDelta
Modification event deltas.
Home class for posting propagators