Scippy

SCIP

Solving Constraint Integer Programs

presol_symmetry.c File Reference

Detailed Description

presolver for storing symmetry information about current problem

Author
Marc Pfetsch
Thomas Rehn

This presolver computes symmetries of the problem and stores this information in adequate form. It does not perform additional actions. The symmetry information can be accessed through external functions. However, the user has to declare the type of symmetry that is needed before execution, see SYMsetSpecRequirement().

Note
We treat implict integer variables as if they were continuous/real variables. The reason is that there is currently no distinction between implicit integer and implicit binary. Moreover, currently implicit integer variables hurt our code more than continuous/real variables (we basically do not handle integral variables at all).
We do not copy symmetry information, since it is not clear how this information transfers. Moreover, copying symmetry might inhibit heuristics. But note that solving the a sub-SCIP might then happen without symmetry information!

Definition in file presol_symmetry.c.

#include <scip/cons_linear.h>
#include <scip/cons_knapsack.h>
#include <scip/cons_varbound.h>
#include <scip/cons_setppc.h>
#include <scip/cons_and.h>
#include <scip/cons_logicor.h>
#include <scip/cons_or.h>
#include <scip/cons_xor.h>
#include <scip/cons_linking.h>
#include <scip/cons_bounddisjunction.h>
#include <scip/presol_symmetry.h>
#include <symmetry/compute_symmetry.h>
#include <string.h>

Go to the source code of this file.

Data Structures

struct  SYM_Sortrhstype
 

Macros

#define PRESOL_NAME   "symmetry"
 
#define PRESOL_DESC   "presolver for computing and storing symmetry information about current problem"
 
#define PRESOL_PRIORITY   0
 
#define PRESOL_MAXROUNDS   -1
 
#define PRESOL_TIMING   SCIP_PRESOLTIMING_EXHAUSTIVE /* timing of the presolver (fast, medium, or exhaustive) */
 
#define DEFAULT_MAXGENERATORS   1500
 
#define DEFAULT_CHECKSYMMETRIES   FALSE
 
#define DEFAULT_DISPLAYNORBITVARS   FALSE
 
#define MAXGENNUMERATOR   64000000
 
#define SCIP_SPECIALVAL   1.12345678912345e+19
 

Typedefs

typedef struct SYM_Sortrhstype SYM_SORTRHSTYPE
 

Functions

static SCIP_DECL_HASHGETKEY (SYMhashGetKeyVartype)
 
static SCIP_DECL_HASHKEYEQ (SYMhashKeyEQVartype)
 
static SCIP_DECL_HASHKEYVAL (SYMhashKeyValVartype)
 
static SCIP_DECL_SORTINDCOMP (SYMsortRhsTypes)
 
static SCIP_DECL_SORTINDCOMP (SYMsortMatCoef)
 
static SCIP_Bool SymmetryFixVar (SYM_SPEC fixedtype, SCIP_VAR *var)
 
static SCIP_RETCODE getActiveVariables (SCIP *scip, SCIP_VAR ***vars, SCIP_Real **scalars, int *nvars, SCIP_Real *constant, SCIP_Bool transformed)
 
static SCIP_RETCODE collectCoefficients (SCIP *scip, SCIP_VAR **linvars, SCIP_Real *linvals, int nlinvars, SCIP_Real lhs, SCIP_Real rhs, SCIP_Bool istransformed, SYM_RHSSENSE rhssense, SYM_MATRIXDATA *matrixdata)
 
static SCIP_RETCODE checkSymmetriesAreSymmetries (SCIP *scip, SYM_SPEC fixedtype, SYM_MATRIXDATA *matrixdata, int nperms, int **perms)
 
static int getNSymhandableConss (SCIP *scip)
 
static SCIP_RETCODE computeSymmetryGroup (SCIP *scip, int maxgenerators, SYM_SPEC fixedtype, SCIP_Bool local, SCIP_Bool checksymmetries, int *npermvars, SCIP_VAR ***permvars, SCIP_Real **permvarsobj, int *nperms, int *nmaxperms, int ***perms, SCIP_Real *log10groupsize, SCIP_Bool *success)
 
