You are on page 1of 2


Annals ofDAAAM for 2009 & Proceedings of the 20th International DAAAM Symposium, Volume 20, No, l, ISSN 1726-9679
ISBN 978-3-901509-70-4, Editor B, Katalinic, Published by DAAAM International, Vienna, Austria, EU, 2009
Make Harmony Between Technology and Nature, and Your Mind will Fly Free as a Bird
4th UPS



MAJSTOROVIC, V[lado]; RAKIC, Klresmr] & BANDIC GLAVAS, M[arijana]

Abstract: Coordination of all participants performing' business (Majstorovic, 2001), Each network diagram must meet the
tasks is of, great importance and decisive impact on the following requirements:
efficiency of its execlit ion, Integrated observing of excution of
there is only one initial and one final event of the project;
the business project provides significantly better planning of
there is at least one path from the initial to the final event of
implementation process and increases the efficiency of the project;
managing these projects. Recognizing the need for continued
specialized software solutions for computer-aided project for .each event there is at least one path to the final event of
I the project;
management, we decide t create a comprehensive software
the existence of cycles is not allowed,
package that will enable us faster and more efficient operation
in the future. In this paper we describe the application of well-
known Floyd-Warshall algorithm for finding the critical path in , In terms of graph, theory; graph vertices represent the
project time analysis. events, and its edges represent project. activities. pue to the hICk
Key words: project management, critical path method, graph of multiply arcs and loops" the network diagram is a strict,
theory, floyd-warshall algorithm directed graph p(Veljan, 2001), Therefore, in our analysis, we
, "
can apply all the known algorithms from mathematical graph
, theory that will help us in solving our tasks, I

To illustrate the usability of these algorithms il). this paper

we des~ribe the .application of well-known Floyd-Warshall
In terms of the increasing division 'of' labor and
algorithm for finding the critical path ({?PM - Critical Path
specialization,' planning and management 'projects becoming
Method) in project tinW analysis, In this analysis, each activity
more complex. Coordination of the participants in performing
is associated with a numeric value that represents its duration.
the business task is of great' importance and' decisive impact on
From the standpoint of graph theory, these numerical values
the efficiency of its execution. Integrated observing" of
can be interpreted as a weight value of edges, so in this case,
execution of business project provides significantly better
the network diagram is an strict weighted directed graph D,
planning of implementation process and increasest-' the
which is very suitable for performing the aforementioned
efficiency of managing these projects, Network planning
Floyd-Warshall's algorithm
methods have the advantage compared-to other methods which
have complete look' at the process of bussines project
realization, because they provide a clear enough view of 3. MODIFIED FLOYD-WARSHALL ALGORITHM
realization' of the 'entire work, unambiguous view of logical
course of mutual dependence" of parts and' 'processes, more Original Floyd-Warshall algorithm compares all possible
precisely and more accurately determine parts of the project paths through the strict' weighted directed graph D between
deadlines and the project as a whole as well as they determine each pair of vertices (Cormen et al., 2001), If' we assume that a
the most burdened pathfrum time aspect (Andrijic, 1982)', strict . weighted directed graph has no negative cycles, and
, Recognizing the need for continued specialized software
i network diagram for time analysis is just such a graph, Floyd-
solutions for computer-aided project management, we' are going Warshall algorithm finds the shortest path between each pair of
to create an comprehensive software package that will enable vertices in a single passage,
us faster and more efficient operation in the future, Despite the Considering that the longest path between initial and final
existence of similar software packages, we decided for this' step vertex of network diagram, as well as paths between all pairs of
because of the need fOI' concrete customizing software solutions internal vertices (due to possible multiple critical paths between
to real problems that we encounter every day, ' any pairs of nodes), is crucial for determination of critical path,
we will modify the Floyd-Warshall algorithm to find the
2. MAIN IDEA longest paths between vertices instead of the shortest ones, First
we will describe modified Floyd-Warshall algorithm for finding
Noticing a strong corelation between the concepts of critical paths in the network diagram.
network planning and concepts of mathematical graph theory, Let D be strict weighted directed graph and let
along 'with a detailed study of th many algorithms used in VD = {VI, V2, "" VII} be set of n vertices of graph D, insome
graph theory, we concluded that the mentioned algorithms can order. We will define an recursive function LongestPath(i,j, k):
very effectively used to solve specific 'problems encountered in LongestPath(i, j, k) = Maximal(LongestPath(i,j, k-L),
project management. LongestPath(i, k, k-l) + LongestPath(k,j, k-l));
The basis of network planning is the network diagram that LongestPath(i,j, O) =ArcWeight(i,j);
consists of activities, 'or parts of projects, 'which can be
for which We claim that, as a result, returns the longest possible
considered as separate entities from' the feasibility and
path starting at the Vi and ending at the Vj, using only the
economic point of view, and events, or moments of time where
vertices VI, "" Vk as an intermediate points along the path,
one or more activities begin or end, Each activity, as well as the
entire project, has a initial event and final event. An activity The basis of the algorithm is an adjacency matrix WeD) of
which initial event is i, and final event is j we will mark as Ai) weighted 'directed graph D, which gives us the value of the
function ArcWeight(i,j) for all vertices pairs (Vi, Vj)' Algorithm

