[论文解读] Dynamic Longest Common Substring in Polylogarithmic Time
本文提出了一种动态算法,用于维护在编辑操作下变化的两个字符串的最长公共子串(LCS),在高概率下实现了均摊更新时间 O(log⁷n)。该方法利用带有标签的双色叶节点的动态树结构,并创新性地应用了字符串解析一致性,显著优于先前的 ˜O(n²/³) 上界,并为任何多项式大小的数据结构建立了近乎最优的 Ω(log n / log log n) 下界。
The longest common substring problem consists in finding a longest string that appears as a (contiguous) substring of two input strings. We consider the dynamic variant of this problem, in which we are to maintain two dynamic strings $S$ and $T$, each of length at most $n$, that undergo substitutions of letters, in order to be able to return a longest common substring after each substitution. Recently, Amir et al. [ESA 2019] presented a solution for this problem that needs only $ ilde{\mathcal{O}}(n^{2/3})$ time per update. This brought the challenge of determining whether there exists a faster solution with polylogarithmic update time, or (as is the case for other dynamic problems), we should expect a polynomial (conditional) lower bound. We answer this question by designing a significantly faster algorithm that processes each substitution in amortized $\log^{\mathcal{O}(1)} n$ time with high probability. Our solution relies on exploiting the local consistency of the parsing of a collection of dynamic strings due to Gawrychowski et al. [SODA 2018], and on maintaining two dynamic trees with labeled bicolored leaves, so that after each update we can report a pair of nodes, one from each tree, of maximum combined weight, which have at least one common leaf-descendant of each color. We complement this with a lower bound of $Ω(\log n/ \log\log n)$ for the update time of any polynomial-size data structure that maintains the LCS of two dynamic strings, and the same lower bound for the update time of any data structure of size $ ilde{\mathcal{O}}(n)$ that maintains the LCS of a static and a dynamic string. Both lower bounds hold even allowing amortization and randomization.
研究动机与目标
- 设计一种动态数据结构,以在编辑操作下保持两个字符串的最长公共子串(LCS)的维护,且更新时间为多对数时间。
- 解决完全动态 LCS 问题中是否可实现多对数更新时间的开放问题。
- 为动态 LCS 数据结构建立紧致的条件性下界,即使在均摊化与随机化条件下亦成立。
- 将 PĂtrařscu 的从倾斜集合不相交性到蝴蝶图可达性的归约方法扩展至动态字符串问题。
提出的方法
- 利用 Gawrychowski 等人(SODA 2018)提出的字符串解析的局部一致性,以维护动态字符串表示。
- 维护两棵带有标签的双色叶节点的动态树,以高效表示与更新动态字符串。
- 采用基于 gadget 的构造方法,通过子串匹配编码最长公共子串的激活与查询模式。
- 将动态 LCS 问题归约为带标签树中叶节点对的激活问题,其中 LCS 长度对应路径深度与标签匹配。
- 应用基于信用的去均摊化技术,将期望的均摊界转换为最坏情况界,以支持下界分析。
- 将 PĂtrařscu 的从倾斜集合不相交性到蝴蝶图可达性的归约方法扩展,以推导条件性下界。
实验结果
研究问题
- RQ1完全动态最长公共子串问题是否能以每次编辑操作的多对数时间求解?
- RQ2是否存在一个条件性下界,可排除在均摊化或随机化条件下实现多对数更新时间的动态 LCS?
- RQ3动态 LCS 问题能否被归约为已知难题(如蝴蝶图可达性)以建立紧致的复杂度界?
- RQ4使用带标签的双色叶节点的动态树与字符串解析一致性,是否能显著优于先前的方法?
主要发现
- 本文提出了一种动态算法,在高概率下以每次编辑操作均摊 O(log⁷n) 的时间维护最长公共子串。
- 所提算法优于先前的 ˜O(n²/³) 更新时间上界,实现了指数级加速。
- 为任何维护两个动态字符串 LCS 的多项式大小数据结构,建立了 Ω(log n / log log n) 的条件性下界。
- 即使在均摊化与拉斯维加斯随机化条件下,该下界对静态与动态字符串组合的情形依然成立。
- 该下界通过新颖地扩展 PĂtrařscu 从倾斜集合不相交性到蝴蝶图可达性的归约方法获得。
- 结果表明,在标准复杂度假设下,所提算法几乎是最优的,仅相差多对数因子。
更好的研究,从现在开始
从论文设计到论文写作,大幅缩短您的研究时间。
无需绑定信用卡
本解读由 AI 生成,并经人工编辑审核。