SlideShare uma empresa Scribd logo
1 de 27
Linear Programming:
Two Phase Method
By
Er. ASHISH BANSODE
M.E. Civil-Water Res. Engg.
DEPARTMENT OF CIVIL ENGINEERING.
GOVERNMENT COLLEGE OF ENGINEERING
AURANGABAD-431 005
10/3/2013 Two-Phase Method 1
Two Phase Method
 In the Big M Method, we observed that it
was frequently necessary to add artificial
variables to the constraints to obtain an
initial basic feasible solution to an LPP. If
problem is to be solved, the artificial variable
must be driven to zero.
 The two phase method is another method to
handle these artificial variable. Here the LP
problem is solved in two phase.
10/3/2013 2Two-Phase Method
Phase I
1. In this phase, we find an ibfs to the original problem,
for this all artificial variable are to be driven to zero.
To do this an artificial objective function (w) is
created which is the sum of all artificial variables.
The new objective function is then minimized,
subjected to the constraints of the given original
problem using the simplex method. At the end of
Phase I, three cases arises
A. If the minimum value of w=0, and no artificial
variable appears in the basis at a positive level then
the given problem has no feasible solution and
procedure terminates.
10/3/2013 3Two-Phase Method
B. If the minimum value of w=0, and no artificial
variable appears in the basis, then a basic feasible
solution to the given problem is obtained.
C. If the minimum value of the w=0 and one or
more artificial variable appears in the basis at
zero level, then a feasible solution to the original
problem is obtained. However, we must take care
of this artificial variable and see that it never
become positive during Phase II computations.
10/3/2013 4Two-Phase Method
Phase II
 When Phase I results in (B) or (C), we go on for Phase
II to find optimum solution to the given LP problem.
The basic feasible solution found at the end of Phase I
now used as a starting solution for the original LP
problem. Mean that find table of Phase I becomes
initial table for Phase II in which artificial (auxiliary)
objective function is replaced by the original objective
function. Simplex method is then applied to arrive at
optimum solution.
 Note that the new objective function is always of
minimization type regardless of whether the original
problem of maximization or minimization type.
10/3/2013 5Two-Phase Method
Example 1
 Solve given LPP by Two-Phase Method
1 2 3
1 2 3
1 2 3
1 2 3
5 4 3
Subject to 2 6 20
6 5 10 76
8 3 6 50
Max Z x x x
x x x
x x x
x x x
10/3/2013 6Two-Phase Method
 Add artificial variable to the first constraint and slack
variable to second and third constraints.
 Phase I
 Assigning a cost 1 to artificial variable and cost o to
other variables, the objective function of the auxiliary
LPP is
1 2 3 1
1 2 3 1
1 2 3 1
1 2 3 1
1 2 3 2
* 0 0 0
* 0 0 0 0
Subject to 2 6 20
6 5 10 76
8 3 6 50
Min Z x x x A
Min Z x x x A
x x x A
x x x S
x x x S
10/3/2013 7Two-Phase Method
Basis
Variable
Coefficients of RHS Ratio
X1 X2 X3 S1 S2 A1
A1 2 1 -6 0 0 1 20
S1 6 5 10 1 0 0 76
S2 8 -3 6 0 1 0 50
Z* 0 0 0 0 0 -1 0
10/3/2013 8Two-Phase Method
 Row Calculations
 New Z=Old Z+R1
 X1 is entering variable and S2 is leaving variable
Basis
Variable
Coefficients of RHS Ratio
X1 X2 X3 S1 S2 A1
A1 2 1 -6 0 0 1 20 10
S1 6 5 10 1 0 0 76 76/6
S2 8 -3 6 0 1 0 50 50/8
Z* 2 1 -6 0 0 0 20
10/3/2013 9Two-Phase Method
 Row Calculations
 New R3=Old R3/8
 New R1=New R3*2-Old R1
 New R2=NewR3*6-Old R2
 New Z*=New R3*2-Old Z*
 X2 is entering variable and A1 is leaving variable
Basis
Variable
Coefficients of RHS Ratio
X1 X2 X3 S1 S2 A1
A1 0 1.75 -7.5 0 -1/4 1 7.5 4.28
S1 0 29/4 11/2 1 -0.75 0 77/2 5.31
X1 1 -3/8 6/8 0 1/8 0 50/8 ---
Z* 0 1.75 -7.5 0 -1/4 0 7.5
10/3/2013 10Two-Phase Method
 Row Calculations
 New R1=Old R1/1.75
 New R2=New R1*29/4-Old R2
 New R3=NewR1*(3/8)+Old R3
 New Z*=New R1-Old Z*
 As there is no artificial variable in the basis go to Phase
II
Basis
Variable
Coefficients of RHS Ratio
X1 X2 X3 S1 S2 A1
X2 0 1 -4.28 0 -0.14 0.57 4.28
S1 0 0 36.53 0 0.765 -4.13 7.47
X1 1 0 -8.86 0 0.073 0.041 7.85
Z* 0 0 0 0 0 0.08 0.01
10/3/2013 11Two-Phase Method
Phase II
 Consider the final Simplex table of Phase I, consider
