Scippy

SCIP

Solving Constraint Integer Programs

prop_genvbounds.c File Reference

Detailed Description

generalized variable bounds propagator

Author
Stefan Weltge
Ambros Gleixner

Definition in file prop_genvbounds.c.

#include <assert.h>
#include <string.h>
#include "scip/prop_genvbounds.h"
#include "scip/debug.h"

Go to the source code of this file.

Macros

#define PROP_NAME   "genvbounds"
 
#define PROP_DESC   "generalized variable bounds propagator"
 
#define PROP_TIMING   SCIP_PROPTIMING_ALWAYS
 
#define PROP_PRIORITY   3000000
 
#define PROP_FREQ   1
 
#define PROP_DELAY   FALSE
 
#define PROP_PRESOL_PRIORITY   -2000000
 
#define PROP_PRESOL_DELAY   FALSE
 
#define PROP_PRESOL_MAXROUNDS   -1
 
#define DEFAULT_GLOBAL_PROPAGATION   TRUE
 
#define DEFAULT_PROPAGATE_IN_ROOT_NODE   TRUE
 
#define DEFAULT_SORT   TRUE
 
#define EVENTHDLR_NAME   "genvbounds"
 
#define EVENTHDLR_DESC   "event handler for generalized variable bounds propagator"
 

Typedefs

typedef struct GenVBound GENVBOUND
 

Functions

static SCIP_Real getCutoffboundGenVBound (SCIP *scip, GENVBOUND *genvbound)
 
static GENVBOUNDgetGenVBound (SCIP *scip, SCIP_PROPDATA *propdata, SCIP_VAR *var, SCIP_BOUNDTYPE boundtype)
 
static SCIP_Real getGenVBoundsMinActivity (SCIP *scip, SCIP_VAR **vars, SCIP_Real *coefs, int nvars, SCIP_Bool global)
 
static SCIP_Real getGenVBoundsMinActivityConflict (SCIP *scip, SCIP_VAR **vars, SCIP_Real *coefs, int nvars, SCIP_BDCHGIDX *bdchgidx)
 
static SCIP_Real getGenVBoundsBound (SCIP *scip, GENVBOUND *genvbound, SCIP_Bool global)
 
static SCIP_RETCODE createStartingData (SCIP *scip, SCIP_PROPDATA *propdata)
 
static SCIP_RETCODE freeStartingData (SCIP *scip, SCIP_PROPDATA *propdata)
 
static SCIP_RETCODE fillGlobalStartingData (SCIP *scip, SCIP_PROPDATA *propdata)
 
static SCIP_RETCODE resetLocalStartingData (SCIP *scip, SCIP_PROPDATA *propdata)
 
static SCIP_RETCODE freeComponentsData (SCIP *scip, SCIP_PROPDATA *propdata)
 
static SCIP_RETCODE freeGenVBound (SCIP *scip, GENVBOUND *genvbound)
 
static SCIP_RETCODE resolveGenVBoundPropagation (SCIP *scip, GENVBOUND *genvbound, SCIP_BDCHGIDX *bdchgidx, SCIP_Real *boundval, SCIP_Bool *success)
 
static SCIP_RETCODE analyzeGenVBoundConflict (SCIP *scip, GENVBOUND *genvbound)
 
static SCIP_RETCODE applyGenVBound (SCIP *scip, SCIP_PROP *prop, GENVBOUND *genvbound, SCIP_Bool global, SCIP_RESULT *result, int *nchgbds)
 
static SCIP_RETCODE freeEventData (SCIP *scip, SCIP_EVENTDATA **eventdata)
 
static SCIP_RETCODE freeAllEventData (SCIP *scip, SCIP_PROPDATA *propdata)
 
static SCIP_RETCODE dropAndFreeEvents (SCIP *scip, SCIP_PROPDATA *propdata)
 
static SCIP_RETCODE getEventData (SCIP *scip, SCIP_PROPDATA *propdata, SCIP_VAR *var, SCIP_BOUNDTYPE boundtype, SCIP_EVENTDATA **eventdata)
 
static SCIP_RETCODE addEventData (SCIP *scip, SCIP_PROPDATA *propdata, SCIP_VAR *var, int startindex, int startcomponent, SCIP_BOUNDTYPE boundtype)
 
static SCIP_RETCODE setUpEvents (SCIP *scip, SCIP_PROPDATA *propdata)
 
