sepastore.c File Reference Detailed Descriptionmethods for storing separated cuts Definition in file sepastore.c. #include <assert.h> #include "scip/def.h" #include "scip/set.h" #include "scip/stat.h" #include "scip/lp.h" #include "scip/var.h" #include "scip/tree.h" #include "scip/reopt.h" #include "scip/sepastore.h" #include "scip/event.h" #include "scip/sepa.h" #include "scip/cons.h" #include "scip/debug.h" #include "scip/struct_sepastore.h" Go to the source code of this file. Function Documentation
resizes cuts and score arrays to be able to store at least num entries
Definition at line 49 of file sepastore.c. References BMSreallocMemoryArray, SCIP_SepaStore::cuts, SCIP_SepaStore::cutssize, SCIP_SepaStore::efficacies, NULL, SCIP_SepaStore::objparallelisms, SCIP_SepaStore::orthogonalities, SCIP_ALLOC, SCIP_OKAY, SCIPsetCalcMemGrowSize(), and SCIP_SepaStore::scores. Referenced by sepastoreAddCut().
creates separation storage
Definition at line 79 of file sepastore.c. References BMSallocMemory, FALSE, NULL, SCIP_ALLOC, and SCIP_OKAY. Referenced by initSolve().
frees separation storage
Definition at line 105 of file sepastore.c. References BMSfreeMemory, BMSfreeMemoryArrayNull, NULL, and SCIP_OKAY. Referenced by freeSolve().
informs separation storage, that the setup of the initial LP starts now
Definition at line 124 of file sepastore.c. References SCIP_SepaStore::initiallp, SCIP_SepaStore::ncuts, NULL, and TRUE. Referenced by SCIPinitConssLP().
informs separation storage, that the setup of the initial LP is now finished
Definition at line 136 of file sepastore.c. References FALSE, SCIP_SepaStore::initiallp, SCIP_SepaStore::ncuts, and NULL. Referenced by SCIPinitConssLP().
informs separation storage, that the following cuts should be used in any case
Definition at line 148 of file sepastore.c. References SCIP_SepaStore::forcecuts, NULL, and TRUE. Referenced by enforceConstraints().
informs separation storage, that the following cuts should no longer be used in any case
Definition at line 159 of file sepastore.c. References FALSE, SCIP_SepaStore::forcecuts, and NULL. Referenced by enforceConstraints().
checks cut for redundancy due to activity bounds
Definition at line 171 of file sepastore.c. References FALSE, NULL, SCIP_Real, SCIPdebugMessage, SCIProwGetLhs(), SCIProwGetMaxActivity(), SCIProwGetMinActivity(), SCIProwGetName(), SCIProwGetRhs(), SCIProwIsModifiable(), SCIPsetIsInfinity(), SCIPsetIsLE(), and TRUE. Referenced by sepastoreAddCut().
checks cut for redundancy or infeasibility due to activity bounds
Definition at line 209 of file sepastore.c. References FALSE, NULL, SCIP_Real, SCIPdebugMessage, SCIProwGetLhs(), SCIProwGetMaxActivity(), SCIProwGetMinActivity(), SCIProwGetName(), SCIProwGetRhs(), SCIProwIsModifiable(), SCIPsetIsFeasGT(), SCIPsetIsFeasLT(), SCIPsetIsInfinity(), SCIPsetIsLE(), and TRUE. Referenced by sepastoreAddCut(). checks whether a cut with only one variable can be applied as boundchange This is the case if the bound change would prove infeasibility (w.r.t feastol), or if the new bound is at least epsilon better than the old bound. In the latter case, also the opposite bound has to be taken into account.
Definition at line 265 of file sepastore.c. References FALSE, MAX, MIN, NULL, SCIP_Bool, SCIP_Real, SCIPcolGetVar(), SCIProwGetCols(), SCIProwGetConstant(), SCIProwGetLhs(), SCIProwGetNNonz(), SCIProwGetRhs(), SCIProwGetVals(), SCIProwIsLocal(), SCIProwIsModifiable(), SCIPsetIsFeasGT(), SCIPsetIsFeasLT(), SCIPsetIsFeasZero(), SCIPsetIsGT(), SCIPsetIsInfinity(), SCIPsetIsLT(), SCIPsetIsZero(), SCIPvarAdjustLb(), SCIPvarAdjustUb(), SCIPvarGetLbGlobal(), SCIPvarGetLbLocal(), SCIPvarGetUbGlobal(), SCIPvarGetUbLocal(), and TRUE. Referenced by SCIPsepastoreApplyCuts(), SCIPsepastoreIsCutApplicable(), and sepastoreAddCut().
adds cut stored as LP row to separation storage and captures it; if the cut should be forced to be used, an infinite score has to be used
Definition at line 366 of file sepastore.c. References SCIP_SepaStore::cuts, SCIP_SepaStore::cutssize, SCIP_SepaStore::efficacies, SCIP_EventFilter::eventmask, FALSE, SCIP_SepaStore::forcecuts, SCIP_SepaStore::initiallp, SCIP_EventFilter::len, SCIP_SepaStore::ncuts, SCIP_SepaStore::nforcedcuts, NULL, SCIP_SepaStore::objparallelisms, SCIP_SepaStore::orthogonalities, SCIP_Bool, SCIP_CALL, SCIP_EVENTTYPE_ROWADDEDSEPA, SCIP_EVENTTYPE_ROWDELETEDSEPA, SCIP_INVALID, SCIP_OKAY, SCIP_Real, SCIPdebugMessage, SCIPeventCreateRowAddedSepa(), SCIPeventCreateRowDeletedSepa(), SCIPeventqueueAdd(), SCIProwCapture(), SCIProwChgLocal(), SCIProwGetLhs(), SCIProwGetName(), SCIProwGetNNonz(), SCIProwGetObjParallelism(), SCIProwGetRhs(), SCIProwIsInLP(), SCIProwIsLocal(), SCIProwIsModifiable(), SCIProwRelease(), SCIPsetGetSepaMaxcuts(), SCIPsetInfinity(), SCIPsetIsInfinity(), SCIP_SepaStore::scores, sepastoreEnsureCutsMem(), sepastoreIsBdchgApplicable(), sepastoreIsCutRedundant(), and sepastoreIsCutRedundantOrInfeasible(). Referenced by SCIPsepastoreAddCut().
removes a non-forced cut from the separation storage
Definition at line 512 of file sepastore.c. References SCIP_SepaStore::cuts, SCIP_SepaStore::efficacies, SCIP_EventFilter::eventmask, SCIP_EventFilter::len, SCIP_SepaStore::ncuts, SCIP_SepaStore::nforcedcuts, NULL, SCIP_SepaStore::objparallelisms, SCIP_SepaStore::orthogonalities, SCIP_CALL, SCIP_EVENTTYPE_ROWDELETEDSEPA, SCIP_OKAY, SCIPeventCreateRowDeletedSepa(), SCIPeventqueueAdd(), SCIProwRelease(), and SCIP_SepaStore::scores. Referenced by SCIPsepastoreApplyCuts(), SCIPsepastoreRemoveInefficaciousCuts(), and sepastoreUpdateOrthogonalities().
adds cut to separation storage and captures it; if the cut should be forced to enter the LP, an infinite score has to be used
Definition at line 554 of file sepastore.c. References SCIP_SepaStore::initiallp, SCIP_SepaStore::ncutsfound, SCIP_SepaStore::ncutsfoundround, NULL, SCIP_CALL, SCIP_OKAY, SCIPdebugCheckRow, SCIProwGetLhs(), SCIProwGetRhs(), SCIProwIsInLP(), SCIPsetIsInfinity(), and sepastoreAddCut(). Referenced by SCIPaddCut(), and SCIPcutpoolSeparate().
applies a lower bound change
Definition at line 592 of file sepastore.c. References FALSE, NULL, SCIP_BOUNDTYPE_LOWER, SCIP_CALL, SCIP_OKAY, SCIPdebugMessage, SCIPnodeAddBoundchg(), SCIPnodeCutoff(), SCIPsetIsFeasLE(), SCIPsetIsGT(), SCIPtreeGetCurrentNode(), SCIPtreeGetRootNode(), SCIPvarAdjustLb(), SCIPvarGetLbGlobal(), SCIPvarGetLbLocal(), SCIPvarGetName(), SCIPvarGetUbGlobal(), SCIPvarGetUbLocal(), and TRUE. Referenced by sepastoreApplyBdchg().
applies an upper bound change
Definition at line 677 of file sepastore.c. References FALSE, NULL, SCIP_BOUNDTYPE_UPPER, SCIP_CALL, SCIP_OKAY, SCIPdebugMessage, SCIPnodeAddBoundchg(), SCIPnodeCutoff(), SCIPsetIsFeasGE(), SCIPsetIsLT(), SCIPtreeGetCurrentNode(), SCIPtreeGetRootNode(), SCIPvarAdjustUb(), SCIPvarGetLbGlobal(), SCIPvarGetLbLocal(), SCIPvarGetName(), SCIPvarGetUbGlobal(), SCIPvarGetUbLocal(), and TRUE. Referenced by sepastoreApplyBdchg().
applies a cut that is a bound change directly as bound change instead of adding it as row to the LP
Definition at line 762 of file sepastore.c. References FALSE, SCIP_SepaStore::initiallp, MAX, SCIP_SepaStore::ncutsapplied, NULL, REALABS, SCIP_Bool, SCIP_CALL, SCIP_EFFICIACYCHOICE_LP, SCIP_EFFICIACYCHOICE_NLP, SCIP_EFFICIACYCHOICE_RELAX, SCIP_INVALID, SCIP_INVALIDCALL, SCIP_OKAY, SCIP_Real, SCIPcolGetVar(), SCIPdebugMessage, SCIPerrorMessage, SCIProwGetCols(), SCIProwGetConstant(), SCIProwGetLhs(), SCIProwGetLPFeasibility(), SCIProwGetName(), SCIProwGetNLPFeasibility(), SCIProwGetNNonz(), SCIProwGetRelaxFeasibility(), SCIProwGetRhs(), SCIProwGetVals(), SCIProwIsLocal(), SCIProwIsModifiable(), SCIPsetEpsilon(), SCIPsetIsFeasZero(), SCIPsetIsInfinity(), SCIPsetIsZero(), sepastoreApplyLb(), and sepastoreApplyUb(). Referenced by SCIPsepastoreApplyCuts().
updates the orthogonalities and scores of the non-forced cuts after the given cut was added to the LP
Definition at line 892 of file sepastore.c. References SCIP_SepaStore::cuts, SCIP_SepaStore::efficacies, SCIP_SepaStore::nforcedcuts, NULL, SCIP_SepaStore::objparallelisms, SCIP_SepaStore::orthogonalities, SCIP_CALL, SCIP_INVALID, SCIP_OKAY, SCIP_Real, SCIPdebugMessage, SCIProwGetName(), SCIProwGetNNonz(), SCIProwGetOrthogonality(), SCIP_SepaStore::scores, and sepastoreDelCut(). Referenced by sepastoreApplyCut().
applies the given cut to the LP and updates the orthogonalities and scores of remaining cuts
Definition at line 944 of file sepastore.c. References SCIP_SepaStore::initiallp, MAX, SCIP_SepaStore::ncutsapplied, NULL, SCIP_Row::origin, SCIP_Row::origintype, SCIP_CALL, SCIP_EFFICIACYCHOICE_LP, SCIP_EFFICIACYCHOICE_NLP, SCIP_EFFICIACYCHOICE_RELAX, SCIP_INVALID, SCIP_INVALIDCALL, SCIP_INVALIDDATA, SCIP_OKAY, SCIP_Real, SCIP_ROWORIGINTYPE_CONS, SCIP_ROWORIGINTYPE_SEPA, SCIP_ROWORIGINTYPE_UNSPEC, SCIPconshdlrIncNAppliedCuts(), SCIPdebugMessage, SCIPerrorMessage, SCIPlpAddRow(), SCIProwGetLPFeasibility(), SCIProwGetName(), SCIProwGetNLPFeasibility(), SCIProwGetRelaxFeasibility(), SCIProwIsInLP(), SCIPsepaIncNAppliedCuts(), SCIPsetEpsilon(), and sepastoreUpdateOrthogonalities(). Referenced by SCIPsepastoreApplyCuts().
returns the position of the best non-forced cut in the cuts array
Definition at line 1034 of file sepastore.c. References SCIP_SepaStore::nforcedcuts, NULL, SCIP_INVALID, SCIP_Real, SCIP_REAL_MIN, and SCIP_SepaStore::scores. Referenced by SCIPsepastoreApplyCuts().
computes score for current LP solution and initialized orthogonalities
Definition at line 1062 of file sepastore.c. References SCIP_SepaStore::cuts, SCIP_SepaStore::efficacies, SCIP_SepaStore::objparallelisms, SCIP_SepaStore::orthogonalities, SCIP_EFFICIACYCHOICE_LP, SCIP_EFFICIACYCHOICE_NLP, SCIP_EFFICIACYCHOICE_RELAX, SCIP_INVALID, SCIP_INVALIDCALL, SCIP_OKAY, SCIP_Real, SCIPerrorMessage, SCIProwGetLPEfficacy(), SCIProwGetNLPEfficacy(), SCIProwGetRelaxEfficacy(), SCIProwIsInGlobalCutpool(), SCIPsetIsInfinity(), and SCIP_SepaStore::scores. Referenced by SCIPsepastoreApplyCuts(), and SCIPsepastoreRemoveInefficaciousCuts().
adds cuts to the LP and clears separation storage
Definition at line 1117 of file sepastore.c. References computeScore(), SCIP_SepaStore::cuts, SCIP_SepaStore::efficacies, FALSE, MAX, SCIP_SepaStore::ncuts, SCIP_SepaStore::nforcedcuts, NULL, SCIP_SepaStore::objparallelisms, SCIP_SepaStore::orthogonalities, SCIP_Bool, SCIP_CALL, SCIP_INVALID, SCIP_OKAY, SCIP_Real, SCIPdebugMessage, SCIPnodeGetDepth(), SCIProwCapture(), SCIProwGetName(), SCIProwGetNNonz(), SCIProwIsModifiable(), SCIProwRelease(), SCIPsepastoreClearCuts(), SCIPsetGetSepaMaxcuts(), SCIPsetIsFeasPositive(), SCIPsetIsInfinity(), SCIPtreeGetCurrentNode(), SCIP_SepaStore::scores, sepastoreApplyBdchg(), sepastoreApplyCut(), sepastoreDelCut(), sepastoreGetBestCut(), sepastoreIsBdchgApplicable(), and TRUE. Referenced by applyCuts(), priceAndCutLoop(), SCIPapplyCutsProbing(), and SCIPinitConssLP().
clears the separation storage without adding the cuts to the LP
Definition at line 1249 of file sepastore.c. References BMSfreeMemoryArrayNull, SCIP_SepaStore::cuts, SCIP_SepaStore::cutssize, SCIP_EventFilter::eventmask, SCIP_SepaStore::initiallp, SCIP_EventFilter::len, SCIP_SepaStore::ncuts, SCIP_SepaStore::ncutsfoundround, SCIP_SepaStore::nforcedcuts, NULL, SCIP_CALL, SCIP_EVENTTYPE_ROWDELETEDSEPA, SCIP_OKAY, SCIPdebugMessage, SCIPeventCreateRowDeletedSepa(), SCIPeventqueueAdd(), and SCIProwRelease(). Referenced by applyCuts(), priceAndCutLoop(), SCIPclearCuts(), and SCIPsepastoreApplyCuts().
removes cuts that are inefficacious w.r.t. the current LP solution from separation storage without adding the cuts to the LP
Definition at line 1297 of file sepastore.c. References computeScore(), SCIP_SepaStore::efficacies, FALSE, SCIP_SepaStore::nforcedcuts, NULL, SCIP_CALL, SCIP_INVALID, SCIP_OKAY, SCIPdebugMessage, SCIPsetIsEfficacious(), and sepastoreDelCut(). Referenced by SCIPremoveInefficaciousCuts(). indicates whether a cut is applicable A cut is applicable if it is modifiable, not a bound change, or a bound change that changes bounds by at least epsilon.
Definition at line 1338 of file sepastore.c. References SCIProwGetNNonz(), SCIProwIsModifiable(), and sepastoreIsBdchgApplicable(). Referenced by SCIPisCutApplicable().
get cuts in the separation storage
Definition at line 1347 of file sepastore.c. References SCIP_SepaStore::cuts, and NULL. Referenced by SCIPgetCuts().
get number of cuts in the separation storage
Definition at line 1357 of file sepastore.c. References SCIP_SepaStore::ncuts, and NULL. Referenced by applyCuts(), cutpoolSeparate(), enforceConstraints(), priceAndCutLoop(), propAndSolve(), SCIPbranchruleExecExternSol(), SCIPbranchruleExecLPSol(), SCIPconshdlrEnforceLPSol(), SCIPconshdlrSeparateLP(), SCIPconshdlrSeparateSol(), SCIPcutpoolSeparate(), SCIPgetNCuts(), SCIPsepaExecLP(), SCIPsepaExecSol(), separationRoundLP(), separationRoundSol(), solveNode(), and solveNodeLP().
get total number of cuts found so far
Definition at line 1367 of file sepastore.c. References SCIP_SepaStore::ncutsfound, and NULL. Referenced by SCIPgetNCutsFound().
get number of cuts found so far in current separation round
Definition at line 1377 of file sepastore.c. References SCIP_SepaStore::ncutsfoundround, and NULL. Referenced by SCIPgetNCutsFoundRound().
get total number of cuts applied to the LPs
Definition at line 1387 of file sepastore.c. References SCIP_SepaStore::ncutsapplied, and NULL. Referenced by SCIPgetNCutsApplied(). |