the actual cost associated with the original variables.
Delete the artificial variable A1 column from the table
as it is eliminated in Phase II.
1 3 1 2
1 3 1 2
5 4 3 0 0
5 4 3 0 0 0
M ax Z x x x S S
M ax Z x x x S S
10/3/2013 12Two-Phase Method
 Row calculation: New Z=Old z+5(R3)-4(R1)
Basis
Variable
Coefficients of RHS Ratio
X1 X2 X3 S1 S2
X2 0 1 -4.28 0 -0.14 4.28 0
S1 0 0 36.53 0 0.765 7.47 0
X1 1 0 -0.86 0 0.073 7.85 7.85
Z* -5 4 -3 0 0
Basis
Variable
Coefficients of RHS Ratio
X1 X2 X3 S1 S2
X2 0 1 -4.28 0 -0.14 4.28
S1 0 0 36.53 0 0.765 7.47
X1 1 0 -0.86 0 0.073 7.855
Z* 0 0 9.82 0 0.925 22.14810/3/2013 13Two-Phase Method
 As the given problem is of maximization and all the
values in Z row are either zero or positive, an optimal
solution is reached and is given by
 X1=7.855
 X2=4.28 and
 Z=5X1-4X2+3X3
 Z=5(7.855)-4(4.28)+3(0)
 = 22.15
10/3/2013 14Two-Phase Method
Example 2
 Solve by Two-Phase Simplex Method
1 2 3
1 2 3
1 2 3
1 2 3
4 3 9
Subject to 2 4 6 15
6 6 12
, , 0
Max Z x x x
x x x
x x x
x x x
10/3/2013 15Two-Phase Method
 Add artificial variable to the first constraint and slack
variable to second and third constraints.
 Phase I
 Assigning a cost 1 to artificial variable and cost o to
other variables, the objective function of the auxiliary
LPP is
A new auxiliary linear programming problem
10/3/2013 Two-Phase Method 16
1 2 3 1 2
1 2
1 2 3 1 1
1 2 3 2 2
* 0 0 0
* 0
2 4 6 15
6 6 12
M in Z x x x A A
M in Z A A
x x x S A
x x x S A
Phase I
Basis
Variable
Coefficients of RHS
X1 X2 X3 S1 S2 A1 A1
A1 2 4 6 -1 0 1 O 15
A2 6 1 6 0 -1 0 1 12
Z* 0 0 0 0 0 -1 -1 0
10/3/2013 17Two-Phase Method
 Row Calculations
 New Z*=R3+R1+R2
 X3 is entering variable and A2 is leaving variable
Basis
Variabl
e
Coefficients of RHS Ratio
X1 X2 X3 S1 S2 A1 A1
A1 2 4 6 -1 0 1 O 15 15/6
A2 6 1 6 0 -1 0 1 12 12/6
Z* 8 5 12 -1 -1 0 0 27
10/3/2013 18Two-Phase Method
 Row Calculations
 New R2=Old R2/6
 New R1= New R2*6-Old R1
 New Z*=New R2*12-Old Z*
 X2 is entering variable and A1 is leaving variable
Basis
Variabl
e
Coefficients of RHS Ratio
X1 X2 X3 S1 S2 A1 A2
A1 -4 3 0 -1 1 1 -1 3 1
X3 1 1/6 1 0 -1/6 0 1/6 2 12
Z* -4 3 0 -1 1 0 -2 3
10/3/2013 19Two-Phase Method
 Row Calculations
 New R1=Old R1/3
 New R2= New R1*(1/6)-Old R2
 New Z*=New R1*3-Old Z*
 Optimality condition is satisfied as Z* is having zero
value
Basis
Variable
Coefficients of RHS
X1 X2 X3 S1 S2 A1 A2
X2 -4/3 1 0 -1/3 1/3 1/3 -1/3 1
X3 11/9 0 1 1/18 -2/9 -2/27 2/9 11/6
Z* 0 0 0 0 0 -1 -1 0
10/3/2013 20Two-Phase Method
Phase II
 Original objective function is given as
 Consider the final Simplex table of Phase I, consider
the actual cost associated with the original variables.
Delete the artificial variable A1 column from the table
as it is eliminated in Phase II.
1 2 3 1 2
1 2 3 1 2
1 2 3 1
1 2 3 2
1 2 3
4 3 9 0 0
4 3 9 0 0
Subject to 2 4 6 0 15
6 6 0 12
, , 0
M ax Z x x x S S
M ax Z x x x S S
x x x S
x x x S
x x x
10/3/2013 21Two-Phase Method
Initial Basic Feasible Solution
 Row calculations New Z=OldZ-3R1-9R2
Basis
Variable
Coefficients of RHS
X1 X2 X3 S1 S2
X2 -4/3 1 0 -1/3 1/3
X3 11/9 0 1 1/18 -2/9
Z 4 3 9 0 0 0
10/3/2013 22Two-Phase Method
 X1 is entering variable and X3 is leaving variable
Basis
Variable
Coefficients of RHS Ratio
X1 X2 X3 S1 S2
X2 -4/3 1 0 -1/3 1/3 1 ---
X3 11/9 0 1 1/18 -2/9 11/6 1.5
Z -3 0 0 1/2 1 -19/5
10/3/2013 23Two-Phase Method
 Row Calculations
 New R2=Old R2/(11/9)
 New R1=New R2+Old R1
 New Z= New R2*3+Old Z
 As all the values in Z row are zero or positive, the
