XPRSchgbounds
Purpose
Synopsis
int XPRS_CC XPRSchgbounds(XPRSprob prob, int nbounds, const int colind[], const char bndtype[], const double bndval[]);
Arguments
|
prob
|
The current problem.
|
||||||
|
nbounds
|
Number of bounds to change.
|
||||||
|
colind
|
Integer array of size
nbounds containing the indices of the columns on which the bounds will change.
|
||||||
|
bndtype
|
Character array of length
nbounds indicating the type of bound to change:
|
||||||
|
bndval
|
Double array of length
nbounds giving the new bound values.
|
Example
The following changes column
0 of the current problem to have an upper bound of
0,5:
colind[0] = 0; bndtype[0] = 'U'; bndval[0] = 0,5; XPRSchgbounds(prob,1,colind,bndtype,bndval);
Further information
1. A column index may appear twice in the
colind array so it is possible to change both the upper and lower bounds on a variable in one go.
2.
XPRSchgbounds can be used from within callbacks to modify the local node bounds of a branch-and-bound search. In this case, the solver expects column indices to match the presolved problem. This function can be called from within the following callbacks: XPRSaddcbprenode,
XPRSaddcbnodelpsolved,
XPRSaddcboptnode,
XPRSaddcbcutmgr.
3. The double constants
XPRS_PLUSINFINITY and
XPRS_MINUSINFINITY defined in the library header file can be used to represent plus and minus infinity respectively in the bound (
bndval) array.
4. If the upper bound on a binary variable is changed to be greater than 1 or the lower bound is changed to be less than 0 then the variable will become an integer variable.
Related topics
© 2001-2023 Fair Isaac Corporation. All rights reserved. This documentation is the property of Fair Isaac Corporation ("FICO"). Receipt or possession of this documentation does not convey rights to disclose, reproduce, make derivative works, use, or allow others to use it except solely for internal evaluation purposes to determine whether to purchase a license to the software described in this documentation, or as otherwise set forth in a written software license agreement between you and FICO (or a FICO affiliate). Use of this documentation and the software described in it must conform strictly to the foregoing permitted uses, and no other use is permitted.
