0% found this document useful (0 votes)
34 views16 pages

Report

The document describes using critical path method (CPM) and linear programming software (CPLEX/LINGO) to analyze a project network and determine the minimum time to complete the project. It provides details of the mathematical model, including defining the network, decision variables, parameters, objective function, and constraints. It also describes applying the model and software to the given data to find an optimal solution that minimizes completion time while satisfying all requirements and precedence relationships.

Uploaded by

Lê Thế Kiên
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
34 views16 pages

Report

The document describes using critical path method (CPM) and linear programming software (CPLEX/LINGO) to analyze a project network and determine the minimum time to complete the project. It provides details of the mathematical model, including defining the network, decision variables, parameters, objective function, and constraints. It also describes applying the model and software to the given data to find an optimal solution that minimizes completion time while satisfying all requirements and precedence relationships.

Uploaded by

Lê Thế Kiên
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 16

VIETNAM NATIONAL UNIVERSITY – HCMC Final

INTERNATIONAL UNIVERSITY
Report

Instructor: Ha Thi Xuan Chi

GROUP Group member


1. IELSIU19158 - Nguyễn Hoàng Ngọc Hoài
7 2. IELSIU19180 - Lê Thế Kiên
3. IELSIU19156 - Nguyễn Thanh Hòa
4. IELSIU19136 - Vương Quốc Dũng
5. IELSIU19138 - Trần Võ Minh Duy

Monday, June 14th 2021


INTERNATIONAL UNIVERSITY Group 4: CRITICAL PATH METHOD IN
A PROJECT NETWORK

This project is aimed at minimizing project time subject to the


available resources using Critical Path Method (CPM) as a planning and
scheduling tool and the visual display of activities to show project
execution flow and coordination between activities based on a defined
algorithm using the Cplex/Lingo as a case study. Data in the problem
was provided by Mrs. Chi with the subject of Deterministic Models in
OR. Analysis of data was network based and use was made of
Cplex/Lingo software and CPM in solving linear programming
problems and performing some statistical tests respectively. Sensitivity
analysis and improvement to optimality using various methods were
also looked at to meet an optimum value.

Keywords: project planning, scheduling, critical path method, Cplex/Lingo


INTERNATIONAL UNIVERSITY Group 4: CRITICAL PATH METHOD IN
A PROJECT NETWORK

Table of Content
I. Introduction ......................................................................................1
1. General information .......................................................................................................1
2. Problem statement .........................................................................................................1

II. Mathematical model ........................................................................ 2


1. Network .......................................................................................................................... 2
2. Set.....................................................................................................................................3
3. Index ................................................................................................................................3
4. Decision variable ............................................................................................................3
5. Parameter........................................................................................................................ 3
6. Objective functions......................................................................................................... 4
7. Constraints...................................................................................................................... 4

III. Sensitivity analysis ..........................................................................4


1. Network ......................................................................................................................... 4
2. Application .....................................................................................................................4

IV. Application ...................................................................................... 5


V. Conclusion ......................................................................................... 7
VI. Appendix .......................................................................................... 7
1. Code Cplex: ORproject.mod ..........................................................................................7
2. Data Cplex: ORproject.dat ............................................................................................. 9
3. Result Cplex: Result.txt ................................................................................................ 10
4. Code Lingo: ORproject.lg4 ............................................................................................ 10

VII. References .......................................................................................11


VIII. Contribution form .........................................................................
INTERNATIONAL UNIVERSITY Group 4: CRITICAL PATH METHOD IN
A PROJECT NETWORK

I. Introduction
1. General information

It is considered as a fundamental quantitative tool of Management Science in which the


methods and techniques of Mathematics and the tools of computing, storing and processing
data of Informatics are applied to model, analyze and find solutions to decision problems,
in order to support the management apparatus to make the most reasonable decisions. In
the world, the research and application of Operations Studies is increasingly developing
extensively with many famous specialized journals, the subject of Operations Studies is
taught with a fairly large amount of time, including many rich and urgent contents in the
field of science and technology. many undergraduate and graduate programs.

One of the suggested methods to solve the OR project is CPLEX/LINGO, softwares that can
solve integer programming problems, linear programming problems with extremely large
sizes, quadratic programming problems and convex programming problems.

2. Problem statement

Before finding the solution, the task for a group of students was that they needed to decide
whether to invest in a company. The teacher guides them to perform the analysis in the
following 14 steps:
 1: Learn about the stock market
 2: Choose a company
 3: Find information and history of the chosen company
 4: Get the company's annual report and do an analysis of the indicators
 5: Make a specific investment strategy
 6: Evaluate the stock screening model
 7: Open stock account
 8: Ask for the staff or human resources at that company for information
 9: Financial investment analysis
 10: How will that market share change in the future?
 11: learn trading discipline
 12: Risk management
 13: Collect stock price data and make charts
 14: Evaluate data and make group decisions whether to buy stocks

1|Page
INTERNATIONAL UNIVERSITY Group 4: CRITICAL PATH METHOD IN
A PROJECT NETWORK

