Display of constraint results
Constraint nodes are used in Analytica Optimizer models (not usable in lower editions of Analytica. The Definition of a Constraint is a comparison such as x + y <= z
.
When displaying the result of a constraint it evaluates and displays the result of the left-hand and right-hand side values, which it displays along with the comparison operator using the selected number format. For example, the constraint defined as
GetFract(Expenses, 75%) <= GetFract(Revenue, 25%)
might show as a result as:
845.1 <= 12.3K
Note that in a non-constraint node, the result of a comparison would display as a Boolean value, i.e., 0
or 1
(False or True).
When the constraint is violated the display is preceded by {!}
, e.g.,
{!}28 <= 21
.
This information can help you debug an optimization model by showing the actual values of each side of the constraint. If you select the Boolean number format, it doesn't show the comparison display but rather True
is displayed when the constraint is satisfied, False
when it is violated. Beware that the optimizer solver engines sometimes find solutions that are within an epsilon (tiny number) of satisfying each constraint, and may show the constraint result as False
because the constraint is violated only by epsilon, even though the solver engine considers it satisfied.
See Also
- Introduction to Optimizer
- Constraints
- DefineOptimization
- Comparison Operators
- Boolean or truth values
Enable comment auto-refresher