NO FRAMES

CPXgetnumnz

int CPXPUBLIC CPXgetnumnz(CPXCENVptr env, CPXCLPptr lp)
Definition file: cplex.h
Include files: cplex.h

The routine CPXgetnumnz is used to access the number of nonzero elements in the constraint matrix of a CPLEX problem object, not including the objective function, quadratic constraints, or the bounds constraints on the variables.

Example

 cur_numnz = CPXgetnumnz (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:

If the problem object or environment does not exist, CPXgetnumnz returns the value 0 (zero); otherwise, it returns the number of nonzero elements.