0% found this document useful (0 votes)
34 views56 pages

Scheduling 1

Uploaded by

Vibh
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
34 views56 pages

Scheduling 1

Uploaded by

Vibh
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 56

SCHEDULING

Production Scheduling
• ‘n’ jobs to be processed – each has setup time, processing time,
and a due date.
• To be completed – each job is to be processed at several machines.
• Sequencing the jobs on the machines to optimize a certain
performance criterion.
List of performance criteria – to be optimized
• Mean flow time – mean time in the shop

• Idle times of machines

• Mean earliness of jobs (Job is completed before its due date – its lateness value
is negative – it is referred as earliness)

• Mean tardiness of jobs (Job is completed after its due date – its lateness value is
positive)

• Mean queue time

• Mean number of jobs in the system

• Percentage of jobs late.


Factors – describe and classify scheduling problem
Number of jobs to be scheduled
• Exact number of jobs to be processed - Time required for each process - Type of
machine needed.
Number of machines in the machine shop
Type of manufacturing facility (flow shop or job shop)
• Flow shop pattern – flow is continuous and jobs require same sequence of
machines.
• Job shop pattern – no common pattern for flow of jobs through the shop.
• From industrial survey – 57% of actual problems are job shop type, compared
with 20% of the flow shop.
• Large portion of sequencing research deals with flow shop problems utilizing
makespan as objective criterion.
• Most industrial problems fall in categories of job shop.
Factors – describe and classify scheduling problem

Manner in which jobs arrive at the facility (static or dynamic)

• Static pattern – n jobs, each of which must be processed by a set of machines.


All n jobs are available for processing at the initiation of the scheduling period,
and no new jobs arrive during the period.

• Dynamic pattern – jobs arrive intermittently according to stochastic process.

Criterion by which scheduling alternatives will be evaluated.

.
Classification of Scheduling
Single machine scheduling
- n jobs with same single operation on each of the jobs.

Flow shop scheduling


- n jobs with m operations on each of the jobs.
- same process sequences.

Job shop scheduling


- n jobs with m operations on each of the jobs.
- process sequences will be different from each other.
Basic data to describe jobs
Processing time (tj)
- Time required to process job j.
- It include both actual processing time and setup time.
Ready time (rj)
- Job j is available for processing.
- difference between arrival time of job and time at job taken
for processing.
Due date (dj)
- time at which job j is to be completed.
Completion time (Cj)
- time at which job j is completed in sequence.
- Performance measures for evaluating schedules are usually
function of job completion time.
Flow time(Fj)
- Amount of time job j spends in the system.
- Indicates the waiting time of jobs in the system.
Fj = cj – rj
Lateness(Lj)
Lj = cj – dj
- measure gives an idea about conformity of the jobs in a
schedule to a given set of due dates of the jobs.
- positive lateness (completed after due date), it is measure of
poor service.
- negative lateness (completed before due date), it is measure
of better service.
Tardiness(Tj)
- fails to meet its due date, or zero, otherwise
- Tj = max {0, Lj}
Makespan

• Total length of the schedule (that is, all the jobs have finished
processing).

• Amount of time, from start to finish for completing a set of


jobs, i.e. the maximum completion time of all jobs.

• The time difference between start and end time of a schedule.

• Completion time of the last job to leave the system.


Measures of Performance
1
• Mean flow time F̅= σ𝑛𝑗=1 Fj
𝑛

1 𝑛
• Mean Tardiness ത
𝑇 = σ𝑗=1 Tj
𝑛

• Maximum flow time Fmax = max {Fj }


1≤𝑗≤𝑛

• Maximum tardiness Tmax = max {Tj }


1≤𝑗≤𝑛

• Number of Tardy jobs NT = σ𝑛𝑗=1 f(Tj)


where, f(Tj) = 1, if Tj > 0, and
f(Tj) = 0, otherwise
Two jobs A and B, are required to be scheduled on 2 m/c, M1
and M2. Each job is processed first on M1, then on M2. The
processing times of these jobs are as follows. Find the
sequence of jobs that minimizes makespan.
Job MC 1 MC 2

A 8 5

B 7 10
Solution

