28
5.2 Iteration 5.2 Iteration We are at an extreme point of the feasible region We want to move to an adjacent extreme point. We want to move to a better extreme point. Observation: A pair of basic feasible solutions which differ only in that a basic and non-basic variable are interchanged corresponds to adjacent feasible extreme points.

5.2 Iteration We are at an extreme point of the feasible region We want to move to an adjacent extreme point. We want to move to a better extreme

  • View
    218

  • Download
    0

Embed Size (px)

Citation preview

Page 1: 5.2 Iteration  We are at an extreme point of the feasible region  We want to move to an adjacent extreme point.  We want to move to a better extreme

5.2 Iteration5.2 Iteration5.2 Iteration5.2 Iteration We are at an extreme point of the feasible region We want to move to an adjacent extreme point. We want to move to a better extreme point. Observation: A pair of basic feasible solutions which differ only

in that a basic and non-basic variable are interchanged corresponds to adjacent feasible extreme points.

Page 2: 5.2 Iteration  We are at an extreme point of the feasible region  We want to move to an adjacent extreme point.  We want to move to a better extreme

GeometryGeometry

Two hyperplane (constraints) in common

Only one hyperplane in common

(adjacent)

(not adjacent)

Page 3: 5.2 Iteration  We are at an extreme point of the feasible region  We want to move to an adjacent extreme point.  We want to move to a better extreme

Moving to an adjacent extreme point

Moving to an adjacent extreme point

Step 1:

– Select which nonbasic variable becomes basic Step 2:

– Determine which basic variable becomes nonbasic

Step 3:

– Reconstruct a new canonical form reflecting this change

Page 4: 5.2 Iteration  We are at an extreme point of the feasible region  We want to move to an adjacent extreme point.  We want to move to a better extreme

Simplex TableauSimplex TableauSimplex TableauSimplex Tableau

It is convenient to describe how the Simplex Method works using a table (=tableau).

There are a number of different layouts for these tables.

All of us shall use the layout specified in the lecture notes.

Page 5: 5.2 Iteration  We are at an extreme point of the feasible region  We want to move to an adjacent extreme point.  We want to move to a better extreme

ObservationObservation It is convenient to incorporate the objective

function into the formulation as a functional constraint.

We can do this by viewing z, the value of the objective function, as a decision variable, and introduce the additional constraint

z = j=1,...,n cjxj

or equivalently z - c1x1 - c2x2 - ... - cnxn = 0

Page 6: 5.2 Iteration  We are at an extreme point of the feasible region  We want to move to an adjacent extreme point.  We want to move to a better extreme

s.t. (5.9)

Z - 4 1x - 3 2x = 02 1x + x2 + x3 = 40x1 + x2 + x4 = 30x1 + x5 = 15

x x x x x1 2 3 4 5 0, , , ,

max,Z xZ

s.t. (5.9)

- - = 02 1x + x2 + x3 = 40x1 + x2 + x4 = 30x1 + x5 = 15

x x x x x1 2 3 4 5 0, , , ,

maxxZ x x 4 31 2

Page 7: 5.2 Iteration  We are at an extreme point of the feasible region  We want to move to an adjacent extreme point.  We want to move to a better extreme

Terminology:

We refer to the last row as the Z-row, and to the coefficient of x their as reduced costs. For example, the reduced cost of x1 is .

Tableau (5.10)BV Eq. # Z x1 x2 x3 x4 x5

RHS

x31 0 2 1 1 0 0 40

x42 0 1 1 0 1 0 30

x53 0 1 0 0 0 1 15

Z Z 1 4 3 0 0 0 0

Page 8: 5.2 Iteration  We are at an extreme point of the feasible region  We want to move to an adjacent extreme point.  We want to move to a better extreme

Step 1: Step 1: Selecting a new basic Selecting a new basic variablevariable

Step 1: Step 1: Selecting a new basic Selecting a new basic variablevariable

Issue:

– which one of the current non-basic variables should add to the basis?

Observation:

The Z-row tells us how the value of the objective function (Z) changes as we change the decision variables:

