Using max-plus to solve the job shop problem with time lags J. E. Cury ∗ J. J. Loiseau ∗∗ C. Martinez ∗∗ M. H. de Queiroz ∗ ∗
DAS-CTC-UFSC, Universidade Federal de Santa Catarina, CEP 88040-900 Florianopolis, SC, Brasil (e-mail:
[email protected],
[email protected]) ∗∗ LUNAM Universit´e, IRCCyN UMR CNRS 6597, 3 Rue de la No¨e, BP 92101, 44321 Nantes cedex 03, France (e-mail:
[email protected],
[email protected]) Abstract: We consider a job shop problem with minimum and maximum time lags (JSPTL). The scheduling method is based on potential inequalities and disjunctive constraints, that are formulated in the max-plus algebra, in terms of inequalities. The computation of the eigenvalue of the corresponding matrices provides bounds, and a feasibility test that is used in a branchand- bound procedure that permits to solve the problem. Effective computations make use of the max-plus Scicoslab toolbox, and its implementation of the Howard algorithm. One can evaluate whether or not a solution exists to the problem, compute one solution, or compute the set of solutions minimizing the completion time. The method is applied to two case studies from the literature, which permit to point out its advantages and drawbacks. Keywords: Scheduling, Time lag, max-plus algebra, disjunctive constraint, eigenvalue, Howard algorithm, job shop. 1. INTRODUCTION
JSP with Generic Time Lags (JSPGTL), where time lags may link operations that belong to separate jobs.
This article presents a scheduling approach to tackle the job shop problem with minimum and maximum time lags (JSPTL) (Caumond et al., 2008; Artigues et al., 2010; Lacomme et al., 2011; Grimes and Hebrard, 2011). The JSPTL is a generalization of the classical job shop problem (JSP) in which time constraints are given, restricting the minimum or the maximum time lag between two successive operations. In the industry this kind of problems is relatively frequent, when the process includes a thermal treatment or a chemical treatment, the sojourn time of parts in such resources should respect a maximal duration to prevent quality degradation. A classical example is the electroplating process in finishing industry, where are involved operations that can not have excessive duration in order to maintain the quality of the products (Spacek et al., 1999). Another example concerns medical analysis where some automatic operations need to be performed sequentially within a time window between succeeding operations because of chemical reactions (Chu and Proth, 1996). Fondrevelle et al. (2006) and Caumond et al. (2008) give some other examples of JSPTL.
Scheduling problems have already been tackled in the litterature using max-plus algebra (Yurdakul and Odrey, 2004; Bouquard and Lent´e, 2006; Bouquard et al., 2006). In Yurdakul and Odrey (2004), authors present a model based on a system of non-linear max-plus equations. They propose an algorithm to solve a steady-state schedule problem by transforming their original non-linear model into a linear one. In Bouquard et al. (2006), authors extend the work of Bouquard and Lent´e (2006) that solves the two-machines flow shop scheduling problem with minimal and maximal delays: they present results that generalize the single machine, two-machines and three-machines flow shop scheduling problems. More recently, a mathematical formulation for cyclic flow-shops using max-plus algebra has been presented in Nambiar and Judd (2011), and a method to solve the cyclic job shop scheduling problem was proposed in Houssin (2011).
In Artigues et al. (2010) and Lacomme et al. (2011), authors recall the relevant results on JSPTL, suggesting that a few articles had tackled this problem. They recall that some special cases can be transformed and therefore treated as single-machines problems. They also claim that a schedule can easily be obtained, taking into account the minimum time lags, but due to maximum time lags, ’finding a non-trivial feasible schedule for the JSPTL is not simple’. In Lacomme et al. (2011), authors study the
In this paper we present a method based on potential inequalities and disjunctive constraints (Roy and Sussman, 1964; Tabourier, 1969; Carlier, 1978; Lopez, 2003). We propose to model the set of inequalities that define the precedence in tasks and the duration constraints in the form of max-plus inequalities. The existence of a finite solution to such an inequality can be effectively checked computing the so-called spectral factor of the corresponding max-plus matrix, which lead to an original approach to solve the JSPTL and the JSPGTL. Nevertheless, the set of solutions is seek within a finite (but maybe large) number of possibilities. Our method take advantage of the fast max-plus Howard algorithm given in Cochet-
Terrasson et al. (1998). The computation of the maximum completion time also benefits from the max-plus model of the JSPTL, that permits to eliminate a wide number of inadequate schedules in the very first steps of our branchand-bound procedure. This work is organised as follows. Section 2 is divided into three subsections. The first subsection provides basic results on max-plus theory. The second one recalls the JSPTL and then the third one presents the max-plus model that is used to solve the JSPTL. Three applications are presented in section 3. The first application is an academic example that illustrates our method. The second and third applications are taken from the litterature, a small JSPGTL and a medium size JSPTL. Section 3 is closed with a discussion. Section 4 concludes this article.
The set of square matrices over a dioid inherits the algebraic structure of dioid, with the matrix sum and product defined as usually. The entry in position (i, j) of any matrix A is denoted, as usually, by Aij . Over Rmax , the sum and product are then defined, for every pair of matrices A, B ∈ Rn×n max , by (A ⊕ B)ij = Aij ⊕ Bij = max (Aij , Bij ) , and n M (Aik ⊗ Bkj ) = max nk=1 (Aik + Bkj ) . (A ⊗ B)ij = k=1
A matrix E ∈ Rn×n max being given, its Kleene star, defined by M E⋆ = Ek . k∈N
n×n
2. BASIC RESULTS 2.1 Max-plus Algebra Some elements on max-plus algebra are recalled in this section. More complete details on this theory, and many applications, can be found in Baccelli et al. (1992); Heidergott et al. (2006); Butkoviˇc (2010). Let us first recall the basic axiomatic definitions. In what follows, D denotes a set. A monoid is a set endowed with an internal operation that is associative and has an identity element. A semiring is a set D endowed with two operations, denoted ⊕ and ⊗, respectivelly called addition and multiplication, that satisfy the following axioms.(D, ⊕) is a commutative monoid, (D, ⊗) is a monoid, the multiplication ⊗ is distributive over finite sums (say ∀a, b, c ∈ D, (a ⊕ b) ⊗ c = (a ⊗ c) ⊕ (b ⊗ c), and c ⊗ (a ⊕ b) = (c ⊗ a) ⊕ (c ⊗ b)), and the neutral element of the addition is absorbing with respect to the multiplication. The neutral element of the multiplication is denoted e, and called unity, and the neutral element of the addition is denoted ǫ, and is said to be null. A dioid is a semiring (D, ⊕, ⊗), with an idempotent addition, which means that for every element x of D, the identity x ⊕ x = x holds true. In this paper we shall make use of the so-called max-plus algebra, that is the dioid (R ∪ {−∞}, max, +), denoted Rmax . As it is usual when dealing with Rmax , we shall in the sequel denote ⊕ the max operation, and call it max-plus addition, and denote ⊗ the usual addition, called max-plus multiplication. The symbol e denotes the number 0, that is the unity of max-plus addition, and ǫ is used for −∞, that is the null element of Rmax . The latter notation is also used for a null vector, or a null matrix, over Rmax . Finally we use the notation In for the n × n unit matrix of Rmax , and 0 is also used for the vector which all entries equal e = 0. Another useful diod is Rmax = (R ∪ {−∞ , +∞}, max, +). Any dioid D is endowed with a sup-semilattice structure, for the order defined by ∀x, y ∈ D, x ≥ y ⇔ x ⊕ y = x . The order associated to Rmax coincides with the usual order. We also write x ≥ y for two vectors x, y ∈ Rnmax , if xi ≥ yi , for i = 1 to n. Rmax is a complete lattice for the same order, which means that the ⊕ operation is well defined for infinite sums.
is well defined on Rmax . There is a max-plus spectral theory. Any square matrix E ∈ Rn×n max admits an eigenvalue λ, and eigenvectors xλ > ǫ, such that E ⊗ xλ = λ ⊗ xλ . One can show (see Baccelli et al. (1992)) that the greatest eigenvalue of matrix E, called its spectral radius, and denoted ρ(E), is equal to " n # k1 M M k ρ(E) = Eii . (1) k≥1
i=1
The matrix E ⋆ is well-defined over Rmax , with no entry equal to +∞, if and only if its spectral radius ρ(E) is less than or equal to 0. Indeed, one can check that, if E has a strictly positive eigenvalue λ, with eigenvector x, then E k ⊗ xλ equals (k · λ) ⊗ x is unbounded, therefore E k is unbounded, and consequently E ⋆ has at least one entry equal to +∞. When E ⋆ is well-defined as an element of Rn×n max , the maxplus sum (1) is equal to its n first terms. This permits to evaluate ρ(E) in finite time. When the sum does not stabilize after its n first terms, one can deduce that ρ > 0. Finally, one can notice that, when E ⋆ is well-defined over Rmax , then E ⋆ = E ⋆ ⊗ E ⋆ , which permits to show that E ⋆ has a unique eigenvalue, ρ(E ⋆ ) = 0, and that its eigenvectors are the max-plus linear combinations of the columns of E ⋆ . We shall consider, in the sequel, the inequation E ⊗ x ≤ x over Rmax . The main results that will be used are stated in the following theorem. Theorem 1. Given a square matrix E ∈ Rn×n max , there exists in Rnmax a finite vector x, that satisfies the inequality E ⊗ x ≤ x, if and only if ρ(E) ≤ e. Provided that this condition is satisfied, the least vector satisfying E ⊗ x ≤ x and x ≥ 0, is equal to x = E ⋆ ⊗ 0. Proof. We first show by recurrence that E ⊗x ≤ x implies that E k ⊗ x ≤ x, for k ∈ N. This condition is true for k = 0 and k = 1, and if it is true for k, then one has E k+1 ⊗x = E k ⊗E ⊗x ≤ E k ⊗x ≤ x, which establishes the fact. One further deduces that E ⋆ ⊗ x ≤ x, and therefore that E ⋆ ⊗ x = x, since, by definition of the Kleene star, E ⋆ ≥ E 0 = In . Now, we use the previously mentioned fact, that if ρ(E) > 0, then E ⋆ is unbounded. In addition, notice that E ⋆ ⊗ x ≤ x implies (E ⋆ )ij ⊗ xj ≤ xi , for every indices i, j from
1 to n. When the indices are so that entry (E ⋆ )ij is equal to +∞, then either xi = +∞, or xj = ǫ, in any case x is not finite. This establishes the necessity of the condition. To show the reverse, it suffices to consider the vector x that is equal to the sum of the columns of E ⋆ . Provided that the condition is satisfied, this vector is finite, greater than or equal to 0, and it is an eigenvector of E ⋆ , therefore satisfying the inequality E ⊗ x ≤ x, and establishing the first statement of the theorem. To prove the second statement we first show that for every vector b ∈ Rnmax , the product x = E ⋆ ⊗b satisfies x ≥ b, and x ≥ E ⊗ x. The latter inequality comes from the previous discussion, and from E ⋆ ⊗x = E ⋆ ⊗E ⋆ ⊗b = E ⋆ ⊗b = x. To end the proof, one can remark that any vector x satisfying x ≥ b and x ≥ E⊗x also satisfies x = x⊕b, and x = E ⋆ ⊗x, and deduce that x = E ⋆ ⊗ x ⊕ E ⋆ ⊗ b, and therefore that x ≥ E ⋆ ⊗ b. Considering b = 0 permits to end the proof. Remark 2. Theorem 1 actually results from a simple adaptation and concatenation of well-known results from the litterature. For an irreducible matrix E ∈ Rn×n max , the set E = {x ∈ Rnmax | E ⊗ x ≤ x} reduces to the null vector if ρ(E) > e. This was first pointed out by Gaubert (1992), and was used by (Katz, 2007, Lemma 6), in the study of controlled invariance of max-plus semimodules. The latter also used the fact, that the set of solutions of x ≥ E ⊗ x is actually equal to Im E ⋆ . This was first established, in the framework of Rmin , by Libeaut and Loiseau (1995), together with the fact, that E ⋆ ⊗ b is the least solution of x ≥ b ⊕ E ⊗ x, for the sake of studying the admissible initial conditions for linear systems over Rmin . Notice that we did not assume that matrix E is irreducible. As we shall now see, the present formulation of Theorem 1 is well adapted to the solution of a class of job-shop problems.
2.2 Job Shop Scheduling Problem with Time Lags A job shop problem (JSP) is depicted by (n × m), n the number of jobs, m the number of machines. The different jobs are denoted J1 , J2 , ..., Jn , and the machines M1 , M2 , ..., Mm . A job Ji is made of a sequence of operations. Each operation is assigned to a unique machine and is not interruptible. The sequence of operations is a priori known for each job. When more than one operation is assigned to a machine, their execution on this machine has to be scheduled. A job shop problem with time lags (JSPTL) consists of a JSP with additional time constraints, on the form of time lags between pairs of operations. These delays are prescribed to stay into given time intervals. Time lags in a JSPTL may be maximal time lags, or minimum time lags, linking starting or ending time of an operation with the ending or starting time of an operation within a single job. In Lacomme et al. (2011), authors define a wider class of problems, the JSP with Generic Time Lags. In a JSPGTL, time lags may link operations between different jobs. In the present work, any type of time lag is considered. As a matter of fact, a set of jobs, for whose each job has to be delivered before a given due date, is modeled as a JSPTL, each due date being a maximum time lag between time origin and completion of the job.
Let us formalize the problem. Consider a (n × m) JSPTL, and let Ω denote the set of N operations denoted ωi , for i ∈ I = {1, 2, ..., N }. Let J denote the set of jobs, Is be the set of indices of those operations that belong Pto job Js , for s = 1 to n, so that Ω = ∪s∈Is ωs , and N = n #Is , where # stands for the cardinal of a S set, and Ωk be the set of m operations on machine k, Ω = k=1 Ωk . For a given pair (i, j) of indices, we write ωi ≺ ωj when both operations ωi and ωj belongs to the same job, and ωi precedes ωj in its sequence. The family Ij , where j = 1 to n, is a partition of I. The notation τi is used to denote the nominal duration max min respectively denote and δij of operation ωi . Finally, δij the minimal time lag and the maximal time lag, between two operations ωi and ωj subject to time constraints, that may belong to the same job, in the case of a JSPTL problem, or also belong to different jobs, in the case of JSPGTL. We call T the set of pairs of indices (i, j) for which time constraints are defined. The variables to be determined are the starting time of the different operations, together with the origin, that is the starting time of the whole set of operations. We denote x0 the time origin and xi denote the starting time of operation ωi . In the present study, each machine can treat a single operation at a time. A solution of the JSP is given by a suitable vector x that respects the sequences of operations for each job and the capacity constraints on each machine. The completion time for this solution is defined as C = max (xi + τi ) , (2) i=1 to N
and a maximum completion time Cmax is prescribed. One looks for an optimal solution, i.e. a vector x that minimizes Cmax , subject to: Cmax ≥ xi + τi , ∀i ∈ I, (3) xi ≥ x0 , ∀i ∈ I, (4) xj ≥ xi + τi , for i, j ∈ Is , s.t. i ≤ j, s = 1, . . . , n, (5) min xj ≥ xi + δij , for i, j ∈ I, (6) max xj ≤ xi + δij , for i, j ∈ I, (7) (xi + τi ≤ xj ) ∨ (xi ≥ xj + τj ), ∀i, j ∈ Ik , k = 1,. . . , m. (8)
Inequality (3) defines the maximal completion time, (4) states that any operation of any job has to start after time origin, (5) states that the order of operations in a job are a priori determined by its sequence, (6) is used to express minimum time lag constraints and (7) maximum time lags. Inequality (8) expresses the constraint on the capacity of a machine, that only one operation is processed at a time, i.e., for two operations ωi and ωj to be processed in the same machine, either ωi terminates before ωj starts or the reverse holds. 2.3 Max-plus Model of JSPTL Inequalities (3) to (8) can be rewritten in max-plus algebra. As long as jobs and time lag constraints are prescribed, one can divide these inequalities into two distinct sets: a set potential constraints corresponding to (3-7), that models the sequences of the jobs and the time lag constraints, and a set of disjunctive inequalities (8) that models the capacity of the machines. The first set is rewritten into the form A ⊗ x ≤ x, where the matrix (N +1)×(N +1) A ∈ Rmax is given by
τj − Cmax , for i = 0 and j = 1 toN , 0 , for i = 1 to N , and j = 0 , τj , for i, j ∈ Is , s.t. ωi ≺ ωj , s = 1 to n, Aij = min δjimax , for (i, j) ∈ T , −δij , for (i, j) ∈ T . The rows and columns of matrix A are numbered from 0 to N , to take into account the variable x0 in a simple way. For the sake of simplicity, we have implicitely assumed here that no couple(i, j) is subject to two different constraints. If it arised, one would take into account the maximal constraint to define the corresponding coefficient Aij . The second set of inequalities forms a set of matrices Bi , for i = 1 to m. Matrices Bi represents the schedule of operations on machine Mi . If mi = #Ωi denotes the number of operations to be scheduled on this machine, the different possible schedules are in number (mi − 1)!. Each schedule is defined by the order of operations, say ωi1 , ωi2 , ..., ωimi . This order is charcterized by mi − 1 inequalities, that define matrix Bi Bij+1 ij = τij , for j = 1 to mi − 1 . Every schedule also has to verify Bi ⊗ x ≤ x, and therefore m M Bi . (9) E ⊗ x ≤ x , with E = A
the optimal completion time Copt with component x0 = 0. If no finite solution exists, our procedure returns empty sets. Applications are presented in the following section. Example 3.1 is a simple illustration of our approach, that is followed by two case studies from the litterature. We used Scilab, a free software for numerical computations, and more particularly the Max-Plus toolbox, that includes fast numerical methods like a combinatorial Howard algorithm Cochet-Terrasson et al. (1998), to evaluate the max-plus spectral radius of a matrix. 3. APPLICATIONS 3.1 A Single Machine JSPTL Let us consider a single machine with three operations, (figure 1). We borrow the representation of tasks and events from Timed Petri nets theory, where transitions model the starting or ending of a task and places model the operations or time lags. The durations of operations and minimum time lags are given next to the places, the duration of maximum time lags are specified in parentheses.
i=1
0, (≤ 30)
Theorem 1 permits to check whether or not a schedule is feasible. Corollary 3. A schedule is feasible if and only if the corresponding matrix E has a non-positive max-plus spectral radius ρ(E) ≤ 0. Under this condition, the minimal nonnegative solution for this schedule is given by xmin = E ⋆ ⊗ 0, and the corresponding completion time, according to definition (2), reads Cmin = x⊺min ⊗ τ . To simplify the solution, one can remark that the feasability of partial schedules can be checked, as well. This comes from the following result. Proposition 4. Given two square matrices P and Q over Rmax , the following inequality holds ρ(P ⊕ Q) ≥ ρ(P) . Proof. This property directly comes from formula (1). Hence one can as well check the feasability L of partial schedules, corresponding to matrices E = A i∈S Bi , for a subset S of machine indices. If the spectral radius of such a matrix is positive, one deduces from Proposition (2.3) and Theorem 1, that, a fortiori, all the schedules that complete this partial schedule are non feasible. This permits to eliminate a lot of candidates when researching a solution. Our approach consists in using this max-plus model in a Branch and Bound like procedure. The machines are considered one after each other. We successively compute the possible schedules for the different machines. The existence of a solution for each partial schedule is evaluated from the computation of the eigenvalue of parLk tial matrices (A i=1 Bi ), with k = 1, 2, ..., m. When a partial schedule is not feasible, we stop the examination of the corresponding branch, and when the partial schedule is feasible, we keep it and check the following machine. The result of our procedure consists in an ordered set of matrices Bi , and a set of optimal trajectories, that lead to
10 0 t1
t4 0, (≤ 30) 15
5, (≤ 20) t0
17
t2
t5 0, (≤ 42)
t3
12
t6
Fig. 1. A simple JSPTL, a single machine, 3 operations. Transition t0 represents the time origin, transitions t1 to t3 represent starting times of operations ω1 to ω3 . Transitions t4 to t6 are added to take into account maximal time lags between time origin and completion time of each operation. Let xi denote the firing instant of transition ti , in this example inequality (3) turns to Cmax ≥ x0 + max(xi + τi ), i = 1 to 3, or in max-plus, Cmax ≥ x0 ⊗ L3 L6 i=1 xi ⊗ τi , Cmax ≥ i=0 xi also. Operation ω2 cannot min start before a minimum time lag δ02 = 5, it neither can max wait more than δ02 = 20 before it starts: x2 ≥ 5 ⊗ x0 and x2 ≤ 20 ⊗ x0 which is also written x0 ≥ −20 ⊗ x2 . Inequalities (5) to (7) are summarized in A ⊗ x ≤ x with: e ε −20 ε −30 −30 −42 e 5 A = 17 e
e ε ε ε e ε ε ε e 10 ε ε e ε 15 ε e ε ε 12
ε ε ε e ε ε
ε ε ε ε e ε
ε ε ε ε ε e
.
Finally, to include the constraint capacity, one has to take (8) into account. One would have to built here 6 matrices Bi and test the feasibility of the proposal, that is ρ(A ⊕ Bi ) ≤ e. As an example, if one wants to express that ω2 ≺ ω1 ≺ ω3 , i.e. x1 ≥ x2 ⊗ τ2 and x3 ≥ x2 ⊗ τ2 ⊕ x1 ⊗ τ1 , one has to built a matrix Bi with all entries equal to ε
except Bi (2, 3) = 15, Bi (4, 3) = 15 and Bi (4, 2) = 10. This choice leads to x = (0 20 5 30 30 20 42)′ , and therefore a completion time C = 42. In this example another consistent schedule can be obtained with ω1 ≺ ω2 ≺ ω3 , leading to the optimal completion time Copt = 37. By the way, this order of operations allows a set of different starting times that cope with the restricting time lags. This set of solutions is given by the columns of (A ⊕ Bi )⋆ . 3.2 Case Studies This section is devoted to the experimental study of our approach on two JSPTL found in the literature. The first problem, a JSPGTL, is a small sized problem (3 × 3) taken from Lacomme et al. (2011). The second problem is a medium size problem that comes from the naval industry. It tackles the problem of scheduling the maintenance operations in a shipyard. A first study based on Supervisory Control Theory of Timed Discrete Events has been presented in Pinha et al. (2011). A (3×3) JSPGTL The following table gives the machine number and duration for the operations of the jobs. J1 J2 J3
1st op. (m1 , 10) (m1 , 15) (m3 , 11)
2nd op. (m2 , 35) (m3 , 16) (m1 , 12)
3rd op. (m3 , 35) (m2 , 12) (m2 , 21)
Further time lag constraints have to be taken into account: • A minimum time lag of 20 must occur between the end of the first operation of J1 and the beginning of the second operation of J2 ; • between both previous events, there is a maximum time lag of 30; • A minimum time lag of 5 must occur between the end of the first operation of J2 and the beginning of the first operation of J3 ; • between both previous events, there is a maximum time lag of 20; Following notations introduced in section 2.3, we have J1 = {ω1 , ω2 , ω3 }, J2 = {ω4 , ω5 , ω6 }, J3 = {ω7 , ω8 , ω9 }, Ω1 = {ω1 , ω4 , ω8 }, Ω2 = {ω2 , ω6 , ω9 } and Ω3 = {ω3 , ω5 , ω7 }. Inequalities (3) to (7) permit to create the following matrix: e e e e e A= e e e e e
ε e 10 ε ε 30 ε ε ε ε
ε ε e 35 ε ε ε ε ε ε
ε ε ε e ε ε ε ε ε ε
ε ε ε ε ε ε ε −40 ε ε ε ε ε ε ε ε ε ε ε ε ε ε ε ε e ε ε −35 ε ε . 15 e ε ε ε ε ε 16 e ε ε ε 20 ε ε e ε ε ε ε ε 11 e ε ε ε ε ε 12 e
This JSPTL admits 6 different schedules with a completion time C ranging from 90 to 162 time units. The optimal schedule is for Ω1 , ω1 ≺ ω4 ≺ ω8 , for Ω2 , ω2 ≺ ω6 ≺ ω9 , and Ω3 , ω5 ≺ ω7 ≺ ω3 . The optimal schedule corresponds to the starting times x = (0 0 10 57 11 30 46 57 69)′ . A Maintenance Shipyard JSPTL The problem presented here concerns the scheduling of maintenance operations on
vessels, the case studied here involves ten jobs. The goal is to perform all the maintenance operations on all the vessels within a determined delay. One consider that the main resources at a maintenance shipyard are the work teams as for example welders, mechanics, painters, quality control agents, each with their own tools. The problem is therefore to schedule the tasks of these teams on the vessels within a predefined order for each job. The teams involved in this case study are: Hydrojet (H), Paint (P ), structural Repair (R), Mechanical maintenance (M ) and Quality control (C). Taking into consideration the real times required to execute the maintenance tasks at the shipyard, the time unit refers to one week. Jobs are numbered according to their arrival time at the shipyard. The duration of each of the operations for each of the vessels, and their respective delivery deadlines (DD) and the order in which the operations are to be performed for the jobs are given in table 1. J1 J2 J3 J4 J5 J6 J7 J8 J9 J10
1st op. (R, 1) (M, 3) (R, 1) (H, 2) (R, 1) (H, 3) (H, 1) (R, 1) (M, 2) (R, 4)
2nd op. (H, 1) (H, 1) (H, 1) (P, 3) (M, 1) (P, 2) (P, 1) (H, 1) (H, 2) (H, 3)
3rd op. (P, 1) (P, 1) (P, 1) (C, 1) (H, 1) (M, 1) (C, 1) (P, 1) (P, 2) (P, 3)
4th op. (C, 1) (C, 1) (C, 1) (M, 1) (P, 2) (R, 7) (M, 1) (C, 1) (C, 1) (C, 1)
5th op. (M, 2) (R, 1) (M, 5) (R, 2) (C, 1) (C, 1) (R, 1) (M, 3) (R, 3) (M, 3)
DD 12 8 10 14 8 24 16 20 26 23
Table 1. Maintenance shipyard operations The dimension of matrix A to model this medium size problem is (51×51). There are 431 minimal schedules with an optimal completion time Copt of 25 weeks which is in conformity with the results given in Pinha et al. (2011). One of the optimal solution is: for J1 : 1 2 3 4 9, for J2 : 0 3 4 5 7, for J3 : 0 1 2 3 4, for J4 : 5 7 10 11 12, for J5 : 2 3 4 5 7, for J6 : 7 10 12 15 22, for J7 : 0 1 11 13 14, for J8 : 8 10 12 13 16, for J9 : 14 16 18 20 22, and for J10 : 3 11 14 17 19. This case study only features maximal time lags, i.e. each job has to be completed before a certain delay. 3.3 Discussion We assume in our work that a JSPTL can be modelled with max-plus inequalities and can be solved with a relatively efficient manner, i.e. avoiding to evaluate all possible trajectories. The case studies we present in section 3.2 show that our modeling approach can be used to solve JSPTL but also JSPGTL. The results obtained in the shipyard problem are consistent with the results given in Pinha et al. (2011). In order to better evaluate our approach, we have applied our method on a subset of the benchmarks presented in Caumond et al. (2008) and also used in Artigues et al. (2010). This subset consists in JSPTL of size (6 × 6) named ft06 0 to ft06 10. We have found the same optimal completion time Copt for each of these ten problems as in Artigues et al. (2010) with execution time in the same range of values that those reported in that study.
Our approach yields a set of solutions, not only the optimal one. This can be useful in industrial context when some unexpected events may impact the a priori schedule. As the result of our approach is a set of feasible schedules, this provides a set of possibilities within which one can select a schedule that cope with the unexpected changes. One of the key points of our work is that the evaluation of the completion time C that needs to compute the Kleene star of (A⊕Bi ) is avoided in most of the branches. It is only executed on the branches selected with the computation of an eigenvalue with the Howard algorithm, a much faster calculus, see for example Dasdan et al. (1999). As a matter of fact, larger problems given in Caumond et al. (2008) have not been tackled in our study. To do this, we would have to refine our procedures that were built as prototype with the max-plus toolbox embedded in Scicoslab. 4. CONCLUSION In this paper we present a method to solve JSPTL and JSPGTL using a max-plus model of potential inequalities and disjunctive constraints introduced first by Roy et al (Roy and Sussman, 1964). We illustrate our method on a small JSPGTL and a medium size JSPTL taken out of the literature. The results obtained confirmed that our method is effective for small or medium size problems. In order to tackle larger JSPTL as the ones given in Caumond et al. (2008); Artigues et al. (2010), we plan to integrate heuristics in our approach and search for a trade-off between computation time and optimality of the resulting schedule. REFERENCES Artigues, C., Huguet, M.J., and Lopez, P. (2010). Generalized disjunctive constraint propagation for solving the job shop problem with time lags. Engineering Applications of Artificial Intelligence, 24(2), 220–231. doi: 10.1016/j.engappai.2010.07.008. Baccelli, F., Cohen, G., Olsder, G., and Quadrat, J. (1992). Synchronization and Linearity. Wiley. Bouquard, J.L., Lent´e, C., and Billaut, J.C. (2006). Application of an optimization problem in max-plus algebra to scheduling problems. Discrete Appl. Math., 154(15), 2064–2079. doi:10.1016/j.dam.2005.04.011. Bouquard, J.L. and Lent´e, C. (2006). Two-machine flow shop scheduling problems with minimal and maximal delays. 4OR: A Quarterly Journal of Operations Research, 4, 15–28. Butkoviˇc, P. (2010). Max-Linear Systems: Theory and Algorithms. Springer Monographs in Mathematics. Springer. Carlier, J. (1978). Ordonnancement `a contraintes disjonctives. Revue fran¸caise dautomatique, dinformatique et de recherche op´erationnelle. Recherche Op´erationnelle, 12, 333–350. Caumond, A., Lacomme, P., and Tchernev, N. (2008). A memetic algorithm for the job-shop with time-lags. Comput. Oper. Res., 35, 2331–2356. Chu, C. and Proth, J. (1996). Single machine scheduling with chain: structured precedence constraints and separation time windows. Robotics and Automation, IEEE Transactions on, 12(6), 835 –844. doi: 10.1109/70.544767.
Cochet-Terrasson, J., Cohen, G., Gaubert, S., Gettrick, M.M., and Quadrat, J.P. (1998). Numerical computation of spectral elements in max-plus algebra. Dasdan, A., Irani, S., and Gupta, R. (1999). Efficient algorithms for optimum cycle mean and optimum cost to time ratio problems. In Design Automation Conference, 1999. Proceedings. 36th, 37 –42. doi: 10.1109/DAC.1999.781227. Fondrevelle, J., Oulamara, A., and Portmann, M.C. (2006). Permutation flowshop scheduling problems with maximal and minimal time lags. Comput. Oper. Res., 1540–1556. Gaubert, S. (1992). Th´eorie des syst´emes lin´eaires dans ´ les dio¨ıdes. Ph.D. thesis, Ecole des Mines de Paris. Grimes, D. and Hebrard, E. (2011). Models and strategies for variants of the job shop scheduling problem. In Proceedings of the 17th international conference on Principles and practice of constraint programming, CP’11, 356–372. Springer-Verlag, Berlin, Heidelberg. Heidergott, B., Olsder, G., and van der Woude, J. (2006). Max Plus at Work: Modeling and Analysis of Synchronised Systems. Princeton and Oxford. Houssin, L. (2011). Cyclic jobshop problem and (max,plus) algebra. In World IFAC Congress (IFAC 2011), 2717–2721. Milan, Italie. Katz, R.D. (2007). Max-plus (a,b)-invariant spaces and control of timed discrete event systems. IEEE Transactions on Automatic Control, 52, 229–241. Lacomme, P., Tchernev, N., and Huguet, M. (2011). Dedicated constraint propagation for job-shop problem with generic time-lags. In Emerging Technologies Factory Automation (ETFA), 2011 IEEE 16th Conference on, 1 –7. doi:10.1109/ETFA.2011.6059042. Libeaut, L. and Loiseau, J. J. (1995) Admissible initial conditions and control of timed event graphs. In 34th Conference on Decision and Control (CDC’95). New Orleans, Louisiana, USA. Lopez, P. (2003). Approche par contraintes des problmes lordonnancement et daffectation : Strucures temporelles et m´ecanismes de propagation. Hdr, Institut National Polytechnique de Toulouse. Nambiar, A. and Judd, R. (2011). Max-plus-based mathematical formulation for cyclic permutation flowshops. International Journal of Mathematical Modelling and Numerical Optimisation, 2, 85–97. doi: 10.1504/IJMMNO.2011.037201. Pinha, D.C., de Queiroz, M.H., and Cury, J.E.R. (2011). Optimal scheduling of a repair shipyard based on supervisory control theory. In CASE, 39–44. Roy, B. and Sussman, B. (1964). Les probl‘emes dordonnancement avec contraintes disjonctives. Spacek, P., Manier, M., and Moudni, A. (1999). Control of an electroplating line in the max and min algebras. International Journal of Systems Science, 30(7), pp 759–778. Tabourier, Y. (1969). Probl`eme dordonnancement `a contraintes purement disjonctives. Revue fran¸caise dautomatique, dinformatique et de recherche op´erationnelle. Recherche Op´erationnelle, 3, 51–65. Yurdakul, M. and Odrey, N.G. (2004). Development of a new dioid algebraic model for manufacturing with the scheduling decision making capability. Robotics and Autonomous Systems, 207–218.