Job A is scheduled first, Makespan – 25 Gantt chart

MC 1 Job A Job B

MC 2 Idle Job A Idle Job B


0 8 Time 13 15 25

Job B is scheduled first, Makespan - 22

MC 1 Job B Job A

MC 2 Idle Job B Job A


0 7 Time 15 17 22
Two jobs A and B processed on M1 and M2. Each job is
processed first on M2, then on M1. The processing times of
these jobs are as follows. Find the sequence of jobs that
minimizes makespan.
Job MC 1 MC 2

A 10 8

B 9 11
Solution

Job A is scheduled first, Makespan – 28 Gantt chart

MC 2 Job A Job B

MC 1 Idle Job A Idle Job B


0 8 Time 18 19 28

Job B is scheduled first, Makespan - 30

MC 2 Job B Job A

MC 1 Idle Job B Job A


0 11 Time 19 20 30
n Jobs, one Machine
• n jobs to be processed by one machine, all jobs go through this
machine.
• Many practical applications – machine, a robot, a manufacturing
cell etc.
• Time required to process a job varies according to job requirement.
• Sequence these jobs – mean flow time (MFT) of jobs is
minimized.
1 𝑛
MFT = σ C
𝑛 𝑖=1 i

Cj – Completion time of job i, n = No. of jobs to be processed.


Given are processing times of 4 jobs on a m/c. Find the
optimal sequence of jobs such that the MFT is minimized.

Job Time (hrs)

J1 7

J2 6

J3 8

J4 5
Assume, sequence A - J1-J2-J3-J4
Job Wi ti Ci
1 0 7 7
MFTsq-A
2 7 6 13 67/4 = 16.75
3 13 8 21
4 21 5 26
41 + 26 67 sequence C –Shortest processing Time(SPT)
sequence B - J2-J3-J1-J4 J4-J2-J1-J3

Job Wi ti Ci Job Wi ti Ci
J2 0 6 6 J4 0 5 5
J3 6 8 14 J2 5 6 11 MFTsq-C
J1 14 7 21 J1 11 7 18 60/4 = 15
J4 21 5 26 J3 18 8 26
41 + 26 67 34 + 26 60

MFTsq-B For single m/c case – SPT guarantees Min. MFT.


67/4 = 16.75
Consider the following single machine scheduling problem. Find
the optimal sequence which will minimize the mean flow time &
also obtain Minimum mean flow time
Job Time (hrs)
1 15
2 4
3 5
4 14
5 8
Jobs Processing Time (PT) Flow Time (FT)
1 15 15
2 4 19 Avg. FT
142/5 = 28.4
3 5 24
4 14 38
5 8 46
142

Jobs PT FT SPT – Shortest PT


Jobs PT FT
Avg. FT = 21.4
2 4 4 1 15 15
3 5 9 4 14 29
5 8 17 5 8 37
4 14 31 3 5 42
1 15 46 LPT – Longest PT 2 4 46
107 Avg. FT = 33.8 169
Earliest Due Date (EDD) rule to minimize Max. Lateness
• Maximum job lateness (Lmax) and Maximum job tardiness are (Tmax)
minimized by EDD sequencing.
• In single machine scheduling problem, sequencing the jobs in increasing
order of due date is known as Earliest Due Date rule.

Problem

Consider the following single machine scheduling problem. Find


sequence which minimize (Max. Lateness Lmax), also determine Lmax
with Optimal Sequence

Job J 1 2 3 4 5 6
PT (tj) 10 8 8 7 12 15
DD (dj) 15 10 12 11 18 25
EDD sequence
Lateness = Completion time – Due Date

Arrange the jobs in increasing


order of due dates

Job PT CT DD Lateness
Job PT CT DD Lateness
2 8 8 10 -2
1 10 10 15 -5
4 7 15 11 4
2 8 18 10 8
3 8 23 12 11
3 8 26 12 14
1 10 33 15 18
4 7 33 11 22
5 12 45 18 27
5 12 45 18 27
6 15 60 25 35 (Max.)
6 15 60 25 35 (Max.)

Lmax of any other non-EDD sequence will not be less than 35


