prop_redcost.c
Go to the documentation of this file.
23 * This propagator uses the reduced cost of an optimal solved LP relaxation to propagate the variables against the 27 /*---+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+----0----+----1----+----2*/ 45 #define PROP_DELAY FALSE /**< should propagation method be delayed, if other propagators found reductions? */ 55 #define DEFAULT_CONTINUOUS FALSE /**< should reduced cost fixing be also applied to continuous variables? */ 56 #define DEFAULT_USEIMPLICS TRUE /**< should implications be used to strength the reduced cost for binary variables? */ 57 #define DEFAULT_FORCE FALSE /**< should the propagator be forced even if active pricer are present? Note that 73 SCIP_Bool continuous; /**< should reduced cost fixing be also applied to continuous variables? */ 76 SCIP_Bool useimplics; /**< should implications be used to strength the reduced cost for binary variables? */ 86 /** propagate the given binary variable/column using the root reduced cost stored in the SCIP internal data structers 87 * and check if the implications can be useful. Depending on that implictions are used or not used during the search to 152 /* evaluate if the implications are useful; the implications are seen to be useful if they provide an increase for 255 /* second, if the implications should be used and if the implications are seen to be promising use the implied 262 assert(!SCIPisDualfeasPositive(scip, lbredcost) || SCIPisFeasEQ(scip, SCIPvarGetLbLocal(var), SCIPvarGetUbLocal(var)) ); 266 assert(!SCIPisDualfeasNegative(scip, ubredcost) || SCIPisFeasEQ(scip, SCIPvarGetLbLocal(var), SCIPvarGetUbLocal(var)) ); 270 SCIPdebugMessage("variable <%s>: cutoff (requiredredcost <%g>, lbredcost <%g>, ubredcost <%g>)\n", 277 SCIPdebugMessage("variable <%s>: fixed 1.0 (requiredredcost <%g>, redcost <%g>, lbredcost <%g>)\n", 285 SCIPdebugMessage("variable <%s>: fixed 0.0 (requiredredcost <%g>, redcost <%g>, ubredcost <%g>)\n", 317 assert(!SCIPisDualfeasNegative(scip, redcost) || SCIPisFeasEQ(scip, SCIPvarGetLbLocal(var), SCIPvarGetUbLocal(var)) ); 352 SCIPdebugMessage("redcost strengthening upper bound: <%s> [%g,%g] -> [%g,%g] (ub=%g, lb=%g, redcost=%g)\n", 367 assert(!SCIPisDualfeasPositive(scip, redcost) || SCIPisFeasEQ(scip, SCIPvarGetLbLocal(var), SCIPvarGetUbLocal(var)) ); 403 SCIPdebugMessage("redcost strengthening lower bound: <%s> [%g,%g] -> [%g,%g] (ub=%g, lb=%g, redcost=%g)\n", 462 /** solving process initialization method of propagator (called when branch and bound process is about to begin) */ 550 /* check if all integral variables are fixed and the continuous variables should not be propagated */ 560 /* skip the propagator if the problem has only binary variables and those should not be propagated */ 571 SCIPdebugMessage("lpobjval <%g>, cutoffbound <%g>, max reduced <%g>, propgate binary %u, use implics %u\n", 595 SCIP_CALL( propagateRedcostBinvar(scip, propdata, var, cols[c], requiredredcost, &nchgbds, &cutoff) ); 634 { 642 SCIP_CALL( SCIPincludePropBasic(scip, &prop, PROP_NAME, PROP_DESC, PROP_PRIORITY, PROP_FREQ, PROP_DELAY, PROP_TIMING,
Definition: type_result.h:33 static SCIP_RETCODE propagateRedcostBinvar(SCIP *scip, SCIP_PROPDATA *propdata, SCIP_VAR *var, SCIP_COL *col, SCIP_Real requiredredcost, int *nchgbds, SCIP_Bool *cutoff) Definition: prop_redcost.c:195 SCIP_RETCODE SCIPchgVarLb(SCIP *scip, SCIP_VAR *var, SCIP_Real newbound) Definition: scip.c:19748 Definition: struct_scip.h:53 SCIP_Real SCIPgetVarImplRedcost(SCIP *scip, SCIP_VAR *var, SCIP_Bool varfixing) Definition: scip.c:17540 SCIP_Bool SCIPisFeasLT(SCIP *scip, SCIP_Real val1, SCIP_Real val2) Definition: scip.c:41920 SCIP_Real SCIPvarGetBestRootLPObjval(SCIP_VAR *var) Definition: var.c:13070 Definition: struct_var.h:196 SCIP_RETCODE SCIPsetPropCopy(SCIP *scip, SCIP_PROP *prop, SCIP_DECL_PROPCOPY((*propcopy))) Definition: scip.c:6945 SCIP_Bool SCIPisDualfeasPositive(SCIP *scip, SCIP_Real val) Definition: scip.c:42157 static SCIP_RETCODE propagateRedcostVar(SCIP *scip, SCIP_VAR *var, SCIP_COL *col, SCIP_Real lpobjval, SCIP_Real cutoffbound, int *nchgbds) Definition: prop_redcost.c:304 Definition: struct_lp.h:123 SCIP_RETCODE SCIPaddBoolParam(SCIP *scip, const char *name, const char *desc, SCIP_Bool *valueptr, SCIP_Bool isadvanced, SCIP_Bool defaultvalue, SCIP_DECL_PARAMCHGD((*paramchgd)), SCIP_PARAMDATA *paramdata) Definition: scip.c:3547 Definition: type_result.h:35 propagator using the LP reduced cost and the cutoff bound SCIP_Real SCIPadjustedVarUb(SCIP *scip, SCIP_VAR *var, SCIP_Real ub) Definition: scip.c:19717 SCIP_Bool SCIPisFeasEQ(SCIP *scip, SCIP_Real val1, SCIP_Real val2) Definition: scip.c:41907 Definition: type_retcode.h:33 Definition: type_result.h:42 Definition: type_lp.h:34 Definition: struct_prop.h:36 SCIP_RETCODE SCIPchgVarUb(SCIP *scip, SCIP_VAR *var, SCIP_Real newbound) Definition: scip.c:19828 SCIP_RETCODE SCIPsetPropFree(SCIP *scip, SCIP_PROP *prop, SCIP_DECL_PROPFREE((*propfree))) Definition: scip.c:6961 SCIP_RETCODE SCIPincludePropBasic(SCIP *scip, SCIP_PROP **propptr, const char *name, const char *desc, int priority, int freq, SCIP_Bool delay, SCIP_PROPTIMING timingmask, SCIP_DECL_PROPEXEC((*propexec)), SCIP_PROPDATA *propdata) Definition: scip.c:6908 SCIP_Bool SCIPisDualfeasNegative(SCIP *scip, SCIP_Real val) Definition: scip.c:42169 SCIP_RETCODE SCIPsetPropInitsol(SCIP *scip, SCIP_PROP *prop, SCIP_DECL_PROPINITSOL((*propinitsol))) Definition: scip.c:7009 static SCIP_RETCODE propagateRootRedcostBinvar(SCIP *scip, SCIP_PROPDATA *propdata, SCIP_VAR *var, SCIP_COL *col, SCIP_Real cutoffbound, int *nchgbds) Definition: prop_redcost.c:94 Definition: type_lpi.h:79 SCIP_Real SCIPadjustedVarLb(SCIP *scip, SCIP_VAR *var, SCIP_Real lb) Definition: scip.c:19685 Definition: type_set.h:42 Definition: type_lpi.h:80 Definition: type_retcode.h:43 Definition: objbranchrule.h:33 Definition: type_lpi.h:82 Definition: type_lpi.h:81 Definition: type_result.h:39 |