Sunteți pe pagina 1din 6

ELSEVIER

Computers in Industry 31 (1996) 155-160

A genetic algorithm for job shop scheduling - A case study


N.S. Hemant Kumar, G. Srinivasan

Industrial Engineering and Management Division. Deparrment of Humanities and Social Sciences, Indian Institute of Technology, Madras
600 036, India
Received 11 May 1995; revised 25 April 1996; accepted 21 May 1996

Abstract
The problem of scheduling n jobs on m machines with each job having a specific route has been one of considerable
research over the last several decades. Branch and Bound algorithms for determining the optimal makespan have been
developed and tested on small sized problems and dispatching rule based heuristic algorithms to minimize specific
performance measures such as makespan, flowtime, tardiness, etc. are available to solve large sized problems. This paper
addresses the same problem faced by an organization and reports the solution of this problem using genetic algorithms (GA)
and a combination of dispatching rules. The proposed algorithm yields an improvement of about 30% in makespan over the
present system.
Keywords: Branch and bound algorithm;

Genetic algorithm;

Dispatching

1. Introduction
Job shop scheduling deals with scheduling n given
jobs over m given machines. Each job has a specific
route. The objective. in this paper is to minimize the
completion time of the last job on its last machine,
i.e., makespan. The problem is known to be hard
when there are man? than two jobs or two machines
[l]. Large sized problems can be solved using dispatching rules, which are used to choose a job to be
loaded on a machine from the queue [2].
The static job shop problem assumes that all jobs
are available at the beginning of the planning period
and that the processing times and set up times are
deterministic. In such cases, the set up times are
added to the proce,ssing times. The assumptions in
static job shop problems are discussed in Baker [2].

* Corresponding

author.

0166-3615/96/$15.00
Copyright
PII SOl66-3615(96)00043-7

rules; Job shop scheduling

Static job shop scheduling problems can be solved


using dispatching rules which are used to choose the
job to be loaded on a machine from a queue. Usually, non-delay schedules are evaluated where the
machine is not kept idle if there is at least one job in
the queue. Dispatching rules can be derived using
available information such as processing times and
due dates. A popular dispatching rule that uses processing time information is the SPT (Shortest Processing Time) rule where the job with the shortest
processing time is chosen from those in a queue. A
survey of dispatching rules can be found in Blackstone et al. [3] where 34 dispatching rules are listed.
They also conclude that no single dispatching rule
has given consistently good results for different job
shop situations. There have also been many instances
where a combination of rules has been used successfully in job shop scheduling [3].
Search techniques such as Simulated Annealing
and Tabu Search have been used to solve the static

0 1996 Elsevier Science B.V. All rights reserved.

156

N.S. Hemant Kmur,

G. Sriniuasm/

job shop scheduling problem. Storer et al. [4] have


proposed algorithms using a set of dispatching rules
along with search heuristics such as Simulated Annealing, Tabu Search, etc. Van Laarhoven et al. [5]
have developed an algorithm using Simulated Annealing and have reported extensive computational
testing of their algorithms using standard problems
from literature.
Gen et al. [6] have developed a genetic algorithm
using mutation
as the operator for minimizing
makespan in a static job shop. Biegal and Davem [7]
have illustrated the use of genetic algorithms to solve
single facility and general job scheduling problems
using crossover and mutation operators. Both the
above papers highlight the potential of genetic algorithms in this field and illustrate the use of problems
of very small size. Genetic algorithms using partially
mapped crossover operators have also been used to
minimize
flow time variance
in single facility
scheduling problems [8] and in flow shop scheduling

191.
In this paper, we use different dispatching rules
for different situations instead of using a single or a
combination rule consistently. The dispatching rule
is chosen randomly from a set of seven rules listed in
Section 3. We also develop a genetic algorithm that
progressively evaluates better solutions without getting trapped in a local minimum. The genetic algorithm includes the random dispatching rule approach
to choose jobs from the queue before every machine.
The genetic algorithm is applied to a real-life problem and results are presented.
The following section describes the problem situation while Section 3 explains in detail the advantages
of using different rules for different dispatching situations. The genetic algorithm is explained in Section
4 and the results obtained on applying the algorithm
to the case study are discussed in Section 5 followed
by the conclusions in Section 6.