static SCIP_RETCODE computeNOrbitVars (SCIP *scip, SCIP_PRESOLDATA *presoldata, SCIP_Bool completestatistic)
 
static SCIP_RETCODE determineSymmetry (SCIP *scip, SCIP_PRESOLDATA *presoldata, SYM_SPEC symspecrequire, SYM_SPEC symspecrequirefixed)
 
static SCIP_DECL_PRESOLINIT (presolInitSymmetry)
 
static SCIP_DECL_PRESOLEXIT (presolExitSymmetry)
 
static SCIP_DECL_PRESOLFREE (presolFreeSymmetry)
 
static SCIP_DECL_PRESOLEXEC (presolExecSymmetry)
 
SCIP_RETCODE SCIPincludePresolSymmetry (SCIP *scip)
 
SCIP_RETCODE SCIPgetGeneratorsSymmetry (SCIP *scip, SYM_SPEC symspecrequire, SYM_SPEC symspecrequirefixed, SCIP_Bool recompute, int *npermvars, SCIP_VAR ***permvars, int *nperms, int ***perms, SCIP_Real *log10groupsize, SCIP_Bool *binvaraffected)
 
SCIP_RETCODE SCIPgetPermvarsObjSymmetry (SCIP *scip, SCIP_Real **permvarsobj)
 

Macro Definition Documentation

◆ PRESOL_NAME

◆ PRESOL_DESC

#define PRESOL_DESC   "presolver for computing and storing symmetry information about current problem"

Definition at line 54 of file presol_symmetry.c.

Referenced by SCIPincludePresolSymmetry().

◆ PRESOL_PRIORITY

#define PRESOL_PRIORITY   0

priority of the presolver (>= 0: before, < 0: after constraint handlers)

Definition at line 55 of file presol_symmetry.c.

Referenced by SCIPincludePresolSymmetry().

◆ PRESOL_MAXROUNDS

#define PRESOL_MAXROUNDS   -1

maximal number of presolving rounds the presolver participates in (-1: no limit)

Definition at line 56 of file presol_symmetry.c.

Referenced by SCIPincludePresolSymmetry().

◆ PRESOL_TIMING

#define PRESOL_TIMING   SCIP_PRESOLTIMING_EXHAUSTIVE /* timing of the presolver (fast, medium, or exhaustive) */

Definition at line 57 of file presol_symmetry.c.

Referenced by SCIPincludePresolSymmetry().

◆ DEFAULT_MAXGENERATORS

#define DEFAULT_MAXGENERATORS   1500

limit on the number of generators that should be produced within symmetry detection (0 = no limit)

Definition at line 60 of file presol_symmetry.c.

Referenced by SCIPincludePresolSymmetry().

◆ DEFAULT_CHECKSYMMETRIES

#define DEFAULT_CHECKSYMMETRIES   FALSE

Should all symmetries be checked after computation?

Definition at line 61 of file presol_symmetry.c.

Referenced by SCIPincludePresolSymmetry().

◆ DEFAULT_DISPLAYNORBITVARS

#define DEFAULT_DISPLAYNORBITVARS   FALSE

Should the number of variables affected by some symmetry be displayed?

Definition at line 62 of file presol_symmetry.c.

Referenced by SCIPincludePresolSymmetry().

◆ MAXGENNUMERATOR

#define MAXGENNUMERATOR   64000000

determine maximal number of generators by dividing this number by the number of variables

Definition at line 65 of file presol_symmetry.c.

Referenced by determineSymmetry().

◆ SCIP_SPECIALVAL

#define SCIP_SPECIALVAL   1.12345678912345e+19

special floating point value for handling zeros in bound disjunctions

Definition at line 66 of file presol_symmetry.c.

Referenced by computeSymmetryGroup().

Typedef Documentation

◆ SYM_SORTRHSTYPE

Definition at line 159 of file presol_symmetry.c.

Function Documentation

◆ SCIP_DECL_HASHGETKEY()

static SCIP_DECL_HASHGETKEY ( SYMhashGetKeyVartype  )
static

