After the handle has been initialized (e.g., handle_init has been called),
handle_set_linobj may be used to define the objective function of the problem as a linear function using a dense vector . If the objective function has already been defined, it will be overwritten. If ,
any existing objective function is removed, no new one is added and the problem will be solved as a feasible point problem.
It is recommended to use handle_set_quadobj if the vector is sparse. e04tef (no CPP interface) may be used to set individual elements of the linear objective.
This will typically be used for Linear Programming (LP)
Second-order Cone Programming (SOCP)
linear Semidefinite Programming problems (SDP)
or SDP with bilinear matrix inequalities (BMI-SDP) where the objective function has only linear terms. See Section 3.1 in the E04 Chapter Introduction for more details about the NAG optimization modelling suite.
An object of either the derived class CommE04RA or its base class NoneCopyableComm can be supplied.
It is recommended that the derived class is used. If the base class is supplied it must
first be initialized via a call to opt::handle_init (e04ra).
2: – double arrayInput
On entry: the dense vector of the objective function.
3: – OptionalE04REInput/Output
Optional parameter container, derived from Optional.
, the current number of decision variables in the model.
6Exceptions and Warnings
Errors or warnings detected by the function:
All errors and warnings have an associated numeric error code field, errorid, stored either as a member of the thrown exception object (see errorid), or as a member of
opt.ifail, depending on how errors
and warnings are being handled (see Error Handling for more details).