Presentation is loading. Please wait.

Presentation is loading. Please wait.

Solving Linear Programming Problems: Asst. Prof. Dr. Nergiz Kasımbeyli

Similar presentations


Presentation on theme: "Solving Linear Programming Problems: Asst. Prof. Dr. Nergiz Kasımbeyli"— Presentation transcript:

1 Solving Linear Programming Problems: Asst. Prof. Dr. Nergiz Kasımbeyli
ISE 203 OR I Chapter 4 Solving Linear Programming Problems: The Simplex Method Asst. Prof. Dr. Nergiz Kasımbeyli

2 The SIMPLEX Method Simplex method is an algebraic procedure
However, its underlying concepts are geometric Understanding these geometric concepts helps before going into their algebraic equivalents

3

4

5 In this example, the point of intersection of two constraint boundaries are the corner-point solutions of the problem. For a linear programming problem with n decision variables, each corner point solution lies at the intersection point of n constraints.

6 The points that lie on the corners of the feasible region are the corner-point feasible (CPF) solutions or extreme points.

7 Edges For any LP problem with n decision variables, two extreme points are adjacent to each other if they share n-1 constraint boundaries. The two adjacent extreme points are connected by a line segment that lies on these same shared constraint boundaries. Such a line segment is referred to as an edge of the feasible region.

8 An edge of the feasible region

9 Optimality test Consider any LP problem that possesses at least one optimal solution. If a CPF solution has no adjacent CPF solutions that are better (as measured by Z), then it must be an optimal solution. (This is due to the fact that the feasible region is a convex set, we will see in Chapter 5) (2,6) must be optimal since Z=36 is greater than Z=30 for (0,6) and Z=27 for (4,3). This is the optimality test used by Simplex.

10

11

12 The Simplex Method in a Nutshell
Initialization (Find initial CPF solution) Is the current CPF solution optimal? Yes Stop No Move to a better adjacent CPF solution

13 Introducing slack variables x3, x4 and x5 to convert inequalities into equalities – Convert LP to Augmented Form

14 Slack variables Slack variable = 0 in the current solution  This solution lies on the constraint boundary for the corresponding functional constraint.  Feasible solution, Binding constraint If slack variable ≥ 0 the solution lies on the feasible side of this constraint boundary.  Feasible solution, Nonbinding constraint If slack variable ≤ 0, the solution lies on the infeasible side of this constraint boundary.  Infeasible solution

15

16

17

18 ‘Language’ of the Simplex Method

19 Initial Assumptions All constraints are of the form ≤
All right-hand-side values (bj, j=1, …,m) are positive We’ll learn how to address other forms later

20 The Augmented Form Set up the method first:
Convert inequality constraints to equality constraints by adding slack variables Augmented (Standard) Form Maximize Z = 3x1+ 5x2 subject to x1 +s1 = 4 2x2 +s2 = 12 3x1+ 2x2 +s3 = 18 x1,x2 , s1, s2, s3 ≥ 0 Original Form Maximize Z = 3x1+ 5x2 subject to x1 ≤ 4 2x2 ≤ 12 3x1+ 2x2 ≤ 18 x1,x2 ≥ 0

21 Basic and Basic Feasible Solutions
X2 Augmented Form Maximize Z = 3x1+ 5x2 subject to x1 +s1 = 4 2x2 +s2 = 12 3x1+ 2x2 +s3 = 18 x1,x2, s1, s2, s3 ≥ 0 (0,9,4,-6,0) (0,6,4,0,6) (2,6,2,0,0) (4,6,0,0,-6) Augmented solution Basic infeasible solution Basic feasible solution (BFS) Nonbasic feasible solution (2,3,2,6,6) (4,3,0,6,0) (0,2,4,8,14) (0,0,4,12,18) (4,0,0,12,6) (6,0,-2,12,0) X1

22 Basic, Nonbasic Solutions and the Basis
In an LP, number of variables > number of equations The difference is the degrees of freedom of the system e.g. in Wyndor Glass, degrees of freedom (d.f.)= 5-3=2 Can set some variables (# = d.f.) to an arbitrary value (simplex uses 0) These variables (set to 0) are called nonbasic variables The rest can be found by solving the remaining system: basis The basis: the set of basic variables If all basic variables are ≥ 0, we have a BFS Between two basic solutions, if their bases are the same except for one variable, then they are adjacent

23 Algebra of the Simplex Method Initialization
Maximize Z = 3x1+ 5x2 subject to x1 +s1 = 4 2x2 +s2 = 12 3x1+ 2x2 +s3 = 18 x1,x2, s1, s2, s3 ≥ 0 Find an initial basic feasible solution If possible, use the origin as the initial CPF solution Equivalent to: Choose original variables to be nonbasic (xi=0, i=1,…n) and let the slack variables be basic (sj=bj, j=1,…m))

24 Algebra of the Simplex Method Optimality Test
Maximize Z = 3x1+ 5x2 subject to x1 +s1 = 4 2x2 +s2 = 12 3x1+ 2x2 +s3 = 18 x1,x2, s1, s2, s3 ≥ 0 Are any adjacent BF solutions better than the current one? Rewrite Z in terms of nonbasic variables and investigate rate of improvement Current nonbasic variables: x1, x2 Corresponding Z= 0 Optimal? No. If I increase the value of one of the nonbasic variables from 0 to a positive value, the objective function will increase.

