Generated on Sat Feb 7 2015 02:01:35 for Gecode by doxygen 1.8.9.1

Modules

 Programming integer actors
 
 Programming set actors
 
 Programming float actors
 
 Reified propagator patterns
 
 Generic brancher based on view and value selection
 
 Generic brancher based on view selection
 
 Status of constraint propagation and branching commit
 
 Propagator patterns
 

Classes

class  Gecode::ViewArray< View >
 View arrays. More...
 
class  Gecode::PropCost
 Propagation cost. More...
 
class  Gecode::Actor
 Base-class for both propagators and branchers. More...
 
class  Gecode::Propagator
 Base-class for propagators. More...
 
class  Gecode::Council< A >
 Council of advisors More...
 
class  Gecode::Advisors< A >
 Class to iterate over advisors of a council. More...
 
class  Gecode::Advisor
 Base-class for advisors. More...
 
class  Gecode::Choice
 Choice for performing commit More...
 
class  Gecode::Brancher
 Base-class for branchers. More...
 
class  Gecode::BrancherHandle
 Handle for brancher. More...
 

Macros

#define GECODE_ME_CHECK(me)
 Check whether modification event me is failed, and forward failure. More...
 
#define GECODE_ME_CHECK_MODIFIED(modified, me)
 Check whether me is failed or modified, and forward failure. More...
 
#define GECODE_ME_FAIL(me)
 Check whether modification event me is failed, and fail space home. More...
 
#define GECODE_ES_CHECK(es)
 Check whether execution status es is failed or subsumed, and forward failure or subsumption. More...
 
#define GECODE_ES_FAIL(es)
 Check whether execution status es is failed, and fail space home. More...
 
#define GECODE_REWRITE(prop, post)
 Rewrite propagator by executing post function. More...
 

Typedefs

typedef int Gecode::ModEventDelta
 Modification event deltas. More...
 

Enumerations

enum  Gecode::PropCost::ActualCost {
  Gecode::PropCost::AC_CRAZY_LO = 0, Gecode::PropCost::AC_CRAZY_HI = 0, Gecode::PropCost::AC_CUBIC_LO = 1, Gecode::PropCost::AC_CUBIC_HI = 1,
  Gecode::PropCost::AC_QUADRATIC_LO = 2, Gecode::PropCost::AC_QUADRATIC_HI = 2, Gecode::PropCost::AC_LINEAR_HI = 3, Gecode::PropCost::AC_LINEAR_LO = 4,
  Gecode::PropCost::AC_TERNARY_HI = 4, Gecode::PropCost::AC_BINARY_HI = 5, Gecode::PropCost::AC_TERNARY_LO = 5, Gecode::PropCost::AC_BINARY_LO = 6,
  Gecode::PropCost::AC_UNARY_LO = 6, Gecode::PropCost::AC_UNARY_HI = 6, Gecode::PropCost::AC_MAX = 6
}
 The actual cost values that are used. More...
 
enum  Gecode::PropCost::Mod { Gecode::PropCost::LO, Gecode::PropCost::HI }
 Propagation cost modifier. More...
 
enum  Gecode::ActorProperty { Gecode::AP_DISPOSE = (1 << 0), Gecode::AP_WEAKLY = (1 << 1) }
 Actor properties. More...
 

Functions

void Gecode::Space::notice (Actor &a, ActorProperty p, bool duplicate=false)
 Notice actor property. More...
 
void Gecode::Space::ignore (Actor &a, ActorProperty p, bool duplicate=false)
 Ignore actor property. More...
 
void Gecode::Space::fail (void)
 Fail space. More...
 
bool Gecode::Space::failed (void) const
 Check whether space is failed. More...
 
bool Gecode::Space::stable (void) const
 Return if space is stable (at fixpoint or failed) More...
 
bool Gecode::me_failed (ModEvent me)
 Check whether modification event me is failed. More...
 
bool Gecode::me_modified (ModEvent me)
 Check whether modification event me describes variable modification. More...
 

Detailed Description

Macro Definition Documentation

#define GECODE_ME_CHECK (   me)
Value:
do { \
if (::Gecode::me_failed(me)) \
} while (0)
Execution has resulted in failure.
Definition: core.hpp:525
bool me_failed(ModEvent me)
Check whether modification event me is failed.
Definition: modevent.hpp:58

Check whether modification event me is failed, and forward failure.

To be used inside the propagate member function of a propagator or the commit member function of a brancher.

Definition at line 45 of file macros.hpp.

