this repo has no description
1% RUNS ON mzn20_fd
2% RUNS ON mzn-fzn_fd
3% RUNS ON mzn20_fd_linear
4% RUNS ON mzn20_mip
5
6% Prior to r8850 mzn2fzn would abort when attempting to flatten the
7% seq_search annotation here.
8
9include "globals.mzn" ;
10
11int: weeks = 5;
12int: flatsize = 7 * weeks ;
13
14array [1..weeks,1..7] of var 1..5: roster;
15array [1..flatsize] of var 1..5: flatroster ;
16
17array [1..7,1..weeks] of var 1..weeks: restdays ;
18array [1..7,1..weeks] of var 1..flatsize: morndays ;
19array [1..7,1..weeks] of var 1..flatsize: evedays ;
20
21solve
22 :: seq_search([
23 int_search([restdays[d,w]|d in 1..7,w in 1..weeks], input_order, indomain_min, complete),
24 int_search([morndays[d,w]|d in 1..7,w in 1..weeks], input_order, indomain_min, complete),
25 int_search([evedays[d,w]|d in 1..7,w in 1..weeks], input_order, indomain_min, complete),
26 int_search(flatroster, first_fail, indomain_min, complete)])
27 satisfy;
28
29output ["roster = ", show(roster), ";\n"];