Computational Methods for Management and Economics Carla Gomes Module 6c Initialization in Simplex (Textbook – Hillier and Lieberman)

Slides:



Advertisements
Similar presentations
February 21, 2002 Simplex Method Continued
Advertisements

February 14, 2002 Putting Linear Programs into standard form
Artificial Variables, 2-Phase and Big M Methods
The simplex algorithm The simplex algorithm is the classical method for solving linear programs. Its running time is not polynomial in the worst case.
IEOR 4004 Midterm Review (part I)
Hillier and Lieberman Chapter 4.
Lecture 3 Linear Programming: Tutorial Simplex Method
Operation Research Chapter 3 Simplex Method.
SIMPLEX METHOD FOR LP LP Model.
LECTURE 14 Minimization Two Phase method by Dr. Arshad zaheer
Chapter 6 Linear Programming: The Simplex Method
Solving Linear Programming Problems: The Simplex Method
Computational Methods for Management and Economics Carla Gomes Module 6a Introduction to Simplex (Textbook – Hillier and Lieberman)
Degeneracy and the Convergence of the Simplex Algorithm LI Xiao-lei.
Water Resources Development and Management Optimization (Linear Programming) CVEN 5393 Feb 18, 2013.
Computational Methods for Management and Economics Carla Gomes Module 8b The transportation simplex method.
Computational Methods for Management and Economics Carla Gomes Module 6b Simplex Pitfalls (Textbook – Hillier and Lieberman)
Operation Research Chapter 3 Simplex Method.
Solving Linear Programs: The Simplex Method
1 5.6 No-Standard Formulations  What do you do if your problem formulation doeshave the Standard Form?  What do you do if your problem formulation does.
Computational Methods for Management and Economics Carla Gomes
Linear Programming (LP)
5.6 Maximization and Minimization with Mixed Problem Constraints
Chapter 4 The Simplex Method
MIT and James Orlin © Chapter 3. The simplex algorithm Putting Linear Programs into standard form Introduction to Simplex Algorithm.
Water Resources Development and Management Optimization (Linear Programming) CVEN 5393 Feb 25, 2013.
LINEAR PROGRAMMING SIMPLEX METHOD.
Linear Programming - Standard Form
Chapter 3 Linear Programming Methods 高等作業研究 高等作業研究 ( 一 ) Chapter 3 Linear Programming Methods (II)
1. The Simplex Method.
MIT and James Orlin © More Linear Programming Models.
Chapter 6 Linear Programming: The Simplex Method
The Two-Phase Simplex Method LI Xiao-lei. Preview When a basic feasible solution is not readily available, the two-phase simplex method may be used as.
Operations Research Assistant Professor Dr. Sana’a Wafa Al-Sayegh 2 nd Semester ITGD4207 University of Palestine.
Simplex method (algebraic interpretation)
Simplex Algorithm.Big M Method
Topic III The Simplex Method Setting up the Method Tabular Form Chapter(s): 4.
Barnett/Ziegler/Byleen Finite Mathematics 11e1 Learning Objectives for Section 6.4 The student will be able to set up and solve linear programming problems.
1 1 Slide © 2000 South-Western College Publishing/ITP Slides Prepared by JOHN LOUCKS.
Kerimcan OzcanMNGT 379 Operations Research1 Linear Programming: The Simplex Method Chapter 5.
1 1 © 2003 Thomson  /South-Western Slide Slides Prepared by JOHN S. LOUCKS St. Edward’s University.
1 1 © 2003 Thomson  /South-Western Slide Slides Prepared by JOHN S. LOUCKS St. Edward’s University.
Public Policy Modeling Simplex Method Tuesday, October 13, 2015 Hun Myoung Park, Ph.D. Public Management & Policy Analysis Program Graduate School of International.
The big M method LI Xiao-lei.
Pareto Linear Programming The Problem: P-opt Cx s.t Ax ≤ b x ≥ 0 where C is a kxn matrix so that Cx = (c (1) x, c (2) x,..., c (k) x) where c.
Solving Linear Programming Problems: The Simplex Method
Mechanical Engineering Department 1 سورة النحل (78)
1 1 Slide © 2005 Thomson/South-Western Linear Programming: The Simplex Method n An Overview of the Simplex Method n Standard Form n Tableau Form n Setting.
Chapter 4 Linear Programming: The Simplex Method
Chapter 6 Linear Programming: The Simplex Method Section 4 Maximization and Minimization with Problem Constraints.
1 Chapter 4 The Simplex Algorithm PART 2 Prof. Dr. M. Arslan ÖRNEK.
OR Chapter 8. General LP Problems Converting other forms to general LP problem : min c’x  - max (-c)’x   = by adding a nonnegative slack variable.
University of Colorado at Boulder Yicheng Wang, Phone: , Optimization Techniques for Civil and Environmental Engineering.
An-Najah N. University Faculty of Engineering and Information Technology Department of Management Information systems Operations Research and Applications.
Simplex Method Simplex: a linear-programming algorithm that can solve problems having more than two decision variables. The simplex technique involves.
1 Simplex algorithm. 2 The Aim of Linear Programming A Linear Programming model seeks to maximize or minimize a linear function, subject to a set of linear.
Decision Support Systems INF421 & IS Simplex: a linear-programming algorithm that can solve problems having more than two decision variables.
The Simplex Method. and Maximize Subject to From a geometric viewpoint : CPF solutions (Corner-Point Feasible) : Corner-point infeasible solutions 0.
An Introduction to Linear Programming
EMGT 6412/MATH 6665 Mathematical Programming Spring 2016
10CS661 OPERATION RESEARCH Engineered for Tomorrow.
The Two-Phase Simplex Method
Chapter 4 Linear Programming: The Simplex Method
Chapter 8. General LP Problems
Chapter 5. The Duality Theorem
Chapter 8. General LP Problems
Simplex method (algebraic interpretation)
Chapter 8. General LP Problems
Presentation transcript:

