Gecode::Int::LDSB Namespace Reference

Symmetry breaking for integer variables. More...

## Classes

class | VariableMap
| Map from variable implementation to index. More...
class | Literal
| A Literal is a pair of variable index and value. More...
class | SymmetryObject
| Implementation of a symmetry at the modelling level. More...
class | VariableSymmetryObject
| Implementation of a variable symmetry at the modelling level. More...
class | ValueSymmetryObject
| Implementation of a value symmetry at the modelling level. More...
class | VariableSequenceSymmetryObject
| Implementation of a variable sequence symmetry at the modelling level. More...
class | ValueSequenceSymmetryObject
| Implementation of a value sequence symmetry at the modelling level. More...
class | SymmetryImp
| Implementation of a single symmetry. More...
class | VariableSymmetryImp
| Implementation of a variable symmetry. More...
class | ValueSymmetryImp
| Implementation of a value symmetry. More...
class | VariableSequenceSymmetryImp
| Implementation of a variable sequence symmetry. More...
class | ValueSequenceSymmetryImp
| Implementation of a value sequence symmetry. More...
class | LDSBChoice
| Choice storing position and value, and symmetric literals to be excluded on the right branch. More...
class | LDSBBrancher
| Symmetry-breaking brancher with generic view and value selection. More...

## Functions

std::pair< int, int > | findVar (int *indices, unsigned int n_values, unsigned int seq_size, int index)
| Find the location of an integer in a collection of sequences.
SymmetryImp< IntView > * | createIntSym (Space &home, const SymmetryHandle &s, VariableMap variableMap)
| Create an integer symmetry implementation from a symmetry handle.
SymmetryImp< BoolView > * | createBoolSym (Space &home, const SymmetryHandle &s, VariableMap variableMap)
| Create a boolean symmetry implementation from a symmetry handle.
template<class View, int n, class Val, unsigned int a>
void | postldsbbrancher (Home home, ViewArray< View > &x, ViewSel< View > *vs[n], ValSelCommitBase< View, Val > *vsc, SymmetryImp< View > **syms, int nsyms, BranchFilter< typename View::VarType > bf, VarValPrint< typename View::VarType, Val > vvp)
| Post LDSB brancher.
template<class View>
ModEvent | prune (Space &home, View x, int v)
| Exclude value \v from variable view \x.
template<>
ModEvent | prune< Int::IntView > (Space &home, Int::IntView x, int v)
template<>
ModEvent | prune< Int::BoolView > (Space &home, Int::BoolView x, int v)
template<class T, class A>
ArgArray< T > | dynamicStackToArgArray (const Support::DynamicStack< T, A > &s)
| Convert a DynamicStack<T,A> into an ArgArray<T>.
template<>
ModEvent | prune< Set::SetView > (Space &home, Set::SetView x, int v)

## Detailed Description

Symmetry breaking for integer variables.

## Function Documentation

## findVar()

std::pair< int, int > Gecode::Int::LDSB::findVar | ( | int * | indices,
|  | unsigned int | n_values,
|  | unsigned int | seq_size,
|  | int | index )

Find the location of an integer in a collection of sequences.

Given an array indices of integers (of length n_values), which represents a collection of sequences each of size seq_size, find the location of the first occurrence of the value index. Returns a pair of sequence number and position within that sequence (both zero-based).

Definition at line 42 of file ldsb.cpp.

## createIntSym()

SymmetryImp< IntView > * Gecode::Int::LDSB::createIntSym | ( | Space & | home,
|  | const SymmetryHandle & | s,
|  | VariableMap | variableMap )

Create an integer symmetry implementation from a symmetry handle.

Definition at line 140 of file ldsb.cpp.

## createBoolSym()

SymmetryImp< BoolView > * Gecode::Int::LDSB::createBoolSym | ( | Space & | home,
|  | const SymmetryHandle & | s,
|  | VariableMap | variableMap )

Create a boolean symmetry implementation from a symmetry handle.

Definition at line 197 of file ldsb.cpp.

## postldsbbrancher()

template<class View, int n, class Val, unsigned int a>

void Gecode::Int::LDSB::postldsbbrancher | ( | Home | home,
|  | ViewArray< View > & | x,
|  | ViewSel< View > * | vs[n],
|  | ValSelCommitBase< View, Val > * | vsc,
|  | SymmetryImp< View > ** | syms,
|  | int | nsyms,
|  | BranchFilter< typename View::VarType > | bf,
|  | VarValPrint< typename View::VarType, Val > | vvp )

inline

Post LDSB brancher.

Definition at line 275 of file brancher.hpp.

## prune()

template<class View>

ModEvent Gecode::Int::LDSB::prune | ( | Space & | home,
|  | View | x,
|  | int | v )

Exclude value \v from variable view \x.

## prune< Int::IntView >()

template<>

ModEvent Gecode::Int::LDSB::prune< Int::IntView > | ( | Space & | home,
|  | Int::IntView | x,
|  | int | v )

inline

Definition at line 215 of file brancher.hpp.

## prune< Int::BoolView >()

template<>

ModEvent Gecode::Int::LDSB::prune< Int::BoolView > | ( | Space & | home,
|  | Int::BoolView | x,
|  | int | v )

inline

Definition at line 222 of file brancher.hpp.

## dynamicStackToArgArray()

template<class T, class A>

ArgArray< T > Gecode::Int::LDSB::dynamicStackToArgArray | ( | const Support::DynamicStack< T, A > & | s | ) |

Convert a DynamicStack<T,A> into an ArgArray<T>.

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

## prune< Set::SetView >()

template<>

ModEvent Gecode::Int::LDSB::prune< Set::SetView > | ( | Space & | home,
|  | Set::SetView | x,
|  | int | v )

Definition at line 60 of file ldsb.cpp.