Problem
Suppose that five jobs have processing times and due dates as given below:
Job J A B C D E
PT (tj) 4 7 6 2 3
DD (dj) 15 16 8 21 9

Find the average flow time, tardiness and lateness for each job if they are
processed in
a) order A-B-C-D-E
b) order of Shortest processing Time
c) order in Earliest Due Date
Solution:
a) Jobs processed in the order A-B-C-D-E
Job A B C D E
Processing Time 4 7 6 2 3
Flow time 4 4+7=11 11+6=17 17+2=19 19+3=22
Due Date 15 16 8 21 9
Tardiness 0 0 9 0 13
Lateness -11 -5 9 -2 13
Average Flow time =( 4+11+17+19+22)/5 = 73/5 =14.6
Average Tardiness =(0+0+9+0+13)/5 = 22/5=4.4
Average Lateness = (-11-5+9-2+13)/5 = 4/5= 0.8
(b) Order according to SPT. The sequence will be D-E-A-C-B

Job D E A C B
Processing Time 2 3 4 6 7
Flow time 2 2+3=5 5+4=9 9+6=15 15+7=22
Due Date 21 9 15 8 16
Tardiness 0 0 0 7 6
Lateness -19 -4 -6 7 6

Average Flow time = (2+5+9+15+22)/5= 53/5=10.6


Average Tardiness =(0+0+0+7+6)/5 = 13/5=2.6
Average Lateness = (-19-4-6+7+6)/5 =-16/5=-3.2
(c) Order according to earliest due date is C-E-A-B-D

Job C E A B D
Processing Time 6 3 4 7 2
Flow time 6 6+3=9 9+4=13 13+7=21 21+2=23
Due Date 8 9 15 16 21
Tardiness 0 0 0 5 2
Lateness -2 0 -2 5 2

Average Flow time = (6+9+13+21+23)/5= 72/5=14.4


