Critical Path Method in A Project Network Using Ant Colony Optimization

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 10

International Journal of Computational Intelligence Research

ISSN 0973-1873 Volume 7, Number 1 (2011), pp. 716


Research India Publications
http://www.ripublication.com/ijcir.htm

Critical Path Method in a Project Network using


Ant Colony Optimization
N. Ravi Shankar, P. Phani Bushan Rao , S. Siresha and K. Usha Madhuri
Department of Applied Mathematics, GIS, GITAM University,
Visakhapatnam, INDIA

Abstract
Critical Path Method (CPM) is useful for planning, analyzing, controlling the
progress and the completion of large and complex projects. The ant colony
optimization (ACO) algorithms are applied to solve many complex
combinatorial optimization problems, such as the traveling salesman problem,
the vehicle routing problem, the problem of graph coloring, the quadratic
assignment problem, the problem of network traffic optimization, the job-shop
scheduling problem, etc. In this paper, we present a study of enhanced ant
colony optimization algorithm for tackling project management problem using
critical path method. In particular, we propose an empirical estimation
approach to evaluate the time duration of the network constructed by the ants.
The proposed method is investigated for a selected project network. The
results demonstrate that compared to conventional methods, the method
proposed in this paper is more effective in determining the critical path and
subcritical paths.
Keywords: CPM, ACO, critical path, project network.

Introduction
Ant algorithms were inspired by observations of real ant colonies. An important and
interesting behavior of ants in colonies is their foraging behavior and in particular
how they can find the shortest paths between food sources and their nest. While
walking from food sources to the nest and vice versa, ants deposit on the ground a
substance called a pheromone, forming in this way a pheromone trail. Ants can smell
a pheromone, and when choosing their way they tend to choose paths marked by
strong pheromone concentrations. When several paths are available from the nest to a
food source, a colony of ants may be able to exploit the pheromone trails left by the
individual ants to discover the shortest path from the nest to the food source and back.

N. Ravi Shankar et al

ACO will have some major differences with a real (natural) one :
(i) artificial ants will have some memory
(ii) they will not be completely blind
(iii)they will live in an environment where time is discrete
Networks have proved very useful for performance evaluation of some types of
projects. This evaluation includes determining certain aspects about the project, e.g.,
what is the least amount of time in which the project may be completed, and which
individual activities should be speeded to reduce overall project length, etc. [1]. Since
the activities in the network can be carried out in parallel, the minimum time to
complete the project is the length of the longest path from the start of project to its
finish. The longest path is the critical path. The purpose of the CPM is to identify
critical activities on the critical path so that resources may be concentrated on these
activities in order to reduce project length time. Besides, CPM has proved very
valuable in evaluating project performance and identifying bottlenecks. Thus CPM is
a vital tool for the planning and control of complex project. By using CPM, managers
are able to obtain [2,3] a graphical display of project activities, an estimate of how
long the project will take and an indication of which activities are the most critical for
timely project completion. A modified Dijkstras algorithm for critical path method
[5] is developed to find earliest event time, latest event time and slack time for each of
its activities in a project network.
The first application of an ACO was done using the traveling salesman problem as
a test problem. Dorigo et al. [6] proposed an ACO algorithm called an ant system for
traveling salesman problem. Dorigo et al. [7] have suggested an ACO approach in
which an ant colony system for traveling salesman problem and the results were
compared and shown to be better than other heuristic approaches like genetic
algorithm, evolutionary programming, simulated annealing, and the annealing genetic
algorithm, which is a combination of genetic algorithm and simulated annealing.
Dorigo et al. [8] have presented the basic biological findings on real ants and their
artificial counterparts and proposed an ACO approach to a number of applications for
combinatorial optimization and routing in communications. Dorigo and Stutzle [9]
suggested various ACO approaches to quadratic assignement problems and compared
the results. Compared with the other heuristics, the ACO approach has proved to be
superior. Den Besten et al. [10] suggested an ACO applicaton for the single machine
total weight tardiness problem. Jayaraman et al. [11] suggested an ACO approach to
the optimal design and scheduling of batch plants. McMullen [12] has suggested an
ACO approach to address a JIT sequencing problem with multiple objectives. The
ACO approach has shown better results than other heuristic approaches in many
scientific and engineering applications and has thus attracted many researchers to
implement the ACO in many unexplored areas. This work is an attempt to implement
the ACO approach in project management problem for critical path method.

Critical path Method


