Declaring the objective: IloObjective
Describes the C++ class IloObjective.
Objects of class IloObjective
represent objective functions in optimization models. IloCplex may only handle models with at most one objective
function, though the modeling API provided by Concert Technology does
not impose this restriction. An objective function is specified by
creating an instance of IloObjective .
For example:
IloObjective obj(env,
1*x[1] + 2*x[2] + 3*x[3],
IloObjective::Minimize);
defines the objective to minimize the expression 1*x[1]
+ 2*x[2] + 3*x[3].