XPRSgetbasis
PurposeReturns the current basis into the user's data areas.Synopsisint XPRS_CC XPRSgetbasis(XPRSprob prob, int rstatus[], int cstatus[]);
Arguments
prob The current problem. rstatus Integer array of length ROWS to the basis status of the slack, surplus or artificial variable associated with each row. The status will be one of:
0 slack, surplus or artificial is non-basic at lower bound; 1 slack, surplus or artificial is basic; 2 slack or surplus is non-basic at upper bound. 3 slack or surplus is super-basic.May be NULL if not required.
cstatus Integer array of length COLS to hold the basis status of the columns in the constraint matrix. The status will be one of:
0 variable is non-basic at lower bound, or superbasic at zero if the variable has no lower bound; 1 variable is basic; 2 variable is non-basic at upper bound; 3 variable is super-basic.May be NULL if not required.
ExampleThe following example minimizes a problem before saving the basis for later:int rows, cols, *rstatus, *cstatus; ... XPRSgetintattrib(prob,XPRS_ROWS,&rows); XPRSgetintattrib(prob,XPRS_COLS,&cols); rstatus = (int *) malloc(sizeof(int)*rows); cstatus = (int *) malloc(sizeof(int)*cols); XPRSminim(prob,""); XPRSgetbasis(prob,rstatus,cstatus);Related topics
If you have any comments or suggestions about these pages, please send mail to docs@dashoptimization.com.