Abstract
A classic problem in computer science involves selecting the m-th smallest item in a set A of n items. The more general weighted selection problem is defined similarly: having assigned non-negative weights to the items of A, return the largest item a in A for which the total weight of the items smaller than or equal to a does not exceed m. Our first main contribution is to provide a novel EREW algorithm for weighted selection, running in O(log n log* n) time with optimal work. Our second main contribution is to propose lower bounds and matching upper bounds for selection and weighted selection in a collection A of k, (1 ≤ k ≤ n), sorted sequences of combined length n. While ,Ω(n) remains a lower bound on the amount of work needed for weighted selection , unweighted selection has a lower bound of Ω(klog ⊋). We go on to propose an optimal sequential algorithm for selection in k sorted sequences running in O(k log ⊋) time, as well as a work-optimal EREW algorithm running in O(log k(log* k +log ⊋)) time. Finally, we present a work-time optimal EREW algorithm solving the weighted selection problem in k sorted sequences, running in O(log n) time whenever k ≤ /nlogO(1)) n.
Work supported in part by NSF grant CCR-9522093, by ONR grant N00014-97-1-0526, and by a grant from the Hori Information Science Promotion Foundation.
Preview
Unable to display preview. Download preview PDF.
Similar content being viewed by others
References
S. G. Akl. An optimal algorithm for parallel selection. Information Processing Letters, 19(1):47–50, July.
M. Blum, R.W. Floyd, V.R. Pratt, R.L. Rivest, and R.E. Tarjan, Time bounds for selection. Journal of Computer and System Sciences, (7):448–461, 1973.
D. Z. Chen, W. Chen, K. Wada, and K. Kawaguchi. Parallel algorithms for partitioning sorted sets and related probles. In Proc. 4th European Symposium on Algorithms (ESA'96, LNCS 1186), pages 234–245, 1996.
R. Cole. An optimally efficient selection algorithm. Information Processing Letters, 26:295–299, January 1987.
R. Cole, Parallel merge sort. SIAM Journal on Computing, 17:770–785, 1988.
G. N. Frederickson and D. B. Johnson, Generalized selection and ranking: sorted matrices, SIAM Journal on Computing, 13:14–30, 1984.
J. JáJá. An Introduction to Parallel Algorithms. Addison-Wesley, Reading, MA, 1992.
H. Shen, Generalized parallel selection in sorted matrices, Proc. Eight IEEE Symposium on Parallel and Distributed Systems, October 1996, 281–285.
U. Vishkin. An optimal parallel algorithm for selection. In Advances in Computing Research. JAI Press Inc., Greenwich CT, 1987.
Author information
Authors and Affiliations
Editor information
Rights and permissions
Copyright information
© 1997 Springer-Verlag Berlin Heidelberg
About this paper
Cite this paper
Hayashi, T., Nakano, K., Olariu, S. (1997). Weighted and unweighted selection algorithms for k sorted sequences. In: Leong, H.W., Imai, H., Jain, S. (eds) Algorithms and Computation. ISAAC 1997. Lecture Notes in Computer Science, vol 1350. Springer, Berlin, Heidelberg. https://doi.org/10.1007/3-540-63890-3_7
Download citation
DOI: https://doi.org/10.1007/3-540-63890-3_7
Published:
Publisher Name: Springer, Berlin, Heidelberg
Print ISBN: 978-3-540-63890-2
Online ISBN: 978-3-540-69662-9
eBook Packages: Springer Book Archive