27
1 Lecture 25 Two-Phase Simple Upper Bounded Simplex Algorithm Example: Minimize –2x 1 – x 2 Subject to x 1 + x 2 < 6 0 < x 1 < 5 0 < x 2 < 5

Lecture 25

  • Upload
    zorana

  • View
    19

  • Download
    0

Embed Size (px)

DESCRIPTION

Lecture 25. Two-Phase Simple Upper Bounded Simplex Algorithm Example: Minimize –2x 1 – x 2 Subject tox 1 + x 2 < 6 0 < x 1 < 5 0 < x 2 < 5. The Graph. x 2 bound. x 2. x 1 bound. optimum. x 1. Convert To An Equality Constraint. Minimize –2x 1 – x 2 - PowerPoint PPT Presentation

Citation preview

Page 1: Lecture 25

1

Lecture 25

Two-Phase Simple Upper Bounded Simplex Algorithm

Example:

Minimize –2x1 – x2

Subject to x1 + x2 < 6

0 < x1 < 5

0 < x2 < 5

Page 2: Lecture 25

2

The Graph

x1

x2

optimum

x1 bound

x2 bound

Page 3: Lecture 25

3

Convert To An Equality Constraint

Minimize –2x1 – x2

Subject to x1 + x2 +x3 = 6

0 < x1 < 5

0 < x2 < 5

0 < x3 < Note Bound on the slack variable

Page 4: Lecture 25

4

Add An Artificial Variable

Minimize –2x1 – x2

Subject to x1 + x2 +x3 + A= 6

0 < x1 < 5

0 < x2 < 5

0 < x3 <

0 < A <

Page 5: Lecture 25

5

Phase I Problem

Minimize ASubject to x1 + x2 +x3 + A= 6

0 < x1 < 5

0 < x2 < 5

0 < x3 <

0 < A <

Page 6: Lecture 25

6

Step 0. Initialization

BASIC = {A at 6}

NONBASIC = {x1 at 0, x2 at 0, x3 at 0}

B = 1

B-1 = 1

Page 7: Lecture 25

7

Step 1. Pricing

v = cBB-1 = 1(1) = 1

cbar1 = c1 – va1 = 0 – 1(1) = -1

cbar2 = c2 – va2 = 0 – 1(1) = -1

cbar3 = c3 – va3 = 0 – 1(1) = -1

All price favorably!

Page 8: Lecture 25

8

Step 2. Optimality

Not optimal

Let p = 3 - that is x3 is allowed to increase from 0

Page 9: Lecture 25

9

Step 3. Direction

y = B-1a3 = 1(1) = 1

= 1 Why?

Page 10: Lecture 25

10

Step 4 Step Size

- = min{, (xj-ℓj)/(yj) : yj > 0}

+ = min{, (uj-xj)/(-yj) : yj < 0}

= min{- , + , up - ℓp}

- = min{, (6-0)/1} = 6+ = min{} = = min{6, , -0} = 6

Page 11: Lecture 25

11

Step 5. New Point

XB = xB - y = 6 – 6(1)(1) = 0

A = 0

xp = x3 = ℓ3 + = 0 + 6 = 6

Current Point: [x1,x2,x3,A] = [0,0,6,0]

BASIC = {x3 at 6}

NONBASIC = {x1 at 0, x2 at 0, A at 0}B = 1 B-1 = 1

Page 12: Lecture 25

12

Step 1. Pricing

v = cBB-1 = 0(1) = 0

cbar1 = c1 – va1 = 0 – 0(1) = 0

cbar2 = c2 – va2 = 0 – 0(1) = 0

All price unfavorably!

Page 13: Lecture 25

13

Step 2. Optimality

Optimal For Phase I

Page 14: Lecture 25

14

Phase II Problem

Minimize -2x1 – x2

Subject to x1 + x2 +x3 = 6

0 < x1 < 5

0 < x2 < 5

0 < x3 <

Page 15: Lecture 25

15

Step 1. Pricing

Current Point: [x1,x2,x3] = [0,0,6]

BASIC = {x3 at 6}

NONBASIC = {x1 at 0, x2 at 0}B = 1 B-1 = 1

v = cBB-1 = 0(1) = 0

cbar1 = c1 – va1 = -2 – 0(1) = -2

cbar2 = c2 – va2 = -1 – 0(1) = -1

All price favorably!

Page 16: Lecture 25

16

Step 2. Optimality

Not Optimal

Let p = 1

Page 17: Lecture 25

17

Step 3. Direction

y = B-1a1 = 1(1) = 1

= 1 Why?

Page 18: Lecture 25

18

Step 4 Step Size

- = min{, (xj-ℓj)/(yj) : yj > 0}

+ = min{, (uj-xj)/(-yj) : yj < 0}

= min{- , + , up - ℓp}

- = min{, (6-0)/1} = 6+ = min{} = = min{6, , 5-0} = 5

Page 19: Lecture 25

19

Step 5. New Point

XB = xB - y = 6 – 5(1)(1) = 1

x3 = 1

xp = x1 = ℓ1 + = 0 + 5 = 5

Current Point: [x1,x2,x3] = [5,0,1]

BASIC = {x3 at 1}

NONBASIC = {x1 at 5, x2 at 0}B = 1 B-1 = 1 Note: The basis stayed the same.

Page 20: Lecture 25

20

Step 1. Pricing

v = cBB-1 = 0(1) = 0

cbar1 = c1 – va1 = -2 – 0(1) = -2 Unfavorable Why?

cbar2 = c2 – va2 = -1 – 0(1) = -1 Favorable

Page 21: Lecture 25

21

The Graph

x1

x2

current point

x1 bound

x2 bound

Page 22: Lecture 25

22

Step 2. Optimality

Not Optimal

Let p = 2

Page 23: Lecture 25

23

Step 3. Direction

y = B-1a1 = 1(1) = 1

= 1 Why?

Page 24: Lecture 25

24

Step 4 Step Size

- = min{, (xj-ℓj)/(yj) : yj > 0}

+ = min{, (uj-xj)/(-yj) : yj < 0}

= min{- , + , up - ℓp}

- = min{, (1-0)/1} = 1+ = min{} = = min{1, , 5-0} = 1

Page 25: Lecture 25

25

Step 5. New Point

XB = xB - y = 1 – 1(1)(1) = 0

x3 = 0

xp = x2 = ℓ2 + = 0 + 1 = 1

Current Point: [x1,x2,x3] = [5,1,0]

BASIC = {x2 at 1}

NONBASIC = {x1 at 5, x3 at 0}B = 1 B-1 = 1

Page 26: Lecture 25

26

Step 1. Pricing

v = cBB-1 = -1(1) = -1

cbar1 = c1 – va1 = -2 – (-1)(1) = -1 Unfavorable Why?

cbar3 = c3 – va3 = 0 – (-1)(1) = 1 Unfavorable Why?

Optimality Obtained

Page 27: Lecture 25

27

The Graph

x1

x2

current point

x1 bound

x2 bound