Previous Page: CPXNETgetphase1cnt First PageNext Page: CPXNETgetprobname

CPXNETgetpi


Description

The function CPXNETgetpi() is used to access dual values or, equivalently, fair prices for a range of nodes in the network stored in a CPLEX network problem object.

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

Return Value

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

Synopsis

int CPXNETgetpi (CPXENVptr env,
                 CPXNETptr net,
                 double *pi,
                 int begin,
                 int end);

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().

double *pi
Array in which to write solution dual values (or fair prices) for requested nodes. If NULL is passed, no data will be returned. Otherwise pi must point to an array of a size that is at least (end-begin+1).

int begin
Index of the first node for which the dual value is obtained.

int end
Index of the last node for which the dual value is obtained.

Example

status = CPXNETgetpi (env, net, pi, 10, 20);

Previous Page: CPXNETgetphase1cnt First PageNext Page: CPXNETgetprobname