You are on page 1of 5

A Hybrid Genetic Algorithm for Project Scheduling

HONGQI PANa, CHUNG-HSING YEHa, ROBERT J. WILLISb b The Monash MBA Programs School of Business Systems Monash University Monash University Caulfield East, Victoria 3145 Clayton, Victoria 3800 AUSTRALIA AUSTRALIA

Abstract: - To obtain a good solution for resource-constrained project scheduling, this paper presents a genetic algorithm combined with tabu mechanism together constituting an innovative approach called a hybrid of genetic algorithm (HGA). In the study, the search strategies, of both intensive and extensive searches, are applied alternatively, depending on the conditions at that time, to guide the search to effectively procure approximate optimal solutions. Key-Worlds: - Genetic algorithm, Tabu search, Metaheuristic, Renewable resource, Project scheduling

1 Introduction
Since Kelley [1] and Wiest [2] raised resourceconstrained project scheduling (RCPS) in the 1960s, this field has been the focus of much research for nearly 40 years. One of the most common interests is to minimize project completion time in circumstances where the activities of a project are subject to precedence and resource constraints. In attempts to resolve a problem, some researchers have used such exact approaches as integer programming [3]; dynamic programming [4]; implicit enumeration [5]; bounded enumeration [6]; brandand-bound [7]. RCPS problems are one of the NP-hard classes because of the complexity of their combinatorial nature [8]. For moderate or large-sized problems, it may be computationally impracticable to obtain an optimal solution. Heuristic approaches have been popularly used because they are simple to apply and fast in their computational effort. Most approaches are based on a set of priority rules combined with serial or parallel schemes [9,10]. However, these do not guarantee the procurement of the proximate optimal solution. Recently improved approaches in metaheuristics have been adapted to RCPS problems. Such approaches can control and guide search by the strategies set up in the approach in order to find the near optimal

solution globally. Boctor and Cho et al developed simulated annealing for RCPS problems [11,12]; Thomas and Salhi applied tabu search to the problems of RCPS [13], and zdamar developed GA combined with rulepriorities in RCPS [14]. These are three main popular metaheuristics used to try to obtain the best results. In the study, the HGA is developed and combined with tabu mechanism to avoid generating some chromosomes that have been generated recently, saving enormous unnecessary time. This innovative approach has intelligent strategies to guide the search to obtain the near global optimal solution.

2 The Min. RCPS Completion Time


Any project contains a set of activities. To schedule a project, the most common cases require the determination of the minimization of completion time of RCPS when resources are limited from period to period, and precedence relation may not be violated. This can be shown in the following mathematical expression:

MinTn s.t. Tj Ti di , (i, j) H ,

(1) (2) (3) ak , T = 1,2...,Tn ; k = 1,2..., K ,

r
At

ik

where Tn represents the end of dummy activity

starting time which means a whole project completion time; Ti is the start time of activity i; di is the duration of activity i; H denotes the set of pairs of activities in the precedence relations; At is the set of activities that are still active at the scheduling time point t; k indicates a type of renewable resource; K renewable resource types are available in the project; rrk signifies the mount of resource k required by activity i; ak specifies the total amount of an available resource k. However, the above mathematical programming fails to produce a result when the number of activities increases as result of NP-hardness. Much evidence has shown that metaheuristics produce better solutions in RCPS [15]. The rest of this paper will introduce the novel HGA developed and demonstrate the significance of experiements designed to evaluate the proposed solution.

Activity number: Activity priorities:

1 2

2 4

3 1

4 5

5 6

6 3

Figure 1 The population size is set as a parameter that must be preset before running HGA. All chromosomes are generated randomly in the first place. Each chromosome is scheduled in forward and backward manners, based on activity priorities assigned to each box in the chromosome. In forward scheduling, four disjointed sets are defined. If the activities have no predecessors (as at the beginning) or if those predecessors have been completed, and also if resources are available to them, these activities are eligible in the decision set D(t). If the activities are completed at some scheduled time point t, these activities are shifted to the complete set C(t). If the activities have been scheduled, but are not completed at that time point t, these activities remain in the active set A(t). However, the activities are not processed at that time point t, and continue to stay in the remaining set R(t). the process of the forward scheduling is shown in Figure 2. The backward scheduling is different only in one aspect: activities can be scheduled when those successors are completed and other procedures are exactly same.
INITIALISATION:

3 A Hybrid of GA (HGA)
GA was first developed by Holland [16] based on the mechanics of natural selection in natural genetics in biological systems. It has been popularly used in many areas. Each chromosome stands for a possible solution to a problem. Firstly, a certain size of population of chromosomes is required to be generated. Each chromosome evolves through successive generations by employing genetic operators. During each generation, each chromosome is evaluated by the fitness function. Fitter chromosomes have higher survival probabilities. After several generations, the chromosome that hopefully represents the optimal or near optimal solution to a problem can be found. In the research, due to the problem-specific of RCPS, the number of genes in a chromosome is equal to the number of activities of a project. The representation is shown in Figure 1 where for e.g. there are 6 activities in the project; the location in each chromosome corresponds to the activity number and a number in the box of a chromosome stands for the priority value of that activity. In this instance sketched in Figure 1, activity 3 has the value of 1 in activity priorities. In the assumption, the smallest value has a highest priority.