A network G = V, E, t , being a project model, is given. V is a set of nodes (events)
and E V V is a set of arcs (activities). The network G is a directed, compact,

Critical Path Method in a Project Network

acyclic graph. The set V = {1,2, ,n} is labeled in such a way that (i,j) E i <j .
By means of function t, t : E R+ {0}, the activity times in the network are
determined, t [(i,j)] = tij is a duration of activity (i,j) E.
Let us denote by Pi = { k V | (k,i) E } the set of predecessors and Si = { k V
| (i,k) E } the set of successors of event i V. The earliest times, Ti e , of occurrence
of the events i V are determined by recurrence formula :

0 for i = 1
Ti e =
for i > 1.
(Tke + t ki )
max
kPi

(1)

And the latest times,


Tne for i = n

l
Ti =
for i < n.
min (Tkl t ik )
kSi i

(2)

The times obtained by the use of (1) and (2) are applied to the calculation of slack
times,
(3)
Zi = Ti l Ti e ,
for events i V and slack times,
Z(i,j) = T jl Ti e t ij ,

(4)

For activities (i,j) E.


Definition 1. An activity (i,j) E is critical if Z (i,j) = 0.
Definition 2 . An event i V is critical if Zi = 0.
Let P be set of all paths in G from node 1 to node n.
Definition 3. A path p P if all activities belonging to p are critical.
The critical path of G = V, E, t is obtained using (1) through (4).

ACO approach to the traveling salesman problem


ACO is a metaheuristic technique for discrete optimization problems. For each ant,
the passage from a town i to a town j depends on the following three components : the
tabu list, visibility, and trails of virtual pheromones. The tabu list is a data structure
that saves the list of the towns already visited, which should not be visited again. This
list is growing in size during the tour and is set zero at the start of each iteration of the
algorithm. Lt us denote by ik , the list of towns yet to be visited by the ant k located in
the town i. It is clear that ik is the component of the tabu list. The visibility is a
quantity reciprocal to the distance : ij =

Dij

, where Dij is the distance between the

10

N. Ravi Shankar et al

towns i and j and is visibility parameter. The trail of virtual pheromones on the edge
(i-j) is the desire based on the experience of the colony to move to the town j from i.
The number of virtual pheromones on the edge (i-j) at an iteration t is denoted by
ij(t).
The probability that an ant k moves at iteration t from a town i to a town j is
calculated by the following probability distribution :

( ij (t )) ( ij )
, if

(
(
t
))
(
)

il
il
Pij , k (t ) =
lik
0, if j ik ,

j ik ,
(5)

where 0 and 0 are adjustable parameters describing the weights of the


pheromone trail and visibility when choosing the path. When = 0, the nearest town
is chosen, which corresponds to a greedy algorithm in the classical optimization
theory. When = 0, only the pheromone trail is taken into account, which implies
that all ants select one suboptimal path. To provide a good optimization dynamics, it
is recommended in [4] to set . We note that eq. (5) determines the probabilities
of choosing a particular node. The node is chosen like throwing a roulette ball, i.e., by
generating a random number to determine the sector where it stops. When the tour is
completed, the kth ant lays down on the edge (i,j) the pheromone value
Q
, if (i, j ) Tk (t )

,
(6)
ij ,k (t ) = Lk (t )
0,
if (i, j ) Tk (t )

where Tk(t) is the route of the ant k at iteration t, Lk(t) is length of the route Tk(t),
and Q > 0 is an adjustable parameter.
To study the whole space of solutions, the pheromones should evaporate. If the
coefficient of evaporation is denoted by p [0,1] , the update rule for the pheromones
takes the form
m

ij (t + 1) = (1 p) ij (t ) + ij ,k (t ) ,

(7)

k =1

where m is the number of ants in the colony.

Optimization algorithm of ACO


Step 1 : initialize the pheromone table.
Step 2 : randomly allocate ants to every node.
Step 3 : every ant walk to next node, depending on the probability distribution using
Eq. (5).

Critical Path Method in a Project Network

11

Step 4 :using Eq.(6), compute the length of the path traveled by each ant k , and
allocate a quantity amount of pheromone and visibility to the path, according to the
length of its path.
Step 5 : perform a local update using Eq. (7).
Step 6 : compute whether a better solution is obtained in this time step than the last; if
so, then perform a global update on the solution and empty the Tabu value.
Step 7 : repeat steps 2 to 6

Proposed ACO algorithm for solving CPM