condition of optimality is reached.
Basis
Variable
Coefficients of RH
S
Ratio
X1 X2 X3 S1 S2
X2 0 1 12/11 -3/11 13/33 3
X1 1 0 9/11 1/22 -2/11 3/2
Z 0 0 27/11 7/11 3/11 -15
10/3/2013 24Two-Phase Method
 X1=3/2
 X3=3
 Hence Z=-4x1-3x2-9x3
Z=-4(1.5)-3(3)-9(0)
Z=-15
10/3/2013 25Two-Phase Method
Exercise
1.
2.
1 2 3
1 2 3
1 2 3
1 2 3
1 2 3
2
Subject to 4 6 3 8
3 6 4 1
2 3 5 4
, , 0
M ax Z x x x
x x x
x x x
x x x
x x x
1 2
1 2
1 2
1 2
2
Subject to 2
4
, 0
Min Z x x
x x
x x
x x
10/3/2013 26Two-Phase Method
3.
1 2 3
1 2 3
1 2
2 3
1 2 3
5 2 3
Subject to 2 2 2
3 4 3
3 5
, , 0
M ax Z x x x
x x x
x x
x x
x x x
10/3/2013 27Two-Phase Method

Mais conteúdo relacionado

Mais procurados

Unit.3. duality and sensetivity analisis
Unit.3. duality and sensetivity analisisUnit.3. duality and sensetivity analisis
Unit.3. duality and sensetivity analisisDagnaygebawGoshme
 
Post-optimal analysis of LPP
Post-optimal analysis of LPPPost-optimal analysis of LPP
Post-optimal analysis of LPPRAVI PRASAD K.J.
 
Duality in Linear Programming
Duality in Linear ProgrammingDuality in Linear Programming
Duality in Linear Programmingjyothimonc
 
Branch and Bound technique to solve Integer Linear Programming
Branch and Bound technique to solve Integer Linear ProgrammingBranch and Bound technique to solve Integer Linear Programming
Branch and Bound technique to solve Integer Linear ProgrammingKaivalya Shah
 
Linear programming graphical method
Linear programming graphical methodLinear programming graphical method
Linear programming graphical methodDr. Abdulfatah Salem
 
Linear Programming Problems : Dr. Purnima Pandit
Linear Programming Problems : Dr. Purnima PanditLinear Programming Problems : Dr. Purnima Pandit
Linear Programming Problems : Dr. Purnima PanditPurnima Pandit
 
Simplex method - Maximisation Case
Simplex method - Maximisation CaseSimplex method - Maximisation Case
Simplex method - Maximisation CaseJoseph Konnully
 
North West Corner Rule
North   West Corner RuleNorth   West Corner Rule
North West Corner Ruleitsvineeth209
 
Canonical form and Standard form of LPP
Canonical form and Standard form of LPPCanonical form and Standard form of LPP
Canonical form and Standard form of LPPSundar B N
 
primal and dual problem
primal and dual problemprimal and dual problem
primal and dual problemYash Lad
 
Graphical Method
Graphical MethodGraphical Method
Graphical MethodSachin MK
 
Transportation and Assignment
Transportation and AssignmentTransportation and Assignment
Transportation and AssignmentLokesh Payasi
 

Mais procurados (20)

simplex method
simplex methodsimplex method
simplex method
 
Simplex two phase
Simplex two phaseSimplex two phase
Simplex two phase
 
Unit.3. duality and sensetivity analisis
Unit.3. duality and sensetivity analisisUnit.3. duality and sensetivity analisis
Unit.3. duality and sensetivity analisis
 
Post-optimal analysis of LPP
Post-optimal analysis of LPPPost-optimal analysis of LPP
Post-optimal analysis of LPP
 
Duality in Linear Programming
Duality in Linear ProgrammingDuality in Linear Programming
Duality in Linear Programming
 
Branch and Bound technique to solve Integer Linear Programming
Branch and Bound technique to solve Integer Linear ProgrammingBranch and Bound technique to solve Integer Linear Programming
Branch and Bound technique to solve Integer Linear Programming
 
Linear programming graphical method
Linear programming graphical methodLinear programming graphical method
Linear programming graphical method
 
Big m method
Big m methodBig m method
Big m method
 
Linear Programming Problems : Dr. Purnima Pandit
Linear Programming Problems : Dr. Purnima PanditLinear Programming Problems : Dr. Purnima Pandit
Linear Programming Problems : Dr. Purnima Pandit
 
Simplex method - Maximisation Case
Simplex method - Maximisation CaseSimplex method - Maximisation Case
Simplex method - Maximisation Case
 
North West Corner Rule
North   West Corner RuleNorth   West Corner Rule
North West Corner Rule
 
Simplex Algorithm
Simplex AlgorithmSimplex Algorithm
Simplex Algorithm
 
Simplex algorithm
Simplex algorithmSimplex algorithm
Simplex algorithm
 
Canonical form and Standard form of LPP
Canonical form and Standard form of LPPCanonical form and Standard form of LPP
Canonical form and Standard form of LPP
 
primal and dual problem
primal and dual problemprimal and dual problem
primal and dual problem
 
