Function GMP::Solution::GetObjective(GMP, solution)

GMP::Solution::GetObjective

The function GMP::Solution::GetObjective retrieves the objective function value of a solution in the solution repository of a generated mathematical program.

GMP::Solution::GetObjective(
     GMP,            ! (input) a generated mathematical program
     solution        ! (input) a solution
     )

Arguments

GMP

An element in AllGeneratedMathematicalPrograms.

solution

An integer scalar reference to a solution.

Return Value

The objective function value of the solution.

Note

The objective function value is only available if the solution has been retrieved from the solver, or if the function GMP::Solution::SetObjective has been called before.