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≤i≤n, 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.
Similar content being viewed by others
References
Chung, K.-M., Lu, H.-I.: An optimal algorithm for the maximum-density segment problem. SIAM J. Comput. 34(2), 373–387 (2004)
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)
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)
Huang, X.: An algorithm for identifying regions of a DNA sequence that satisfy a content requirement. Comput. Appl. Biosci. 10(3), 219–225 (1994)
Kim, S.K.: Linear-time algorithm for finding a maximum-density segment of a sequence. Inf. Process. Lett. 86(6), 339–342 (2003)
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)
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)
Nekrutenko, A., Li, W.-H.: Assessment of compositional heterogeneity within and between eularyotic genomes. Genome Res. 10, 1986–1995 (2000)
Rice, P., Longden, I., Bleasby, A.: Emboss: the European molecular biology open software suite. Trends Genet. 16, 276–277 (2000)
Ioshikhes, I.P., Zhang, M.Q.: Large-scale human promoter mapping using CpG islands. Gene, Nat. Genet. 26, 61–63 (2000)
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)
Ben-Or, M.: Lower bounds for algebraic computation trees. In: Proc. 15th Annu. ACM Sympos. Theory Comput., pp. 80–86 (1983)
Cormen, T.H., Leiserson, C.E., Rivest, R.L.: Introduction to Algorithms, MIT Press
Graham, R.L.: An efficient algorithm for determining the convex hull of a finite planar set. Inf. Process. Lett. 1, 132–133 (1972)
Author information
Authors and Affiliations
Corresponding author
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
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
Received:
Accepted:
Published:
Issue Date:
DOI: https://doi.org/10.1007/s00453-007-9023-8