Sorting in linear time?

被引:66
作者
Andersson, A
Hagerup, T
Nilsson, S
Raman, R
机构
[1] Goethe Univ Frankfurt, Fachbereich Informat, D-60054 Frankfurt, Germany
[2] Lund Univ, Dept Comp Sci, S-22100 Lund, Sweden
[3] Aalto Univ, Dept Comp Sci, FIN-02150 Espoo, Finland
[4] Kings Coll London, Dept Comp Sci, London WC2R 2LS, England
[5] Max Planck Inst Informat, Saarbrucken, Germany
关键词
D O I
10.1006/jcss.1998.1580
中图分类号
TP3 [计算技术、计算机技术];
学科分类号
0812 ;
摘要
We show that a unit-cost RAM with a word length of w bits can sort n integers in the range 0 ... 2(w)-1 in O(n log log n) time for arbitrary w greater than or equal to log n, a significant improvement over the bound of O(n root log n) achieved by the fusion trees of Fredman and Willard. Provided that w greater than or equal to (log n)(2+epsilon) for some fixed epsilon> 0. the sorting can even be accomplished in linear expected time with a randomized algorithm. Both of our algorithms parallelize without loss on a unit-cost PRAM with a word length of w bits. The first one yields an algorithm that uses O(log n) time and O(n log log n) operations on a deterministic CRCW PRAM. The second one yields an algorithm that uses O(log n) expected time and O(n) expected operations on a randomized EREW PRAM, provided that w greater than or equal to (log n)(2+epsilon) for some fixed epsilon > 0. Our deterministic and randomized sequential and parallel algorithms generalize to the lexicographic sorting of multiple-precision integers represented in several words. (C) 1998 Academic Press.
引用
收藏
页码:74 / 93
页数:20
相关论文
共 36 条
[1]  
Ajtai Miklos, 1983, P 15 ANN ACM S THEOR, P1, DOI DOI 10.1145/800061.808726
[2]   Improved parallel integer sorting without concurrent writing [J].
Albers, S ;
Hagerup, T .
INFORMATION AND COMPUTATION, 1997, 136 (01) :25-51
[3]  
ANDERSON RJ, 1988, LECT NOTES COMPUT SC, V319, P81
[4]   Faster deterministic sorting and searching in linear space [J].
Andersson, A .
37TH ANNUAL SYMPOSIUM ON FOUNDATIONS OF COMPUTER SCIENCE, PROCEEDINGS, 1996, :135-141
[5]  
Andersson A., 1994, Proceedings. 35th Annual Symposium on Foundations of Computer Science (Cat. No.94CH35717), P714, DOI 10.1109/SFCS.1994.365721
[6]  
[Anonymous], COMPUTER ORG DESIGN
[7]  
BAST H, 1991, P 3 ANN ACM S PAR AL, P50
[8]   OPTIMAL BOUNDS FOR DECISION-PROBLEMS ON THE CRCW PRAM [J].
BEAME, P ;
HASTAD, J .
JOURNAL OF THE ACM, 1989, 36 (03) :643-670
[9]  
Ben-Amram A. M., 1993, Proceedings. 34th Annual Symposium on Foundations of Computer Science (Cat. No.93CH3368-8), P538, DOI 10.1109/SFCS.1993.366833
[10]   IMPROVED DETERMINISTIC PARALLEL INTEGER SORTING [J].
BHATT, PCP ;
DIKS, K ;
HAGERUP, T ;
PRASAD, VC ;
RADZIK, T ;
SAXENA, S .
INFORMATION AND COMPUTATION, 1991, 94 (01) :29-47