5.363. soft_same_modulo_var
DESCRIPTION | LINKS | GRAPH |
- Origin
- Constraint
- Synonym
.
- Arguments
- Restrictions
- Purpose
For each integer in , let (respectively ) denote the number of variables of (respectively ) that have as a rest when divided by . is the minimum number of values to change in the and collections so that for all in we have .
- Example
-
In the example, the values of the collections and are respectively associated with the equivalence classes , , , , , and , , , , , . Since there is a correspondence between two pairs of equivalence classes we must unset at least items (6 is the number of items of the and collections). Consequently, the constraint holds since its first argument is set to .
- Typical
- Symmetries
Arguments are permutable w.r.t. permutation .
Items of are permutable.
Items of are permutable.
An occurrence of a value of can be replaced by any other value such that is congruent to modulo .
An occurrence of a value of can be replaced by any other value such that is congruent to modulo .
- Usage
- Algorithm
- See also
-
implies: .
- Keywords
characteristic of a constraint: modulo.
constraint arguments: constraint between two collections of variables.
constraint type: soft constraint, relaxation, variable-based violation measure.
- Arc input(s)
- Arc generator
-
- Arc arity
- Arc constraint(s)
- Graph property(ies)
-
- Graph model
PartsΒ (A) andΒ (B) of FigureΒ 5.363.1 respectively show the initial and final graph associated with the Example slot. Since we use the graph property, the source and sink vertices of the final graph are stressed with a double circle. The constraint holds since the cost 4 corresponds to the difference between the number of variables of and the sum over the different connected components of the minimum number of sources and sinks.
Figure 5.363.1. Initial and final graph of the constraint
(a) (b)