You are on page 1of 27

Indr 460

Operations Research
Applications

Modeling Optimization
Problems

Koç University – Spring 2019


1
Decision Making
Structuring the problem Analyzing the problem

Define the Quantitative Qualitative


problem Analysis Analysis

Summary
Identify the and
alternatives Evaluation

Determine Make the


the criteria decision

2
Quantitative Analysis
p Quantitative Analysis Process
1) Model development
2) Data preparation
3) Model solution
4) Analysis of the solution and report generation

p Potential reasons for a quantitative


analysis approach to decision making
n The problem is complex, has significant impact,
is large-scale or repetitive.

3
Concept of a Model
p Models are representations of real objects or
systems
p Building a model helps understanding a
system
p Generally, experimenting with models
(compared to experimenting with the real
system) requires less time, is less
expensive, involves less risk

4
Mathematical Models
p Mathematical models represent real world
problems through a system of mathematical
relationships (formulas and expressions)
based on key assumptions, estimates, or
statistical analyses

p Examples of mathematical models


n Simulation models, econometric models, time
series models, mathematical programming models

5
Mathematical Programming Models
p Relate decision variables (controllable inputs)
with fixed or variable parameters
(uncontrollable inputs).

p Maximize or minimize some objective function


subject to constraints.
Objectives (minimize risk, maximize profit, etc. )
Constraints (capacities, budget limits, etc.)

6
Solving Mathematical Programming
Models
p Solution
n Feasible solution: The values of the decision
variables that satisfy all of the constraints.
n Optimal solution: A feasible solution that provides
the best objective function value.

p Deterministic vs. stochastic models


n deterministic: All input data are known exactly and
do not vary
n stochastic: Any of the uncontrollable inputs is
subject to variation
n Generally, stochastic models are more difficult to
solve 7
Components of Models
Model Decision Uncontrollable Outputs
Variables Variables
Investment Investment Rate of return Total return
amount and Inflation rate Total net profit
times Risk level Total risk

Inventory When and Demand Total net profit,


how much to Storage cost Service level,
order Order cost Total cost

Transportation Quantities Distances, Total


shipped and Transportation transportation
Routes taken cost, Demand cost

8
Guidelines for Model Development
Write a verbal description of the objective and each
constraint

Define the decision variables

Express the objective in terms of the decision variables

Express the constraints in terms of the decision variables

9
Example: Iron Works, Inc. Product
Mix Problem
p Iron Works, Inc. manufactures two products made from
steel and receives 2000 pounds of steel each month. It
takes 2 pounds of steel to make a unit of product 1, and
it takes 3 pounds of steel to make a unit of product 2.
p The unit profits for product 1 and product 2 are $100
and $200, respectively.
p Each month the manufacturer has a contract calling for
at least 60 units of product 1.
p At most 720 units of product 2 may be produced by the
firm's facilities.
p Find the monthly production quantities of product 1 and
product 2 to maximize profit from these products.

10
Example: Iron Works, Inc.
Mathematical Model
n Decision Variables:
p Product-1 production: !
p Product-2 production: "

n Objective :
p Maximize total monthly profit:
max: 100x + 200 "

11
Example: Iron Works, Inc.
Constraints
n The total amount of steel used during monthly
production must be at most 2000 pounds
2" + 3% ≤ 2000
n The monthly production quantity of product 1 must be
greater than or equal to 60
" ≥ 60
n The monthly production quantity of product 2 must be
less than or equal to 720
% ≤ 720
n The production levels cannot be negative:
x,% ≥ 0
12
Example: Iron Works, Inc.
p Mathematical Model Summary:

Max: !"" # + %""&


st: %# + '& ≤ %"""
# ≥ *"
& ≤ +%"
#≥"
&≥"

13
Example: Iron Works, Inc.

The optimal solution to the this LP model is

x = 60 and y = 626.67

Question: Is the optimal solution acceptable?

14
Example: Iron Works, Inc.
Uncontrollable Inputs
$100 profit per unit Prod. 1
$200 profit per unit Prod. 2
2 lbs. steel per unit Prod. 1
3 lbs. Steel per unit Prod. 2
2000 lbs. steel allocated
60 units minimum Prod. 1
720 units maximum Prod. 2
0 units minimum Prod. 2