gets the key of the given element

Definition at line 99 of file presol_symmetry.c.

◆ SCIP_DECL_HASHKEYEQ()

static SCIP_DECL_HASHKEYEQ ( SYMhashKeyEQVartype  )
static

returns TRUE iff both keys are equal

Compare the types of two variables according to objective, lower and upper bound, and variable type.

Definition at line 109 of file presol_symmetry.c.

References FALSE, SYM_Vartype::lb, SYM_Vartype::obj, SCIPisEQ(), TRUE, SYM_Vartype::type, and SYM_Vartype::ub.

◆ SCIP_DECL_HASHKEYVAL()

static SCIP_DECL_HASHKEYVAL ( SYMhashKeyValVartype  )
static

returns the hash value of the key

Definition at line 140 of file presol_symmetry.c.

References SYM_Vartype::lb, SYM_Vartype::obj, SCIPcombineTwoInt, SCIPhashTwo, SCIPrealHashCode(), and SYM_Vartype::ub.

◆ SCIP_DECL_SORTINDCOMP() [1/2]

static SCIP_DECL_SORTINDCOMP ( SYMsortRhsTypes  )
static

sort rhs types - first by sense, then by value

Due to numerical issues, we first sort by sense, then by value.

result: < 0: ind1 comes before (is better than) ind2 = 0: both indices have the same value

0: ind2 comes after (is worse than) ind2

Definition at line 171 of file presol_symmetry.c.

References SYM_Sortrhstype::nrhscoef, SCIP_Real, SYM_Sortrhstype::senses, and SYM_Sortrhstype::vals.

◆ SCIP_DECL_SORTINDCOMP() [2/2]

static SCIP_DECL_SORTINDCOMP ( SYMsortMatCoef  )
static

sort matrix coefficients

result: < 0: ind1 comes before (is better than) ind2 = 0: both indices have the same value

0: ind2 comes after (is worse than) ind2

Definition at line 205 of file presol_symmetry.c.

References SCIP_Real, and SYM_Sortrhstype::vals.

◆ SymmetryFixVar()

static SCIP_Bool SymmetryFixVar ( SYM_SPEC  fixedtype,
SCIP_VAR var 
)
static

determines whether variable should be fixed by permutations

Parameters
fixedtypebitset of variable types that should be fixed
varvariable to be considered

Definition at line 228 of file presol_symmetry.c.

References FALSE, SCIP_VARTYPE_BINARY, SCIP_VARTYPE_CONTINUOUS, SCIP_VARTYPE_IMPLINT, SCIP_VARTYPE_INTEGER, SCIPvarGetType(), SYM_SPEC_BINARY, SYM_SPEC_INTEGER, SYM_SPEC_REAL, and TRUE.

Referenced by checkSymmetriesAreSymmetries(), and computeSymmetryGroup().

◆ getActiveVariables()

static SCIP_RETCODE getActiveVariables ( SCIP scip,
SCIP_VAR ***  vars,
SCIP_Real **  scalars,
int *  nvars,
SCIP_Real constant,
SCIP_Bool  transformed 
)
static

Transforms given variables, scalars, and constant to the corresponding active variables, scalars, and constant.

Note
constant needs to be initialized!
Parameters
scipSCIP data structure
varspointer to vars array to get active variables for
scalarspointer to scalars a_1, ..., a_n in linear sum a_1*x_1 + ... + a_n*x_n + c
nvarspointer to number of variables and values in vars and vals array
constantpointer to constant c in linear sum a_1*x_1 + ... + a_n*x_n + c
transformedtransformed constraint?

Definition at line 249 of file presol_symmetry.c.

References NULL, SCIP_CALL, SCIP_OKAY, SCIPgetProbvarLinearSum(), SCIPreallocBufferArray, SCIPvarGetOrigvarSum(), and TRUE.

Referenced by collectCoefficients().

◆ collectCoefficients()

static SCIP_RETCODE collectCoefficients ( SCIP scip,
SCIP_VAR **  linvars,
SCIP_Real linvals,
int  nlinvars,
SCIP_Real  lhs,
SCIP_Real  rhs,
SCIP_Bool  istransformed,
SYM_RHSSENSE  rhssense,
SYM_MATRIXDATA matrixdata 
)
static

