40namespace Gecode {
namespace Set {
namespace Channel {
51 for (
int i=
ys.size();
i--;)
74 int xssize = xs.size();
75 for (
int i=ys.
size();
i--;) {
79 int yssize = ys.size();
82 for (
int i=xs.
size();
i--;) {
110 return sizeof(*this);
123 for (
int v=xs.size();
v--;) {
126 if (xs[
v].modified())
129 if (xs[
v].modified()) {
139 for (
int i=ys.
size();
i--;) {
140 if (ys[
i].glbModified()) {
145 ys[
i].cacheGlb(home);
147 if (ys[
i].lubModified()) {
152 ys[
i].cacheLub(home);
int p
Number of positive literals for node type.
Base-class for both propagators and branchers.
virtual size_t dispose(Space &home)
Delete actor and return its size.
int size(void) const
Return size of array (number of elements)
Home class for posting propagators
static const IntSet empty
Empty set.
Integer view for integer variables.
Range iterator for cached integer views
Value iterator from range iterator.
int val(void) const
Return current value.
static PropCost quadratic(PropCost::Mod m, unsigned int n)
Quadratic complexity for modifier m and size measure n.
Base-class for propagators.
Propagator for channelling between variable-value-dual models
static ExecStatus post(Home home, ViewArray< Gecode::Int::CachedView< Gecode::Int::IntView > > &x, ViewArray< CachedView< View > > &y)
Post propagator for .
virtual PropCost cost(const Space &home, const ModEventDelta &med) const
Cost function (defined as PC_QUADRATIC_LO)
ChannelInt(Space &home, ChannelInt &p)
Constructor for cloning p.
ViewArray< Gecode::Int::CachedView< Gecode::Int::IntView > > xs
IntViews, reflects which set contains element .
virtual ExecStatus propagate(Space &home, const ModEventDelta &med)
Perform propagation.
virtual void reschedule(Space &home)
Schedule function.
virtual Actor * copy(Space &home)
Copy propagator during cloning.
ViewArray< CachedView< View > > ys
SetViews that are constrained to be disjoint.
virtual size_t dispose(Space &home)
Delete propagator and return its size.
Range iterator for difference of greatest lower bound and cache
Range iterator for difference of least upper bound and cache
void update(Space &home, ViewArray< View > &a)
Update array to be a clone of array a.
void subscribe(Space &home, Propagator &p, PropCond pc, bool schedule=true)
Subscribe propagator p with propagation condition pc to variable.
int size(void) const
Return size of array (number of elements)
ExecStatus ES_SUBSUMED(Propagator &p)
int ModEventDelta
Modification event deltas.
#define GECODE_ME_CHECK(me)
Check whether modification event me is failed, and forward failure.
const int max
Largest allowed integer value.
bool assigned(View x, int v)
Whether x is assigned to value v.
ModEvent exclude(Space &home, View &x, int s)
Prune view x to exclude all values from s.
ModEvent include(Space &home, View &x, int s)
Prune view x to only include values from s.
const Gecode::PropCond PC_INT_DOM
Propagate when domain changes.
const int min
Smallest allowed integer in integer set.
const int max
Largest allowed integer in integer set.
const Gecode::PropCond PC_SET_ANY
Propagate when any bound or the cardinality of a view changes.
Gecode toplevel namespace
@ ES_OK
Execution is okay.
@ ES_FAILED
Execution has resulted in failure.
@ ES_NOFIX
Propagation has not computed fixpoint.
Gecode::IntArgs i({1, 2, 3, 4})