对于字符串$S$,回文子字符串$S[i..j]$被称为$S$中的$[s, t]$间隔的\emph{shortest unique palindromic substring}($\mathit{SUPS}$),如果$S[i..j]$在$S$中恰好出现一次,则间隔$[i, j]$包含$[s, t]$,并且每个包含比$S[i..j]$短的$[s, t]$的回文子字符串在$S$中至少出现两次。在本文中,我们研究的问题,回答$\mathit{SUPS}$查询行程编码字符串。我们展示了如何预处理一个给定的运行长度编码的字符串$\mathit{RLE}_{S}$的大小$m$在$O(m)$空间和$O(m \log σ_{\mathit{RLE}_{S}} + m \sqrt{\log m / \log\log m})$时间,使所有的$\mathit{SUPSs}$的任何后续查询间隔可以回答在$O(\sqrt{\log m / \log\log m} + α)$时间,其中$α$是输出的数量,和$σ_{\mathit{RLE}_{S}}$是不同的运行的$\mathit{RLE}_{S}$的数量。此外,我们考虑的SUPS问题的一个变种,其中的查询间隔也给出了游程编码的形式。对于这个变种的问题,我们提出了两种替代算法更快的查询。第一个在$O(\sqrt{\log\log m /\log\log\log m} + α)$时间内回答查询,可以在$O(m \log σ_{\mathit{RLE}_{S}} + m \sqrt{\log m / \log\log m})$时间内构建,第二个在$O(\log \log m + α)$时间内回答查询,可以在$O(m \log σ_{\mathit{RLE}_{S}})$时间内构建。这两种数据结构都需要$O(m)$空间。
英文摘要:
For a string $S$, a palindromic substring $S[i..j]$ is said to be a \emph{shortest unique palindromic substring} ($\mathit{SUPS}$) for an interval $[s, t]$ in $S$, if $S[i..j]$ occurs exactly once in $S$, the interval $[i, j]$ contains $[s, t]$, and every palindromic substring containing $[s, t]$ which is shorter than $S[i..j]$ occurs at least twice in $S$. In this paper, we study the problem of answering $\mathit{SUPS}$ queries on run-length encoded strings. We show how to preprocess a given run-length encoded string $\mathit{RLE}_{S}$ of size $m$ in $O(m)$ space and $O(m \log σ_{\mathit{RLE}_{S}} + m \sqrt{\log m / \log\log m})$ time so that all $\mathit{SUPSs}$ for any subsequent query interval can be answered in $O(\sqrt{\log m / \log\log m} + α)$ time, where $α$ is the number of outputs, and $σ_{\mathit{RLE}_{S}}$ is the number of distinct runs of $\mathit{RLE}_{S}$. Additionaly, we consider a variant of the SUPS problem where a query interval is also given in a run-length encoded form. For this variant of the problem, we present two alternative algorithms with faster queries. The first one answers queries in $O(\sqrt{\log\log m /\log\log\log m} + α)$ time and can be built in $O(m \log σ_{\mathit{RLE}_{S}} + m \sqrt{\log m / \log\log m})$ time, and the second one answers queries in $O(\log \log m + α)$ time and can be built in $O(m \log σ_{\mathit{RLE}_{S}})$ time. Both of these data structures require $O(m)$ space.
School of Informatics, University of Edinburgh(爱丁堡大学信息学院);Graduate School of Mathematics, Nagoya University(名古屋大学研究生院数学系);China Telecom Cloud Technology Co., Ltd.(中国电信云计算科技有限公司);XVERSE Technology Inc.(幻维科技(深圳)有限公司)
Improved Approximation Ratios for the Shortest Common Superstring Problem with Reverse Complements
Department of Computer Science, Graduate School of Information Science and Technology, The University of Tokyo(东京大学大学院信息理工学研究科计算机科学系);Division of Medical Data Informatics, Human Genome Center, Institute of Medical Science, The University of Tokyo(东京大学医学科学研究所人类基因组中心医疗数据信息学分部)
Quantum Algorithm for the Shortest Superstring Problem
Institute of Computational Mathematics and Information Technologies, Kazan Federal University(喀山联邦大学计算数学与信息技术研究所);Zavoisky Physical-Technical Institute, FRC Kazan Scientific Center of RAS(俄罗斯科学院喀山科学中心联邦研究中心扎沃伊斯基物理技术研究所)