violation

fun violation(responseValue: Double): Double(source)

The violation is maxOf(0, R(x) - b). This quantity is often used in penalty function calculations.

Parameters

responseValue

The value of the response to be evaluated for the constraint.


fun violation(estimatedResponse: EstimatedResponse): Double(source)

Overloaded violation function that accepts an EstimatedResponse.


open override fun violation(solution: Solution): Double(source)

A response constraint's violation is computed from the solution's estimated response for this constraint's response; 0 when the solution has no estimate for it.