Weighted and unweighted selection algorithms for k sorted sequences

説明

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.

詳細情報 詳細情報について

問題の指摘

ページトップへ