fill in matrix elements into coefficient arrays

Parameters
scipSCIP data structure
linvarsarray of linear variables
linvalsarray of linear coefficients values (or NULL if all linear coefficient values are 1)
nlinvarsnumber of linear variables
lhsleft hand side
rhsright hand side
istransformedwhether the constraint is transformed
rhssenseidentifier of constraint type
matrixdatamatrix data to be filled in

Definition at line 295 of file presol_symmetry.c.

References getActiveVariables(), SYM_Matrixdata::matcoef, SYM_Matrixdata::matidx, SYM_Matrixdata::matrhsidx, SYM_Matrixdata::matvaridx, SYM_Matrixdata::nmatcoef, SYM_Matrixdata::nmaxmatcoef, SYM_Matrixdata::nrhscoef, SYM_Sortrhstype::nrhscoef, NULL, SYM_Matrixdata::rhscoef, SYM_Matrixdata::rhsidx, SYM_Matrixdata::rhssense, SCIP_CALL, SCIP_OKAY, SCIP_Real, SCIPallocBufferArray, SCIPcalcMemGrowSize(), SCIPdebugMsg, SCIPduplicateBufferArray, SCIPfreeBufferArray, SCIPgetNVars(), SCIPisEQ(), SCIPisInfinity(), SCIPreallocBlockMemoryArray, SCIPvarGetProbindex(), SYM_SENSE_BOUNDIS_TYPE_2, SYM_SENSE_EQUATION, SYM_SENSE_INEQUALITY, SYM_SENSE_XOR, and SYM_Sortrhstype::vals.

Referenced by computeSymmetryGroup().

◆ checkSymmetriesAreSymmetries()

static SCIP_RETCODE checkSymmetriesAreSymmetries ( SCIP scip,
SYM_SPEC  fixedtype,
SYM_MATRIXDATA matrixdata,
int  nperms,
int **  perms 
)
static

checks whether given permutations form a symmetry of a MIP

We need the matrix and rhs in the original order in order to speed up the comparison process. The matrix is needed in the right order to easily check rows. The rhs is used because of cache effects.

Parameters
scipSCIP data structure
fixedtypevariable types that must be fixed by symmetries
matrixdatamatrix data
npermsnumber of permutations
permspermutations

Definition at line 487 of file presol_symmetry.c.

References FALSE, SYM_Matrixdata::matcoef, SYM_Matrixdata::matrhsidx, SYM_Matrixdata::matvaridx, SYM_Matrixdata::nmatcoef, SYM_Matrixdata::npermvars, SYM_Matrixdata::nrhscoef, SYM_Sortrhstype::nrhscoef, NULL, SYM_Matrixdata::permvars, SYM_Matrixdata::rhscoef, SYM_Matrixdata::rhssense, SCIP_Bool, SCIP_CALL, SCIP_ERROR, SCIP_OKAY, SCIP_Real, SCIPallocBlockMemoryArray, SCIPdebugMsg, SCIPerrorMessage, SCIPfreeBlockMemoryArray, SCIPisEQ(), SCIPisZero(), SymmetryFixVar(), and TRUE.

Referenced by computeSymmetryGroup().

◆ getNSymhandableConss()

static int getNSymhandableConss ( SCIP scip)
static

returns the number of active constraints that can be handled by symmetry

Parameters
scipSCIP instance

Definition at line 633 of file presol_symmetry.c.

References NULL, SCIPconshdlrGetNActiveConss(), and SCIPfindConshdlr().

Referenced by computeSymmetryGroup(), and determineSymmetry().

◆ computeSymmetryGroup()

static SCIP_RETCODE computeSymmetryGroup ( SCIP scip,
int  maxgenerators,
SYM_SPEC  fixedtype,
SCIP_Bool  local,
SCIP_Bool  checksymmetries,
int *  npermvars,
SCIP_VAR ***  permvars,
SCIP_Real **  permvarsobj,
int *  nperms,
int *  nmaxperms,
int ***  perms,
SCIP_Real log10groupsize,
SCIP_Bool success 
)
static