Average Tardiness =(0+0+0+5+2)/5 = 7/5= 1.4
Average Lateness = (-2+0-2+5+2/5 = 3/5= 0.6
Flow shop scheduling problem
Find out Make Span
Job MC 1 MC 2

1 5 4
2 3 1
3 6 2
4 7 8
Gnatt Chart
Job Sequence: 2-1-4-3 Make span: 25 Idle times on MC 2: 0-3, 4-8, 12-15

MC 1 J2 J1 J4 J3

MC 2 Idle J2 Idle J1 Idle J4 J3


0 3 4 8 12 15 21 23 25
Time
Job Sequence: 3-4-1-2 Make span: 26 Idle times on MC 2: 0-6, 8-13

MC 1 J3 J4 J1 J2

MC 2 Idle J3 Idle J4 J1 J2
0 6 8 13 18 21 25 26
Time
n jobs, Two machines
Johnson’s Algorithm

Step 1. Find the minimum among various ti1 and ti2 .

Step 2a. If the minimum processing time requires machine 1, place the associated
job in the first available position in sequence. Go to step 4.

Step 2b. If the minimum processing time requires machine 2, place the associated
job in the last available position in sequence. Go to step 4.

Step 3. when there is a tie in selecting the minimum processing time, then there may
be three solution.

step 3a. If equal minimum value occur only for machine 1, select the job
with smallest processing time in the corresponding M/C 2 and to be placed in the
first of the sequence.
step 3b. If equal minimum value occur only for machine 2,
select the job with smallest processing time in the corresponding
M/C 1 and to be placed in the last of the sequence.

step 3c. If there are equal minimum values one for each
machine, then place the job of machine 1 first and then job of
machine 2 last in the sequence.

Step 4. Remove the assigned job from consideration and return to


step 1 until all positions in sequence are filled.
Problem

Consider 2 m/c and 6 job flow shop scheduling problem. Using Johnson’s
algorithm, Obtain optimal sequence which will minimize the makespan

Job 1 2 3 4 5 6
MC 1 5 2 13 10 8 12
MC 2 4 3 14 1 9 11
Solution

Stage Unsheduled Jobs Minimum Assignment Partial


tik Sequence
1 1, 2, 3, 4, 5, 6 t42 4 = [6] XXXXX 4
2 1, 2, 3, 5, 6 t21 2 = [1] 2 XXXX 4
3 1, 3, 5, 6 t12 1 = [5] 2X X X1 4
4 3, 5, 6 t51 5 = [2] 2 5X X1 4
5 3, 6 t62 6 = [4] 2 5X 6 1 4
6 3 t31 3 = [3] 2 5 3 6 1 4

The optimal sequence is 2–5–3–6–1–4


Sequence

Jobs Processing Time Idle time


Machine 1 Machine 2 on
Machine 2
Time in Time out Time in Time out
2 0 2 2 5 2
5 2 10 10 19 5
3 10 23 23 37 4
6 23 35 37 48 0
1 35 40 48 52 0
4 40 50 52 53 0

Make span
Johnson's Algorithm
Consider 2 m/c and 8 job flow shop scheduling problem. Obtain optimal sequence
which will minimize the makespan

Job 1 2 3 4 5 6 7 8
MC 1 (Pj1) 5 2 1 7 6 3 7 5
MC 2 (Pj2) 2 6 2 5 6 7 2 1
Optimal Sequence: 3-2-6-5-4-7-1-8

Jobs Processing Time Idle time


Machine 1 Machine 2 on
Machine 2
Time in Time out Time in Time out
3 0 1 1 3 1
2 1 3 3 9 0
6 3 6 9 16 0
5 6 12 16 22 0
4 12 19 22 27 0
7 19 24 27 29 0
1 24 29 29 31 0
8 29 34 34 35 3

Make span
Extension of Johnson’s Rule (n jobs, 3 M/C)
Consider 3 M/C and n jobs flow shop scheduling problem
Job Processing Time
MC 1 MC 2 MC 3
1 t11 t12 t13
2 t21 t22 t23
3 t31 t32 t33
. . . .
. . . .
i ti1 ti2 ti3
. . . .
. . . .
n tn1 tn2 tn3

If any one of the below conditions is satisfied then, we can extend the Johnson’s
algorithm
1) if min ti1 ≥ max ti2
2) if min ti3 ≥ max ti2
Extension of Johnson’s Rule
• Create hypothetical problem with two m/c’s and n jobs as shown in table.
• Objective is to obtain optimal sequence, then makespan is to be determined for
optimal sequence

Job Processing Time


MC A MC B
1 t11 + t12 t12 + t13
2 t21 + t22 t22 + t23
3 t31 + t32 t32 + t33
. . .
. . .
i ti1 + ti2 ti2 + ti3
. . .
. . .
n tn1 + tn2 tn2 + tn3
Johnson’s Algorithm for 3 M/Cs
Consider the following 3 M/Cs and 4 jobs flow shop problem
Job 1 2 3 4
MC 1 (PT) 3 12 8 12
MC 2 (PT) 8 9 6 10
MC 3 (PT) 10 12 13 16

If any one of the below conditions is satisfied then, we can extend the Johnson’s
algorithm
1) if min ti1 ≥ max ti2
2) if min ti3 ≥ max ti2
Condition 2 is satisfied,
Optimal Sequence
Job MC 1 + MC2 MC2 + MC 3
1 11 18
2 21 21
3 14 19
4 22 26
Same procedure of 2 M/C problem is applied here to find optimal sequence
Optimal sequence: Sequence 1: 1-3-4-2
Sequence 2: 1-3-2-4
Job Processing Time (in hour) Idle Idle
Machine 1 Machine 2 Machine 3 Time Time
MC 2 MC 3
in out in out in out
1 0 3 3 11 11 21 3 11
3 3 11 11 17 21 34 0 0
4 11 23 23 33 34 50 6 0
2 23 35 35 44 50 62 2 0

