Generated on Thu Jul 21 2022 00:00:00 for Gecode by doxygen 1.9.5
Gecode::Int::LDSB::VariableSequenceSymmetryImp< View > Class Template Reference

Implementation of a variable sequence symmetry. More...

#include <ldsb.hh>

Public Member Functions

 VariableSequenceSymmetryImp (Space &home, int *_indices, unsigned int n, unsigned int seqsize)
 Constructor for creation. More...
 
 VariableSequenceSymmetryImp (Space &home, const VariableSequenceSymmetryImp< View > &s)
 Copy constructor. More...
 
virtual size_t dispose (Space &home)
 Disposal. More...
 
void update (Literal)
 Search left-branch update. More...
 
virtual ArgArray< Literalsymmetric (Literal, const ViewArray< View > &) const
 Compute symmetric literals. More...
 
SymmetryImp< View > * copy (Space &home) const
 Copy function. More...
 
ArgArray< Literalsymmetric (Literal l, const ViewArray< Set::SetView > &x) const
 
ArgArray< Literalsymmetric (Literal l, const ViewArray< Set::SetView > &x) const
 
- Public Member Functions inherited from Gecode::Int::LDSB::SymmetryImp< View >
virtual ArgArray< Literalsymmetric (Literal, const ViewArray< View > &) const =0
 Compute symmetric literals. More...
 
virtual void update (Literal)=0
 Left-branch update. More...
 
virtual SymmetryImp< View > * copy (Space &home) const =0
 Copy function. More...
 
virtual size_t dispose (Space &home)=0
 Disposal. More...
 
virtual ~SymmetryImp (void)
 Unused destructor. More...
 

Protected Member Functions

int getVal (unsigned int sequence, unsigned int position) const
 Get the value in the specified sequence at the specified position. (Both are zero-based.) More...
 

Protected Attributes

unsigned int * indices
 Array of variable indices. More...
 
unsigned int n_indices
 Total number of indices (n_seqs * seq_size) More...
 
unsigned int seq_size
 Size of each sequence in symmetry. More...
 
unsigned int n_seqs
 Number of sequences in symmetry. More...
 
int * lookup
 Map from variable's index to its sequence and position. More...
 
unsigned int lookup_size
 Size of lookup. More...
 

Additional Inherited Members

- Static Public Member Functions inherited from Gecode::Int::LDSB::SymmetryImp< View >
static void * operator new (size_t s, Space &home)
 Placement new operator. More...
 
static void operator delete (void *, Space &)
 Return memory to space. More...
 
static void operator delete (void *)
 Needed for exceptions. More...
 

Detailed Description

template<class View>
class Gecode::Int::LDSB::VariableSequenceSymmetryImp< View >

Implementation of a variable sequence symmetry.

Definition at line 223 of file ldsb.hh.

Constructor & Destructor Documentation

◆ VariableSequenceSymmetryImp() [1/2]

template<class View >
Gecode::Int::LDSB::VariableSequenceSymmetryImp< View >::VariableSequenceSymmetryImp ( Space home,
int *  _indices,
unsigned int  n,
unsigned int  seqsize 
)

Constructor for creation.

Definition at line 180 of file sym-imp.hpp.

◆ VariableSequenceSymmetryImp() [2/2]

template<class View >
Gecode::Int::LDSB::VariableSequenceSymmetryImp< View >::VariableSequenceSymmetryImp ( Space home,
const VariableSequenceSymmetryImp< View > &  s 
)

Copy constructor.

Definition at line 203 of file sym-imp.hpp.

Member Function Documentation

◆ getVal()

template<class View >
int Gecode::Int::LDSB::VariableSequenceSymmetryImp< View >::getVal ( unsigned int  sequence,
unsigned int  position 
) const
protected

Get the value in the specified sequence at the specified position. (Both are zero-based.)

Definition at line 174 of file sym-imp.hpp.

◆ dispose()

template<class View >
size_t Gecode::Int::LDSB::VariableSequenceSymmetryImp< View >::dispose ( Space home)
virtual

Disposal.

Implements Gecode::Int::LDSB::SymmetryImp< View >.

Definition at line 216 of file sym-imp.hpp.

◆ update()

template<class View >
void Gecode::Int::LDSB::VariableSequenceSymmetryImp< View >::update ( Literal  l)
virtual

Search left-branch update.

Implements Gecode::Int::LDSB::SymmetryImp< View >.

Definition at line 270 of file sym-imp.hpp.

◆ symmetric() [1/3]

template<class View >
ArgArray< Literal > Gecode::Int::LDSB::VariableSequenceSymmetryImp< View >::symmetric ( Literal  l,
const ViewArray< View > &  x 
) const
virtual

Compute symmetric literals.

Implements Gecode::Int::LDSB::SymmetryImp< View >.

Definition at line 226 of file sym-imp.hpp.

◆ copy()

template<class View >
SymmetryImp< View > * Gecode::Int::LDSB::VariableSequenceSymmetryImp< View >::copy ( Space home) const
virtual

Copy function.

Implements Gecode::Int::LDSB::SymmetryImp< View >.

Definition at line 278 of file sym-imp.hpp.

◆ symmetric() [2/3]

◆ symmetric() [3/3]

Definition at line 97 of file sym-imp.cpp.

Member Data Documentation

◆ indices

template<class View >
unsigned int* Gecode::Int::LDSB::VariableSequenceSymmetryImp< View >::indices
protected

Array of variable indices.

Definition at line 227 of file ldsb.hh.

◆ n_indices

template<class View >
unsigned int Gecode::Int::LDSB::VariableSequenceSymmetryImp< View >::n_indices
protected

Total number of indices (n_seqs * seq_size)

Definition at line 229 of file ldsb.hh.

◆ seq_size

template<class View >
unsigned int Gecode::Int::LDSB::VariableSequenceSymmetryImp< View >::seq_size
protected

Size of each sequence in symmetry.

Definition at line 231 of file ldsb.hh.

◆ n_seqs

template<class View >
unsigned int Gecode::Int::LDSB::VariableSequenceSymmetryImp< View >::n_seqs
protected

Number of sequences in symmetry.

Definition at line 233 of file ldsb.hh.

◆ lookup

template<class View >
int* Gecode::Int::LDSB::VariableSequenceSymmetryImp< View >::lookup
protected

Map from variable's index to its sequence and position.

Definition at line 242 of file ldsb.hh.

◆ lookup_size

template<class View >
unsigned int Gecode::Int::LDSB::VariableSequenceSymmetryImp< View >::lookup_size
protected

Size of lookup.

Definition at line 244 of file ldsb.hh.


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