Skip to main content

Improved Algorithms for the K-Maximum Subarray Problem for Small K

  • Conference paper
Computing and Combinatorics (COCOON 2005)

Part of the book series: Lecture Notes in Computer Science ((LNTCS,volume 3595))

Included in the following conference series:

Abstract

The maximum subarray problem for a one- or two-dimensional array is to find the array portion that maiximizes the sum of array elements in it. The K-maximum subarray problem is to find the K subarrays with largest sums. We improve the time complexity for the one-dimensional case from \(O(min\{K+n\log^2 n, n\sqrt{K}\})\) for 0 ≤ Kn(n–1)/2 to O(nlog K + K 2) for Kn. The latter is better when \(K \le \sqrt n\log n\). If we simply extend this result to the two-dimensional case, we will have the complexity of O(n 3log K + K 2 n 2). We improve this complexity to O(n 3) for \(K \le \sqrt{n}\).

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 84.99
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 109.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. Bae, S.E., Takaoka, T.: Parallel approaches to the maximum subarray problem. In: Japan-Korea Workshop on Al. and Comp., pp. 94–104 (2003)

    Google Scholar 

  2. Bae, S.E., Takaoka, T.: Algorithms for the problem of K maximum sums and a VLSI algorithm for the K maximum subarrays problem. In: ISPAN 2004, pp. 247–253 (2004)

    Google Scholar 

  3. Bengtsson, F., Chen, J.: Efficient algorithms for the k maximum sums. In: Fleischer, R., Trippen, G. (eds.) ISAAC 2004. LNCS, vol. 3341, pp. 137–148. Springer, Heidelberg (2004)

    Chapter  Google Scholar 

  4. Bentley, J.: Programming pearls: algorithm design techniques. Commun. ACM 27(9), 865–873 (1984)

    Article  MathSciNet  Google Scholar 

  5. Bentley, J.: Programming pearls: perspective on performance. Commun. ACM 27(11), 1087–1092 (1984)

    Article  Google Scholar 

  6. Brodal, G.S.: Finger search trees with constant insertion time. In: SODA, pp. 540–549 (1998)

    Google Scholar 

  7. Brown, M.R., Tarjan, R.E.: The design and analysis of a data structure for representing sorted lists. SIAM Jour. on Comp. 9(3), 594–614 (1980)

    Article  MathSciNet  MATH  Google Scholar 

  8. Csürös, M.: Algorithms for finding maxima-scoring segment sets. In: Jonassen, I., Kim, J. (eds.) WABI 2004. LNCS (LNBI), vol. 3240, pp. 62–73. Springer, Heidelberg (2004)

    Chapter  Google Scholar 

  9. Dietz, P.F., Raman, R.: A constant update time finger search tree. Inf. Process. Lett. 52(3), 147–154 (1994)

    Article  MATH  Google Scholar 

  10. Miller, R., Boxer, L.: Algorithms Sequential & Parallel- A Unified Approach. Prentice-Hall, Englewood Cliffs (2000)

    Google Scholar 

  11. Perumalla, K., Deo, N.: Parallel algorithms for maximum subsequence and maximum subarray. Parallel Process. Lett. 5(3), 367–373 (1995)

    Article  Google Scholar 

  12. Qui, K., Akl, S.G.: Parallel maximum sum algorithms on intercommenction networks. Queen’s Uni. Dept. of Com. and Info. Sci. Technical Report 99-431 (1999)

    Google Scholar 

  13. Ruzzo, W.L., Tompa, M.: A linear time algorithm for finding all maximal scoring subsequences. In: Intelligent Sys. in Molecular Biology, pp. 234–241 (1999)

    Google Scholar 

  14. Takaoka, T.: A new upper bound on the complexity of the all pairs shortest paths problem. Inf. Process. Lett. 43(4), 195–199 (1992)

    Article  MathSciNet  MATH  Google Scholar 

  15. Takaoka, T.: Efficient algorithms for the maximum subarray problem by distance matrix multiplication. Elec. Notes in Theoretical Computer Sci., vol. 61. Elsevier, Amsterdam (2002)

    Google Scholar 

  16. Takaoka, T.: A faster algorithm for the all-pairs shortest path problem and its application. In: Roth-Berghofer, T.R., Göker, M.H., Güvenir, H.A. (eds.) ECCBR 2006. LNCS (LNAI), vol. 4106, pp. 278–289. Springer, Heidelberg (2006)

    Google Scholar 

  17. Tamaki, H., Tokuyama, T.: Algorithms for the maximum subarray problem based on matrix multiplication. In: SODA, pp. 446–452 (1998)

    Google Scholar 

  18. Wen, Z.: Fast parallel algorithms for the maximum sum problem. Parallel Computing 21(3), 461–466 (1995)

    Article  MathSciNet  MATH  Google Scholar 

  19. Zwick, U.: A slightly improved sub-cubic algorithm for the all pairs shortest paths problem with real edge lengths. In: Fleischer, R., Trippen, G. (eds.) ISAAC 2004. LNCS, vol. 3341, pp. 921–932. Springer, Heidelberg (2004)

    Chapter  Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2005 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Bae, S.E., Takaoka, T. (2005). Improved Algorithms for the K-Maximum Subarray Problem for Small K . In: Wang, L. (eds) Computing and Combinatorics. COCOON 2005. Lecture Notes in Computer Science, vol 3595. Springer, Berlin, Heidelberg. https://doi.org/10.1007/11533719_63

Download citation

  • DOI: https://doi.org/10.1007/11533719_63

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-540-28061-3

  • Online ISBN: 978-3-540-31806-4

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics