PowerPoint **

advertisement
以分支界限法為基礎的啟發式方法
求解二次指派問題
A heuristic method based on branch and bound algorithm
for solving quadratic assignment problems
指導教授:楊能舒 教授
學生:陳泓翔
Reporting process
一
Introduction
二
Literature
review
Background
Motivation
Research
Objective
Research
Process
三
Research
Methods
四
Scope
of
Research
Spreadsheet
Literature
Table
Branch
And
Bound
五
Conclusion
&
Timetable
Conclusion
Research
Plan
Heuristic
Method
Timetable
Solution
Procedure
1.Introduction-Background
Department 1
Location
Matrix A:the distance
between location
Department 2
Department 4
Department 3
Matrix B:the interaction
among the department
One department
Assign to
One location
Matrix U:
Assigned matrix
1.Introduction-Background
If the flow matrix is symmetrical
Total cost(2134)=
𝑗≠𝑖 𝑤𝑖𝑗 𝑑
𝑎𝑖 , 𝑎𝑗
= 1×7+2×7+4×0
+
1×8+3×4
+
2×5
= 51
1
2
1
3
3
4
3
4
4
But there exist 4!=24 different layouts if we don’t know
optimal solution
1.Introduction-Motivation
Spreadsheets
(Rasmus 2007)
QAP
framework
method
Use LAP to solve
(francis and white
1974)
Bound Value
generated
trouble!
Branch and Bound
This research try to
use Genetic Algorithm
Better ?
1.Introduction-Research objective
QAP
Genetic
Algorithm
Branch and Bound
search: Expect to get better
Bound value
A heuristic
method
Use LAP to Calculate
Bound Value generated
trouble!
Use A heuristic method
To reduce the complexity of branch and bound for solving quadratic
assignment problems
1.Introduction-Research objective
QAP
High complexity
Spreadsheets
Can not be
solved
Low complexity
Spreadsheets
Good solution
quality and speed
Use A heuristic method compared with Spreadsheets ,
expect to solve Spreadsheets’s defect
1.Introduction-Research Process
2.Literature review-Literature table
作者
年代
1
Rasmus
Rasmussen
2007
Use EXCEL to solve
QAP:Input distance matrix
and flow matrix, and
develop a set of formulas
to solve QAP easier
When solving the
Low complexity
QAP, have good
solution, but can
not solve High
complexity
problems
Provided the
Motivation
2
Francis,
White
1974
Use Branch and Bound to
solve QAP
Have good
solution, but
Bound value have
the problem
Objective :Improve
Branch and Bound
3
Y. Yuan,
S. Omatu
2000
Use GA With Local Search
Policy to solve QAP
Compared with
genetic algorithms,
the result is better
than genetic
algorithms
genetic algorithms
for solving QAP
has good results,
and can be
improved
4
Yong zhong
Wu,
Ping Ji
2008
Use GA With New
Replacement Strategyto
solve QAP
Compared with
genetic algorithms,
the result is better
than genetic
algorithms
genetic algorithms
for solving QAP
has good results,
and can be
improved
NO
方法
結果
和本研究相關性
2.Literature review-Literature table
NO
作者
年代
方法
結果
和本研究相關性
5
G.Askin,
R.Standridge
1999
QAP definition
and introduce a
variety of
different
solutions
These
methods are
used to solve
the QAP can
be obtained a
good solution
Understand the
definition of the QAP
and choose the branch
and bound method to
do for the study of
framework
6
Peter Hahn,
Thomas Grant,
Nat Hall
1998
Use hungarian
method based
on branch and
bound to solve
QAP
Has better
solutions
Branch and bound to
solve QAP can be
improved
7
Hsin-Fu Chen
2004
proposed two
methods to
speed up the
solving
efficiency of
branch and
bound
Has better
solutions
Understanding branch
and bound’s
framework and how
to improve the branch
and bound
3. Research Methods-Spreadsheets
Department 1
Location
Matrix A:the distance
between location
Department 2
Department 4
Department 3
Matrix B:the interaction
among the department
One department
Assign to
One location
Matrix U:
Assigned matrix
3. Research Methods-Spreadsheets
R. Rasmussen(2007)提出spreadsheets的方法
A: Distance matrix
B: Interaction flow matrix
U: Assignment matrix
3. Research Methods-Spreadsheets
B
Min S =
0
7
8
4
7
0
7
0
8
7
0
5
U
4
0
5
0
×
1
0
0
0
0
0
1
0
0
0
0
1
0
1
0
0
×
0
7
8
4
= 51
7
0
7
0
8
7
0
5
A
4
0
5
0
×
1
0
0
0
0
0
1
0
0
0
0
1
U
0
1
0
0
TRACE
1 0 0 0
T
0 1 0 0 1
× 0 0 1 0 ×
2
0 0 0 1
3. Research Methods-Spreadsheets
Can be solved by programming solver and obtain the minimum cost solution of this equation by
Spreadsheets
3. Research Methods-Branch&Bound
(1.....)
(21....)
(2.....)
(3.....)
(23....)
(4.....)
(24....)
(5.....)
(25....)
(6.....)
(26....)
3. Research Methods-Branch&Bound
If (2 1 ....) are assigned
Assigned
Unassigned
4/?
3/?
2
2
2
1/2
5/?
6/?
2
2/1
2
3. Research Methods-Branch&Bound
B21= W21 ×d(a(2)=1,a(1)=2)+ W12 × d(a(1)=2,a(2)=1)
Between already assigned departments
+ W23 × d(a(2)=1,a(3)=?)+ W24 × d(d(a(2)=1,a(4)=?)+ …
+ W13 × d(a(1)=2,a(3)=?)+ W14 × d(d(a(1)=2,a(4)=?)+ …
Between already assigned departments and not yet assigned departments
+ W34 × d(a(3)=?,a(4)=?)+ W35 × d(d(a(3)=?,a(5)=?)+ …
Between not yet assigned departments
The number of all the Wxd arcs symmetric and
non-symmetric are 30
3. Research Methods-Branch&Bound
What if the Flow and Distance Matrix are symmetric
w21xd(a(2)=1,a(1)=2) = w12xd(a(1)=2,a(2)=1)
w23xd(a(2)=1,a(3)=?) = w32xd(a(3)=?,a(2)=1)
w34xd(a(3)=?,a(4)=?) = w43xd(a(4)=?,a(3)=?)
Save the calculations by half
But in real world, distance may be symmetric, flow is usually not
3. Research Methods-Branch&Bound
Let partial assignment 𝑎𝑞 = 𝑎𝑞1 , 𝑎𝑞2 , 𝑎𝑞3 , ..., 𝑎𝑞𝑞
denote the locations of Departments 1,2,3...q,
where q≤M
3. Research Methods-Branch&Bound
𝑞
𝑞−1
TC 𝑎𝑞 =
𝐶𝑖𝑎𝑖 +
𝑖=1
𝑢𝑚𝑖≤𝑗≤𝑞 𝑤𝑖𝑗 𝑑 𝑎𝑖 , 𝑎𝑗
𝑖=1
𝑀
Assigned departments to
other assigned departments
𝑞
+
𝐶𝑗𝑎𝑗 +
𝑗=𝑞+1
𝑤𝑖𝑗 𝑑 𝑎𝑖 , 𝑎𝑗
𝑖=1
Yet to be assigned departments
to assigned departments
𝑀−1
+
𝑤𝑖𝑗 𝑑 𝑎𝑖 , 𝑎𝑗
𝑖=𝑞+1 𝑗>𝑖
The interaction cost of
unassigned departments
3. Research Methods-Branch&Bound
If (2 1 ....) assigned
we calculate the bound value of B21 by following steps
Assigned
Unassigned
2/1
3/?
4/?
1/2
5/?
6/?
3. Research Methods-Branch&Bound
𝑞
𝑞−1
TC 𝑎𝑞 =
𝐶𝑖𝑎𝑖 +
𝑖=1
𝑢𝑚𝑖≤𝑗≤𝑞 𝑤𝑖𝑗 𝑑 𝑎𝑖 , 𝑎𝑗
𝑖=1
𝑀
Assigned departments to
other assigned departments
𝑞
+
𝐶𝑗𝑎𝑗 +
𝑗=𝑞+1
𝑤𝑖𝑗 𝑑 𝑎𝑖 , 𝑎𝑗
𝑖=1
Yet to be assigned departments
to assigned departments
𝑀−1
+
𝑤𝑖𝑗 𝑑 𝑎𝑖 , 𝑎𝑗
The interaction cost of
unassigned departments
𝑖=𝑞+1 𝑗>𝑖
What we know
The flow and distance between those departments already assigned to specific
locations
3. Research Methods-Branch&Bound
𝑞
𝑞−1
TC 𝑎𝑞 =
𝐶𝑖𝑎𝑖 +
𝑖=1
𝑢𝑚𝑖≤𝑗≤𝑞 𝑤𝑖𝑗 𝑑 𝑎𝑖 , 𝑎𝑗
𝑖=1
𝑀
Assigned departments to
other assigned departments
𝑞
+
𝐶𝑗𝑎𝑗 +
𝑗=𝑞+1
𝑤𝑖𝑗 𝑑 𝑎𝑖 , 𝑎𝑗
𝑖=1
Yet to be assigned departments
to assigned departments
𝑀−1
+
𝑤𝑖𝑗 𝑑 𝑎𝑖 , 𝑎𝑗
The interaction cost of
unassigned departments
𝑖=𝑞+1 𝑗>𝑖
What we do not know, But we can Guess in a logical sense
The flow and distance between those departments not yet assigned to specific
locations
3. Research Methods-Branch&Bound
𝑞
𝑞−1
TC 𝑎𝑞 =
𝐶𝑖𝑎𝑖 +
𝑖=1
𝑢𝑚𝑖≤𝑗≤𝑞 𝑤𝑖𝑗 𝑑 𝑎𝑖 , 𝑎𝑗
𝑖=1
𝑀
Assigned departments to
other assigned departments
𝑞
+
𝐶𝑗𝑎𝑗 +
𝑗=𝑞+1
𝑤𝑖𝑗 𝑑 𝑎𝑖 , 𝑎𝑗
𝑖=1
Yet to be assigned departments
to assigned departments
𝑀−1
+
𝑤𝑖𝑗 𝑑 𝑎𝑖 , 𝑎𝑗
𝑖=𝑞+1 𝑗>𝑖
The interaction cost of
unassigned departments
3. Research Methods-Branch&Bound
What to do with those un assigned departments
assign these departments to every possible location
An Optimal Solution can be found by LAP
3. Research Methods-Branch&Bound
Assign Department 3 to Location 3
3/3
Department
w34 4
w35 5
w36 6
Location
4
5
6
d34
d35
d36
3. Research Methods-Branch&Bound
3. Research Methods-Branch&Bound
The cheapest way is to use the shortest distances for the
highest flow volumes
WxD= [w41 w45 w46] x d34
d35
d36
3. Research Methods-Branch&Bound
Calculated for each value of the G matrix to
find the best arrangement unassigned
G=3
4
5
6
3
4
5
6
g33
g43
g53
g63
g34
g44
g54
g64
g35
g45
g55
g65
g36
g46
g56
g66
+
w*d (assigned)
= Bound value of Node B21
3. Research Methods-Branch&Bound
Backtracking : Search Procedure
(1.....)
(2.....)
B=30
B=15
(21....)
B=35
(3.....)
(4.....)
(5.....)
(6.....)
B=18
B=25
B=28
B=32
(23....)
(24....)
B=20
B=38
(25....)
B=33
(26....)
B=39
3. Research Methods-Branch&Bound
Live Search List
(B1=30, B2=15, B3=32, B4=18, B5=25, B6=28)
(B1=31, B21=35, B23=20, B24=33, B25=38, B26=39, B3=32, B4=18, B5=25, B5=28)
3. Research Methods- Heuristic method
(1.....)
(2.....)
B=30
B=15
(21....)
B=35
(3.....)
(4.....)
(5.....)
(6.....)
B=18
B=25
B=28
B=32
(23....)
(24....)
B=20
B=38
(25....)
B=33
(26....)
B=39
3. Research Methods-Heuristic method
Why Bound value have problem?
WxD= [w41 w45 w46] x
3
G=3
4
5
6
g33
g43
g53
g63
4
g34
g44
g54
g64
5
g35
g45
g55
g65
d34
d35
d36
6
g36
g46
g56
g66
3. Research Methods- Heuristic method
Automatically Assign
4/5
3/4
3/3
4/6
???
½+½=1 ???
3. Research Methods- Genetic Algorithm
So we do not use LAP find the solutions, use GA based on branch and
bound method to find a better solutions
1.[coding]
Department 1(1)、 Department 2(2)、 Department 3(3)、
、、、 Department 6(6)
2.[Initialization]
Ex: 213456 123456 132546 345612
3. [fitness function]
Ex:f(213456) = 30
3. Research Methods- Genetic Algorithm
4. [selection] selected for next generation
5. [crossover]
If S1=241356 S2=214563
then S1=2143563 S2=214356
6. [mutation]
Before mutation
241356
7. Repeat 4. 5. 6 until end
after mutation
261354
3. Research Methods- Heuristic method
What to do with those unassigned departments
assign these departments to every possible location
So we use GA Try to found better Bound value
3. Research Methods- Heuristic method
(1.....)
(21....)
(2.....)
(3.....)
(23....)
(4.....)
(24....)
(5.....)
(25....)
(6.....)
(26....)
3. Research Methods-Method Procedure
QAP
Branch&Bound
Use LAP
Bound value has
problem!
Good Solution
Use GA
Different!
Good Solution
4.Scope of Research-Research plan
Compared following algorithms to explore the feasibility of the
new heuristic method
1.Branch and Bound
2.Spreadsheets
3. Heuristic method
4.Scope of Research-Research plan
According to the problems characteristic comparison methods
problem
method
Spreadsheets
Branch and
bound
A heuristic
method
Problem Size Symmetrical
(ex:3*3 6*6)
Flow Size
Distance
…..
5. Conclusion
This study proposes a heuristic method based on branch and
bound algorithm for solving quadratic assignment problems, aims
to improve the LAP for solving quadratic assignment problems’s
defect .
In this research, we will compared three methods with the
different kind of problems, and look forward to providing a solving
method for solving quadratic assignment problem’s people.
5. Timetable
Thanks for your listening
Download