for finding the longest path between each pair of peaks is O 4 4 5 00 00 00 00

carried out in n steps.
00 O O 00 8 00 00 00
The proof of correctness of the basics of Floyd-
Warshallovog algorithm, that is the above recursive formula
00 00 O 00 8 8 15 00

LongestPath(i, j, k), is carried out with an mathematical 00 00 00 O 00 7 00 00

induction, according to the cardinal number k of vertices set 00 00 00 00 O 00 6 00
{VI, V2, ... , vd E VD, which are used as an intermediate points 00 00 00 00 00 O 7 00
along the path.
00 00 00 00 00 00 O 2
Basis: For k = O set of vertices that we use as an
intermediate points along the path is an empty set. Thus, the 00 00 00 00 00 00 00 O
longest path beginning at the Vi and ending at the Vi' which does Fig. 2. Adjacency matrix WeD)
not contain any vertex as an intermediate point, is either equal
to the weight of arc starting at the Vi and ending at the Vj' if this
We geF the yalues of the latest beginnings by detracting the
arc exists, or it is not defined (i.e. has value 00) if there is no
results of Floyd-Warshall algorithm from the value of the
such arc. Those are the exact values that we can 'find in
earliest start of the final event. Final results will be as the
adjacency matrix WeD), or, in other words, the return values of
following figure:
function ArcWeight(i,j). This proves induction basis.
Assumption: We assume that the recursive function
LongestPath (i, j, k) returns the longest possible path starting at
the Vi and ending at the Vj' using only vertices VI, ... , Vk as an
intermediate points along the path.
Inductive step: Let us prove the claim for k+ l. Therefore,
we ar looking for the longest possible path starting at the Vi and
ending at the Vj, using only the vertices from the set
{VI, V2, ... , v), Vk+} as an intermediate points along the path:
There are two candidates for this path: it's either the path which
uses only the vertices from the st ' {vj, V2, ... , Vk} and Vk+1 is Fig. 3. Network diagram with completed time analysis' and
not used, or there is all' longer path that goes from Vi to Vk+l, and determined critical path .
further from Vk+1 to Vj' We know that the longest possible path
from Vi to Vi that uses only vertices VI, ... , Vk isdeterrnined by I" Critical project .activities are those activities in which have
function Longestl'ath, j, k). It is also obvious that, if thhe is a the same earliest and latest start (Heldman & Cram, 2004). In
langet path from Vi to Vj through the vertex Vk+' then its lenght our example, those activitis are A13, A36, A6? and A78 (marked
is the sum ofthe longest paths from Vi to V k+ I and from vj., I to Vj with thicker arrows), and they form, it critical path in time
(using only the set of vertices {VI, V2, ... , Vk}). Therefore: analysis of observed project.
LongestPath(i, j, k+ 1) = Maximal(LongestPath(i, j, k),
LongestPath(i, k+], k) + LongtestPath(k+1,j, k)); 5. CONCLUSWN ) ,
which proves the inductive step. J r : l ..

Since both the basis and the inductive step have been The presented problem is a simple 'example. of finding
proved, it has now been proved by mathematical induction that unique critica! path in project time analysis. Used the modified
our formula holds for all natural n. Q.E.D. Floyd-Warshall algorithm also allows the determination of
multiple critical paths; due to the fact that it determines the
4., iMPLEMENTATION EXAMPLE longest paths between each pair of vertices, not only between
the initial. and final vertex .. Once w,e determine .the critical
Functioning of the Floyd-Warshallov algorithm for finding project activities, vye can determine all the critical paths in,a
critical times in the project time analysis we will show using way that for every internal vertex of criticalpath (excluding
the following network diagram, initial and final vertex), verify the existence of an alternative
critical paths from the initial vertex to the observed one, which
does, not pass, all previously tested internal vertices of critical
Pflth., , ,I - I I J

This way of finding the critical path will be a basis of

software pack;age, which we plan to develop. In this direction
we face our further work.


Andrijic, S. (1.982). Matematicke metode programiranja u

organizacijama udruzenog rada (Mathematical Methods of
Fig. !. Example' of network diagram Programming in Organizations of Associated Labor)
Svjetlost;ISBN, Sarajevo ,
The final results of modified Floyd-Warshall algorithm are Cormen, T.H.; Leiserson, C.E.; Rivest R.L. & Stein C. q001)..
the longest paths between each pair of vertices of strict Introduction to Algorithms, 2nd Edition, The Ml'T Press,
weighted directed graph D. In the terminology of network ISBN 0-262,03293-7, Cambridge
planning these numerical values represent the earliest Heldman, W. & Cram, L. (2904). IT Project +, Sybex, ISBN 0-
beginnings of the project activities. 782!-43l8-0, San Francisco-London ,
The next step is to determine the latest baginnings of Majstorovic, V. (2001). Production and Project Management,
project activities. For this purpose, we observe the network . DAAAM, ISBN 3-90! 509-23-2, Mostar-Wien
diagram starting from the final event and all the activities 'in the Veljan, D. (200!). Kombinatorna i diskretna mqtematika
reverse direction, which is achieved by transforming the (Combinatorial and Discrete Mathematics), Algoritam,
adjacency matrix. ISBN 953-6450-74-7, Zagreb