Book Nook Join Book Nook

Solving Some Sequence Problems on Run-Length Encoded Strings: Longest Common Subsequences, Edit Distances, and Squares

Y. L. Wang, G. S. Huang, and Jia-Jie Liu

Measuring the similarity or difference between two strings is a fundamental problem to many applications. In bioinformatics, one has to predict the structures of RNA and proteins, to classify the functions of molecules, to infer the phylogeny of organisms, and to search entries in huge sequence databases. While processing electronic documents, one needs fast and flexible indexing techniques to perform searches. For this purpose, many measures are defined. The longest common subsequence and the edit distance are the most studied dealt with problems in string processing. In this book, we propose an O(min{mN,Mn}) time algorithm for finding a longest common subsequence of strings X and Y with lengths m and n, respectively, and run-length-encoded lengths M and N, respectively. On the other hand, we also improve the time bound to O(min{mN,Mn}) for finding the edit distance between strings X and Y. Squares play a central role from word combinatorics and application perspective. We show how to locate all squares in a run-length encoded string in time O(N logN). The time complexity of our result is optimal, and it is irrelevant to the length of the original uncompressed string.

German edition · First published 2008 by VDM Verlag Dr. Müller · ISBN 9783639022650

Readers also shelved

Be the first to rate this book

Tap or drag across the stars

Keep track of what you read

Book Nook is a free reading tracker with a 3D bookshelf, a reading timer, challenges with friends and a Reading Wrapped at the end of the year. Add Solving Some Sequence Problems on Run-Length Encoded Strings: Longest Common Subsequences, Edit Distances, and Squares to your shelf in one tap.

Join Book Nook Get the app