static SCIP_RETCODE sortGenVBounds (SCIP *scip, SCIP_PROPDATA *propdata)
 
static SCIP_RETCODE applyGenVBounds (SCIP *scip, SCIP_PROP *prop, SCIP_Bool global, SCIP_RESULT *result, int *nchgbds)
 
static SCIP_RETCODE initPropdata (SCIP *scip, SCIP_PROPDATA *propdata)
 
static SCIP_RETCODE addNewGenVBound (SCIP *scip, SCIP_PROPDATA *propdata, GENVBOUND *genvbound)
 
static SCIP_RETCODE execGenVBounds (SCIP *scip, SCIP_PROPDATA *propdata, SCIP_RESULT *result, SCIP_Bool local, int *nchgbds)
 
SCIP_RETCODE SCIPgenVBoundAdd (SCIP *scip, SCIP_PROP *genvboundprop, SCIP_VAR **vars, SCIP_VAR *var, SCIP_Real *coefs, int ncoefs, SCIP_Real coefcutoffbound, SCIP_Real constant, SCIP_BOUNDTYPE boundtype)
 
static SCIP_DECL_PROPINIT (propInitGenvbounds)
 
static SCIP_DECL_PROPPRESOL (propPresolGenvbounds)
 
static SCIP_DECL_PROPEXITPRE (propExitpreGenvbounds)
 
static SCIP_DECL_PROPEXEC (propExecGenvbounds)
 
static SCIP_DECL_PROPRESPROP (propRespropGenvbounds)
 
static SCIP_DECL_PROPEXITSOL (propExitsolGenvbounds)
 
static SCIP_DECL_PROPFREE (propFreeGenvbounds)
 
static SCIP_DECL_EVENTEXEC (eventExecGenvbounds)
 
SCIP_RETCODE SCIPincludePropGenvbounds (SCIP *scip)
 

Macro Definition Documentation

#define PROP_DESC   "generalized variable bounds propagator"

Definition at line 36 of file prop_genvbounds.c.

Referenced by SCIPincludePropGenvbounds().

#define PROP_TIMING   SCIP_PROPTIMING_ALWAYS

Definition at line 37 of file prop_genvbounds.c.

Referenced by SCIPincludePropGenvbounds().

#define PROP_PRIORITY   3000000

propagator priority

Definition at line 38 of file prop_genvbounds.c.

Referenced by SCIPincludePropGenvbounds().

#define PROP_FREQ   1

propagator frequency

Definition at line 39 of file prop_genvbounds.c.

Referenced by SCIPincludePropGenvbounds().

#define PROP_DELAY   FALSE

should propagation method be delayed, if other propagators found reductions?

Definition at line 40 of file prop_genvbounds.c.

Referenced by SCIPincludePropGenvbounds().

#define PROP_PRESOL_PRIORITY   -2000000

priority of the presolving method (>= 0: before, < 0: after constraint handlers); combined with presolvers

Definition at line 42 of file prop_genvbounds.c.

Referenced by SCIPincludePropGenvbounds().

#define PROP_PRESOL_DELAY   FALSE

should presolving be delay, if other presolvers found reductions?

Definition at line 44 of file prop_genvbounds.c.

Referenced by SCIPincludePropGenvbounds().

#define PROP_PRESOL_MAXROUNDS   -1

maximal number of presolving rounds the presolver participates in (-1: no limit)

Definition at line 46 of file prop_genvbounds.c.

Referenced by SCIPincludePropGenvbounds().

#define DEFAULT_GLOBAL_PROPAGATION   TRUE

apply global propagation?

Definition at line 48 of file prop_genvbounds.c.

Referenced by SCIPincludePropGenvbounds().

#define DEFAULT_PROPAGATE_IN_ROOT_NODE   TRUE

apply genvbounds in root node if no new incumbent was found?

Definition at line 49 of file prop_genvbounds.c.

Referenced by SCIPincludePropGenvbounds().

#define DEFAULT_SORT   TRUE

sort genvbounds and wait for bound change events? (otherwise all genvbounds are applied in each node)

Definition at line 50 of file prop_genvbounds.c.

Referenced by SCIPincludePropGenvbounds().

#define EVENTHDLR_NAME   "genvbounds"

Definition at line 53 of file prop_genvbounds.c.

Referenced by SCIPincludePropGenvbounds().