A(t n ) = C (t n ) := , R(t n ) := {Z } GOTO Step (2) DO WHILE n <J DO STAGE n


BEGIN (1)

n:= 1,t n := 0,D(t n ) := {1}, Rr := Rr r R

t n := min{FTi Z i A(t n1 )}

A(t n ) := A(t n1 ) \ {Z i | Z i A(t n1 ),FTi = t n } C (t n ):= C (t n1 ) {Z i FTi = t n } K r = K r


iA ( t n )

ir

,r R

D(t n ) = {Z i | Z i {C (t n ) A(t n ),Pi C (t n ) R(t n ) = Z \ {C (t n ) A(t n ) D(t n )} (2) Ordering the priority list in D (t n ) DO WHILE kir K r STi := t n

FTi := STi + d i A(t n ) := A(t n ) Z i Update K r r R, D(t n ),and R(t n ) n: = n + 1


END

Figure 2 Each chromosome will obtain two solutions after using forward and backward scheduling respectively. However, each chromosome keeps only one solution that has the shortest project completion time, dropping off the one with the longest completion time. To generate the next generation, all chromosomes are evaluated by the fitness function, only fit chromosomes are chosen as parents for generating the next generation.

In the crossover operation, a child will take some genes from parent 1 at random, and fill the empty positions in a child chromosome with genes from parent 2 by left to right shift. The generated offspring will be similar to neither of its parents. In terms of RCPS, the sequence of priorities is changed greatly. The operation is displayed in Figure 4.
Parent 1 3 5 1 2 6 4

Child

Parent 2

Figure 4 Figure 5 shows how the neighbourhood swaps are operated. The operation can be viewed as a modified mutation. In this example, the key gene is randomly selected at one position. Then the key gene swaps its location to the 2nd position and the gene at the 2nd position takes the former place of the key gene. From this 2nd position, the key gene moves progressively to the 3rd and 4th positions until it arrives the next to the former place of the key gene. Each gene that it replaces, moves to the original position of the key gene.
Key Gene 2 2 Neighbourhood swaps 2 2 6 4 6 6 1 1 4 1 5 5 5 4 4 6 1 5 3 3 3 3

4 Operation and Tabu mechanism


In order to generate the next generation, genetic operations such as mutation, crossover and neighbourhood swaps are operated on parents to produce offspring. The tabu mechanism applied here, prevents the generation of chromosomes that have been generated previously. The tabu list size is a parameter that is pre-given or through determined experimentally. Our experiments have demonstrated that the better size of tabu list should be around population size divided by 10. This mechanism stops to revisit the previous search areas to save enormous time in the search of the optimal solution. For the mutation operator, two locations along a chromosome will be selected randomly, and their locations are swapped to generate a new offspring. When this operator is applied, most genes in the sequence of the chromosome in this offspring are similar to the parent. The process of this operation is sketched in Figure 3.
Parent 2 4 1 5 6 3

Figure 5

5 Search Strategies
Child 2 6 1 5 4 3

Figure 3

In HGA, intensive and extensive search strategies are used in turn, depending on the

current condition, to guide search in the evolution process. The intensive search strategy is used to search intensively the specific local space when the improved solution is found after generating a number of offspring. The mutation and neighbourhood swaps are usually employed to support this strategy. However, if an improved solution is unable to be found through a number of operations, the extensive strategy will be followed to explore other search spaces. Therefore, the crossover operator is normally applied. In the beginning of each generation, the mutation operator applies first to a chromosome the number of times that is preset as a parameter to let the user to determine, followed by neighbourhood swaps. Then the program will investigates to see if the solution is improved. If an improved solution is not found, the crossover operator is applied. Otherwise, the mutation and neighbourhood swaps operations continue.

There are two purposes setting up parameter: firstly to prevent the denominator of formula (4) from zero; secondly make the adjustment in some way to naturalise random selection.

7 Testing Results
In the experiment, 15 sets of problems are tested with the size of activities from 50 to 250 and the number of resources ranging from 2 to 8. The population size set here is 100 and the size of tabu list chosen varies from 10 to 15. The number of iterations for generation is chosen as 150, 200, and 250, 300 respective-ly depending on number of activities. For example, for a problem set containing 50 activities here, a number of iterations select 150. The results of different problem sets are displayed in Table 1. These results are very encouraging. As noted in the table, the worst and average project completion times are quite close to the best ones with minor deferences. Table 1: Testing results
Problem Number of Number of Best Set Activities Resources Result Worst Result Average Result

6 Fitness Evaluation
During each generation, all current chromosomes are evaluated, based on some measure of fitness. Normally the fitness of a chromosome is estimated according to the natural objective function. In RCPS, the objective function is to minimize the project completion time. However, the fitter chromosome should have a higher value of the fitness function. Therefore, the original objective value has to covert into the fitness value. The fitness function is adopted from R. Cheng and M. Gen [17]. Let vi be the ith chromosome in the current generation. f(vi) signifies the objective function of the project completion time. fmax and fmin are the maximum and minimum values of the project duration time respectively. The selection probability P(vi) for a chromosome i is represented in the following form: f f (vi ) + P(vi ) = max (4) f max f min + where must be chosen as positive real number restricting with the open interval (0,1).

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15

50 50 50 100 100 100 150 150 150 200 200 200 250 250 250

2 4 8 2 4 8 2 4 8 2 4 8 2 4 8

105 113 130 140 157 132 142 161 155 172 188 198 240 280 423

108 115 134 142 160 135 145 165 158 178 194 201 246 288 417

106.5 114 132 141 158.3 133.8 143.8 160 157 175 190.5 200.3 244 284 419

8 Conclusion
RCPS is often a difficult problem to overcome when project sizes increase. Typically this is caused by NP-hardness due to the combinatorial nature. Exact approaches fail to handle such problems. Although priority rule based

heuristics is simple to apply, it cannot always ensure good results. This paper presents a GA that incorporates tabu mechanism to avoid revisiting the previous search space, providing more effective computational effort. The search strategies intelligently guide search in a variety of different spaces, avoiding local optima in order to find global or near global solutions for RCPS. This innovative approach is simple and straightforward in practical applications. This study provides the some ideas about how to combine the advantages of different metaheuristics into one hybrid approach in order to become more effective and efficient in procuring good solutions for RCPS problems. References: [1] J. E. Kelley, The Critical-path Method: Resources Planning and Scheduling, J.F. Muth et al (Ed.), Industrial Scheduling, Prentice Hall, 1963, pp.347-365. [2] J.D. Wiest, Some Properties of Schedules for Large Projects with Limited Resources, Operations Research, Vol.12, No.3, 1964, pp.395-418. [3] J.H. Patterson and G. Roth, Scheduling A Project under Multiple Resource Constraints: A Zero-one Programming Approach, AIIE Transactions, Vol.8, No.4, 1976, pp.449-456. [4] J.A. Carruthers and A. Battersby, Advances in Critical Path Methods, Operational Research Quarterly, Vol. 17, 1966, pp.359-380. [5] F.B. Talbot and J.H. Patterson, An Efficient Integer Programming Algorithm with Network Cuts for Solving Resource-constrained Scheduling Problems, Management Science, Vol.24, 1978, pp.1164-1174. [6] E.W. Davis and G.E. Heidorn, An algorithm for optimal project scheduling under multiple resource constraints, Management Science, Vol.17, No.12, 1971, pp.B803-B816. [7] N. Christofides, Project scheduling with resource constraints: A branch and bound approach, European Journal of Opera-

[8]

[9]

[10]

[11]

[12]

[13]

[14]

[15]

[16]

[17]

tional Research, Vol.29, No.3, 1987, pp. 262-273. J. Blazewick et al, Scheduling Subject to Resource Constraints: Classification and Complexity, Discrete Applied Mathematics, Vol.5, 1983, pp.11-24. D.F. Cooper, Heuristics for Scheduling Resource-constrained Projects: An Experimental Investigation, Management Science, Vol.22, No.11, 1976, pp.11861194. E.A. Elsayed and N.Z. Nasr, Heuristics for Resource-constrained Project Scheduling, International Journal of Production Research, Vol.24, 1986, pp.299-310. F.F. Boctor, Resource-constrained Project Scheduling by Simulated Annealing, International Journal of Production Research, 1996, Vol.34, No.8, pp.23352351. J-H. Cho and Y-D. Kim, A Simulated Annealing for Resource Constrained Project Scheduling Problems, Journal of the Operational Research Society, Vol.48, No.7, 1977, pp.736-744. P.R. Thomas and S. Salhi, A Tabu Search Approach for the Resource Constrained Project Scheduling Problem, Journal of Heuristics, Vol.4, No.2, 1998, pp.123-139. L. zdamar, A Genetic Algorithm Approach to A General Category Project Scheduling Problem, IEEE Transactions on Systems, Man, and Cybernetics-Part C: Applications and Reviews, 1999, Vol.29, No.1, pp.44-59. S. Liu and M. Wang, An Objet-oriented Methodology for Solving the RCPSPs with Heuristics and Metaheuristics, Production Planning & Control, 2000, Vol.5, No.11, pp.434-442. J.H. Holland, Adaptation in Natural and Artificial Systems, University of Michigan Press, Ann Arbor, 1975. R.Cheng and M. Gen, An Evolution Program for Resource Constrained Project Scheduling Problem, Proceedings of the 1st IEEE Conference on Evolutionary Computational Intelligence, 1994, Vol.2, pp.736-741.

You might also like