z - c1x1 - c2x2 - ... - cnxn = 0

Page 9: 5.2 Iteration  We are at an extreme point of the feasible region  We want to move to an adjacent extreme point.  We want to move to a better extreme

Because all the nonbasic variables are equal to zero, if we decide to add xj to the basis we must have

z - cjxj = 0

namely

z = cjxj

Page 10: 5.2 Iteration  We are at an extreme point of the feasible region  We want to move to an adjacent extreme point.  We want to move to a better extreme

Since we try to maximize the objective function, it would be better to select a non-basic variable with a large (positive) cost coefficient (large cj).

Thus, if we do the selection via the reduced costs, we will prefer a variable with a negative reduced cost.

Page 11: 5.2 Iteration  We are at an extreme point of the feasible region  We want to move to an adjacent extreme point.  We want to move to a better extreme

ConclusionConclusionConclusionConclusion

If we maximize the objective function, to improve (increase) the value of the objective function we have to select a non-basic variable whose reduced cost is negative.

Page 12: 5.2 Iteration  We are at an extreme point of the feasible region  We want to move to an adjacent extreme point.  We want to move to a better extreme

Greedy RuleGreedy RuleGreedy RuleGreedy Rule

Select the non-basic variable with the most negative reduced cost

Page 13: 5.2 Iteration  We are at an extreme point of the feasible region  We want to move to an adjacent extreme point.  We want to move to a better extreme

ExampleExample(Continued)(Continued)

ExampleExample(Continued)(Continued)

The most negative reduced cost in the Z-row is 4, corresponding to j=1. Thus, we select x1 as the new basic variable.

BV Eq. # Z x1 x2 x3 x4 x5RHS

x31 0 2 1 1 0 0 40

x42 0 1 1 0 1 0 30

x53 0 1 0 0 0 1 15

Z Z 1 4 3 0 0 0 0

Page 14: 5.2 Iteration  We are at an extreme point of the feasible region  We want to move to an adjacent extreme point.  We want to move to a better extreme

Step 2:Step 2:

Determining the new Determining the new nonbasic variablenonbasic variable

Step 2:Step 2:

Determining the new Determining the new nonbasic variablenonbasic variable

Suppose we decided to select xj as a new basic variable.

Since the number of basic variables is fixed (m), we have to take one variable out of the basis.

Which one?

Page 15: 5.2 Iteration  We are at an extreme point of the feasible region  We want to move to an adjacent extreme point.  We want to move to a better extreme

ObservationObservation

As we increase xj from zero, sooner or later one or more of the basic variables will become negative.

We can thus take the first such variable out of the basis and set it to zero.

Page 16: 5.2 Iteration  We are at an extreme point of the feasible region  We want to move to an adjacent extreme point.  We want to move to a better extreme

Example (continued)Example (continued)

Suppose we select x1 as the new basic variable.

Since x2 is a nonbasic variable, its value is zero. Thus the above system can be simplified!

s.t. (5.9)

- = 02 1x + x2 + x3 = 40x1 + x2 + x4 = 30x1 + x5 = 15

Page 17: 5.2 Iteration  We are at an extreme point of the feasible region  We want to move to an adjacent extreme point.  We want to move to a better extreme

Each equation involves only two variables:

– The new basic variable (x1)

– The old basic variable associated with the respective constraint.

We can thus express the old basic variables in terms of the new one!

x3 = 40 - 2x1

x4 = 30 - x1

x5 = 15 - x1

Page 18: 5.2 Iteration  We are at an extreme point of the feasible region  We want to move to an adjacent extreme point.  We want to move to a better extreme

We can now compute the critical values of the new basic variable (x1), namely the values for which the old basic variables will reach zero:

We had:

x3 = 40 - 2x1

x4 = 30 - x1

x5 = 15 - x1

We take x5 out of the basis.

Page 19: 5.2 Iteration  We are at an extreme point of the feasible region  We want to move to an adjacent extreme point.  We want to move to a better extreme

thus the critical values are obtained from:

0 = 40 - 2x1 (x1*=20)

