部分文字列の最小接尾と回転を最適時間で行う
Minimal Suffix and Rotation of a Substring in Optimal Time
Minimal Suffix and Rotation of a Substring in Optimal Time
@misc{kociumaka2016minimal,
title = {Minimal Suffix and Rotation of a Substring in Optimal Time},
author = {Tomasz Kociumaka},
year = {2016},
eprint = {1601.08051},
archivePrefix = {arXiv},
primaryClass = {cs.DS},
url = {https://arxiv.org/abs/1601.08051}
}
Kociumaka, T. (2016). Minimal Suffix and Rotation of a Substring in Optimal Time [Preprint]. arXiv. https://doi.org/10.48550/arXiv.1601.08051
KOCIUMAKA T. Minimal Suffix and Rotation of a Substring in Optimal Time[EB/OL]. (2016-01-29)[2026-11-29]. https://arxiv.org/abs/1601.08051.
要旨
与えられたテキストに対して、文字列最小接尾辞クエリは、その出現位置で指定された部分文字列の辞書順最小の非空接尾辞を決定することを問う。我々は、線形時間の前処理後に定数時間でこのようなクエリを回答するデータ構造を開発した。これは、Babenko ら(CPM 2014)の、これらの時間複雑性の積 Theta(nlog n) で特徴づけられるトレードオフ解を改善するものである。次に、我々はこれらのクエリを拡張し、O(1) 文字列の連結をサポートするものとした。この拡張において、構築時間とクエリ時間は維持された。我々はこれらの一般化されたクエリを用いて、与えられた部分文字列の辞書順最小および最大回転を、線形時間の前処理後に定数時間で計算する。我々のデータ構造は、主に Lyndon 文字と Lyndon 分解の性質に依存している。これらに、融合木や文字列の順序同型という概念といったさらなるアルゴリズム的および組合せ論的なツールを組み合わせることで、効率的な実装を実現した。
For a text given in advance, the substring minimal suffix queries ask to determine the lexicographically minimal non-empty suffix of a substring specified by the location of its occurrence in the text. We develop a data structure answering such queries optimally: in constant time after linear-time preprocessing. This improves upon the results of Babenko et al. (CPM 2014), whose trade-off solution is characterized by Theta(nlog n) product of these time complexities. Next, we extend our queries to support concatenations of O(1) substrings, for which the construction and query time is preserved. We apply these generalized queries to compute lexicographically minimal and maximal rotations of a given substring in constant time after linear-time preprocessing. Our data structures mainly rely on properties of Lyndon words and Lyndon factorizations. We combine them with further algorithmic and combinatorial tools, such as fusion trees and the notion of order isomorphism of strings.