Description
The CPXcopystart() routine is used to copy starting-point information. Any one of three different kinds of starting points can be copied, in any combination: a starting basis (cstat, rstat), starting primal values (cprim, rprim), and starting dual values (cdual, rdual).cstat and rstat, both of cprim and rprim, or both of cdual and rdual must be specified. If there is no such pair of pointers (both of which are not NULL), an error is returned; otherwise, any resident starting-point information is freed and the specified new information is copied.CPXcopystart(), the CPLEX routines CPXprimopt(), CPXdualopt(), and CPXhybbaropt() will use this information to construct a starting point for the CPLEX simplex algorithms or the CPLEX crossover algorithms.
|
|
The starting point information is ignored by the optimizers if the CPX_PARAM_ADVIND parameter is off.
|
int CPXcopystart (CPXENVptr env,
CPXLPptr lp,
int *cstat,
int *rstat,
double *cprim,
double *rprim,
double *cdual,
double *rdual);
CPXENVptr envThe pointer to the CPLEX environment as returned by one of the
CPXopenCPLEX routines.
CPXLPptr lpA pointer to a CPLEX LP problem object as returned by
CPXcreateprob().
int *cstatAn array containing the basis status of the columns in the constraint matrix. The length of the array is equal to the number of columns in the LP problem object.
CPX_AT_LOWER
|
0
|
variable at lower bound
|
CPX_BASIC
|
1
|
variable is basic
|
CPX_AT_UPPER
|
2
|
variable at upper bound
|
CPX_FREE_SUPER
|
3
|
variable free and non-basic
|
Values for cstat[j]:
If this array is
NULL, rstat must be NULL.
int *rstatAn array containing the basis status of the slack/surplus/artificial variable associated with each row in the constraint matrix. The array's length is equal to the number of rows in the LP problem. For rows other than ranged rows, the array element
rstat[i] has the following meaning:
CPX_AT_LOWER
|
0
|
associated slack variable non-basic at value 0.0
|
CPX_BASIC
|
1
|
associated slack artificial variable basic
|
For ranged rows, the array element
rstat[i] has the following meaning:
CPX_AT_LOWER
|
0
|
associated slack variable non-basic at its lower bound
|
CPX_BASIC
|
1
|
associated slack variable basic
|
CPX_AT_UPPER
|
2
|
associated slack variable non-basic at upper bound
|
If this array is
NULL, cstat must be NULL.
double *cprimAn array containing the initial values of the primal column variables. The length of the array must be no less than the number of columns in the LP problem object. If this array is
NULL, rprim must be NULL.
double *rprimAn array containing the initial values of the primal slack (row) variables. The length of the array must be no less than the number of rows in the LP problem object. If this array is NULL,
cprim must be NULL.
double *cdualAn array containing the initial values of the reduced costs for the column variables. The length of the array must be no less than the number of columns in the LP problem object. If this array is NULL,
rdual must be NULL.
double *rdualAn array containing the initial values of the dual variables for the rows.The length of the array must be no less than the number of rows in the LP problem object. If this array is NULL,
cdual must be NULL.
status = CPXcopystart (env, lp, cstat, rstat, cprim, rprim,
cdual, rdual);