this repo has no description
1include "global_cardinality_closed.mzn";
2
3/** @group globals.counting
4 Returns an array with number of occurences of \p i in \a x.
5
6 The elements of \a x must take their values from \a cover.
7*/
8function array[int] of var int: global_cardinality_closed(array[int] of var int: x,
9 array[int] of int: cover) :: promise_total =
10 let { array[index_set(cover)] of var 0..length(x): counts;
11 constraint global_cardinality_closed(x,cover,counts); }
12 in counts;