ACO technique is used primarily for path minimization problem, traveling
salesman problem etc. The proposed ACO algorithm modifies the basic ACO
approach to the traveling salesman problem.
Proposed ACO algorithm
Step 1 : find all simple paths from initial node to final node in the project network
using DFS algorithm.
Step 2.: for each path, initialize the pheromone table.
Step 3 : allocate first ant to initial node of each path.
Step 4 : calculate the probability of choosing next node by each ant in each path by
Dij
Eq.(5). Here we take ij = 1 +
and Dij is the time of the activity (i,j)

Step 5 : determine the amount of pheromone to be deposit on every activity on each


path based on the total path length using the equation
Q Lk (t ), if (i, j ) Tk (t )
ij ,k (t ) =
if (i, j ) Tk (t )
0,
Step 6 : compute whether a better solution is obtained in this time step than the last; if
so, then perform global update on the solution and empty the tabu value.
Step 7 : repeat steps 3 to 6.
Example :
The project network diagram is shown in Fig.1. Table 1 lists the activities of our case
study with activity times. All possible simple paths in the project network from initial

12

N. Ravi Shankar et al

node to final node are calculated using DFS algorithm. To investigate the applicability
of the proposed ACO technique, it has been applied to study the case study network,
the influence of number of ants (n) , the decay rate (p) , visibility parameter ( ) and
numerical parameter (Q) are investigated.

5
1
2

Figure 1: Project Network.


Table I: Activity times of the project network.
Activity
1-2
1-3
2-3
2-4
3-4
3-5
4-5

Activity time (days)


5.1
7.2
4.5
3
0
15.8
2.5

Table II: The influence of number of ants on the paths in project network found by
ACO.
Number
of Ants

10

30

Paths

1-2-3-4-5
1-2-3-5
1-2-4-5
1-3-4-5
1-3-5
1-2-3-4-5
1-2-3-5
1-2-4-5
1-3-4-5

Percentage

36
10
22
18
65
34
22
20
16

Critical Path Method in a Project Network

100

500

1000

1-3-5
1-2-3-4-5
1-2-3-5
1-2-4-5
1-3-4-5
1-3-5
1-2-3-4-5
1-2-3-5
1-2-4-5
1-3-4-5
1-3-5
1-2-3-4-5
1-2-3-5
1-2-4-5
1-3-4-5
1-3-5

13
67
31
45
18
15
68
28
76
16
14
58
25
98
15
13
48

The influence of number of ants on all possible paths in project network found by
ACO for 100 tests is described in table II. During these tests the decay rate ( p) ,
visibility parameter ( ) and numerical parameter (Q) are kept constants. The initial
pheromone level is assumed randomly on all paths. In the initialization phase, the ants
walk randomly according to the randomly existing pheromone level from the initial
step. While they are moving they leave their own pheromones. Then, they follow the
usual pheromone and visibility level. It is clear that using starting from 300 ants leads
to a satisfying results and converge to the optimal solution. These results show that
the ability of ACO to produce a good solution in a short time.
The influence of decay rates on all possible paths in project network solution is
described in table III. In this case, the number of ants(n), intensity parameter(), and
numerical parameter (Q) are kept constants. Using high decay rate leads the ants to
make all paths randomly and the ant does not influence the successor ones. Low
decay rate leads to fast convergence to the preceding path and may lead to immature
convergence due to the lack of exploration of other paths.
The influence of visibility rate on all possible paths in project network is
described in table IV, the number of ants (n), tests the decay rate ( p) and numerical
parameter (Q) are kept constants. Using the high influence of visibility encourages the
ants to choose the path having the largest trail time.
By considering number of ants, decay rate, constants and increasing numerical
parameter. The influence of numerical parameter Q upon the results is described in
table V.

14

N. Ravi Shankar et al

Table III: The influence of decay rate on the paths in project network found by ACO.
Decay
rate

0.05

0.1

0.2

0.5

0.9

Paths

Percentage

1-2-3-4-5
1-2-3-5
1-2-4-5
1-3-4-5
1-3-5
1-2-3-4-5
1-2-3-5
1-2-4-5
1-3-4-5
1-3-5
1-2-3-4-5
1-2-3-5
1-2-4-5
1-3-4-5
1-3-5
1-2-3-4-5
1-2-3-5
1-2-4-5
1-3-4-5
1-3-5
1-2-3-4-5
1-2-3-5
1-2-4-5
1-3-4-5
1-3-5