compute symmetry group of MIP

Parameters
scipSCIP pointer
maxgeneratorsmaximal number of generators constructed (= 0 if unlimited)
fixedtypevariable types that must be fixed by symmetries
localUse local variable bounds?
checksymmetriesShould all symmetries be checked after computation?
npermvarspointer to store number of variables for permutations
permvarspointer to store variables on which permutations act
permvarsobjobjective values of permuted variables
npermspointer to store number of permutations
nmaxpermspointer to store maximal number of permutations (needed for freeing storage)
permspointer to store permutation generators as (nperms x npermvars) matrix
log10groupsizepointer to store log10 of size of group
successpointer to store whether symmetry computation was successful

Definition at line 669 of file presol_symmetry.c.

References checkSymmetriesAreSymmetries(), collectCoefficients(), SYM_Vartype::color, FALSE, getNSymhandableConss(), SYM_Vartype::lb, SYM_Matrixdata::matcoef, SYM_Matrixdata::matcoefcolors, SYM_Matrixdata::matidx, SYM_Matrixdata::matrhsidx, SYM_Matrixdata::matvaridx, MAX, MIN, SYM_Matrixdata::nmatcoef, SYM_Matrixdata::nmaxmatcoef, SYM_Matrixdata::npermvars, SYM_Matrixdata::nrhscoef, SYM_Sortrhstype::nrhscoef, NULL, SYM_Matrixdata::nuniquemat, SYM_Matrixdata::nuniquerhs, SYM_Matrixdata::nuniquevars, SYM_Vartype::obj, SYM_Matrixdata::permvarcolors, SYM_Matrixdata::permvars, SYM_Matrixdata::rhscoef, SYM_Matrixdata::rhscoefcolors, SYM_Matrixdata::rhsidx, SYM_Matrixdata::rhssense, SCIP_Bool, SCIP_BOUNDTYPE_LOWER, SCIP_CALL, SCIP_ERROR, SCIP_INVALID, SCIP_Longint, SCIP_OKAY, SCIP_Real, SCIP_SETPPCTYPE_COVERING, SCIP_SETPPCTYPE_PACKING, SCIP_SETPPCTYPE_PARTITIONING, SCIP_SPECIALVAL, SCIP_STAGE_INITPRESOLVE, SCIP_STAGE_SOLVING, SCIP_VERBLEVEL_HIGH, SCIPallocBlockMemoryArray, SCIPblkmem(), SCIPconsGetHdlr(), SCIPconsGetName(), SCIPconshdlrGetName(), SCIPconsIsActive(), SCIPconsIsConflict(), SCIPconsIsTransformed(), SCIPdebugMsg, SCIPduplicateBlockMemoryArray, SCIPerrorMessage, SCIPfreeBlockMemoryArray, SCIPfreeBlockMemoryArrayNull, SCIPgetBinvarsLinking(), SCIPgetBoundsBounddisjunction(), SCIPgetBoundtypesBounddisjunction(), SCIPgetCapacityKnapsack(), SCIPgetConss(), SCIPgetIntvarLinking(), SCIPgetIntVarXor(), SCIPgetLhsLinear(), SCIPgetLhsVarbound(), SCIPgetNActiveConss(), SCIPgetNConss(), SCIPgetNFixedVars(), SCIPgetNVars(), SCIPgetNVarsAnd(), SCIPgetNVarsBounddisjunction(), SCIPgetNVarsKnapsack(), SCIPgetNVarsLinear(), SCIPgetNVarsLogicor(), SCIPgetNVarsOr(), SCIPgetNVarsSetppc(), SCIPgetNVarsXor(), SCIPgetResultantAnd(), SCIPgetResultantOr(), SCIPgetRhsLinear(), SCIPgetRhsVarbound(), SCIPgetRhsXor(), SCIPgetStage(), SCIPgetTypeSetppc(), SCIPgetValsLinear(), SCIPgetValsLinking(), SCIPgetVars(), SCIPgetVarsAnd(), SCIPgetVarsBounddisjunction(), SCIPgetVarsKnapsack(), SCIPgetVarsLinear(), SCIPgetVarsLogicor(), SCIPgetVarsOr(), SCIPgetVarsSetppc(), SCIPgetVarsXor(), SCIPgetVarVarbound(), SCIPgetVbdcoefVarbound(), SCIPgetVbdvarVarbound(), SCIPgetWeightsKnapsack(), SCIPhashtableCreate(), SCIPhashtableExists(), SCIPhashtableFree(), SCIPhashtableInsert(), SCIPhashtableRetrieve(), SCIPinfinity(), SCIPisEQ(), SCIPisStopped(), SCIPisZero(), SCIPmarkDoNotMultaggrVar(), SCIPsort(), SCIPvarGetLbGlobal(), SCIPvarGetLbLocal(), SCIPvarGetName(), SCIPvarGetObj(), SCIPvarGetProbindex(), SCIPvarGetType(), SCIPvarGetUbGlobal(), SCIPvarGetUbLocal(), SCIPverbMessage(), SYM_Sortrhstype::senses, SYM_SENSE_AND, SYM_SENSE_BOUNDIS_TYPE_1, SYM_SENSE_BOUNDIS_TYPE_2, SYM_SENSE_EQUATION, SYM_SENSE_INEQUALITY, SYM_SENSE_OR, SYM_SENSE_UNKOWN, SYM_SENSE_XOR, SYMcanComputeSymmetry(), SYMcomputeSymmetryGenerators(), SymmetryFixVar(), TRUE, SYM_Vartype::type, SYM_Vartype::ub, and SYM_Sortrhstype::vals.

