40namespace Gecode {
namespace Int {
namespace GCC {
50 int m =
l + (
r -
l) / 2;
51 if (v ==
a[m].card()) {
55 }
else if (v <
a[m].card()) {
167 unsigned int size(
void)
const;
171 int card(
void)
const;
218 _min =
min; _max=
max; _card = c; _counter = 0;
249 if (++_counter > _max)
267 if ((_min >
n) || (_max <
n))
281 _min=
x._min; _max=
x._max; _card=
x._card; _counter=
x._counter;
int p
Number of positive literals for node type.
int n
Number of negative literals for node type.
struct Gecode::@603::NNF::@65::@67 a
For atomic nodes.
Base-class for derived views.
Constant view containing lower and upper cardinality bounds.
void subscribe(Space &home, Propagator &p, PropCond pc, bool process=true)
Cancel subscription of propagator p with propagation condition pc to view.
ModEvent eq(Space &home, int n)
Restrict domain values to be equal to n.
void cancel(Space &home, Propagator &p, PropCond pc)
Cancel subscription of propagator p with propagation condition pc to view.
int card(void) const
Return cardinality.
ModEvent inc(void)
Increment counter.
int min(void) const
Return minimum of domain.
static const bool propagate
This view does not require propagation.
int counter(void) const
Return the number of times the value occurs.
void init(Space &home, int min, int max, int c)
Initialize with min, max, and cardinality c.
ModEvent gq(Space &home, int n)
Restrict domain values to be greater or equal than n.
int max(void) const
Return maximum of domain.
void update(Space &home, CardConst &x)
bool assigned(void) const
CardConst(void)
Default constructor.
void reschedule(Space &home, Propagator &p, PropCond pc)
Schedule propagator p.
ModEvent lq(Space &home, int n)
Restrict domain values to be less or equal than n.
IntView base(void) const
Return used IntView (cannot be used)
Cardinality integer view.
ModEvent eq(Space &home, int n)
Restrict domain values to be equal to n.
ModEvent minus_v(Space &home, I &i, bool depends=true)
Remove from domain the values described by i.
int card(void) const
Return cardinality.
int counter(void) const
Return the number of times the value occurs.
unsigned int size(void) const
Return size (cardinality) of domain.
void init(const IntView &y, int c)
Initialize with integer view y and value c.
int min(void) const
Return minimum of domain.
ModEvent inter_v(Space &home, I &i, bool depends=true)
Intersect domain with values described by i.
void update(Space &home, CardView &x)
ModEvent lq(Space &home, int n)
Restrict domain values to be less or equal than n.
ModEvent gq(Space &home, int n)
Restrict domain values to be greater or equal than n.
CardView(void)
Default constructor.
static const bool propagate
This view does require propagation.
int max(void) const
Return maximum of domain.
ModEvent inc(void)
Increment counter.
ModEvent narrow_v(Space &home, I &i, bool depends=true)
Replace domain by values described by i.
Integer view for integer variables.
unsigned int size(void) const
Return size (cardinality) of domain.
int min(void) const
Return minimum of domain.
ModEvent narrow_v(Space &home, I &i, bool depends=true)
Replace domain by values described by i.
ModEvent lq(Space &home, int n)
Restrict domain values to be less or equal than n.
ModEvent inter_v(Space &home, I &i, bool depends=true)
Intersect domain with values described by i.
ModEvent gq(Space &home, int n)
Restrict domain values to be greater or equal than n.
ModEvent minus_v(Space &home, I &i, bool depends=true)
Remove from domain the values described by i.
int max(void) const
Return maximum of domain.
ModEvent eq(Space &home, int n)
Restrict domain values to be equal to n.
Range iterator for integer views.
void init(const View &x)
Initialize with ranges for view x.
ViewRanges(void)
Default constructor.
Base-class for propagators.
VarImp * x
Pointer to variable implementation.
void update(Space &home, VarImpView< Var > &y)
Update this view to be a clone of view y.
bool lookupValue(T &a, int v, int &i)
Return index of v in array a.
const Gecode::ModEvent ME_INT_FAILED
Domain operation has resulted in failure.
const Gecode::ModEvent ME_INT_NONE
Domain operation has not changed domain.
Gecode toplevel namespace
Post propagator for SetVar SetOpType SetVar SetRelType r
void min(Home home, FloatVar x0, FloatVar x1, FloatVar x2)
Post propagator for .
Post propagator for SetVar SetOpType SetVar y
const ModEvent ME_GEN_NONE
Generic modification event: no modification.
void max(Home home, FloatVar x0, FloatVar x1, FloatVar x2)
Post propagator for .
int PropCond
Type for propagation conditions.
Post propagator for SetVar x
int ModEvent
Type for modification events.
#define GECODE_NEVER
Assert that this command is never executed.