Shortest Path

Shortest Path
吳仲軒(9526709)
前言
• 本系列章節主要利用圖解法探討最小花
費之網路流通問題
• 同時轉換其他模型使其成為網路流通模
型
簡介
• Let G=(N,A) be a directed network defined
by a set N of n node and A of m directed
arcs
• Each arc (i,j)€A has associated cost Cij per
unit flow on that arc
Min ∑Cij Xij
(i,j)€A
ST ∑ Xij –
{J:(i,j)€A}
∑Xji =b(i)……..(1b)
{I:(j,i)€A}
(Mass balance constraints)
Lij ≤Xij≤Uij………………..(1C)
(The flow Bound constraint)
Shortest Path problem
• We wish to minimum cost (length) form the
starting node to the ending
Applications-1 System of difference constraints
Example
• X(ik)-X(jk)≦Xb(k) for k=1………….m
• X(3)-X(4) ≦5
•X(4)-X(1) ≦-10
•X(1)-X(3) ≦8
•X(2)-X(1) ≦-11
•X(3)-X(2) ≦-2
• 1-最短路徑d(i)從Source Node 至任何
Node i 皆滿足Optomality conditions d(j)d(i) ≦Cij
• 2.最短路徑只在沒有Negative Cycle時成
立
• Fig 1
•
•
•
•
Because 1->2->3->1=-1
It’s not a feasible solution
Using a label correcting algorithm
Fig 2
Telephone operator Scheduling
23
Min∑ Yi
I=0
S.T Yi-7+Yi-6…….+Yi ≥ b(i)
(For i=8 to 23)
Y17+i+….+Y23+….Yi ≥ b(i)
(For i=0 to 7)
Yi ≥0
• Shortest path has a special structure.
• The associated constraint only 0’s and 1’s
and 0’s or 1’s in each row consecutively
≥
• X(i)-X(i-8) ≥b(i)
• X(23)-X(16+i)+X(i)=P-X(16-i)+X(i) ≥b(i)
• X(i)-X(i-1) ≥0
Application 3 Production
planning problems
• 問題概敘
• See p11 Fig(a)
Application 4 Approximating piecewise linear functions
• 嘗試將一線圖簡化 如下圖
3
簡化時產生的Cost 可轉換為以下的公式
P
β∑[F1(Xk)-F2(Xk)]^2
K=1
•
P
Cij= α + β∑[F1(Xk)-F2(Xk)]^2
K=1