Professional Documents
Culture Documents
Optimization Examples
Notation
Problem Classification
Modeling
Chapter 6
Introduction to Optimization
1 / 34
Introduction
Optimization Examples
Notation
Problem Classification
Modeling
Outline
1 Introduction
Motivation
Definition
2 Optimization Examples
3 Notation
4 Problem Classification
Convex vs. non-convex
Continuous vs. discrete optimization
Constrained vs. unconstrained
Single- vs. Multi-objective optimization
5 Modeling
2 / 34
Introduction
Optimization Examples
Motivation
Notation
Definition
Problem Classification
Modeling
Motivation
3 / 34
Introduction
Optimization Examples
Motivation
Notation
Definition
Problem Classification
Modeling
Definition
4 / 34
Introduction
Optimization Examples
Notation
Problem Classification
Modeling
5 / 34
Introduction
Optimization Examples
Notation
Problem Classification
Modeling
Problem statement:
Find the maximal and minimal value of f (x , y ) = 3x + 4y
subject to the following constraints:
x + 2y ≤ 14,
3x − y ≥ 0,
x − y ≤ 2;
6 / 34
Introduction
Optimization Examples
Notation
Problem Classification
Modeling
Solution:
Rewrite:
x + 2y ≤ 14 y ≤ −0.5x + 7
3x − y ≥ 0 ⇒ y ≥ 3x
x −y ≤2 y≤ x − 2
Plot and identify the feasibility region.
7 / 34
Introduction
Optimization Examples
Notation
Problem Classification
Modeling
Solution:
Evaluate f (x , y ) at corner points:
Corner 1 Corner 2 Corner 3
y = −0.5x + 7 y = −0.5x + 7 y = 3x
y = 3x y =x −2 y =x −2
intersection at intersection at intersection at
(2, 6) (6, 4) (−1, −3)
f (x , y ) = 30 f (x , y ) = 34 f (x , y ) = −15
Identify the minimal and the maximal from the corner
points
- The maximum of f (x , y ) = 34 occurs at (6, 4), and
- The minimum of f (x , y ) = −15 occurs at (−1, −3).
8 / 34
Introduction
Optimization Examples
Notation
Problem Classification
Modeling
Problem statement:
A student has a choice of breakfast menu (eggs, cereals, tarts)
and a limited ($10) budget to fulfill his/her nutrition needs
(1000 calories, 100 g protein) at minimum cost. Eggs provide
500 calories and 50g protein and cost $3.50; cereals provide
500 calories and 40g protein and cost $3; tarts provide 600
calories and 20g protein and cost $2. How does he/she choose
his/her breakfast mix?
9 / 34
Introduction
Optimization Examples
Notation
Problem Classification
Modeling
Formulation:
Let x T = [x1 , x2 , x3 ] represent the quantities of eggs, cereals
and tarts chosen for breakfast. Then, the optimization
problem is mathematically formulated as follows:
subject to:
10 / 34
Introduction
Optimization Examples
Notation
Problem Classification
Modeling
Problem statement:
A manufacturer produces two products: tables and chairs.
Each table requires 10 kg of material and 5 units of labor, and
earns $7.50 in profit. Each chair requires 5 kg of material and
12 units of labor, and earns $5 in profit. A total of 60 kg of
material and 80 units of labor are available. Find the best
production mix to earn maximum profit.
11 / 34
Introduction
Optimization Examples
Notation
Problem Classification
Modeling
Formulation:
Let x T = [x1 , x2 ] represent the quantities of tables and chairs
to be manufactured. Then, the optimization problem is
mathematically formulated as follows:
subject to:
12 / 34
Introduction
Optimization Examples
Notation
Problem Classification
Modeling
Problem statement:
Find the shortest distance from a given point (x0 , y0 ) to a
given curve: y = f (x ).
Formulation:
The optimization problem is mathematically formulated to
minimize the Euclidian distance from the given point to the
curve:
min f = (x − x0 )2 + (y − y0 )2
x ,y
subject to:
y = f (x )
13 / 34
Introduction
Optimization Examples
Notation
Problem Classification
Modeling
Problem statement:
Given a set of N data points (xi , yi ), i = 1, . . . , N, fit a
polynomial of degree m to the data such that the mean
square error N 2
i=1 (yi − f (xi )) is minimized.
P
Formulation:
Let the polynomial be given as: f (x ) = a0 + a1 x + · · · + am x m
then, the unconstrained optimization problem is formulated as:
N
X
min f = (yi − a0 − a1 x − · · · − am x m )2
a0 ,··· ,am
i=1
14 / 34
Introduction
Optimization Examples
Notation
Problem Classification
Modeling
Problem statement:
Given an assortment of n items, where each item i has a value
ci > 0, and a weight wi > 0, fill a knapsack of given capacity
(weight W ) so as to maximize the value of the included items.
Formulation:
Without loss of generality, we assume that W = 1. Let
xi ∈ {0, 1} denote the event that item i is selected for
inclusion in the sack; then, the knapsack problem is
formulated as:
n
X n
X
max f = ci xi subject to: wi xi ≤ 1
ai
i=1 i=1
15 / 34
Introduction
Optimization Examples
Notation
Problem Classification
Modeling
Problem statement:
Given the stock prices pi and anticipated rates of return ri
associated with a group of investments, choose a mix of
securities to invest a sum of $1M in order to maximize return
on investment.
Formulation:
Let xi ∈ {0, 1} express the inclusion of security i in the mix,
then the investment problem is modeled as the knapsack
problem.
16 / 34
Introduction
Optimization Examples
Notation
Problem Classification
Modeling
subject to:
X X
xij = si , for i = 1, . . . , m; xij = dj , for j = 1, . . . , n; xij ≥ 0
j i
17 / 34
Introduction
Optimization Examples
Notation
Problem Classification
Modeling
Problem statement:
Find the shortest path from node p to node q in a connected
graph (V , E ), where V denotes the vertices and E denotes
the edges.
Formulation:
Let eij denote the edge incident to both nodes i and j and let
f : E → R represent a real-valued weight function; further, let
P = (v1 , v2 , . . . , vn ) denote a path, where v1 = p, vn = q;
then, the unconstrained single-pair shortest path problem is
formulated as:
n−1
X
min f = ei,i+1
n
i=1
18 / 34
Introduction
Optimization Examples
Notation
Problem Classification
Modeling
subject to:
X X 1,
for i = p;
xij − xji = −1, for i = q;
0,
j j otherwise.
Problem formulation:
Parameters:
i: index on the set of demands F = {1, ..., n};
ai : capacity used by demand i (∀i ∈ F );
ci : routing cost for demand i on link 1 (∀i ∈ F );
p: cost percentage difference between routing on link 2 and
link 1;
u1 : capacity installed on link 1;
u2 : capacity installed on link 2.
Optimization variables:
xi1 = 1 if packet i is routed on link 1, 0 otherwise (∀i ∈ F );
xi2 = 1 if packet i is routed on link 2, 0 otherwise (∀i ∈ F ).
22 / 34
Introduction
Optimization Examples
Notation
Problem Classification
Modeling
n
X
min f = (ci xi1 + (p + 1)ci xi2 )
xi1 ,xi2
i=1
subject to:
xi1 + xi2 = 1 ∀i ∈ F ,
X
ai xi1 ≤ u1 ,
i=1
X
ai xi2 ≤ u2 .
i=1
23 / 34
Introduction
Optimization Examples
Notation
Problem Classification
Modeling
Exercise:
1 Solve the above example using Microsoft Excel’s Solver
package.
2 How would you change the model to generalize to a situation
with m possible parallel links between s and t?
24 / 34
Introduction
Optimization Examples
Notation
Problem Classification
Modeling
Problem statement:
In wireless system with L transmitter-receiver pairs
(communication links), a reliable communication is
established if signal-to-interference and noise ratios (SINRs)
Gii Pi
γi (P) = PL
σi + j6=i Gij Pj
25 / 34
Introduction
Optimization Examples
Notation
Problem Classification
Modeling
Problem formulation:
L
X
min f = Pi
Pi
i=1
subject to:
γi (P) ≥ γ0 , i = 1, . . . , L
0 ≤ Pi ≤ Pmax , i = 1, . . . , L.
26 / 34
Introduction
Optimization Examples
Notation
Problem Classification
Modeling
Notations
The following notation is used:
R denotes the set of real numbers;
Rn denotes the set of real n-vectors;
Rm×n denotes the set of real m × n matrices;
f : Rn → Rm denotes an Rm valued function defined over Rn ;
Z denotes integer vectors;
Small bold face letters such as x, y are used to represent
vectors or points in Rn ;
capital bold face letters such as A, B are used to represent
matrices;
Aq represents qth column of A; and,
I represents an identity matrix.
27 / 34
Introduction
Convex vs. non-convex
Optimization Examples
Continuous vs. discrete optimization
Notation
Constrained vs. unconstrained
Problem Classification
Single- vs. Multi-objective optimization
Modeling
Standard form
Mathematical optimization
min f (x )
x ∈Rn
subject to :
ci (x ) = 0, i = 1, . . . , ne
dj (x ) ≥ 0, j = 1, . . . , ni
31 / 34
Introduction
Convex vs. non-convex
Optimization Examples
Continuous vs. discrete optimization
Notation
Constrained vs. unconstrained
Problem Classification
Single- vs. Multi-objective optimization
Modeling
32 / 34
Introduction
Convex vs. non-convex
Optimization Examples
Continuous vs. discrete optimization
Notation
Constrained vs. unconstrained
Problem Classification
Single- vs. Multi-objective optimization
Modeling
33 / 34
Introduction
Optimization Examples
Notation
Problem Classification
Modeling
Modeling
Modeling: the process of identifying the objective, variables,
and constraints for a given problem.
The more abstract the problem, the more difficult modeling
becomes.
34 / 34