prop_redcost.c
Go to the documentation of this file.
33 * This propagator uses the reduced cost of an optimal solved LP relaxation to propagate the variables against the
37/*---+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+----0----+----1----+----2*/
72#define PROP_DELAY FALSE /**< should propagation method be delayed, if other propagators found reductions? */
82#define DEFAULT_CONTINUOUS FALSE /**< should reduced cost fixing be also applied to continuous variables? */
83#define DEFAULT_USEIMPLICS FALSE /**< should implications be used to strength the reduced cost for binary variables? */
84#define DEFAULT_FORCE FALSE /**< should the propagator be forced even if active pricer are present? Note that
100 SCIP_Bool continuous; /**< should reduced cost fixing be also applied to continuous variables? */
103 SCIP_Bool useimplics; /**< should implications be used to strength the reduced cost for binary variables? */
113/** propagate the given binary variable/column using the root reduced cost stored in the SCIP internal data structures
114 * and check if the implications can be useful. Depending on that implications are used or not used during the search to
149 /* SCIPisLPDualReliable should always return TRUE if the dual feasibility check is enabled and the LP claims to
150 * have a dual feasible solution. if the check is disabled the dual solution might be incorrect and the assert
151 * might fail. however, if the user decides to disable the dual feasibility check (which also can lead to wrong
170 /* SCIPisLPDualReliable should always return TRUE if the dual feasibility check is enabled and the LP claims to
171 * have a dual feasible solution. if the check is disabled the dual solution might be incorrect and the assert
172 * might fail. however, if the user decides to disable the dual feasibility check (which also can lead to wrong
190 /* evaluate if the implications are useful; the implications are seen to be useful if they provide an increase for
209 /* SCIPisLPDualReliable should always return TRUE if the dual feasibility check is enabled and the LP claims to
210 * have a dual feasible solution. if the check is disabled the dual solution might be incorrect and the assert
211 * might fail. however, if the user decides to disable the dual feasibility check (which also can lead to wrong
220 /* SCIPisLPDualReliable should always return TRUE if the dual feasibility check is enabled and the LP claims to
221 * have a dual feasible solution. if the check is disabled the dual solution might be incorrect and the assert
222 * might fail. however, if the user decides to disable the dual feasibility check (which also can lead to wrong
266 /* SCIPisLPDualReliable should always return TRUE if the dual feasibility check is enabled and the LP claims to
267 * have a dual feasible solution. if the check is disabled the dual solution might be incorrect and the assert
268 * might fail. however, if the user decides to disable the dual feasibility check (which also can lead to wrong
287 /* SCIPisLPDualReliable should always return TRUE if the dual feasibility check is enabled and the LP claims to
288 * have a dual feasible solution. if the check is disabled the dual solution might be incorrect and the assert
289 * might fail. however, if the user decides to disable the dual feasibility check (which also can lead to wrong
309 /* SCIPisLPDualReliable should always return TRUE if the dual feasibility check is enabled and the LP claims to
310 * have a dual feasible solution. if the check is disabled the dual solution might be incorrect and the assert
311 * might fail. however, if the user decides to disable the dual feasibility check (which also can lead to wrong
322 /* second, if the implications should be used and if the implications are seen to be promising use the implied
330 /* SCIPisLPDualReliable should always return TRUE if the dual feasibility check is enabled and the LP claims to
331 * have a dual feasible solution. if the check is disabled the dual solution might be incorrect and the assert
332 * might fail. however, if the user decides to disable the dual feasibility check (which also can lead to wrong
345 SCIPdebugMsg(scip, "variable <%s>: cutoff (requiredredcost <%g>, lbredcost <%g>, ubredcost <%g>)\n",
352 SCIPdebugMsg(scip, "variable <%s>: fixed 1.0 (requiredredcost <%g>, redcost <%g>, lbredcost <%g>)\n",
360 SCIPdebugMsg(scip, "variable <%s>: fixed 0.0 (requiredredcost <%g>, redcost <%g>, ubredcost <%g>)\n",
392 /* SCIPisLPDualReliable should always return TRUE if the dual feasibility check is enabled and the LP claims to
393 * have a dual feasible solution. if the check is disabled the dual solution might be incorrect and the assert
394 * might fail. however, if the user decides to disable the dual feasibility check (which also can lead to wrong
434 SCIPdebugMsg(scip, "redcost strengthening upper bound: <%s> [%g,%g] -> [%g,%g] (ub=%g, lb=%g, redcost=%g)\n",
449 /* SCIPisLPDualReliable should always return TRUE if the dual feasibility check is enabled and the LP claims to
450 * have a dual feasible solution. if the check is disabled the dual solution might be incorrect and the assert
451 * might fail. however, if the user decides to disable the dual feasibility check (which also can lead to wrong
492 SCIPdebugMsg(scip, "redcost strengthening lower bound: <%s> [%g,%g] -> [%g,%g] (ub=%g, lb=%g, redcost=%g)\n",
502 /* SCIPisLPDualReliable should always return TRUE if the dual feasibility check is enabled and the LP claims to
503 * have a dual feasible solution. if the check is disabled the dual solution might be incorrect and the assert
504 * might fail. however, if the user decides to disable the dual feasibility check (which also can lead to wrong
558/** solving process initialization method of propagator (called when branch and bound process is about to begin) */
646 /* check if all integral variables are fixed and the continuous variables should not be propagated */
656 /* skip the propagator if the problem has only binary variables and those should not be propagated */
667 SCIPdebugMsg(scip, "lpobjval <%g>, cutoffbound <%g>, max reduced <%g>, propgate binary %u, use implics %u\n",
691 SCIP_CALL( propagateRedcostBinvar(scip, propdata, var, cols[c], requiredredcost, &nchgbds, &cutoff) );
733 SCIP_CALL( SCIPincludePropBasic(scip, &prop, PROP_NAME, PROP_DESC, PROP_PRIORITY, PROP_FREQ, PROP_DELAY, PROP_TIMING,
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_param.c:57
SCIP_RETCODE SCIPsetPropInitsol(SCIP *scip, SCIP_PROP *prop, SCIP_DECL_PROPINITSOL((*propinitsol)))
Definition: scip_prop.c:219
SCIP_RETCODE SCIPsetPropFree(SCIP *scip, SCIP_PROP *prop, SCIP_DECL_PROPFREE((*propfree)))
Definition: scip_prop.c:171
SCIP_RETCODE SCIPsetPropCopy(SCIP *scip, SCIP_PROP *prop, SCIP_DECL_PROPCOPY((*propcopy)))
Definition: scip_prop.c:155
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_prop.c:118
SCIP_Bool SCIPisDualfeasNegative(SCIP *scip, SCIP_Real val)
Definition: scip_numerics.c:1033
SCIP_Bool SCIPisFeasEQ(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
Definition: scip_numerics.c:771
SCIP_Bool SCIPisDualfeasPositive(SCIP *scip, SCIP_Real val)
Definition: scip_numerics.c:1021
SCIP_Bool SCIPisFeasLT(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
Definition: scip_numerics.c:784
SCIP_Bool SCIPisDualfeasZero(SCIP *scip, SCIP_Real val)
Definition: scip_numerics.c:1009
SCIP_Bool SCIPisEQ(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
Definition: scip_numerics.c:436
SCIP_RETCODE SCIPchgVarLb(SCIP *scip, SCIP_VAR *var, SCIP_Real newbound)
Definition: scip_var.c:5697
SCIP_RETCODE SCIPchgVarUb(SCIP *scip, SCIP_VAR *var, SCIP_Real newbound)
Definition: scip_var.c:5875
SCIP_Real SCIPadjustedVarUb(SCIP *scip, SCIP_VAR *var, SCIP_Real ub)
Definition: scip_var.c:5634
SCIP_Real SCIPadjustedVarLb(SCIP *scip, SCIP_VAR *var, SCIP_Real lb)
Definition: scip_var.c:5570
SCIP_Real SCIPvarGetBestRootLPObjval(SCIP_VAR *var)
Definition: var.c:19581
SCIP_Real SCIPgetVarImplRedcost(SCIP *scip, SCIP_VAR *var, SCIP_Bool varfixing)
Definition: scip_var.c:2653
Definition: multiprecision.hpp:66
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:242
static SCIP_RETCODE propagateRedcostVar(SCIP *scip, SCIP_VAR *var, SCIP_COL *col, SCIP_Real lpobjval, SCIP_Real cutoffbound, int *nchgbds)
Definition: prop_redcost.c:376
static SCIP_RETCODE propagateRootRedcostBinvar(SCIP *scip, SCIP_PROPDATA *propdata, SCIP_VAR *var, SCIP_COL *col, SCIP_Real cutoffbound, int *nchgbds)
Definition: prop_redcost.c:118
propagator using the LP reduced cost and the cutoff bound
public methods for LP management
public methods for message output
public methods for propagators
public methods for branch and bound tree
public methods for problem variables
public methods for branching rule plugins and branching
public methods for exact solving
general public methods
public methods for the LP relaxation, rows and columns
public methods for memory management
public methods for message handling
public methods for numerical tolerances
public methods for SCIP parameter handling
public methods for variable pricer plugins
public methods for global and local (sub)problems
public methods for propagator plugins
public methods for querying solving statistics
public methods for the branch-and-bound tree
public methods for SCIP variables
Definition: struct_lp.h:138
Definition: struct_prop.h:47
Definition: struct_var.h:262
Definition: struct_scip.h:72
type definitions for specific LP solvers interface