Referenced by determineSymmetry().

◆ computeNOrbitVars()

static SCIP_RETCODE computeNOrbitVars ( SCIP scip,
SCIP_PRESOLDATA presoldata,
SCIP_Bool  completestatistic 
)
static
Parameters
scipSCIP instance
presoldatapresolver data
completestatisticwhether a complete statistic on affected vars should be computed

Definition at line 1308 of file presol_symmetry.c.

References NULL, SCIP_CALL, SCIP_OKAY, SCIP_Shortbool, SCIPallocClearBufferArray, SCIPfreeBufferArray, SCIPvarIsBinary(), and TRUE.

Referenced by determineSymmetry().

◆ determineSymmetry()

static SCIP_RETCODE determineSymmetry ( SCIP scip,
SCIP_PRESOLDATA presoldata,
SYM_SPEC  symspecrequire,
SYM_SPEC  symspecrequirefixed 
)
static

determine symmetry

Parameters
scipSCIP instance
presoldatapresolver data
symspecrequiresymmetry specification for which we need to compute symmetries
symspecrequirefixedsymmetry specification of variables which must be fixed by symmetries

Definition at line 1369 of file presol_symmetry.c.

References computeNOrbitVars(), computeSymmetryGroup(), FALSE, getNSymhandableConss(), MAXGENNUMERATOR, MIN, NULL, SCIP_CALL, SCIP_OKAY, SCIP_VERBLEVEL_HIGH, SCIPgetIntParam(), SCIPgetNActiveConss(), SCIPgetNActivePricers(), SCIPgetNBinVars(), SCIPgetNContVars(), SCIPgetNImplVars(), SCIPgetNIntVars(), SCIPgetNVars(), SCIPgetSolvingTime(), SCIPsetIntParam(), SCIPverbMessage(), SCIPwarningMessage(), SYM_SPEC_BINARY, SYM_SPEC_INTEGER, SYM_SPEC_REAL, SYMcanComputeSymmetry(), and TRUE.

Referenced by SCIPgetGeneratorsSymmetry().

◆ SCIP_DECL_PRESOLINIT()

static SCIP_DECL_PRESOLINIT ( presolInitSymmetry  )
static

initialization method of presolver (called after problem was transformed)

Definition at line 1550 of file presol_symmetry.c.

