ADVANCED ALGORITHMS
Lecture 19: optimization, linear programming
1
ADVANCED ALGORITHMS Lecture 19: optimization, linear programming 1 - - PowerPoint PPT Presentation
ADVANCED ALGORITHMS Lecture 19: optimization, linear programming 1 ANNOUNCEMENTS HW 4 is due on Monday, November 5 lb mod 2 Project meetings air n L 2 LAST CLASS Optimization {x 1 , x 2 , , x n } are variables
Lecture 19: optimization, linear programming
1
ANNOUNCEMENTS
➤ HW 4 is due on Monday, November 5 ➤ Project meetings …
2
air
lb
n
mod2
LAST CLASS
3
➤ Optimization ➤ Can phrase many natural problems as optimization — e.g. scheduling, matching,
shortest paths, … [[why?]]
➤ {x1, x2, …, xn} are variables — values in some domain D ➤ find maximum value of f(x) subject to
g2(x) ≥ 0 g1(x) ≥ 0 ….
EXAMPLE: MATCHING
4
EXAMPLE: SHORTEST PATHS
5
➤ What are variables? ➤ What are constraints? ➤ What is the objective?
{xe}e∈E
Variables: Three different ways of writing constraints … (“matrix powers”, flow based, cut based) Objective: minimize∑
e
wexe
AE
linear constrain
exponentially manyof
their
polynomial constraints
introducing directed
edges
in deg
EXAMPLE: SPANNING TREE
6
WE
a
Pro I
G
aoe
is.to
a
sub
see 0 if
e is notselected
total weight
so that
the
l if
e is selected
graph is connected
min Exe we
ideas take any
method we saw for enforcing
a
path between
s t
use such constraints As 1
EXAMPLE: SPANNING TREE
7
see
n
t
along with
no cycles
Hs
ne
E 1st I
e with
bothendpbu.rs
Cut
m
Vstfo.BE He 7
e in the
cut 15,5
ZOOMING OUT
8
➤ What are variables? ➤ What are constraints? ➤ What is the objective?
Argue about constraints
capturing the problem
WHEN CAN WE SOLVE OPTIMIZATION?
9
➤ The bad news: ➤ all the formulations we wrote so far are intractable!
ni E 0113
D
Discrete optimization
is generally hard
WHEN CAN WE SOLVE OPTIMIZATION?
10
➤ The bad news: ➤ all the formulations we wrote so far are intractable! ➤ The good news: ➤ Continuous optimization with linear constraints, objective ➤ Convex optimization
Main challenge: can we express problem of interest as an optimization we can solve?
Linear programs
i
local search
TODAY
11
➤ Linear and convex optimization ➤ Visualizing linear optimization ➤ Express problems as linear optimization ➤ What to do with a solution?
LINEAR PROGRAMMING
12
Variables
a fx
xn EIR
Objedive
min
c
n
t Gaz t
1 Cnnn
I Ise
Constraints
Ann t Aizazt
t AinXn
I b ATn Sb
I
LINEAR PROGRAMMING — TWO DIMENSIONS
13
ni
na EIR
m.nuTsnbiea to
Gen
sn
Each constraint is
half space
Overall set of feasible solutions is
an
intersection of half spaces
I.T
X
1
2
X
X
L j
X
t Xz
2
a
a
Objective function defines
a direction
the optimum point is
the'furthestpoint
in the
fean.to
Qection
LINEAR PROGRAMMING — TWO DIMENSIONS
14
OPTIMAL POINT ALWAYS A “CORNER”
15
suppose
the
feasible set
Aaa'InI
is
mdd Then for any
e EIR
theanoptimalpoint
corner point of this feasible set
c
Hand
ALGORITHM FOR LINEAR PROGRAMMING — 2 DIMENSIONS
16
GENERAL ALGORITHM & RUN TIME
17
IMPROVEMENT — ALWAYS MOVE TO “NEIGHBOR”?
18
CAN WE GET STUCK?
19
CONVEX OPTIMIZATION
20
GENERAL RESULTS
21
➤ [Dantzig]: simplex algorithm ➤ Khachiyan’s “ellipsoid” algorithm
MATCHING AS LINEAR PROGRAMS
22
MATCHING AS LINEAR PROGRAMS
23