Approximate On-line Palindrome Recognition, and Applications
Palindrome recognition is a classic problem in computer science. It is an example of a language that can not be recognized by a deterministic finite automaton and is often brought as an example of a problem whose decision by a single-tape Turing machine requires quadratic time.
In this paper we re-visit the palindrome recognition problem. We define a novel fingerprint that allows recognizing palindromes on-line in linear time with high probability. We then use group testing techniques to show that the fingerprint can be adapted to recognizing approximate palindromes on-line, i.e. it can recognize that a string is a palindrome with no more than k mismatches, where k is given.
Finally, we show that this fingerprint can be used as a tool for solving other problems on-line. In particular we consider approximate pattern matching by non-overlapping reversals. This is the problem where two strings S and T are given and the question is whether applying a sequence of non-overlapping reversals to S results in string T.
KeywordsPattern Match Defective Item Reversal Operation Information Processing Letter Deterministic Finite Automaton
Unable to display preview. Download preview PDF.
- 2.Amir, A., Aumann, Y., Landau, G., Lewenstein, M., Lewenstein, N.: Pattern matching with swaps. Journal of Algorithms 37, 247–266 (2000) (Preliminary version appeared at FOCS 1997)Google Scholar
- 10.Carpara, A.: Sorting by reversals is difficult. In: Proc. 1st Annual International Conference on Research in Computational Biology (RECOMB), pp. 75–83. ACM Press (1997)Google Scholar
- 12.Christie, D.A.: A 3/2-approximation algorithm for sorting by reversals. In: Proc. 9th Annual ACM-SIAM Symposium on Discrete Algorithms (SODA), pp. 244–252 (1998)Google Scholar
- 13.Cole, R., Hariharan, R.: Randomized swap matching in o(m logm log|σ|) time, Tech. Report TR1999-789, New York University, Courant Institute (September 1999)Google Scholar
- 15.Du, D.-Z., Hwang, F.K.: Combinatorial group testing and its applications, 2nd edn. Series on Applied Mathematics, vol. 12. World Scientific (2000)Google Scholar
- 16.Galil, Z.: On converting on-line algorithms into real-time and on real-time algorithms for string matching and palindrome recognition. SIGACT News, 26–30 (1975)Google Scholar
- 18.Karp, R.M., Rabin, M.O.: Efficient randomized pattern-matching algorithms. IBM Journal of Res. and Dev., 249–260 (1987)Google Scholar
- 21.Porat, B., Porat, E.: Exact and approximate pattern matching in the streaming model. In: Proc. 50th IEEE Symposium on the Foundation of Computer Science (FOCS), pp. 315–323 (2009)Google Scholar