Operations Research - The Two Phase Method
Operations Research - The Two Phase MethodOperations Research - The Two Phase Method
Operations Research - The Two Phase Method
 
Graphical Method
Graphical MethodGraphical Method
Graphical Method
 
Simplex Method.pptx
Simplex Method.pptxSimplex Method.pptx
Simplex Method.pptx
 
Transportation and Assignment
Transportation and AssignmentTransportation and Assignment
Transportation and Assignment
 
Big M method
Big M methodBig M method
Big M method
 

Destaque

Special Cases in Simplex Method
Special Cases in Simplex MethodSpecial Cases in Simplex Method
Special Cases in Simplex MethodDivyansh Verma
 
Simplex method Big M infeasible
Simplex method Big M infeasibleSimplex method Big M infeasible
Simplex method Big M infeasibleIzzati Hamid
 
optimization simplex method introduction
optimization simplex method introductionoptimization simplex method introduction
optimization simplex method introductionKunal Shinde
 
Dual y simplex dual
Dual y simplex dualDual y simplex dual
Dual y simplex dualpuracastillo
 
Graphical Method Of LPP
Graphical Method Of LPPGraphical Method Of LPP
Graphical Method Of LPPKJ Savaliya
 
Mean field Green function solution of the two-band Hubbard model in cuprates
Mean field Green function solution of the two-band Hubbard model in cupratesMean field Green function solution of the two-band Hubbard model in cuprates
Mean field Green function solution of the two-band Hubbard model in cupratesABDERRAHMANE REGGAD
 
Abel - A great mathematician
Abel - A great mathematicianAbel - A great mathematician
Abel - A great mathematicianNandiniNandus
 
Simplex method
Simplex methodSimplex method
Simplex methodAbu Bashar
 
Artificial Variable Technique –
Artificial Variable Technique –Artificial Variable Technique –
Artificial Variable Technique –itsvineeth209
 
Solving linear programming model by simplex method
Solving linear programming model by simplex methodSolving linear programming model by simplex method
Solving linear programming model by simplex methodRoshan Kumar Patel
 

Destaque (20)

Big-M Method Presentation
Big-M Method PresentationBig-M Method Presentation
Big-M Method Presentation
 
Special Cases in Simplex Method
Special Cases in Simplex MethodSpecial Cases in Simplex Method
Special Cases in Simplex Method
 
Operations research 1_the_two-phase_simp
Operations research 1_the_two-phase_simpOperations research 1_the_two-phase_simp
Operations research 1_the_two-phase_simp
 
Simplex method Big M infeasible
Simplex method Big M infeasibleSimplex method Big M infeasible
Simplex method Big M infeasible
 
optimization simplex method introduction
optimization simplex method introductionoptimization simplex method introduction
optimization simplex method introduction
 
Dual y simplex dual
Dual y simplex dualDual y simplex dual
Dual y simplex dual
 
S1 Dualsimplex
S1 DualsimplexS1 Dualsimplex
S1 Dualsimplex
 
Graphical Method Of LPP
Graphical Method Of LPPGraphical Method Of LPP
Graphical Method Of LPP
 
Mean field Green function solution of the two-band Hubbard model in cuprates
Mean field Green function solution of the two-band Hubbard model in cupratesMean field Green function solution of the two-band Hubbard model in cuprates
Mean field Green function solution of the two-band Hubbard model in cuprates
 
Abel - A great mathematician
Abel - A great mathematicianAbel - A great mathematician
Abel - A great mathematician
 
Dual simplexmethod
Dual simplexmethodDual simplexmethod
Dual simplexmethod
 
Number theory lecture (part 1)
Number theory lecture (part 1)Number theory lecture (part 1)
Number theory lecture (part 1)
 
Simplex method
Simplex methodSimplex method
Simplex method
 
Artificial Variable Technique –
Artificial Variable Technique –Artificial Variable Technique –
Artificial Variable Technique –
 
Number theory Grade 7, 8 and 9
Number theory Grade 7, 8 and 9Number theory Grade 7, 8 and 9
Number theory Grade 7, 8 and 9
 
Number theory
Number theoryNumber theory
Number theory
 
OR 14 15-unit_1
OR 14 15-unit_1OR 14 15-unit_1
OR 14 15-unit_1
 
Types of coagulants
Types of coagulantsTypes of coagulants
Types of coagulants
 
Solving linear programming model by simplex method
Solving linear programming model by simplex methodSolving linear programming model by simplex method
Solving linear programming model by simplex method
 
Simplex method
Simplex methodSimplex method
Simplex method
 

Semelhante a LINEAR PROGRAMMING

Twophasemethod 131003081339-phpapp01
Twophasemethod 131003081339-phpapp01Twophasemethod 131003081339-phpapp01
Twophasemethod 131003081339-phpapp01kongara
 
Simplex Method Explained
Simplex Method ExplainedSimplex Method Explained
Simplex Method ExplainedAtif Shahzad
 
Simplex Algorithm
Simplex AlgorithmSimplex Algorithm
Simplex AlgorithmAizaz Ahmad
 
Optimum Solution of Quadratic Programming Problem: By Wolfe’s Modified Simple...
Optimum Solution of Quadratic Programming Problem: By Wolfe’s Modified Simple...Optimum Solution of Quadratic Programming Problem: By Wolfe’s Modified Simple...
Optimum Solution of Quadratic Programming Problem: By Wolfe’s Modified Simple...IJLT EMAS
 
