Communications of the ACM
A Sorting Algorithm for Polynomial Multiplication
Journal of the ACM (JACM)
Codes: Unequal Probabilities, Unequal Letter Cost
Journal of the ACM (JACM)
A new representation for linear lists
STOC '77 Proceedings of the ninth annual ACM symposium on Theory of computing
Assembling approximately optimal binary search trees efficiently using arithmetics
Information Processing Letters
Efficient decision tree re-alignment for clustering time-changing data streams
From active data management to event-based systems and more
Hi-index | 0.00 |
Let X &equil; {x1,...,xN} and Y &equil; {y1,...,yN} be sets of N real numbers. We denote by X + Y the multiset {xi + yj; 1 ≤ i, j ≤ N} of size N2. Berklekamp has posed the problem of sorting X + Y. Harper, Payne, Savage and Strauss [1] show that N21og2N comparisons suffice to sort X + Y, thereby saving a factor of 2 over sorting without exploiting the structure of X + Y. (Given u in X + Y, we assume that we know the i,j indices such that u &equil; xi + yj.) Furthermore, they show that this bound is tight for a restricted class of comparison algorithms. However, without their restriction the order of magnitude comparison complexity of this problem has remained an open question. In this paper we show that X + Y can be sorted with O(N2) comparisons. Our proof is unusual for this type of problem in that we do not explicitly exhibit an algorithm. Instead, it is a particular application of a more general search technique whose behavior is easily related to information theoretic lower bounds. In the context of sorting, this search method translates into an insertion sort, where the insertions are not performed by means of the usual binary search, but rather as off-centered searches designed so that each comparison, roughly speaking, equally divides the space of remaining possibilities. We draw attention to this search technique because it might find application to other problems, and we illustrate this possibility with a second application. Our second application concerns the construction of probabilistically balanced binary search trees.