Synthesis of fast programs for maximum segment sum problems
نویسندگان
چکیده
منابع مشابه
Maximum Segment Sum, Monadically (distilled tutorial)
The maximum segment sum problem is to compute, given a list of integers, the largest of the sums of the contiguous segments of that list. This problem specification maps directly onto a cubic-time algorithm; however, there is a very elegant linear-time solution too. The problem is a classic exercise in the mathematics of program construction, illustrating important principles such as calculatio...
متن کاملEfficient Algorithms for the Maximum Sum Problems
We present efficient sequential and parallel algorithms for the maximum sum (MS) problem, which is to maximize the sum of some shape in the data array. We deal with two MS problems; the maximum subarray (MSA) problem and the maximum convex sum (MCS) problem. In the MSA problem, we find a rectangular part within the given data array that maximizes the sum in it. The MCS problem is to find a conv...
متن کاملAlgorithms for Problems on Maximum Density Segment
Let A be a sequence of n ordered pairs of real numbers (ai, li) (i = 1, . . . , n) with li > 0, and L and U be two positive real numbers with 0 < L U . A segment, denoted by A[i, j], 1 i j n, of A is a consecutive subsequence of A between the indices i and j (i and j included). The length l[i, j], sum s[i, j] and density d[i, j] of a segment A[i, j] are l[i, j] = ∑j t=i lt, s[i, j] = ∑j t=i at ...
متن کاملOptimal algorithms for the average-constrained maximum-sum segment problem
a r t i c l e i n f o a b s t r a c t Given a real number sequence A = (a 1 , a 2 ,. .. ,a n), an average lower bound L, and an average upper bound U , the Average-Constrained Maximum-Sum Segment problem is to locate a segment A(i, j) = (a i , a i+1 ,. .. ,a j) that maximizes ik j a k subject to L (ik j a k)/(j − i + 1) U. In this paper, we give an O (n)-time algorithm for the case where the av...
متن کاملParallel Programming, List Homomorphisms and the Maximum Segment Sum Problem
We review the use of the Bird-Meertens Formalism as a vehicle for the construction of programs with massive implicit parallelism. We show that a simple result from the theory, concerning the expression of list homomorph-isms, can help us in our search for parallel algorithms and demonstrate its application to some simple problems including the maximum segment sum problem. Our main purpose is to...
متن کاملذخیره در منابع من
با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید
ژورنال
عنوان ژورنال: ACM SIGPLAN Notices
سال: 2010
ISSN: 0362-1340,1558-1160
DOI: 10.1145/1837852.1621626