With the processing time and predecessor in the following table:

The objective of this problem is to satisfy the minimum time to complete the project if all
activities run on time; the activities that are critical to ensure that the project is finished in
the minimum time; the earliest start time and the latest finish time for each activity, if the
project is to be finished in the minimum time; the amount of time by which each activity
can be delayed without delaying the project as a whole. We use linear programming
software (CPLEX/LINGO) and critical path method (CPM) to solve the model for this
problem according to the provided data.

After using the given data time, the OR team of the project could achieve an optimal
solution (We will show it in detail in the next part).

II. Mathematical Model

1. Network

To solve this problem first we need to draw a network to have an insight about the
problem, our group chose activity on the arrow (AOA) network to illustrate the problem.
Our solution which is minimizing Cmax and finding critical path will be based on this
network.

2|Page
INTERNATIONAL UNIVERSITY Group 4: CRITICAL PATH METHOD IN
A PROJECT NETWORK

2. Set

n: Number of job

3. Index

i: The precedence Job


j: The immediate Job
k: The original Job

4. Decision variables:

Xij (binary) : the critical path


Xij = 1 if the path is chosen
Xij = 0 if the path is not chosen

5. Parameter:

a) Pij : The processing time of job (i,j)


b) ��� : the precedence relation between two job i and j.
��� = 1, if there is a direct path from job i to job j
��� = 0,if there is no direct path from job i to job j

6. Objective function

The Critical Path is the longest path between the start and finish nodes of the project
network. So, the objective is

� �

��� � = ��� ∗ ���


� �
7. Constraints:

For each node, the total input flow must equal to total output to balance the flow equation.
Our problem has only one beginning node and final node, so the critical path must go
through both. Also, it is important to assure that xij follow the presence constraints.

3|Page
INTERNATIONAL UNIVERSITY Group 4: CRITICAL PATH METHOD IN
A PROJECT NETWORK

a. Starting flow constraint:


��� = � (�)
�=�

b. Ending flow constraint:


��� = � (�)
�=�

c. Balance flow constraint:


� �

��� = ��� ∀� = �. . � − � (�)


�=� �=�

d. Precedence constraint:
��� ≤ ��� ∀�, ∀� (�)

e. Binary constraint:

��� = �; � (�)

III. Sensitivity Analysis

1. Definition
Sensitivity analysis is a systematic study of how sensitive optimal solutions are to changes
in the data. This includes the changes in coefficient of decision variables and the right hand
side..

2. Application
However, in this problem, only can the change in coefficient occur, so our analysis mainly
calculates the allowable range. Which is the allowable increase/decrease associated with
the original coefficient of a decision variable tells us the range in which the coefficient of a

4|Page
INTERNATIONAL UNIVERSITY Group 4: CRITICAL PATH METHOD IN
A PROJECT NETWORK

given decision variable in the objective function may be increased/ decreased without
changing the optimal solution, where all other data are fixed. Since, sensitivity analysis
cannot apply on integer model, we change the constraint of our decision variable (xij) from
binary to 0 ≤ xij ≤ 1. This allows us to use the Tool in Lingo to find allowable range for each
node.

Table 1: Allowable range deriving from Lingo

5|Page
INTERNATIONAL UNIVERSITY Group 4: CRITICAL PATH METHOD IN
A PROJECT NETWORK

From the above table, we can find the range of processing time for each job (i,j) that the
optimum does not change. Take node x(0,1) as an example, the duration of this job can
change from 0.0 (Current Coefficient – Allowable Increase) to 7.0 (Current Coefficient +
Allowable Decrease).

IV. Application
To better understand how CPM works, look at Figure below, which shows a CPM diagram
for constructing a house. All of the tasks required to finish the house and an estimated time
for each have been identified. The arrows indicate the links between the various steps and
their required sequence. As you can see, most of the jobs to be done can’t be started until
the house’s foundation and frame are completed. It will take five days to finish the
foundation and another seven days to erect the house frame. The activities linked by brown
arrows form the critical path for this project. It tells us that the fastest possible time the
house can be built is 38 days, the total time needed for all of the critical path tasks. The
noncritical path jobs, those connected with black arrows, can be delayed a bit or done early.
Short delays in installing appliances or roofing won’t delay construction of the house
because these activities don’t lie on the critical path.

Practical application (3)


The process layout arranges workflow around the production process. All workers
performing similar tasks are grouped together. Products pass from one workstation to
another (but not necessarily to every workstation). All grinding would be done in one area,
all assembling in another, and all inspection in yet another. The process layout with critical
path method (CPM) is best for firms that produce small numbers of a wide variety of
products, typically using general-purpose machines that can be changed rapidly to new
operations for different product designs. For example, a manufacturer of custom machinery
would use a process layout.

6|Page
INTERNATIONAL UNIVERSITY Group 4: CRITICAL PATH METHOD IN
A PROJECT NETWORK

