NO FRAMES

CPXgetstat

public int CPXgetstat(CPXCENVptr env, CPXCLPptr lp)
Definition file: cplex.h

The routine CPXgetstat accesses the solution status of the problem after an LP, QP, QCP, or MIP optimization, after CPXfeasopt and its extensions, after CPXrefineconflict and its extensions.

Example

 lpstat = CPXgetstat (env, lp);
 

Parameters:

env

A pointer to the CPLEX environment as returned by CPXopenCPLEX.

lp

A pointer to a CPLEX problem object as returned by CPXcreateprob.

Returns:

The routine returns the solution status of the most recent optimization performed on the CPLEX problem object. Nonzero return values are shown in the group optim.cplex.solutionstatus. A return value of 0 (zero) specifies either an error condition or that a change to the most recently optimized problem may have invalidated the solution status. For status code CPX_STAT_NUM_BEST, the algorithm could not converge to the requested tolerances due to numeric difficulties.

The best solution found can be retrieved by the routine CPXsolution. Similarly, when an abort status is returned, the last solution computed before the algorithm aborted can be retrieved by CPXsolution.

Use the query routines CPXsolninfo and CPXsolution to obtain further information about the current solution of an LP, QP, or QCP.