A Dynamic Programming Solution to a Generalized LCS Problem

preprint2013arXivOpen access

Abstract

In this paper, we consider a generalized longest common subsequence problem, the string-excluding constrained LCS problem. For the two input sequences XX and YY of lengths nn and mm, and a constraint string PP of length rr, the problem is to find a common subsequence ZZ of XX and YY excluding PP as a substring and the length of ZZ is maximized. The problem and its solution were first proposed by Chen and Chao\cite{1}, but we found that their algorithm can not solve the problem correctly. A new dynamic programming solution for the STR-EC-LCS problem is then presented in this paper. The correctness of the new algorithm is proved. The time complexity of the new algorithm is O(nmr)O(nmr).

Explore this paper’s authors, topics and related work.

Building this map preview

BZPEER is loading the nearby papers, people, topics and institutions for this page.

Reviews 0

Write a reviewWrite

No reviews yet.

Discussion 0

Add a commentWrite

No comments yet.