Class: Gecode::Constraints::Set::Channel::ChannelConstraint
- Inherits:
-
Constraint
- Object
- Constraint
- Gecode::Constraints::Set::Channel::ChannelConstraint
- Defined in:
- lib/gecoder/interface/constraints/set/channel.rb
Overview
Describes a channel constraint that “channels” a set variable and an enumerations of boolean variables. This constrains the set variable to include value i exactly when the variable at index i in the boolean enumeration is true.
Neither reification nor negation is supported. The boolean enum and set can be interchanged.
Examples
# Constrains the enumeration of boolean variables called bools
to at # least have the first and third variables set to true set.must_be.superset_of [0, 2] set.must.channel bools
# An alternative way of writing the above. set.must_be.superset_of [0, 2] bools.must.channel set
Instance Method Summary collapse
Methods inherited from Constraint
Constructor Details
This class inherits a constructor from Gecode::Constraints::Constraint