XSLPadddcs


Purpose
Add delayed constraints (DCs) to the SLP problem
Synopsis
int XPRS_CC XSLPadddcs(XSLPprob Prob, int nSLPDC, int *RowIndex, int *Delay, int *DCStart, int Parsed, int *Type, double *Value);
Arguments
Prob 
The current SLP problem.
nSLPDC 
Number of DCs to be added.
RowIndex 
Integer array of the row indices of the DCs. This respects the setting of XPRS_CSTYLE.
Delay 
Integer array of length nSLPDC holding the delay after initiation for each DC.
DCStart 
Integer array of length nSLPDC holding the start position in the arrays Type and Value of the formula for each DC. The DCStart entry should be negative for any DC which does not have a formula to determine the DC initiation.
Parsed 
Integer indicating the whether the token arrays are formatted as internal unparsed (Parsed=0) or internal parsed reverse Polish (Parsed=1).
Type 
Array of token types providing the description and formula for each item.
Value 
Array of values corresponding to the types in Type.
Example
The following example adds rows 3 and 5 to the list of delayed constraints. Row 3 is delayed until 2 SLP iterations after column 12 becomes nonzero; row 5 is delayed for 10 SLP iterations from the start (that is, until SLP iteration 11).
int RowIndex[2], Delay[2], DCStart[2], Type[2];
double Value[2];

RowIndex[0] = 3; Delay[0] = 2; DCStart[0] = 0;
Type[0] = XSLP_COL; Value[0] = 12;
Type[1] = XSLP_EOF;

RowIndex[1] = 5; Delay[1] = 10; DCStart[1] = -1;

XSLPadddcs(Prob, 2, RowIndex, Delay, DCStart, 1, Type, Value);

Note that the entry for row 5 has a negative DCStart because there is no specific initiation formula (the countdown is started when the SLP optimization starts).


Further information

The XSLPadd... functions load additional items into the SLP problem. The corresponding XSLPload... functions delete any existing items first.

The token type and value arrays Type and Value follow the rules for parsed or unparsed formulae. For possible token types and values see the chapter on "Formula Parsing". Each formula must be terminated by an XSLP_EOF token.


Related topics
XSLPchgdc, XSLPgetdc, XSLPloaddcs


If you have any comments or suggestions about these pages, please send mail to docs@dashoptimization.com.