Computational Methods for Management and Economics Carla Gomes Module 6c Initialization in Simplex (Textbook – Hillier and Lieberman)

Initialization Adapting to other forms

Equality constraints Negative Right-hand sides Constraints ≥ Minimization

Artificial Variable Approach What if our problem is not in standard form – i.e., it may include functional constraints of type = and ≥ and also negative RHS? How can we identify an initial BFS? Approach – artificial variable technique: –Construct an artificial problem: introduce a dummy variable – an artificial variable, s.t., the usual non-negativity constraints, just for the purpose of being initial basic variable -- into each of the constraints that are non standard; Objective function – modify it to impose an exorbitant penalty on the artificial variables –Simplex method – forces the artificial variables to become 0, one at a time, until they are all gone, providing an initial basic solution for the original problem.

Handling Equality Constraints a i1 x 1 + a i2 x 2 + … + a in x n = b i Can be transformed into: a i1 x 1 + a i2 x 2 + … + a in x n ≥ b i a i1 x 1 + a i2 x 2 + … + a in x n ≤ b i But we still would have to deal with one constraint in non-standard form.

Wyndor Glass Requirement: plant 3must be uses at full capacity  3 x x 2 = 18; Algebraic form: Z - 3 x x 2 = 0; x 1 + x 3 = 4; 2 x 2 + x 3 = 12; 3 x x 2 = 18; What’s the problem with this initial system from the simplex’s point of view?

What is the basic variable in the 3 rd equation? No obvious BFS

Procedure Construct an artificial problem that has the same optimal solution as the real problem by making two modifications to the real problem: 1.Apply the artificial variable technique by introducing a non-negative artificial variable into the equality constraint as if it were a slack variable. 2.Assign an overwhelming penalty to having by changing the objective function to: 3 x x 2 + = 18; Z = 3 x x 2 - M M is a huge positive number (Big M Method). = x x 2

Note: because plays the role of the slack variable in the 3 rd constraint, this constraint becomes equivalent to 3 x x 2 <=18; therefore the feasible region is identical to the feasible region of the original Wyndor Glass problem.

3. Converting Z equation into proper form x 1 + x 3 = 4; 2 x 2 + x 4 = 12; 3 x x 2 + = 18; Is this form the right form for the simplex? Why? Z - 3 x x 2 + M = 0  convert Z equation into the proper form by subtracting from Eq(0), Eq(3) times M

Converting Z equation into proper form Now we are ready to use the Simplex method. Note: Think of M as a huge number. M only appears in Eq 0 in Expressions of the form aM + b; because M is huge it is enough to Compare the multiplicative factor a. What variable will enter the basis? What variable will leave the basis?