#define EVENTHDLR_DESC   "event handler for generalized variable bounds propagator"

Definition at line 54 of file prop_genvbounds.c.

Referenced by SCIPincludePropGenvbounds().

Typedef Documentation

typedef struct GenVBound GENVBOUND

Definition at line 75 of file prop_genvbounds.c.

Function Documentation

static SCIP_Real getCutoffboundGenVBound ( SCIP scip,
GENVBOUND genvbound 
)
static

returns correct cutoff bound value

Parameters
scipSCIP data structure
genvboundgenvbound

Definition at line 135 of file prop_genvbounds.c.

References NULL, SCIPdebugMessage, SCIPgetCutoffbound(), SCIPgetTransObjoffset(), and SCIPgetTransObjscale().

Referenced by getGenVBoundsBound(), and resolveGenVBoundPropagation().

static GENVBOUND* getGenVBound ( SCIP scip,
SCIP_PROPDATA propdata,
SCIP_VAR var,
SCIP_BOUNDTYPE  boundtype 
)
static

returns corresponding genvbound in genvboundstore if there is one, NULL otherwise

Parameters
scipSCIP data structure
propdatadata of the genvbounds propagator
varbounds variable
boundtypebounds type

Definition at line 158 of file prop_genvbounds.c.

References NULL, SCIP_BOUNDTYPE_LOWER, and SCIPhashmapGetImage().

Referenced by addNewGenVBound(), and SCIPgenVBoundAdd().

static SCIP_Real getGenVBoundsMinActivity ( SCIP scip,
SCIP_VAR **  vars,
SCIP_Real coefs,
int  nvars,
SCIP_Bool  global 
)
static

calculates the minactivity of a linear combination of variables stored in an array

Parameters
scipSCIP data structure
varsarray of variables
coefsarray of coefficients
nvarsnumber of variables
globaluse global variable bounds?

Definition at line 225 of file prop_genvbounds.c.

References NULL, SCIP_Real, SCIPinfinity(), SCIPisInfinity(), SCIPisZero(), SCIPvarGetLbGlobal(), SCIPvarGetLbLocal(), SCIPvarGetUbGlobal(), and SCIPvarGetUbLocal().

Referenced by getGenVBoundsBound().

static SCIP_Real getGenVBoundsMinActivityConflict ( SCIP scip,
SCIP_VAR **  vars,
SCIP_Real coefs,
int  nvars,
SCIP_BDCHGIDX bdchgidx 
)
static

calculates the minactivity of a linear combination of variables stored in the current conflict set

Parameters
scipSCIP data structure
varsarray of variables
coefsarray of coefficients
nvarsnumber of variables
bdchgidxbound change at which minactivity should be computed; if NULL use local bounds

Definition at line 268 of file prop_genvbounds.c.

References NULL, SCIP_Real, SCIPgetConflictVarLb(), SCIPgetConflictVarUb(), SCIPinfinity(), SCIPisEQ(), SCIPisInfinity(), SCIPisZero(), SCIPvarGetLbAtIndex(), SCIPvarGetLbLocal(), SCIPvarGetUbAtIndex(), SCIPvarGetUbLocal(), and TRUE.

Referenced by resolveGenVBoundPropagation().

static SCIP_Real getGenVBoundsBound ( SCIP scip,
GENVBOUND genvbound,
SCIP_Bool  global 
)
static

returns a valid bound given by a generalized variable bound

Parameters
scipSCIP data structure
genvboundgeneralized variable bound
globaluse global variable bounds?

Definition at line 330 of file prop_genvbounds.c.

References GenVBound::boundtype, GenVBound::coefs, GenVBound::constant, GenVBound::cutoffcoef, getCutoffboundGenVBound(), getGenVBoundsMinActivity(), GenVBound::ncoefs, NULL, SCIP_BOUNDTYPE_LOWER, SCIP_BOUNDTYPE_UPPER, SCIP_Real, SCIPinfinity(), SCIPisInfinity(), and GenVBound::vars.

Referenced by applyGenVBound().

static SCIP_RETCODE createStartingData ( SCIP scip,
SCIP_PROPDATA propdata 
)
static

allocate local and global startindices, startcomponents and startmap

Parameters
scipSCIP data structure
propdatadata of the genvbounds propagator

Definition at line 412 of file prop_genvbounds.c.