0 = 30 - x1 (x1*=30)

0 = 15 - x1 (x1*=15)

Conclusions:

The critical value of x1 is 15.

We take x5 out of the basis.

Page 20: 5.2 Iteration  We are at an extreme point of the feasible region  We want to move to an adjacent extreme point.  We want to move to a better extreme

More generally ....More generally ....More generally ....More generally .... If we select xj as the new basic variable,

then for each of the functional constraints we have

aijxj + xi = bi (i=1,2,...,m)

where xi is the old basic variable associated with constraint i.

Page 21: 5.2 Iteration  We are at an extreme point of the feasible region  We want to move to an adjacent extreme point.  We want to move to a better extreme

Thus,

xi = bi - aijxj

so that the critical values of xj are determined by setting the xi’s to zero:

0 = bi - aijxj (i=1,2,...,m)

Page 22: 5.2 Iteration  We are at an extreme point of the feasible region  We want to move to an adjacent extreme point.  We want to move to a better extreme

Bottom LineBottom LineBottom LineBottom Line

Question: Why aren’t we interested in rows for which

aij 0 ???

xbaji

ij aij > 0,

Page 23: 5.2 Iteration  We are at an extreme point of the feasible region  We want to move to an adjacent extreme point.  We want to move to a better extreme

Ratio TestRatio TestRatio TestRatio Test

Given the new basic variable xj, take out of the basis the old basic variable corresponding to row i where the following ratio attains its smallest value:

Ratiobaii

ij: aij( > 0 )

Page 24: 5.2 Iteration  We are at an extreme point of the feasible region  We want to move to an adjacent extreme point.  We want to move to a better extreme

Example Example (Continued)(Continued)Example Example (Continued)(Continued)

Take x5 out of the basis.

BV Eq. # Z x1 x2 x3 x4 x5RHS

x31 0 2 1 1 0 0 40

x42 0 1 1 0 1 0 30

x53 0 1 0 0 0 1 15

Z Z 1 4 3 0 0 0 0

Ratio1 40

220

Ratio2 30

130

Ratio3 15

115

Page 25: 5.2 Iteration  We are at an extreme point of the feasible region  We want to move to an adjacent extreme point.  We want to move to a better extreme

Step 3:Step 3:

Restore The Canonical FormRestore The Canonical FormStep 3:Step 3:

Restore The Canonical FormRestore The Canonical Form

We interchanged a basic variable with a nonbasic variable

We have a new basis We have to construct the simplex tableau

for the new set-up This is done by one pivot operation

Page 26: 5.2 Iteration  We are at an extreme point of the feasible region  We want to move to an adjacent extreme point.  We want to move to a better extreme

BV Eq. # Z x1 x2 x3 x4 x5RHS

x31 0 2 1 1 0 0 40

x42 0 1 1 0 1 0 30

x53 0 1 0 0 0 1 15

Z Z 1 4 3 0 0 0 0

Example Example (Continued)(Continued)Example Example (Continued)(Continued)

1

BV Eq. # Z x1 x2 x3 x4 x5 RHSx3 1 0 0 1 1 0 - 2 10x4 2 0 0 1 0 1 - 1 15x1 3 0 1 0 0 0 1 15Z Z 1 0 - 3 0 0 4 60

Old

New

Page 27: 5.2 Iteration  We are at an extreme point of the feasible region  We want to move to an adjacent extreme point.  We want to move to a better extreme

How do we “read” a Simplex Tableau ?

How do we “read” a Simplex Tableau ?

New basis:

(x3,x4,x1)

New basic feasible solution:

x = (15,0,10,15,0)

BV Eq. # Z x1 x2 x3 x4 x5 RHSx3 1 0 0 1 1 0 - 2 10x4 2 0 0 1 0 1 - 1 15x1 3 0 1 0 0 0 1 15Z Z 1 0 - 3 0 0 4 60

Page 28: 5.2 Iteration  We are at an extreme point of the feasible region  We want to move to an adjacent extreme point.  We want to move to a better extreme

New value of objective function:

z = 60