NO FRAMES

CPXNETprimopt

public int CPXNETprimopt(CPXCENVptr env, CPXNETptr net)
Definition file: cplex.h

The routine CPXNETprimopt can be called after a network problem has been copied to a network problem object, to find a solution to that problem using the primal network simplex method. When this function is called, the CPLEX primal network algorithm attempts to optimize the problem. The results of the optimization are recorded in the problem object and can be retrieved by calling the appropriate solution functions for that object.

Example

 status = CPXNETprimopt (env, net);

See also the examples netex1.c and netex2.c in the standard distribution of the product.

Parameters:

env

A pointer to the CPLEX environment as returned by CPXopenCPLEX.

net

A pointer to a CPLEX network problem object as returned by CPXNETcreateprob.

Returns:

The routine returns zero unless an error occurred during the optimization. Examples of errors include exhausting available memory (CPXERR_NO_MEMORY) or encountering invalid data in the CPLEX problem object (CPXERR_NO_PROBLEM). Exceeding a user-specified CPLEX limit, or proving the model infeasible or unbounded, are not considered errors. Note that a zero return value does not necessarily mean that a solution exists. Use query routines CPXNETsolninfo, CPXNETgetstat, and CPXNETsolution to obtain further information about the status of the optimization.