Centrum voor Wiskunde en lnformatica
Centre
for
Mathematics
and
Computer
Science
P.J.M.
van
Laarhoven,
E.H.L.
Aarts,
J.K.
Lenstra
Job
shop
scheduling
by
simulated
annealing
,
Department
of
Operations
Research
and
System
Theory
Report
OS-R8809
July
Bibfiothf!of>J;
Centrum
vocr
',\ ;
..
.r.:;
"":"
e,
1
lnformaUca;
/o'JT1$lt<1cJ<;rT>
The Centre for Mathematics and Computer Science
is
a research institute of the Stichting
Mathematisch Centrum, which was founded on February
11
. 1946,
as
a nonprofit institution aim-
ing at the promotion of mathematics. computer science, and their applications.
It
is
sponsored by
the Dutch Government through the Netherlands Organization for the Advancement of Pure
Research (Z.W.0.).
Copyright
© Stichting Mathematisch Centrum, Amsterdam
Job
Shop
Scheduling
by
Simulated
Annealing
Peter
J.M.
van
Laarhoven
Philips
Research
Laboratories,
P.O.
Box
BO.OOO,
5600
JA
Eindhoven,
The
Netherlands
Emile
H.L.
Aarts
Philips
Research
Laboratories,
P.O.
Box
BO.OOO,
5600
JA
Eindhoven,
The
Netherlands;
Department
of
Mathematics
and
Computing
Science,
Eindhoven
University
of
Technology,
P.O.
Box513, 5600MBEindhoven,
The
Netherlands
Jan
Karel
Lenstra
Centre
for
Mathematics
and
Computer
Science,
P.
0.
Box
4079,
1009
AB
Amsterdam,
The
Netherlands;
Econometric
Institute,
Erasmus
University,
P.O.
Box
173B,
3000
DR
Rotterdam,
The
Netherlands
We
describe
an
approximation
algorithm
for
the
problem
of
finding
the
minimum
makespan
in
a
job
shop.
The
algorithm
is
based
on
simulated
annealing,
a
gen-
eralization
of
the
well-known
iterative
improvement
approach
to
combinatorial
optimization
problems.
The
generalization
implies
the
acceptance
of
cost-
increasing
transitions
with
a
non-zero
probability
so
as
to
avoid
getting
stuck
in
local
minima.
We
prove
that
our
algorithm
asymptotically
converges
in
probability
to
a
glo-
bally
minimal
solution,
despite
the
fact
that
the
Markov
chains
generated
by
the
algorithm
are
generally
not
irreducible.
Computational
experiments
show
that
our
algorithm
can
find
shorter
make-
spans
than
tailored
heuristics
for
this
problem,
at
the
expense
of
larger
computa-
tion
times.
19BO
Mathematics
Subject
Classification
(19B5
Revision):
90835,
90C27.
Key
Words
&
Phrases.
job
shop
scheduling,
probabilistic
algorithms,
simulated
annealing.
Note-.
This
paper
has
been
submitted
for
publication.
In
this
paper
we are concerned
with
a problem
in
machine scheduling, which
is known as
the
job shop scheduling problem
(Coffman 1976, French 1982).
Informally,
the
problem
can
be described as follows.
We
are
given a
set
of
jobs
and
a
set
of machines. Each
job
consists
of
a chain
of
operations,
each
of
which needs
to
be processed
during
an
uninterrupted
time
period
of
a
given
length
on
a given machine. Each machine
can
process
at
most
one
operation
at
a time.
The
problem is
to
find a
schedule,
i.e.
an
allocation
of
Report
OS-R8809
Centre
for
Mathematics
and
Computer
Science
P.O.
Box
4079,
1009
AB
Amsterdam,
The
Netherlands
the
operations
to
time
intervals on
the
machines,
that
has
minimum
length.
A precise formulation of
the
problem is given in §1.
The
job
shop
scheduling problem is among
the
hardest
combinatorial
opti-
mization
problems;
not
only is
it
}./
P-hard,
but
even among
the
members
of
the
latter
class
it
belongs
to
the
more difficult ones (Lawler,
Lenstra
and
Rinnooy
Kan
1982). Optimization algorithms for
job
shop
scheduling pro-
ceed by
branch
and
bound, see for instance Lageweg,
Lenstra
and
Rinnooy
Kan
{1977),
Carlier
and
Pinson
{1988).
Most
approximation algorithms use
a
priority
rule, i.e. a rule for choosing
an
operation
from a specified
subset
of
as
yet
unscheduled operations.
Adams,
Balas
and
Zawack (1988) developed
a shifting bottleneck procedure, which employs
an
ingeneous
combination
of
schedule
construction
and
iterative
improvement, guided by solutions
to
single-machine problems. In this
paper
we describe
an
alternative
approach,
known as
simulated annealing (Kirkpatrick,
Gelatt
and
Vecchi 1983, Cerny
1985). Simulated annealing
can
be viewed as a generalization
of
iterative
improvement
and
is described
in
more
detail
in §2.
In
§3
we describe
the
application of simulated annealing
to
job
shop
schedul-
ing. We prove
asymptotic
convergence
of
the
algorithm
to
a globally minimal
solution
by showing
that
the
neighbourhood
structure
is such
that
each er-
godic
set
contains
at
least one global minimum. §4
contains
the
results
of
a
computational
study, in which
simulated
annealing is used
to
find approxi-
mate
solutions
to
a large
set
of
instances of
the
job
shop scheduling problem.
We
show
that
simulated annealing performs slightly
better
than
the
shifting
bottleneck
procedure
with
respect
to
the
length
of
the
schedules
returned
by
the
algorithm,
though
computation
times
can
be (very) long.
We
end
this
paper
with
some concluding remarks.
1
The
Problem
We
are
given a
set
J
of
n
jobs,
a
set
.M
of
m machines,
and
a
set
0
of
N
operations.
For each
operation
v E 0
there
is a
job
Jv
E J
to
which
it
belongs, a machine
Mv
E .Mon which
it
requires processing,
and
a processing
time
tv
E
IN.
There
is a binary relation
~
on
0
that
decomposes 0
into
chains corresponding
to
the
jobs; more specifically, if v
~
w,
then
Jv
=
Jw
and
there
is no x
€/:.
{ v,
w}
such
that
v
~
x
or
x
~
w.
The
problem
is
to
find a
start
time
Sv
for each
operation
v E 0 such
that
max
Sv +
tv,
vEO
2
(1)
is minimized
subject
to
Bv
2:
O,
Vv
E
0
{2)
Bw
-
Bv
2:
tv,
if
V
-t
w,
v,
WE
0
{3)
Bw
-
Bv
2:
tv
V
Bv
-
Bw
2::
tw,
if
Mv
=
Mw,
V,
W
E
0 (
4)
It
is useful
to
represent
the
problem
by
the
disjunctive graph
model
of
Roy
and
Bussmann
(1964).
The
disjunctive
graph
G = (V,
A,
E)
is defined as
follows:
• V
=
Ou{O,
N
+1},
where
0
and
N
+1
are
two
fictitious
operations;
the
weight
of
a
vertex
vis
given by
the
processing time
tv
(to=
tN+l
=
0).
•
A=
{(v,w)I
v,w
E
O,v
-t
w}
U
{(O,w)I
w
E
0,
~
v
E
0:
v
-t
w}
U
{(v, N
+
1)1
v
E
0,
~
w
E
0 :
v
-t
w}.
Thus,
A
contains
arcs connect-
ing consecutive
operations
of
the
same
job,
as well as arcs
from
0
to
the
first
operation
of
each
job
and
from
the
last
operation
of
each
job
to
N
+
1.
• E
=
{{
v,
w}
I
Mv
=
Mw}.
Thus,
edges in
E
connect
operations
to
be
processed by
the
same
machine.
Figure
1
illustrates
the
disjunctive
graph
for a 3-job 3-machine
instance,
where
each
job
consists
of
three
operations.
For
each
pair
of
operations
v,
w
E
0
with
v
-t
w,
condition
(3) is
represented
by
an
arc
(v,w)
in
A.
Similarly, for each
pair
of
operations
v,w
E
0
with
Mv
=
Mw,
the
disjunctive
constraint
( 4) is represented by
an
edge {
v,
w}
in
E,
and
the
two ways
to
settle
the
disjunction correspond
to
the
two
possible
orientations
of
the
edge.
There
is
an
obvious one-to-one correspondence
between a
set
of
choices
in
(
4)
that
is overall feasible
and
an
orientation
of
all
the
edges
in
E
for which
the
resulting
digraph
is acyclic.
The
objective
value
(the
makespan)
of
the
corresponding
solution
is given by
the
length
of
a longest
path
in
this
digraph. Such a
set
of
orientations
decomposes
0
into
chains corresponding
to
the
machines, i.e.,
it
defines for each machine
an
ordering
or
permutation
of
the
operations
to
be
processed by
that
machine.
Conversely, a
set
of
machine
permutations
defines a
set
of
orientations
of
the
edges
in
E,
though
not
necessarily one which results in
an
acyclic
digraph.
Since
the
longest
path
in a cyclic
digraph
has
infinite
length,
we
can
now
rephrase
the
problem
as: find a
set
of
machine
permutations
that
minimizes
the
longest
path
in
the
resulting digraph.
In
§3
we use
this
formulation
of
the
problem
to
find
approximate
solutions by
simulated
annealing.
3