Faster Algorithms for Growing Prioritized Disks and Rectangles
Motivated by map labeling, Funke, Krumpe, and Storandt [IWOCA 2016] introduced the following problem: we are given a sequence of $n$ disks in the plane. Initially, all disks have radius $0$, and they grow at constant, but possibly different, speeds. Whenever two disks touch, the one with the higher index disappears. The goal is to determine the elimination order, i.e., the order in which the disks disappear. We provide the first general subquadratic algorithm for this problem. Our solution extends to other shapes (e.g., rectangles), and it works in any fixed dimension. We also describe an alternative algorithm that is based on quadtrees. Its running time is $O\big(n \big(\log n + \min { \log \Delta, \log \Phi }\big)\big)$, where $\Delta$ is the ratio of the fastest and the slowest growth rate and $\Phi$ is the ratio of the largest and the smallest distance between two disk centers. This improves the running times of previous algorithms by Funke, Krumpe, and Storandt [IWOCA 2016], Bahrdt et al. [ALENEX 2017], and Funke and Storandt [EuroCG 2017]. Finally, we give an $\Omega(n\log n)$ lower bound, showing that our quadtree algorithms are almost tight.
💡 Research Summary
The paper addresses a geometric problem motivated by map labeling: given a sequence of n disks (or more generally, axis‑aligned rectangles) in the plane, each starting with radius zero and growing at a constant but possibly distinct speed, whenever two objects touch the one with the higher index (i.e., lower priority) disappears. The task is to compute the exact elimination order and the time at which each object vanishes.
Basic Model and Prior Work
For any pair of objects i and j the theoretical meeting time is
t(i,j) = ‖p_i – p_j‖ / (v_i + v_j),
where p_i is the center and v_i the growth rate. The rule “the higher‑indexed object disappears” yields a deterministic elimination sequence. Earlier work by Funke, Krump e, and Storandt (IWOCA 2016) simulated the process with a priority queue in O(n² log n) time, and later refinements introduced parameters such as Δ = max v_i / min v_i (ratio of fastest to slowest growth) to obtain algorithms whose worst‑case running time still scales quadratically in n.
Quadratic Baseline
Section 2 presents a straightforward O(d n²) algorithm (Algorithm 1) that works in any fixed dimension d. It iterates over the objects in order of decreasing priority, and for each object i finds the earliest alive higher‑priority object j that would meet i, using the formula for t(i,j). This algorithm generalizes to any shape for which the meeting time can be computed in O(d) arithmetic operations.
Sub‑Quadratic Algorithm via Bucketing and Lower Envelopes
The core contribution is a sub‑quadratic algorithm that combines bucketing with a sophisticated data structure for vertical ray‑shooting in lower envelopes. The objects are partitioned into contiguous buckets of size m. For a bucket B, each object j ∈ B defines a three‑dimensional function
f_j(x, y, v) = t((x, y, v), j) if t((x, y, v), j) < t_j,
∞ otherwise,
where (x, y, v) encodes a query object’s center and growth rate. The lower envelope of the set {f_j | j ∈ B} captures, for any query, the first alive object in B that would collide with the query. Using the result of Agarwal et al. (2010) on lower envelopes of constant‑degree algebraic surfaces, the envelope can be pre‑processed in expected O(m^{3+ε}) time and space, allowing a query to be answered in O(log² m) time.
Processing proceeds as follows: after the elimination times of all objects in a bucket are known, its envelope structure is built. When determining the elimination time of a later object i, the algorithm queries the envelopes of all earlier buckets (O(n/m) queries) and scans the current bucket linearly (O(m) work). The total expected running time becomes
O(n m^{2+ε} + (n²/m) log² m + n m).
Choosing m = n^{1/3} balances the terms and yields an expected O(n^{5/3+ε}) time algorithm with O(n^{5/3+ε}) space for disks.
Extension to Growing Rectangles and General Semi‑Algebraic Shapes
For rectangles, each object is described by four parameters (two opposite corners), leading to a five‑dimensional function space. The authors employ the high‑dimensional point‑location structure of Chazelle and Koltun (2008) to handle vertical ray‑shooting in this setting. The preprocessing cost becomes O(m^{2d‑4+ε}) for d‑dimensional algebraic surfaces; with d = 5 and m = n^{1/3}, the overall expected time is O(n^{11/6+ε}). More generally, any fixed‑parameter semi‑algebraic shape described by k ≥ 4 parameters can be handled with the same framework, giving the first sub‑quadratic algorithms for a broad class of growing objects.
Quadtree‑Based Algorithms Parameterized by Δ and Φ
A second line of attack uses quadtrees. Let Φ be the spread of the point set (ratio of maximum to minimum inter‑center distance) and Δ the growth‑rate ratio. By recursively subdividing the plane, each quadtree cell stores the objects whose centers lie inside it, sorted by growth rate. For a query object, only objects in the same cell or neighboring cells can possibly be the first to collide, and the number of candidates is bounded by O(min{log Δ, log Φ}). Consequently, the algorithm runs in
O(n (log n + min{log Δ, log Φ}))
time and O(n) space. When Δ or Φ is polynomial in n, this is essentially linear.
Lower Bound and Near‑Optimality
The authors prove an Ω(n log n) lower bound by reduction from sorting, showing that any algorithm that determines the elimination order must at least sort the input in the worst case. Since the quadtree algorithm attains O(n log n) when Δ and Φ are constant, it is asymptotically optimal up to polylogarithmic factors.
Overall Contributions
- A simple O(d n²) baseline algorithm for any fixed dimension.
- The first sub‑quadratic expected‑time algorithms for growing disks (O(n^{5/3+ε})) and growing rectangles (O(n^{11/6+ε})).
- A general framework extending to any semi‑algebraic shape with a constant number of parameters.
- A quadtree‑based algorithm whose running time depends on the geometric spread Φ and growth‑rate ratio Δ, achieving near‑linear performance in many realistic scenarios.
- An Ω(n log n) lower bound establishing near‑optimality of the quadtree approach.
These results significantly improve upon prior work by Funke et al., Bahrdt et al., and Funke & Storandt, both in theoretical worst‑case bounds and in practical applicability to higher‑dimensional or more complex shapes. The combination of geometric data structures (lower envelopes, high‑dimensional point location, quadtrees) with careful parameterization demonstrates a powerful methodology for handling dynamic, priority‑driven collision problems in computational geometry.
Comments & Academic Discussion
Loading comments...
Leave a Comment