Initializing help system before first use

XPRBsetincvars

XPRBsetincvars


Purpose
Set the include vars constraint type.
Synopsis
int XPRBsetincvars(XPRBctr ctr, int ivstat);
Arguments
ctr 
Reference to a previously created constraint.
ivstat 
The constraint type, which must be one of:
normal constraint;
include vars special constraint.
Return value
0 if function executed successfully, 1 otherwise.
Example
The following turns the constraint ctr1 into an include vars special constraint.
XPRBprob prob;
XPRBctr ctr1;
   ...
ctr1 = XPRBnewctr(prob, "r1", XPRB_N);
XPRBsetincvars(ctr1, 1);
Further information
1. This function changes the type of a previously defined constraint from ordinary constraint to an include vars special constraint. Include vars constraints are used to force the loading of all variables they contain into the Optimizer (even if they don't appear in any other constraint). Only constraints of type XPRB_N can be changed into include vars constraints; the constraints themselves are not loaded into the Optimizer (as all constraints of type XPRB_N), just the variables they contain are loaded. The coefficients of the variables are also ignored as long as they are non-zero.
2. Constraint properties 'include vars', 'model cut', 'delayed constraint', and 'indicator constraint' are mutually exclusive. When changing from one of these types to another you must first reset the correponding type to 0.
Related topics