References NULL, SCIP_CALL, SCIP_OKAY, SCIPallocMemoryArray, SCIPblkmem(), SCIPcalcHashtableSize(), SCIPdebugMessage, and SCIPhashmapCreate().

Referenced by execGenVBounds().

static SCIP_RETCODE freeStartingData ( SCIP scip,
SCIP_PROPDATA propdata 
)
static

free local and global startindices, startcomponents and startmap

Parameters
scipSCIP data structure
propdatadata of the genvbounds propagator

Definition at line 451 of file prop_genvbounds.c.

References NULL, SCIP_OKAY, SCIPdebugMessage, SCIPfreeMemoryArray, and SCIPhashmapFree().

Referenced by execGenVBounds(), and SCIP_DECL_PROPEXITSOL().

static SCIP_RETCODE fillGlobalStartingData ( SCIP scip,
SCIP_PROPDATA propdata 
)
static
Parameters
scipSCIP data structure
propdatadata of the genvbounds propagator

Definition at line 494 of file prop_genvbounds.c.

References NULL, SCIP_CALL, SCIP_OKAY, SCIPdebugMessage, SCIPisNegative(), SCIPisZero(), and SCIPreallocMemoryArray.

Referenced by execGenVBounds().

static SCIP_RETCODE resetLocalStartingData ( SCIP scip,
SCIP_PROPDATA propdata 
)
static

resets local starting data

Parameters
scipSCIP data structure
propdatadata of the genvbounds propagator

Definition at line 542 of file prop_genvbounds.c.

References NULL, SCIP_CALL, SCIP_OKAY, and SCIPhashmapRemoveAll().

Referenced by applyGenVBounds(), and SCIP_DECL_EVENTEXEC().

static SCIP_RETCODE freeComponentsData ( SCIP scip,
SCIP_PROPDATA propdata 
)
static

frees sorted components data

Parameters
scipSCIP data structure
propdatadata of the genvbounds propagator

Definition at line 562 of file prop_genvbounds.c.

References NULL, SCIP_OKAY, SCIPdebugMessage, and SCIPfreeMemoryArray.

Referenced by execGenVBounds(), and SCIP_DECL_PROPEXITSOL().

static SCIP_RETCODE freeGenVBound ( SCIP scip,
GENVBOUND genvbound 
)
static

frees memory allocated for a generalized variable bound

Definition at line 588 of file prop_genvbounds.c.

References GenVBound::coefs, NULL, SCIP_OKAY, SCIPfreeMemory, SCIPfreeMemoryArray, and GenVBound::vars.

Referenced by SCIP_DECL_PROPEXITPRE(), and SCIP_DECL_PROPEXITSOL().

static SCIP_RETCODE resolveGenVBoundPropagation ( SCIP scip,
GENVBOUND genvbound,
SCIP_BDCHGIDX bdchgidx,
SCIP_Real boundval,
SCIP_Bool success 
)
static

resolves propagation of lower bound on +/- left-hand side variable of a generalized variable bound

Parameters
scipSCIP data structure
genvboundgenvbound data structure
bdchgidxthe index of the bound change, representing the point of time where the change took place
boundvalpointer to lower bound value on +/- left-hand side variable
successwas the explanation succesful?

Definition at line 608 of file prop_genvbounds.c.

References GenVBound::boundtype, GenVBound::coefs, GenVBound::constant, GenVBound::cutoffcoef, FALSE, getCutoffboundGenVBound(), getGenVBoundsMinActivityConflict(), MAX, GenVBound::ncoefs, NULL, SCIP_BOUNDTYPE_LOWER, SCIP_BOUNDTYPE_UPPER, SCIP_CALL, SCIP_OKAY, SCIP_Real, SCIPaddConflictRelaxedLb(), SCIPaddConflictRelaxedUb(), SCIPdebugMessage, SCIPfeasCeil(), SCIPgetConflictVarLb(), SCIPgetConflictVarUb(), SCIPisEQ(), SCIPisGE(), SCIPisGT(), SCIPisLE(), SCIPisLT(), SCIPisPositive(), SCIPisZero(), SCIPvarGetLbAtIndex(), SCIPvarGetLbGlobal(), SCIPvarGetLbLocal(), SCIPvarGetName(), SCIPvarGetUbAtIndex(), SCIPvarGetUbGlobal(), SCIPvarGetUbLocal(), SCIPvarIsIntegral(), TRUE, GenVBound::var, and GenVBound::vars.

