EvaluatedConstraint#
- class EvaluatedConstraint#
- is_feasible(*, atol: float) bool#
Check feasibility using the supplied absolute tolerance.
The query compares the stored violation with
atol. It does not re-evaluate the function or canonicalize the input state.
- violation() float#
Calculate the violation (constraint breach) value for this constraint
Returns the amount by which this constraint is violated:
For \(f(x) = 0\): returns \(|f(x)|\)
For \(f(x) \leq 0\): returns \(\max(0, f(x))\)
Zero implies feasibility. A small positive violation may also be feasible within the supplied query tolerance; the residual is not rounded to zero.
- property equality: Equality#
Read-only property.
Get the constraint equality type
- property evaluated_value: float#
Read-only property.
Get the evaluated constraint value
- property parameters: dict[str, str]#
Read-only property.
Get the parameters
- property provenance: list[Provenance]#
Read-only property.
Get the provenance chain.
See
provenancefor semantics.
- property subscripts: list[int]#
Read-only property.
Get the subscripts
- property used_decision_variable_ids: set[int]#
Read-only property.
Get the used decision variable IDs