23
0

Sorting in One and Two Rounds using tt-Comparators

Abstract

We examine sorting algorithms for nn elements whose basic operation is comparing tt elements simultaneously (a tt-comparator). We focus on algorithms that use only a single round or two rounds -- comparisons performed in the second round depend on the outcomes of the first round comparators. We design deterministic and randomized algorithms. In the deterministic case, we show an interesting relation to design theory (namely, to 2-Steiner systems), which yields a single-round optimal algorithm for n=t2kn=t^{2^k} with any k1k\ge 1 and a variety of possible values of tt. For some values of tt, however, no algorithm can reach the optimal (information-theoretic) bound on the number of comparators. For this case (and any other nn and tt), we show an algorithm that uses at most three times as many comparators as the theoretical bound. We also design a randomized Las-Vegas two-rounds sorting algorithm for any nn and tt. Our algorithm uses an asymptotically optimal number of O(max(n3/2t2,nt))O(\max(\frac{n^{3/2}}{t^2},\frac{n}{t})) comparators, with high probability, i.e., with probability at least 11/n1-1/n. The analysis of this algorithm involves the gradual unveiling of randomness, using a novel technique which we coin the binary tree of deferred randomness.

View on arXiv
Comments on this paper