NO FRAMES

CPXNETchgobj

int CPXPUBLIC CPXNETchgobj(CPXCENVptr env, CPXNETptr net, int cnt, const int * indices, const double * obj)
Definition file: cplex.h
Include files: cplex.h

The routine CPXNETchgobj is used to change the objective values for a set of arcs in the network stored in a network problem object.

Any solution information stored in the problem object is lost.

Example

 status = CPXNETchgobj (env, net, cnt, indices, newobj);

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.

cnt

Number of arcs for which the objective values are to be changed.

indices

An array of indices that indicate the arcs for which the objective values are to be changed. This array must have a length of at least cnt. The indices must be in the range [0, narcs-1].

obj

An array of the new objective values for the arcs. This array must have a length of at least cnt.

Returns:

The routine returns zero on success and nonzero if an error occurs.