Using mixed graph coloring to minimize total completion time in job shop scheduling

Using mixed graph coloring to minimize total completion time in job shop scheduling

Applied Mathematics and Computation 182 (2006) 1137–1148 www.elsevier.com/locate/amc Using mixed graph coloring to minimize total completion time in ...

284KB Sizes 4 Downloads 124 Views

Applied Mathematics and Computation 182 (2006) 1137–1148 www.elsevier.com/locate/amc

Using mixed graph coloring to minimize total completion time in job shop scheduling Fawaz S. Al-Anzi a

a,*

, Yuri N. Sotskov b, Ali Allahverdi c, George V. Andreev

b

Department of Computer Engineering, College of Engineering and Petroleum, Kuwait University, P.O. Box 5969, Safat, Kuwait b United Institute of Informatics Problems, Surganova str. 6, 220012 Minsk, Belarus c Department of Industrial and Management Systems Engineering, College of Engineering and Petroleum, Kuwait University, P.O. Box 5969, Safat, Kuwait

Abstract The problem of scheduling a set of jobs with unit operation times in a job shop to minimize total completion time is addressed. It is shown that this problem can be modeled as finding the optimal coloring of a special mixed graph. Subgraph of such a mixed graph without edges represents union of paths, and subgraph without arcs represents union of cliques. Finding the optimal coloring of the mixed graph with the criterion of minimizing the sum of maximal colors (used for the paths) is shown to determine a schedule for minimizing total completion time for processing jobs in a job shop. Since the problem is NP-hard, we develop a branch and bound algorithm for obtaining the optimal coloring of such a mixed graph. We develop a color-based branching scheme, dominance of the vertices in the solution tree, and three lower bounds of the objective function. The computational experiments indicate that the branch and bound algorithm performs well for randomly generated mixed graphs of order up to 200, if all the paths in the directed subgraph (job routes) have the same length, and of order up to 750 otherwise. Since in the considered job shop problem, machine repetition and absence of some machines in the job route are allowed, the developed methodology can be used to minimize total completion time in the job shop with arbitrary integer operation durations.  2006 Elsevier Inc. All rights reserved. Keywords: Scheduling; Job shop; Total completion time; Mixed graph coloring; Branch and bound

1. Introduction We consider the following job shop problem. A set of jobs J = {J1, J2, . . . , Jn} has to be processed by a set of machines M = {M1, M2, . . . , Mm}. At any time, each machine can process no more than one job, and each job can be processed by no more than one machine. Job Ji consists of ri ordered operations ðvLðiÞþ1 ; vLðiÞþ2 ; . . . ; Pi1 vLðiÞþri Þ where LðiÞ ¼ k¼0 rk and r0 = 0. For a job Jk, let i = L(k) + l where machine M ki has to process *

Corresponding author. E-mail addresses: [email protected] (F.S. Al-Anzi), [email protected] (Y.N. Sotskov), [email protected]. edu.kw (A. Allahverdi), [email protected] (G.V. Andreev). 0096-3003/$ - see front matter  2006 Elsevier Inc. All rights reserved. doi:10.1016/j.amc.2006.04.063

1138

F.S. Al-Anzi et al. / Applied Mathematics and Computation 182 (2006) 1137–1148

operation vi. In a technological route of ðM kLðkÞþ1 ; M kLðkÞþ2 ; . . . ; M kLðkÞþrk Þ that is used for processing job Jk 2 J, a given machine may be used more than once or not used at all. Duration of each operation vi, i 2 {1, 2, . . . , L(n + 1)}, is equal to one unit, and preemption of each operation is not allowed. As a result, for each operation vi the following equality must hold: ci = si + 1 where si and ci denote starting and completion times of operation vi, respectively. P Let UðC 1 ; C 2 ; . . . ; C n Þ ¼ ni¼1 C i where Ci means completion time of job Ji: C i ¼ cLðiÞþri . The scheduling problem under consideration is to construct an optimal schedule for processing the jobs in the set J by machinesPin the set M to minimize U(C1, C2, . . . , Cn). This problem can be described by the notation Jjpi ¼ 1j P C i when jobs may have different technological routes (a job shop problem), and by the notation F jpi ¼ 1j C i when technological routes of all the jobs are identical and each machine Mk 2 M is used in the technological route exactly once (a flow shop P problem). It is known that the problem F jpi 2 f0; 1gj C i is NP-hard, see [4]. The notation pi 2 {0, 1} means the operation duration can be equal to either zero or one unit, provided that zero duration of operation P vi , i = L(k) + l, means that machine M ki 2 MPdoes not process job Jk 2 J at all. The problem J jp ¼ 1j C i is i P NP-hard since the problem F jpi 2 f0; 1gj C i is a special case of the problem J jpi ¼ 1j C i . Kubiak and Timkovsky [7] considered the unit time job shop scheduling problem to minimize total completion time. They considered the case of two machines and proposed an efficient algorithm to solve this special case of the problem. Timkovsky [13] considered the same problem with a general case of m machines. He discussed the complexities of the problem with respect to different criteria including total completion time. Both problems of Jjn = 2jU and Jjn = 2, PrjU with two jobs are polynomially solvable for any non-decreasing objective function U = U(C1, C2, . . . , Cn), see [9]. Hereafter, the symbol Pr means operation preemption is P allowed. Sotskov and Shakhlevich [11] and Brucker et al.P [2] proved that both problem J 3jn ¼ 3j C i (with three machines and three jobs) and problem J 2jn ¼ 3; Prj C i (with two machines and three jobs) are binary NP-hard. The above results on NP-hardness of scheduling problems have been proven with the usual assumption that P all the operation durations are integers. Therefore, NP-hardness proof of the problem P J 2jn ¼ 3; Prj C i with integer operation durations implies NP-hardness of the problem J 2jn ¼ 3; p ¼ 1j C i due i P to their equivalence. Thus, to obtain exact solution to the problem Jmjn ¼ no ; pi ¼ 1j C i with large numbers m P 2 or/and no P 3 we need to use some kind of an implicit enumeration technique, e.g., a branch and bound algorithm. In this paper, we show that job shop scheduling problem of unit time operations with total completion time criterion can be modeled as finding the optimal coloring of a mixed graph. The problem of coloring of a mixed graph has been studied by Hansen et al. [5] and Sotskov et al. [10,12]. The problem Jjpi = 1jCmax with makespan minimization Cmax = max{Ci : Ji 2 J} and unit operation times may be reduced to the problem of coloring vertices of a graph or vertices of a mixed graph in minimum number of colors, i.e., with criterion MINMAX, see [8,3,10,12]. P The rest of this paper is organized as follows. In Section 2, we show that the problem J jpi ¼ 1j C i can be represented as the problem of constructing optimal coloring of a special P mixed graph with criterion MINSUM. A branch and bound algorithm for solving the problem J jp ¼ 1j C i is proposed in Section 3. In Seci P tion 4, three lower bounds on the objective function C i are developed. Computational analysis for randomly generated problems is conducted in Section 5. Concluding remarks are made in Section 6. 2. Reduction of the problem Jjpi ¼ 1j+C i to mixed graph coloring Let G = (V, A, E) be a mixed graph with an non-empty set of vertices V, a set of arcs A, and a set of edges E. N denotes the set of natural numbers. The function u : V ! N is called coloring of mixed graph G, if it assigns a number u(vi) 2 N called a color to each vertex vi 2 V in such a way that arc inclusion (vi, vj) 2 A implies inequality uðvi Þ < uðvj Þ;

