Abstract
The Longest Common Subsequence (LCS) of two or more strings is a fundamental well-studied problem which has a wide range of applications throughout computational sciences. When the common subsequence must contain one or more constraint strings as subsequences, the problem becomes the Constrained LCS (CLCS) problem. In this paper we consider the Restricted LCS (RLCS) problem, where our goal is finding a longest common subsequence between two or more strings that does not contain a given set of restriction strings as subsequences. First we show that in case of two input strings and an arbitrary number of restriction strings the RLCS problem is NP-hard. Afterwards, we present a dynamic programming solution for RLCS and we show that this algorithm implies that RLCS is in FPT when parameterized by the total length of the restriction strings. In the last part of this paper we present two approximation algorithms for the hard variants of the problem.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Preview
Unable to display preview. Download preview PDF.
References
Aho, A.V., Hirschberg, D.S., Ullman, J.D.: Bounds on the Complexity of the Longest Common Subsequence Problem. Journal of the ACM 23(1), 1–12 (1976)
Amir, A., Hartman, T., Kapah, O., Shalom, B.R., Tsur, D.: Generalized LCS. In: Ziviani, N., Baeza-Yates, R. (eds.) SPIRE 2007. LNCS, vol. 4726, pp. 50–61. Springer, Heidelberg (2007)
Andrejkova, G.: The Longest Restricted Common Subsequence Problem. In: Proceedings, Prague Stringology Club Workshop 1998, pp. 14–25 (1998)
Apostolico, A., Landau, G.M., Skiena, S.: Matching for Run-Length Encoded Strings. Journal of Complexity 15(1), 4–16 (1999)
Arslan, A.N., Egecioglu, Ö.: Algorithms For The Constrained Longest Common Subsequence Problems. International Journal of Foundations of Computer Science 16(6), 1099–1109 (2005)
Bergroth, L., Hakonen, H., Raita, T.: A Survey of Longest Common Subsequence Algorithms. In: Proc. SPIRE 2000, pp. 39–48 (2000)
Berman, P., Karpinski, M.: On Some Tighter Inapproximability Results. Electronic Colloquium on Computational Complexity 5(29) (1998)
Chen, Y.C., Chao, K.M.: On the generalized constrained longest common subsequence problems. Journal of Combinatorial Optimization, 1–10 (2009)
Chin, F.Y.L., De Santis, A., Ferrara, A.L., Ho, N.L., Kim, S.K.: A simple algorithm for the constrained sequence problems. Information Processing Letters 90(4), 175–179 (2004)
Gotthilf, Z., Hermelin, D., Lewenstein, M.: Constrained LCS: Hardness and Approximation. In: Ferragina, P., Landau, G.M. (eds.) CPM 2008. LNCS, vol. 5029, pp. 255–262. Springer, Heidelberg (2008)
Gotthilf, Z., Lewenstein, M.: Approximating Constrained LCS. In: Ziviani, N., Baeza-Yates, R. (eds.) SPIRE 2007. LNCS, vol. 4726, pp. 164–172. Springer, Heidelberg (2007)
Hirschberg, D.S.: A Linear Space Algorithm for Computing Maximal Common Subsequences. Communications of the ACM 18(6), 341–343 (1975)
Hirschberg, D.S.: Algorithms for the Longest Common Subsequence Problem. Journal of the ACM 24(4), 664–675 (1977)
Iliopoulos, C.S., Rahman, M.S.: New efficient algorithms for the LCS and constrained LCS problems. Information Processing Letters 106(1), 13–18 (2008)
Iliopoulos, C.S., Rahman, M.S., Rytter, W.: Algorithms for two versions of the lcs problem for indeterminate strings. Journal of Combinatorial Mathematics and Combinatorial Computing (2008)
Maier, D.: The Complexity of Some Problems on Subsequences and Supersequences. Journal of the ACM 25(2), 322–336 (1978)
Masek, W.J., Paterson, M.: A Faster Algorithm Computing String Edit Distances. Journal of Computer and System Sciences 20(1), 18–31 (1980)
Tsai, Y.-T.: The constrained longest common subsequence problem. Information Processing Letters 88(4), 173–176 (2003)
Author information
Authors and Affiliations
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2010 Springer-Verlag Berlin Heidelberg
About this paper
Cite this paper
Gotthilf, Z., Hermelin, D., Landau, G.M., Lewenstein, M. (2010). Restricted LCS. In: Chavez, E., Lonardi, S. (eds) String Processing and Information Retrieval. SPIRE 2010. Lecture Notes in Computer Science, vol 6393. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-642-16321-0_26
Download citation
DOI: https://doi.org/10.1007/978-3-642-16321-0_26
Publisher Name: Springer, Berlin, Heidelberg
Print ISBN: 978-3-642-16320-3
Online ISBN: 978-3-642-16321-0
eBook Packages: Computer ScienceComputer Science (R0)