V. Conclusion
This research used mathematical programming, based on the Deterministic model of
Operation Research, approach to formulate the decision model. Besides, we also clarified
the mathematical model into the Lingo application which is the better and quicker tool to
get the optimal solution of the model, and the final objective, in this case, is to find the ideal
critical path to manage the completion of duration. After this problem, we have chance to
approach the OR knowledge to solve the real case. And we hope that this problem will be
the motivation for the next generation of university students for knowing how to apply
what they learn and how they can handle the hard problem

VI. Appendix
1. Code Cplex: ORproject.mod

/*********************************************
* OPL 12.10.0.0 Model
* Author: Admin
* Creation Date: May 1, 2021 at 1:25:09 PM
*********************************************/
// Set:
int n=14;
// Range:
range job=0..n;
// Parameter
int P[job][job]=...;
int E[job][job]=...;
// Decision variable
dvar boolean x[job][job];
// Objective function
dexpr float z=sum(i in job, j in job)x[i][j]*P[i][j];
maximize z;
// Constraint

7|Page
INTERNATIONAL UNIVERSITY Group 4: CRITICAL PATH METHOD IN
A PROJECT NETWORK

subject to
{

contraint_1: // Staring Flow Constraint


sum(j in job) x[1][j] == 1;

constraint_2: // Ending Flow Constraint


sum(i in job) x[i][n] == 1;

contraint_3: // Precedence Contraint


forall (i in job, j in job)
x[i][j] <= E[i][j];

contraint_4: // Balance Flow Constraint


forall (k in 2..n-1)
sum(i in job)x[i][k] == sum(j in job)x[k][j];
}
execute write_result
{

var ofile = new IloOplOutputFile("Result.txt" ) ;


ofile.writeln(cplex.getObjValue());
ofile.writeln("Completion time: ",z);
ofile.writeln("Critical path: ");
for ( var i in job)
for (var j in job)
if (j < n)
{
if (x[i][j]==1)
ofile.write(j," - ");
}
ofile.write("14");
ofile.writeln();
ofile.writeln("_____________")
ofile.close();

8|Page
INTERNATIONAL UNIVERSITY Group 4: CRITICAL PATH METHOD IN
A PROJECT NETWORK

2.Data Cplex: ORproject.dat

a) ORproject.dat

b) ORproject.xlsx

9|Page
INTERNATIONAL UNIVERSITY Group 4: CRITICAL PATH METHOD IN
A PROJECT NETWORK

3. Result Cplex: Result.txt

4. Code Lingo: ORproject.lg4

model:
sets:
jobs/0,1,2,3,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ective function;
max=@sum(p(i,j):x(i,j)*d(i,j));

!Decision Variable Constraint;


@for(p(i,j):x(i,j)>=0);

!Staring Flow Constraint;


@sum(jobs(j):x(2,j))=1;

!Ending Flow Constrain;


@sum(jobs(i):x(i,15))=1;

!Precedence Constraint;
@for(p(i,j):x(i,j)<= e(i,j));

!Balance Flow Constraint;


@for(jobs(k)|k #GT# 2 #AND# k #LT# 15 :@sum (jobs(i):x(i,k))=
@sum(jobs(j):x(k,j)));

11 | P a g e
INTERNATIONAL UNIVERSITY Group 4: CRITICAL PATH METHOD IN
A PROJECT NETWORK

VII. References
https://www.youtube.com/watch?v=vUMGvpsb8dc

https://sms.wgtn.ac.nz/foswiki/pub/Events/TeacherDay/WebHome/Peter_Rachel_Linear_Progra
mming_and_Critical_Path_Analysis.pdf?fbclid=IwAR13SevsgjFB__QGnAR3vMlLF3vrkCKyPxRF2Wp
CckakRmcI2JHDMggdB38

https://116.90.59.164/MODSIM03/Volume_04/C06/04_Caccetta_Project.pdf?fbclid=IwAR3ae45r
U_eSX_MU82iu3GE3WWdIC_G4JqqhJvKP6gXhoHYE4_OIV1Aj81U

http://ikucukkoc.baun.edu.tr/lectures/EMM4129/Algorithms_for_Sequencing_and_Scheduling.pdf?
fbclid=IwAR3Glsx3EoTD2EO97s44mWdsF6ZgTZHrOpucOdAE69NL2GYh8WFymrEz_pQ

https://courses.lumenlearning.com/wmopen-introductiontobusiness/chapter/production-
planning/

12 | P a g e
INTERNATIONAL UNIVERSITY Group 4: CRITICAL PATH METHOD IN
A PROJECT NETWORK

Contribution form
Name and ID Evaluation
Lê Thế Kiên 100%
IELSIU19180
Nguyễn Hoàng Ngọc Hoài 100%
IELSIU19158
Nguyễn Thanh Hòa 100%
IELSIU19156
Trần Võ Minh Duy 100%
IELSIU19138
Vương Quốc Dũng 100%
IELSIU19136

The end
13 | P a g e

You might also like