Towards Optimal Range Medians
Beat Gfeller, Peter Sanders

TL;DR
This paper introduces an efficient algorithm for computing medians in multiple subarray intervals, improving upon previous methods and extending naturally to higher-dimensional problems through range counting queries.
Contribution
The paper presents a simple, space-efficient algorithm that improves query time for range median problems and generalizes to higher dimensions by reducing to range counting queries.
Findings
Achieves $O(n ext{ log }k + k ext{ log }n)$ query time, improving previous algorithms.
Matches the lower bound for $k=O(n)$, indicating optimality.
Generalizes to higher-dimensional problems via range counting queries.
Abstract
We consider the following problem: given an unsorted array of elements, and a sequence of intervals in the array, compute the median in each of the subarrays defined by the intervals. We describe a simple algorithm which uses O(n) space and needs time to answer the first queries. This improves previous algorithms by a logarithmic factor and matches a lower bound for . Since the algorithm decomposes the range of element values rather than the array, it has natural generalizations to higher dimensional problems -- it reduces a range median query to a logarithmic number of range counting queries.
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
Taxonomy
TopicsVideo Surveillance and Tracking Methods · Data Management and Algorithms · Advanced Data Compression Techniques