2. The case problem


The job shop problem solved and reported in this
paper is extracted from an organization
making a
product for defense purposes. There is a single final
product whose annual demand is known. There are
several assembly shops which feed sub assemblies to

Computers in Industry 31 (19961 155-160

Fig. 1. Schematic diagram of the production

system.

the main assembly shop. There is a production shop


where components are manufactured and sent to the
assembly shops. A schematic description of the shop
is shown in Fig. 1.
The proposed genetic algorithm is tested using
data from the production shop. The shop has 80 jobs
and 59 machines. The maximum operations per job
is 37 while the minimum is two. The routes for the
jobs are such that a job may visit some machines
more than once. Wherever we have more than one
machine of the same type, we have considered a
common queue from which the jobs are loaded using
the randomly chosen dispatching rule. The component routes are usually fixed but if there is a situation
where the required machine is busy while an identical machine is free, the jobs are loaded on the free
machine.
The annual demand of the final product is used to
compute the demand of each of the components.
Unit processing times are multiplied by a factor to
include lost time due to non-availability
of machine
and operator. The batch size of each component is
equal to the monthly demand. The unit processing
time is multiplied with the batch size and the set up
times are added to result in the processing time of a
batch. Time to transport the items from one machine
to the next is also added to the processing times.
Orders for raw materials and purchased items are
usually placed in the beginning
of the year. The
production rate is less during this period since orders
for most material would not have been received.
During busy times capacity cannot meet the demand
and a compromise between utilization (large batches)
and customer service (small batches) has to be made.
This results in a situation where the best schedule
has to be determined for production of components

N.S. Hemant Kumar, G. Srinivasan/

in correct batch sizes to meet the requirements of the


subassembly
shops in time and to ensure prompt
starting of the assembly of the final product, leading
to objectives of minnmizing tardiness and makespan.
The annual demand for the final product is found
to fluctuate and the production shop is required to
meet increased demand without a proportional increase in the number of machines. The production
shop is usually behind schedule in such situations
which results in many tardy jobs. The shop also
faces the problem of rush orders from subassembly
shops which have to be met. The production shop
currently follows the Minimum Slack rule to choose
jobs from a queue to be loaded on a machine. Since
there are always a set of tardy jobs, there is a need to
find out whether this is because of an inefficient
dispatching rule, i.e., whether there are better dispatching rules that minimize makespan and tardiness.
This study focuses on the question of whether another single dispatching rule or a combination
of
rules can result in improvements
in makespan or
tardiness which after discussions are identified as
important objectives to be considered.

3. Advantages in using different dispatching


for different situations

rules

Let us consider the following seven popular dispatching rules from the literature [3]: SPT, TPT
(Total Processing Time), RPT (Remaining Processing Time), DS (Dynamic Slack), EDD (Earliest Due
Date), RANDOM
and FIFO (First-In-First-Out).
Each of the seven rules can be used individually to
yield seven different schedules from which the best
may be accepted.
Let us now consider the possibility of using a
randomly chosen ruble to choose jobs from the queue
whenever it is required. Let us consider a random
sequence of a fixed length (say 10) from numbers 1
to 7 given by [2 3 1 6 7 4 3 2 1 51. Here the number
represents the rule to be chosen. For example, number 1 indicates the SPT rule, 2 indicates the TPT rule
and so on.
In our scheduling procedure, we choose the dispatching rule according to the order in the random
sequence. The first dispatching rule chosen is rule 2
(TPT rule), the second is rule 3 (RPT rule) and SO

Computers in Industry 31 (1996) 155-160

157

on. In our example, we have created a sequence of


10 numbers. We actually need to have an infinitely
long string so that we have a rule every time a job is
to be chosen from the queue. However, if the string
length is sufficiently long, we can start from the
beginning once we have completed the string length.
In our example, if we need to choose a job to be
loaded for the eleventh time, we can use the TPT
rule (rule 2) again.
There is a possibility that a schedule generated
using this random sequence may be better than the
schedules generated using any of the seven used
individually
in the schedule. The motivation
to
choose different rules at different points comes from
the fact that the optimal solution can always be
looked upon as originating from such an infinitely
long string where the correct rules are in the required
order. It is also well known that no single rule has
consistently given the optimal solution for job shop
scheduling problems. It has been shown [lo] that
when more than one rule is used randomly, it is
possible with proper learning to obtain solutions with
better makespan than the solution obtained using the
poorest performing rule (among the rules considered).
A single randomly generated sequence may or
may not give better solutions when compared with
using the rules individually.
If we generate many
sequences and use an algorithm to learn and progressively improve the solutions, it is possible to obtain
better solutions than those obtained using each of the
rules individually.

4. A genetic algorithm
ing

(GA) for job shop schedul-

A genetic algorithm is a generic search procedure


for combinatorial optimization problems [ 111. It uses
the idea of survival of the fittest by progressively
accepting better solutions to the problems. The algorithm starts with a population of parent chromosomes from which off springs are generated. These
are evaluated for the fitness function (objective) and
off springs with better fitness values are used for
further analysis.
In the job shop scheduling problem, the fitness
function is the makespan of a given schedule which
has to be minimized.

158

N.S. Hemant Kumar, G, Sriniuasan/

The genetic algorithm developed for job shop


scheduling developed in this paper has an initial
population of 50 chromosomes. The fitness value for
all these chromosomes are computed and the mean
and standard deviation are calculated. The fitness
values of the chromosomes
in the population are
assumed to be normally distributed and the probability of acceptance being the difference of the cumulative distribution function at the fitness value from 1.
A chromosome is picked randomly from the population and is put into the mating pool if the acceptance
probability is more than a randomly generated number between 0 and 1. This process is continued till
the mating pool thus created has 100 chromosomes.
The next population is created from the mating
pool using operators such as single point crossover,
two point crossover, inversion and mutation. Single
point crossover chooses two chromosomes and one
position randomly. The values in the two chromosomes are interchanged from that position onwards.
For example, if two chromosomes [2 4 3 1 51 and [5
3 2 4 11 are chosen and the position is 3, the resultant
chromosomes are [2 4 2 4 11 and [5 3 3 1 51.
If the same procedure is repeated with two positions and the values are changed in the interval, it is
called two point crossover. If the two positions are 1
and 4, the two point crossover results in new chromosomes [5 3 2 4 51 and [2 4 3 1 11. If we pick one
chromosome
randomly and choose two positions
randomly and invert the values between this positions, it becomes inversion. If we take our first
chromosome and the positions are 1 and 4, then
inversion results in the chromosome [l 3 4 2 51.
Mutation is a random interchange of values in two
positions. Mutation for the previous situation will
result in [l 4 3 2 51.
In the genetic algorithm, the randomly generated
string of dispatching rules has a length of 10. This is
found to give better results than the solutions obtained using the dispatching rules individually. This
is possible because the GA considers several such
random strings and also performs genetic operations
to change the order of appearance of the rules in
each string.
In our algorithm, mutation is used 2% of the
times, single point crossover 30% of the times, two
point crossover 40% of the times and inversion 28%
of the times. This setting is found to give good

Computers in Industry 31 (19%) 155-160

results. In general, GA is found to give good results


when crossover operations are used more times than
mutation and inversion. Mutation is to be kept to a
minimum since it does the role of pairwise interchange in our algorithm.
From the mating pool an off spring is created
using these operators and accepted into the next
population if the fitness value is less than the mean
of the previous population. All populations are created with 50 chromosomes. From the new population, off springs are created and the procedure is
repeated till either 30 generations are completed or if
the population repeats again. The best solution which
is periodically updated is accepted from the algorithm.

5. Results
The solution using the proposed genetic algorithm
(GA) to minimize makespan is shown in Table 1.
Here, solutions using the seven individual dispatching rules are also shown for comparison. The due
dates are taken to be twice the processing times after
discussions with the management
of the organization.
Table 1 shows the makespan for completing a
single batch of 1000 items using the seven rules
individually
and using the proposed GA. It can be
seen that there is an improvement of about 39% over
the EDD rule (poorest performing among the seven
rules considered) and an improvement of about 3%
over the best of the individual rules (SPT). There is
an improvement of about 37.5% over the result given
by the Dynamic Slack rule, which the organization

Table 1
Performance

of various rules and the genetic algorithm

Rule

Makespan

CPU-time

SPT
TPT
RPT
DS
EDD
RS
FIFO
GA

98003
131688
131688
131688
133713
120672
111161
95758

3.32
3.28
3.34
3.68
3.21
3.10
3.32
998.00

(seconds)

N.S. Hemnt Kumar, G. Sriniuasan/ Computers in Industry 31 (1996) 155-160


Table 2
Batch sizes for producing

2000 items

Rule

Makespan

Batch size (number)

SPT
TPT
RPT
DS
EDD
RS
FIFO
GA

1568048
2107010
2107010
2107010
2139408
1930752
1778576
1532128

143
154
154
154
118
125
134
143

(14)
(13)
(13)
(13)
(17)
(16)
(15)
(14)

currently follows. The CPU times for these are also


shown in Table 1. It is seen that the GA takes a
considerable amount of time as expected. However,
considering the improvement in the solutions and the
availability of conrputers, it may be worthwhile to
spend on increased computing time.
The time taken to produce 2000 items in batches
of 1 to 20 are found. From this, the best batch size
that minimizes
makespan
and the corresponding
number of batches are found. These are shown in
Table 2 for the seven dispatching rules used individually and for the proposed genetic algorithm. The
batch size and the number of batches (shown in
brackets) to complete 2000 items of the final product
are shown.
The same problem is solved for multiple objectives of minimizing makespan, minimizing tardiness
and minimizing the number of tardy jobs. Here, the
fitness function is taken to be the product of the
values of the three objectives. The results are shown
in Table 3. For the seven individual rules, the three
objectives are evaluated and reported. Two solutions

Table 3
Solutions using various rules and the genetic algorithm
ple objectives
_
_

for multi-

Rule

Makespar

Tardiness

Number of tardy jobs

SPT
TPT
RPT
DS
EDD
RANDOM
FIFO
GA
GA

98003
131688
131688
131688
133713
120672
111161
125842
120856

1040947
889999
846120
889999
954005
1523430
1573501
888340
872315

63
63
58
63
66
68
71
58
61

159

are reported using the genetic algorithm. Both of


these have the same product of the values of the
three objectives.
If we consider only minimizing
the number of
tardy jobs, one of the GA solutions has 58 jobs as
against the value of 63 given by the Dynamic Slack
rule which the organization is currently following.
The RPT rule results in the same number of tardy
jobs but has an increased makespan compared to
both the GA solutions. The only instance where the
proposed algorithm performs inferior to a single
dispatching rule is when the tardiness values are
compared to the solution using RPT. However, the
GA solution has a better makespan than the RPT
solution and the product of the values of the three
performance measures is lower for the solution using
the proposed algorithm than for the solution using
the RPT rule. If the genetic algorithm is used only to
minimize tardiness, it is possible to obtain better
values of minimum tardiness than what is obtained
in the solution for the multiple objective case. The
individual dispatching rules are unable to provide
good solutions when all the three objectives are
combined because they are invariably aimed at optimizing a single objective, while the GA which attempts to optimize the three objectives together provides better solutions.

6. Conclusions
In this paper we addressed the important problem
of job shop scheduling for a real-life situation using
genetic algorithms. The approach uses different dispatching rules from a set of seven rules, for different
situations and improves the solution using a genetic
algorithm.
Results indicate that for the problem situation
considered, the concept of using different dispatching rules for different situations in a genetic algorithm yields better results than using a single dispatching rule. The proposed algorithm yields an
improvement of about 37.5% in makespan over the
existing rule and an improvement
of 3% over the
best among the seven rules. The superior results
obtained using the algorithm have been communicated to the organization and the algorithm is being
considered for implementation.

160

N.S. Hemant Kumar, G. Sriniuasan/Computers

A very obvious conclusion is that by changing the


current dispatching rule from slack to SPT, the organization
can obtain significant
improvement
in
makespan. Though the proposed algorithm is little
complicated for the factory managers compared to
using simple dispatching rules, the superiority of the
results and the use of recent sophisticated tools such
as genetic algorithms are expected to facilitate implementation
of the results of the proposed aIgorithm.
The proposed algorithm uses seven popular dispatching rules and chooses from these. It may be
possible to get better results by increasing the set of
dispatching rules and by including combination rules
such as slack/NOP,
SPT/RPT, etc. Further research
can include considering a combination of Simulated
Annealing and dispatching rules which can be compared to the proposed genetic algorithm and dispatching rules. Further research can concentrate on
using consistently different dispatching rules for different machines and improve the solutions using a
genetic algorithm.

Acknowledgements
The authors are grateful to the reviewers for their
comments which have improved the presentation and
contents of the paper considerably.

References
[ll B.J. Lagewag, J.K. Lenstra and A.H.G. Rinnooy Kan, Job
shop scheduling by implicit enumeration,
Management Science, Vol. 24, 1977, pp. 441-450.
[2] K.R. Baker, Introduction to Sequencing and Scheduling,
Wiley, New York, 1974.
[3] J.H. Blackstone, D.T. Phillips and G.L. Hogg, A state of
the art survey of dispatching rules for manufacturing
job
shop operations,
International Journal of Production Research, Vol. 20, 1982, pp. 27-45.
[4] R.H. Storer, S.D. Wu and R. Vaccari, New search spaces
for sequencing problems with applications
to job shop,
Management Science, Vol. 38, 1992, pp. 1495-1509.

in Industry 31 (1996) 155-160

[5] P.J.M. Van Laarhoven, E.H.L. Aarts and J.K. Lenstra, Job
shop scheduling by simulated annealing,
Operations Research, 1992, pp. 113-126.
[6] M. Gen, Y. Tsujimora and E. Kuhota, Solving the job shop
scheduling problem using genetic algorithms,
Proceedings
of the I6 Conference of Computers and Industrial Engineering, 1994.
[7] J.E. Biegel and J.J. Davern, Genetic algorithms and job
shop scheduling,
Computers and Industrial Engineering,
1990, pp. 81-91.
IS] M.C. Gupta, Y.P. Gupta and Anup Kumar, Minimizing
flow time variance in a single machine system using genetic
European Journal of Operational Research,
algorithms,
1993, pp. 289-303.
[9] J. Sridhar and C. Rajendran, Scheduling
in flow shop and
cellular manufacturing
systems with multiple objectives - A
genetic algorithmic
approach,
to appear in Production
Planning and Control.
[lo] J.F Muth and G.L. Thompson, industrial Scheduling, Prentice Hall, Englewood Cliffs, New Jersey, 1963.
[l 11 D.E. Goldberg, Genetic Algorithms in Search Optimization
and Machine Learning, Addison Wesley Reading, 1989.

N.S. Hemant
Kumar
is currently a
Doctoral Student in Management at the
University of Texas at Austin. He has a
Bachelors degree in Aerospace Engineering and a Masters degree in Matagement from the Indian Institute of
Technology, Madras, India. His research
interests are in the areas of scheduling
and management of manufacturing
systems.

G. Srinivasan is an Assistant Professor


of Industrial Engineering and Management at the Indian Institute of Technology, Madras, India. He has a Bachelors
degree in Mechanical Engineering from
Anna University,
Madras, India followed by a Masters degree and a Ph.D.
from the Indian Institute of Technology,
Madras. He has six years of teaching
and research experience in operations
management,
operations
research and
cellular manufacturing.
He has published in the International Journal of Production Research and
Computers and Industrial Engineering. He is also a referee for
research in cellular manufacturing for these journals.

S-ar putea să vă placă și