All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
pub_var.h
Go to the documentation of this file.
22 /*---+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+----0----+----1----+----2*/
74 /** compares the index of two variables, only active or negated variables are allowed, if a variable
75 * is negated then the index of the corresponding active variable is taken, returns -1 if first is
85 /** comparison method for sorting active and negated variables by non-decreasing index, active and negated
91 /** compares the index of two variables, returns -1 if first is smaller than, and +1 if first is greater than second
136 /** gets corresponding active, fixed, or multi-aggregated problem variables of binary variables and
146 /** gets corresponding active, fixed, or multi-aggregated problem variable of a binary variable and
155 /** transforms given variable, boundtype and bound to the corresponding active, fixed, or multi-aggregated variable
165 /** transforms given variable and domain hole to the corresponding active, fixed, or multi-aggregated variable
175 /** retransforms given variable, scalar and constant to the corresponding original variable, scalar
176 * and constant, if possible; if the retransformation is impossible, NULL is returned as variable
185 /** returns whether the given variable is the direct counterpart of an original problem variable */
191 /** returns the number of times, a bound of the variable was changed in given direction due to branching */
198 /** returns the number of times, a bound of the variable was changed in given direction due to branching
230 /** returns the number of cutoffs branching on this variable in given direction produced in the current run */
237 /** returns the average depth of bound changes in given direction due to branching on the variable */
244 /** returns the average depth of bound changes in given direction due to branching on the variable
253 /** returns whether there is an implication x == varfixing -> y <= b or y >= b in the implication graph;
254 * implications that are represented as cliques in the clique table are not regarded (use SCIPvarsHaveCommonClique());
260 SCIP_Bool varfixing, /**< FALSE if y should be searched in implications for x == 0, TRUE for x == 1 */
265 /** returns whether there is an implication x == varfixing -> y == implvarfixing in the implication graph;
266 * implications that are represented as cliques in the clique table are not regarded (use SCIPvarsHaveCommonClique());
272 SCIP_Bool varfixing, /**< FALSE if y should be searched in implications for x == 0, TRUE for x == 1 */
280 * if regardimplics is TRUE, both the cliques and the implications of the implication graph are regarded
291 /** gets corresponding objective value of active, fixed, or multi-aggregated problem variable of given variable
353 SCIP_DECL_VARTRANS ((*vartrans)) /**< creates transformed user data by transforming original user data */
436 * method can only be called before the variable is added to the problem by SCIPaddVar() or SCIPaddPricedVar()
509 /** gets number n of aggregation variables of a multi aggregated variable x = a0*y0 + ... + a(n-1)*y(n-1) + c */
515 /** gets vector of aggregation variables y of a multi aggregated variable x = a0*y0 + ... + a(n-1)*y(n-1) + c */
521 /** gets vector of aggregation scalars a of a multi aggregated variable x = a0*y0 + ... + a(n-1)*y(n-1) + c */
527 /** gets aggregation constant c of a multi aggregated variable x = a0*y0 + ... + a(n-1)*y(n-1) + c */
557 /** gets original lower bound of original problem variable (i.e. the bound set in problem creation) */
563 /** gets original upper bound of original problem variable (i.e. the bound set in problem creation) */
635 /** gets type (lower or upper) of best bound of variable with respect to the objective function */
641 /** gets type (lower or upper) of worst bound of variable with respect to the objective function */
659 /** gets the branch factor of the variable; this value can be used in the branching methods to scale the score
660 * values of the variables; higher factor leads to a higher probability that this variable is chosen for branching
667 /** gets the branch priority of the variable; variables with higher priority should always be preferred to variables
687 /** gets array with bounding variables z_i in variable lower bounds x >= b_i*z_i + d_i of given variable x;
688 * the variable bounds are sorted by increasing variable index of the bounding variable z_i (see SCIPvarGetIndex())
695 /** gets array with bounding coefficients b_i in variable lower bounds x >= b_i*z_i + d_i of given variable x */
701 /** gets array with bounding constants d_i in variable lower bounds x >= b_i*z_i + d_i of given variable x */
713 /** gets array with bounding variables z_i in variable upper bounds x <= b_i*z_i + d_i of given variable x;
714 * the variable bounds are sorted by increasing variable index of the bounding variable z_i (see SCIPvarGetIndex())
721 /** gets array with bounding coefficients b_i in variable upper bounds x <= b_i*z_i + d_i of given variable x */
727 /** gets array with bounding constants d_i in variable upper bounds x <= b_i*z_i + d_i of given variable x */
733 /** gets number of implications y <= b or y >= b for x == 0 or x == 1 of given active problem variable x,
742 /** gets number of implications y <= 0 or y >= 1 for x == 0 or x == 1 of given active problem variable x with binary y,
751 /** gets array with implication variables y of implications y <= b or y >= b for x == 0 or x == 1 of given active
753 * the implications are sorted such that implications with binary implied variables precede the ones with non-binary
754 * implied variables, and as a second criteria, the implied variables are sorted by increasing variable index
763 /** gets array with implication types of implications y <= b or y >= b for x == 0 or x == 1 of given active problem
773 /** gets array with implication bounds b of implications y <= b or y >= b for x == 0 or x == 1 of given active problem
782 /** Gets array with unique ids of implications y <= b or y >= b for x == 0 or x == 1 of given active problem variable x,
784 * If an implication is a shortcut, i.e., it was added as part of the transitive closure of another implication,
853 /* In optimized mode, the function calls are overwritten by defines to reduce the number of function calls and
866 || ((var)->varstatus == SCIP_VARSTATUS_NEGATED && (var)->negatedvar->varstatus == SCIP_VARSTATUS_ORIGINAL))
868 && ((var)->varstatus != SCIP_VARSTATUS_NEGATED || (var)->negatedvar->varstatus != SCIP_VARSTATUS_ORIGINAL))
872 ((var)->vartype != SCIP_VARTYPE_CONTINUOUS && MAX((var)->glbdom.lb, (var)->lazylb) >= 0.0 && MIN((var)->glbdom.ub, (var)->lazyub) <= 1.0))
885 #define SCIPvarIsInLP(var) ((var)->varstatus == SCIP_VARSTATUS_COLUMN && SCIPcolIsInLP((var)->data.col))
910 #define SCIPvarGetBestBoundGlobal(var) ((var)->obj >= 0.0 ? (var)->glbdom.lb : (var)->glbdom.ub)
911 #define SCIPvarGetWorstBoundGlobal(var) ((var)->obj >= 0.0 ? (var)->glbdom.ub : (var)->glbdom.lb)
916 #define SCIPvarGetWorstBoundLocal(var) ((var)->obj >= 0.0 ? (var)->locdom.ub : (var)->locdom.lb)
917 #define SCIPvarGetBestBoundType(var) ((var)->obj >= 0.0 ? SCIP_BOUNDTYPE_LOWER : SCIP_BOUNDTYPE_UPPER)
918 #define SCIPvarGetWorstBoundType(var) ((var)->obj >= 0.0 ? SCIP_BOUNDTYPE_UPPER : SCIP_BOUNDTYPE_LOWER)
940 #define SCIPvarGetLPSol(var) ((var)->varstatus == SCIP_VARSTATUS_COLUMN ? SCIPcolGetPrimsol((var)->data.col) : SCIPvarGetLPSol_rec(var))
941 #define SCIPvarGetNLPSol(var) (((var)->varstatus == SCIP_VARSTATUS_COLUMN || ((var)->varstatus == SCIP_VARSTATUS_LOOSE)) ? (var)->nlpsol : SCIPvarGetNLPSol_rec(var))
975 /** returns the solution of the variable in the last root node's relaxation, if the root relaxation is not yet
983 /** returns the best solution (w.r.t. root reduced cost propagation) of the variable in the root node's relaxation, if
991 /** returns the best reduced costs (w.r.t. root reduced cost propagation) of the variable in the root node's relaxation,
992 * if the root relaxation is not yet completely solved, or the variable was no column of the root LP, SCIP_INVALID is
1000 /** returns the best objective value (w.r.t. root reduced cost propagation) of the root LP which belongs the root
1001 * reduced cost which is accessible via SCIPvarGetRootRedcost() or the variable was no column of the root LP,
1009 /** set the given solution as the best root solution w.r.t. root reduced cost propagation in the variables */
1018 /** returns a weighted average solution value of the variable in all feasible primal solutions found so far */
1024 /** returns the bound change information for the last lower bound change on given active problem variable before or
1035 /** returns the bound change information for the last upper bound change on given active problem variable before or
1046 /** returns the bound change information for the last lower or upper bound change on given active problem variable
1058 /** returns lower bound of variable directly before or after the bound change given by the bound change index
1068 /** returns upper bound of variable directly before or after the bound change given by the bound change index
1078 /** returns lower or upper bound of variable directly before or after the bound change given by the bound change index
1089 /** returns whether the binary variable was fixed at the time given by the bound change index */
1097 /** returns the last bound change index, at which the bounds of the given variable were tightened */
1113 * returns FALSE, if the first variable is not fixed, and returns TRUE, if the first variable is fixed, but the
1122 /** returns whether first bound change index belongs to an earlier applied bound change than second one;
1123 * if a bound change index is NULL, the bound change index represents the current time, i.e. the time after the
1132 /** returns whether first bound change index belongs to an earlier applied bound change than second one */
1157 /** returns whether the bound change information belongs to a branching decision or a deduction */
1199 /** returns inference propagator of given bound change information, or NULL if no propagator was responsible */
1223 /** returns whether the bound change has an inference reason (constraint or propagator), that can be resolved */
1229 /** for two bound change informations belonging to the same variable and bound, returns whether the first bound change
1262 /** returns whether the bound change is redundant due to a more global bound that is at least as strong */
1301 /* In optimized mode, the function calls are overwritten by defines to reduce the number of function calls and
1306 ((idx1)->depth < (idx2)->depth || ((idx1)->depth == (idx2)->depth && (idx1)->pos < (idx2)->pos))
1321 #define SCIPbdchginfoGetInferBoundtype(bdchginfo) (SCIP_BOUNDTYPE)((bdchginfo)->inferboundtype)
1325 || ((bdchginfo)->boundchgtype == SCIP_BOUNDCHGTYPE_PROPINFER && (bdchginfo)->inferencedata.reason.prop != NULL))
1326 #define SCIPbdchginfoIsTighter(bdchginfo1,bdchginfo2) ((bdchginfo1)->boundtype == SCIP_BOUNDTYPE_LOWER \
1327 ? (bdchginfo1)->newbound > bdchginfo2->newbound : (bdchginfo1)->newbound < bdchginfo2->newbound)
|