Make span
Similar procedure for sequence 2,
Johnson’s Algorithm for 3 M/Cs
Consider the following 3 M/Cs and 7 jobs flow shop problem
Job 1 2 3 4 5 6 7
MC 1 (PT) 1 3 7 9 4 5 2
MC 2 (PT) 7 3 8 2 8 6 1
MC 3 (PT) 8 10 9 11 9 14 12
If any one of the below conditions is satisfied then, we can extend the Johnson’s
algorithm
Job MC 1 + MC2 MC2 + MC 3
1) if min ti1 ≥ max ti2
2) if min ti3 ≥ max ti2 1 8 15
Condition 2 is satisfied, 2 6 13
Optimal Sequence 3 15 17
4 11 13
5 12 17
6 11 20
7 3 13
Same procedure of 2 M/C problem is applied here to find optimal sequence
Optimal sequence: 7-2-1-4-6-5-3

Job Processing Time (in hour) Idle Idle


Machine 1 Machine 2 Machine 3 Time Time
MC 2 MC 3
in out in out in out
7 0 2 2 3 3 15 2 3
2 2 5 5 8 15 25 2 0
1 5 6 8 15 25 33 0 0
4 6 15 15 17 33 44 0 0
6 15 20 20 26 44 58 3 0
5 20 24 26 34 58 67 0 0
3 24 31 34 42 67 76 0 0

Make span
Problem

Consider 2 m/c and 6 job flow shop scheduling problem. Using Johnson’s
algorithm, Obtain optimal sequence which will minimize the makespan

Job 1 2 3 4 5 6
MC 1 4 2 8 2 9 10
MC 2 1 3 7 6 5 11
Optimal Sequence: 2-4-6-3-5-1

Jobs Processing Time Idle time


Machine 1 Machine 2 on
Machine 2
Time in Time out Time in Time out
2 0 2 2 5 2
4 2 4 5 11 0
6 4 14 14 25 3
3 14 22 25 32 0
5 22 31 32 37 0
1 31 35 37 38 0

Make span
Problem

Consider 2 m/c and 6 job flow shop scheduling problem. Using Johnson’s
algorithm, Obtain optimal sequence which will minimize the makespan

Job 1 2 3 4 5 6
MC 1 3 1 8 5 9 10
MC 2 2 7 4 4 6 11
Optimal Sequence: 2-6-5-3-4-1

Jobs Processing Time Idle time


Machine 1 Machine 2 on
Machine 2
Time in Time out Time in Time out
2 0 1 1 8 1
6 1 11 11 22 3
5 11 20 22 28 0
3 20 28 28 32 0
4 28 33 33 37 1
1 33 36 37 39 0

Make span
CDS Heuristic (n jobs m machines)
• Difficult to get optimal solution in finite time for large size problems.
• Use efficient heuristics for large size problems.
• CDS (Campbell, Dudek and Smith) heuristic is one such heuristic used for flow
shop scheduling.
Stage 1, t1j1 = tj1 and t1j2 = tjm
Johnson’s rule is applied to first and ‘m’th operations and intermediate
operations are ignored.
Stage 2, t2j1 = tj1 + tj2, t2j2 = tjm + tj,m-1
Johnson’s rule is applied to the sum of the first two and the last two
operation processing times. In general at stage i,
tij1 = σ𝒊𝒌=𝟏 𝒕𝒋𝒌 and tij2 = σ𝒊𝒌=𝟏 tj,m−k+1
For each stage i(i=1,2,…, m-1), the job order obtained is used to calculate a
makespan for the original problem. After m-1, stages, the best makespan among the
m-1 schedules is identified. (some of the m-1 sequences may be identical).
Find the makespan using the CDS heuristic for the following flow shop problem
Job j tj1 tj2 tj3 tj4
1 4 3 7 8 Stage 1 Optimal Sequence: 3-2-1-4
2 3 7 2 5
job MC 1 (tj1) MC 2 (tj2)
3 1 2 4 7
1 4 8
4 3 4 3 2
2 3 5
3 1 7
4 3 2

Job Processing Time (in hour)


Machine 1 Machine 2 Machine 3 Machine 4
in out in out in out in out
3 0 1 1 3 3 7 7 14
2 1 4 4 11 11 13 14 19
1 4 8 11 14 14 21 21 29
4 8 11 14 18 21 24 29 31
Stage 2 job MC 1 + MC2 MC 3 + MC 4
1 7 15
2 10 7
3 3 11
4 7 5

Optimal Sequence: 3-1-2-4


