Computing longest palindromic substring after single-character or block-wise edits

From MaRDI portal
Publication:2227497

DOI10.1016/J.TCS.2021.01.014zbMATH Open1502.68378arXiv1901.10722OpenAlexW3120084479MaRDI QIDQ2227497FDOQ2227497

Shunsuke Inenaga, Yuto Nakashima, Masayuki Takeda, Hideo Bannai, Mitsuru Funakoshi

Publication date: 15 February 2021

Published in: Theoretical Computer Science (Search for Journal in Brave)

Abstract: Palindromes are important objects in strings which have been extensively studied from combinatorial, algorithmic, and bioinformatics points of views. It is known that the length of the longest palindromic substrings (LPSs) of a given string T of length n can be computed in O(n) time by Manacher's algorithm [J. ACM '75]. In this paper, we consider the problem of finding the LPS after the string is edited. We present an algorithm that uses O(n) time and space for preprocessing, and answers the length of the LPSs in O(log (min {sigma, log n})) time after a single character substitution, insertion, or deletion, where sigma denotes the number of distinct characters appearing in T. We also propose an algorithm that uses O(n) time and space for preprocessing, and answers the length of the LPSs in O(ell + log log n) time, after an existing substring in T is replaced by a string of arbitrary length ell.


Full work available at URL: https://arxiv.org/abs/1901.10722





Cites Work


Cited In (9)

Uses Software


Recommendations





This page was built for publication: Computing longest palindromic substring after single-character or block-wise edits

Report a bug (only for logged in users!)Click here to report a bug for this page (MaRDI item Q2227497)