cuts.h
Go to the documentation of this file.
33 /*---+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+----0----+----1----+----2*/
57 /** perform activity based coefficient tigthening on the given cut; returns TRUE if the cut was detected
68 int* cutinds, /**< array of the problem indices of variables with a non-zero coefficient in the cut */
113 /** Removes a given variable @p var from position @p pos the aggregation row and updates the right-hand side according
114 * to sign of the coefficient, i.e., rhs -= coef * bound, where bound = lb if coef >= 0 and bound = ub, otherwise.
116 * @note: The choice of global or local bounds depend on the validity (global or local) of the aggregation row.
118 * @note: The list of non-zero indices will be updated by swapping the last non-zero index to @p pos.
129 /** add the objective function with right-hand side @p rhs and scaled by @p scale to the aggregation row */
152 /** calculates the efficacy norm of the given aggregation row, which depends on the "separating/efficacynorm" parameter
154 * @return the efficacy norm of the given aggregation row, which depends on the "separating/efficacynorm" parameter
180 int negslack, /**< should negative slack variables be used? (0: no, 1: only for integral rows, 2: yes) */
219 SCIP_Real* minabsrowweight, /**< pointer to store smallest absolute value of weights used for aggregating rows */
220 SCIP_Real* maxabsrowweight /**< pointer to store largest absolute value of weights used for aggregating rows */
223 /** gets the array of corresponding variable problem indices for each non-zero in the aggregation row */
288 * aggregation row must not contain non-zero weights for modifiable rows, because these rows cannot
291 * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
304 SCIP_Real boundswitch, /**< fraction of domain up to which lower bound is used in transformation */
306 SCIP_Bool allowlocal, /**< should local information allowed to be used, resulting in a local cut? */
307 SCIP_Bool fixintegralrhs, /**< should complementation tried to be adjusted such that rhs gets fractional? */
308 int* boundsfortrans, /**< bounds that should be used for transformed variables: vlb_idx/vub_idx,
311 SCIP_BOUNDTYPE* boundtypesfortrans, /**< type of bounds that should be used for transformed variables;
319 int* cutinds, /**< array to store the problem indices of variables with a non-zero coefficient in the cut */
324 SCIP_Bool* success /**< pointer to store whether the returned coefficients are a valid MIR cut */
328 * aggregation row must not contain non-zero weights for modifiable rows, because these rows cannot
329 * participate in an MIR cut. The function uses a cut generation heuristic which tries different scaling
336 * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
349 SCIP_Real boundswitch, /**< fraction of domain up to which lower bound is used in transformation */
351 SCIP_Bool allowlocal, /**< should local information allowed to be used, resulting in a local cut? */
353 int* boundsfortrans, /**< bounds that should be used for transformed variables: vlb_idx/vub_idx,
356 SCIP_BOUNDTYPE* boundtypesfortrans, /**< type of bounds that should be used for transformed variables;
363 int* cutinds, /**< array to store the problem indices of variables with a non-zero coefficient in the cut */
365 SCIP_Real* cutefficacy, /**< pointer to store efficacy of best cut; only cuts that are strictly better than the value of
372 /** calculates a lifted simple generalized flow cover cut out of the weighted sum of LP rows given by an aggregation row; the
373 * aggregation row must not contain non-zero weights for modifiable rows, because these rows cannot
377 * Gu, Z., Nemhauser, G. L., & Savelsbergh, M. W. (1999). Lifted flow cover inequalities for mixed 0-1 integer programs.
380 * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
393 SCIP_Real boundswitch, /**< fraction of domain up to which lower bound is used in transformation */
394 SCIP_Bool allowlocal, /**< should local information allowed to be used, resulting in a local cut? */
398 int* cutinds, /**< array to store the problem indices of variables with a non-zero coefficient in the cut */
406 /** calculates a lifted knapsack cover cut out of the weighted sum of LP rows given by an aggregation row; the
407 * aggregation row must not contain non-zero weights for modifiable rows, because these rows cannot
411 * Letchford, A. N., & Souli, G. (2019). On lifted cover inequalities: A new lifting procedure with unusual properties.
414 * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
426 SCIP_Bool allowlocal, /**< should local information allowed to be used, resulting in a local cut? */
430 int* cutinds, /**< array to store the problem indices of variables with a non-zero coefficient in the cut */
438 /** calculates a strong CG cut out of the weighted sum of LP rows given by an aggregation row; the
439 * aggregation row must not contain non-zero weights for modifiable rows, because these rows cannot
442 * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
455 SCIP_Real boundswitch, /**< fraction of domain up to which lower bound is used in transformation */
457 SCIP_Bool allowlocal, /**< should local information allowed to be used, resulting in a local cut? */
464 int* cutinds, /**< array to store the problem indices of variables with a non-zero coefficient in the cut */
SCIP_RETCODE SCIPcalcStrongCG(SCIP *scip, SCIP_SOL *sol, SCIP_Bool postprocess, SCIP_Real boundswitch, SCIP_Bool usevbds, SCIP_Bool allowlocal, SCIP_Real minfrac, SCIP_Real maxfrac, SCIP_Real scale, SCIP_AGGRROW *aggrrow, SCIP_Real *cutcoefs, SCIP_Real *cutrhs, int *cutinds, int *cutnnz, SCIP_Real *cutefficacy, int *cutrank, SCIP_Bool *cutislocal, SCIP_Bool *success)
Definition: cuts.c:8974
type definitions for miscellaneous datastructures
Definition: struct_scip.h:69
SCIP_RETCODE SCIPaggrRowAddRow(SCIP *scip, SCIP_AGGRROW *aggrrow, SCIP_ROW *row, SCIP_Real weight, int sidetype)
Definition: cuts.c:1867
Definition: struct_cuts.h:40
void SCIPaggrRowCancelVarWithBound(SCIP *scip, SCIP_AGGRROW *aggrrow, SCIP_VAR *var, int pos, SCIP_Bool *valid)
Definition: cuts.c:1953
Definition: struct_var.h:207
SCIP_RETCODE SCIPcutGenerationHeuristicCMIR(SCIP *scip, SCIP_SOL *sol, SCIP_Bool postprocess, SCIP_Real boundswitch, SCIP_Bool usevbds, SCIP_Bool allowlocal, int maxtestdelta, int *boundsfortrans, SCIP_BOUNDTYPE *boundtypesfortrans, SCIP_Real minfrac, SCIP_Real maxfrac, SCIP_AGGRROW *aggrrow, SCIP_Real *cutcoefs, SCIP_Real *cutrhs, int *cutinds, int *cutnnz, SCIP_Real *cutefficacy, int *cutrank, SCIP_Bool *cutislocal, SCIP_Bool *success)
Definition: cuts.c:4220
type definitions for cuts
SCIP_RETCODE SCIPcalcKnapsackCover(SCIP *scip, SCIP_SOL *sol, SCIP_Bool allowlocal, SCIP_AGGRROW *aggrrow, SCIP_Real *cutcoefs, SCIP_Real *cutrhs, int *cutinds, int *cutnnz, SCIP_Real *cutefficacy, int *cutrank, SCIP_Bool *cutislocal, SCIP_Bool *success)
Definition: cuts.c:8055
type definitions for return codes for SCIP methods
void SCIPaggrRowPrint(SCIP *scip, SCIP_AGGRROW *aggrrow, FILE *file)
Definition: cuts.c:1784
SCIP_Bool SCIPaggrRowHasRowBeenAdded(SCIP_AGGRROW *aggrrow, SCIP_ROW *row)
Definition: cuts.c:2526
type definitions for LP management
Definition: struct_sol.h:73
SCIP_RETCODE SCIPaggrRowAddObjectiveFunction(SCIP *scip, SCIP_AGGRROW *aggrrow, SCIP_Real rhs, SCIP_Real scale)
Definition: cuts.c:2012
type definitions for SCIP's main datastructure
void SCIPaggrRowRemoveZeros(SCIP *scip, SCIP_AGGRROW *aggrrow, SCIP_Bool useglbbounds, SCIP_Bool *valid)
Definition: cuts.c:2479
type definitions for problem variables
SCIP_RETCODE SCIPaggrRowAddCustomCons(SCIP *scip, SCIP_AGGRROW *aggrrow, int *inds, SCIP_Real *vals, int len, SCIP_Real rhs, SCIP_Real weight, int rank, SCIP_Bool local)
Definition: cuts.c:2088
SCIP_RETCODE SCIPcalcMIR(SCIP *scip, SCIP_SOL *sol, SCIP_Bool postprocess, SCIP_Real boundswitch, SCIP_Bool usevbds, SCIP_Bool allowlocal, SCIP_Bool fixintegralrhs, int *boundsfortrans, SCIP_BOUNDTYPE *boundtypesfortrans, SCIP_Real minfrac, SCIP_Real maxfrac, SCIP_Real scale, SCIP_AGGRROW *aggrrow, SCIP_Real *cutcoefs, SCIP_Real *cutrhs, int *cutinds, int *cutnnz, SCIP_Real *cutefficacy, int *cutrank, SCIP_Bool *cutislocal, SCIP_Bool *success)
Definition: cuts.c:3881
SCIP_Real SCIPaggrRowCalcEfficacyNorm(SCIP *scip, SCIP_AGGRROW *aggrrow)
Definition: cuts.c:2166
SCIP_Bool SCIPcutsTightenCoefficients(SCIP *scip, SCIP_Bool cutislocal, SCIP_Real *cutcoefs, SCIP_Real *cutrhs, int *cutinds, int *cutnnz, int *nchgcoefs)
Definition: cuts.c:1535
SCIP_RETCODE SCIPcalcFlowCover(SCIP *scip, SCIP_SOL *sol, SCIP_Bool postprocess, SCIP_Real boundswitch, SCIP_Bool allowlocal, SCIP_AGGRROW *aggrrow, SCIP_Real *cutcoefs, SCIP_Real *cutrhs, int *cutinds, int *cutnnz, SCIP_Real *cutefficacy, int *cutrank, SCIP_Bool *cutislocal, SCIP_Bool *success)
Definition: cuts.c:7425
Definition: struct_lp.h:201
SCIP_Real * SCIPaggrRowGetRowWeights(SCIP_AGGRROW *aggrrow)
Definition: cuts.c:2515
type definitions for storing primal CIP solutions
SCIP_RETCODE SCIPaggrRowCopy(SCIP *scip, SCIP_AGGRROW **aggrrow, SCIP_AGGRROW *source)
Definition: cuts.c:1821
void SCIPaggrRowGetAbsWeightRange(SCIP_AGGRROW *aggrrow, SCIP_Real *minabsrowweight, SCIP_Real *maxabsrowweight)
SCIP_RETCODE SCIPaggrRowSumRows(SCIP *scip, SCIP_AGGRROW *aggrrow, SCIP_Real *weights, int *rowinds, int nrowinds, SCIP_Bool sidetypebasis, SCIP_Bool allowlocal, int negslack, int maxaggrlen, SCIP_Bool *valid)
Definition: cuts.c:2287
SCIP_RETCODE SCIPaggrRowCreate(SCIP *scip, SCIP_AGGRROW **aggrrow)
Definition: cuts.c:1731
static INLINE SCIP_Real SCIPaggrRowGetProbvarValue(SCIP_AGGRROW *aggrrow, int probindex)
Definition: cuts.h:251
common defines and data types used in all packages of SCIP
Definition: objbenders.h:43
static INLINE SCIP_Real SCIPaggrRowGetValue(SCIP_AGGRROW *aggrrow, int i)
Definition: cuts.h:237
struct definitions for cuts