XSLPadddfs
XSLPadddfs |
Purpose
Add a set of distribution factors
Synopsis
int XSLP_CC XSLPadddfs(XSLPprob Prob, int nDF, const int *ColIndex, const int *RowIndex, const double *Value)
Arguments
Prob
|
The current SLP problem.
|
nDF
|
The number of distribution factors.
|
ColIndex
|
Array of indices of columns whose distribution factor is to be changed.
|
RowIndex
|
Array of indices of the rows where each distribution factor applies.
|
Value
|
Array of double precision variables holding the new values of the distribution factors.
|
Example
The following example adds distribution factors as follows:
column 282 in row 134 = 0.1
column 282 in row 136 = 0.15
column 285 in row 133 = 1.0.
column 282 in row 134 = 0.1
column 282 in row 136 = 0.15
column 285 in row 133 = 1.0.
int ColIndex[3], RowIndex[3]; double Value[3]; ColIndex[0] = 282; RowIndex[0] = 134; Value[0] = 0.1; ColIndex[1] = 282; RowIndex[1] = 136; Value[1] = 0.15; ColIndex[2] = 285; RowIndex[2] = 133; Value[2] = 1.0; XSLPadddfs(prob,3,ColIndex,RowIndex,Value);
Further information
The distribution factor of a column in a row is the matrix coefficient of the corresponding delta vector in the row. Distribution factors are used in conventional recursion models, and are essentially normalized first-order derivatives. Xpress-SLP can accept distribution factors instead of initial values, provided that the values of the variables involved can all be calculated after optimization using determining rows, or by a callback.
The XSLPadd... functions load additional items into the SLP problem. The corresponding XSLPload... functions delete any existing items first.
Related topics