Академический Документы
Профессиональный Документы
Культура Документы
122
World Academy of Science, Engineering and Technology 31 2007
(∀i∈J) (∀k∈M): wik = waiting time (idle time) of the job Ji C(J1, 1) = p(J1 ,1) (8)
after finishing processing on machine C(Ji , 1) = C(Ji –1 , 1) + p(Ji , 1), i = 2 , … , n (9)
k, while waiting for machine k+1 to C(J1 , j) = C(J1 , j −1) + p(J1 , j), j = 2 , … , m (10)
become free C(Ji , j) = max {C(J i –1 , j), C(Ji , j −1)} + p(Ji , j),
Define the following decision variables i=2,…,n; j=2,…,m (11)
Cmax(π) = C(Jn , m) (12)
⎧1, if job j is assigned to the ith
⎪ There are many various methods for an approximation of
⎪ position in the permutation,
∀i, j ∈ J : xi j =⎨ (1) the optimal solution by searching only a part of the space of
⎪ i.e. J i = j feasible solutions (represented here by all permutations). For
⎪⎩ 0, otherwise complex combinatorial problems, stochastic heuristic
The following mathematical formulation of the permutation techniques [15], [21] are frequently used. We present an
flow shop scheduling can be derived. approach based on genetic algorithms. As the genetic
n algorithms are well known, see e.g. [16], we only concentrate
∀i ∈ J : ∑ xij = 1 (2) on problem specific details.
j =1 As to the crossover operation, we cannot use the traditional
n two-point crossover, because it would lead to infeasible
∀j ∈ J : ∑ xij = 1 (3) solutions. If we change the middle parts of the parent
i =1 chromosomes P1=(1,10,7,2,8,9,4,6,5,3) and
∀k ∈ M − {m} : w1k = 0 (4) P2=(5,8,2,9,7,4,1,10,3,6) between the 4th and 7th position,
k −1 n then we would obtain offspring (1,10,7,9,7,4,1,6,5,3) and
∀k ∈ M − {1}: v1k = ∑ ∑ pi r x1 i (5) (5,8,2,2,8,9,4,10,3,6) that correspond to no permutations,
r =1 i =1 because some jobs are duplicated or omitted. We used the so
(∀i ∈ J − {n}) (∀k ∈ M − {m}) : called crossover in a partially mapped representation where
n n the genes in the middle part of one chromosome are ordered in
vi +1, k + ∑ p jk xi +1, j + wi +1, k = wik + ∑ p j , k +1 xij + vi +1, k +1 its offspring by their occurrence in the second parent
j =1 j =1
chromosome.
(6) For mutation we considered three operators:
n n
• exchange mutation (it exchanges two randomly selected
Cmax = ∑ (vi m + ∑ p jm xij ) (7)
positions in a permutation),
i =1 j =1
• shift mutation (it removes a value at one position and
This mixed integer programming model can be easily puts it at another position), and
transformed into the form necessary for the optimisation • mutation inspired by well-known Lin-2-Opt change
package GAMS (General Algebraic Modelling System) [4]. operator usually used for solving the travelling salesman
The ability of computing optimal solutions was checked problem [10]. Here first two elements are added to the
using standard benchmarks from OR-Library (OR = permutation (into positions 0 and |n|+1) and then the
Operations Research) accessible from London Imperial same values are assigned to them to simulate a cyclic
College Management School [2]. tour. Two 'edges' (pairs of neighbour elements in
All computations leading to optimum were performed in a permutation) are randomly chosen ((p1, p2) and (q1, q2)
few seconds, but for larger instances 20 × 10 (20 × 10 say), the inner elements p2, q1 are swapped and the
corresponds to 20 jobs and 10 machines), 20 × 15, 30 × 10, elements between p2 and q1 are reversed.
etc., they ended with a run time error with GAMS indicating In the literature, slight modifications of these shift
”insufficient space to update U-factor …”. operations can be found, e.g. 1stSwap, FullSwap, DoubleCut,
Therefore, for these cases, we must choose another DoublePointShift and RightDoublePoint [8], [15], [16].
approach. One way seems to be straightforward – to search Best results were achieved with the shift mutation. In
the optimum in the space of permutations of jobs. Fig. 1, a skeleton of proposed genetic algorithm is shown.
Unfortunately, this approach is useable again only for not very Operators that have not been yet discussed are clear from their
high number of jobs, because its time complexity for n jobs is denotations in the algorithms. Number of individuals Npop in
equal to O(n!). the population was set to 50 and the number of iterations to
The mathematical formulation given by equations (2)-(7) is 10 × n2.
not suitable for searching in the space of permutations because
P(0) : = {P1, P2, … , PNpop};
it contains no explicitly expressed permutation. Therefore it is
Pmin : = Permutation_minimizing_makespan ∈ P(0);
necessary to formulate another model. If we have processing
t:=0;
times p(i,j) for job i on machine j, and a job permutation
while t < number_of_iterations do
π = J1, J2, ... , Jn, then we can calculate the completion times begin repeat BinaryTournamentSelection(P(t), parent1,
C(Ji, j) as follows: parent2);
123
World Academy of Science, Engineering and Technology 31 2007
124
World Academy of Science, Engineering and Technology 31 2007
125
World Academy of Science, Engineering and Technology 31 2007
126
World Academy of Science, Engineering and Technology 31 2007
127