Go to the documentation of this file.
44 #ifndef __GECODE_INT_DISTINCT_HH__
45 #define __GECODE_INT_DISTINCT_HH__
57 namespace Gecode {
namespace Int {
namespace Distinct {
98 template<
class View,
bool complete>
Val(Home home, ViewArray< View > &x)
Constructor for posting.
Post propagator for SetVar x
View-value graph base class.
Graph(void)
Construct graph as not yet initialized.
Bnd(Home home, ViewArray< View > &x)
Constructor for posting.
static ExecStatus post(Home home, View x0, View x1, View x2)
Post propagator for views x.
virtual Actor * copy(Space &home, bool share)
Copy propagator during cloning.
Dom(Space &home, bool share, Dom< View > &p)
Constructor for cloning p.
ExecStatus init(Space &home, ViewArray< View > &x)
Initialize view-value graph for views x.
Bounds consistent distinct propagator.
ExecStatus sync(Space &home)
Synchronize available view-value graph.
static ExecStatus post(Home home, ViewArray< View > &x)
Post propagator for views x.
static ExecStatus post(Home home, ViewArray< View > &x)
Post propagator for view array x.
virtual ExecStatus propagate(Space &home, const ModEventDelta &med)
Perform propagation.
ExecStatus prop_bnd(Space &home, ViewArray< View > &x, int *minsorted, int *maxsorted)
bool assigned(View x, int v)
Whether x is assigned to value v.
virtual PropCost cost(const Space &home, const ModEventDelta &med) const
Cost function (defined as high ternary)
TerDom(Space &home, bool share, TerDom< View > &p)
Constructor for cloning p.
Base-class for both propagators and branchers.
static ExecStatus post(Home home, IntView x0, IntView x1, int c0, int c1)
Post if-then-else propagator.
ViewArray< View > x
Array of views.
virtual Actor * copy(Space &home, bool share)
Copy propagator during cloning.
DomCtrl< View > dc
Propagation controller.
virtual size_t dispose(Space &home)
Destructor.
virtual ExecStatus propagate(Space &home, const ModEventDelta &med)
Perform propagation.
virtual Actor * copy(Space &home, bool share)
Copy propagator during cloning.
Gecode toplevel namespace
Base-class for propagators.
ExecStatus prop_val(Space &home, ViewArray< View > &x)
Eliminate singletons by naive value propagation.
Propagation controller for domain consistent distinct.
DomCtrl(void)
Initialize with non-initialized view-value graph.
virtual ExecStatus propagate(Space &home, const ModEventDelta &med)
Perform propagation.
EqIte(Space &home, bool share, EqIte &p)
Constructor for cloning p.
#define GECODE_INT_EXPORT
Ternary domain consistent distinct propagator.
virtual ExecStatus propagate(Space &home, const ModEventDelta &med)
Perform propagation.
Equal-if-then-else domain-consistent propagator.
Home class for posting propagators
virtual PropCost cost(const Space &home, const ModEventDelta &med) const
Cost function.
int min_x
Minimum (approximation) of view in x.
ModEventDelta med
A set of modification events (used during propagation)
int c0
The integer constant.
bool sync(Space &home)
Synchronize graph with new view domains.
virtual ExecStatus propagate(Space &home, const ModEventDelta &med)
Perform propagation.
virtual void reschedule(Space &home)
Schedule function.
Domain consistent distinct propagator.
virtual PropCost cost(const Space &home, const ModEventDelta &med) const
Cost function.
virtual Actor * copy(Space &home, bool share)
Copy propagator during cloning.
virtual Actor * copy(Space &home, bool share)
Copy propagator during cloning.
ViewArray< View > y
Views on which to perform value-propagation (subset of x)
bool mark(Space &home)
Mark edges in graph, return true if pruning is at all possible.
ExecStatus prune(Space &home, bool &assigned)
Prune unmarked edges, assigned is true if a view got assigned.
View-value graph for propagation.
static ExecStatus post(Home home, ViewArray< View > &x)
Post propagator for view array x.
Integer view for integer variables.
int max_x
Maximum (approximation) of view in x.
ExecStatus propagate(Space &home, bool &assigned)
Perform propagation, assigned is true if a view gets assigned.
Graph< View > g
Propagation is performed on a view-value graph.
ViewArray< View > x
Views on which to perform bounds-propagation.
int ModEventDelta
Modification event deltas.
ExecStatus init(Space &home, ViewArray< View > &x)
Initialize graph.
int p
Number of positive literals for node type.
bool available(void)
Check whether a view-value graph is available.
Naive value distinct propagator.