Simplex part 2 of 4
Simplex part 2 of 4Simplex part 2 of 4
Simplex part 2 of 4Ed Dansereau
 
CHAPTER 7.pdfdjdjdjdjdjdjdjsjsjddhhdudsko
CHAPTER 7.pdfdjdjdjdjdjdjdjsjsjddhhdudskoCHAPTER 7.pdfdjdjdjdjdjdjdjsjsjddhhdudsko
CHAPTER 7.pdfdjdjdjdjdjdjdjsjsjddhhdudskoSydneyJaydeanKhanyil
 
OR Linear Programming
OR Linear ProgrammingOR Linear Programming
OR Linear Programmingchaitu87
 
Linear programming
Linear programmingLinear programming
Linear programmingsabin kafle
 
simplex method-maths 4 mumbai university
simplex method-maths 4 mumbai universitysimplex method-maths 4 mumbai university
simplex method-maths 4 mumbai universityshobhakedari59
 
performance management and Resource optimization part-2.pptx
performance management and Resource optimization part-2.pptxperformance management and Resource optimization part-2.pptx
performance management and Resource optimization part-2.pptxtefera21
 
Applied numerical methods lec6
Applied numerical methods lec6Applied numerical methods lec6
Applied numerical methods lec6Yasser Ahmed
 
Numerical integration
Numerical integration Numerical integration
Numerical integration Dhyey Shukla
 
Integer Linear Programming
Integer Linear ProgrammingInteger Linear Programming
Integer Linear ProgrammingSukhpalRamanand
 
18-21 Principles of Least Squares.ppt
18-21 Principles of Least Squares.ppt18-21 Principles of Least Squares.ppt
18-21 Principles of Least Squares.pptBAGARAGAZAROMUALD2
 
Chapter 12 Dynamic programming.pptx
Chapter 12 Dynamic programming.pptxChapter 12 Dynamic programming.pptx
Chapter 12 Dynamic programming.pptxMdSazolAhmmed
 
3rd-edition-linear-algebra-and-its-applications-solutions-manual.pdf
3rd-edition-linear-algebra-and-its-applications-solutions-manual.pdf3rd-edition-linear-algebra-and-its-applications-solutions-manual.pdf
3rd-edition-linear-algebra-and-its-applications-solutions-manual.pdfJennifer Strong
 

Semelhante a LINEAR PROGRAMMING (20)

Twophasemethod 131003081339-phpapp01
Twophasemethod 131003081339-phpapp01Twophasemethod 131003081339-phpapp01
Twophasemethod 131003081339-phpapp01
 
Simplex Method Explained
Simplex Method ExplainedSimplex Method Explained
Simplex Method Explained
 
Simplex Algorithm
Simplex AlgorithmSimplex Algorithm
Simplex Algorithm
 
aaoczc2252
aaoczc2252aaoczc2252
aaoczc2252
 
Optimum Solution of Quadratic Programming Problem: By Wolfe’s Modified Simple...
Optimum Solution of Quadratic Programming Problem: By Wolfe’s Modified Simple...Optimum Solution of Quadratic Programming Problem: By Wolfe’s Modified Simple...
Optimum Solution of Quadratic Programming Problem: By Wolfe’s Modified Simple...
 
MFCS2-Module1.pptx
MFCS2-Module1.pptxMFCS2-Module1.pptx
MFCS2-Module1.pptx
 
Simplex part 2 of 4
Simplex part 2 of 4Simplex part 2 of 4
Simplex part 2 of 4
 
CHAPTER 7.pdfdjdjdjdjdjdjdjsjsjddhhdudsko
CHAPTER 7.pdfdjdjdjdjdjdjdjsjsjddhhdudskoCHAPTER 7.pdfdjdjdjdjdjdjdjsjsjddhhdudsko
CHAPTER 7.pdfdjdjdjdjdjdjdjsjsjddhhdudsko
 
OR Linear Programming
OR Linear ProgrammingOR Linear Programming
OR Linear Programming
 
Linear programming
Linear programmingLinear programming
Linear programming
 
simplex method-maths 4 mumbai university
simplex method-maths 4 mumbai universitysimplex method-maths 4 mumbai university
simplex method-maths 4 mumbai university
 
performance management and Resource optimization part-2.pptx
performance management and Resource optimization part-2.pptxperformance management and Resource optimization part-2.pptx
performance management and Resource optimization part-2.pptx
 
Applied numerical methods lec6
Applied numerical methods lec6Applied numerical methods lec6
Applied numerical methods lec6
 
Simplex Algorithm
Simplex AlgorithmSimplex Algorithm
Simplex Algorithm
 
Numerical integration
Numerical integration Numerical integration
Numerical integration
 
Integer Linear Programming
Integer Linear ProgrammingInteger Linear Programming
Integer Linear Programming
 
18-21 Principles of Least Squares.ppt
18-21 Principles of Least Squares.ppt18-21 Principles of Least Squares.ppt
18-21 Principles of Least Squares.ppt
 
Xx
XxXx
Xx
 
Chapter 12 Dynamic programming.pptx
Chapter 12 Dynamic programming.pptxChapter 12 Dynamic programming.pptx
Chapter 12 Dynamic programming.pptx
 
