# Difference between revisions of "OptSlack"

Line 17: | Line 17: | ||

== See Also == | == See Also == | ||

+ | * [[OptScalarToConstraint]] | ||

* [[OptRhsSa]] | * [[OptRhsSa]] | ||

* [[OptShadow]] | * [[OptShadow]] |

## Latest revision as of 22:10, 22 January 2016

## OptSlack(opt)

Returns the slack, or surplus, values for the constraints at the optimal solution. «opt» is a problem specified by DefineOptimization.

As an example, consider the following example constraint:

`5 x`

_{1}+ 3 x_{2}- x_{3}<= 14

Suppose the optimal solution is found at `(1, 2, 3)`

. Then the left-hand side of this constraint at the optimum is 8. The slack, therefore, is *14 - 8 = 6*. In other words, the right-hand side coefficient could be decreased by 6 units before the optimal solution would be impacted.

A slack of zero indicates that the constraint is one that is actively constraining the optimal solution.

## History

This function was introduced in Analytica 4.3. Prior to Analytica 4.3, it was named LpSlack.

## See Also

Comments

Enable comment auto-refresher