Klees Measure Problem Made Easy Timothy Chan U of Waterloo & HKUST.
-
Upload
scarlett-isaacs -
Category
Documents
-
view
215 -
download
0
Transcript of Klees Measure Problem Made Easy Timothy Chan U of Waterloo & HKUST.
Klee’s Measure Problem Made Easy
Timothy ChanU of Waterloo & HKUST
Beginning of Story…
• Victor Klee, “Can the measure of U1n [ai,bi] be
computed in less than O(n log n) steps?”, Amer. Math. Monthly, 84:284-285, 1977
The Problem
• Given n rectangular boxes in d dimensions, compute the measure of the union
Known Result in 2D
• Union may have Ω(n2) boundary edges
• Bentley'77: O(n log n) time
Bentley’s Algorithm in 2D
• Idea: sweep!
dynamic data structure problem in 1D
Known Results in d ≥ 3 Dimensions
• Union may have Ω(nd) boundary faces
• Bentley'77: O(nd-1 log n) time• Van Leeuwen,Wood'81: O(nd-1) time
• Overmars,Yap [FOCS'88]: O(nd/2 log n) time• C.'08: O(nd/2 loglog n)
time
Known Results in d ≥ 3 Dimensions
• Union may have Ω(nd) boundary faces
• Bentley'77: O(nd-1 log n) time• Van Leeuwen,Wood'81: O(nd-1) time
• Overmars,Yap [FOCS'88]: O(nd/2 log n) time• C.'08: O(nd/2 logloglog n)
Known Results in d ≥ 3 Dimensions
• Union may have Ω(nd) boundary faces
• Bentley'77: O(nd-1 log n) time• Van Leeuwen,Wood'81: O(nd-1) time
• Overmars,Yap [FOCS'88]: O(nd/2 log n) time• C.'08: O(nd/2 loglogloglog
n)
Known Results in d ≥ 3 Dimensions
• Union may have Ω(nd) boundary faces
• Bentley'77: O(nd-1 log n) time• Van Leeuwen,Wood'81: O(nd-1) time
• Overmars,Yap [FOCS'88]: O(nd/2 log n) time• C.'08: O(nd/2 2O(log*n)) time• Today: O(nd/2) time
New Algorithm: Warm-Up in 2D
• Idea: good old divide&conquer!
New Algorithm in 2D: First Attempt
• Given set B of n rectangles inside cell C:
1. divide C into Cleft & Cright
2. recurse inside Cleft & inside Cright
New Algorithm in 2D: How to Divide?
• … by median-x
• Problem: “bad” rectangles!
C
Cleft Cright
New Algorithm in 2D
• Given set B of n rectangles inside cell C: 0. simplify B new twist!
1. divide C into Cleft & Cright
2. recurse inside Cleft & inside Cright
New Algorithm in 2D: How to Simplify?
• … by removing all “bad” rectangles that don't have vertices inside C
New Algorithm in 2D: Summary & Analysis
• Given set B of n rectangles inside cell C: 0. simplify B
… by removing all “bad” rectangles that don't have vertices inside C
1. divide C into Cleft & Cright
… by median-x
2. recurse inside Cleft & inside Cright
• Let N = # vertices inside C
T(N) = 2 T(N/2) + O(N) O(N log N)
Extending New Algorithm to 3D
• Given set B of n boxes inside cell C: 0. simplify B
… by removing all “bad” boxes that don't have edges intersecting C
1. divide C into Cleft & Cright
… by weighted median-x
2. recurse inside Cleft & inside Cright
New Algorithm in 3D: How to Simplify?
• … by removing all “bad” boxes that don't have edges intersecting C
New Algorithm in 3D:How to Divide?
• … by weighted median-xx
y
z
New Algorithm in 3D:How to Divide?
• … by weighted median-x
• Define weight of an edge:
• Total weight of edges intersecting Cleft (or Cright) =
… after factoring out 2-2/3
x
y
z
1 21/322/3
1 21/3 /2 22/3 /22-2/3 2-1/322/321/31
New Algorithm in 3D: Analysis
• Let N = total weight of edges intersecting C
Nleft, Nright ≤ 2-2/3 N after renaming axes
T(N) = 2 T(N / 22/3) + O(N) O(N3/2)
Extending New Algorithm to d Dimensions
• Define weight of a (d-2)-dimensional face f= 2(i+j)/d if f is orthogonal to axis i & j
T(N) = 2 T(N / 22/d) + O(N) O(Nd/2)
FINAL REMARKS
Other Applications
• Cover problem: given n boxes in d dimensions, does their union completely cover C?
• Depth problem: given n boxes in d dimensions, find a point q minimizing # of boxes containing q
• Weighted depth problem: given n weighted boxes in d dimensions, find a point q minimizing total weight of boxes containing q
• Etc.
Lower Bounds?
• C'08: Finding cliques of size d in a graph with V=n1/2 vertices reduces to the cover/depth/ measure problem
hard to beat O(Vd) = O(nd/2) time (ignoring log factors) by “purely combinatorial”
algorithms
• Open question: can matrix multiplication help??
Log Factor Speedups
• Cover/depth problem: O**(nd/2 / logd/2 n)by table lookup
• Weighted depth problem: O**(nd/2 / logd/2 - 5 n) by linear decision trees [Meyer auf der
Heide’84,Meiser’93]
• Measure problem: O**(nd/2 / logd/2 - 2 n) by Chinese remainder theorem for integer
input
• Open question: speedup for measure problem for real input?
Special Case: Hypercubes (or “Fat” Boxes)
• Union may have Ω(nd/2) boundary faces
• Agarwal,Kaplan,Sharir'07: O(n4/3 log2 n) time (d=3)
• Agarwal'10: O(n log4 n) time (d=3)
• Bringman'10: O(n(d+2)/3) • New: O(n(d+1)/3 polylog
n)by more complicated additional ideas…
• Open question: faster algorithms for hypercubes?