5.276. relaxed_sliding_sum
| DESCRIPTION | LINKS | GRAPH |
- Origin
CHIP
- Constraint
- Arguments
- Restrictions
- Purpose
There are between and sequences of consecutive variables of the collection such that the sum of the variables of the sequence is in .
- Example
-
Within the sequence we have exactly 3 subsequences of consecutive values such that their sum is located within the interval : subsequences , and . Consequently the constraint holds since the number of such subsequences is located within the interval .
- Symmetries
- Algorithm
- See also
-
used in graph description: Β (the sliding constraint).
- Keywords
characteristic of a constraint: hypergraph.
combinatorial object: sequence.
constraint type: sliding sequence constraint, soft constraint, relaxation.
- Arc input(s)
- Arc generator
-
- Arc arity
- Arc constraint(s)
-
- Graph property(ies)
-
- Graph model
Within the context of the Example slot, the corresponding final directed hypergraph is given by FigureΒ 5.276.1. For each vertex of the graph we show its corresponding position within the collection of variables. The constraint associated with each arc corresponds to a conjunction of two constraints involving 4 consecutive variables. We did not put vertex 1 since the single arc constraint that mentions vertex 1 does not hold (i.e.,Β the sum is not located in interval ). However, the directed hypergraph contains 3 arcs, so the constraint is satisfied since it was requested to have between 3 and 4 arcs.
Figure 5.276.1. Final directed hypergraph associated with the example