What operations do we need to perform to this tableau? Answer: Multiply pivot row by (-3) and add it to eq (3); Multiply pivot row by (3M+3) and add it to eq (0); What variable will enter the basis? What variable will leave the basis? Is this a feasible solution for the original problem? Optimal?Why?

What operations do we need to perform to this tableau? Answer: Divide pivot row by 2 Multiply new pivot row by (-2) and add it to eq (2); Multiply new pivot row by (2M+5) and add it to eq (0); Is this a feasible solution for the original problem? Optimal?Why? What variable will enter the basis? What variable will leave the basis?

Is this a feasible solution for the original problem? Optimal?Why?

Graphical Visualization of Wyndor Glass Problem x1=0,x2=0,x3=4,x4=12,x5=18 x1=4,x2=0,x3=0,x4=12,x5=18 x1=4,x2=3,x3=0,x4=6,x5=0 x1=2,x2=5,x3=2,x4=0,x5=0

Handling Negative Right Hand Sides x 1 + x 3 <=-1; -x 1 - x 3 ≥ 1;

Handling ≥ constraints x 1 + x 2 >= 6 start by introducing a surplus variable x 1 + x 2 - x3 = 6 now we know how to deal with equality constraints by adding an artificial variable, x 3 ≥ 0; x 1 + x 2 - x 3 + x 4 = 6 x 4 ≥ 0 is an artificial variable Note: x 1 + x 2 - x 3 + x 4 = 6  x 1 + x 2 = 6 + x 3 - x 4 Since x 3 >=0 and x 4 >=0 that means that x 1 + x 2 can now take any value (below or above the constraint) so this procedure in fact eliminates the constraint from the artificial problem.

Minimization Minimize Z = c 1 x 1 + c 2 x 2 + … + c n x n  Maximize - Z = - c 1 x 1 - c 2 x 2 - … - c n x n

The Big M Method Description of the Big M Method 1.Modify the constraints so that the RHS of each constraint is nonnegative. Identify each constraint that is now an = or ≥ constraint. 2.Convert each inequality constraint to augmented form (add a slack variable for ≤ constraints, add an surplus (excess) variable for ≥ constraints). 3.For each ≥ or = constraint, add artificial variables. Add sign restriction a i ≥ 0. 4.Let M denote a very large positive number. Add (for each artificial variable) Ma i to min problem objective functions or -Ma i to max problem objective functions. 5.Since each artificial variable will be in the starting basis, all artificial variables must be eliminated from row 0 before beginning the simplex. Remembering M represents a very large number, solve the transformed problem by the simplex.

Math Programming and Radiation Therapy

Radiation Therapy Overview High doses of radiation (energy/unit mass) can kill cells and/or prevent them from growing and dividing –True for cancer cells and normal cells Radiation is attractive because the repair mechanisms for cancer cells is less efficient than for normal cells (slides adapted from James Orlin’s)

Radiation Therapy Overview Recent advances in radiation therapy now make it possible to –map the cancerous region in greater detail –aim a larger number of different beamlets with greater specificity This has spawned the new field of tomotherapy “Optimizing the Delivery of Radiation Therapy to Cancer patients,” by Shepard, Ferris, Olivera, and Mackie, SIAM Review, Vol 41, pp , Also see

Conventional Radiotherapy Relative Intensity of Dose Delivered

Conventional Radiotherapy Relative Intensity of Dose Delivered

Conventional Radiotherapy In conventional radiotherapy –3 to 7 beams of radiation –radiation oncologist and physicist work together to determine a set of beam angles and beam intensities –determined by manual “trial-and-error” process

Goal: maximize the dose to the tumor while minimizing dose to the critical area Critical Area Tumor area With a small number of beams, it is difficult to achieve these goals.

Recent Advances More accurate map of tumor area –CT -- Computed Tomography –MRI -- Magnetic Resonance Imaging More accurate delivery of radiation –IMRT: Intensity Modulated Radiation Therapy –Tomotherapy

Tomotherapy: a diagram

Radiation Therapy: Problem Statement For a given tumor and given critical areas For a given set of possible beamlet origins and angles Determine the weight of each beamlet such that: –dosage over the tumor area will be at least a target level  L. –dosage over the critical area will be at most a target level  U.

Display of radiation levels

Linear Programming Model First, discretize the space –Divide up region into a 2D (or 3D) grid of pixels

More on the LP Create the beamlet data for each of p = 1,..., n possible beamlets. D p is the matrix of unit doses delivered by beam p. = unit dose delivered to pixel (i,j) by beamlet p

Linear Program Decision variables w = (w 1,..., w p ) w p = intensity weight assigned to beamlet p for p = 1 to n; D ij = dosage delivered to pixel (i,j)

An LP model minimize In an example reported in the paper, there were more than 63,000 variables, and more than 94,000 constraints (excluding upper/lower bounds) took 4 minutes to solve.

What to do if there is no feasible solution Use penalties: e.g., D ij   L – y ij and then penalize y in the objective. Consider non-linear penalties (e.g., quadratic) Consider costs that depend on damage rather than on radiation Develop target doses and penalize deviation from the target

Optimal Solution for the LP

An Optimal Solution to an NLP

Further considerations Minimize damage to critical tissue Maximize damage to tumor cells Minimize time to carry out the dosage LP depends on the technology

Mary’s radiation therapy: simplified version Goal – design and select the combination of beamlets to be used and the intensity of each one, to generate the best possible dose distribution (units: kilorads) Decision variables: –x 1 - dose at the entry point for beamlet 1 –x 2 - dose at the entry point for beamlet 1 Objective function: –Z – total dosage reaching healthy anatomy min z = 0.4 x x 2 st 0.3x x 2 ≤ 2.7 critical tissues 0.6x x 2 = 6 tumor region 0.5x x 2 ≥ 6 center of tumor x 1, x 2, > 0

min z = 0.4 x x 2 st 0.3x x 2 ≤ x x 2 = 6 0.5x x 2 ≥ 5 x 1, x 2, > 0

Getting the problem into augmented form (canonical form) for simplex

1 st Simplex Tableaux Optimal? Entering Variable? x 1 enters the base and x 3 leaves the base

When do we get a feasible solution for the original problem? What the optimal solution? x1 = ? x2 = ? Z = ? x4 = ? x5 = ? x6 = ?

From Big M Method to the Two- Phase Method The Big-M Method can be thought of as having two phases: –Phase 1 – all the artificial variables are driven to 0 (because of the penalty M) in order to reach an initial BF solution to the real problem; –Phase 2 – all the artificial variables are kept to 0 (because of the penalty M) while the simplex method generates a sequence of BF solutions for the real problem that leads to an optimal solution.  Two phase method – streamlined procedure for performing the two-phases directly, without introducing M explicitly ;

Two Phase Method: Mary’s radiation therapy Real problem’s objective function: min z = 0.4 x x 2 Big M method’s objective function: min z = 0.4 x x 2 + M x 4 + M x 6 Since the two first coefficients are negligible compared to M, the two phase method drops M by using the following objective functions: –Phase 1: minimize z = x 4 + x 6 (until x 4 =, x 6 =0) –Phase 2: min z = 0.4 x x 2 (with x 4 =, x 6 =0)

min z = x 4 + x 6 st 0.3x x 2 + x3 = x x 2 + x 4 = 6 0.5x x 2 - x 5 + x 6 = 6 x 1, x 2, x 3, x 4, x 5, x 6 >= 0 The solution of phase 1 is the initial solution for phase 2, assuming That the optimal solution of phase 1 is z=0 and x 4, x 6 = 0; Phase 1: Mary’s radiation therapy

min z = 0.4x x 2 st 0.3x x 2 + x3 = x x 2 = 6 0.5x x 2 - x 5 = 6 x 1, x 2, x 3, x 5 >= 0 Phase 2: Mary’s radiation therapy Note: the solution from phase 1 is the initial BFS for phase 2.

Tableau for Phase 1: Mary’s radiation therapy min z = x 4 + x 6 st 0.3x x 2 + x3 = x x 2 + x 4 = 6 0.5x x 2 - x 5 + x 6 = 6 x 1, x 2, x 3, x 4, x 5, x 6 >= 0 What is the basic variable in equation 1? Equation 2? Equation 3? What operations do we need to perform in order to get the canonical form for the simplex? (multiply row 2 by –1 and row 3 by –1; add new row 2 and new row 3 to row 0)

Tableau for Phase 1: Mary’s radiation therapy What’s the initial solution for phase 2?x 1 =6; x 3 = 0.3; x 2 =6, x 4,x 5,x 6 =0

min z = 0.4x x 2 st 0.3x x 2 + x3 = x x 2 = 6 0.5x x 2 - x 5 = 6 x 1, x 2, x 3, x 5 >= 0 Phase 2: Mary’s radiation therapy Using phase 1 solution, how do we get the 1 st tableau for phase 2?

