The geometric GMST problem with grid clustering
Presented by 楊劭文 , 游岳齊 , 吳郁君 , 林信仲 , 萬高維Department of Computer Science and
Information Engineering, National Taiwan University
Outlines
• Geometric GMST with grid clustering• Proof of NP-hardness
– Reduction– Optimal structure– Optimal cost
• Dynamic programming algorithm• Polynomial time approximation scheme
2Special Topics on Graph Algorithms
Minimum Spanning Tree
• a tree formed from a subset of the edges in a given undirected graph, with two properties:– (1) it spans the graph, i.e., it includes every vertex
in the graph, and – (2) it is a minimum, i.e., the total weight of all the
edges is as low as possible.
3Special Topics on Graph Algorithms
Generalized Minimum Spanning Tree• A partition of the vertex set V into clusters
• Find a tree of minimum cost containing at least one vertex in each cluster
4Special Topics on Graph Algorithms
Applications
• Applications are encountered in telecoms.
5Special Topics on Graph Algorithms
Geometric GMST w/grid clustering
• The graph is complete• All vertices are the points situated inside the
k × l planar integer grid• Edge cost: Euclidean distance between the
points in the plane• All points in the same cell form a cluster• k × l grid is the smallest integer grid containing
all points
6Special Topics on Graph Algorithms
Geometric GMST w/grid clustering
7Special Topics on Graph Algorithms
Outlines
• Geometric GMST with grid clustering• Proof of NP-hardness
– Reduction– Optimal structure– Optimal cost
• Dynamic programming algorithm• Polynomial time approximation scheme
8Special Topics on Graph Algorithms
Theorem 1
The geometric GMST is strongly NP-hard, even if we restrict to instances in which all nonempty
grid cells are connected and each grid cell contains at most two points
• Proof by reducing from the problem exact cover by 3-sets (X3C)
9Special Topics on Graph Algorithms
Exact Cover by 3-Sets
• A ground set X = {1, 2, … , n}, n = 3q
S1 S2 S3 S4
x1 x3 x4x2 x5 x6
• C = {S1, S2, …, Sm}– For 1 ≤ i ≤ m, Si is a subset of X
– |Si| = 3
10Special Topics on Graph Algorithms
Exact Cover by 3-Sets
• Is there a set C’ such that– C’ ⊆ C– The elements of C’ are disjoint and– For each xi C’, Uxi = X
x1 x3 x4x2 x5 x6
S1 S2 S3 S4
11Special Topics on Graph Algorithms
x2
x1
S1S2 S3
12Special Topics on Graph Algorithms
x1 S3
x2 S2
13Special Topics on Graph Algorithms
Outlines
• Geometric GMST with grid clustering• Proof of NP-hardness
– Reduction– Optimal structure– Optimal cost
• Dynamic programming algorithm• Polynomial time approximation scheme
14Special Topics on Graph Algorithms
Connecting Edge
• Connecting Edge (dotted edge)• Its length d is slightly larger
than √2.• Assume d is arbitrary
close to √2.
15Special Topics on Graph Algorithms
Lemma1
• No edge in Topt is larger than d, where Topt is some optimal solution.
16Special Topics on Graph Algorithms
Optimal subgraph
17Special Topics on Graph Algorithms
Lemma2
• The subgraph induced by an arbitrary optimal solution and nonempty cells of an arbitrary block is connected.
18Special Topics on Graph Algorithms
Optimal Subgraph
19Special Topics on Graph Algorithms
Two possible structures
• Two possible structure in a column.– By lemma1 and lemma2
• Trunk: the structure in a column.
20Special Topics on Graph Algorithms
Outlines
• Geometric GMST with grid clustering• Proof of NP-hardness
– Reduction– Optimal structure– Optimal cost
• Dynamic programming algorithm• Polynomial time approximation scheme
21Special Topics on Graph Algorithms
Calculate the Total Cost
• For any n ≥ 1 let be the total cost of the edges in a trunk
• Let > 0 be a small enough number.
22Special Topics on Graph Algorithms
• we can move some points by a very small distance– The cost of a red trunk remains– The cost of a blue trunk is– Connecting blocks in a red trunk costs d– The connection cost for a blue trunk is as follows.
Connecting block i with block i + 1 in column j costs d − if i and ∈ d otherwise
Differences between Red Trunk & Blue Trunk
23Special Topics on Graph Algorithms
Definition
• let Z = c( ) be its cost.• = Z−3(m−1)(n+1)• let be the contribution of column j•
24Special Topics on Graph Algorithms
Connecting edge
• For a connecting edge e in a column j wedefine its averaged connecting cost as
where is the number of connecting edges in column j.
• We have
25Special Topics on Graph Algorithms
Use Blue Trunk
• the averaged connecting cost c(e) for each of the three connecting edges e in this column is
• if a column j contains at least one connecting edge e that connects block i with block i+1 while , then the averaged connecting cost c(e) is at least
26Special Topics on Graph Algorithms
433
3
31 332
dt
dtdt
ntt
tddAAec nn
X3CGMST
• If an exact cover exists
• if no cover exists
27Special Topics on Graph Algorithms
Outlines
• Geometric GMST with grid clustering• Proof of NP-hardness
– Reduction– Optimal structure– Optimal cost
• Dynamic programming algorithm• Polynomial time approximation scheme
28Special Topics on Graph Algorithms
Definitionst {1, 2, ∈ . . . , − 3}
Ct: The tth columnSt: subset of V containing exactly
one point from each nonempty cell in Ct+1,Ct+2, and Ct+3.
Tt: edge set on St-1 U St
M: zero-one transitive matrix represents the connectivity
f (St,M): a generalized minimum spanning forest
Ct Ct+2 Ct+3Ct+1
St-1
St
… …
M
M’
f (St,M)
f (St-1,M’)
29Special Topics on Graph Algorithms
Lemma 3
Assume that all nonempty grid cells are connected, then an optimal solution of a geometric GMST with grid clustering does not contain edges of length greater than 2√2.
By Lemma 3, any forest f(St, M) can be obtained as a forest f(St-1, M’) extended by a subset Tt of edges on the point set St-1∪St.
30Special Topics on Graph Algorithms
Dynamic programming algorithm
The recursive relation:
Consistency
Enumerate St and M
Enumerate St-1 and M’
Enumerate Tt
kO 3 292 kO
2162 kO
Adding 2kO
kO 3 292 kO
kS 3
kkM 33
4k points
Number of St O 31Special Topics on Graph Algorithms
Theorem 2
The dynamic programming algorithm solves the geometric GMST with connected nonempty grid cells in time
2346 2
2 kO kk
The computation time is polynomial if k is fixed.
32Special Topics on Graph Algorithms
Outlines
• Geometric GMST with grid clustering• Proof of NP-hardness
– Reduction– Optimal structure– Optimal cost
• Dynamic programming algorithm• Polynomial time approximation scheme
33Special Topics on Graph Algorithms
Polynomial Time Approximation Scheme (PTAS)
• Assume all nonempty grid cells are connected.• The number is at least .• The PTAS is based on the DP.• It is a - approximation where .
kkfkf 1,
1 0
34Special Topics on Graph Algorithms
Partitioning into Slices
• Define . 2811 kf
Slice 1
Slice 2
Slice 3
Slice △
Row
k 1k
k2
k
1#Rows
1O
1O
1O
35Special Topics on Graph Algorithms
Finding GST for each Slice
• GMSTs are obtained by applying DP.• Obtain a GST by adding edges only in the
upper/bottom rows of the slice.
Slice i
11 ki
ki
iT
36Special Topics on Graph Algorithms
Obtaining the GST for the Graph
• Picking edges greedily yields GST .
Slice 1
Slice 2
Slice 3
Slice △
Row
k 1k
k2
k
1
APPXT
37Special Topics on Graph Algorithms
TAPPX: (1+ ε)-approximation
1.
2.
OPT
OPTAPPX
TcTcTc
:Claim
1
22i
iAPPX TcTc
1i
iOPT FcTc TOPT
1F2F
F
38Special Topics on Graph Algorithms
Lower Bound of c(Fi)
3. 2226 ii TcFc
Slice iiF
32.8284271222,:3 Lemma Recall ecGEe
connected makes
2 cell ain distancelongest with 6most at Adding
iF
39Special Topics on Graph Algorithms
Lower Bound of c(Fi)
3. 2226 ii TcFc
Slice iiT
rows bottom andupper in the edges addingby obtained is that Recall iT
edges additional theseRemove
40Special Topics on Graph Algorithms
Combining (1), (2) and (3)
4.
228
2211
i
ii
iOPTAPPX FcTcTcTc
?
228
OPT
OPTAPPX
TcTcTc
41Special Topics on Graph Algorithms
Upper Bound of c(TOPT)
• Consider 3×3 subgrid with nonempty center.• There are at least such subgrids.• It takes at least length 1 for the center to
connect to its boundary.
5.
9kf
19
kfTc OPT
42Special Topics on Graph Algorithms
Combining (4) and (5)
6.
1281
9 assuming 299
92928
kf
kf
kfTcTcTc
OPT
OPTAPPX
43Special Topics on Graph Algorithms
Open Questions, Further Research
• PTAS for geometric GMST with non-intersecting square clusters of variable sizes.
• Fast constant approximation algorithms for geometric GMST with grid clustering.– DP as a subroutine of PTAS is impractical.
44Special Topics on Graph Algorithms
THE ENDThanks
45Special Topics on Graph Algorithms