Detailed Description
public methods for working with decomposition structures
public methods for working with priority queues
Definition in file pub_decomp.h.
#include "type_decomp.h"
#include "scip/type_scip.h"
#include "scip/type_retcode.h"
#include "scip/type_var.h"
#include "scip/type_cons.h"
#include "scip/type_misc.h"
#include "type_detector.h"
Go to the source code of this file.
Data Structures | |
struct | Dec_Scores |
typedef struct Dec_Scores | DEC_SCORES |
const char * | DECgetStrType (DEC_DECTYPE type) |
SCIP_RETCODE | DECdecompCreate (SCIP *scip, DEC_DECOMP **decomp) |
SCIP_RETCODE | DECdecompFree (SCIP *scip, DEC_DECOMP **decomp) |
SCIP_RETCODE | DECdecompSetType (DEC_DECOMP *decomp, DEC_DECTYPE type) |
DEC_DECTYPE | DECdecompGetType (DEC_DECOMP *decomp) |
SCIP_Real | DECdecompGetMaxwhiteScore (DEC_DECOMP *decomp) |
void | DECsetMaxWhiteScore (SCIP *scip, DEC_DECOMP *decomp, SCIP_Real maxwhitescore) |
void | DECdecompSetPresolved (DEC_DECOMP *decomp, SCIP_Bool presolved) |
SCIP_Bool | DECdecompGetPresolved (DEC_DECOMP *decomp) |
void | DECdecompSetNBlocks (DEC_DECOMP *decomp, int nblocks) |
int | DECdecompGetNBlocks (DEC_DECOMP *decomp) |
SCIP_RETCODE | DECdecompSetSubscipvars (SCIP *scip, DEC_DECOMP *decomp, SCIP_VAR ***subscipvars, int *nsubscipvars) |
SCIP_VAR *** | DECdecompGetSubscipvars (DEC_DECOMP *decomp) |
int * | DECdecompGetNSubscipvars (DEC_DECOMP *decomp) |
SCIP_RETCODE | DECdecompSetSubscipconss (SCIP *scip, DEC_DECOMP *decomp, SCIP_CONS ***subscipconss, int *nsubscipconss) |
SCIP_CONS *** | DECdecompGetSubscipconss (DEC_DECOMP *decomp) |
int * | DECdecompGetNSubscipconss (DEC_DECOMP *decomp) |
SCIP_RETCODE | DECdecompSetLinkingconss (SCIP *scip, DEC_DECOMP *decomp, SCIP_CONS **linkingconss, int nlinkingconss) |
SCIP_CONS ** | DECdecompGetLinkingconss (DEC_DECOMP *decomp) |
int | DECdecompGetNLinkingconss (DEC_DECOMP *decomp) |
SCIP_RETCODE | DECdecompSetLinkingvars (SCIP *scip, DEC_DECOMP *decomp, SCIP_VAR **linkingvars, int nlinkingvars, int nfixedlinkingvars, int nmastervars) |
SCIP_VAR ** | DECdecompGetLinkingvars (DEC_DECOMP *decomp) |
int | DECdecompGetNMastervars (DEC_DECOMP *decomp) |
int | DECdecompGetNLinkingvars (DEC_DECOMP *decomp) |
int | DECdecompGetNFixedLinkingvars (DEC_DECOMP *decomp) |
SCIP_RETCODE | DECdecompSetStairlinkingvars (SCIP *scip, DEC_DECOMP *decomp, SCIP_VAR ***stairlinkingvars, int *nstairlinkingvars) |
SCIP_VAR *** | DECdecompGetStairlinkingvars (DEC_DECOMP *decomp) |
int * | DECdecompGetNStairlinkingvars (DEC_DECOMP *decomp) |
int | DECdecompGetNTotalStairlinkingvars (DEC_DECOMP *decomp) |
void | DECdecompSetVartoblock (DEC_DECOMP *decomp, SCIP_HASHMAP *vartoblock) |
SCIP_HASHMAP * | DECdecompGetVartoblock (DEC_DECOMP *decomp) |
void | DECdecompSetConstoblock (DEC_DECOMP *decomp, SCIP_HASHMAP *constoblock) |
SCIP_HASHMAP * | DECdecompGetConstoblock (DEC_DECOMP *decomp) |
void | DECdecompSetVarindex (DEC_DECOMP *decomp, SCIP_HASHMAP *varindex) |
SCIP_HASHMAP * | DECdecompGetVarindex (DEC_DECOMP *decomp) |
void | DECdecompSetConsindex (DEC_DECOMP *decomp, SCIP_HASHMAP *consindex) |
SCIP_HASHMAP * | DECdecompGetConsindex (DEC_DECOMP *decomp) |
SCIP_RETCODE | DECfilloutDecompFromHashmaps (SCIP *scip, DEC_DECOMP *decomp, SCIP_HASHMAP *vartoblock, SCIP_HASHMAP *constoblock, int nblocks, SCIP_Bool staircase) |
SCIP_RETCODE | DECfilloutDecompFromConstoblock (SCIP *scip, DEC_DECOMP *decomp, SCIP_HASHMAP *constoblock, int nblocks, SCIP_Bool staircase) |
void | DECdecompSetDetector (DEC_DECOMP *decomp, DEC_DETECTOR *detector) |
DEC_DETECTOR * | DECdecompGetDetector (DEC_DECOMP *decomp) |
DEC_DETECTOR ** | DECdecompGetDetectorChain (DEC_DECOMP *decomp) |
int | DECdecompGetDetectorChainSize (DEC_DECOMP *decomp) |
int | DECdecompGetPartialdecID (DEC_DECOMP *decomp) |
void | DECdecompSetDetectorClockTimes (SCIP *scip, DEC_DECOMP *decomp, SCIP_Real *detectorClockTimes) |
SCIP_Real * | DECdecompGetDetectorClockTimes (DEC_DECOMP *decomp) |
SCIP_RETCODE | DECdecompSetDetectorChainString (SCIP *scip, DEC_DECOMP *decomp, const char *detectorchainstring) |
char * | DECdecompGetDetectorChainString (SCIP *scip, DEC_DECOMP *decomp) |
void | DECdecompSetDetectorPctVarsToBorder (SCIP *scip, DEC_DECOMP *decomp, SCIP_Real *pctVarsToBorder) |
SCIP_Real * | DECdecompGetDetectorPctVarsToBorder (DEC_DECOMP *decomp) |
void | DECdecompSetDetectorPctConssToBorder (SCIP *scip, DEC_DECOMP *decomp, SCIP_Real *pctConssToBorder) |
SCIP_Real * | DECdecompGetDetectorPctConssToBorder (DEC_DECOMP *decomp) |
void | DECdecompSetDetectorPctVarsToBlock (SCIP *scip, DEC_DECOMP *decomp, SCIP_Real *pctVarsToBlock) |
SCIP_Real * | DECdecompGetDetectorPctVarsToBlock (DEC_DECOMP *decomp) |
void | DECdecompSetDetectorPctConssToBlock (SCIP *scip, DEC_DECOMP *decomp, SCIP_Real *pctConssToBlock) |
SCIP_Real * | DECdecompGetDetectorPctConssToBlock (DEC_DECOMP *decomp) |
void | DECdecompSetDetectorPctVarsFromOpen (SCIP *scip, DEC_DECOMP *decomp, SCIP_Real *pctVarsFromOpen) |
SCIP_Real * | DECdecompGetDetectorPctVarsFromOpen (DEC_DECOMP *decomp) |
void | DECdecompSetDetectorPctConssFromOpen (SCIP *scip, DEC_DECOMP *decomp, SCIP_Real *pctConssToBorder) |
SCIP_Real * | DECdecompGetDetectorPctConssFromOpen (DEC_DECOMP *decomp) |
void | DECdecompSetNNewBlocks (SCIP *scip, DEC_DECOMP *decomp, int *nNewBlocks) |
int * | DECdecompGetNNewBlocks (DEC_DECOMP *decomp) |
SCIP_RETCODE | DECdecompTransform (SCIP *scip, DEC_DECOMP *decomp) |
SCIP_RETCODE | DECdecompRemoveDeletedConss (SCIP *scip, DEC_DECOMP *decomp) |
SCIP_RETCODE | DECdecompAddRemainingConss (SCIP *scip, DEC_DECOMP *decomp) |
SCIP_RETCODE | DECdecompCheckConsistency (SCIP *scip, DEC_DECOMP *decomp) |
SCIP_RETCODE | DECcreateBasicDecomp (SCIP *scip, DEC_DECOMP **decomp, SCIP_Bool solveorigprob) |
SCIP_RETCODE | DECcreateDecompFromMasterconss (SCIP *scip, DEC_DECOMP **decomp, SCIP_CONS **conss, int nconss) |
void | DECgetSubproblemVarsData (SCIP *scip, DEC_DECOMP *decomp, int *nvars, int *nbinvars, int *nintvars, int *nimplvars, int *ncontvars, int nproblems) |
void | DECgetLinkingVarsData (SCIP *scip, DEC_DECOMP *decomp, int *nvars, int *nbinvars, int *nintvars, int *nimplvars, int *ncontvars) |
SCIP_RETCODE | DECgetDensityData (SCIP *scip, DEC_DECOMP *decomp, SCIP_VAR **vars, int nvars, SCIP_CONS **conss, int nconss, int *varsubproblemdensity, int *varmasterdensity, int *conssubproblemdensity, int *consmasterdensity) |
SCIP_RETCODE | DECgetVarLockData (SCIP *scip, DEC_DECOMP *decomp, SCIP_VAR **vars, int nvars, int nsubproblems, int **subsciplocksdown, int **subsciplocksup, int *masterlocksdown, int *masterlocksup) |
SCIP_Real | DECgetMaxWhiteScore (SCIP *scip, DEC_DECOMP *decomp) |
SCIP_RETCODE | DECevaluateDecomposition (SCIP *scip, DEC_DECOMP *decomp, DEC_SCORES *score) |
int | DECdecompGetNConss (DEC_DECOMP *decomp) |
SCIP_RETCODE | GCGprintDecompStatistics (SCIP *scip, FILE *file, DEC_DECOMP *decomp) |
SCIP_Bool | DECdecompositionsAreEqual (SCIP *scip, DEC_DECOMP *decomp1, DEC_DECOMP *decomp2) |
int | DECfilterSimilarDecompositions (SCIP *scip, DEC_DECOMP **decs, int ndecs) |
SCIP_RETCODE | DECdetermineConsBlock (SCIP *scip, DEC_DECOMP *decomp, SCIP_CONS *cons, int *block) |
SCIP_RETCODE | DECdecompMoveLinkingConsToPricing (SCIP *scip, DEC_DECOMP *decomp, int consindex, int block) |
SCIP_RETCODE | DECtryAssignMasterconssToExistingPricing (SCIP *scip, DEC_DECOMP *decomp, int *transferred) |
SCIP_RETCODE | DECtryAssignMasterconssToNewPricing (SCIP *scip, DEC_DECOMP *decomp, DEC_DECOMP **newdecomp, int *transferred) |
SCIP_RETCODE | DECcreatePolishedDecomp (SCIP *scip, DEC_DECOMP *decomp, DEC_DECOMP **newdecomp) |
SCIP_RETCODE | DECpermuteDecomp (SCIP *scip, DEC_DECOMP *decomp, SCIP_RANDNUMGEN *randnumgen) |
int | DECgetNDecomps (SCIP *scip) |
Typedef Documentation
◆ DEC_SCORES
typedef struct Dec_Scores DEC_SCORES |
Definition at line 66 of file pub_decomp.h.
Function Documentation
◆ DECgetStrType()
const char* DECgetStrType | ( | DEC_DECTYPE | type | ) |
converts the DEC_DECTYPE enum to a string
- Parameters
-
type decomposition type
Definition at line 462 of file decomp.c.
Referenced by DECevaluateDecomposition(), GCGprintDecompStatistics(), and GCGwriteDecompositionData().
◆ DECdecompCreate()
SCIP_RETCODE DECdecompCreate | ( | SCIP * | scip, |
DEC_DECOMP ** | decdecomp | ||
) |
initializes the decomposition to absolutely nothing
Definition at line 471 of file decomp.c.
References DecDecomp::consindex, DecDecomp::constoblock, DEC_DECTYPE_UNKNOWN, DecDecomp::detector, DecDecomp::detectorchain, DecDecomp::detectorchainstring, DecDecomp::detectorclocktimes, GCGconshdlrDecompIncreaseNCallsCreateDecomp(), DecDecomp::linkingconss, DecDecomp::linkingvars, DecDecomp::maxwhitescore, DecDecomp::nblocks, DecDecomp::nfixedlinkingvars, DecDecomp::nlinkingconss, DecDecomp::nlinkingvars, DecDecomp::nmastervars, DecDecomp::nnewblocks, DecDecomp::nstairlinkingvars, DecDecomp::nsubscipconss, DecDecomp::nsubscipvars, DecDecomp::partialdecid, DecDecomp::pctconssfromopen, DecDecomp::pctconsstoblock, DecDecomp::pctconsstoborder, DecDecomp::pctvarsfromopen, DecDecomp::pctvarstoblock, DecDecomp::pctvarstoborder, DecDecomp::presolved, DecDecomp::sizedetectorchain, DecDecomp::stairlinkingvars, DecDecomp::subscipconss, DecDecomp::subscipvars, DecDecomp::type, DecDecomp::varindex, and DecDecomp::vartoblock.
Referenced by createDecompFromPartialdec(), gcg::ColumnGraph< T >::createDecompFromPartition(), gcg::RowGraph< T >::createDecompFromPartition(), gcg::HyperrowcolGraph< T >::createDecompFromPartition(), gcg::HyperrowGraph< T >::createDecompFromPartition(), gcg::HypercolGraph< T >::createDecompFromPartition(), DECcreateBasicDecomp(), DECcreateDecompFromMasterconss(), DECtryAssignMasterconssToNewPricing(), readBLKFile(), and SCIPreadRef().
◆ DECdecompFree()
SCIP_RETCODE DECdecompFree | ( | SCIP * | scip, |
DEC_DECOMP ** | decdecomp | ||
) |
frees the decomposition
frees the decdecomp structure
Definition at line 530 of file decomp.c.
References DecDecomp::consindex, DecDecomp::constoblock, DecDecomp::detectorchain, DecDecomp::detectorchainstring, DecDecomp::detectorclocktimes, GCGconshdlrDecompDecreaseNCallsCreateDecomp(), DecDecomp::linkingconss, DecDecomp::linkingvars, DecDecomp::nblocks, DecDecomp::nlinkingconss, DecDecomp::nlinkingvars, DecDecomp::nnewblocks, DecDecomp::nstairlinkingvars, DecDecomp::nsubscipconss, DecDecomp::nsubscipvars, DecDecomp::pctconssfromopen, DecDecomp::pctconsstoblock, DecDecomp::pctconsstoborder, DecDecomp::pctvarsfromopen, DecDecomp::pctvarstoblock, DecDecomp::pctvarstoborder, DecDecomp::sizedetectorchain, DecDecomp::stairlinkingvars, DecDecomp::subscipconss, DecDecomp::subscipvars, DecDecomp::varindex, and DecDecomp::vartoblock.
Referenced by DECcreatePolishedDecomp(), GCGconshdlrDecompGetDecomps(), GCGsetStructDecomp(), GCGsolve(), GCGwriteDecompositionData(), readBLKFile(), SCIP_DECL_CONSEXIT(), SCIP_DECL_DIALOGEXEC(), SCIP_DECL_RELAXEXIT(), SCIP_DECL_RELAXEXITSOL(), SCIP_DECL_RELAXFREE(), SCIPreadRef(), and writeREFFile().
◆ DECdecompSetType()
SCIP_RETCODE DECdecompSetType | ( | DEC_DECOMP * | decomp, |
DEC_DECTYPE | type | ||
) |
sets the type of the decomposition
Definition at line 647 of file decomp.c.
References DEC_DECTYPE_ARROWHEAD, DEC_DECTYPE_BORDERED, DEC_DECTYPE_DIAGONAL, DEC_DECTYPE_STAIRCASE, DEC_DECTYPE_UNKNOWN, DecDecomp::linkingconss, DecDecomp::linkingvars, DecDecomp::nlinkingconss, DecDecomp::nlinkingvars, and DecDecomp::type.
Referenced by createDecompFromPartialdec(), DECfilloutDecompFromHashmaps(), fillDecompStruct(), and removeFromLinkingvars().
◆ DECdecompGetType()
DEC_DECTYPE DECdecompGetType | ( | DEC_DECOMP * | decomp | ) |
gets the type of the decomposition
Definition at line 691 of file decomp.c.
References DecDecomp::type.
Referenced by DECdecompCheckConsistency(), DECevaluateDecomposition(), DECgetLinkingVarsData(), DECgetSubproblemVarsData(), GCGprintDecompStatistics(), GCGwriteDecompositionData(), SCIP_DECL_DIALOGEXEC(), and solveMasterProblem().
◆ DECdecompGetMaxwhiteScore()
SCIP_Real DECdecompGetMaxwhiteScore | ( | DEC_DECOMP * | decomp | ) |
- Parameters
-
decomp decomposition data structure
Definition at line 701 of file decomp.c.
References DecDecomp::maxwhitescore.
Referenced by initRelaxator().
◆ DECsetMaxWhiteScore()
void DECsetMaxWhiteScore | ( | SCIP * | scip, |
DEC_DECOMP * | decdecomp, | ||
SCIP_Real | maxwhitescore | ||
) |
sets the score of the given decomposition based on the border, the average density score and the ratio of linking variables
Definition at line 3253 of file decomp.c.
References DecDecomp::maxwhitescore.
Referenced by createDecompFromPartialdec().
◆ DECdecompSetPresolved()
void DECdecompSetPresolved | ( | DEC_DECOMP * | decomp, |
SCIP_Bool | presolved | ||
) |
sets the presolved flag for decomposition
Definition at line 712 of file decomp.c.
References DecDecomp::presolved.
Referenced by createDecompFromPartialdec(), DECcreateBasicDecomp(), fillDecompStruct(), and readREFFile().
◆ DECdecompGetPresolved()
SCIP_Bool DECdecompGetPresolved | ( | DEC_DECOMP * | decomp | ) |
gets the presolved flag for decomposition
Definition at line 723 of file decomp.c.
References DecDecomp::presolved.
◆ DECdecompSetNBlocks()
void DECdecompSetNBlocks | ( | DEC_DECOMP * | decomp, |
int | nblocks | ||
) |
sets the number of blocks for decomposition
Definition at line 733 of file decomp.c.
References DecDecomp::nblocks.
Referenced by createDecompFromPartialdec(), DECfilloutDecompFromHashmaps(), fillDecompStruct(), and readREFFile().
◆ DECdecompGetNBlocks()
int DECdecompGetNBlocks | ( | DEC_DECOMP * | decomp | ) |
gets the number of blocks for decomposition
Definition at line 745 of file decomp.c.
References DecDecomp::nblocks.
Referenced by computeConssNzeros(), computeNonzeros(), convertStructToGCG(), createPartialdecFromDecomp(), createPricingprobConss(), createPricingVariables(), DECcreatePolishedDecomp(), DECdecompAddRemainingConss(), DECdecompCheckConsistency(), DECdecompGetNConss(), DECdecompGetNTotalStairlinkingvars(), DECdecompositionsAreEqual(), DECdetermineConsBlock(), DECevaluateDecomposition(), DECgetDensityData(), DECgetVarLockData(), DECpermuteDecomp(), DECtryAssignMasterconssToExistingPricing(), GCGprintDecompStatistics(), GCGwriteDecompositionData(), initRelaxator(), and writeREFFile().
◆ DECdecompSetSubscipvars()
SCIP_RETCODE DECdecompSetSubscipvars | ( | SCIP * | scip, |
DEC_DECOMP * | decomp, | ||
SCIP_VAR *** | subscipvars, | ||
int * | nsubscipvars | ||
) |
copies the input subscipvars array to the given decomposition
Definition at line 755 of file decomp.c.
References DecDecomp::nblocks, DecDecomp::nsubscipvars, and DecDecomp::subscipvars.
Referenced by createDecompFromPartialdec(), and fillOutVarsFromVartoblock().
◆ DECdecompGetSubscipvars()
SCIP_VAR*** DECdecompGetSubscipvars | ( | DEC_DECOMP * | decomp | ) |
returns the subscipvars array of the given decomposition
Definition at line 823 of file decomp.c.
References DecDecomp::subscipvars.
Referenced by computeVarDensities(), convertStructToGCG(), DECdecompCheckConsistency(), DECgetSubproblemVarsData(), and DECpermuteDecomp().
◆ DECdecompGetNSubscipvars()
int* DECdecompGetNSubscipvars | ( | DEC_DECOMP * | decomp | ) |
returns the nsubscipvars array of the given decomposition
Definition at line 833 of file decomp.c.
References DecDecomp::nsubscipvars.
Referenced by computeVarDensities(), convertStructToGCG(), DECdecompCheckConsistency(), DECevaluateDecomposition(), DECfilloutDecompFromHashmaps(), DECgetSubproblemVarsData(), DECpermuteDecomp(), and GCGwriteDecompositionData().
◆ DECdecompSetSubscipconss()
SCIP_RETCODE DECdecompSetSubscipconss | ( | SCIP * | scip, |
DEC_DECOMP * | decomp, | ||
SCIP_CONS *** | subscipconss, | ||
int * | nsubscipconss | ||
) |
copies the input subscipconss array to the given decomposition
Definition at line 843 of file decomp.c.
References DecDecomp::nblocks, DecDecomp::nsubscipconss, and DecDecomp::subscipconss.
Referenced by createDecompFromPartialdec(), and fillOutConsFromConstoblock().
◆ DECdecompGetSubscipconss()
SCIP_CONS*** DECdecompGetSubscipconss | ( | DEC_DECOMP * | decomp | ) |
returns the subscipconss array of the given decomposition
Definition at line 908 of file decomp.c.
References DecDecomp::subscipconss.
Referenced by computeNonzeros(), convertStructToGCG(), createPricingprobConss(), DECdecompCheckConsistency(), DECevaluateDecomposition(), DECfilloutDecompFromHashmaps(), DECgetDensityData(), DECgetVarLockData(), DECpermuteDecomp(), and writeREFFile().
◆ DECdecompGetNSubscipconss()
int* DECdecompGetNSubscipconss | ( | DEC_DECOMP * | decomp | ) |
returns the nsubscipconss array of the given decomposition
Definition at line 917 of file decomp.c.
References DecDecomp::nsubscipconss.
Referenced by computeNonzeros(), computeVarDensities(), convertStructToGCG(), createPricingprobConss(), DECdecompCheckConsistency(), DECdecompGetNConss(), DECevaluateDecomposition(), DECfilloutDecompFromHashmaps(), DECgetDensityData(), DECgetVarLockData(), DECpermuteDecomp(), GCGprintDecompStatistics(), GCGwriteDecompositionData(), and writeREFFile().
◆ DECdecompSetLinkingconss()
SCIP_RETCODE DECdecompSetLinkingconss | ( | SCIP * | scip, |
DEC_DECOMP * | decomp, | ||
SCIP_CONS ** | linkingconss, | ||
int | nlinkingconss | ||
) |
copies the input linkingconss array to the given decomposition
Definition at line 926 of file decomp.c.
References DecDecomp::linkingconss, and DecDecomp::nlinkingconss.
Referenced by createDecompFromPartialdec(), and fillOutConsFromConstoblock().
◆ DECdecompGetLinkingconss()
SCIP_CONS** DECdecompGetLinkingconss | ( | DEC_DECOMP * | decomp | ) |
returns the linkingconss array of the given decomposition
Definition at line 967 of file decomp.c.
References DecDecomp::linkingconss.
Referenced by checkSetppcStructure(), computeNonzeros(), convertStructToGCG(), createMasterprobConss(), createPartialdecFromDecomp(), DECdecompCheckConsistency(), DECgetDensityData(), DECgetVarLockData(), and DECpermuteDecomp().
◆ DECdecompGetNLinkingconss()
int DECdecompGetNLinkingconss | ( | DEC_DECOMP * | decomp | ) |
returns the nlinkingconss array of the given decomposition
Definition at line 977 of file decomp.c.
References DecDecomp::nlinkingconss.
Referenced by checkSetppcStructure(), computeNonzeros(), computeVarDensities(), convertStructToGCG(), createDecompFromPartialdec(), createMasterprobConss(), createPartialdecFromDecomp(), DECdecompCheckConsistency(), DECdecompGetNConss(), DECevaluateDecomposition(), DECgetDensityData(), DECpermuteDecomp(), GCGprintDecompStatistics(), GCGwriteDecompositionData(), initRelaxator(), and removeFromLinkingvars().
◆ DECdecompSetLinkingvars()
SCIP_RETCODE DECdecompSetLinkingvars | ( | SCIP * | scip, |
DEC_DECOMP * | decomp, | ||
SCIP_VAR ** | linkingvars, | ||
int | nlinkingvars, | ||
int | nfixedlinkingvars, | ||
int | nmastervars | ||
) |
copies the input linkingvars array to the given decomposition
copies the input linkingvars array to the given decdecomp structure
Definition at line 989 of file decomp.c.
References DecDecomp::linkingvars, DecDecomp::nfixedlinkingvars, DecDecomp::nlinkingvars, and DecDecomp::nmastervars.
Referenced by createDecompFromPartialdec(), and fillOutVarsFromVartoblock().
◆ DECdecompGetLinkingvars()
SCIP_VAR** DECdecompGetLinkingvars | ( | DEC_DECOMP * | decomp | ) |
returns the linkingvars array of the given decomposition
Definition at line 1036 of file decomp.c.
References DecDecomp::linkingvars.
Referenced by convertStructToGCG(), DECdecompCheckConsistency(), DECgetLinkingVarsData(), and DECpermuteDecomp().
◆ DECdecompGetNMastervars()
int DECdecompGetNMastervars | ( | DEC_DECOMP * | decomp | ) |
returns the number of master variables of the given decomposition
returns the number of linking variables that are purely master ("static") variables of the given decomposition
Definition at line 1069 of file decomp.c.
References DecDecomp::nmastervars.
Referenced by DECevaluateDecomposition(), GCGprintDecompStatistics(), and initRelaxator().
◆ DECdecompGetNLinkingvars()
int DECdecompGetNLinkingvars | ( | DEC_DECOMP * | decomp | ) |
returns the nlinkingvars array of the given decomposition
Definition at line 1046 of file decomp.c.
References DecDecomp::nlinkingvars.
Referenced by convertStructToGCG(), createDecompFromPartialdec(), DECdecompCheckConsistency(), DECevaluateDecomposition(), DECgetLinkingVarsData(), DECgetVarLockData(), DECpermuteDecomp(), GCGwriteDecompositionData(), and initRelaxator().
◆ DECdecompGetNFixedLinkingvars()
int DECdecompGetNFixedLinkingvars | ( | DEC_DECOMP * | decomp | ) |
returns the nlinkingvars array of the given decomposition
Definition at line 1057 of file decomp.c.
References DecDecomp::nfixedlinkingvars.
◆ DECdecompSetStairlinkingvars()
SCIP_RETCODE DECdecompSetStairlinkingvars | ( | SCIP * | scip, |
DEC_DECOMP * | decomp, | ||
SCIP_VAR *** | stairlinkingvars, | ||
int * | nstairlinkingvars | ||
) |
copies the input stairlinkingvars array to the given decomposition
Definition at line 1081 of file decomp.c.
References DecDecomp::nblocks, DecDecomp::nstairlinkingvars, and DecDecomp::stairlinkingvars.
Referenced by createDecompFromPartialdec(), and DECfilloutDecompFromHashmaps().
◆ DECdecompGetStairlinkingvars()
SCIP_VAR*** DECdecompGetStairlinkingvars | ( | DEC_DECOMP * | decomp | ) |
returns the stairlinkingvars array of the given decomposition
Definition at line 1151 of file decomp.c.
References DecDecomp::stairlinkingvars.
Referenced by createPartialdecFromDecomp().
◆ DECdecompGetNStairlinkingvars()
int* DECdecompGetNStairlinkingvars | ( | DEC_DECOMP * | decomp | ) |
returns the nstairlinkingvars array of the given decomposition
Definition at line 1160 of file decomp.c.
References DecDecomp::nstairlinkingvars.
Referenced by createPartialdecFromDecomp(), and DECdecompGetNTotalStairlinkingvars().
◆ DECdecompGetNTotalStairlinkingvars()
int DECdecompGetNTotalStairlinkingvars | ( | DEC_DECOMP * | decomp | ) |
returns the total number of stairlinkingvars array of the given decomposition
Definition at line 1170 of file decomp.c.
References DECdecompGetNBlocks(), and DECdecompGetNStairlinkingvars().
Referenced by DECdecompCheckConsistency().
◆ DECdecompSetVartoblock()
void DECdecompSetVartoblock | ( | DEC_DECOMP * | decomp, |
SCIP_HASHMAP * | vartoblock | ||
) |
sets the vartoblock hashmap of the given decomposition
Definition at line 1187 of file decomp.c.
References DecDecomp::vartoblock.
Referenced by createDecompFromPartialdec(), and fillOutVarsFromVartoblock().
◆ DECdecompGetVartoblock()
SCIP_HASHMAP* DECdecompGetVartoblock | ( | DEC_DECOMP * | decomp | ) |
returns the vartoblock hashmap of the given decomposition
Definition at line 1199 of file decomp.c.
References DecDecomp::vartoblock.
Referenced by computeConssNzeros(), computeVarDensities(), createPartialdecFromDecomp(), createPricingVariables(), DECdecompCheckConsistency(), DECdecompositionsAreEqual(), DECdetermineConsBlock(), DECevaluateDecomposition(), DECgetDensityData(), and DECgetVarLockData().
◆ DECdecompSetConstoblock()
void DECdecompSetConstoblock | ( | DEC_DECOMP * | decomp, |
SCIP_HASHMAP * | constoblock | ||
) |
sets the constoblock hashmap of the given decomposition
Definition at line 1209 of file decomp.c.
References DecDecomp::constoblock.
Referenced by createDecompFromPartialdec(), and fillOutConsFromConstoblock().
◆ DECdecompGetConstoblock()
SCIP_HASHMAP* DECdecompGetConstoblock | ( | DEC_DECOMP * | decomp | ) |
returns the constoblock hashmap of the given decomposition
Definition at line 1221 of file decomp.c.
References DecDecomp::constoblock.
Referenced by createPartialdecFromDecomp(), DECdecompAddRemainingConss(), DECdecompCheckConsistency(), and DECdecompositionsAreEqual().
◆ DECdecompSetVarindex()
void DECdecompSetVarindex | ( | DEC_DECOMP * | decomp, |
SCIP_HASHMAP * | varindex | ||
) |
sets the varindex hashmap of the given decomposition
Definition at line 1231 of file decomp.c.
References DecDecomp::varindex.
Referenced by createDecompFromPartialdec(), and DECfilloutDecompFromHashmaps().
◆ DECdecompGetVarindex()
SCIP_HASHMAP* DECdecompGetVarindex | ( | DEC_DECOMP * | decomp | ) |
returns the varindex hashmap of the given decomposition
Definition at line 1242 of file decomp.c.
References DecDecomp::varindex.
◆ DECdecompSetConsindex()
void DECdecompSetConsindex | ( | DEC_DECOMP * | decomp, |
SCIP_HASHMAP * | consindex | ||
) |
sets the consindex hashmap of the given decomposition
Definition at line 1251 of file decomp.c.
References DecDecomp::consindex.
Referenced by createDecompFromPartialdec(), and DECfilloutDecompFromHashmaps().
◆ DECdecompGetConsindex()
SCIP_HASHMAP* DECdecompGetConsindex | ( | DEC_DECOMP * | decomp | ) |
returns the consindex hashmap of the given decomposition
Definition at line 1262 of file decomp.c.
References DecDecomp::consindex.
◆ DECfilloutDecompFromHashmaps()
SCIP_RETCODE DECfilloutDecompFromHashmaps | ( | SCIP * | scip, |
DEC_DECOMP * | decomp, | ||
SCIP_HASHMAP * | vartoblock, | ||
SCIP_HASHMAP * | constoblock, | ||
int | nblocks, | ||
SCIP_Bool | staircase | ||
) |
completely initializes decomposition structure from the values of the hashmaps
Definition at line 1271 of file decomp.c.
References DEC_DECTYPE_ARROWHEAD, DEC_DECTYPE_BORDERED, DEC_DECTYPE_DIAGONAL, DEC_DECTYPE_STAIRCASE, DECdecompCheckConsistency(), DECdecompGetNSubscipconss(), DECdecompGetNSubscipvars(), DECdecompGetSubscipconss(), DECdecompSetConsindex(), DECdecompSetNBlocks(), DECdecompSetStairlinkingvars(), DECdecompSetType(), DECdecompSetVarindex(), fillOutConsFromConstoblock(), and fillOutVarsFromVartoblock().
Referenced by DECcreateBasicDecomp(), DECfilloutDecompFromConstoblock(), and readREFFile().
◆ DECfilloutDecompFromConstoblock()
SCIP_RETCODE DECfilloutDecompFromConstoblock | ( | SCIP * | scip, |
DEC_DECOMP * | decomp, | ||
SCIP_HASHMAP * | constoblock, | ||
int | nblocks, | ||
SCIP_Bool | staircase | ||
) |
completely fills out decomposition structure from only the constraint partition
completely fills out decomposition structure from only the constraint partition in the following manner: given constraint block/border assignment (by constoblock), one gets the following assignment of probvars: let C(j) be the set of constraints containing variable j, set block of j to (i) constoblock(i) iff constoblock(i1) == constoblock(i2) for all i1,i2 in C(j) with constoblock(i1) != nblocks+1 && constoblock(i2) != nblocks+1 (ii) nblocks+2 ["linking var"] iff exists i1,i2 with constoblock(i1) != constoblock(i2) && constoblock(i1) != nblocks+1 && constoblock(i2) != nblocks+1 (iii) nblocks+1 ["master var"] iff constoblock(i) == nblocks+1 for all i in C(j)
Definition at line 1455 of file decomp.c.
References DECfilloutDecompFromHashmaps().
Referenced by gcg::ColumnGraph< T >::createDecompFromPartition(), gcg::RowGraph< T >::createDecompFromPartition(), gcg::HyperrowcolGraph< T >::createDecompFromPartition(), gcg::HyperrowGraph< T >::createDecompFromPartition(), gcg::HypercolGraph< T >::createDecompFromPartition(), DECcreateDecompFromMasterconss(), DECtryAssignMasterconssToNewPricing(), and fillDecompStruct().
◆ DECdecompSetDetector()
void DECdecompSetDetector | ( | DEC_DECOMP * | decomp, |
DEC_DETECTOR * | detector | ||
) |
sets the detector for the given decomposition
Definition at line 1579 of file decomp.c.
References DecDecomp::detector.
Referenced by createDecompFromPartialdec(), fillDecompStruct(), and readREFFile().
◆ DECdecompGetDetector()
DEC_DETECTOR* DECdecompGetDetector | ( | DEC_DECOMP * | decomp | ) |
gets the detector for the given decomposition
Definition at line 1590 of file decomp.c.
References DecDecomp::detector.
Referenced by GCGwriteDecompositionData().
◆ DECdecompGetDetectorChain()
DEC_DETECTOR** DECdecompGetDetectorChain | ( | DEC_DECOMP * | decomp | ) |
gets the detectors for the given decomposition
Definition at line 1600 of file decomp.c.
References DecDecomp::detectorchain.
Referenced by createPartialdecFromDecomp().
◆ DECdecompGetDetectorChainSize()
int DECdecompGetDetectorChainSize | ( | DEC_DECOMP * | decomp | ) |
gets the number of detectors for the given decomposition
Definition at line 1637 of file decomp.c.
References DecDecomp::sizedetectorchain.
Referenced by createPartialdecFromDecomp().
◆ DECdecompGetPartialdecID()
int DECdecompGetPartialdecID | ( | DEC_DECOMP * | decomp | ) |
gets the id of the original partialdec
Definition at line 1660 of file decomp.c.
References DecDecomp::partialdecid.
Referenced by checkIdenticalBlocks(), and pricingprobsAreIdenticalFromDetectionInfo().
◆ DECdecompSetDetectorClockTimes()
void DECdecompSetDetectorClockTimes | ( | SCIP * | scip, |
DEC_DECOMP * | decomp, | ||
SCIP_Real * | detectorClockTimes | ||
) |
sets the detector clock times of the detectors of the detector chain
Definition at line 1671 of file decomp.c.
References DecDecomp::detectorclocktimes, and DecDecomp::sizedetectorchain.
Referenced by createDecompFromPartialdec().
◆ DECdecompGetDetectorClockTimes()
SCIP_Real* DECdecompGetDetectorClockTimes | ( | DEC_DECOMP * | decomp | ) |
gets the detector clock times of the detectors of the detector chain
Definition at line 1696 of file decomp.c.
References DecDecomp::detectorclocktimes.
Referenced by createPartialdecFromDecomp().
◆ DECdecompSetDetectorChainString()
SCIP_RETCODE DECdecompSetDetectorChainString | ( | SCIP * | scip, |
DEC_DECOMP * | decomp, | ||
const char * | detectorchainstring | ||
) |
sets the detector clock times of the detectors of the detector chain
Definition at line 1705 of file decomp.c.
References DecDecomp::detectorchainstring.
Referenced by createDecompFromPartialdec().
◆ DECdecompGetDetectorChainString()
char* DECdecompGetDetectorChainString | ( | SCIP * | scip, |
DEC_DECOMP * | decomp | ||
) |
sets the detector clock times of the detectors of the detector chain
Definition at line 1718 of file decomp.c.
References DecDecomp::detectorchainstring.
◆ DECdecompSetDetectorPctVarsToBorder()
void DECdecompSetDetectorPctVarsToBorder | ( | SCIP * | scip, |
DEC_DECOMP * | decomp, | ||
SCIP_Real * | pctVarsToBorder | ||
) |
sets the percentages of variables assigned to the border of the corresponding detectors (of the detector chain) on this decomposition
Definition at line 1728 of file decomp.c.
References DecDecomp::pctvarstoborder, and DecDecomp::sizedetectorchain.
Referenced by createDecompFromPartialdec().
◆ DECdecompGetDetectorPctVarsToBorder()
SCIP_Real* DECdecompGetDetectorPctVarsToBorder | ( | DEC_DECOMP * | decomp | ) |
gets the percentages of variables assigned to the border of the corresponding detectors (of the detector chain) on this decomposition
Definition at line 1756 of file decomp.c.
References DecDecomp::pctvarstoborder.
Referenced by createPartialdecFromDecomp().
◆ DECdecompSetDetectorPctConssToBorder()
void DECdecompSetDetectorPctConssToBorder | ( | SCIP * | scip, |
DEC_DECOMP * | decomp, | ||
SCIP_Real * | pctConssToBorder | ||
) |
sets the percentages of constraints assigned to the border of the corresponding detectors (of the detector chain) on this decomposition
Definition at line 1764 of file decomp.c.
References DecDecomp::pctconsstoborder, and DecDecomp::sizedetectorchain.
Referenced by createDecompFromPartialdec().
◆ DECdecompGetDetectorPctConssToBorder()
SCIP_Real* DECdecompGetDetectorPctConssToBorder | ( | DEC_DECOMP * | decomp | ) |
gets the percentages of constraints assigned to the border of the corresponding detectors (of the detector chain) on this decomposition
Definition at line 1791 of file decomp.c.
References DecDecomp::pctconsstoborder.
Referenced by createPartialdecFromDecomp().
◆ DECdecompSetDetectorPctVarsToBlock()
void DECdecompSetDetectorPctVarsToBlock | ( | SCIP * | scip, |
DEC_DECOMP * | decomp, | ||
SCIP_Real * | pctVarsToBlock | ||
) |
sets the percentages of variables assigned to some block of the corresponding detectors (of the detector chain) on this decomposition
Definition at line 1799 of file decomp.c.
References DecDecomp::pctvarstoblock, and DecDecomp::sizedetectorchain.
Referenced by createDecompFromPartialdec().
◆ DECdecompGetDetectorPctVarsToBlock()
SCIP_Real* DECdecompGetDetectorPctVarsToBlock | ( | DEC_DECOMP * | decomp | ) |
gets the percentages of variables assigned to some block of the corresponding detectors (of the detector chain) on this decomposition
Definition at line 1826 of file decomp.c.
References DecDecomp::pctvarstoblock.
Referenced by createPartialdecFromDecomp().
◆ DECdecompSetDetectorPctConssToBlock()
void DECdecompSetDetectorPctConssToBlock | ( | SCIP * | scip, |
DEC_DECOMP * | decomp, | ||
SCIP_Real * | pctConssToBlock | ||
) |
sets the percentages of constraints assigned to some block of the corresponding detectors (of the detector chain) on this decomposition
Definition at line 1834 of file decomp.c.
References DecDecomp::pctconsstoblock, and DecDecomp::sizedetectorchain.
Referenced by createDecompFromPartialdec().
◆ DECdecompGetDetectorPctConssToBlock()
SCIP_Real* DECdecompGetDetectorPctConssToBlock | ( | DEC_DECOMP * | decomp | ) |
gets the percentages of constraints assigned to some block of the corresponding detectors (of the detector chain) on this decomposition
Definition at line 1862 of file decomp.c.
References DecDecomp::pctconsstoblock.
Referenced by createPartialdecFromDecomp().
◆ DECdecompSetDetectorPctVarsFromOpen()
void DECdecompSetDetectorPctVarsFromOpen | ( | SCIP * | scip, |
DEC_DECOMP * | decomp, | ||
SCIP_Real * | pctVarsFromOpen | ||
) |
sets the percentages of variables assigned to some block of the corresponding detectors (of the detector chain) on this decomposition
Definition at line 1871 of file decomp.c.
References DecDecomp::pctvarsfromopen, and DecDecomp::sizedetectorchain.
Referenced by createDecompFromPartialdec().
◆ DECdecompGetDetectorPctVarsFromOpen()
SCIP_Real* DECdecompGetDetectorPctVarsFromOpen | ( | DEC_DECOMP * | decomp | ) |
gets the percentages of variables assigned to some block of the corresponding detectors (of the detector chain) on this decomposition
Definition at line 1899 of file decomp.c.
References DecDecomp::pctvarsfromopen.
Referenced by createPartialdecFromDecomp().
◆ DECdecompSetDetectorPctConssFromOpen()
void DECdecompSetDetectorPctConssFromOpen | ( | SCIP * | scip, |
DEC_DECOMP * | decomp, | ||
SCIP_Real * | pctConssFromOpen | ||
) |
sets the percentages of constraints assigned to some block of the corresponding detectors (of the detector chain) on this decomposition
Definition at line 1907 of file decomp.c.
References DecDecomp::pctconssfromopen, and DecDecomp::sizedetectorchain.
Referenced by createDecompFromPartialdec().
◆ DECdecompGetDetectorPctConssFromOpen()
SCIP_Real* DECdecompGetDetectorPctConssFromOpen | ( | DEC_DECOMP * | decomp | ) |
gets the percentages of constraints assigned to some block of the corresponding detectors (of the detector chain) on this decomposition
Definition at line 1936 of file decomp.c.
References DecDecomp::pctconssfromopen.
Referenced by createPartialdecFromDecomp().
◆ DECdecompSetNNewBlocks()
void DECdecompSetNNewBlocks | ( | SCIP * | scip, |
DEC_DECOMP * | decomp, | ||
int * | nNewBlocks | ||
) |
sets the number of new blocks of the corresponding detectors (of the detector chain) on this decomposition
Definition at line 1944 of file decomp.c.
References DecDecomp::nnewblocks, and DecDecomp::sizedetectorchain.
Referenced by createDecompFromPartialdec().
◆ DECdecompGetNNewBlocks()
int* DECdecompGetNNewBlocks | ( | DEC_DECOMP * | decomp | ) |
gets the number of new blocks corresponding detectors (of the detector chain) on this decomposition
Definition at line 1970 of file decomp.c.
References DecDecomp::nnewblocks.
Referenced by createPartialdecFromDecomp().
◆ DECdecompTransform()
SCIP_RETCODE DECdecompTransform | ( | SCIP * | scip, |
DEC_DECOMP * | decomp | ||
) |
transforms all constraints and variables, updating the arrays
Definition at line 1982 of file decomp.c.
References DecDecomp::constoblock, DECdecompCheckConsistency(), DecDecomp::linkingconss, DecDecomp::linkingvars, DecDecomp::nblocks, DecDecomp::nlinkingconss, DecDecomp::nlinkingvars, DecDecomp::nsubscipconss, DecDecomp::nsubscipvars, DecDecomp::subscipconss, DecDecomp::subscipvars, and DecDecomp::vartoblock.
◆ DECdecompRemoveDeletedConss()
SCIP_RETCODE DECdecompRemoveDeletedConss | ( | SCIP * | scip, |
DEC_DECOMP * | decdecomp | ||
) |
Remove all those constraints that were removed from the problem after the decomposition had been created
Definition at line 2123 of file decomp.c.
References DecDecomp::linkingconss, DecDecomp::nblocks, DecDecomp::nlinkingconss, DecDecomp::nsubscipconss, and DecDecomp::subscipconss.
◆ DECdecompAddRemainingConss()
SCIP_RETCODE DECdecompAddRemainingConss | ( | SCIP * | scip, |
DEC_DECOMP * | decdecomp | ||
) |
Adds all those constraints that were added to the problem after the decomposition as created
Adds all those constraints that were added to the problem after the decomposition had been created
Definition at line 2179 of file decomp.c.
References assignConsvarsToBlock(), DecDecomp::constoblock, DEC_DECTYPE_ARROWHEAD, DEC_DECTYPE_BORDERED, DEC_DECTYPE_DIAGONAL, DEC_DECTYPE_STAIRCASE, DECdecompGetConstoblock(), DECdecompGetNBlocks(), DECdetermineConsBlock(), GCGisConsGCGCons(), DecDecomp::linkingconss, DecDecomp::nlinkingconss, DecDecomp::nsubscipconss, DecDecomp::subscipconss, and DecDecomp::type.
Referenced by convertStructToGCG(), and createDecompFromPartialdec().
◆ DECdecompCheckConsistency()
SCIP_RETCODE DECdecompCheckConsistency | ( | SCIP * | scip, |
DEC_DECOMP * | decdecomp | ||
) |
checks the validity of the decomposition data structure
checks the consistency of the data structure
In particular, it checks whether the redundant information in the structure agree and whether the variables in the structure are both existant in the arrays and in the problem
Definition at line 2267 of file decomp.c.
References DEC_DECTYPE_ARROWHEAD, DEC_DECTYPE_BORDERED, DEC_DECTYPE_DIAGONAL, DEC_DECTYPE_STAIRCASE, DEC_DECTYPE_UNKNOWN, DECdecompGetConstoblock(), DECdecompGetLinkingconss(), DECdecompGetLinkingvars(), DECdecompGetNBlocks(), DECdecompGetNLinkingconss(), DECdecompGetNLinkingvars(), DECdecompGetNSubscipconss(), DECdecompGetNSubscipvars(), DECdecompGetNTotalStairlinkingvars(), DECdecompGetSubscipconss(), DECdecompGetSubscipvars(), DECdecompGetType(), DECdecompGetVartoblock(), GCGconsGetNVars(), GCGconsGetVars(), and GCGisConsGCGCons().
Referenced by convertStructToGCG(), createDecompFromPartialdec(), createPartialdecFromDecomp(), DECdecompTransform(), DECfilloutDecompFromHashmaps(), and DECpermuteDecomp().
◆ DECcreateBasicDecomp()
SCIP_RETCODE DECcreateBasicDecomp | ( | SCIP * | scip, |
DEC_DECOMP ** | decomp, | ||
SCIP_Bool | solveorigprob | ||
) |
creates a decomposition with all constraints in the master
Definition at line 2388 of file decomp.c.
References DECdecompCreate(), DECdecompSetPresolved(), DECfilloutDecompFromHashmaps(), and GCGisConsGCGCons().
Referenced by initRelaxator().
◆ DECcreateDecompFromMasterconss()
SCIP_RETCODE DECcreateDecompFromMasterconss | ( | SCIP * | scip, |
DEC_DECOMP ** | decomp, | ||
SCIP_CONS ** | masterconss, | ||
int | nmasterconss | ||
) |
creates a decomposition with provided constraints in the master The function will put the remaining constraints in one or more pricing problems depending on whether the subproblems decompose with no variables in common.
Definition at line 2715 of file decomp.c.
References assignConstraintsToRepresentatives(), DECdecompCreate(), DECfilloutDecompFromConstoblock(), fillConstoblock(), GCGisConsGCGCons(), and processBlockRepresentatives().
◆ DECgetSubproblemVarsData()
void DECgetSubproblemVarsData | ( | SCIP * | scip, |
DEC_DECOMP * | decomp, | ||
int * | nvars, | ||
int * | nbinvars, | ||
int * | nintvars, | ||
int * | nimplvars, | ||
int * | ncontvars, | ||
int | nproblems | ||
) |
return the number of variables and binary, integer, implied integer, continuous variables of all subproblems
Definition at line 2837 of file decomp.c.
References DEC_DECTYPE_UNKNOWN, DECdecompGetNSubscipvars(), DECdecompGetSubscipvars(), DECdecompGetType(), and incVarsData().
Referenced by GCGprintDecompStatistics().
◆ DECgetLinkingVarsData()
void DECgetLinkingVarsData | ( | SCIP * | scip, |
DEC_DECOMP * | decomp, | ||
int * | nvars, | ||
int * | nbinvars, | ||
int * | nintvars, | ||
int * | nimplvars, | ||
int * | ncontvars | ||
) |
return the number of variables and binary, integer, implied integer, continuous variables of the master
Definition at line 2886 of file decomp.c.
References DEC_DECTYPE_UNKNOWN, DECdecompGetLinkingvars(), DECdecompGetNLinkingvars(), DECdecompGetType(), and incVarsData().
Referenced by GCGprintDecompStatistics().
◆ DECgetDensityData()
SCIP_RETCODE DECgetDensityData | ( | SCIP * | scip, |
DEC_DECOMP * | decomp, | ||
SCIP_VAR ** | vars, | ||
int | nvars, | ||
SCIP_CONS ** | conss, | ||
int | nconss, | ||
int * | varsubproblemdensity, | ||
int * | varmasterdensity, | ||
int * | conssubproblemdensity, | ||
int * | consmasterdensity | ||
) |
returns the number of nonzeros of each column of the constraint matrix both in the subproblem and in the master
- Note
- For linking variables, the number of nonzeros in the subproblems corresponds to the number on nonzeros in the border
- The arrays have to be allocated by the caller
- Precondition
- This function assumes that constraints are partitioned in the decomp structure, no constraint is present in more than one block
Definition at line 2936 of file decomp.c.
References DECdecompGetLinkingconss(), DECdecompGetNBlocks(), DECdecompGetNLinkingconss(), DECdecompGetNSubscipconss(), DECdecompGetSubscipconss(), and DECdecompGetVartoblock().
Referenced by GCGprintDecompStatistics().
◆ DECgetVarLockData()
SCIP_RETCODE DECgetVarLockData | ( | SCIP * | scip, |
DEC_DECOMP * | decomp, | ||
SCIP_VAR ** | vars, | ||
int | nvars, | ||
int | nsubproblems, | ||
int ** | subsciplocksdown, | ||
int ** | subsciplocksup, | ||
int * | masterlocksdown, | ||
int * | masterlocksup | ||
) |
calculates the number of up and down locks of variables for a given decomposition in both the original problem and the pricingproblems
- Note
- All arrays need to be allocated by the caller
- Warning
- This function needs a lot of memory (nvars*nblocks+1) array entries
Definition at line 3117 of file decomp.c.
References DECdecompGetLinkingconss(), DECdecompGetNBlocks(), DECdecompGetNLinkingvars(), DECdecompGetNSubscipconss(), DECdecompGetSubscipconss(), DECdecompGetVartoblock(), GCGconsGetLhs(), GCGconsGetRhs(), GCGconsGetVals(), and increaseLock().
◆ DECgetMaxWhiteScore()
SCIP_Real DECgetMaxWhiteScore | ( | SCIP * | scip, |
DEC_DECOMP * | decdecomp | ||
) |
returns the maximum white score ( if it is not calculated yet is decomp is evaluated)
computes the score of the given decomposition based on the border, the average density score and the ratio of linking variables
Definition at line 3270 of file decomp.c.
References DECevaluateDecomposition(), and DecDecomp::maxwhitescore.
◆ DECevaluateDecomposition()
SCIP_RETCODE DECevaluateDecomposition | ( | SCIP * | scip, |
DEC_DECOMP * | decdecomp, | ||
DEC_SCORES * | score | ||
) |
computes the score of the given decomposition based on the border, the average density score and the ratio of linking variables
Definition at line 3288 of file decomp.c.
References Dec_Scores::borderscore, DEC_DECTYPE_ARROWHEAD, DEC_DECTYPE_BORDERED, DEC_DECTYPE_DIAGONAL, DEC_DECTYPE_STAIRCASE, DEC_DECTYPE_UNKNOWN, DECdecompGetNBlocks(), DECdecompGetNLinkingconss(), DECdecompGetNLinkingvars(), DECdecompGetNMastervars(), DECdecompGetNSubscipconss(), DECdecompGetNSubscipvars(), DECdecompGetSubscipconss(), DECdecompGetType(), DECdecompGetVartoblock(), DECgetStrType(), Dec_Scores::densityscore, GCGconsGetNVars(), GCGconsGetVars(), GCGisVarRelevant(), Dec_Scores::linkingscore, and Dec_Scores::totalscore.
Referenced by DECgetMaxWhiteScore(), and GCGprintDecompStatistics().
◆ DECdecompGetNConss()
int DECdecompGetNConss | ( | DEC_DECOMP * | decomp | ) |
returns the number of constraints saved in the decomposition
Definition at line 3650 of file decomp.c.
References DECdecompGetNBlocks(), DECdecompGetNLinkingconss(), and DECdecompGetNSubscipconss().
Referenced by GCGprintDecompStatistics().
◆ GCGprintDecompStatistics()
SCIP_RETCODE GCGprintDecompStatistics | ( | SCIP * | scip, |
FILE * | file, | ||
DEC_DECOMP * | decomp | ||
) |
display statistics about the decomposition
Definition at line 3778 of file decomp.c.
References Dec_Scores::borderscore, computeNonzeros(), computeVarDensities(), DECdecompGetNBlocks(), DECdecompGetNConss(), DECdecompGetNLinkingconss(), DECdecompGetNMastervars(), DECdecompGetNSubscipconss(), DECdecompGetType(), DECevaluateDecomposition(), DECgetDensityData(), DECgetLinkingVarsData(), DECgetStrType(), DECgetSubproblemVarsData(), Dec_Scores::densityscore, DecDecomp::detectorchainstring, GCGgetMasterprob(), GCGgetNIdenticalBlocks(), GCGisPricingprobRelevant(), Dec_Scores::linkingscore, DEC_STATISTIC::max, DEC_STATISTIC::mean, DEC_STATISTIC::median, and DEC_STATISTIC::min.
Referenced by GCGprintStatistics().
◆ DECdecompositionsAreEqual()
SCIP_Bool DECdecompositionsAreEqual | ( | SCIP * | scip, |
DEC_DECOMP * | decomp1, | ||
DEC_DECOMP * | decomp2 | ||
) |
returns whether both structures lead to the same decomposition
Definition at line 3939 of file decomp.c.
References DECdecompGetConstoblock(), DECdecompGetNBlocks(), and DECdecompGetVartoblock().
Referenced by DECfilterSimilarDecompositions().
◆ DECfilterSimilarDecompositions()
int DECfilterSimilarDecompositions | ( | SCIP * | scip, |
DEC_DECOMP ** | decs, | ||
int | ndecs | ||
) |
filters similar decompositions from a given list and moves them to the end
- Returns
- the number of unique decompositions
Definition at line 4004 of file decomp.c.
References DECdecompositionsAreEqual().
◆ DECdetermineConsBlock()
SCIP_RETCODE DECdetermineConsBlock | ( | SCIP * | scip, |
DEC_DECOMP * | decomp, | ||
SCIP_CONS * | cons, | ||
int * | block | ||
) |
returns the number of the block that the constraint is with respect to the decomposition
returns the number of the block that the constraint is with respect to the decomposition; set *block = -2, if it has no variables *block = -1, if it has only variables belonging only to the master (meaning that this constraint should build a new block) *block in [0,...,nblocks-1] if it only contains variables of a particular block (plus linking variables) *block = nblocks, if it contains
- either variables from more than one block (plus linking variables or master only variables)
- or linking variables only
Definition at line 4047 of file decomp.c.
References DECdecompGetNBlocks(), and DECdecompGetVartoblock().
Referenced by DECdecompAddRemainingConss(), DECtryAssignMasterconssToExistingPricing(), and DECtryAssignMasterconssToNewPricing().
◆ DECdecompMoveLinkingConsToPricing()
SCIP_RETCODE DECdecompMoveLinkingConsToPricing | ( | SCIP * | scip, |
DEC_DECOMP * | decomp, | ||
int | consindex, | ||
int | block | ||
) |
move a master constraint to pricing problem
Definition at line 4137 of file decomp.c.
References assignConsvarsToBlock(), DecDecomp::constoblock, DecDecomp::linkingconss, DecDecomp::nlinkingconss, DecDecomp::nsubscipconss, and DecDecomp::subscipconss.
Referenced by DECtryAssignMasterconssToExistingPricing().
◆ DECtryAssignMasterconssToExistingPricing()
SCIP_RETCODE DECtryAssignMasterconssToExistingPricing | ( | SCIP * | scip, |
DEC_DECOMP * | decomp, | ||
int * | transferred | ||
) |
tries to assign masterconss to pricing problem
Definition at line 4172 of file decomp.c.
References DECdecompGetNBlocks(), DECdecompMoveLinkingConsToPricing(), DECdetermineConsBlock(), DecDecomp::linkingconss, and DecDecomp::nlinkingconss.
Referenced by DECcreatePolishedDecomp().
◆ DECtryAssignMasterconssToNewPricing()
SCIP_RETCODE DECtryAssignMasterconssToNewPricing | ( | SCIP * | scip, |
DEC_DECOMP * | decomp, | ||
DEC_DECOMP ** | newdecomp, | ||
int * | transferred | ||
) |
tries to assign masterconss to new pricing problem
Definition at line 4220 of file decomp.c.
References DecDecomp::constoblock, DECdecompCreate(), DECdetermineConsBlock(), DECfilloutDecompFromConstoblock(), DecDecomp::linkingconss, DecDecomp::nblocks, and DecDecomp::nlinkingconss.
Referenced by DECcreatePolishedDecomp().
◆ DECcreatePolishedDecomp()
SCIP_RETCODE DECcreatePolishedDecomp | ( | SCIP * | scip, |
DEC_DECOMP * | decomp, | ||
DEC_DECOMP ** | newdecomp | ||
) |
polish the decomposition and try to greedily assign master constraints to pricing problem where useful
Definition at line 4276 of file decomp.c.
References DECdecompFree(), DECdecompGetNBlocks(), DECtryAssignMasterconssToExistingPricing(), and DECtryAssignMasterconssToNewPricing().
◆ DECpermuteDecomp()
SCIP_RETCODE DECpermuteDecomp | ( | SCIP * | scip, |
DEC_DECOMP * | decomp, | ||
SCIP_RANDNUMGEN * | randnumgen | ||
) |
permutes the decomposition according to the permutation seed
Definition at line 4323 of file decomp.c.
References DECdecompCheckConsistency(), DECdecompGetLinkingconss(), DECdecompGetLinkingvars(), DECdecompGetNBlocks(), DECdecompGetNLinkingconss(), DECdecompGetNLinkingvars(), DECdecompGetNSubscipconss(), DECdecompGetNSubscipvars(), DECdecompGetSubscipconss(), and DECdecompGetSubscipvars().
Referenced by initRelaxator().
◆ DECgetNDecomps()
int DECgetNDecomps | ( | SCIP * | scip | ) |
gets the number of existing decompositions
- Returns
- number of decompositions
- Parameters
-
scip SCIP data structure
Definition at line 2554 of file cons_decomp.cpp.
References GCGconshdlrDecompGetNDecomps().