z-logo
open-access-imgOpen Access
Randomized Algorithm for the Sum Selection Problem
Author(s) -
Tien-Ching Lin,
D. T. Lee
Publication year - 2005
Publication title -
lecture notes in computer science
Language(s) - English
Resource type - Book series
SCImago Journal Rank - 0.249
H-Index - 400
eISSN - 1611-3349
pISSN - 0302-9743
DOI - 10.1007/11602613_52
Subject(s) - combinatorics , integer (computer science) , randomized algorithm , selection (genetic algorithm) , sequence (biology) , rank (graph theory) , mathematics , algorithm , subset sum problem , binary logarithm , discrete mathematics , computer science , knapsack problem , artificial intelligence , biology , genetics , programming language
Given a sequence of n real numbers A = a1, a2,..., an and a positive integer k, the Sum Selection Problem is to find the segment A( i,j)=ai, ai+1,..., aj such that the rank of the sum $s(i, j) = \sum_{t = i}^{j}{a_{t}}$ is k over all ${n(n-1)} \over {2}$ segments. We will give a randomized algorithm for this problem that runs in expected O(n log n) time. Applying this algorithm we can obtain an algorithm for the kMaximum Sums Problem, i.e., the problem of enumerating the k largest sum segments, that runs in expected O(n log n + k) time. The previously best known algorithm for the kMaximum Sums Problem runs in O(n log2n + k) time in the worst case.

The content you want is available to Zendy users.

Already have an account? Click here to sign in.
Having issues? You can contact us here
Accelerating Research

Address

John Eccles House
Robert Robinson Avenue,
Oxford Science Park, Oxford
OX4 4GP, United Kingdom