900 likes | 1.17k Views
Introduction to Management Science. The Challenges of Nonlinear Programming NLP with Decreasing Marginal Returns: Wyndor NLP with Decreasing Marginal Returns: Portfolio Selection Separable Programming Difficult Nonlinear Programming Problems Evolutionary Solver and Genetic Algorithms
E N D
Introduction to Management Science Introduction to Management Science
The Challenges of Nonlinear Programming NLP with Decreasing Marginal Returns: Wyndor NLP with Decreasing Marginal Returns: Portfolio Selection Separable Programming Difficult Nonlinear Programming Problems Evolutionary Solver and Genetic Algorithms Nonlinear and Separable Programming Evolutionary Solver Table of ContentsChapter 10 (Nonlinear Programming) Introduction to Management Science
Recall - Optimization problems • In an optimization problem, we seek to minimize or maximize a specific quantity (the objective), which depends on a finite number of input variables. • These variables may be independent of one another, or • They may be related through one or more constraints. • Example: minimize: z = x12 + x22 subject to: x1 – x2 = 3 x2 ≥ 3 Introduction to Management Science
A mathematical program optimize: z = f(x1, x2, x3, …, xn) subject to: g1(x1, x2, x3, …, xn) g2(x1, x2, x3, …, xn) g3(x1, x2, x3, …, xn) …. gm(x1, x2, x3, …, xn) b1 b2 b3 … bm = • A mathematical program is an optimization problem in which the objective and constraints are given as mathematical functions and functional relationships. Introduction to Management Science
Linear programs • A mathematical program is linear if f(x1, x2, x3, …, xn) and each gi(x1, x2, x3, …, xn),i = (1, 2, …, m) are linear in each of their arguments: f(x1, x2, …, xn) = c1x1 + c2x2 + … + cnxn and gi(x1, x2, …, xn) = ai1x1 + ai2x2 + … + ainxn Where cj and aij (i = 1, 2, …, m; j = 1, 2, …, n) are known constants. Any other mathematical program is non-linear. Introduction to Management Science
Integer programs • An integer program is a linear program with the additional restriction that the input variables be integers. • It is not necessary that the coefficients in the arguments f(x) and gi(x) and the constants bi also be integers, but they frequently may be. Introduction to Management Science
Quadratic (non-linear) programs • A quadratic program is an example of a non-linear program in which each constraint is linear, but the objective function has the form: f(x1, x2, …, xn) = i→nj→ncijx1xj + i→ndixi Where cij and diare known constants. Example: minimize: z = x12 + x22 subject to: x1 – x2 = 3 x2 ≥ 3 Quadratic program with linear constraints, quadratic objective function, n = 2 variables, c11 = 1, c12 = c21 = 0, c22 = 1, and d1 = d2 = 0. Introduction to Management Science
Examples of Linear and Nonlinear Formulas Data cells are located in D1:D6 and changing cells are in C1:C6. Introduction to Management Science
The Challenges of Nonlinear Programming • Nonlinear programming is used to model nonproportional relationships between activity levels and the overall measure of performance, whereas linear programming assumes a proportional relationship. • Constructing the nonlinear formula(s) needed for a nonlinear programming model is considerably more difficult than developing the linear formulas used in linear programming. • Solving a nonlinear programming model is often much more difficult (if it is possible at all) than solving a linear programming model. Introduction to Management Science
The Challenge of Nonproportional Relationships • Proportionality Assumption of Linear Programming: • The contribution of each activity to the value of the objective function is proportional to the level of the activity. In other words, the term in the objective function involving this activity consists of a coefficient times the decision variable. • Nonlinear programming problems arise when any activity has a nonproportional relationship where the contribution of the activity to the measure of performance is not proportional to the level of the activity. Introduction to Management Science
Profit Graphs for Wyndor Glass Co.(Proportional Relationship) Introduction to Management Science
Profit Graphs with Nonproportional Relationships Piecewise Linear withDecreasing Marginal Returns Decreasing Marginal Returns Introduction to Management Science
Profit Graphs with Nonproportional Relationships Decreasing Marginal ReturnsExcept for Discontinuities Increasing Marginal Returns Introduction to Management Science
Constructing a Nonlinear Formula Introduction to Management Science
Add Trendline Dialogue Box Introduction to Management Science
Add Trendline Options Introduction to Management Science
The Trendline (Quadratic Equation) Introduction to Management Science
Solving Nonlinear Programming Models Consider the following model in algebraic form: maximize: Profit = 0.5x5 – 6x4 + 24.5x3 – 39x2 + 20x subject to: x ≤ 5 x ≥ 0 Introduction to Management Science
Solver Solution Starting with x = 0 Introduction to Management Science
Solver Solution Starting with x = 3 Introduction to Management Science
Solver Solution Starting with x = 4.7 Introduction to Management Science
The Profit Graph Introduction to Management Science
Original Wyndor Glass Co. Spreadsheet Introduction to Management Science
Wyndor Glass with Marketing Costs • Market research indicates that Wyndor could sell small numbers of doors and windows with no advertising. However, extensive advertising would be required to sell all that could be produced. • A curve-fitting procedure was used to estimate the weekly marketing costs required to sustain a production rate of D doors and W windows: • Marketing cost for doors = $25D2 • Marketing costs for windows = ($662/3)W2 • The gross profit per door sold is about $375, and the gross profit per window is about $700. Therefore, the net profits are as follows: • Net profit for doors = $375D – $25D2 • Net profit for windows = $700W – ($662/3)W2 • Thus, the revised objective function is maximize: Profit = $375D – 25D2 + $700W –($662/3)W2 Question: Considering the nonlinear marketing costs, how many doors and windows should Wyndor produce? Introduction to Management Science
Profit Graphs for Doors and Windows Introduction to Management Science
Spreadsheet Formulation Introduction to Management Science
Graphical Display of Nonlinear Formulation Introduction to Management Science
Portfolio Selection • It is now common practice for professional managers of large stock portfolios to use computer models based on nonlinear programming to guide them. • Investors are concerned about both the expected return and the risk. • One way of formulating their approach is as a nonlinear version of a cost-benefit trade-off problem: • Minimize: Risk • subject to: Expected return ≥ Minimum acceptable level • Consider a portfolio with 3 stocks. Question:What is the portfolio that will minimize the risk subject to achieving at least an 18% expected return? Introduction to Management Science
Data for Stocks Introduction to Management Science
Algebraic Formulation minimize: Risk = (0.25S1)2+(0.45S2)2+(0.05S3)2+2(0.04)S1S2+2(–0.005)S1S3+2(–0.01)S2S3subject to: (21%)S1 + (30%)S2 + (8%)S3 ≥ 18%S1 + S2 + S3 = 100%andS1 ≥ 0, S2 ≥ 0, S3 ≥ 0. Introduction to Management Science
Portfolio selection spreadsheet model Introduction to Management Science
Using Solver Table to examine trade-offsbetween expected return and risk Introduction to Management Science
Wyndor Glass when overtime is needed • Wyndor Glass has accepted a special order for hand-crafted goods to be made in plants 1 and 2 throughout the next four months. • Filling this order will require borrowing certain employees from the work crews of regular products. • The remaining workers will need to work overtime to utilize the full production capacity of each plant’s machinery for the regular products. • The original constraints of Hours Used ≤ Hours Available are still valid. However, the objective function will need to be modified because of the additional cost of using overtime work. • In particular, because of the additional cost, the profit per unit will be reduced for those units that require overtime. Question:Considering overtime costs, how many doors and windows should Wyndor produce? Introduction to Management Science
Data for Wyndor When Overtime is Needed Introduction to Management Science
Profit Graphs for Doors and Windows Introduction to Management Science
The Separable Programming Technique • For each activity that violates the proportionality assumption, separate its profit graph into parts, with a line segment in each part. • Then, instead of using a single decision variable to represent the level of each such activity, introduce a separate new decision variable for each line segment on that activity’s profit graph. • Since the proportionality assumption holds for these new decision variables, formulate a linear programming model in terms of these variables. • For the Wyndor problem, these new decision variables are • DR = Number of doors produced per week on regular time • DO = Number of doors produced per week on overtime • WR = Number of windows produced per week on regular time • WO = Number of windows produced per week on overtime Introduction to Management Science
Separable programming spreadsheet model Introduction to Management Science
Separable Programming with smooth profit graphs Introduction to Management Science
Advantages of Separable Programming • The Excel Solver can readily solve nonlinear problems that have decreasing marginal returns, with the advantage that no approximation is needed. • However, the separable programming approach also has certain advantages: • Converting the problem into a linear programming problem tends to make it quicker to solve, which can be very helpful for large problems. • A linear programming formulation makes available Solver’s Sensitivity Report. • Separable programming only requires estimating the profit from each activity at a few points. Therefore, it is not necessary to use a curve fitting method to estimate the formula for the profit graph. Introduction to Management Science
Wyndor Problem with Both Overtime Costs andNonlinear Marketing Costs • The previous spreadsheet model does not include nonlinear marketing costs. • Recall that the curve-fitting procedure was used to estimate the weekly marketing costs required to sustain a production rate of D doors and W windows: • Marketing cost for doors = $25D2 • Marketing costs for windows = ($662/3)W2 Question:Considering both overtime costs and nonlinear marketing costs, how many doors and windows should Wyndor produce? Introduction to Management Science
Data for Wyndor with Overtime Costs andNonlinear Marketing Costs Introduction to Management Science
Weekly Profit from Producing Doors Introduction to Management Science
Weekly Profit from Producing Windows Introduction to Management Science
Separable Programming Spreadsheet Model Introduction to Management Science
Nonlinear Programming Spreadsheet Model Introduction to Management Science
Difficult Nonlinear Programming Problems • Even if a model has a nonlinear objective function, so long as the model has certain properties (e.g., linear constraints, decreasing marginal returns), the Solver can easily find an optimal solution. • In some cases separable programming can be used to model a nonlinear problem in such a way that linear programming can be used. • However, if a problem has increasing marginal returns, or nonlinear functions in the constraints, or disconnected profit graphs, finding a solution is often much more difficult. • Such problems may have many local optima • Solver can get stuck at local optima, rather than finding the global optimum • One approach with such problems is to solve the problem many times, each time starting with a different initial solution. • Solver Table can be used to do this process more systematically when there are only one or two variables. Introduction to Management Science
Using Solver Table to try different starting points Introduction to Management Science
Evolutionary Solver and Genetic Algorithms • Evolutionary Solver uses an entirely different approach than the standard Solver to search for an optimal solution for a model. • The philosophy of Evolutionary Solver is based on genetics, evolution and the survival of the fittest. Hence, this type of algorithm is sometimes called a genetic algorithm. • The standard Solver starts with a single solution, and then moves in directions that will improve this solution. Evolutionary Solver begins by randomly generating a whole population of solutions. • After generating the population, Evolutionary Solver creates a new generation by pairing off solutions in the population to create “offspring”, combining some elements from each parent. Introduction to Management Science
Evolutionary Solver and Genetic Algorithms • Among solutions in the population, some will be good (or “fit”) and some will be bad (or “unfit”), as measured by evaluating the objective function. Borrowing from the principles of evolution and survival of the fittest, the “fit” members are allowed to reproduce more frequently than the unfit members. • Another key feature is mutation. Like gene mutation in biology, Evolutionary Solver will occasionally make a random change in a member of the population. This helps the algorithm get unstuck if it is getting trapped near a local optimum. • Evolutionary Solver keeps creating new generations of solutions until there have been no improvements for several consecutive generations. Introduction to Management Science
Selecting a portfolio to beat the market • A common goal of portfolio managers is to beat the market. • If we assume that past performance is somewhat of an indicator of the future, then picking a portfolio that beat the market most often in the past might yield a portfolio that will more than likely beat the market in the future. • Consider a portfolio of five large stocks traded on the New York Stock Exchange (NYSE): • America Online (AOL) • Boeing (BA) • Ford (F) • Procter & Gamble (PG) • McDonald’s (MCD) Question:What mix of these five stocks will yield a portfolio that is likely to beat the market in the future? Introduction to Management Science