25 Algebra of the Simplex Method Step 1 of Iteration 1: Direction of Movement
Maximize Z = 3x1+ 5x2 subject to x1 +s1 = 4 2x2 +s2 = 12 3x1+ 2x2 +s3 = 18 x1,x2, s1, s2, s3 ≥ 0 Which edge to move on? Determine the direction of movement by selecting the entering variable (variable ‘entering’ the basis) Choose the direction of steepest ascent (increase, since maximization) x1: Rate of improvement in Z =3 x2: Rate of improvement in Z =5 Entering basic variable = x2 (pivot column)

26 Algebra of the Simplex Method Step 2 of Iteration 1: Where to Stop
Maximize Z = 3x1+ 5x2 subject to x1 +s1 = 4 (1) 2x2 +s2 = 12 (2) 3x1+ 2x2 +s3 = 18 (3) x1,x2, s1, s2, s3 ≥ 0 How far can we go? Determine where to stop by selecting the leaving variable (variable ‘leaving’ the basis) Increasing the value of x2 decreases the value of basic variables. The minimum ratio test Constraint (1): x1 ≤ 4 no bound on x2 (s1= 4 - x1 ≥ 0) Constraint (2): 2x2+ s2= 12  x2 can be increased up to 6 before s2= 0. Min. Ratio Constraint (3): 3x1+ 2x2+s3 = 18  x2 can be increased up to 9 before s3= 0. Leaving basic variable = s2 (pivot row)

27 Algebra of the Simplex Method Step 3 of Iteration 1: Solving for the New BF Solution
Z - 3x1- 5x2 = 0 (0) x1 +s1 = 4 (1) 2x2 +s2 = 12 (2) 3x1+ 2x2 +s3 = 18 (3) Z - 3x /2 s2 = 30 (0) x1 +s1 = 4 (1) x2 + 1/2 s2 = 6 (2) 3x1 - s2 + s3 = 6 (3) Convert the system of equations to a more proper form for the new BF solution Elementary algebraic operations: Gaussian elimination Eliminate the entering basic variable (x2) from all but constraint 2 (pivot row) Since x1=0 and s2=0 we obtain (x1,x2,s1,s2,s3)= (0,6,4,0,6)

28 Algebra of the Simplex Method Optimality Test
Z - 3x /2 s2 = 30 (0) x1 +s1 = 4 (1) x2 + 1/2 s2 = 6 (2) 3x1 - s2 + s3 = 6 (3) Are any adjacent BF solutions better than the current one? Rewrite Z in terms of nonbasic variables and investigate rate of improvement Current nonbasic variables: x1, s2 Corresponding Z= 30 Optimal? No (increasing x1 increases Z value)

29 Algebra of the Simplex Method Step 1 of Iteration 2: Direction of Movement
Z - 3x /2 s2 = 30 (0) x1 +s1 = 4 (1) x2 + 1/2 s2 = 6 (2) 3x1 - s2 + s3 = 6 (3) Which edge to move on? Determine the direction of movement by selecting the entering variable (variable ‘entering’ the basis) Choose the direction of steepest ascent x1: Rate of improvement in Z = 3 s2: Rate of improvement in Z = - 5/2 Entering basic variable = x1

30 Algebra of the Simplex Method Step 2 of Iteration 2: Where to Stop
Z - 3x /2 s2 = 30 (0) x1 +s1 = 4 (1) x2 + 1/2 s2 = 6 (2) 3x1 - s2 + s3 = 6 (3) How far can we go? Determine where to stop by selecting the leaving variable (variable ‘leaving’ the basis) Increasing the value of x1 decreases the value of basic variables The minimum ratio test Constraint (1): x1 ≤ 4 Constraint (2): no upper bound on x1 Constraint (3): x1 ≤ 6/3= 2 Leaving basic variable = s3

31 Algebra of the Simplex Method Step 3 of Iteration 2: Solving for the New BF Solution
Z - 3x /2 s2 = 30 (0) x1 +s1 = 4 (1) x2 + 1/2 s2 = 6 (2) 3x1 - s2 + s3 = 6 (3) Convert the system of equations to a more proper form for the new BF solution Elementary algebraic operations: Gaussian elimination Eliminate the entering basic variable (x1) from all but its equation The next BF solution is (x1,x2,s1,s2,s3)= (2,6,2,0,0)

32 Algebra of the Simplex Method Optimality Test
Z /2 s2 + s3 = 36 (0) +s1 + 1/3 s2 - 1/3 s3 = 2 (1) x2 + 1/2 s2 = 6 (2) x /3 s2 + 1/3 s3 = 2 (3) Are any adjacent BF solutions better than the current one? Rewrite Z in terms of nonbasic variables and investigate rate of improvement Current nonbasic variables: s2, s3 Corresponding Z= 36 Optimal? yes

33 The Simplex Method in Tabular Form
For convenience in performing the required calculations Record only the essential information of the (evolving) system of equations in tableaux Coefficients of the variables Constants on the right-hand-sides Basic variables corresponding to equations

34 Table 4.3

35

36

37

38

39

40

41

42

43

44

45

46

47

48

49

50

51

52

53

54

55

56 Table 4.10

57


Download ppt "Solving Linear Programming Problems: Asst. Prof. Dr. Nergiz Kasımbeyli"

Similar presentations


Ads by Google