Referenced by analyzeGenVBoundConflict(), and SCIP_DECL_PROPRESPROP().

static SCIP_RETCODE applyGenVBound ( SCIP scip,
SCIP_PROP prop,
GENVBOUND genvbound,
SCIP_Bool  global,
SCIP_RESULT result,
int *  nchgbds 
)
static

apply propagation for one generalized variable bound; also if the left-hand side variable is locally fixed, we compute the right-hand side minactivity to possibly detect infeasibility

Parameters
scipSCIP data structure
propgenvbounds propagator
genvboundgenvbound data structure
globalapply global bound changes? (global: true, local: false)
resultresult pointer
nchgbdscounter to increment if bound was tightened

Definition at line 959 of file prop_genvbounds.c.

References analyzeGenVBoundConflict(), GenVBound::boundtype, FALSE, getGenVBoundsBound(), GenVBound::index, NULL, SCIP_Bool, SCIP_BOUNDTYPE_LOWER, SCIP_BOUNDTYPE_UPPER, SCIP_CALL, SCIP_CUTOFF, SCIP_DIDNOTRUN, SCIP_OKAY, SCIP_Real, SCIP_REDUCEDDOM, SCIP_STAGE_PRESOLVING, SCIP_SUCCESS, SCIP_VARSTATUS_MULTAGGR, SCIPdebugMessage, SCIPgetStage(), SCIPinferVarLbProp(), SCIPinferVarUbProp(), SCIPtightenVarLbGlobal(), SCIPtightenVarUbGlobal(), SCIPvarGetLbGlobal(), SCIPvarGetLbLocal(), SCIPvarGetName(), SCIPvarGetStatus(), SCIPvarGetUbGlobal(), SCIPvarGetUbLocal(), and GenVBound::var.

Referenced by applyGenVBounds().

static SCIP_RETCODE freeEventData ( SCIP scip,
SCIP_EVENTDATA **  eventdata 
)
static

frees event data

Parameters
scipSCIP data structure
eventdataevent data to be freed

Definition at line 1090 of file prop_genvbounds.c.

References NULL, SCIP_OKAY, SCIPfreeMemory, and SCIPfreeMemoryArray.

Referenced by freeAllEventData().

static SCIP_RETCODE freeAllEventData ( SCIP scip,
SCIP_PROPDATA propdata 
)
static

frees all eventdata stored

Parameters
scipSCIP data structure
propdatadata of the genvbounds propagator

Definition at line 1113 of file prop_genvbounds.c.

References freeEventData(), NULL, SCIP_CALL, SCIP_OKAY, SCIPfreeMemoryArray, and SCIPhashmapFree().

Referenced by dropAndFreeEvents().

static SCIP_RETCODE dropAndFreeEvents ( SCIP scip,
SCIP_PROPDATA propdata 
)
static

drops all events caught by genvbounds propagator and frees their data

Parameters
scipSCIP data structure
propdatadata of the genvbounds propagator

Definition at line 1160 of file prop_genvbounds.c.

References freeAllEventData(), NULL, SCIP_CALL, SCIP_EVENTTYPE_LBTIGHTENED, SCIP_EVENTTYPE_UBTIGHTENED, SCIP_OKAY, SCIPdebugMessage, and SCIPdropVarEvent().

Referenced by execGenVBounds(), and SCIP_DECL_PROPEXITSOL().

static SCIP_RETCODE getEventData ( SCIP scip,
SCIP_PROPDATA propdata,
SCIP_VAR var,
SCIP_BOUNDTYPE  boundtype,
SCIP_EVENTDATA **  eventdata 
)
static

returns the corresponding event data entry in the corresponding array, if there is one; if not: allocates a new event data entry, stores it in the array and returns its adress

Parameters
scipSCIP data structure
propdatadata of the genvbounds propagator
varvariable
boundtypetype of bound
eventdataevent data to return

Definition at line 1209 of file prop_genvbounds.c.

References NULL, SCIP_BOUNDTYPE_LOWER, SCIP_CALL, SCIP_OKAY, SCIPallocMemory, SCIPallocMemoryArray, SCIPhashmapExists(), SCIPhashmapGetImage(), and SCIPhashmapInsert().

Referenced by addEventData().

static SCIP_RETCODE addEventData ( SCIP scip,
SCIP_PROPDATA propdata,
SCIP_VAR var,
int  startindex,
int  startcomponent,
SCIP_BOUNDTYPE  boundtype 
)
static

adds an event to the event array lbevents (if boundtype == SCIP_BOUNDTYPE_LOWER) or ubevents (if boundtype == SCIP_BOUNDTYPE_UPPER)

Parameters
scipSCIP data structure
propdatadata of the genvbounds propagator
varvariable thats event to be added
startindexstarting index
startcomponentstarting components index
boundtypetype of bound

Definition at line 1260 of file prop_genvbounds.c.

References getEventData(), NULL, SCIP_CALL, and SCIP_OKAY.

Referenced by setUpEvents().

static SCIP_RETCODE sortGenVBounds ( SCIP scip,
SCIP_PROPDATA propdata 
)
static

performs a topological sort on genvboundstore array

The genvbounds graph is defined as follows: Given two genvbounds

(genvbound1) c1 * x_i1 >= RHS1

and

(genvbound2) c2 * x_i2 >= RHS2,

there is an arc from genvbound1 to genvbound2 iff c1 = +1 and x_i1 appears with positive coefficient in RHS2 or c1 = -1 and x_i1 appears with negative coefficient in RHS2; in this case, a bound change of x_i1 deduced from genvbound1 improves genvbound2's minactivity in RHS2.

Parameters
scipSCIP data structure
propdatadata of the genvbounds propagator

Definition at line 1426 of file prop_genvbounds.c.

References GenVBound::coefs, GenVBound::index, GenVBound::ncoefs, NULL, SCIP_CALL, SCIP_OKAY, SCIPallocMemoryArray, SCIPdebugMessage, SCIPdigraphAddArc(), SCIPdigraphComputeUndirectedComponents(), SCIPdigraphCreate(), SCIPdigraphFree(), SCIPdigraphGetComponent(), SCIPdigraphGetNComponents(), SCIPdigraphTopoSortComponents(), SCIPfreeMemoryArray, SCIPhashmapExists(), SCIPhashmapGetImage(), SCIPisNegative(), SCIPisPositive(), TRUE, and GenVBound::vars.

Referenced by execGenVBounds().

static SCIP_RETCODE applyGenVBounds ( SCIP scip,
SCIP_PROP prop,
SCIP_Bool  global,
SCIP_RESULT result,
int *  nchgbds 
)
static

apply propagation of generalized variable bounds

Parameters
scipSCIP data structure
propgenvbounds propagator
globaluse global variable bounds for propagation?
resultresult pointer
nchgbdscounter to increase by the number of changed bounds

Definition at line 1541 of file prop_genvbounds.c.

References applyGenVBound(), NULL, resetLocalStartingData(), SCIP_CALL, SCIP_CUTOFF, SCIP_DIDNOTFIND, SCIP_DIDNOTRUN, SCIP_OKAY, SCIP_VARSTATUS_MULTAGGR, SCIPdebugMessage, SCIPgetDepth(), SCIPinProbing(), SCIPpropGetData(), and SCIPvarGetStatus().

Referenced by execGenVBounds().

static SCIP_RETCODE initPropdata ( SCIP scip,
SCIP_PROPDATA propdata 
)
static

initialize propagator data

Parameters
scipSCIP data structure
propdatadata of the genvbounds propagator

Definition at line 1632 of file prop_genvbounds.c.

References BMSclearMemoryArray, NULL, SCIP_CALL, SCIP_OKAY, SCIPallocMemoryArray, SCIPblkmem(), SCIPcalcHashtableSize(), SCIPdebugMessage, SCIPgetNVars(), and SCIPhashmapCreate().

Referenced by SCIPgenVBoundAdd().

static SCIP_RETCODE addNewGenVBound ( SCIP scip,
SCIP_PROPDATA propdata,
GENVBOUND genvbound 
)
static

adds a new genvbound to genvboundstore array and sets a hashmap entry

Parameters
scipSCIP data structure
propdatadata of the genvbounds propagator
genvboundgenvbound to be added

Definition at line 1661 of file prop_genvbounds.c.

References GenVBound::boundtype, getGenVBound(), GenVBound::index, NULL, SCIP_BOUNDTYPE_LOWER, SCIP_CALL, SCIP_OKAY, SCIPhashmapInsert(), SCIPreallocMemoryArray, and GenVBound::var.

Referenced by SCIPgenVBoundAdd().

static SCIP_RETCODE execGenVBounds ( SCIP scip,
SCIP_PROPDATA propdata,
SCIP_RESULT result,
SCIP_Bool  local,
int *  nchgbds 
)
static

runs propagation routine

Parameters
scipSCIP data structure
propdatadata of the genvbounds propagator
resultresult pointer
localshould local propagation be applied?
nchgbdscounter to increase by the number of changed bounds

Definition at line 1700 of file prop_genvbounds.c.

References applyGenVBounds(), createStartingData(), dropAndFreeEvents(), FALSE, fillGlobalStartingData(), freeComponentsData(), freeStartingData(), NULL, SCIP_CALL, SCIP_CUTOFF, SCIP_DIDNOTFIND, SCIP_DIDNOTRUN, SCIP_OKAY, SCIPdebugMessage, SCIPgetCurrentNode(), SCIPgetCutoffbound(), SCIPgetDepth(), SCIPinProbing(), SCIPisFeasLT(), setUpEvents(), sortGenVBounds(), and TRUE.

Referenced by SCIP_DECL_PROPEXEC(), and SCIP_DECL_PROPPRESOL().

SCIP_RETCODE SCIPgenVBoundAdd ( SCIP scip,
SCIP_PROP genvboundprop,
SCIP_VAR **  vars,
SCIP_VAR var,
SCIP_Real coefs,
int  ncoefs,
SCIP_Real  coefcutoffbound,
SCIP_Real  constant,
SCIP_BOUNDTYPE  boundtype 
)

adds a generalized variable bound to the genvbounds propagator; if there is already a genvbound for the bound "boundtype" of variable "var", it will be replaced

Parameters
scipSCIP data structure
genvboundpropgenvbound propagator
varsarray of RHSs variables
varLHSs variable
coefsarray of coefficients for the RHSs variables
ncoefssize of coefs array
coefcutoffboundnonpositive value of the cutoff bounds multiplier
constantconstant term
boundtypetype of bound provided by the genvbound

Definition at line 1785 of file prop_genvbounds.c.

References addNewGenVBound(), GenVBound::boundtype, GenVBound::coefs, GenVBound::constant, GenVBound::cutoffcoef, FALSE, getGenVBound(), initPropdata(), GenVBound::ncoefs, NULL, PROP_NAME, SCIP_Bool, SCIP_CALL, SCIP_OKAY, SCIPallocMemory, SCIPdebug, SCIPdebugMessage, SCIPduplicateMemoryArray, SCIPfreeMemoryArray, SCIPgetTransObjoffset(), SCIPgetTransObjscale(), SCIPisNegative(), SCIPisPositive(), SCIPpropGetData(), SCIPpropGetName(), SCIPreallocMemoryArray, GenVBound::var, and GenVBound::vars.

Referenced by createGenVBound().

static SCIP_DECL_PROPINIT ( propInitGenvbounds  )
static

initialization method of propagator (called after problem was transformed)

Definition at line 1929 of file prop_genvbounds.c.

References FALSE, NULL, PROP_NAME, SCIP_OKAY, SCIPinfinity(), SCIPpropGetData(), and SCIPpropGetName().

static SCIP_DECL_PROPPRESOL ( propPresolGenvbounds  )
static
static SCIP_DECL_PROPEXEC ( propExecGenvbounds  )
static
static SCIP_DECL_PROPEXITSOL ( propExitsolGenvbounds  )
static

solving process deinitialization method of propagator (called before branch and bound process data is freed)

Definition at line 2185 of file prop_genvbounds.c.

References dropAndFreeEvents(), freeComponentsData(), freeGenVBound(), freeStartingData(), NULL, PROP_NAME, SCIP_CALL, SCIP_OKAY, SCIPdebugMessage, SCIPfreeMemoryArray, SCIPgetProbName(), SCIPhashmapFree(), SCIPisInRestart(), SCIPpropGetData(), and SCIPpropGetName().

static SCIP_DECL_PROPFREE ( propFreeGenvbounds  )
static

destructor of propagator to free user data (called when SCIP is exiting)

Definition at line 2230 of file prop_genvbounds.c.

References NULL, PROP_NAME, SCIP_OKAY, SCIPfreeMemory, SCIPpropGetData(), SCIPpropGetName(), and SCIPpropSetData().