最优时间移动结构构造
Optimal-Time Move Structure Construction
AI总结:
本文提出一种最优时间与空间的移动结构构造算法,用于高效表示和导航排列,尤其在r远小于n时能显著压缩空间。
摘要:
移动结构通过覆盖集表示排列π,其中覆盖集由O(r)个不相交的区间组成,r是使得值一起置换的最小区间数。形式上,r=1+|{i∈[1,n) : π(i)−1≠π(i−1)}|。移动结构需要O(r)个字节的空间。给定包含i的区间的索引,它可以在O(1)时间内计算π(i)和包含π(i)的区间的索引。因此,对于r远小于n的排列,它允许在显著压缩的空间中表示和导航。之前的最佳O(r)空间移动结构构造算法需要O(rlogr)时间。在本文中,我们描述了一种构造算法,实现最优的O(r)时间和空间。我们还展示,使用改进的算法在最近的先前工作中,可以在O(r)工作空间和最优O(n)时间内计算最长公共前缀数组,给定运行长度编码的Burrows-Wheeler变换。最后,我们实现了改进的移动结构构造算法,并发现其比之前的最佳算法更快,同时使用相同比例的内存。
英文摘要:
The move structure represents a permutation $π$ of $[0,n)$ by partitioning the domain into $O(r)$ disjoint, contiguously permuted intervals, with $r$ being the minimum number of such intervals. This data structure occupies $O(r)$ words of space and enables $O(1)$-time computation of $π(i)$ given the interval that contains $i$. For permutations where $r \ll n$, this provides an efficient, compressed representation for navigation. While the existing best $O(r)$-space construction approaches require $O(r\log r)$-time, we present an optimal $O(r)$-time and space construction algorithm. This is achieved by replacing balanced search trees with pointer-based lists through introducing a bidirectional strategy that synchronizes construction of the structures for $π$ and its inverse $π^{-1}$ in a single, unified pass. By applying this algorithm to an existing result, we achieve the first optimal $O(n)$-time construction of the longest common prefix (LCP) array from a run-length-encoded Burrows-Wheeler transform (RLBWT) of $r$ runs in $O(r)$ working space. Empirical evaluation on pangenome-scale data confirms that our move structure construction algorithm is consistently faster than the previous best, achieving speedups of up to $\sim 2\times$ while using less memory.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。