Generated on Sat Jun 2 2018 07:17:44 for Gecode by doxygen 1.8.13
Gecode::AFC Class Reference

Class for AFC (accumulated failure count) management. More...

#include <afc.hpp>

Public Member Functions

 ~AFC (void)
 Destructor. More...
 

Protected Attributes

int n
 Number of views. More...
 

Related Functions

(Note that these are not member functions.)

template<class Char , class Traits >
std::basic_ostream< Char, Traits > & operator<< (std::basic_ostream< Char, Traits > &os, const AFC &a)
 Print AFC information (prints nothing) More...
 

Constructors and initialization

static const AFC def
 Default (empty) AFC information. More...
 
 AFC (void)
 Construct as not yet intialized. More...
 
 AFC (const AFC &a)
 Copy constructor. More...
 
AFCoperator= (const AFC &a)
 Assignment operator. More...
 
template<class Var >
 AFC (Home home, const VarArgArray< Var > &x, double d, bool share=true)
 Initialize for variables x and decay factor d. More...
 
template<class Var >
void init (Home home, const VarArgArray< Var > &x, double d, bool share=true)
 Initialize for variables x and decay factor d. More...
 
 operator bool (void) const
 Test whether already initialized. More...
 

Information access

int size (void) const
 Return number of AFC values. More...
 

Decay factor for aging

void decay (Space &home, double d)
 Set decay factor to d. More...
 
double decay (const Space &home) const
 Return decay factor. More...
 

Detailed Description

Class for AFC (accumulated failure count) management.

Definition at line 40 of file afc.hpp.

Constructor & Destructor Documentation

◆ AFC() [1/3]

Gecode::AFC::AFC ( void  )
inline

Construct as not yet intialized.

The only member functions that can be used on a constructed but not yet initialized AFC storage is init and the assignment operator.

Definition at line 119 of file afc.hpp.

◆ AFC() [2/3]

Gecode::AFC::AFC ( const AFC a)
inline

Copy constructor.

Definition at line 149 of file afc.hpp.

◆ AFC() [3/3]

template<class Var >
Gecode::AFC::AFC ( Home  home,
const VarArgArray< Var > &  x,
double  d,
bool  share = true 
)
inline

Initialize for variables x and decay factor d.

If several AFC objects are created for a space or its clones, the AFC values are shared between spaces. If the values should not be shared, share should be false.

Definition at line 128 of file afc.hpp.

◆ ~AFC()

Gecode::AFC::~AFC ( void  )
inline

Destructor.

Definition at line 157 of file afc.hpp.

Member Function Documentation

◆ operator=()

AFC & Gecode::AFC::operator= ( const AFC a)
inline

Assignment operator.

Definition at line 152 of file afc.hpp.

◆ init()

template<class Var >
void Gecode::AFC::init ( Home  home,
const VarArgArray< Var > &  x,
double  d,
bool  share = true 
)
inline

Initialize for variables x and decay factor d.

If several AFC objects are created for a space or its clones, the AFC values are shared between spaces. If the values should not be shared, share should be false.

Definition at line 138 of file afc.hpp.

◆ operator bool()

Gecode::AFC::operator bool ( void  ) const
inline

Test whether already initialized.

Definition at line 122 of file afc.hpp.

◆ size()

int Gecode::AFC::size ( void  ) const
inline

Return number of AFC values.

Definition at line 113 of file afc.hpp.

◆ decay() [1/2]

void Gecode::AFC::decay ( Space home,
double  d 
)
inline

Set decay factor to d.

Definition at line 160 of file afc.hpp.

◆ decay() [2/2]

double Gecode::AFC::decay ( const Space home) const
inline

Return decay factor.

Definition at line 167 of file afc.hpp.

Friends And Related Function Documentation

◆ operator<<()

template<class Char , class Traits >
std::basic_ostream< Char, Traits > & operator<< ( std::basic_ostream< Char, Traits > &  os,
const AFC a 
)
related

Print AFC information (prints nothing)

Definition at line 174 of file afc.hpp.

Member Data Documentation

◆ n

int Gecode::AFC::n
protected

Number of views.

Definition at line 43 of file afc.hpp.

◆ def

const AFC Gecode::AFC::def
static

Default (empty) AFC information.

Definition at line 78 of file afc.hpp.


The documentation for this class was generated from the following files: