Scippy

SCIP

Solving Constraint Integer Programs

Detailed Description

Methods and datastructures for storing and manipulating the main problem.

Author
Tobias Achterberg

Definition in file prob.c.

#include "scip/branch.h"
#include "scip/conflictstore.h"
#include "scip/cons.h"
#include "scip/event.h"
#include "scip/lp.h"
#include "scip/primal.h"
#include "scip/prob.h"
#include "scip/pub_cons.h"
#include "scip/pub_lp.h"
#include "scip/pub_message.h"
#include "scip/pub_misc.h"
#include "scip/pub_misc_sort.h"
#include "scip/pub_var.h"
#include "scip/set.h"
#include "scip/stat.h"
#include "scip/struct_cons.h"
#include "scip/struct_lp.h"
#include "scip/struct_prob.h"
#include "scip/struct_set.h"
#include "scip/struct_stat.h"
#include "scip/struct_var.h"
#include "scip/var.h"
#include <string.h>

Go to the source code of this file.

Macros

#define OBJSCALE_MAXDNOM   1000000LL
 
#define OBJSCALE_MAXSCALE   1000000.0
 
#define OBJSCALE_MAXFINALSCALE   1000.0
 

Functions

static SCIP_RETCODE probEnsureVarsMem (SCIP_PROB *prob, SCIP_SET *set, int num)
 
static SCIP_RETCODE probEnsureFixedvarsMem (SCIP_PROB *prob, SCIP_SET *set, int num)
 
static SCIP_RETCODE probEnsureDeletedvarsMem (SCIP_PROB *prob, SCIP_SET *set, int num)
 
static SCIP_RETCODE probEnsureConssMem (SCIP_PROB *prob, SCIP_SET *set, int num)
 
static SCIP_Bool consHasName (SCIP_CONS *cons)
 
static SCIP_Bool varHasName (SCIP_VAR *var)
 
SCIP_RETCODE SCIPprobCopy (SCIP_PROB **prob, BMS_BLKMEM *blkmem, SCIP_SET *set, const char *name, SCIP *sourcescip, SCIP_PROB *sourceprob, SCIP_HASHMAP *varmap, SCIP_HASHMAP *consmap, SCIP_Bool original, SCIP_Bool global)
 
SCIP_RETCODE SCIPprobCreate (SCIP_PROB **prob, BMS_BLKMEM *blkmem, SCIP_SET *set, const char *name, SCIP_DECL_PROBDELORIG((*probdelorig)), SCIP_DECL_PROBTRANS((*probtrans)), SCIP_DECL_PROBDELTRANS((*probdeltrans)), SCIP_DECL_PROBINITSOL((*probinitsol)), SCIP_DECL_PROBEXITSOL((*probexitsol)), SCIP_DECL_PROBCOPY((*probcopy)), SCIP_PROBDATA *probdata, SCIP_Bool transformed)
 
void SCIPprobSetDelorig (SCIP_PROB *prob, SCIP_DECL_PROBDELORIG((*probdelorig)))
 
void SCIPprobSetTrans (SCIP_PROB *prob, SCIP_DECL_PROBTRANS((*probtrans)))
 
void SCIPprobSetDeltrans (SCIP_PROB *prob, SCIP_DECL_PROBDELTRANS((*probdeltrans)))
 
void SCIPprobSetInitsol (SCIP_PROB *prob, SCIP_DECL_PROBINITSOL((*probinitsol)))
 
void SCIPprobSetExitsol (SCIP_PROB *prob, SCIP_DECL_PROBEXITSOL((*probexitsol)))
 
void SCIPprobSetCopy (SCIP_PROB *prob, SCIP_DECL_PROBCOPY((*probcopy)))
 
SCIP_RETCODE SCIPprobFree (SCIP_PROB **prob, SCIP_MESSAGEHDLR *messagehdlr, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_STAT *stat, SCIP_EVENTQUEUE *eventqueue, SCIP_LP *lp)
 
SCIP_RETCODE SCIPprobTransform (SCIP_PROB *source, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_STAT *stat, SCIP_PRIMAL *primal, SCIP_TREE *tree, SCIP_REOPT *reopt, SCIP_LP *lp, SCIP_BRANCHCAND *branchcand, SCIP_EVENTFILTER *eventfilter, SCIP_EVENTQUEUE *eventqueue, SCIP_CONFLICTSTORE *conflictstore, SCIP_PROB **target)
 
SCIP_RETCODE SCIPprobResetBounds (SCIP_PROB *prob, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_STAT *stat)
 
void SCIPprobResortVars (SCIP_PROB *prob)
 
SCIP_RETCODE SCIPprobSortConssCheck (SCIP_PROB *prob)
 
void SCIPprobSetData (SCIP_PROB *prob, SCIP_PROBDATA *probdata)
 
static void probInsertVar (SCIP_PROB *prob, SCIP_VAR *var)
 
static SCIP_RETCODE probRemoveVar (SCIP_PROB *prob, BMS_BLKMEM *blkmem, SCIP_CLIQUETABLE *cliquetable, SCIP_SET *set, SCIP_VAR *var)
 
SCIP_RETCODE SCIPprobAddVarName (SCIP_PROB *prob, SCIP_VAR *var)
 
SCIP_RETCODE SCIPprobRemoveVarName (SCIP_PROB *prob, SCIP_VAR *var)
 
SCIP_RETCODE SCIPprobAddVar (SCIP_PROB *prob, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_LP *lp, SCIP_BRANCHCAND *branchcand, SCIP_EVENTFILTER *eventfilter, SCIP_EVENTQUEUE *eventqueue, SCIP_VAR *var)
 
SCIP_RETCODE SCIPprobDelVar (SCIP_PROB *prob, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_EVENTQUEUE *eventqueue, SCIP_VAR *var, SCIP_Bool *deleted)
 
SCIP_RETCODE SCIPprobPerformVarDeletions (SCIP_PROB *prob, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_STAT *stat, SCIP_EVENTQUEUE *eventqueue, SCIP_CLIQUETABLE *cliquetable, SCIP_LP *lp, SCIP_BRANCHCAND *branchcand)
 
SCIP_RETCODE SCIPprobChgVarType (SCIP_PROB *prob, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_PRIMAL *primal, SCIP_LP *lp, SCIP_BRANCHCAND *branchcand, SCIP_EVENTQUEUE *eventqueue, SCIP_CLIQUETABLE *cliquetable, SCIP_VAR *var, SCIP_VARTYPE vartype)
 
SCIP_RETCODE SCIPprobVarChangedStatus (SCIP_PROB *prob, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_BRANCHCAND *branchcand, SCIP_CLIQUETABLE *cliquetable, SCIP_VAR *var)
 
SCIP_RETCODE SCIPprobAddConsName (SCIP_PROB *prob, SCIP_CONS *cons)
 
SCIP_RETCODE SCIPprobRemoveConsName (SCIP_PROB *prob, SCIP_CONS *cons)
 
SCIP_RETCODE SCIPprobAddCons (SCIP_PROB *prob, SCIP_SET *set, SCIP_STAT *stat, SCIP_CONS *cons)
 
SCIP_RETCODE SCIPprobDelCons (SCIP_PROB *prob, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_STAT *stat, SCIP_CONS *cons)
 
void SCIPprobMarkNConss (SCIP_PROB *prob)
 
void SCIPprobSetObjsense (SCIP_PROB *prob, SCIP_OBJSENSE objsense)
 
void SCIPprobAddObjoffset (SCIP_PROB *prob, SCIP_Real addval)
 
void SCIPprobSetDualbound (SCIP_PROB *prob, SCIP_Real dualbound)
 
void SCIPprobSetObjlim (SCIP_PROB *prob, SCIP_Real objlim)
 
void SCIPprobSetObjIntegral (SCIP_PROB *prob)
 
SCIP_RETCODE SCIPprobCheckObjIntegral (SCIP_PROB *transprob, SCIP_PROB *origprob, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_STAT *stat, SCIP_PRIMAL *primal, SCIP_TREE *tree, SCIP_REOPT *reopt, SCIP_LP *lp, SCIP_EVENTFILTER *eventfilter, SCIP_EVENTQUEUE *eventqueue)
 
void SCIPprobUpdateNObjVars (SCIP_PROB *prob, SCIP_SET *set, SCIP_Real oldobj, SCIP_Real newobj)
 
void SCIPprobUpdateDualbound (SCIP_PROB *prob, SCIP_Real newbound)
 
void SCIPprobInvalidateDualbound (SCIP_PROB *prob)
 
SCIP_RETCODE SCIPprobScaleObj (SCIP_PROB *transprob, SCIP_PROB *origprob, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_STAT *stat, SCIP_PRIMAL *primal, SCIP_TREE *tree, SCIP_REOPT *reopt, SCIP_LP *lp, SCIP_EVENTFILTER *eventfilter, SCIP_EVENTQUEUE *eventqueue)
 
void SCIPprobStoreRootSol (SCIP_PROB *prob, SCIP_SET *set, SCIP_STAT *stat, SCIP_LP *lp, SCIP_Bool roothaslp)
 
void SCIPprobUpdateBestRootSol (SCIP_PROB *prob, SCIP_SET *set, SCIP_STAT *stat, SCIP_LP *lp)
 
SCIP_RETCODE SCIPprobExitPresolve (SCIP_PROB *prob, SCIP_SET *set)
 
SCIP_RETCODE SCIPprobInitSolve (SCIP_PROB *prob, SCIP_SET *set)
 
SCIP_RETCODE SCIPprobExitSolve (SCIP_PROB *prob, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_EVENTQUEUE *eventqueue, SCIP_LP *lp, SCIP_Bool restart)
 
SCIP_RETCODE SCIPprobSetName (SCIP_PROB *prob, const char *name)
 
int SCIPprobGetNImplBinVars (SCIP_PROB *prob)
 
int SCIPprobGetNObjVars (SCIP_PROB *prob, SCIP_SET *set)
 
SCIP_Real SCIPprobGetAbsMinObjCoef (SCIP_PROB *prob, SCIP_SET *set)
 
SCIP_Real SCIPprobGetAbsMaxObjCoef (SCIP_PROB *prob, SCIP_SET *set)
 
SCIP_Real SCIPprobExternObjval (SCIP_PROB *transprob, SCIP_PROB *origprob, SCIP_SET *set, SCIP_Real objval)
 
SCIP_Real SCIPprobInternObjval (SCIP_PROB *transprob, SCIP_PROB *origprob, SCIP_SET *set, SCIP_Real objval)
 
SCIP_VARSCIPprobFindVar (SCIP_PROB *prob, const char *name)
 
SCIP_CONSSCIPprobFindCons (SCIP_PROB *prob, const char *name)
 
void SCIPprobPrintPseudoSol (SCIP_PROB *prob, SCIP_SET *set, SCIP_MESSAGEHDLR *messagehdlr)
 
void SCIPprobPrintStatistics (SCIP_PROB *prob, SCIP_SET *set, SCIP_MESSAGEHDLR *messagehdlr, FILE *file)
 
SCIP_Bool SCIPprobIsPermuted (SCIP_PROB *prob)
 
void SCIPprobMarkPermuted (SCIP_PROB *prob)
 
SCIP_Bool SCIPprobIsTransformed (SCIP_PROB *prob)
 
SCIP_Bool SCIPprobIsObjIntegral (SCIP_PROB *prob)
 
SCIP_Bool SCIPprobAllColsInLP (SCIP_PROB *prob, SCIP_SET *set, SCIP_LP *lp)
 
SCIP_Real SCIPprobGetObjlim (SCIP_PROB *prob, SCIP_SET *set)
 
SCIP_PROBDATASCIPprobGetData (SCIP_PROB *prob)
 
const char * SCIPprobGetName (SCIP_PROB *prob)
 
int SCIPprobGetNVars (SCIP_PROB *prob)
 
int SCIPprobGetNBinVars (SCIP_PROB *prob)
 
int SCIPprobGetNIntVars (SCIP_PROB *prob)
 
int SCIPprobGetNImplVars (SCIP_PROB *prob)
 
int SCIPprobGetNContVars (SCIP_PROB *prob)
 
SCIP_VAR ** SCIPprobGetVars (SCIP_PROB *prob)
 
int SCIPprobGetNConss (SCIP_PROB *prob)
 
SCIP_Real SCIPprobGetObjoffset (SCIP_PROB *prob)
 
SCIP_Real SCIPprobGetObjscale (SCIP_PROB *prob)
 
SCIP_Bool SCIPprobIsConsCompressionEnabled (SCIP_PROB *prob)
 
void SCIPprobEnableConsCompression (SCIP_PROB *prob)
 

Macro Definition Documentation

◆ OBJSCALE_MAXDNOM

#define OBJSCALE_MAXDNOM   1000000LL

maximal denominator in objective integral scaling

Definition at line 58 of file prob.c.

Referenced by SCIPprobScaleObj().

◆ OBJSCALE_MAXSCALE

#define OBJSCALE_MAXSCALE   1000000.0

maximal scalar to reach objective integrality

Definition at line 59 of file prob.c.

Referenced by SCIPprobScaleObj().

◆ OBJSCALE_MAXFINALSCALE

#define OBJSCALE_MAXFINALSCALE   1000.0

maximal final value to apply as scaling

Definition at line 60 of file prob.c.

Referenced by SCIPprobScaleObj().

Function Documentation

◆ probEnsureVarsMem()

static SCIP_RETCODE probEnsureVarsMem ( SCIP_PROB prob,
SCIP_SET set,
int  num 
)
static

resizes vars array to be able to store at least num entries

Parameters
probproblem data
setglobal SCIP settings
numminimal number of slots in array

Definition at line 70 of file prob.c.

References BMSreallocMemoryArray, NULL, SCIP_ALLOC, SCIP_OKAY, SCIPsetCalcMemGrowSize(), SCIP_Prob::vars, and SCIP_Prob::varssize.

Referenced by SCIPprobAddVar(), and SCIPprobTransform().

◆ probEnsureFixedvarsMem()

static SCIP_RETCODE probEnsureFixedvarsMem ( SCIP_PROB prob,
SCIP_SET set,
int  num 
)
static

resizes fixedvars array to be able to store at least num entries

Parameters
probproblem data
setglobal SCIP settings
numminimal number of slots in array

Definition at line 94 of file prob.c.

References BMSreallocMemoryArray, SCIP_Prob::fixedvars, SCIP_Prob::fixedvarssize, NULL, SCIP_ALLOC, SCIP_OKAY, and SCIPsetCalcMemGrowSize().

Referenced by SCIPprobVarChangedStatus().

◆ probEnsureDeletedvarsMem()

static SCIP_RETCODE probEnsureDeletedvarsMem ( SCIP_PROB prob,
SCIP_SET set,
int  num 
)
static

resizes deletedvars array to be able to store at least num entries

Parameters
probproblem data
setglobal SCIP settings
numminimal number of slots in array

Definition at line 118 of file prob.c.

References BMSreallocMemoryArray, SCIP_Prob::deletedvars, SCIP_Prob::deletedvarssize, NULL, SCIP_ALLOC, SCIP_OKAY, and SCIPsetCalcMemGrowSize().

Referenced by SCIPprobDelVar().

◆ probEnsureConssMem()

static SCIP_RETCODE probEnsureConssMem ( SCIP_PROB prob,
SCIP_SET set,
int  num 
)
static

resizes conss array to be able to store at least num entries

Parameters
probproblem data
setglobal SCIP settings
numminimal number of slots in array

Definition at line 142 of file prob.c.

References BMSreallocMemoryArray, SCIP_Prob::conss, SCIP_Prob::consssize, NULL, SCIP_Prob::origcheckconss, SCIP_ALLOC, SCIP_OKAY, and SCIPsetCalcMemGrowSize().

Referenced by SCIPprobAddCons().

◆ consHasName()

static SCIP_Bool consHasName ( SCIP_CONS cons)
static

returns whether the constraint has a name

Parameters
consconstraint

Definition at line 171 of file prob.c.

References NULL, and SCIPconsGetName().

Referenced by SCIPprobAddConsName(), and SCIPprobRemoveConsName().

◆ varHasName()

static SCIP_Bool varHasName ( SCIP_VAR var)
static

returns whether the variable has a name

Parameters
varvariable

Definition at line 184 of file prob.c.

References NULL, and SCIPvarGetName().

Referenced by SCIPprobAddVarName(), and SCIPprobRemoveVarName().

◆ SCIPprobCopy()

SCIP_RETCODE SCIPprobCopy ( SCIP_PROB **  prob,
BMS_BLKMEM blkmem,
SCIP_SET set,
const char *  name,
SCIP sourcescip,
SCIP_PROB sourceprob,
SCIP_HASHMAP varmap,
SCIP_HASHMAP consmap,
SCIP_Bool  original,
SCIP_Bool  global 
)

creates problem data structure by copying the source problem

If the problem type requires the use of variable pricers, these pricers should be activated with calls to SCIPactivatePricer(). These pricers are automatically deactivated, when the problem is freed.

Parameters
probpointer to problem data structure
blkmemblock memory
setglobal SCIP settings
nameproblem name
sourcescipsource SCIP data structure
sourceprobsource problem structure
varmapa hashmap to store the mapping of source variables corresponding target variables
consmapa hashmap to store the mapping of source constraints to the corresponding target constraints
originalcopy original or transformed problem?
globalcreate a global or a local copy?

Definition at line 206 of file prob.c.

References FALSE, NULL, SCIP_Prob::probdata, SCIP_CALL, SCIP_DIDNOTRUN, SCIP_INVALIDRESULT, SCIP_OKAY, SCIP_SUCCESS, SCIPerrorMessage, and SCIPprobCreate().

Referenced by copyProb().

◆ SCIPprobCreate()

SCIP_RETCODE SCIPprobCreate ( SCIP_PROB **  prob,
BMS_BLKMEM blkmem,
SCIP_SET set,
const char *  name,
SCIP_DECL_PROBDELORIG((*probdelorig))  ,
SCIP_DECL_PROBTRANS((*probtrans))  ,
SCIP_DECL_PROBDELTRANS((*probdeltrans))  ,
SCIP_DECL_PROBINITSOL((*probinitsol))  ,
SCIP_DECL_PROBEXITSOL((*probexitsol))  ,
SCIP_DECL_PROBCOPY((*probcopy))  ,
SCIP_PROBDATA probdata,
SCIP_Bool  transformed 
)

creates problem data structure If the problem type requires the use of variable pricers, these pricers should be activated with calls to SCIPactivatePricer(). These pricers are automatically deactivated, when the problem is freed.

Parameters
probpointer to problem data structure
blkmemblock memory
setglobal SCIP settings
nameproblem name
probdatauser problem data set by the reader
transformedis this the transformed problem?

Definition at line 270 of file prob.c.

References BMSallocMemory, BMSduplicateMemoryArray, FALSE, NULL, SCIP_ALLOC, SCIP_CALL, SCIP_HASHSIZE_NAMES, SCIP_HASHSIZE_NAMES_SMALL, SCIP_INVALID, SCIP_OBJSENSE_MINIMIZE, SCIP_OKAY, and SCIPhashtableCreate().

Referenced by SCIPcreateProb(), SCIPprobCopy(), and SCIPprobTransform().

◆ SCIPprobSetDelorig()

void SCIPprobSetDelorig ( SCIP_PROB prob,
SCIP_DECL_PROBDELORIG((*probdelorig))   
)

sets callback to free user data of original problem

Parameters
probproblem

Definition at line 351 of file prob.c.

References NULL.

Referenced by SCIPsetProbDelorig().

◆ SCIPprobSetTrans()

void SCIPprobSetTrans ( SCIP_PROB prob,
SCIP_DECL_PROBTRANS((*probtrans))   
)

sets callback to create user data of transformed problem by transforming original user data

Parameters
probproblem

Definition at line 362 of file prob.c.

References NULL.

Referenced by SCIPsetProbTrans().

◆ SCIPprobSetDeltrans()

void SCIPprobSetDeltrans ( SCIP_PROB prob,
SCIP_DECL_PROBDELTRANS((*probdeltrans))   
)

sets callback to free user data of transformed problem

Parameters
probproblem

Definition at line 373 of file prob.c.

References NULL.

Referenced by SCIPsetProbDeltrans().

◆ SCIPprobSetInitsol()

void SCIPprobSetInitsol ( SCIP_PROB prob,
SCIP_DECL_PROBINITSOL((*probinitsol))   
)

sets solving process initialization callback of transformed data

Parameters
probproblem

Definition at line 384 of file prob.c.

References NULL.

Referenced by SCIPsetProbInitsol().

◆ SCIPprobSetExitsol()

void SCIPprobSetExitsol ( SCIP_PROB prob,
SCIP_DECL_PROBEXITSOL((*probexitsol))   
)

sets solving process deinitialization callback of transformed data

Parameters
probproblem

Definition at line 395 of file prob.c.

References NULL.

Referenced by SCIPsetProbExitsol().

◆ SCIPprobSetCopy()

void SCIPprobSetCopy ( SCIP_PROB prob,
SCIP_DECL_PROBCOPY((*probcopy))   
)

sets callback to copy user data to copy it to a subscip, or NULL

Parameters
probproblem

Definition at line 406 of file prob.c.

References NULL.

Referenced by SCIPsetProbCopy().

◆ SCIPprobFree()

SCIP_RETCODE SCIPprobFree ( SCIP_PROB **  prob,
SCIP_MESSAGEHDLR messagehdlr,
BMS_BLKMEM blkmem,
SCIP_SET set,
SCIP_STAT stat,
SCIP_EVENTQUEUE eventqueue,
SCIP_LP lp 
)

frees problem data structure

