English

Longest Square Subsequence Problem Revisited

Data Structures and Algorithms 2020-07-30 v2

Abstract

The longest square subsequence (LSS) problem consists of computing a longest subsequence of a given string SS that is a square, i.e., a longest subsequence of form XXXX appearing in SS. It is known that an LSS of a string SS of length nn can be computed using O(n2)O(n^2) time [Kosowski 2004], or with (model-dependent) polylogarithmic speed-ups using O(n2(loglogn)2/log2n)O(n^2 (\log \log n)^2 / \log^2 n) time [Tiskin 2013]. We present the first algorithm for LSS whose running time depends on other parameters, i.e., we show that an LSS of SS can be computed in O(rmin{n,M}lognr+n+Mlogn)O(r \min\{n, M\}\log \frac{n}{r} + n + M \log n) time with O(M)O(M) space, where rr is the length of an LSS of SS and MM is the number of matching points on SS.

Keywords

Cite

@article{arxiv.2006.00216,
  title  = {Longest Square Subsequence Problem Revisited},
  author = {Takafumi Inoue and Shunsuke Inenaga and Hideo Bannai},
  journal= {arXiv preprint arXiv:2006.00216},
  year   = {2020}
}

Comments

Accepted for SPIRE 2020