#define GECODE_ME_CHECK_MODIFIED (   modified,
  me 
)
Value:
do { \
ModEvent __me__ ## __LINE__ = (me); \
if (::Gecode::me_failed(__me__ ## __LINE__)) \
modified |= ::Gecode::me_modified(__me__ ## __LINE__); \
} while (0)
int ModEvent
Type for modification events.
Definition: core.hpp:146
Execution has resulted in failure.
Definition: core.hpp:525
bool me_modified(ModEvent me)
Check whether modification event me describes variable modification.
Definition: modevent.hpp:63
bool me_failed(ModEvent me)
Check whether modification event me is failed.
Definition: modevent.hpp:58

Check whether me is failed or modified, and forward failure.

To be used inside the propagate member function of a propagator or the commit member function of a brancher.

Definition at line 57 of file macros.hpp.

#define GECODE_ME_FAIL (   me)
Value:
do { \
if (::Gecode::me_failed(me)) { \
(home).fail(); \
return; \
}} while (0)
bool me_failed(ModEvent me)
Check whether modification event me is failed.
Definition: modevent.hpp:58

Check whether modification event me is failed, and fail space home.

To be used inside post functions.

Definition at line 70 of file macros.hpp.

#define GECODE_ES_CHECK (   es)
Value:
do { \
::Gecode::ExecStatus __es__ ## __LINE__ = (es); \
if (__es__ ## __LINE__ < ::Gecode::ES_OK) \
return __es__ ## __LINE__; \
} while (0)
ExecStatus
Definition: core.hpp:523
Execution is okay.
Definition: core.hpp:527

Check whether execution status es is failed or subsumed, and forward failure or subsumption.

Definition at line 84 of file macros.hpp.

#define GECODE_ES_FAIL (   es)
Value:
do { \
::Gecode::ExecStatus __es__ ## __LINE__ = (es); \
assert(__es__ ## __LINE__ != ::Gecode::__ES_SUBSUMED); \
if (__es__ ## __LINE__ < ::Gecode::ES_OK) { \
(home).fail(); return; \
} \
} while (0)
Internal: propagator is subsumed, do not use.
Definition: core.hpp:524
ExecStatus
Definition: core.hpp:523
Execution is okay.
Definition: core.hpp:527

Check whether execution status es is failed, and fail space home.

Definition at line 96 of file macros.hpp.

#define GECODE_REWRITE (   prop,
  post 
)
Value:
do { \
Propagator& __p__ ## __LINE__ = (prop); \
size_t __s__ ## __LINE__ = __p__ ## __LINE__.dispose(home); \
ExecStatus __es__ ## __LINE__ = (post); \
if (__es__ ## __LINE__ != ::Gecode::ES_OK) \
return home.ES_SUBSUMED_DISPOSED(__p__ ## __LINE__,__s__ ## __LINE__); \
} while (0)
void post(Home home, Term *t, int n, FloatRelType frt, FloatVal c)
Post propagator for linear constraint over floats.
Definition: post.cpp:228
Execution has resulted in failure.
Definition: core.hpp:525
ExecStatus
Definition: core.hpp:523
Execution is okay.
Definition: core.hpp:527

Rewrite propagator by executing post function.

Definition at line 109 of file macros.hpp.

Typedef Documentation

typedef int Gecode::ModEventDelta

Modification event deltas.

Modification event deltas are used by propagators. A propagator stores a modification event for each variable type. They can be accessed through a variable or a view from a given propagator. They can be constructed from a given modevent by a variable or view.

Definition at line 173 of file core.hpp.

Enumeration Type Documentation

The actual cost values that are used.

Enumerator
AC_CRAZY_LO 

Exponential complexity, cheap.

AC_CRAZY_HI 

Exponential complexity, expensive.

AC_CUBIC_LO 

Cubic complexity, cheap.

AC_CUBIC_HI 

Cubic complexity, expensive.

AC_QUADRATIC_LO 

Quadratic complexity, cheap.

AC_QUADRATIC_HI 

Quadratic complexity, expensive.

AC_LINEAR_HI 

Linear complexity, expensive.

AC_LINEAR_LO 

Linear complexity, cheap.

AC_TERNARY_HI 

Three variables, expensive.

AC_BINARY_HI 

Two variables, expensive.

AC_TERNARY_LO 

Three variables, cheap.

AC_BINARY_LO 

Two variables, cheap.

AC_UNARY_LO 

Only single variable, cheap.

AC_UNARY_HI 

Only single variable, expensive.

AC_MAX 

Maximal cost value.

Definition at line 541 of file core.hpp.

Propagation cost modifier.

Enumerator
LO 

Cheap.

HI 

Expensive.

Definition at line 562 of file core.hpp.

Actor properties.

Enumerator
AP_DISPOSE 

Actor must always be disposed.

Normally, a propagator will not be disposed if its home space is deleted. However, if an actor uses external resources, this property can be used to make sure that the actor will always be disposed.

AP_WEAKLY 

Propagator is only weakly monotonic, that is, the propagator is only monotonic on assignments.

Definition at line 601 of file core.hpp.

Function Documentation

void Gecode::Space::notice ( Actor a,
ActorProperty  p,
bool  duplicate = false 
)

Notice actor property.

Make the space notice that the actor a has the property p. Note that the same property can only be noticed once for an actor unless duplicate is true.

Definition at line 136 of file core.cpp.

void Gecode::Space::ignore ( Actor a,
ActorProperty  p,
bool  duplicate = false 
)

Ignore actor property.

Make the space ignore that the actor a has the property p. Note that a property must be ignored before an actor is disposed.

Definition at line 169 of file core.cpp.

void Gecode::Space::fail ( void  )
inline

Fail space.

This is useful for failing outside of actors. Never use inside a propagate or commit member function. The system will crash!

Definition at line 3428 of file core.hpp.

bool Gecode::Space::failed ( void  ) const
inline

Check whether space is failed.

Note that this does not perform propagation. This is useful for posting actors: only if a space is not yet failed, new actors are allowed to be created.

Definition at line 3442 of file core.hpp.

bool Gecode::Space::stable ( void  ) const
inline

Return if space is stable (at fixpoint or failed)

Definition at line 3451 of file core.hpp.

bool Gecode::me_failed ( ModEvent  me)
inline

Check whether modification event me is failed.

Definition at line 58 of file modevent.hpp.

bool Gecode::me_modified ( ModEvent  me)
inline

Check whether modification event me describes variable modification.

Definition at line 63 of file modevent.hpp.