Creates, returns, and adds to the invoking model an empty objective function with the name specified by name and with the sense specified by sense.

Namespace: ILOG.Concert
Assembly: oplall (in oplall.dll)

Syntax

C#
IObjective AddObjective(
	ObjectiveSense sense,
	string name
)

Parameters

sense
Type: ILOG.Concert..::..ObjectiveSense
The optimization sense of the new objective.
name
Type: System..::..String
The name assigned to the new objective.

Return Value

The new zero objective.

Remarks

This method creates and returns an IObjective object with a zero expression and the specified optimization sense. The new IObjective object is assigned name as its name and added to the invoking IModel. This method is typically used in an application that applies column-wise modeling to fill in the objective function while creating the variables.

See Also