CPXXcheckchgcoeflist and CPXcheckchgcoeflist
Checks data when the list of coefficients in a model changes.
Signature
CPXCHECKLIBAPI
int CPXPUBLIC CPXXcheckchgcoeflist (CPXCENVptr env,
CPXCLPptr lp,
CPXNNZ numcoefs,
const CPXDIM *rowlist,
const CPXDIM *collist,
const double *vallist);
CPXCHECKLIBAPI
int CPXPUBLIC CPXcheckchgcoeflist (CPXCENVptr env,
CPXCLPptr lp,
CPXNNZ numcoefs,
const CPXDIM *rowlist,
const CPXDIM *collist,
const double *vallist);
Description
This routine validates the arguments of the corresponding routine
CPXXchgcoeflist and CPXchgcoeflist.
The source code of this data checking routine
is in the file check.c, provided
as part of the product.
To call this routine, you must compile
and link check.c with your program
as you compile and link with the CPLEX Callable Library.
Arguments
The arguments of this routine are the same as those of
CPXXchgcoeflist and CPXchgcoeflist.
The second argument, lp, is technically
a pointer to a constant LP object
of type CPXCLPptr rather than type CPXLPptr,
because this routine does not modify the problem.
For most user applications, this distinction is unimportant.
| Name | Description |
|---|---|
| env |
A pointer to the CPLEX environment as returned by CPXXopenCPLEX/CPXopenCPLEX.
|
| lp |
A pointer to a CPLEX problem object as returned by CPXXcreateprob/CPXcreateprob.
|
| numcoefs |
The number of coefficients to change, or, equivalently, the length of the arrays rowlist, collist, and vallist.
|
| rowlist |
An array of length numcoefs that with collist and vallist specifies the coefficients to change.
|
| collist |
An array of length numcoefs that with rowlist and vallist specifies the coefficients to change.
|
| vallist |
An array of length numcoefs that with rowlist and collist specifies the coefficients to change. The entries rowlist[k], collist[k], and vallist[k] specify that the matrix coefficient in row rowlist[k] and column collist[k] should be changed to the value vallist[k].
|
Return
The routine returns nonzero if it detects an error in the data; it returns zero if it does not detect any data errors.
Example
status = CPXcheckchgcoeflist (env, lp, numcoefs, rowlist,
collist, vallist);