3rd-edition-linear-algebra-and-its-applications-solutions-manual.pdf
3rd-edition-linear-algebra-and-its-applications-solutions-manual.pdf3rd-edition-linear-algebra-and-its-applications-solutions-manual.pdf
3rd-edition-linear-algebra-and-its-applications-solutions-manual.pdf
 

Último

A Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformA Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformChameera Dedduwage
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introductionMaksud Ahmed
 
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxSOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxiammrhaywood
 
The Most Excellent Way | 1 Corinthians 13
The Most Excellent Way | 1 Corinthians 13The Most Excellent Way | 1 Corinthians 13
The Most Excellent Way | 1 Corinthians 13Steve Thomason
 
Interactive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationInteractive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationnomboosow
 
Activity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfActivity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfciinovamais
 
Separation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and ActinidesSeparation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and ActinidesFatimaKhan178732
 
Hybridoma Technology ( Production , Purification , and Application )
Hybridoma Technology  ( Production , Purification , and Application  ) Hybridoma Technology  ( Production , Purification , and Application  )
Hybridoma Technology ( Production , Purification , and Application ) Sakshi Ghasle
 
Arihant handbook biology for class 11 .pdf
Arihant handbook biology for class 11 .pdfArihant handbook biology for class 11 .pdf
Arihant handbook biology for class 11 .pdfchloefrazer622
 
Measures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and ModeMeasures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and ModeThiyagu K
 
1029-Danh muc Sach Giao Khoa khoi 6.pdf
1029-Danh muc Sach Giao Khoa khoi  6.pdf1029-Danh muc Sach Giao Khoa khoi  6.pdf
1029-Danh muc Sach Giao Khoa khoi 6.pdfQucHHunhnh
 
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...EduSkills OECD
 
mini mental status format.docx
mini    mental       status     format.docxmini    mental       status     format.docx
mini mental status format.docxPoojaSen20
 
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...Marc Dusseiller Dusjagr
 
Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104misteraugie
 
Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityParis 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityGeoBlogs
 
URLs and Routing in the Odoo 17 Website App
URLs and Routing in the Odoo 17 Website AppURLs and Routing in the Odoo 17 Website App
URLs and Routing in the Odoo 17 Website AppCeline George
 
Introduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptxIntroduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptxpboyjonauth
 
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxPOINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxSayali Powar
 

Último (20)

A Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformA Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy Reform
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introduction
 
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxSOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
 
The Most Excellent Way | 1 Corinthians 13
The Most Excellent Way | 1 Corinthians 13The Most Excellent Way | 1 Corinthians 13
The Most Excellent Way | 1 Corinthians 13
 
Interactive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationInteractive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communication
 
Activity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfActivity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdf
 
Separation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and ActinidesSeparation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and Actinides
 
Hybridoma Technology ( Production , Purification , and Application )
Hybridoma Technology  ( Production , Purification , and Application  ) Hybridoma Technology  ( Production , Purification , and Application  )
Hybridoma Technology ( Production , Purification , and Application )
 
Arihant handbook biology for class 11 .pdf
Arihant handbook biology for class 11 .pdfArihant handbook biology for class 11 .pdf
Arihant handbook biology for class 11 .pdf
 
Measures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and ModeMeasures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and Mode
 
1029-Danh muc Sach Giao Khoa khoi 6.pdf
1029-Danh muc Sach Giao Khoa khoi  6.pdf1029-Danh muc Sach Giao Khoa khoi  6.pdf
1029-Danh muc Sach Giao Khoa khoi 6.pdf
 
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
 
mini mental status format.docx
mini    mental       status     format.docxmini    mental       status     format.docx
mini mental status format.docx
 
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
 
INDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptx
INDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptxINDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptx
INDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptx
 
Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104
 
Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityParis 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activity
 
URLs and Routing in the Odoo 17 Website App
URLs and Routing in the Odoo 17 Website AppURLs and Routing in the Odoo 17 Website App
URLs and Routing in the Odoo 17 Website App
 
Introduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptxIntroduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptx
 
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxPOINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
 

