Lecture 23: The Timetable Constrained Distance Minimization Problem © J. Christopher Beck 2008

advertisement
Lecture 23:
The Timetable Constrained
Distance Minimization Problem
© J. Christopher Beck 2008
1
Outline






The timetable constrained distance
minimization problem (TCDMP)
The problem
IP Model
CP Model
CP/IP Hybrid
Results
© J. Christopher Beck 2008
2
Readings

Rasmussen, R. & Trick, M.,
The timetable constrained distance
minimization problem, Annals of
Operations Research, in press.
© J. Christopher Beck 2008
3
TCDMP
Pattern set
(HAPS!)
Timetable
© J. Christopher Beck 2008
4
TCDMP

Given:




a timetable for a double round robin
distance matrix between each city
upper bound on the # of consecutive
home/away games for a team
Find:

a feasible pattern set which minimizes the
total distance travelled by all teams

assign all home/away games
© J. Christopher Beck 2008
5
Notation



T: set of teams, |T| = n
S: set of slots, S0 = S U {0}
D: distance matrix


entry Di1i2 is the distance between home of
team i1 and home of team i2
TT: timetable

entry TTis is the opponent of team i in slot
s
© J. Christopher Beck 2008
6
IP Formulation


his = 1 if team i plays at home in slot s
= 0 if it plays away
dis = distance team i travels between
slot s and s + 1

slot 0 and 2n-1 are “home”
© J. Christopher Beck 2008
7
IP Formulation
away/away
home/away
away/home
starts at home (in slot 0)
end at home (in last slot)
right # of home games
© J. Christopher Beck 2008
8
one team must be home
one home one away
against a given other team
max consecutive home games
max consecutive away games
© J. Christopher Beck 2008
9
CP Formulation
logical
constraints to
determine
travel
distance
© J. Christopher Beck 2008
10
Sequence Constraint
sequence(min,max,width,base,value,card)




GCC


min,max,width: integers
base: vector of variables
value: vector of values
card: vector of cardinalities
value[i] is taken by card[i] elements of
base, and
for any sub-sequence of base of size width
each value[i] is present [min .. max] times
© J. Christopher Beck 2008
11
CP Formulation
logical
constraints to
determine
travel
distance
team i must play exactly n-1 home games
(1 appears n-1 times)
in UB+1 consecutive games, must have at
© J. one
Christopher
2008
least
and atBeck
most
UB home games
12
CP Formulation
one home, one away
against a given other team
team and opponent not both home or both away
starts at home (in slot 0)
end at home (in last slot)
© J. Christopher Beck 2008
13
Results
Time limit per run = 1800 seconds
IP
n
6
8
10
12
14
16
CP
# Solved
Mean CPU (s)
# Solved
Mean CPU (s)
10
10
1
0
0
0
22.5
397.4
1273.7
-
10
0
0
0
0
0
17.0
-
© J. Christopher Beck 2008
14
CP/IP Hybrid

Phase 1: generate all feasible patterns
for each team


remember we already have the timetable
Phase 2: find optimal pattern set by
assigning each team to a pattern from
Phase 1
© J. Christopher Beck 2008
15
Phase 1: CP Formulation
same sequence constraint as in full CP model
team i must play exactly n-1 home games (1 appears n-1 times)
in UB+1 consecutive games, must have at least one
and at most UB home games
one home, one away
against a given other team
one problem per team (same formulation solved n times)
© J. Christopher Beck 2008
16
Phase 1: CP Formulation




Find all satisfying solutions to model
Pi: set of satisfying patterns for team i
hjs: hs entry in pattern j є Pi
dij: distance team i must travel if it uses
pattern j є Pi
© J. Christopher Beck 2008
17
Phase 2: IP Formulation

xij = 1 iff team i takes pattern j є Pi
each team takes one pattern
when teams meet, one is home, one away
© J. Christopher Beck 2008
18
Results
Time limit per run = 1800 seconds
IP
n
6
8
10
12
14
16
CP
# Solved
Mean CPU (s)
# Solved
Mean CPU (s)
10
10
1
0
0
0
22.5
397.4
1273.7
-
10
0
0
0
0
0
17.0
-
© J. Christopher Beck 2008
19
Results
Time limit per run = 1800 seconds
IP
n
6
8
10
12
14
16
CP
CP/IP
# Solved
Mean CPU (s)
# Solved
Mean CPU (s)
# Solved
Mean CPU (s)
10
10
1
0
0
0
22.5
397.4
1273.7
-
10
0
0
0
0
0
17.0
-
10
10
10
10
10
10
0.07
0.44
2.02
12.2
38.1
197.2
© J. Christopher Beck 2008
20
Discussion

Clever decomposition!



Generate-and-choose is interesting
CP not strong at optimization but good
at satisfaction
Similar to 3 phase breakdown we’ve
been looking at, but finds optimal
solutions

why?
© J. Christopher Beck 2008
21
Download