Skip to main content
Log in

Fast Algorithms for the Density Finding Problem

  • Published:
Algorithmica Aims and scope Submit manuscript

Abstract

We study the problem of finding a specific density subsequence of a sequence arising from the analysis of biomolecular sequences. Given a sequence A=(a 1,w 1),(a 2,w 2),…,(a n ,w n ) of n ordered pairs (a i ,w i ) of numbers a i and width w i >0 for each 1≤in, two nonnegative numbers , u with u and a number δ, the Density Finding Problem is to find the consecutive subsequence A(i *,j *) over all O(n 2) consecutive subsequences A(i,j) with width constraint satisfying w(i,j)=∑ j r=i w r u such that its density \(d(i^{*},j^{*})=\sum_{r=i^{*}}^{j*}a_{r}/w(i^{*},j^{*})\) is closest to δ. The extensively studied Maximum-Density Segment Problem is a special case of the Density Finding Problem with δ=∞. We show that the Density Finding Problem has a lower bound Ω(nlog n) in the algebraic decision tree model of computation. We give an algorithm for the Density Finding Problem that runs in optimal O(nlog n) time and O(nlog n) space for the case when there is no upper bound on the width of the sequence, i.e., u=w(1,n). For the general case, we give an algorithm that runs in O(nlog 2 m) time and O(n+mlog m) space, where \(m=\min\{\lfloor\frac{u-\ell}{w_{\mathrm{min}}}\rfloor,n\}\) and w min=min  n r=1 w r . As a byproduct, we give another O(n) time and space algorithm for the Maximum-Density Segment Problem.

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

Access this article

Price excludes VAT (USA)
Tax calculation will be finalised during checkout.

Instant access to the full article PDF.

Institutional subscriptions

Similar content being viewed by others

References

  1. Chung, K.-M., Lu, H.-I.: An optimal algorithm for the maximum-density segment problem. SIAM J. Comput. 34(2), 373–387 (2004)

    Article  MATH  MathSciNet  Google Scholar 

  2. Goldwasser, M.H., Kao, M.-Y., Lu, H.-I.: Fast algorithms for finding maximum-density segments of a sequence with applications to bioinformatics. In: Guigó, R., Gusfield, D. (eds.) Proceedings of the Second International Workshop of Algorithms in Bioinformatics, Rome, Italy, 2002. Lecture Notes in Computer Science, vol. 2452, pp. 157–171. Springer, New York (2002)

    Google Scholar 

  3. Goldwasser, M.H., Kao, M.-Y., Lu, H.-I.: Linear-time algorithms for computing maximum-density sequence segments with bioinformatics applications. J. Comput. Syst. Sci. 70(2), 128–144 (2005)

    Article  MATH  MathSciNet  Google Scholar 

  4. Huang, X.: An algorithm for identifying regions of a DNA sequence that satisfy a content requirement. Comput. Appl. Biosci. 10(3), 219–225 (1994)

    Google Scholar 

  5. Kim, S.K.: Linear-time algorithm for finding a maximum-density segment of a sequence. Inf. Process. Lett. 86(6), 339–342 (2003)

    Article  Google Scholar 

  6. Lin, Y.-L., Jiang, T., Chao, K.-M.: Algorithms for locating the length-constrained heaviest segments, with applications to biomolecular sequence analysis. J. Comput. Syst. Sci. 65(3), 570–586 (2002)

    Article  MATH  MathSciNet  Google Scholar 

  7. Lin, Y.-L., Huang, X., Jiang, T., Chao, K.-M.: MAVG: locating non-overlapping maximum average segments in a given sequence. Bioinformatics 19(1), 151–152 (2003)

    Article  Google Scholar 

  8. Nekrutenko, A., Li, W.-H.: Assessment of compositional heterogeneity within and between eularyotic genomes. Genome Res. 10, 1986–1995 (2000)

    Article  Google Scholar 

  9. Rice, P., Longden, I., Bleasby, A.: Emboss: the European molecular biology open software suite. Trends Genet. 16, 276–277 (2000)

    Article  Google Scholar 

  10. Ioshikhes, I.P., Zhang, M.Q.: Large-scale human promoter mapping using CpG islands. Gene, Nat. Genet. 26, 61–63 (2000)

    Google Scholar 

  11. Ohler, U., Niemann, H., Liao, G., Rubin, G.M.: Joint modeling of DNA sequence and physical properties to improve eukaryotic promoter recognition. Gene, Bioinf. 17(Suppl 1), S199–S206 (2001)

    Google Scholar 

  12. Ben-Or, M.: Lower bounds for algebraic computation trees. In: Proc. 15th Annu. ACM Sympos. Theory Comput., pp. 80–86 (1983)

  13. Cormen, T.H., Leiserson, C.E., Rivest, R.L.: Introduction to Algorithms, MIT Press

  14. Graham, R.L.: An efficient algorithm for determining the convex hull of a finite planar set. Inf. Process. Lett. 1, 132–133 (1972)

    Article  MATH  Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Tien-Ching Lin.

Additional information

Grants NSC95-2221-E-001-016-MY3, NSC-94-2422-H-001-0001, and NSC-95-2752-E-002-005-PAE, and by the Taiwan Information Security Center (TWISC) under the Grants NSC NSC95-2218-E-001-001, NSC95-3114-P-001-002-Y, NSC94-3114-P-001-003-Y and NSC 94-3114-P-011-001.

Rights and permissions

Reprints and permissions

About this article

Cite this article

Lee, D.T., Lin, TC. & Lu, HI. Fast Algorithms for the Density Finding Problem. Algorithmica 53, 298–313 (2009). https://doi.org/10.1007/s00453-007-9023-8

Download citation

  • Received:

  • Accepted:

  • Published:

  • Issue Date:

  • DOI: https://doi.org/10.1007/s00453-007-9023-8

Keywords

Navigation