Previous Page: CPXNETgetarcnodes First PageNext Page: CPXNETgetdj

CPXNETgetbase


Description

Use function CPXNETgetbase() to access the network basis for a CPLEX network problem object. Either of the arguments astat or nstat may be NULL.

For this function to succeed, a solution must exist for the CPLEX network problem object.

Return Value

If the operation is successful, CPXNETgetbase() returns the value 0; if not, it returns a nonzero value to indicate an error.

Synopsis

int CPXNETgetbase (CPXENVptr env,
                   CPXNETptr net,
                   int *astat,
                   int *nstat);

Arguments


CPXENVptr env
The pointer to the CPLEX environment as returned by one of the CPXopenCPLEX() routines.

CPXNETptr net
A pointer to a CPLEX network problem object as returned by CPXNETcreateprob().

int *astat
An array in which the statuses for network arcs are to be written. After termination, astat[i] will contain the status assigned to arc i of the network stored in net. The status may be one of the following:

CPX_BASIC  
If the arc is basic.  
CPX_AT_LOWER  
If the arc is nonbasic and its flow is on the lower bound.  
CPX_AT_UPPER  
If the arc is nonbasic and its flow is on the upper bound.  
CPX_FREE_SUPER  
If the arc is nonbasic but is free. In this case its flow will be 0.  

If NULL is passed, no arc statuses will be copied. Otherwise, astat must be an array of a size that is at least CPXNETgetnumarcs().

int *nstat
An array in which the statuses for artificial arcs from each node to the root node are to be written. After termination, nstat[i] will contain the status assigned to the artificial arc from node i to the root node of the network stored in net. The status may be one of the following:

CPX_BASIC  
If the arc is basic.  
CPX_AT_LOWER  
If the arc is nonbasic and its flow is on the lower bound.  

If NULL is passed, no node statuses will be copied. Otherwise, nstat must be an array of a size that is at least CPXNETgetnumnodes().

Example

status = CPXNETgetbase (env, net, astat, nstat);

Previous Page: CPXNETgetarcnodes First PageNext Page: CPXNETgetdj