Homework 3

advertisement
Advanced Topics in Computational and Combinatorial Geometry
Assignment 3 (short answers and hints)
Problem 1
a) There are 𝑂(𝑛2 ) faces in the arrangement of the lines. Each triple of faces generate
a different 𝐿Δ . Thus there are in total: 𝑂(𝑛6 ).
b) Hint: Use induction. Assume for n lines. Given 𝑛 + 1 lines, take one line out and then
return it. Bound the number of triangles added after you return the line.
c) Use the Clarkson-Shor’s technique.
Problem 2
Observation: if there is an interval I of length k that does not contain any point of R, then
there is an interval I’ of length k/2 starting at position that is multiple of k/2 (there are 2n/k
such intervals). Thus it is enough to show upper bound on the probability that at least one of
the 2n/k intervals of length k/2 does not contain a point of R.
P(there is an interval of length k at any position) ≤
≤ P(there is one of the 2n/k intervals of length k/2 at fixed positions) ≤
≤ 2n/k P(there is an interval of length k/2 at fixed position) ≤
𝑘
≤
2𝑛
𝑟 2
(1 − )
𝑘
𝑛
𝑛𝑟𝑘
=
Substitute 𝑘 =
2𝑛
(1
𝑘
𝑟 𝑟𝑛2
𝑛
− )
≤
2𝑛 − 𝑟𝑘
𝑒 2𝑛
𝑘
𝑐𝑛
log 𝑟.
𝑟
Problem 3
Very similar to the construction and proof we used in class. The main difference is that there
is no need for the union-find data structure and that the DAG is simpler.
Problem 4
a) Use the DAG. Just like in class.
b) Cost of the query is proportional to number of visited nodes in the DAG.
Denote:
-
Xt, i = trapezoid t appears in cell’s decomposition after adding i arcs
T(q) = set of all possible trapezoids containing q
Let’s compute the probability that trapezoid is changed after adding the i’th arc (we sum
probabilities of each possible trapezoid containing q to appear after adding the i’th arc):
∑ 𝑃(𝑋𝑡,𝑖 ∩ 𝑋̅𝑡,𝑖−1 ) = ∑ 𝑃(𝑋̅𝑡,𝑖−1|𝑋𝑡,𝑖 )𝑃(𝑋𝑡,𝑖 ) ≤ ∑
𝑡∈𝑇(𝑞)
𝑡∈𝑇(𝑞)
𝑡∈𝑇(𝑞)
4
4
𝑃(𝑋𝑡,𝑖 ) = ∑ 𝑃(𝑋𝑡,𝑖 )
𝑖
𝑖
𝑡∈𝑇(𝑞)
4
≤
𝑖
because for every insertion order there is at most one trapezoid containing q.
4
Expected total number of different trapezoids is: ∑𝑛𝑖=1 𝑖 = 𝑂(log 𝑛).
c) Same as in class.
Problem 5
a) Triangulate the polygon. Take the Minkowski sum of each triangle with the unit disk.
Then unite the structures you get. Since these structures are pseudo-disks we
conclude that the complexity of their union is 𝑂(𝑛).
b) We’ve shown in class how to compute the union of n pseudo-disks in O(n log2 n)
time. As in (a), and as shown in 4(c) of the previous assignment, the Minkowski
sums are pseudo-disks. In this case, though, we have m pseudo-disks with a total
complexity of n+mk (denote N = n+mk). It’s easy to see that the “conquer” step will
run now in O(N log N) time. And the whole algorithm in O(N log N log m) time.
Download