Parameters
probpointer to problem data structure
messagehdlrmessage handler
blkmemblock memory buffer
setglobal SCIP settings
statdynamic problem statistics
eventqueueevent queue
lpcurrent LP data (or NULL, if it's the original problem)

Definition at line 417 of file prob.c.

References BMSfreeMemory, BMSfreeMemoryArray, BMSfreeMemoryArrayNull, FALSE, h, NULL, SCIP_Bool, SCIP_CALL, SCIP_OKAY, SCIPconshdlrNeedsCons(), SCIPconshdlrUnlockVars(), SCIPhashtableFree(), SCIPmessageFPrintWarning(), SCIPprobDelCons(), SCIPprobGetName(), SCIPvarGetName(), SCIPvarGetNUses(), SCIPvarGetProbindex(), SCIPvarRelease(), SCIPvarRemove(), and TRUE.

Referenced by freeTransform(), freeTransforming(), and SCIPfreeProb().

◆ SCIPprobTransform()

SCIP_RETCODE SCIPprobTransform ( SCIP_PROB source,
BMS_BLKMEM blkmem,
SCIP_SET set,
SCIP_STAT stat,
SCIP_PRIMAL primal,
SCIP_TREE tree,
SCIP_REOPT reopt,
SCIP_LP lp,
SCIP_BRANCHCAND branchcand,
SCIP_EVENTFILTER eventfilter,
SCIP_EVENTQUEUE eventqueue,
SCIP_CONFLICTSTORE conflictstore,
SCIP_PROB **  target 
)

transform problem data into normalized form

Parameters
sourceproblem to transform
blkmemblock memory buffer
setglobal SCIP settings
statproblem statistics
primalprimal data
treebranch and bound tree
reoptreoptimization data structure
lpcurrent LP data
branchcandbranching candidate storage
eventfilterevent filter for global (not variable dependent) events
eventqueueevent queue
conflictstoreconflict store
targetpointer to target problem data structure

Definition at line 536 of file prob.c.

References SCIP_Prob::conss, SCIP_Prob::dualbound, h, SCIP_Prob::name, SCIP_Prob::nlpenabled, NULL, SCIP_Prob::nvars, SCIP_Prob::objisintegral, SCIP_Prob::objlim, SCIP_Prob::objsense, SCIP_Prob::permuted, SCIP_Prob::probdata, probEnsureVarsMem(), SCIP_CALL, SCIP_INVALID, SCIP_MAXSTRLEN, SCIP_OKAY, SCIPconflictstoreTransform(), SCIPconshdlrLockVars(), SCIPconshdlrNeedsCons(), SCIPconsRelease(), SCIPconsTransform(), SCIPprobAddCons(), SCIPprobAddVar(), SCIPprobCheckObjIntegral(), SCIPprobCreate(), SCIPprobGetNObjVars(), SCIPprobSetDualbound(), SCIPprobSetObjlim(), SCIPprobSetObjsense(), SCIPsetDebugMsg, SCIPsetIsIntegral(), SCIPsnprintf(), SCIPvarRelease(), SCIPvarTransform(), TRUE, and SCIP_Prob::vars.

Referenced by SCIPtransformProb().

◆ SCIPprobResetBounds()

SCIP_RETCODE SCIPprobResetBounds ( SCIP_PROB prob,
BMS_BLKMEM blkmem,
SCIP_SET set,
SCIP_STAT stat 
)

resets the global and local bounds of original variables in original problem to their original values

Parameters
proboriginal problem data
blkmemblock memory
setglobal SCIP settings
statproblem statistics

Definition at line 637 of file prob.c.

References SCIP_Prob::nfixedvars, NULL, SCIP_Prob::nvars, SCIP_CALL, SCIP_OKAY, SCIPvarResetBounds(), and SCIP_Prob::vars.

Referenced by freeTransform().

◆ SCIPprobResortVars()

void SCIPprobResortVars ( SCIP_PROB prob)

(Re)Sort the variables, which appear in the four categories (binary, integer, implicit, continuous) after presolve with respect to their original index (within their categories). Adjust the problem index afterwards which is supposed to reflect the position in the variable array. This additional (re)sorting is supposed to get more robust against the order presolving fixed variables. (We also reobtain a possible block structure induced by the user model)

Parameters
probproblem data

Definition at line 663 of file prob.c.

References SCIP_Prob::nbinvars, SCIP_Prob::ncontvars, SCIP_Prob::nimplvars, SCIP_Prob::nintvars, NULL, SCIP_Prob::nvars, SCIPdebugMessage, SCIPsortPtr(), and SCIP_Prob::vars.

Referenced by presolve().

◆ SCIPprobSortConssCheck()

SCIP_RETCODE SCIPprobSortConssCheck ( SCIP_PROB prob)

possibly create and sort the constraints according to check priorties

Parameters
probproblem data

Definition at line 715 of file prob.c.

References BMSduplicateMemoryArray, SCIP_Prob::conss, SCIP_Prob::consschecksorted, SCIP_Prob::consssize, SCIP_Prob::nconss, NULL, SCIP_Prob::origcheckconss, SCIP_ALLOC, SCIP_OKAY, SCIPsortPtr(), SCIP_Prob::transformed, and TRUE.

Referenced by SCIPsolCheckOrig().

◆ SCIPprobSetData()

void SCIPprobSetData ( SCIP_PROB prob,
SCIP_PROBDATA probdata 
)

sets user problem data

Parameters
probproblem
probdatauser problem data to use

Definition at line 745 of file prob.c.

References NULL, and SCIP_Prob::probdata.

Referenced by SCIPsetProbData().

◆ probInsertVar()

◆ probRemoveVar()

static SCIP_RETCODE probRemoveVar ( SCIP_PROB prob,
BMS_BLKMEM blkmem,
SCIP_CLIQUETABLE cliquetable,
SCIP_SET set,
SCIP_VAR var 
)
static

◆ SCIPprobAddVarName()

SCIP_RETCODE SCIPprobAddVarName ( SCIP_PROB prob,
SCIP_VAR var 
)

adds variable's name to the namespace

Parameters
probproblem data
varvariable

Definition at line 939 of file prob.c.

References NULL, SCIP_CALL, SCIP_OKAY, SCIPhashtableInsert(), SCIPvarGetProbindex(), varHasName(), and SCIP_Prob::varnames.

Referenced by SCIPchgVarName(), and SCIPprobAddVar().

◆ SCIPprobRemoveVarName()

SCIP_RETCODE SCIPprobRemoveVarName ( SCIP_PROB prob,
SCIP_VAR var 
)

removes variable's name from the namespace

Parameters
probproblem data
varvariable

Definition at line 955 of file prob.c.

References NULL, SCIP_CALL, SCIP_OKAY, SCIPhashtableExists(), SCIPhashtableRemove(), varHasName(), and SCIP_Prob::varnames.

Referenced by SCIPchgVarName(), and SCIPprobPerformVarDeletions().

◆ SCIPprobAddVar()

SCIP_RETCODE SCIPprobAddVar ( SCIP_PROB prob,
BMS_BLKMEM blkmem,
SCIP_SET set,
SCIP_LP lp,
SCIP_BRANCHCAND branchcand,
SCIP_EVENTFILTER eventfilter,
SCIP_EVENTQUEUE eventqueue,
SCIP_VAR var 
)

◆ SCIPprobDelVar()

SCIP_RETCODE SCIPprobDelVar ( SCIP_PROB prob,
BMS_BLKMEM blkmem,
SCIP_SET set,
SCIP_EVENTQUEUE eventqueue,
SCIP_VAR var,
SCIP_Bool deleted 
)

marks variable to be removed from the problem; however, the variable is NOT removed from the constraints

Parameters
probproblem data
blkmemblock memory
setglobal SCIP settings
eventqueueevent queue
varproblem variable
deletedpointer to store whether marking variable to be deleted was successful

Definition at line 1043 of file prob.c.

References SCIP_Prob::deletedvars, FALSE, SCIP_Prob::nbinvars, SCIP_Prob::ncontvars, SCIP_Prob::ndeletedvars, SCIP_Prob::nimplvars, SCIP_Prob::nintvars, NULL, SCIP_Prob::nvars, probEnsureDeletedvarsMem(), SCIP_CALL, SCIP_OKAY, SCIP_VARSTATUS_COLUMN, SCIP_VARSTATUS_LOOSE, SCIP_VARSTATUS_ORIGINAL, SCIPeventCreateVarDeleted(), SCIPeventqueueAdd(), SCIPsetDebugMsg, SCIPvarGetName(), SCIPvarGetNegatedVar(), SCIPvarGetProbindex(), SCIPvarGetStatus(), SCIPvarIsTransformedOrigvar(), SCIPvarMarkDeleted(), SCIP_Prob::transformed, and TRUE.

Referenced by focusnodeCleanupVars(), SCIPdelVar(), and SCIPprobExitSolve().

◆ SCIPprobPerformVarDeletions()

SCIP_RETCODE SCIPprobPerformVarDeletions ( SCIP_PROB prob,
BMS_BLKMEM blkmem,
SCIP_SET set,
SCIP_STAT stat,
SCIP_EVENTQUEUE eventqueue,
SCIP_CLIQUETABLE cliquetable,
SCIP_LP lp,
SCIP_BRANCHCAND branchcand 
)

actually removes the deleted variables from the problem and releases them

Parameters
probproblem data
blkmemblock memory
setglobal SCIP settings
statdynamic problem statistics
eventqueueevent queue
cliquetableclique table data structure
lpcurrent LP data (may be NULL)
branchcandbranching candidate storage

Definition at line 1104 of file prob.c.

References SCIP_Prob::deletedvars, SCIP_Prob::ndeletedvars, NULL, probRemoveVar(), SCIP_CALL, SCIP_OKAY, SCIP_STAGE_SOLVING, SCIP_VARSTATUS_COLUMN, SCIP_VARSTATUS_ORIGINAL, SCIPbranchcandRemoveVar(), SCIPconshdlrDelVars(), SCIPlpUpdateDelVar(), SCIPprobRemoveVarName(), SCIPprobUpdateNObjVars(), SCIPsetDebugMsg, SCIPsetGetStage(), SCIPvarGetName(), SCIPvarGetObj(), SCIPvarGetProbindex(), SCIPvarGetStatus(), SCIPvarLoose(), SCIPvarRelease(), and SCIP_Prob::transformed.

Referenced by exitPresolve(), focusnodeCleanupVars(), initPresolve(), presolveRound(), and SCIPdelVar().

◆ SCIPprobChgVarType()

SCIP_RETCODE SCIPprobChgVarType ( SCIP_PROB prob,
BMS_BLKMEM blkmem,
SCIP_SET set,
SCIP_PRIMAL primal,
SCIP_LP lp,
SCIP_BRANCHCAND branchcand,
SCIP_EVENTQUEUE eventqueue,
SCIP_CLIQUETABLE cliquetable,
SCIP_VAR var,
SCIP_VARTYPE  vartype 
)

changes the type of a variable in the problem

Parameters
probproblem data
blkmemblock memory
setglobal SCIP settings
primalprimal data
lpcurrent LP data
branchcandbranching candidate storage
eventqueueevent queue
cliquetableclique table data structure
varvariable to add
vartypenew type of variable

Definition at line 1175 of file prob.c.

References NULL, probInsertVar(), probRemoveVar(), SCIP_CALL, SCIP_OKAY, SCIP_VARSTATUS_COLUMN, SCIP_VARSTATUS_LOOSE, SCIP_VARSTATUS_ORIGINAL, SCIPbranchcandRemoveVar(), SCIPbranchcandUpdateVar(), SCIPvarChgType(), SCIPvarGetProbindex(), SCIPvarGetStatus(), and SCIPvarGetType().

Referenced by SCIPchgVarType().

◆ SCIPprobVarChangedStatus()

SCIP_RETCODE SCIPprobVarChangedStatus ( SCIP_PROB prob,
BMS_BLKMEM blkmem,
SCIP_SET set,
SCIP_BRANCHCAND branchcand,
SCIP_CLIQUETABLE cliquetable,
SCIP_VAR var 
)

informs problem, that the given loose problem variable changed its status

Parameters
probproblem data
blkmemblock memory
setglobal SCIP settings
branchcandbranching candidate storage
cliquetableclique table data structure
varproblem variable

Definition at line 1224 of file prob.c.

References SCIP_Prob::fixedvars, SCIP_Prob::ncolvars, SCIP_Prob::nfixedvars, NULL, SCIP_Prob::nvars, probEnsureFixedvarsMem(), probRemoveVar(), SCIP_CALL, SCIP_INVALIDDATA, SCIP_OKAY, SCIP_VARSTATUS_AGGREGATED, SCIP_VARSTATUS_COLUMN, SCIP_VARSTATUS_FIXED, SCIP_VARSTATUS_LOOSE, SCIP_VARSTATUS_MULTAGGR, SCIP_VARSTATUS_NEGATED, SCIP_VARSTATUS_ORIGINAL, SCIPbranchcandUpdateVar(), SCIPerrorMessage, SCIPvarGetProbindex(), and SCIPvarGetStatus().

Referenced by SCIPvarAggregate(), SCIPvarColumn(), SCIPvarFix(), SCIPvarLoose(), and SCIPvarMultiaggregate().

◆ SCIPprobAddConsName()

SCIP_RETCODE SCIPprobAddConsName ( SCIP_PROB prob,
SCIP_CONS cons 
)

adds constraint's name to the namespace

Parameters
probproblem data
consconstraint

Definition at line 1282 of file prob.c.

References consHasName(), SCIP_Prob::consnames, NULL, SCIP_CALL, SCIP_OKAY, and SCIPhashtableInsert().

Referenced by SCIPchgConsName(), and SCIPprobAddCons().

◆ SCIPprobRemoveConsName()

SCIP_RETCODE SCIPprobRemoveConsName ( SCIP_PROB prob,
SCIP_CONS cons 
)

remove constraint's name from the namespace

Parameters
probproblem data
consconstraint

Definition at line 1297 of file prob.c.

References consHasName(), SCIP_Prob::consnames, SCIP_Cons::name, NULL, SCIP_CALL, SCIP_OKAY, SCIPhashtableRemove(), and SCIPhashtableRetrieve().

Referenced by SCIPchgConsName(), and SCIPprobDelCons().

◆ SCIPprobAddCons()

◆ SCIPprobDelCons()

SCIP_RETCODE SCIPprobDelCons ( SCIP_PROB prob,
BMS_BLKMEM blkmem,
SCIP_SET set,
SCIP_STAT stat,
SCIP_CONS cons 
)

releases and removes constraint from the problem; if the user has not captured the constraint for his own use, the constraint may be invalid after the call

Parameters
probproblem data
blkmemblock memory
setglobal SCIP settings
statdynamic problem statistics
consconstraint to remove

Definition at line 1390 of file prob.c.

References SCIP_Cons::active, SCIP_Cons::addarraypos, SCIP_Cons::addconssetchg, BMSfreeMemoryArray, SCIP_Prob::conss, SCIP_Prob::consschecksorted, SCIP_Cons::enabled, FALSE, SCIP_Prob::nconss, NULL, SCIP_Prob::origcheckconss, SCIP_CALL, SCIP_LOCKTYPE_MODEL, SCIP_OKAY, SCIPconsAddLocks(), SCIPconsDeactivate(), SCIPconsIsChecked(), SCIPconsRelease(), SCIPprobRemoveConsName(), SCIP_Prob::transformed, and SCIP_Cons::updatedeactivate.

Referenced by SCIPconsDelete(), and SCIPprobFree().

◆ SCIPprobMarkNConss()

void SCIPprobMarkNConss ( SCIP_PROB prob)

remembers the current number of constraints in the problem's internal data structure

  • resets maximum number of constraints to current number of constraints
  • remembers current number of constraints as starting number of constraints
Parameters
probproblem data

Definition at line 1455 of file prob.c.

References SCIP_Prob::maxnconss, SCIP_Prob::nconss, NULL, SCIP_Prob::nvars, SCIP_Prob::startnconss, and SCIP_Prob::startnvars.

Referenced by initSolve(), presolve(), and SCIPtransformProb().

◆ SCIPprobSetObjsense()

void SCIPprobSetObjsense ( SCIP_PROB prob,
SCIP_OBJSENSE  objsense 
)

sets objective sense: minimization or maximization

Parameters
probproblem data
objsensenew objective sense

Definition at line 1468 of file prob.c.

References NULL, SCIP_Prob::objsense, SCIP_OBJSENSE_MAXIMIZE, and SCIP_OBJSENSE_MINIMIZE.

Referenced by SCIPprobTransform(), and SCIPsetObjsense().

◆ SCIPprobAddObjoffset()

void SCIPprobAddObjoffset ( SCIP_PROB prob,
SCIP_Real  addval 
)

adds value to objective offset

Parameters
probproblem data
addvalvalue to add to objective offset

Definition at line 1481 of file prob.c.

References NULL, SCIP_Prob::objoffset, SCIPdebugMessage, and SCIP_Prob::transformed.

Referenced by SCIPaddObjoffset(), and SCIPvarAddObj().

◆ SCIPprobSetDualbound()

void SCIPprobSetDualbound ( SCIP_PROB prob,
SCIP_Real  dualbound 
)

sets the dual bound on objective function

Parameters
probproblem data
dualboundexternal dual bound

Definition at line 1494 of file prob.c.

References SCIP_Prob::dualbound, and NULL.

Referenced by SCIPcopyConcurrentSolvingStats(), SCIPprobTransform(), and SCIPprobUpdateDualbound().

◆ SCIPprobSetObjlim()

void SCIPprobSetObjlim ( SCIP_PROB prob,
SCIP_Real  objlim 
)

sets limit on objective function, such that only solutions better than this limit are accepted

Parameters
probproblem data
objlimexternal objective limit

Definition at line 1505 of file prob.c.

References NULL, and SCIP_Prob::objlim.

Referenced by SCIPprimalSetCutoffbound(), SCIPprobTransform(), and SCIPsetObjlimit().

◆ SCIPprobSetObjIntegral()

void SCIPprobSetObjIntegral ( SCIP_PROB prob)

informs the problem, that its objective value is always integral in every feasible solution

Parameters
probproblem data

Definition at line 1516 of file prob.c.

References NULL, SCIP_Prob::objisintegral, and TRUE.

Referenced by SCIPsetObjIntegral().

◆ SCIPprobCheckObjIntegral()

SCIP_RETCODE SCIPprobCheckObjIntegral ( SCIP_PROB transprob,
SCIP_PROB origprob,
BMS_BLKMEM blkmem,
SCIP_SET set,
SCIP_STAT stat,
SCIP_PRIMAL primal,
SCIP_TREE tree,
SCIP_REOPT reopt,
SCIP_LP lp,
SCIP_EVENTFILTER eventfilter,
SCIP_EVENTQUEUE eventqueue 
)

sets integral objective value flag, if all variables with non-zero objective values are integral and have integral objective value and also updates the cutoff bound if primal solution is already known

Parameters
transprobtranformed problem data
origproboriginal problem data
blkmemblock memory
setglobal SCIP settings
statproblem statistics data
primalprimal data
treebranch and bound tree
reoptreoptimization data structure
lpcurrent LP data
eventfilterevent filter for global (not variable dependent) events
eventqueueevent queue

Definition at line 1528 of file prob.c.

References NULL, SCIP_Prob::nvars, SCIP_Prob::objisintegral, SCIP_Prob::objoffset, SCIP_CALL, SCIP_OKAY, SCIP_Real, SCIP_VARTYPE_CONTINUOUS, SCIPprimalUpdateObjoffset(), SCIPsetIsIntegral(), SCIPsetIsZero(), SCIPvarGetObj(), SCIPvarGetType(), TRUE, and SCIP_Prob::vars.

Referenced by exitPresolve(), prepareReoptimization(), SCIPprobTransform(), and SCIPtransformProb().

◆ SCIPprobUpdateNObjVars()

void SCIPprobUpdateNObjVars ( SCIP_PROB prob,
SCIP_SET set,
SCIP_Real  oldobj,
SCIP_Real  newobj 
)

update the number of variables with non-zero objective coefficient

Parameters
probproblem data
setglobal SCIP settings
oldobjold objective value for variable
newobjnew objective value for variable

Definition at line 1592 of file prob.c.

References SCIP_Prob::nobjvars, SCIPsetIsZero(), and SCIP_Prob::transformed.

Referenced by SCIPprobAddVar(), SCIPprobPerformVarDeletions(), SCIPvarAddObj(), and SCIPvarChgObj().

◆ SCIPprobUpdateDualbound()

void SCIPprobUpdateDualbound ( SCIP_PROB prob,
SCIP_Real  newbound 
)

update the dual bound if its better as the current one

Parameters
probproblem data
newboundnew dual bound for the node (if it's tighter than the old one)

Definition at line 1609 of file prob.c.

References SCIP_Prob::dualbound, MAX, MIN, SCIP_Prob::objsense, SCIP_INVALID, SCIP_OBJSENSE_MAXIMIZE, SCIP_OBJSENSE_MINIMIZE, SCIPABORT, SCIPerrorMessage, and SCIPprobSetDualbound().

Referenced by freeSolve(), SCIPupdateLocalDualbound(), and SCIPupdateLocalLowerbound().

◆ SCIPprobInvalidateDualbound()

void SCIPprobInvalidateDualbound ( SCIP_PROB prob)

invalidates the dual bound

Parameters
probproblem data

Definition at line 1636 of file prob.c.

References SCIP_Prob::dualbound, NULL, and SCIP_INVALID.

Referenced by freeReoptSolve().

◆ SCIPprobScaleObj()

SCIP_RETCODE SCIPprobScaleObj ( SCIP_PROB transprob,
SCIP_PROB origprob,
BMS_BLKMEM blkmem,
SCIP_SET set,
SCIP_STAT stat,
SCIP_PRIMAL primal,
SCIP_TREE tree,
SCIP_REOPT reopt,
SCIP_LP lp,
SCIP_EVENTFILTER eventfilter,
SCIP_EVENTQUEUE eventqueue 
)

if possible, scales objective function such that it is integral with gcd = 1

Parameters
transprobtranformed problem data
origproboriginal problem data
blkmemblock memory
setglobal SCIP settings
statproblem statistics data
primalprimal data
treebranch and bound tree
reoptreoptimization data structure
lpcurrent LP data
eventfilterevent filter for global (not variable dependent) events
eventqueueevent queue

Definition at line 1646 of file prob.c.

References SCIP_Prob::ncontvars, NULL, SCIP_Prob::nvars, SCIP_Prob::objisintegral, SCIP_Prob::objoffset, SCIP_Prob::objscale, OBJSCALE_MAXDNOM, OBJSCALE_MAXFINALSCALE, OBJSCALE_MAXSCALE, REALABS, SCIP_Bool, SCIP_CALL, SCIP_Longint, SCIP_LONGINT_FORMAT, SCIP_LONGINT_MAX, SCIP_OKAY, SCIP_Real, SCIPcalcGreComDiv(), SCIPcalcIntegralScalar(), SCIPprimalUpdateObjoffset(), SCIPsetAllocBufferArray, SCIPsetDebugMsg, SCIPsetEpsilon(), SCIPsetFeasFloor(), SCIPsetFreeBufferArray, SCIPsetIsEQ(), SCIPsetIsFeasIntegral(), SCIPsetIsZero(), SCIPvarChgObj(), SCIPvarGetName(), SCIPvarGetObj(), TRUE, and SCIP_Prob::vars.

Referenced by exitPresolve(), prepareReoptimization(), and SCIPtransformProb().

◆ SCIPprobStoreRootSol()

void SCIPprobStoreRootSol ( SCIP_PROB prob,
SCIP_SET set,
SCIP_STAT stat,
SCIP_LP lp,
SCIP_Bool  roothaslp 
)

remembers the current solution as root solution in the problem variables

Parameters
probproblem data
setglobal SCIP settings
statSCIP statistics
lpcurrent LP data
roothaslpis the root solution from LP?

Definition at line 1778 of file prob.c.

References SCIP_Prob::nbinvars, SCIP_Prob::nimplvars, SCIP_Prob::nintvars, NULL, SCIP_Prob::nvars, SCIPlpGetColumnObjval(), SCIPlpIsRelax(), SCIPlpSetRootLPIsRelax(), SCIPlpStoreRootObjval(), SCIPstatComputeRootLPBestEstimate(), SCIPvarStoreRootSol(), SCIP_Prob::transformed, and SCIP_Prob::vars.

Referenced by solveNode().

◆ SCIPprobUpdateBestRootSol()

◆ SCIPprobExitPresolve()

SCIP_RETCODE SCIPprobExitPresolve ( SCIP_PROB prob,
SCIP_SET set 
)

informs problem, that the presolving process was finished, and updates all internal data structures

Parameters
probproblem data
setglobal SCIP settings

Definition at line 1903 of file prob.c.

References SCIP_OKAY.

Referenced by exitPresolve().

◆ SCIPprobInitSolve()

SCIP_RETCODE SCIPprobInitSolve ( SCIP_PROB prob,
SCIP_SET set 
)

initializes problem for branch and bound process and resets all constraint's ages and histories of current run

Parameters
probproblem data
setglobal SCIP settings

Definition at line 1912 of file prob.c.

References SCIP_Prob::conss, SCIP_Prob::nconss, SCIP_Prob::nobjvars, NULL, SCIP_Prob::nvars, SCIP_Prob::probdata, SCIP_CALL, SCIP_OKAY, SCIPconsResetAge(), SCIPprobGetNObjVars(), SCIPvarInitSolve(), SCIP_Prob::transformed, and SCIP_Prob::vars.

Referenced by initSolve().

◆ SCIPprobExitSolve()

SCIP_RETCODE SCIPprobExitSolve ( SCIP_PROB prob,
BMS_BLKMEM blkmem,
SCIP_SET set,
SCIP_EVENTQUEUE eventqueue,
SCIP_LP lp,
SCIP_Bool  restart 
)

deinitializes problem after branch and bound process, and converts all COLUMN variables back into LOOSE variables

Parameters
probproblem data
blkmemblock memory
setglobal SCIP settings
eventqueueevent queue
lpcurrent LP data
restartwas this exit solve call triggered by a restart?

Definition at line 1947 of file prob.c.

References SCIP_Prob::ncolvars, NULL, SCIP_Prob::nvars, SCIP_Prob::probdata, SCIP_Bool, SCIP_CALL, SCIP_INVALID, SCIP_OKAY, SCIP_VARSTATUS_COLUMN, SCIPprobDelVar(), SCIPsetDebugMsg, SCIPvarGetName(), SCIPvarGetNLocksDown(), SCIPvarGetNLocksUp(), SCIPvarGetNUses(), SCIPvarGetStatus(), SCIPvarIsDeletable(), SCIPvarIsRelaxationOnly(), SCIPvarLoose(), SCIPvarSetBestRootSol(), SCIP_Prob::transformed, and SCIP_Prob::vars.

Referenced by freeReoptSolve(), and freeSolve().

◆ SCIPprobSetName()

SCIP_RETCODE SCIPprobSetName ( SCIP_PROB prob,
const char *  name 
)

sets problem name

Parameters
probproblem data
namename to be set

Definition at line 2022 of file prob.c.

References BMSduplicateMemoryArray, BMSfreeMemoryArray, SCIP_Prob::name, NULL, SCIP_ALLOC, and SCIP_OKAY.

Referenced by SCIPsetProbName().

◆ SCIPprobGetNImplBinVars()

int SCIPprobGetNImplBinVars ( SCIP_PROB prob)

returns the number of implicit binary variables, meaning variable of vartype != SCIP_VARTYPE_BINARY and != SCIP_VARTYPE_CONTINUOUS but with global bounds [0,1]

Note
this number needs to be computed, because it cannot be updated like the other counters for binary and integer variables, each time the variable type changes(, we would need to update this counter each time a global bound changes), even at the end of presolving this cannot be computed, because some variable can change to an implicit binary status
Parameters
probproblem data

Definition at line 2043 of file prob.c.

References SCIP_Prob::nbinvars, SCIP_Prob::nimplvars, SCIP_Prob::nintvars, SCIPvarIsBinary(), and SCIP_Prob::vars.

Referenced by SCIPshrinkDisjunctiveVarSet().

◆ SCIPprobGetNObjVars()

int SCIPprobGetNObjVars ( SCIP_PROB prob,
SCIP_SET set 
)

returns the number of variables with non-zero objective coefficient

Parameters
probproblem data
setglobal SCIP settings

Definition at line 2060 of file prob.c.

References SCIP_Prob::nobjvars, SCIP_Prob::nvars, SCIPsetIsZero(), SCIPvarGetObj(), SCIP_Prob::transformed, and SCIP_Prob::vars.

Referenced by SCIPgetNObjVars(), SCIPprobInitSolve(), SCIPprobPrintStatistics(), SCIPprobTransform(), and SCIPprobUpdateBestRootSol().

◆ SCIPprobGetAbsMinObjCoef()

SCIP_Real SCIPprobGetAbsMinObjCoef ( SCIP_PROB prob,
SCIP_SET set 
)

returns the minimal absolute non-zero objective coefficient

Note
currently, this is only used for statistics and printed after the solving process. if this information is needed during the (pre)solving process this should be implemented more efficiently, e.g., updating the minimal absolute non-zero coefficient every time an objective coefficient has changed.
Parameters
probproblem data
setglobal SCIP settings

Definition at line 2107 of file prob.c.

References SCIP_Prob::nvars, REALABS, SCIP_Real, SCIPsetInfinity(), SCIPsetIsLT(), SCIPsetIsZero(), SCIPvarGetObj(), and SCIP_Prob::vars.

Referenced by SCIPprobPrintStatistics().

◆ SCIPprobGetAbsMaxObjCoef()

SCIP_Real SCIPprobGetAbsMaxObjCoef ( SCIP_PROB prob,
SCIP_SET set 
)

returns the maximal absolute non-zero objective coefficient

Note
currently, this is only used for statistics and printed after the solving process. if this information is needed during the (pre)solving process this should be implemented more efficiently, e.g., updating the maximal absolute non-zero coefficient every time an objective coefficient has changed.
Parameters
probproblem data
setglobal SCIP settings

Definition at line 2134 of file prob.c.

References SCIP_Prob::nvars, REALABS, SCIP_Real, SCIPsetInfinity(), SCIPsetIsGT(), SCIPsetIsZero(), SCIPvarGetObj(), and SCIP_Prob::vars.

Referenced by SCIPprobPrintStatistics().

◆ SCIPprobExternObjval()

◆ SCIPprobInternObjval()

SCIP_Real SCIPprobInternObjval ( SCIP_PROB transprob,
SCIP_PROB origprob,
SCIP_SET set,
SCIP_Real  objval 
)

returns the internal value of the given external objective value

Parameters
transprobtranformed problem data
origproboriginal problem data
setglobal SCIP settings
objvalexternal objective value

Definition at line 2179 of file prob.c.

References NULL, SCIP_Prob::objoffset, SCIP_Prob::objscale, SCIP_Prob::objsense, SCIP_Real, SCIPsetInfinity(), SCIPsetIsInfinity(), and SCIP_Prob::transformed.

Referenced by exitPresolve(), initSolve(), primalAddSol(), SCIPgetFirstLPLowerboundRoot(), SCIPprimalUpdateObjlimit(), SCIPprimalUpdateObjoffset(), SCIPsetObjlimit(), SCIPsolGetObj(), SCIPsolveCIP(), SCIPstatResetCurrentRun(), SCIPtransformObj(), SCIPupdateLocalDualbound(), and SCIPupdateNodeDualbound().

◆ SCIPprobFindVar()

SCIP_VAR* SCIPprobFindVar ( SCIP_PROB prob,
const char *  name 
)

returns variable of the problem with given name

Parameters
probproblem data
namename of variable to find

Definition at line 2201 of file prob.c.

References NULL, SCIPABORT, SCIPerrorMessage, SCIPhashtableRetrieve(), and SCIP_Prob::varnames.

Referenced by SCIPfindVar().

◆ SCIPprobFindCons()

SCIP_CONS* SCIPprobFindCons ( SCIP_PROB prob,
const char *  name 
)

returns constraint of the problem with given name

Parameters
probproblem data
namename of variable to find

Definition at line 2220 of file prob.c.

References SCIP_Prob::consnames, NULL, SCIPABORT, SCIPerrorMessage, and SCIPhashtableRetrieve().

Referenced by SCIPfindCons(), and SCIPfindOrigCons().

◆ SCIPprobPrintPseudoSol()

void SCIPprobPrintPseudoSol ( SCIP_PROB prob,
SCIP_SET set,
SCIP_MESSAGEHDLR messagehdlr 
)

displays current pseudo solution

Parameters
probproblem data
setglobal SCIP settings
messagehdlrmessage handler

Definition at line 2239 of file prob.c.

References NULL, SCIP_Prob::nvars, SCIP_Real, SCIPmessagePrintInfo(), SCIPsetIsZero(), SCIPvarGetName(), SCIPvarGetPseudoSol(), and SCIP_Prob::vars.

◆ SCIPprobPrintStatistics()

void SCIPprobPrintStatistics ( SCIP_PROB prob,
SCIP_SET set,
SCIP_MESSAGEHDLR messagehdlr,
FILE *  file 
)

◆ SCIPprobIsPermuted()

SCIP_Bool SCIPprobIsPermuted ( SCIP_PROB prob)

is the problem permuted

Definition at line 2308 of file prob.c.

References NULL, and SCIP_Prob::permuted.

Referenced by SCIPpermuteProb().

◆ SCIPprobMarkPermuted()

void SCIPprobMarkPermuted ( SCIP_PROB prob)

mark the problem as permuted

Definition at line 2318 of file prob.c.

References NULL, SCIP_Prob::permuted, and TRUE.

Referenced by SCIPpermuteProb().

◆ SCIPprobIsTransformed()

SCIP_Bool SCIPprobIsTransformed ( SCIP_PROB prob)

is the problem data transformed

Parameters
probproblem data

Definition at line 2328 of file prob.c.

References NULL, and SCIP_Prob::transformed.

Referenced by applyImplic(), detectImpliedBounds(), SCIPreoptInstallBounds(), SCIPvarAddVlb(), SCIPvarAddVub(), SCIPvarChgObj(), SCIPvarFixBinary(), SCIPvarGetImplRedcost(), and varAddImplic().

◆ SCIPprobIsObjIntegral()

SCIP_Bool SCIPprobIsObjIntegral ( SCIP_PROB prob)

returns whether the objective value is known to be integral in every feasible solution

Parameters
probproblem data

Definition at line 2338 of file prob.c.

References NULL, and SCIP_Prob::objisintegral.

Referenced by primalSetUpperbound(), SCIPconflictAnalyzePseudo(), SCIPconflictstoreAddDualsolcons(), SCIPconflictstoreCleanNewIncumbent(), SCIPgetDualProof(), SCIPisObjIntegral(), and SCIPpresolve().

◆ SCIPprobAllColsInLP()

SCIP_Bool SCIPprobAllColsInLP ( SCIP_PROB prob,
SCIP_SET set,
SCIP_LP lp 
)

returns TRUE iff all columns, i.e. every variable with non-empty column w.r.t. all ever created rows, are present in the LP, and FALSE, if there are additional already existing columns, that may be added to the LP in pricing

Parameters
probproblem data
setglobal SCIP settings
lpcurrent LP data

Definition at line 2350 of file prob.c.

References SCIP_Prob::ncolvars, SCIP_Prob::nvars, and SCIPlpGetNCols().

Referenced by conflictAnalyzeBoundexceedingLP(), conflictAnalyzeInfeasibleLP(), conflictAnalyzeLP(), priceAndCutLoop(), propAndSolve(), SCIPaddRow(), SCIPallColsInLP(), SCIPconflictAnalyzeLP(), SCIPconflictAnalyzeStrongbranch(), SCIPgetVarsStrongbranchesFrac(), SCIPgetVarsStrongbranchesInt(), SCIPgetVarStrongbranchFrac(), SCIPgetVarStrongbranchInt(), SCIPlpSolveAndEval(), SCIPpriceLoop(), SCIPrunBoundHeuristic(), SCIPsolveDiveLP(), SCIPtreeEndProbing(), solveNodeInitialLP(), and solveProbingLP().

◆ SCIPprobGetObjlim()

SCIP_Real SCIPprobGetObjlim ( SCIP_PROB prob,
SCIP_SET set 
)

gets limit on objective function in external space

Parameters
probproblem data
setglobal SCIP settings

Definition at line 2362 of file prob.c.

References NULL, SCIP_Prob::objlim, SCIP_Prob::objsense, SCIP_INVALID, SCIP_Real, and SCIPsetInfinity().

Referenced by primalAddOrigSol(), primalAddSol(), SCIPgetObjlimit(), SCIPprimalSetCutoffbound(), SCIPprimalUpdateObjlimit(), SCIPprimalUpdateObjoffset(), SCIPsetObjlimit(), and SCIPsolveCIP().

◆ SCIPprobGetData()

SCIP_PROBDATA* SCIPprobGetData ( SCIP_PROB prob)

gets user problem data

Parameters
probproblem

Definition at line 2374 of file prob.c.

References NULL, and SCIP_Prob::probdata.

Referenced by SCIPgetProbData().

◆ SCIPprobGetName()

const char* SCIPprobGetName ( SCIP_PROB prob)

gets problem name

Parameters
probproblem data

Definition at line 2384 of file prob.c.

References SCIP_Prob::name, and NULL.

Referenced by detectImpliedBounds(), initSolve(), SCIPgetProbName(), SCIPprobFree(), SCIPshrinkDisjunctiveVarSet(), SCIPtransformProb(), SCIPvarCapture(), and SCIPvarRelease().

◆ SCIPprobGetNVars()

int SCIPprobGetNVars ( SCIP_PROB prob)

◆ SCIPprobGetNBinVars()

int SCIPprobGetNBinVars ( SCIP_PROB prob)

gets number of binary problem variables

Parameters
probproblem data

Definition at line 2402 of file prob.c.

References SCIP_Prob::nbinvars, and NULL.

Referenced by SCIPsolAdjustImplicitSolVals().

◆ SCIPprobGetNIntVars()

int SCIPprobGetNIntVars ( SCIP_PROB prob)

gets number of integer problem variables

Parameters
probproblem data

Definition at line 2411 of file prob.c.

References SCIP_Prob::nintvars, and NULL.

Referenced by SCIPsolAdjustImplicitSolVals().

◆ SCIPprobGetNImplVars()

int SCIPprobGetNImplVars ( SCIP_PROB prob)

gets number of implicit integer problem variables

Parameters
probproblem data

Definition at line 2420 of file prob.c.

References SCIP_Prob::nimplvars, and NULL.

Referenced by SCIPsolAdjustImplicitSolVals().

◆ SCIPprobGetNContVars()

int SCIPprobGetNContVars ( SCIP_PROB prob)

gets number of continuous problem variables

Parameters
probproblem data

Definition at line 2429 of file prob.c.

References SCIP_Prob::ncontvars, and NULL.

Referenced by SCIPvarGetImplRedcost().

◆ SCIPprobGetVars()

◆ SCIPprobGetNConss()

int SCIPprobGetNConss ( SCIP_PROB prob)

gets number of problem constraints

Parameters
probproblem data

Definition at line 2447 of file prob.c.

References SCIP_Prob::nconss, and NULL.

Referenced by initConflictstore().

◆ SCIPprobGetObjoffset()

SCIP_Real SCIPprobGetObjoffset ( SCIP_PROB prob)

gets the objective offset

Parameters
probproblem data

Definition at line 2456 of file prob.c.

References NULL, and SCIP_Prob::objoffset.

Referenced by SCIPsolRecomputeObj().

◆ SCIPprobGetObjscale()

SCIP_Real SCIPprobGetObjscale ( SCIP_PROB prob)

gets the objective scalar

Parameters
probproblem data

Definition at line 2465 of file prob.c.

References NULL, and SCIP_Prob::objscale.

◆ SCIPprobIsConsCompressionEnabled()

SCIP_Bool SCIPprobIsConsCompressionEnabled ( SCIP_PROB prob)

is constraint compression enabled for this problem?

Parameters
probproblem data

Definition at line 2474 of file prob.c.

References SCIP_Prob::conscompression, and NULL.

Referenced by SCIPisConsCompressionEnabled().

◆ SCIPprobEnableConsCompression()

void SCIPprobEnableConsCompression ( SCIP_PROB prob)

enable problem compression, i.e., constraints can reduce memory size by removing fixed variables during creation

Parameters
probproblem data

Definition at line 2484 of file prob.c.

References SCIP_Prob::conscompression, NULL, and TRUE.

Referenced by SCIPenableConsCompression().