Job Processing Time (in hour)
Machine 1 Machine 2 Machine 3 Machine 4
in out in out in out in out
3 0 1 1 3 3 7 7 14
1 1 5 5 8 8 15 15 23
2 5 8 8 15 15 17 23 28
4 8 11 15 19 19 22 28 30
job MC 1 + MC 2 + MC 3 MC 2+ MC 3+ MC 4
Stage 3 1 14 18
Optimal Sequence: 2 12 14
3-2-1-4 3 7 13
4 10 9

Job Processing Time (in hour)


Machine 1 Machine 2 Machine 3 Machine 4
in out in out in out in out
3 0 1 1 3 3 7 7 14
2 1 4 4 11 11 13 14 19
1 4 8 11 14 14 21 21 29
4 8 11 14 18 21 24 29 31
Stage Sequence Makespan
Summary best
1 3-2-1-4 31 sequence
2 3-1-2-4 30
3 3-2-1-4 31
Problem
Suppose that five jobs have processing times and due dates as
given below:

Job J A B C D E
PT (tj) 5 4 2 6 9
DD (dj) 15 7 8 11 13

Find the average flow time, tardiness and lateness for each job if
they are processed in
a) order of Shortest processing Time
b) order in Earliest Due Date
Solution
SPT EDD
➢ Sequence: C-B-A-D-E ➢ Sequence: B-C-D-E-A
➢ Average Flow time : 12.4 ➢ Average Flow time : 13.8
➢ Average Tardiness : 3.8 ➢ Average Tardiness : 4
➢ Average Lateness : 1.6 ➢ Average Lateness : 3
Problem

Consider 2 m/c and 7 job flow shop scheduling problem. Using Johnson’s
algorithm, Obtain optimal sequence which will minimize the makespan.

Job 1 2 3 4 5 6 7
MC 1 6 3 10 5 9 7 4
MC 2 4 2 5 9 5 8 3
Optimal Sequence: 4-6-3-5-1-7-2

Jobs Processing Time Idle time


Machine 1 Machine 2 on
Machine 2
Time in Time out Time in Time out
4 0 5 5 14 5
6 5 12 14 22 0
3 12 22 22 27 0
5 22 31 31 36 4
1 31 37 37 41 1
7 37 41 41 44 0
2 41 44 44 46 0

Make span
Consider the following 3 M/Cs and 7 jobs flow shop problem. Find the
optimal sequence and makespan.

Job 1 2 3 4 5 6 7
MC 1 (PT) 2 4 8 10 5 6 3
MC 2 (PT) 8 4 9 3 9 7 2
MC 3 (PT) 9 11 10 12 10 15 13
If any one of the below conditions is satisfied then, we can extend the
Johnson’s
algorithm
1) if min ti1 ≥ max ti2
2) if min ti3 ≥ max ti2
Condition 2 is satisfied,
Optimal Sequence
Job MC 1 + MC2 MC2 + MC 3
1 10 17
2 8 15
3 17 19
4 13 15
5 14 19
6 13 22
7 5 15
Same procedure of 2 M/C problem is applied here to find optimal sequence
Optimal sequence: 7-2-1-4-6-5-3

Job Processing Time (in hour) Idle Idle


Machine 1 Machine 2 Machine 3 Time Time
MC 2 MC 3
in out in out in out
7 0 3 3 5 5 18 3 5
2 3 7 7 11 18 29 2 0
1 7 9 11 19 29 38 0 0
4 9 19 19 22 38 50 0 0
6 19 25 25 32 50 65 3 0
5 25 30 32 41 65 75 0 0
3 30 38 41 50 75 85 0 0

Make span
Find the Make span using the CDS heuristic for the following flow shop problem.

Job j 𝑇𝑗 1 𝑇𝑗 2 𝑇𝑗 3 𝑇𝑗 4

1 9 3 5 8

2 2 4 3 8

3 5 8 3 9

4 7 7 7 4
Solution
➢ Stage 1 : 2-3-1-4
❖ Makespan : 41

➢ Stage 2 : 2-1-3-4
❖ Makespan : 42

➢ Stage 3 : 2-3-4-1
❖ Makespan : 42

You might also like