# Fast linear-space computations of longest common subsequences

- Authors
- Journal
- Theoretical Computer Science 0304-3975
- Publisher
- Elsevier
- Publication Date
- Volume
- 92
- Issue
- 1
- Identifiers
- DOI: 10.1016/0304-3975(92)90132-y
- Disciplines

## Abstract

Abstract Space saving techniques in computations of a longest common subsequence (LCS) of two strings are crucial in many applications, notably, in molecular sequence comparisons. For about ten years, however, the only linear-space LCS algorithm known required time quadratic in the length of the input, for all inputs. This paper reviews linear-space LCS computations in connection with two classical paradigms originally designed to take less than quadratic time in favorable circumstances. The objective is to achieve the space reduction without alteration of the asymptotic time complexity of the original algorithm. The first one of the resulting constructions takes time O( n( m− l)), and is thus suitable for cases where the LCS is expected to be close to the shortest input string. The second takes time O( ml log(min[ s, m, 2n l ])) and suits cases where one of the inputs is much shorter than the other. Here m and n ( m⩽ n) are the lengths of the two input strings, l is the length of the longest common subsequences and s is the size of the alphabet. Along the way, a very simple O( m( m−l)) time algorithm is also derived for the case of strings of equal length.

## There are no comments yet on this publication. Be the first to share your thoughts.