Derivation of Randomized Sorting and Selection Algorithms
In this paper we systematically derive randomized algorithms (both sequential and parallel) for sorting and selection from basic principles and fundamental techniques like random sampling. We prove several sampling lemmas which will find independent applications. The new algorithms derived here are the most efficient known. From among other results, we have an efficient algorithm for sequential sorting.
The problem of sorting has attracted so much attention because of its vital importance. Sorting with as few comparisons as possible while keeping the storage size minimum is a long standing open problem. This problem is referred to as ‘the minimum storage sorting’  in the literature. The previously best known minimum storage sorting algorithm is due to Frazer and McKellar . The expected number of comparisons made by this algorithm is n log n + O(n log log n). The algorithm we derive in this paper makes only an expected n log n + O(n ω(n)) number of comparisons, for any function ω(n) that tends to infinity. A variant of this algorithm makes no more than n log n + O(n log log n) comparisons on any input of size n with overwhelming probability.
We also prove high probability bounds for several randomized algorithms for which only expected bounds have been proven so far.
KeywordsSorting Algorithm Overwhelming Probability Random Access Machine Parallel Random Access Machine Select Algorithm
Unable to display preview. Download preview PDF.
- A. Aho, J.E. Hopcroft, and J.D. Ullman, The Design and Analysis of Algorithms, Addison-Wesley Publications, 1976.Google Scholar
- M. Ajtai, J. Komlós, and E. Szemerédi, An O(n log n) Sorting Network, in Proc. ACM Symposium on Theory of Computing, 1983, pp. 1–9.Google Scholar
- H. Chernoff, A Measure of Asymptotic Efficiency for Tests of a Hypothesis Based on the Sum of Observations, Annals of Mathematical Statistics 23, 1952, pp. 493–507.Google Scholar
- R. Cole, An Optimally Efficient Selection Algorithm, Information Processing Letters 26, Jan. 1988, pp. 295–299.Google Scholar
- R. Cole and U. Vishkin, Approximate and Exact Parallel Scheduling with Applications to List, Tree, and Graph Problems, in Proc. IEEE Symposium on Foundations of Computer Science, 1986, pp. 478–491.Google Scholar
- C. Kaklamanis, D. Krizanc, L. Narayanan, and Th. Tsantilas, Randomized Sorting and Selection on Mesh Connected Processor Arrays, Proc. 3rd Annual ACM Symposium on Parallel Algorithms and Architectures, 1991.Google Scholar
- L. Kleinrock, Queueing Theory. Volume 1: Theory, John Wiley & Sons, 1975.Google Scholar
- D.E. Knuth, The Art of Computer Programming, vol. 3, Sorting and Searching, Addison-Wesley Publications, 1973.Google Scholar
- T. Leighton, Tight Bounds on the Complexity of Parallel Sorting, in Proc. ACM Symposium on Theory of Computing, 1984, pp. 71–80.Google Scholar
- F.P. Preparata, New Parallel Sorting Schemes, IEEE Transactions on Computers, vol. C27, no. 7, 1978, pp. 669–673.Google Scholar
- M.O. Rabin, Probabilistic Algorithms, in Algorithms and Complexity, New Directions and Recent Results, edited by J. Traub, Academic Press, 1976, pp. 21–36.Google Scholar
- S. Rajasekaran, k-k Routing, k-k Sorting, and Cut Through Routing on the Mesh, Technical Report MS-CIS-91-93, Department of CIS, University of Pennsylvania, October 1991. Also presented in the 4th Annual ACM Symposium on Parallel Algorithms and Architectures, 1992.Google Scholar
- S. Rajasekaran, Mesh Connected Computers with Fixed and Reconfigurable Buses: Packet Routing, Sorting, and Selection, Technical Report MS-CIS-92-56, Department of CIS, University of Pennsylvania, July 1992.Google Scholar
- S. Rajasekaran, Randomized Parallel Selection, Proc. Tenth Conference on Foundations of Software Technology and Theoretical Computer Science, Bangalore, India, 1990. Springer-Verlag Lecture Notes in Computer Science 472, pp. 215–224.Google Scholar
- S. Rajasekaran and D.S.L. Wei, Selection, Routing, and Sorting on the Star Graph, to appear in Proc. 7th International Parallel Processing Symposium, 1993.Google Scholar
- J.H. Reif and L.G. Valiant, A Logarithmic Time Sort for Linear Size Networks, in Proc. 15th Annual ACM Symposium on Theory of Computing, Boston, MASS., 1983, pp. 10–16.Google Scholar
- J.H. Reif, An n1+ε Processor O(log log n) Time Probabilistic Sorting Algorithm, in Proc. SIAM Symposium on the Applications of Discrete Mathematics, Cambridge, MASS., 1983, pp. 27–29.Google Scholar
- Y. Shiloach, and U. Vishkin, Finding the Maximum, Merging, and Sorting in a Parallel Computation Model, Journal of Algorithms 2, 1981, pp. 81–102.Google Scholar
- I. Wegener, Bottom-up-Heapsort, a New Variant of Heapsort Beating of Average Quicksort (if n is not very small), in Proc. Mathematical Foundations of Computer Science, Springer-Verlag Lecture Notes in Computer Science 452, 1990, pp. 516–522.Google Scholar