LINEAR PROGRAMMING

  • 1. Linear Programming: Two Phase Method By Er. ASHISH BANSODE M.E. Civil-Water Res. Engg. DEPARTMENT OF CIVIL ENGINEERING. GOVERNMENT COLLEGE OF ENGINEERING AURANGABAD-431 005 10/3/2013 Two-Phase Method 1
  • 2. Two Phase Method  In the Big M Method, we observed that it was frequently necessary to add artificial variables to the constraints to obtain an initial basic feasible solution to an LPP. If problem is to be solved, the artificial variable must be driven to zero.  The two phase method is another method to handle these artificial variable. Here the LP problem is solved in two phase. 10/3/2013 2Two-Phase Method
  • 3. Phase I 1. In this phase, we find an ibfs to the original problem, for this all artificial variable are to be driven to zero. To do this an artificial objective function (w) is created which is the sum of all artificial variables. The new objective function is then minimized, subjected to the constraints of the given original problem using the simplex method. At the end of Phase I, three cases arises A. If the minimum value of w=0, and no artificial variable appears in the basis at a positive level then the given problem has no feasible solution and procedure terminates. 10/3/2013 3Two-Phase Method
  • 4. B. If the minimum value of w=0, and no artificial variable appears in the basis, then a basic feasible solution to the given problem is obtained. C. If the minimum value of the w=0 and one or more artificial variable appears in the basis at zero level, then a feasible solution to the original problem is obtained. However, we must take care of this artificial variable and see that it never become positive during Phase II computations. 10/3/2013 4Two-Phase Method
  • 5. Phase II  When Phase I results in (B) or (C), we go on for Phase II to find optimum solution to the given LP problem. The basic feasible solution found at the end of Phase I now used as a starting solution for the original LP problem. Mean that find table of Phase I becomes initial table for Phase II in which artificial (auxiliary) objective function is replaced by the original objective function. Simplex method is then applied to arrive at optimum solution.  Note that the new objective function is always of minimization type regardless of whether the original problem of maximization or minimization type. 10/3/2013 5Two-Phase Method
  • 6. Example 1  Solve given LPP by Two-Phase Method 1 2 3 1 2 3 1 2 3 1 2 3 5 4 3 Subject to 2 6 20 6 5 10 76 8 3 6 50 Max Z x x x x x x x x x x x x 10/3/2013 6Two-Phase Method
  • 7.  Add artificial variable to the first constraint and slack variable to second and third constraints.  Phase I  Assigning a cost 1 to artificial variable and cost o to other variables, the objective function of the auxiliary LPP is 1 2 3 1 1 2 3 1 1 2 3 1 1 2 3 1 1 2 3 2 * 0 0 0 * 0 0 0 0 Subject to 2 6 20 6 5 10 76 8 3 6 50 Min Z x x x A Min Z x x x A x x x A x x x S x x x S 10/3/2013 7Two-Phase Method
  • 8. Basis Variable Coefficients of RHS Ratio X1 X2 X3 S1 S2 A1 A1 2 1 -6 0 0 1 20 S1 6 5 10 1 0 0 76 S2 8 -3 6 0 1 0 50 Z* 0 0 0 0 0 -1 0 10/3/2013 8Two-Phase Method
  • 9.  Row Calculations  New Z=Old Z+R1  X1 is entering variable and S2 is leaving variable Basis Variable Coefficients of RHS Ratio X1 X2 X3 S1 S2 A1 A1 2 1 -6 0 0 1 20 10 S1 6 5 10 1 0 0 76 76/6 S2 8 -3 6 0 1 0 50 50/8 Z* 2 1 -6 0 0 0 20 10/3/2013 9Two-Phase Method
  • 10.  Row Calculations  New R3=Old R3/8  New R1=New R3*2-Old R1  New R2=NewR3*6-Old R2  New Z*=New R3*2-Old Z*  X2 is entering variable and A1 is leaving variable Basis Variable Coefficients of RHS Ratio X1 X2 X3 S1 S2 A1 A1 0 1.75 -7.5 0 -1/4 1 7.5 4.28 S1 0 29/4 11/2 1 -0.75 0 77/2 5.31 X1 1 -3/8 6/8 0 1/8 0 50/8 --- Z* 0 1.75 -7.5 0 -1/4 0 7.5 10/3/2013 10Two-Phase Method
  • 11.  Row Calculations  New R1=Old R1/1.75  New R2=New R1*29/4-Old R2  New R3=NewR1*(3/8)+Old R3  New Z*=New R1-Old Z*  As there is no artificial variable in the basis go to Phase II Basis Variable Coefficients of RHS Ratio X1 X2 X3 S1 S2 A1 X2 0 1 -4.28 0 -0.14 0.57 4.28 S1 0 0 36.53 0 0.765 -4.13 7.47 X1 1 0 -8.86 0 0.073 0.041 7.85 Z* 0 0 0 0 0 0.08 0.01 10/3/2013 11Two-Phase Method
  • 12. Phase II  Consider the final Simplex table of Phase I, consider the actual cost associated with the original variables. Delete the artificial variable A1 column from the table as it is eliminated in Phase II. 1 3 1 2 1 3 1 2 5 4 3 0 0 5 4 3 0 0 0 M ax Z x x x S S M ax Z x x x S S 10/3/2013 12Two-Phase Method
  • 13.  Row calculation: New Z=Old z+5(R3)-4(R1) Basis Variable Coefficients of RHS Ratio X1 X2 X3 S1 S2 X2 0 1 -4.28 0 -0.14 4.28 0 S1 0 0 36.53 0 0.765 7.47 0 X1 1 0 -0.86 0 0.073 7.85 7.85 Z* -5 4 -3 0 0 Basis Variable Coefficients of RHS Ratio X1 X2 X3 S1 S2 X2 0 1 -4.28 0 -0.14 4.28 S1 0 0 36.53 0 0.765 7.47 X1 1 0 -0.86 0 0.073 7.855 Z* 0 0 9.82 0 0.925 22.14810/3/2013 13Two-Phase Method
  • 14.  As the given problem is of maximization and all the values in Z row are either zero or positive, an optimal solution is reached and is given by  X1=7.855  X2=4.28 and  Z=5X1-4X2+3X3  Z=5(7.855)-4(4.28)+3(0)  = 22.15 10/3/2013 14Two-Phase Method
  • 15. Example 2  Solve by Two-Phase Simplex Method 1 2 3 1 2 3 1 2 3 1 2 3 4 3 9 Subject to 2 4 6 15 6 6 12 , , 0 Max Z x x x x x x x x x x x x 10/3/2013 15Two-Phase Method
  • 16.  Add artificial variable to the first constraint and slack variable to second and third constraints.  Phase I  Assigning a cost 1 to artificial variable and cost o to other variables, the objective function of the auxiliary LPP is A new auxiliary linear programming problem 10/3/2013 Two-Phase Method 16 1 2 3 1 2 1 2 1 2 3 1 1 1 2 3 2 2 * 0 0 0 * 0 2 4 6 15 6 6 12 M in Z x x x A A M in Z A A x x x S A x x x S A
  • 17. Phase I Basis Variable Coefficients of RHS X1 X2 X3 S1 S2 A1 A1 A1 2 4 6 -1 0 1 O 15 A2 6 1 6 0 -1 0 1 12 Z* 0 0 0 0 0 -1 -1 0 10/3/2013 17Two-Phase Method
  • 18.  Row Calculations  New Z*=R3+R1+R2  X3 is entering variable and A2 is leaving variable Basis Variabl e Coefficients of RHS Ratio X1 X2 X3 S1 S2 A1 A1 A1 2 4 6 -1 0 1 O 15 15/6 A2 6 1 6 0 -1 0 1 12 12/6 Z* 8 5 12 -1 -1 0 0 27 10/3/2013 18Two-Phase Method
  • 19.  Row Calculations  New R2=Old R2/6  New R1= New R2*6-Old R1  New Z*=New R2*12-Old Z*  X2 is entering variable and A1 is leaving variable Basis Variabl e Coefficients of RHS Ratio X1 X2 X3 S1 S2 A1 A2 A1 -4 3 0 -1 1 1 -1 3 1 X3 1 1/6 1 0 -1/6 0 1/6 2 12 Z* -4 3 0 -1 1 0 -2 3 10/3/2013 19Two-Phase Method
  • 20.  Row Calculations  New R1=Old R1/3  New R2= New R1*(1/6)-Old R2  New Z*=New R1*3-Old Z*  Optimality condition is satisfied as Z* is having zero value Basis Variable Coefficients of RHS X1 X2 X3 S1 S2 A1 A2 X2 -4/3 1 0 -1/3 1/3 1/3 -1/3 1 X3 11/9 0 1 1/18 -2/9 -2/27 2/9 11/6 Z* 0 0 0 0 0 -1 -1 0 10/3/2013 20Two-Phase Method
  • 21. Phase II  Original objective function is given as  Consider the final Simplex table of Phase I, consider the actual cost associated with the original variables. Delete the artificial variable A1 column from the table as it is eliminated in Phase II. 1 2 3 1 2 1 2 3 1 2 1 2 3 1 1 2 3 2 1 2 3 4 3 9 0 0 4 3 9 0 0 Subject to 2 4 6 0 15 6 6 0 12 , , 0 M ax Z x x x S S M ax Z x x x S S x x x S x x x S x x x 10/3/2013 21Two-Phase Method
  • 22. Initial Basic Feasible Solution  Row calculations New Z=OldZ-3R1-9R2 Basis Variable Coefficients of RHS X1 X2 X3 S1 S2 X2 -4/3 1 0 -1/3 1/3 X3 11/9 0 1 1/18 -2/9 Z 4 3 9 0 0 0 10/3/2013 22Two-Phase Method
  • 23.  X1 is entering variable and X3 is leaving variable Basis Variable Coefficients of RHS Ratio X1 X2 X3 S1 S2 X2 -4/3 1 0 -1/3 1/3 1 --- X3 11/9 0 1 1/18 -2/9 11/6 1.5 Z -3 0 0 1/2 1 -19/5 10/3/2013 23Two-Phase Method
  • 24.  Row Calculations  New R2=Old R2/(11/9)  New R1=New R2+Old R1  New Z= New R2*3+Old Z  As all the values in Z row are zero or positive, the condition of optimality is reached. Basis Variable Coefficients of RH S Ratio X1 X2 X3 S1 S2 X2 0 1 12/11 -3/11 13/33 3 X1 1 0 9/11 1/22 -2/11 3/2 Z 0 0 27/11 7/11 3/11 -15 10/3/2013 24Two-Phase Method
  • 25.  X1=3/2  X3=3  Hence Z=-4x1-3x2-9x3 Z=-4(1.5)-3(3)-9(0) Z=-15 10/3/2013 25Two-Phase Method
  • 26. Exercise 1. 2. 1 2 3 1 2 3 1 2 3 1 2 3 1 2 3 2 Subject to 4 6 3 8 3 6 4 1 2 3 5 4 , , 0 M ax Z x x x x x x x x x x x x x x x 1 2 1 2 1 2 1 2 2 Subject to 2 4 , 0 Min Z x x x x x x x x 10/3/2013 26Two-Phase Method
  • 27. 3. 1 2 3 1 2 3 1 2 2 3 1 2 3 5 2 3 Subject to 2 2 2 3 4 3 3 5 , , 0 M ax Z x x x x x x x x x x x x x 10/3/2013 27Two-Phase Method