References NULL, PRESOL_NAME, SCIP_CALL, SCIP_OKAY, SCIPgetIntParam(), SCIPpresolGetData(), and SCIPpresolGetName().

◆ SCIP_DECL_PRESOLEXIT()

static SCIP_DECL_PRESOLEXIT ( presolExitSymmetry  )
static

deinitialization method of presolver (called before transformed problem is freed)

Definition at line 1569 of file presol_symmetry.c.

References FALSE, NULL, PRESOL_NAME, SCIP_CALL, SCIP_OKAY, SCIPdebugMsg, SCIPfreeBlockMemoryArray, SCIPfreeBlockMemoryArrayNull, SCIPpresolGetData(), SCIPpresolGetName(), and SCIPsetIntParam().

◆ SCIP_DECL_PRESOLFREE()

static SCIP_DECL_PRESOLFREE ( presolFreeSymmetry  )
static

destructor of presolver to free user data (called when SCIP is exiting)

Definition at line 1614 of file presol_symmetry.c.

References NULL, PRESOL_NAME, SCIP_OKAY, SCIPdebugMsg, SCIPfreeBlockMemory, SCIPpresolGetData(), and SCIPpresolGetName().

◆ SCIP_DECL_PRESOLEXEC()

static SCIP_DECL_PRESOLEXEC ( presolExecSymmetry  )
static

execution method of presolver

Definition at line 1635 of file presol_symmetry.c.

References NULL, PRESOL_NAME, SCIP_DIDNOTRUN, SCIP_OKAY, and SCIPpresolGetName().

◆ SCIPincludePresolSymmetry()

◆ SCIPgetGeneratorsSymmetry()

SCIP_RETCODE SCIPgetGeneratorsSymmetry ( SCIP scip,
SYM_SPEC  symspecrequire,
SYM_SPEC  symspecrequirefixed,
SCIP_Bool  recompute,
int *  npermvars,
SCIP_VAR ***  permvars,
int *  nperms,
int ***  perms,
SCIP_Real log10groupsize,
SCIP_Bool binvaraffected 
)

return symmetry group generators

Parameters
scipSCIP data structure
symspecrequiresymmetry specification for which we need to compute symmetries
symspecrequirefixedsymmetry specification of variables which must be fixed by symmetries
recomputeHave symmetries already been computed?
npermvarspointer to store number of variables for permutations
permvarspointer to store variables on which permutations act
npermspointer to store number of permutations
permspointer to store permutation generators as (nperms x npermvars) matrix
log10groupsizepointer to store log10 of group size (or NULL)
binvaraffectedpointer to store whether binary variables are affected

Definition at line 1712 of file presol_symmetry.c.

References determineSymmetry(), FALSE, NULL, PRESOL_NAME, SCIP_CALL, SCIP_INVALIDCALL, SCIP_OKAY, SCIP_PLUGINNOTFOUND, SCIP_STAGE_EXITPRESOLVE, SCIP_STAGE_INITPRESOLVE, SCIP_STAGE_INITSOLVE, SCIP_STAGE_PRESOLVED, SCIP_STAGE_PRESOLVING, SCIP_STAGE_SOLVING, SCIPerrorMessage, SCIPfindPresol(), SCIPfreeBlockMemoryArray, SCIPfreeBlockMemoryArrayNull, SCIPgetStage(), SCIPpresolGetData(), and SCIPpresolGetName().

Referenced by getSymmetries(), and tryAddSymmetryHandlingConss().

◆ SCIPgetPermvarsObjSymmetry()

SCIP_RETCODE SCIPgetPermvarsObjSymmetry ( SCIP scip,
SCIP_Real **  permvarsobj 
)

return objective coefficients of permuted variables at time of symmetry computation

Parameters
scipSCIP data structure
permvarsobjpointer to store objective coefficients of permuted variables (NULL if not available)

Definition at line 1799 of file presol_symmetry.c.

References NULL, PRESOL_NAME, SCIP_OKAY, SCIP_PLUGINNOTFOUND, SCIPerrorMessage, SCIPfindPresol(), SCIPpresolGetData(), and SCIPpresolGetName().

Referenced by propagateOrbitalFixing().