sasoptpy.Model.get_objective

Model.get_objective(self)[source]

Returns the objective function as an Expression object

Returns
objectiveExpression

Objective function

Examples

>>> m.set_objective(4 * x - 5 * y, name='obj')
>>> print(repr(m.get_objective()))
sasoptpy.Expression(exp =  4.0 * x  -  5.0 * y , name='obj')