Flow Shops and Flexible Flow Shops (Deterministic)
6.2 Flow Shops with Limited Intermediate Storage
proceed to the next machine if that machine is busy; the job must remain on the first machine, which thus cannot start any processing of subsequent jobs.
As stated before, this phenomenon is referred to asblocking.
In what follows only flow shops with zero intermediate storages are consid- ered, since any flow shop with positive (but finite) intermediate storages between machines can be modeled as a flow shop with zero intermediate storages. This follows fromthe fact that a storage space capable of containing one job may be regarded as a machine on which the processing times of all jobs are equal to zero.
The problem of minimizing the makespan in a flow shop with zero interme- diate storages is referred to in what follows asF m|block|Cmax.
LetDijdenote the time that jobjactually departs machinei. Clearly,Dij ≥ Cij. Equality holds when jobjis not blocked. The time jobjstarts its processing at the first machine is denoted byD0j. The following recursive relationships hold under sequencej1, . . . , jn.
Di,j1 = i l=1
pl,j1
Di,jk= m ax(Di−1,jk+pi,jk, Di+1,jk−1) Dm,jk=Dm−1,jk+pm,jk
For this model the makespan under a given permutation schedule can also be computed by determining the critical path in a directed graph. In this directed graph node (i, jk) denotes the departure time of job jk frommachine i. In contrast to the graph in Section 6.1 for flow shops with unlimited intermediate storages, in this graph the arcs, rather than the nodes, have weights. Node (i, jk),i= 1, . . . , m−1; k= 1, . . . , n−1,has two outgoing arcs; one arc goes to node (i+ 1, jk) and has a weight or distance pi+1,jk, the other arc goes to node (i−1, jk+1) and has weight zero. Node (m, jk) has only one outgoing arc to node (m−1, jk+1) with zero weight. Node (i, jn) has only one outgoing arc to node (i+ 1, jn) with weightpi+1,jn. Node (m, jn) has no outgoing arcs (see Figure 6.6). TheCmax under sequence j1, . . . , jn is equal to the length of the maximumweight path fromnode (0, j1) to node (m, jn).
Example 6.2.1 (Graph Representation of Flow Shop with Blocking) Consider the instance of Example 6.1.1. Assume that the same 5 jobs with the same processing times have to traverse the same four machines. The only difference is that now there is zero intermediate storage between the machines. The directed graph and the Gantt chart corresponding to this situation is depicted in Figure 6.7. There is now only one critical path that
determines the makespan of 35. ||
6.2 Flow Shops with Limited Intermediate Storage 165
0,jn
m,jn p1,
jn
pm,
jn
pi + 1,j
k
pi,j
k + 1
i+1,jk i,jk
i—1, jk+1
m,j1 0,j1 0
0
0
0 1,j1
0,j2
1,j2 p1,j
1
p2,j
1
p1,j
2
Fig. 6.6Directed graph for the computation of the makespan
The following lemma shows that the reversibility property extends to flow shops with zero intermediate storage. Consider twommachine flow shops with blocking and letp(1)ij andp(2)ij denote the processing times of jobj on machine iin the first and second flow shop respectively.
Lemma 6.2.2. If
p(1)ij =p(2)m+1−i,j
then sequencej1, . . . , jn in the first flow shop results in the same makespan as sequencejn, . . . , j1 in the second flow shop.
Proof. It can be shown that there is a one-to-one correspondence between paths of equal weight in the two directed graphs corresponding to the two flow shops.
This implies that the paths with maximal weights in the two directed graphs
must have the same total weight.
This reversibility result is similar to the result in Lemma 6.1.2. Actually, one can argue that the result in Lemma 6.1.2 is a special case of the result in Lemma 6.2.2. The unlimited intermediate storages can be regarded as sets of machines on which all processing is equal to zero.
Consider theF2|block|Cmaxproblemwith two machines in series and zero intermediate storage in between. Note that in this flow shop, whenever a job starts its processing on the first machine, the preceding job starts its processing on the second machine. The time job jk spends on machine 1, in process or blocked, is therefore max(p1,jk, p2,jk−1). The first job in the sequence spends onlyp1,jk on machine 1. This makespan minimization problem is equivalent to a Travelling Salesman Problem withn+ 1 cities. Let the distance fromcity j
0 0 0 0
0 0 0 0
0 0 0 0
0 0 0 0
5
4
4
3
5
4
4
6 3
2
3
3
6
4
4
2 3
4
1
5
0 10 20 30
3 6 3 2 5
4 4 3 4 1
4 4 2 4 4
5 5 3 6 3
Fig. 6.7Directed graph, critical path and Gantt chart (the numerical entries represent the processing times of the jobs and not the job
indexes)
to citykbe equal to
d0k =p1k
dj0=p2j
djk= m ax(p2j, p1k)
The total distance travelled is then equal to the makespan of the flow shop.
Actually, the distance matrix can be simplified somewhat. Instead of minimizing the makespan, one can minimize the total time between 0 andCmax that one of the two machines is either idle or blocked. The two objectives are equivalent since twice the makespan is equal to the sum of the 2nprocessing times plus
6.2 Flow Shops with Limited Intermediate Storage 167 the sum of all idle times. Minimizing the sum of all idle times is equivalent to the following Travelling Salesman Problem withn+ 1 cities:
d0k =p1k
dj0 =p2j
djk =||p2j−p1k||
The idle time on one of the machines, when job j starts on machine 2 and job k starts on machine 1, is the difference between the processing times p2j
andp1k. Ifp2j is larger thanp1k job kwill be blocked for the time difference on machine 1, otherwise machine 2 will remain idle for the time difference.
The distance matrix of this Travelling Salesman Problem is identical to the one discussed in Section 4.5. The values for b0 and a0 in Section 4.5 have to be chosen equal to zero.
The algorithmfor the 1|sjk|Cmaxproblemwithsjk=ak−bjcan now be used forF2|block|Cmax as well, which implies that there exists anO(n2) algorithmforF2|block|Cmax.
Example 6.2.3 (A Two Machine Flow Shop with Blocking and the TSP)
Consider a 4 job instance with processing times jobs 1 2 3 4 p1,j 2 3 3 9 p2,j 8 4 6 2
This translates into a TSP with 5 cities. In the notation of Section 4.5 this instance of the TSP is specified by followingaj andbj values.
cities 0 1 2 3 4 bj 0 2 3 3 9 aj 0 8 4 6 2
Applying Algorithm4.5.5 on this instance results in the tour 0→1→4→ 2 → 3 → 0. Actually, two schedules are optimal for the flow shop with blocking, namely schedule 1,4,2,3 and schedule 1,4,3,2. These are different from the SPT(1)-LPT(2) schedules that are optimal in the case of unlimited buffers. With the same four jobs and unlimited buffers the following three schedules are optimal: 1,3,4,2 ; 1,2,3,4 and 1,3,2,4. ||
The three machine version of this problem cannot be described as a Travelling Salesman Problem and is known to be strongly NP-hard. The proof, however, is rather complicated and therefore omitted.
Certain special cases ofF m|block |Cmax are tractable. Consider the pro- portionate case wherep1j =· · ·=pmj=pj, forj = 1, . . . , m. That is, consider F m|block, pij =pj |Cmax.
Theorem 6.2.4. A schedule is optimal for F m|block, pij =pj |Cmax if and only if it is an SPT-LPT schedule.
Proof. The makespan has to satisfy the inequality Cmax≥
n j=1
pj+ (m−1) max(p1, . . . , pn),
as the R.H.S. is the optimal makespan when there are unlimited buffers between any two successive machines. Clearly, the makespan with limited or no buffers has to be at least as large. It suffices to show that the makespan under any SPT-LPT schedule is equal to the lower bound, while the makespan under any schedule that is not SPT-LPT is strictly larger than the lower bound.
That the makespan under any SPT-LPT schedule is equal to the lower bound can be shown easily. Under the SPT part of the schedule the jobs are never blocked. In other words, each job in this first part of the schedule, once started on the first machine, proceeds through the system without stopping. If in the SPT-LPT schedulej1, . . . , jnjobjk is the job with the longest processing time, then jobjk departs the systemat
Cjk =
k−1
l=1
pjl+m pjk.
The jobs in the LPT part of the sequence, of course, do experience blocking as shorter jobs follow longer jobs. However, it is clear that now, in this part of the schedule, a machine never has to wait for a job. Every time a machine has completed processing a job from the LPT part of the schedule, the next job is ready to start (as shorter jobs follow longer jobs). So, after jobjk has completed its processing on machinem, machinemremains continuously busy until it has completed all the remaining jobs. The makespan under an SPT-LPT schedule is therefore equal to the makespan under an SPT-LPT schedule in the case of unlimited buffers. SPT-LPT schedules therefore have to be optimal.
That SPT-LPT schedules are the only schedules that are optimal can be shown by contradiction. Suppose that another schedule, that is not SPT-LPT, is also optimal. Again, the job with the longest processing time, jobjk, contributes mtimes its processing to the makespan. However, there must be some job, say jobjh, (not the longest job) that is positioned in between two jobs that are both longer. If jobjhappears in the schedule before jobjkit remains on machine 1 for
6.2 Flow Shops with Limited Intermediate Storage 169 an amount of time that is larger than its processing time, since it is blocked by the preceding job on machine 2. So its contribution to the makespan is strictly larger than its processing time, causing the makespan to be strictly larger than the lower bound. If job jh appears in the schedule after job jk, then the jobs following jobjk on machinemare not processed one after another without any idle times in between. After jobjh there is an idle time on machine m as the next job has a processing time that is strictly larger than the processing time
of jobjh.
There exists some similarity between this model and the proportionate flow shop model with unlimited intermediate storage. For the case with blocking it also can be shown that the SPT rule minimizes
Cj.
As with flow shops with unlimited intermediate storage, a fair amount of research has been done in the development of heuristics for the minimization of the makespan in flow shops with limited intermediate storage and blocking. One popular heuristic for F m | block | Cmax is the Profile Fitting (PF) heuristic, which works as follows: one job is selected to go first, possibly according to some scheme, e.g., the job with the smallest sum of processing times. This job, say jobj1, does not encounter any blocking and proceeds smoothly from one machine to the next, generating a profile. The profile is determined by its departure frommachinei. If jobj1 corresponds to jobk, then
Di,j1 = i h=1
ph,j1= i h=1
phk
To determine which job should go second, every remaining unscheduled job is tried out. For each candidate job a computation is carried out to determine the amount of time machines are idle and the amount of time the job is blocked at a machine. The departure epochs of a candidate for the second position, say jobj2, can be computed recursively:
D1,j2 = m ax(D1,j1+p1,j2, D2,j1)
Di,j2 = m ax(Di−1,j2+pi,j2, Di+1,j1), i= 2, . . . , m−1 Dm,j2 = m ax(Dm−1,j2, Dm,j1) +pm,j2
The tim e wasted at m achinei, that is, the time the machine is either idle or blocked, isDi,j2−Di,j1−pi,j2. The sumof these idle and blocked times over all mmachines is then computed. The candidate with the smallest total is selected as the second job.
After selecting the job that fits best as the job for second position, the new profile, i.e., the departure times of this second job from the m machines, is computed and the procedure repeats itself. From the remaining jobs in the set of unscheduled jobs the best fit is again selected and so on.
In this description the goodness of fit of a particular job was measured by the total time wasted on allmmachines. Each machine was considered equally
important. It is intuitive that lost time on a bottleneck machine is worse than lost time on a machine that does not have much processing to do. When mea- suring the total amount of lost time, it may be appropriate to multiply each of these inactive time periods on a given machine by a factor that is proportional to the degree of congestion at that machine. The higher the degree of congestion at a particular machine, the larger the weight. One measure for the degree of congestion of a machine that is easy to calculate is simply the total amount of processing to be done on all the jobs at the machine in question. Experiments have shown that such a weighted version of the PF heuristic works quite well.
Example 6.2.5 (Application of the PF Heuristic)
Consider again 5 jobs and 4 machines. The processing times of the five jobs are in the tables in Examples 6.1.1 and 6.1.6. Assume that there is zero storage in between the successive machines.
Take as the first job the job with the smallest total processing time, i.e., job 3. Apply the unweighted PF heuristic. Each one of the four remaining jobs has to be tried out. If either job 1 or job 2 would go second, the total idle time of the four machines would be 11; if job 4 would go second the total idle time of the four machines would be 15 and if job 5 would be second, the total idle time would be 3. It is clear that job 5 is the best fit. Continuing in this manner the PF heuristic results in the sequence 3,5,1,2,4 with a makespan equal to 32. From the fact that this makespan is equal to the minimum makespan in the case of unlimited intermediate storage, it follows that sequence 3,5,1,2,4 is also optimal in the case of zero intermediate storage.
In order to study the effect of the selection of the first job, consider the application of the PF heuristic after selecting the job with the largest total processing time as the initial job. So job 2 goes first. Application of the unweighted PF heuristic leads to the sequence 2,1,3,5,4 with makespan 35.
This sequence is clearly not optimal. ||
Consider now a flow shop with zero intermediate storage that is subject to different operational procedures. A job, when it goes through the system, is not allowed to wait at any machine. That is, whenever it has completed its processing on one machine the next machine has to be idle, so that the job does not have to wait. In contrast to the blocking case where jobs arepusheddown the line by machines upstream that have completed their processing, in this case the jobs are actuallypulled down the line by machines that have become idle. This constraint is referred to as theno-wait constraint and minimizing the makespan in such a flow shop is referred to as the F m|nwt | Cmax problem. It is easy to see thatF2|block|Cmax is equivalent toF2|nwt|Cmax. However, when there are more than two machines in series the two problems are different. The F m| nwt|Cmax problem, in contrast to the F m|block|Cmax problem, can still be formulated as a Travelling Salesman Problem. The intercity distances
6.3 Flexible Flow Shops with Unlimited Intermediate Storage 171 are
djk= m ax
1≤i≤m
i
h=1
phj−
i−1
h=1
phk
forj, k= 0, . . . , n. When there are more than two machines in series this Trav- elling Salesman Problem is known to be strongly NP-hard.