60 units Prod. 1 Max 100(60) + 200(626.67) Profit = $131,333.33


626.67 units Prod. 2 s.t. 2(60) + 3(626.67) £ 2000 Steel Used = 2000
60 ³ 60
Controllable Inputs 626.67 £ 720 Output
626.67 ³ 0
Mathematical Model 15
Software
p A variety of software packages are available
for solving mathematical models:
n Spreadsheet packages such as Microsoft Excel
n Optimization packages such as CPLEX, LINDO,
OSL, EXPRESS, MINTO, MINOS, SAS/OR, AIMMS,
Gurobi, Optimization Toolbox of Matlab
n Modeling packages such as GAMS, OPL Studio,
AMPL, AIMMS

16
Software
p A number of modeling systems and solvers are
also available free for testing by submission
through the Internet to the NEOS
Server (www.neos-server.org).
p NEOS imposes no problem-size restrictions and is
free of charge
p Survey for Mathematical Programming software:
p https://www.informs.org/ORMS-Today/Public-
Articles/June-Volume-38-Number-3/Software-Survey-
Linear-Programming
p http://www.eudoxus.com/mp-in-
action/software/mpac9411

17
Optimization Packages
Typically contain algorithms for solving
Linear
• The revised simplex algorithm, dual simplex
programming algorithm, interior point algorithms
models

Separable
• Approximating complex structures (i.e.
programming nonliear) with piecewise linear functions.
models

Integer
• Branch and bound algorithm, strengthened
programming with cutting plane generation
models

Nonlinear
programming • Search methods, interior point algorithms
models 18
Optimization Packages - Algorithms
p Constraint Logic Programming
n Alternate concise modeling and solution approach
for certain cases
n Each variable has a finite domain of values
n Constraints restrict possible combinations of
values, ex: all_different(x1, x2 , …, xn)
n Solution by domain reduction/constraint
propagation
n Mainly useful for complex feasibility problems

19
Typical Options of Packages
p Reduction
p Starting solutions
p Simple bounding constraints
p Generalized upper bounding constraints
p Sensitivity analysis
p MPS format for input
p Save and restore solution

20
Use of Modeling Languages
Inputting a model into a package
p Matrix generators, programs that prepare
MPS, LP format
p Modeling languages
n More natural than MPS format
n Easier debugging and modification
n Large models usually arise due to sets with indices,
e.g. multiple periods, plants or products

21
How to Build a Good Model
p Ease of understanding the model
p Ease of detecting errors in the model
p Ease of computing the solution
p Units of measurement, scaling the
coefficients, robustness

22
How to Build a Good Model
p Ease of understanding the model
n Use mnemonic (related) names for variables and
constraints

n Explicit definition of an expression by a variable


may help
f(x) – y = 0
even though this could be avoided for compactness

n Examples: inventory in a period, total revenue,


total waiting time

23
How to Build a Good Model
p Ease of detecting errors in the model
n Clerical errors
p to avoid, use a matrix generator or a modeling
language
n Formulation errors
p Unbounded or infeasible models are usually indicators
of error
p Use “presolve” or “reduce” procedures to detect
p Examine if the optimal solution is sensible, check
objective value
p Use known feasible solutions for testing

24
How to Build a Good Model
p Ease of computing the solution
n Realistic assumptions may simplify the model
p LP -> NLP -> IP -> Nonlinear IP -> Stochastic Models
n Reduction procedures that detect redundancy and
fix some variables may reduce size of the model
n Structured models, e.g. network models
n Decomposable models, e.g. several periods,
products, factories
n For IPs, strong LP relaxations lead to significant
improvements in solution time

25
How to Build a Good Model
p Units of measurement
n When writing constraints make sure lhs and rhs
have the same units
n Disparity in the sizes of coefficients leads to
unstable models
n Rule of thumb: define variables so that coefficients
are in the range 1 to 100
p Ex: 10000x, x: tons; 10x, x:1000 tons

n Most packages have scaling procedures

26
Sources
p Videos:
n INFORMS Video Library:
p https://www.informs.org/Resource-Center/Video-
Library
n OR application examples:
p https://www.youtube.com/watch?v=0oMVVx81kCs
p https://www.youtube.com/watch?v=sFWrmpXPVJw

27

You might also like