ð1Þ

and edge inclusion [vi, vj] 2 E implies uðvi Þ 6¼ uðvj Þ:

ð2Þ

F.S. Al-Anzi et al. / Applied Mathematics and Computation 182 (2006) 1137–1148

1139

Similar to the case of coloring of a graph (V, Ø, E), in the mixed graph coloring problem studied by Hansen et al. [5] and Sotskov et al. [10,12], it was required to construct a coloring of a mixed graph G = (V, A, E), A 5 Ø, E 5 Ø, which contains minimum number of different colors (criterion MINMAX). P Next, we show that the problem of coloring of a mixed graph can be used to solve the problem J jpi ¼ 1j C i of minimizing total completion time of processing n jobs with unit operation times in a job shop with m machines. We consider, however, the criterion MINSUM instead of MINMAX. Note that for graph coloring problems it is possible to use various criteria, P see the survey by Tuza [14]. The problem Jjpi ¼ 1j C i can be formulated as the coloring problem of the mixed graph G = (V, A, E) with vertex set V being the set of operations. An edge set E connects pair-wise operations processed by the same machine, and hence, the following splitting of subgraph (V, Ø, E) of the mixed graph G is obtained: ðV ; Ø; EÞ ¼ ðV 1 ; Ø; E1 Þ [ ðV 2 ; Ø; E2 Þ [    [ ðV m ; Ø; Em Þ;

ð3Þ

where the graph (Vk, Ø, Ek) is a clique with a set of all the operations Vk  V processed by the same machine Mk 2 M. An arc set A determines partial order of operations V. Taking into account that technological route of job Ji 2 J is given as the ordered set Vi of all the operations including in processing job Ji, we obtain the following splitting of subgraph (V, A, Ø) of the mixed graph G: ðV ; A; ØÞ ¼ ðV 1 ; A1 ; ØÞ [ ðV 2 ; A2 ; ØÞ [    [ ðV n ; An ; ØÞ:

ð4Þ

In equality (4), the digraph (Vi, Ai, Ø) is defined as a path ðvLðiÞþ1 ; vLðiÞþ2 ; . . . ; vLðiÞþri Þ, i.e., ordered set of operations. Thus, the following equalities must hold for mixed graph G under consideration: V ¼

n [ i¼1

Vi ¼

m [

V k:

k¼1

since Note that both inclusions [vi, vj] 2 E and (vi, vj) 2 A are possible in the mixed graph G under considerationP machine repetitions in the technological route of a job is allowed in the corresponding problem J jp ¼ 1j Ci. i P Since each operation duration in the problem J jpi ¼ 1j C i is equal to one unit, the coloring u : V ! {1, 2, . . . , t}  N of mixed graph G determines feasible assignment (schedule) of operations V to the following unit time intervals: [0, 1], (1, P2], (2, 3], . . . , (t  1, t]. From conditions (1) and (2), it follows that optimal schedule for the problem J jpi ¼ 1j C i corresponds to such a coloring u of the vertices of mixed graph G for which the value of the objective function n X uðvLðiÞþri Þ ð5Þ i¼1

is minimal. In what follows, the above coloring u of the mixed graph G is called optimal coloring. It is easy to see that the following P one-to-one correspondence between colorings of mixed graph G and schedules to the problem J jpi ¼ 1j C i holds: fvertex vj g $ foperation vj g; fset of vertices V i of path ðV i ; Ai ; ØÞg $ fset of operations V i for processing job J i g; fset of vertices V k of clique ðV k ; Ø; Ek Þg $ fset operations V k processed by the same machine M k g; fcoloring ug $ fschedule ug;     n n P P objective function uðvLðiÞþri Þ $ objective function Ci ; i¼1

i¼1

foptimal coloringg $ foptimal scheduleg: Due to the above association, one can use both graph terminology (which is more common in OR literature) and scheduling terminology for the problem under consideration. Sotskov [9] has shown that both problems Jjn = 2jU and Jjn = 2, PrjU can be solved via construction of a digraph in coordinate system on a plane and looking for the shortest path in the constructed digraph. The basic idea of such geometrical algorithms (see [1,6] for the case U = Cmax) consists of processing both jobs

1140

F.S. Al-Anzi et al. / Applied Mathematics and Computation 182 (2006) 1137–1148

in parallel whenever possible. In the following sections, the same idea is used for the case n > 2 when geometrical representation of job processing is not as efficient as for the case n = 2. 3. Branch and bound algorithm In thisPsection, we develop a branch and bound algorithm, called MINSUM, for solving the problem Jjpi ¼ 1j C i via optimal coloring of a mixed graph G = (V, A, E) provided that both properties (3) and (4) hold. The algorithm MINSUM is based on the lower bounds of value (5), dominance rule, and the color-based branching procedure for resolution conflicts arising when the same color tends to be assigned to adjacent vertices in the graph (V, Ø, E). A solution tree has to be constructed in order to implicitly enumerate feasible colorings u of the mixed graph G. To avoid redundant formalities P in our description of algorithm MINSUM, we use the following example of the problem J 5jpi ¼ 1; n ¼ 3j C i with five machines and three jobs. P The mixed graph corresponding to the problem J 5jpi ¼ 1; n ¼ 3j C i is given in Fig. 1, where an edge [vi, vj] is not shown if there exists a path from vertex vi to vertex vj in the digraph (V, A, Ø), i.e., if both inclusions vi 2 Vk and vj 2 Vk hold. It is easy to see that such an edge is redundant while coloring mixed graph G. The routes of jobs J1, J2 and J3, respectively, are given as follows: (M1, M2, M3, M4, M2, M2, M5), (M2, M1, M2, M4, M3, M5, M5) and (M3,M1, M4, M3, M5). In Fig. 1, vertices of set V are represented as squares, notations of vertices vi 2 V being indicated under the corresponding square. The route of job J1 (i.e., the order of machines for processing operations V1 of job J1) is indicated above the squares corresponding to the operations for processing job J1. The pictures of all the operations of set Vk (i.e., operations processed by machine Mk) have an identical figure inside the corresponding squares applicable to them. We use the color-based branching when at each step of the algorithm the same color c is assigned to as many vertices as possible. At the next step for the same branch of the solution tree, color c + 1 is assigned to as many vertices as possible, and so on. P Solution tree T = (W, R, Ø) constructed via algorithm MINSUM for the example J5jpi = 1, n = 3j Ci under consideration is shown in Fig. 2. Each vertex w(i) 2 W of the solution tree represents an integer n-dimensional vector determining state of the coloring process as follows: 0 ðiÞ 1 w1 B ðiÞ C Bw C 2 C: wðiÞ ¼ B C B @... A wðiÞ n ðiÞ

The first component w1 of vector w(i) corresponds to the color used for operation of job J1 which may be ðiÞ colored at this iteration, the second component w2 to the color used for operation of job J2, and so on, the last component wðiÞ n corresponds to the color used for operation of job Jn. We call the iteration of algorithm

Fig. 1. Mixed graph G corresponding to the example J 5jpi ¼ 1; n ¼ 3j

P

Ci .

F.S. Al-Anzi et al. / Applied Mathematics and Computation 182 (2006) 1137–1148

Color:

1

2

3

4

5

6

1141

7

8

9

w(8)

w(10)

w(11)

7 -6 7

8 6 8

9 7 9

w(2)

w(0)

w(1)

0 0 0

1 1 1 19, 20

2 2 -2 20, 21 w(3)

w(4)

w(5)

w(6)

W(7)

2 -2 2

3 2 3

4 3 4

5 4 5

6 5 6

20, 21

20, 21

20, 21

20, 21

21, 21

21, 21

21, 21

21, 21

w(9)

-7 6 7 22, 22

Fig. 2. Solution tree T = (W, R, Ø) constructed for the example J 5jpi ¼ 1; n ¼ 3j

P

Ci .

MINSUM the process of vertex construction in solution tree T = (W, R, Ø). Let iteration number coincide with index i of vector w(i) 2 W. Zero iteration of the algorithm MINSUM corresponds to vector w(0) (see Fig. 2) which indicates that no vertex of mixed graph G is colored at zero (initial) iteration. At zero iteration, all possible operations from the set {vL(1)+1, vL(2)+1, . . . , vL(n)+1} have to be colored in color 1 provided that both conditions (1) and (2) hold. In particular, at zero iteration while solving the example, color 1 has to be assigned to all three possible vertices vL(1)+1, vL(2)+1 and vL(3)+1 where u(vL(1)+1) = u(vL(2)+1) = u(vL(3)+1) = 1, which are the first operations of jobs J1, J2 and J3, respectively. This is possible since no edge connects any two vertices of the three. ðiÞ In general, at the ith iteration of algorithm MINSUM, component wk of vector w(i) is assumed to be equal either to index q of operation vL(k)+q in the sequence of operations ðvLðkÞþ1 ; . . . ; vLðkÞþq ; . . . ; vLðkÞþrk Þ of job Jk (if vertex vL(k)+q is colored with color c used at the ith iteration), or it is assumed to be equal to –q (if vertex vL(k)+q is not colored at the ith iteration, i.e., color c is omitted for vertex vL(k)+q, and therefore, a color grater than c has to be used for coloring vertex vL(k)+q at one of the iterations that follows. The latter situation holds, if at the ith iteration, another vertex vL(t)+u 2 V is colored with color c, and the inclusion [vL(k)+q, vL(t)+u] 2 E holds. P At the second iteration of the algorithm MINSUM used for the example J 5 j pi ¼ 1; n ¼ 3 j C i , there exists a conflict since two vertices vL(2)+2 and vL(3)+2 which are in turn to be colored by color 1 are joined by the edge [vL(2)+2, vL(3)+2] 2 E. As a result of conflict resolution, two vertices in the solution tree have to be constructed (instead of constructing only one vertex in the solution tree, if there is no such a conflict), which are defined by the following two vectors: 0 1 0 1 2 2 B C B C wð2Þ ¼ @ 2 A; wð3Þ ¼ @ 2 A: 2 2 ð2Þ

ð3Þ

The equality w3 ¼ 2 (equality w2 ¼ 2) indicates that in the coloring state defined by the vector w(2) (vector w(3)) vertex vL(3)+2 (vertex vL(2)+2) of job J3 (job J2) is not colored by color 2 at the second iteration, i.e., color 2 is omitted for this vertex, and hence, a color greater than 2 has to be assigned to this vertex at one of the iterations that follows. At any iteration of the algorithm MINSUM, exactly one color can be used for coloring vertices, which are the first in turn for the jobs from the set J. For the given example, colors used at the current iteration are indicated in the top of Fig. 2. Each arc (w(i), w(s)) of the solution tree T = (W, R, Ø) transfers state w(i) of coloring vertices by color c-1 to state w(s) of coloring vertices (which are in turn) by color c. The number of arcs in the set R starting from vertex w(i) 2 W is equal to the product of k numbers of vertices from the same set Vk, which are in turn for coloring in color c  1. Each arc (w(i), w(s)) in solution tree T defines a variant for conflict resolution since condition (2) cannot be violated.

1142

F.S. Al-Anzi et al. / Applied Mathematics and Computation 182 (2006) 1137–1148

Vertex w(s) of the solution tree O is pendent if either it determines coloring of all the vertices of mixed graph G, or there exists vertex w(u), u < s, in the solution tree O which dominates vertex w(s), or the largest lower bound of the value (5) among lower bounds to be described in Section 4 is not less than the upper bound of value (5) already reached at the current iteration of the algorithm MINSUM. Color-based branching allows using the following dominance rule: Vertex w(u), u < s, of the solution tree O ðuÞ ðsÞ dominates vertex w(s) if inequality wi P wi holds for each index i 2 {1, 2, . . . , n}, and c 6 c 0 where color c 0 (color c respectively) is used for generating state of the coloring process defined by vertex w(u) (by vertex w(s)). 4. Lower bounds on the objective function In the algorithm MINSUM, three lower bounds on the value of the objective function (5) have been tested: one local lower bound, represented as LB0 (which uses only local data available at the current vertex of the solution tree), and two global lower bounds represented by LB1 and LB2. Calculation of the latter bounds needs ‘‘global data’’, i.e., data located outside the current vertex of the solution tree. If coloring process is in the state determined by vector w(j), then for coloring all the vertices from the set Vi, it is required to use no less than ri þ lji different colors, where lji means the number of colors which were omitted for some vertices from set Vi during coloring process finished at the state determined by vector w(j) inclusively. Therefore, at the coloring state determined by vector w(j), one can use the following sum as a local lower bound of value (5): LB0 ¼

n X

ðri þ lji Þ:

ð6Þ

i¼1

It is worth noting that only local data are needed for calculation of the lower bound LB0. Indeed, it is sufficient to know only vector w(j) determining the current state of coloring process and the given vector (r1, r2, . . . , rn) of the lengths of job routes. Therefore, calculation of the local lower bound LB0 can be performed very fast, and therefore, the lower bound LB0 is used in both versions of the algorithm MINSUM. On the other hand, calculation of the global lower bounds LB1 and LB2 is more time-consuming since it requires data retrieval in different vertices of a solution tree. Next, we demonstrate the validity of the lower bound LB1 if there is machine Mk 2 M that processes each job Ji 2 J exactly once. In other words, it is assumed that for each job Ji 2 J, the following equality holds: \ ð7Þ V i V k ¼ fvLðiÞþj g; where M iLðiÞþj ¼ M k . Let hmin ¼ minJ i 2J fj  1 : M iLðiÞþj ¼ M k g; tmin ¼ minJ i 2J fri  j : M iLðiÞþj ¼ M k g where the value hmin (tmin) means the length of the minimum path in digraph (V, A, Ø) finishing (starting) in a vertex from the set Vk. Since each machine can process no more than one operation in any time interval (t  1, t], the operations of the set Vk processed by machine Mk should be linearly ordered in order to be processed. Therefore, sum of colors used for coloring all the vertices Vk should be greater or equal to the fraction nðnþ1Þ . Accordingly, 2 sum of the colors used for all the vertices from the set V should be greater than or equal to LB1ðkÞ ¼ nhmin þ nðnþ1Þ þ ntmin . As a result, we obtain the following lower bound on the objective function value (5): 2 n X i¼1

uðvLðiÞþri Þ P LB1ðkÞ ¼ nhmin þ

nðn þ 1Þ þ ntmin : 2

ð8Þ

If the condition (7) does not hold, an analytical expression for the lower bound LB1(k) can be obtained as a result of the following modification of formula (8). Let J(Mk) denote a set of jobs fJ i1 ; J i2 ; . . . ; J iri g  J such that for each job from this set, the following conditions hold: V itP \ V k 6¼ Ø, t 2 {1, 2, . . . , s}. Obviously, if there exists only one machine Mk, the value of the objective function C i is minimal P when jobs from the set J(Mk) are processed in non-increasing order of numbers of operations per job. Let J i 2J ðM k Þ C i denote the objective function value (5) defined for processing jobs J(Mk) in this order. Therefore, in general, instead of (8) we obtain the following lower bound LB1(k):

F.S. Al-Anzi et al. / Applied Mathematics and Computation 182 (2006) 1137–1148

X

LB1ðkÞ ¼ shmin þ

C i þ stmin þ

J i 2J ðM k Þ

X

rj :

1143

ð9Þ

J j 2J nJ ðM k Þ

The values hmin and tmin , in equality (9), can be computed as follows: hmin ¼ min fj  1 : vLðiÞþj 2 V i \ V k ; M iLðiÞþj ¼ M k g; J i 2J ðM k Þ

tmin

¼ min fri  j : vLðiÞþj 2 V i \ V k ; M iLðiÞþj ¼ M k g: J i 2J ðM k Þ

Let the greatest lower bound LB1(k) calculated among all the machines Mk 2 M be called as lower bound LB1. The lower bounds (8) and (9) may be tight for the first iteration of the algorithm MINSUM, while at the ith iteration of the algorithm with i > 1, the lower bound LB1(k) can be improved (since some vertices from set Vk are already colored, and hence, hmin may increase). Moreover, the order of jobs J(Mk) may differ from non-increasing order of numbers of operations per job on machine Mk. The global lower bound LB2 may be obtained as the following generalization of local lower bound LB0. Let n(c) denote the greatest possible number of jobs which operations can be colored by color c during realization of the algorithm MINSUM. In particular, we obtain n(1) = n. At the subsequent iterations, the value n(c) can become less than n (if all the vertices of one job or several jobs will be colored by colors smaller than c). Also, let m(c) denote the number of machines required for processing operations within time interval (c  1, c] and operations omitted while some vertices were colored at the previous iterations of the algorithm MINSUM. It is clear that the value m(c) can be determined on the basis of the corresponding vector w(i). In particular, m(1) is equal to the number of machines required for processing operations from the set {vL(1)+1, vL(2)+1, . . . , vL(n)+1}. If at the first iteration of the algorithm MINSUM (while coloring vertices by color 1), m(1) machines are required, then in the lower bound n X i¼1

uðvLðiÞþri Þ P

n X

ð10Þ

ri

i¼1

it is possible to add to the right-hand side of the inequality (10) the difference n(1)  m(1) since at any interval (t  1, t] each machine can process no more than one operation. Accordingly, while coloring vertices in color 2, it is possible to add the value max{0, n(2)  m(2)} to the right-hand side of the inequality (10). And in general, for coloring vertices by color c, one can add the value max{0, n(c)  m(c)} to the right-hand side of the inequality (10). As a result, we obtain the following lower bound: n X

uðvLðiÞþri Þ P LB2 ¼

i¼1

n X i¼1

ri þ

r X

maxf0; nðjÞ  mðjÞg;

ð11Þ

j¼1

where r = max{ri : Ji 2 J}. In general, both of the global lower bounds LB1 and LB2 should be calculated at any iteration of the algorithm MINSUM. In Fig. 2, values of the global lower bounds LB1 and LB2 are shown under the corresponding vertices of a solution tree in the following order: LB1, LB2. For vectors w(0), w(1), etc., in the solution tree (until obtaining the first vector determining coloring all the vertices of mixed graph G), an upperP bound of the objective function value (5) is assumed to be equal to the n following sum: r1 þ ðr1 þ r2 Þ þ    þ i¼1 ri which defines the objective function value (5) for the feasible coloring of mixed graph G in the case when m = 1. This rough upper bound is used for the case m P 1 in order to reserve enough memory for saving solution tree T = (W, R, Ø). If at least one coloring of all the vertices of mixed graph G is currently constructed within the algorithm MINSUM, then the best recorded value (5) among all the colorings already obtained is used as an upper bound of the objective function. 5. Computational results The algorithm MINSUM was coded in C++ and tested on PC Pentium III (600 MHz) for coloring (pseudo) random mixed graphs G of orders 70, 90, 100, 120 and 200 with equal lengths of paths (job routes), and on PC Pentium IV (2000 MHz) for coloring random mixed graphs G of orders 300, 400, 500, 600 and 750

1144

F.S. Al-Anzi et al. / Applied Mathematics and Computation 182 (2006) 1137–1148

with different lengths of paths (provided that both conditions (4) and (5) hold for each randomly generated mixed graph). Tables 1–5 show the results of computational experiments on PC Pentium III (600 MHz) for the case when job routes have the same length r1 = r2 =    = rn, which is usually a harder problem than that with essentially P different lengths of job routes. Indeed, if job routes have the same lengths, then the objective function Ci may have closer values for a lot of different schedules (colorings). Moreover, if r1 = r2 =    = rn, then conflicts with coloring vertices that are adjacent in graph (V, Ø, E) may arise more often while implementing the algorithm MINSUM, and it implies increasing of vertices in a solution tree as a result of conflict resolutions. For such hard problems, two versions of the algorithm MINSUM have been evaluated. In the first one, the global

Table 1 Mixed graphs of order jVj = 70 n·m

jEj

Bound LB1

1

2

3

4

5

6

7

8

9

10

11

12

7·5 7·7 7 · 10 10 · 6 10 · 8 10 · 10 14 · 10 14 · 11 14 · 12 14 · 14

479.5 345.6 240.0 396.6 304.5 238.4 244.2 208.3 199.3 168.3

93.0 82.9 78.3 100.2 91.2 84.3 96.4 91.8 91.0 86.4

101.7 93.2 84.6 108.0 100.5 93.8 108.4 99.3 100.2 96.2

3,245,658 461,247 711 8,066,796 2,108,315 24,106 5,737,391 1,148,966 812,531 151,375

80 100 100 50 100 100 60 100 90 100

64.73 5.71 0.06 292.77 54.20 0.49 429.16 70.05 35.51 7.30

93.2 82.9 78.3 100.2 92.3 85.7 98.5 91.9 92.6 88.3

103.0 93.2 84.6 109.0 100.5 93.8 108.4 99.3 100.1 96.2

1,034,828 89,037 632 4,089,110 206,872 12,323 384,453 256,644 320,603 94,528

90 100 100 80 100 100 100 100 100 100

33.64 2.72 0.22 249.08 9.60 0.47 64.85 21.49 20.51 7.06

Bounds LB1 and LB2

Table 2 Mixed graphs of order jVj = 90 n·m

jEj

Bound LB1

1

2

3

4

5

6

7

8

9

10

11

12

6·4 6·5 6·6 10 · 8 10 · 9 10 · 10 15 · 12 15 · 14 15 · 55

983.5 796.6 662.0 489.0 447.3 396.4 334.3 292.1 257.9

121.6 110.3 102.6 115.0 111.3 106.9 117.5 112.5 109.6

131.0 121.6 116.0 124.8 122.2 118.5 126.0 122.9 119.6

10,138,166 4,964,368 120,778 5,857,087 4,053,500 1,309,243 1,055,275 2,636,349 150,841

40 90 100 60 90 100 30 70 100

176.40 131.15 1.77 137.22 131.58 38.60 62.25 139.20 7.16

121.6 110.3 102.6 115.0 111.3 107.1 119.0 114.0 109.8

131.6 121.6 116.0 125.9 122.8 118.5 128.9 126.1 119.6

12,286,352 3,890,109 107,283 3,722,763 1,703,791 146,865 2,809,480 2,929,057 59,930

80 90 100 80 100 100 80 100 100

453.59 1421.56 2.73 163.19 83.77 6.75 572.87 432.30 4.29

Bounds LB1 andLB2

Table 3 Mixed graphs of order jVj = 100 n·m

jEj

Bound LB1

1

2

3

4

5

6

7

8

9

10

11

12

5·4 5·5 5·6 10 · 9 10 · 10 10 · 11 20 · 20 20 · 22 20 · 25

1228.7 999.2 830.8 544.9 489.2 440.1 244.3 225.3 196.7

124.0 114.3 111.6 122.3 118.5 114.1 124.0 120.7 116.3

135.4 128.4 124.2 133.2 132.5 126.9 136.0 130.2 127.1

1,609,875 683,916 248,935 2,187,751 421,152 2,475,391 5,187,153 1,820,208 1,068,121

70 100 100 80 80 100 90 90 100

19.85 8.19 4.11 47.50 10.29 83.41 1040.21 296.14 168.50

124.0 114.3 111.6 122.3 118.5 114.2 124.0 122.5 116.6

135.4 128.4 124.2 134.4 132.7 126.9 136.0 131.4 127.1

1,597,596 594,437 248,889 3,396,962 1,569,142 475,550 2,412,107 195,214 900,975

70 100 100 100 90 100 90 100 100

34.37 13.87 7.42 169.03 100.22 21.05 636.56 56.10 176.57

Bounds LB1 and LB2

F.S. Al-Anzi et al. / Applied Mathematics and Computation 182 (2006) 1137–1148

1145

Table 4 Mixed graphs of order jVj = 120 n·m

jEj

Bound LB1

1

2

3

4

5

6

7

8

9

10

11

12

6·5 6·6 6·7 8·8 8·9 8 · 10 8 · 11 10 · 9 10 · 10 10 · 12 15 · 15 15 · 17 15 · 20 20 · 20 20 · 21 20 · 22 20 · 23 20 · 24 20 · 25 20 · 26 20 · 27

1427.0 1185.8 1015.1 875.6 799.4 699.2 648.4 791.9 703.8 599.3 465.5 417.7 358.4 353.6 337.5 319.2 310.6 288.0 283.4 273.6 266.5

145.8 136.3 131.7 136.9 136.3 131.0 131.4 145.6 139.4 135.5 142.2 139.2 136.0 146.7 145.8 142.4 142.1 138.7 138.6 138.2 137.3

160.5 152.7 149.2 153.7 152.2 146.6 144.9 161.0 156.4 150.2 155.9 154.4 151.6 158.5 158.5 155.1 155.7 152.2 151.6 152.0 149.9

6,800,490 3,955,279 862,342 3,635,017 2,154,475 234,380 303,533 9,066,021 5,925,586 853,598 2,989,791 2,799,784 2,816,778 3,708,888 4,930,280 2,664,345 4,098,524 1,199,904 755,786 1,208,435 174,786

60 90 100 80 80 100 100 20 90 100 70 100 100 40 80 70 90 100 90 100 90

276.46 177.90 16.88 162.25 67.72 5.40 7.19 310.16 280.44 23.98 192.09 154.46 155.50 419.62 654.64 410.07 520.63 147.80 67.08 117.12 23.33

145.8 136.3 131.7 136.9 136.3 131.0 131.4 145.6 139.4 135.5 143.9 139.4 136.8 146.7 145.8 143.5 142.8 138.7 138.6 138.2 137.3

160.5 152.7 149.2 153.7 152.2 146.6 144.9 161.0 156.4 150.2 158.4 154.8 151.6 159.7 158.5 155.9 155.8 152.2 151.6 152.0 150.8

6,586,068 3,926,692 843,899 3,495,129 2,081,932 230,118 291,114 9,529,912 2,768,785 644,894 4,037,277 2,068,091 361,953 3,059,639 4,316,874 2,112,155 1,046,320 991,529 283,544 792,385 196,138

60 90 100 80 80 100 100 30 90 100 100 100 100 70 80 80 100 100 90 100 100

342.07 229.83 28.25 215.51 107.58 9.20 12.62 787.78 160.52 33.73 424.27 252.19 36.40 782.00 783.72 614.44 238.30 155.57 45.05 121.41 52.22

Bounds LB1 and LB2

Table 5 Mixed graphs of order jVj = 200 n·m

jEj

1

2

3

4

5

6

7

8

9

10

11

12

10 · 15 10 · 17 15 · 18 20 · 33 20 · 35 20 · 40

1332.5 1174.4 1097.0 603.8 571.7 502.5

217.3 215.1 212.9 217.6 217.2 215.2

236.0 233.4 231.6 236.9 235.5 232.5

6,364,626 3,168,299 4,439,601 5,194,660 5,069,522 1,381,569

50 90 100 70 90 100

441.61 170.07 304.58 799.67 926.98 200.55

217.3 215.1 212.9 217.9 217.8 215.9

236.0 233.4 231.6 237.4 235.5 232.5

6,361,378 3,154,827 4,432,942 5,041,105 4,633,708 1,336,430

50 90 100 80 90 100

666.52 276.60 409.25 1514.92 1720.68 331.92

Bound LB1

Bounds LB1 and LB2

lower bound LB1 was used. The reason for using LB1 is that this lower bound performed better than LB2 in preliminary computational experiments. In the second version of the algorithm, both of the global lower bounds LB1 and LB2 have been calculated with the best one selected at any iteration. The local lower bound LB0 was used in both versions of the algorithm MINSUM. The main computational results for randomly generated instances are shown in Tables 1–5 for the mixed graphs with orders jVj 2 {70, 90, 100, 120, 200}. In the first column of each of these five tables, dimension n · m of job shop problem is given where n is the number of jobs, and m the number of machines. The length of job routes is equal to jVj/n (in the experiments, we considered only such jVj and n that the value jVj/n is an integer number). For each series of mixed graphs G with the same number of vertices jVj and dimension n · m, ten randomly generated instances have been solved. Column 2 of Tables 1–5 represents the average number of edges in mixed graph G randomly generated, column 3 the average value of the bound LB1 obtained at the initial iteration of the algorithm, column 4 the average optimal value of the objective function (evaluated only for the precisely solved instances), column 5 the average value of number jWj of vertices in a solution-tree, column 6 the percentage of the precisely solved instances from the given series, and column 7 the average running time used for solving one instance in seconds of the PC Pentium III processor (CPU-time).

1146

F.S. Al-Anzi et al. / Applied Mathematics and Computation 182 (2006) 1137–1148

The results for the second version of the algorithm MINSUM, which uses both global lower bounds LB1 and LB2, are given in columns 8–12 of Tables 1–5. Column 8 represents the average value of the greatest lower bounds LB1 and LB2, obtained at zero iteration of the algorithm, column 9 the average optimal value of the objective function (evaluated only for the precisely solved instances by the second version of the algorithm MINSUM), column 10 the average value of the number jWj of vertices in a solution-tree, column 11 the percentage of the precisely solved instances from the given series, and finally, column 12 the average running time

Table 6 Mixed graphs of orders 300, 400, 500, 600 and 750 n·m

jEj

Bound LB1

1

2

3

4

Mixed graphs of order jVj = 300 30 · 70 629.9 30 · 80 555.5 20 · 40 1131.5 20 · 45 986.7 20 · 50 886.5 10 · 15 2982.1 10 · 18 2494.4 10 · 20 2244.3

315.6 312.6 316.4 313.7 313.8 318.9 317.0 316.9

335.6 328.7 339.0 332.6 329.2 346.2 338.1 333.8

Mixed graphs of order jVj = 400 25 · 70 1159.9 25 · 80 1005.3 20 · 50 1598.7 20 · 55 1453.4 20 · 60 1317.4 10 · 20 3964.1 10 · 25 3251.1

416.5 414.5 417.9 417.8 416.8 422.8 421.4

Mixed graphs of order jVj = 500 25 · 80 1536.9 25 · 85 1454.0 25 · 90 1379.9 20 · 60 2079.4 20 · 65 1919.4 20 · 70 1792.8 10 · 25 4968.0

5

6

7

3,625,042 804,928 3,646,579 1,771,839 537,816 3,289,345 2,925,045 593,278

70 100 50 100 100 20 90 100

1205.3350 170.9983 549.6874 256.0626 72.9469 143.4065 126.4898 19.7235

437.5 430.1 437.5 435.3 432.3 442.8 435.0

5,067,638 1,555,600 2,891,483 5,035,653 730,496 6,353,363 123,679

60 100 80 100 100 80 100

987.7708 299.2923 388.1973 854.4377 72.7626 320.0294 5.4404

518.9 519.0 516.6 519.0 520.6 517.4 528.9

537.2 534.6 534.0 539.7 537.1 532.6 544.3

4,459,200 3,617,246 1,923,842 5,154,898 3,644,036 431,478 1,186,886

60 100 100 60 100 100 100

1072.9300 621.5484 311.6360 760.4063 432.8329 43.3391 56.9749

Mixed graphs of order jVj = 600 30 · 100 1796.4 1640.3 30 · 110 30 · 120 1514.0 30 · 130 1377.6 20 · 70 2553.5 15 · 50 3604.4 10 · 25 7170.5 10 · 30 5977.3

619.6 622.2 618.6 619.6 624.1 624.4 630.6 629.7

641.6 639.5 637.2 635.5 639.1 642.1 649.4 641.4

10,966,301 7,811,041 6,718,265 2,410,258 2,315,785 2,841,603 2,839,976 358,139

60 70 90 100 100 100 100 100

3228.2740 1847.7920 1756.5830 548.2312 349.9704 234.9782 136.8205 17.6735

Mixed graphs of order jVj = 750 25 · 100 2781.9 25 · 110 2531.3 25 · 120 2308.8 15 · 50 5633.8 15 · 60 4691.3 10 · 25 11221.0 10 · 30 9344.0 10 · 35 8047.0

773.0 773.1 771.6 781.5 778.1 789.2 785.9 783.8

793.5 789.9 786.4 801.2 792.4 812.6 803.9 797.8

9,118,326 4,970,391 679,417 4,962,223 246,498 7,562,739 1,283,328 225,207

70 90 100 70 100 40 90 100

1371.2590 856.2081 97.2423 490.5893 17.2968 560.4020 81.2258 12.6140

F.S. Al-Anzi et al. / Applied Mathematics and Computation 182 (2006) 1137–1148

1147

used for solving one instance in seconds of the PC Pentium III processor. In all the experiments, the maximum number of vertices in a solution-tree T = (W, R, Ø) for solving each instance was restricted to 20,000,000. That is jWj 6 20,000,000. From Tables 1–5 it follows that using both global lower bounds give better results in terms of both the number of precisely solved instances (columns 6 and 11) and the average number jWj of vertices in a solution-tree constructed for solving one instance (columns 5 and 10). Note that the CPU-time used for solving one instance has to be compared for two versions of the algorithm MINSUM only if the percentages of exactly solved problems coincidence for both versions of the algorithm. Indeed, in columns 7 and 12 the average CPU-times are evaluated only for the precisely solved instances since instances unsolved by one version of the algorithm usually require the greater CPU-time for solving by the other version of the algorithm. Concerning the average CPU-time used for solving one instance of some problems, it is not that obvious to prefer one of the two versions of algorithm MINSUM. This fact may be explained because of additional CPU-time needed for calculating the lower bound LB2. To solve problems with different lengths of job routes (of paths in digraph (V, A, Ø)), we used only the version of the algorithm MINSUN based on the local lower bound LB0 and global lower bound LB1. This is because it has been observed that the global lower bound LB2 was not very useful for optimal coloring of this type of randomly generated mixed graphs (global lower bound LB1 performs essentially better than LB2). Table 6 presents the main results of computational experiments on PC Pentium IV (2000 MHz) for the case when lengths of the job routes may be different for different jobs. The meaning of the columns 1 –7 in Table 6 is the same as that of corresponding columns 1–7 used in Tables 1–5. In the first column of Table 6, the dimension n · m of job shop problem is given. Table 6 is divided into five parts with respect to the orders of mixed graphs jVj 2 {300, 400, 500, 600, 750} that have been tested. For each of these orders of mixed graphs, the lengths of job routes are defined as follows. Minimal possible length of job route is assumed to be equal to a = jVj/2n, and maximal possible length to b = 3jVj/2n. The set of all paths of the mixed graph G were divided into two subsets P1 and P2 with equal cardinality for even number n : jP1j = jP2j. The length of a path from set P1 was defined as random value ri uniformly distributed in the closed interval [a, b]. For each value ri randomly generated, we calculated the difference 2jVj/n  ri that is used as the length of one path from set P2.P If the number n is odd, then jP1j = jP2j = (n  1)/2, and length of nth n1 path is assumed to be equal to jV j  i¼1 ri . For each of 10 randomly generated mixed graphs, the most critical parameter of an instance is the number jEj of edges in mixed graph G. Tables 1–6 present the problem dimension n · m with the largest numbers jEj when the most instances have been solved exactly by algorithm MINSUM (provided that the maximum number of vertices in a solution-tree T was restricted to 20,000,000). 6. Concluding remarks The job shop scheduling problem with unit processing times is addressed with respect to total completion time criterion. It is shown that the problem can be modeled as finding the optimal coloring of a special mixed graph. The results obtained may be presented using only graph terminology which is widely used in OR literature, e.g., one can use terms vertex, path, clique, color, coloring, etc. instead of terms operation, technological route, machine, completion time, schedule, etc. Such an interpretation of the known and new results seems to be useful for the researchers in graph theory to work on the scheduling theory. Since the problem is NP-hard, we develop a branch and bound algorithm for obtaining the optimal coloring of a mixed graph. We test color-based branching scheme, dominance rule, and three lower bounds of the objective function. The developed branch and bound algorithm has reasonable computational results P for randomly generated job shop problems J jpi ¼ 1j C i with number of jobs up to 20 provided that all the jobs have the same P length of technological routes. If the lengths of job routes are essentially different, then problems J jpi ¼ 1j C i with the number of jobs up toP 30 can be solved by the proposed algorithm MINSUM. Since in the considered job shop problem J jpi ¼ 1j C i , machine repetition and absence of some machines in the job route are allowed, P the above reduction of job shop problem to mixed graph coloring remains valid also for the problem J jPrj C i with arbitrary integer operation durations and allowance of an operation preemption. Indeed, if all the processing times are integers, then operation preemption may be useful (for any

1148

F.S. Al-Anzi et al. / Applied Mathematics and Computation 182 (2006) 1137–1148

non-decreasing objective function) only in integer times. Therefore, the algorithm MINSUM may be used for P solving the problem J jPrj C i via constructing an appropriate mixed graph G. Thus, the obtained computationalPresults may be interpreted for solving corresponding instances of randomly generated problems JjPrj C i with the same numbers of jobs P n and machines m. Note that the number jVj ofPoperations per job in the corresponding problem J jPrj C i may be less than that in the problem J jpi ¼ 1j C i . A possible P subject for further research is to develop and test tighter lower and upper bounds for the objective function C i in order to increase dimension of the problems that could be solved in a reasonable time. For example, it makes sense to use some kind of heuristic algorithms in order to get better upper bound instead of trivial upper bound used in the algorithm MINSUM. Moreover, the above reduction to coloring problem and color-based branching scheme may be tested for problems Jjpi = 1jU and JjPrjU with other non-decreasing objective functions U. References [1] P. Brucker, An efficient algorithm for the job-shop problem with two jobs, Computing 40 (1988) 353–359. [2] P. Brucker, S.A. Kravchenko, Yu. N. Sotskov, Preemptive job-shop scheduling problems with a fixed number of jobs, Mathematical Methods of Operations Research 49 (1999) 41–76. [3] D. De Werra, An introduction to timetabling, European Journal of Operational Research 19 (1985) 151–162. [4] T. Gonzalez, Unit execution time shop problems, Mathematics of Operations Research 7 (1) (1982) 57–66. [5] P. Hansen, J. Kuplinsky, D. de Werra, Mixed graph colorings, Mathematical Methods of Operations Research 45 (1997) 145–160. [6] W.W. Hardgrave, G. Nemhauser, A geometric model and graphical algorithm for a sequencing problem, Operations Research 11 (1963) 889–900. [7] W. Kubiak, V.G. Timkovsky, Total completion time minimization in two-machine job shops with unit-time operations, European Journal of Operational Research 94 (1996) 310–320. [8] F.T. Leighton, A graph coloring algorithm for large scheduling problems, Journal of Research of the National Bureau of Standards 84 (1979) 489–506. [9] Yu.N. Sotskov, The complexity of shop-scheduling problems with two or three jobs, European Journal of Operational Research 53 (1991) 326–336. [10] Yu.N. Sotskov, A. Dolgui, F. Werner, Mixed graph coloring for unit-time job-shop scheduling, International Journal of Mathematical Algorithms 2 (2001) 289–323. [11] Yu.N. Sotskov, N.V. Shakhlevich, NP-hardness of shop-scheduling problems with three jobs, Discrete Applied Mathematics 59 (1995) 237–266. [12] Yu.N. Sotskov, V.S. Tanaev, F. Werner, Scheduling problems and mixed graph colorings, Optimization 5 (3) (2002) 597–624. [13] V.G. Timkovsky, Is a unit-time job shop not easier than identical parallel machines? Discrete Applied Mathematics 85 (1998) 149– 162. [14] Z. Tuza, Graph colorings with local constraints: a survey, Discussions Mathematical Graph Theory 17 (1997) 101–228.