class CAS::BoxConditionClosed
Implements the box condition with both bounds closed
“` a ≤ f(x) ≤ b “`
Public Instance Methods
call(fd)
click to toggle source
Function
call will evaluate box condition to evaluate relation
* **argument**: `Hash` with feed dictionary * **returns**: `Trueclass` or `Falseclass`
# File lib/functions/fnc-box-conditions.rb, line 269 def call(fd) x_call = @x.call(fd) return ((@lower.call(fd) <= x_call) and (x_call <= @upper)) end
representative()
click to toggle source
Saves some required elements
# File lib/functions/fnc-box-conditions.rb, line 258 def representative @lower_cond = @upper_cond = "<=" @lower_str = @upper_str = "≤" self end