arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 1610.08305cs.DS
收藏

最优原地后缀排序

Optimal In-Place Suffix Sorting

Zhize Li, Jian Li, Hongwei Huo

摘要:

后缀数组是许多涉及字符串搜索和数据压缩的应用程序的基本数据结构。在过去的20年里,设计时间/空间有效的后缀阵列构造算法引起了人们的极大关注,并取得了相当大的进展。我们得到的\emph{first}在位后缀数组的建设算法,是最佳的时间和空间(只读)整数字母表。具体而言,本文做出了以下贡献:1.对于整数字母表,我们得到了第一个后缀排序算法,它需要线性时间,只使用$O(1)$工作空间(工作空间是输入字符串和输出后缀数组之外所需的总空间)。输入字符串可以在算法执行期间被修改,但是应该在算法终止时被恢复。2.我们通过为只读整数字母表提供第一个就地线性时间算法来加强第一个结果,该算法具有$|Σ|=O(n)$(即,不能修改输入字符串)。该算法解决了Franceschini和Muthukrishnan在ICALP 2007中提出的公开问题。开放性问题要求在$o(n\log n)$时间内设计就地算法,并最终在$O(n)$时间内使用$|Σ| \leq n$设计(只读)整数字母表。我们的结果实际上稍微强一些,因为我们允许$|Σ|=O(n)$。3.此外,对于只读通用字母表(即,只允许比较),我们提出了一个最优的原地$O(n\log n)$时间后缀排序算法,恢复了Manzini和Ferragina在ESA 2002中提出的一个公开问题Franceschini和Muthukrishnan的结果.

英文摘要:

The suffix array is a fundamental data structure for many applications that involve string searching and data compression. Designing time/space-efficient suffix array construction algorithms has attracted significant attention and considerable advances have been made for the past 20 years. We obtain the \emph{first} in-place suffix array construction algorithms that are optimal both in time and space for (read-only) integer alphabets. Concretely, we make the following contributions: 1. For integer alphabets, we obtain the first suffix sorting algorithm which takes linear time and uses only $O(1)$ workspace (the workspace is the total space needed beyond the input string and the output suffix array). The input string may be modified during the execution of the algorithm, but should be restored upon termination of the algorithm. 2. We strengthen the first result by providing the first in-place linear time algorithm for read-only integer alphabets with $|Σ|=O(n)$ (i.e., the input string cannot be modified). This algorithm settles the open problem posed by Franceschini and Muthukrishnan in ICALP 2007. The open problem asked to design in-place algorithms in $o(n\log n)$ time and ultimately, in $O(n)$ time for (read-only) integer alphabets with $|Σ| \leq n$. Our result is in fact slightly stronger since we allow $|Σ|=O(n)$. 3. Besides, for the read-only general alphabets (i.e., only comparisons are allowed), we present an optimal in-place $O(n\log n)$ time suffix sorting algorithm, recovering the result obtained by Franceschini and Muthukrishnan which was an open problem posed by Manzini and Ferragina in ESA 2002.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