Preparing for Phase 2 Drop the artificial variables Substitute phase 2 objective function Restore canonical form for simplex for phase 2

Phase 2: Mary’s radiation therapy What variable leaves the basis and what variable enters the basis? Is it optimal? What’s the solution? And Z?

Graphical Visualization of Phase I and Phase II

Big M Method vs. Two-phase Method The two-phase method streamlines the Big M method by using only the multiplicative factors in phase 1 and by dropping the artificial variables in phase 2. Two-phase method is commonly used in computational implementations. 

No Feasible Solutions If the original problem has no feasible solutions, then either the Big M method or the phase 1 of the two-phase method yields a final solution that has at least one artificial variable greater than zero.

No Feasible Solutions min z = 0.4 x x 2 st 0.3x x 2 ≤ x x 2 = 6 0.5x x 2 ≥ 5 x 1, x 2, > 0

No Feasible Solutions Why is it an infeasible solution to the original problem?

Handling variables allowed to be negative In several situation we need to consider variables that can have negative values – e.g., rates of increase. We consider two cases: –Variables with a bound on the negative values allowed –Variables with no bound on the negative values allowed

Variables with a bound on the negative values allowed Let’s consider the lower bound L, where L is a negative constant; Let’s assume the constraint: x ≥ L x ≥ L  x’ = x - L, x’ ≥ 0  x = x’ + L So x and the constraint x ≥ L can be replace with x’ + L and x’ ≥ 0.

Wyndor Glass x 1 – rate of increase in production (does not go below –10) Maximize Z = 3 x1+ 5 x2 subject to x1 ≤ 4 2x2≤ 12 3x1 + 2x2 ≤ 18 and x1 ≥ -10, x2 ≥0. Letx1 = rate of increase of the number of doors to produce x2 = the number of windows to produce Maximize Z = 3 (x’-10) + 5 x2 subject to (x’-10) ≤ 4 2 x2 ≤ 12 3 (x’-10) + 2x2 ≤ 18 and (x’-10) ≥ -10, x2 ≥ 0. Maximize Z = x’ + 5 x2 subject to x’≤ 14 2x’ ≤ 12 3x’+ 2x2 ≤ 48 and x’ ≥ 0, x2 ≥ 0. Note: A similar technique can be used when L is positive and a variable is subject to the constraint: x ≥ L

Variables with no bound on the negative values allowed Let’s consider a variable x that can have arbitrary values What transformation do we perform to use the LP model? x = x + - x - where x + ≥ 0; x - ≥ 0 (note that x can have arbitrary values since x + and x - can only have positive values) What’s the interpretation of this transformation? Any BF solution has the property that either x + = 0 or x - = 0 (or both) Therefore at the optimal solution we have: x if x > 0 x + = x + is the positive part 0 otherwise |x| if x < 0 x + = x - is the negative part 0 otherwise Example: if x=10 then x + =10 and x - = 0

Wyndor Glass x 1 – rate of increase in production (can have arbitrary values)) Maximize Z = 3 x1+ 5 x2 subject to x1 ≤ 4 2x2≤ 12 3x1 + 2x2 ≤ 18 and x2 ≥0. Letx1 = rate of increase of the number of doors to produce x2 = the number of windows to produce Maximize Z = 3 ( x + - x - ) + 5 x2 subject to ( x + - x - ) ≤ 4 2 x2 ≤ 12 3 ( x + - x - ) + 2x2 ≤ 18 and x + ≥0, x - ≥0, x2 ≥ 0. Note: A similar technique can be used when L is positive and a variable is subject to the constraint: x ≥ L Maximize Z = 3 x x x2 subject to x + - x - ≤ 4 2 x2 ≤ 12 3 x x - + 2x2 ≤ 18 and x + ≥0, x - ≥0, x2 ≥ 0.

From a computational view point this approach has the disadvantage of introducing new variables. If all the variables can have arbitrary values the transformed model will have twice as many variables. Can we do better? Yes – by introducing only one additional variable. All variables x j are replaced by: –with x j = x j ’-x’’ where x j ’ ≥0, x’’ ≥ 0 (x’’ is the same for all variables; -x’’ corresponds to the largest (in absolute terms) negative original variable; x j ’is the amount by which x j exceeds x’’. )