14
30
12
20
67
32
35
14
22
61
36
38
16
25
53
38
40
14
26
44
40
42
18
24
61

Table IV: The influence of visibility rate on the paths in project network found by ACO.
Visibility

Paths
1-2-3-4-5
1-2-3-5
1-2-4-5
1-3-4-5
1-3-5
1-2-3-4-5
1-2-3-5
1-2-4-5
1-3-4-5
1-3-5

Percentage
42
6
28
38
51
38
15
26
36
49

Critical Path Method in a Project Network

25

50

100

1-2-3-4-5
1-2-3-5
1-2-4-5
1-3-4-5
1-3-5
1-2-3-4-5
1-2-3-5
1-2-4-5
1-3-4-5
1-3-5
1-2-3-4-5
1-2-3-5
1-2-4-5
1-3-4-5
1-3-5

15
35
30
23
42
46
32
48
26
40
35
31
56
25
41
33

Table V: The influence of parameter Q on the paths in project network found by ACO.
Q

0.5

0.3

0.1

0.06

0.02

Paths
1-2-3-4-5
1-2-3-5
1-2-4-5
1-3-4-5
1-3-5
1-2-3-4-5
1-2-3-5
1-2-4-5
1-3-4-5
1-3-5
1-2-3-4-5
1-2-3-5
1-2-4-5
1-3-4-5
1-3-5
1-2-3-4-5
1-2-3-5
1-2-4-5
1-3-4-5
1-3-5
1-2-3-4-5
1-2-3-5
1-2-4-5
1-3-4-5
1-3-5

Percentage
25
8
28
32
56
23
19
27
31
45
22
28
32
24
40
31
33
25
36
35
45
30
26
38
26

16

N. Ravi Shankar et al

Conclusions
Several researchers have investigated the critical path analysis in the project network
with discrete times. This paper discusses an approach to use Ant Colony optimization
for solving CPM networks. The applicability of the proposed algorithm is
demonstrated for a project network with deterministic times. Investigation of results
reveals that the main advantage of the proposed ACO over traditional CPM is the
ability of the Ant system to produce good critical path and subcritical paths.

References
[1]
[2]

[3]
[4]

[5]

[6]

[7]

[8]
[9]
[10]

[11]

[12]

E. Horowitz, S.Sahni, and D.Mehta, Fundamental of Data structures in C++,


New York : Freeman, 1995.
A.Azaron, H. Katagiri, M.Sakawa, K.Kato, A.Memariani, A multi-objective
resource allocation problem in PERT networks, European Journal of
Operations Research 172 (2006) 838-854.
W.J. Stevenson, operation Management, seventh edition, McGraw-Hill, 2002.
Dorigo, M., Maniezzo, V., and Colorni, A., The Ant System : Optimization by
a Colony of Cooperating Agents, IEEE Trans. Systems, Man Cybernetics, Part
B, 1996, vol.26, no.1, 29-41.
N.Ravi Shankar , V.Sireesha , A graphical approach to find the critical path in
a project network , Contemporary Engineering Sciences, vol.2, no.12 (2009)
553-558.
Dorigo M, Colorni A, Maniezzo V (1992) An investigation of some properties
of an ant algorithm, Proceedings of an the conference on parallel problem
solving from nature, Brussels, Elsevier, Amsterdam, 509-520.
Dorigo M, Gamberdella LM (1997) Ant colony system : a cooperative
learning approach to the traveling salesman problem. IEEE Transaction
Evolutionary Computation 1(1) : 53-66.
Dorigo M. di Caro G, Gamberdella LM (1999) Ant algorithms for discrete
optimization. Artif Life 5(3) : 137 -172.
Stutzle T, Dorigo M (1999) Ant colony algorithms for quadratic assignment
problem : new ideas in optimization, McGraw Hill, New York
Den Besten M, Stutzle T, Dorigo M (2000) An ant colony optimization
applicaton to the singe machine total weighted tardiness problem. Proceedins
og ANTS2000, Brussels, Belgium, 2000, 39-42.
Jayaraman VK, Kulkarni BD, Karale S, Shalokar P (2000) Ant colony frame
work for optimal design and scheduling of batch plants. International Journal
of Computer and Chemical Engineering 24 : 1901-1912.
R.Logendran, A workload based model for minimizing total intercell and
intracell moves in cellular manufacturing.International Journal of Production
Research , 28(5) : 913-925.

You might also like