کد مقاله | کد نشریه | سال انتشار | مقاله انگلیسی | نسخه تمام متن |
---|---|---|---|---|
426748 | 686259 | 2014 | 6 صفحه PDF | دانلود رایگان |

The longest common subsequence (LCS) problem with gap constraints (or the gapped LCS), which has applications to genetics and molecular biology, is an interesting and useful variant to the LCS problem. In previous work, this problem is solved in O(nm)O(nm) time when the gap constraints are fixed to a single integer, where n and m denote the lengths of the two input sequences A and B , respectively. In this paper, we first generalize the problem from fixed gaps to variable gap constraints. Then, we devise an optimal approach for the incremental suffix maximum query (ISMQ), which helps us obtain an efficient algorithm with O(nm)O(nm) time for finding LCS with variable gap constraints. In addition, our technique for ISMQ can be applied to solve one of the block edit problems on strings, reducing the time complexity from O(nmlogm+m2) to O(nm+m2)O(nm+m2). Hence, the result of this paper is beneficial to related research on sequence analysis and stringology.
Journal: Information and Computation - Volume 237, October 2014, Pages 95–100