重温广义模式匹配
Generalised Pattern Matching Revisited
摘要:
在$\texttt{Generalised Pattern Matching}\ (\texttt{GPM})$ [STOC'94,Muthukrishnan和Palem]的问题中,我们给出了长度为$n$的文本$T$在字母表$Σ_T$上,长度为$m$的模式$P$在字母表$Σ_P$上,以及匹配关系$\subseteq Σ_T \times Σ_P$,并且必须返回与PDMATHBMQ匹配的PDMATHBMN的所有子字符串(报告)或长度为$m$的$T$的每个子串与$P$之间的不匹配数量(计数)。在这项工作中,我们改进了所有以前已知的算法,这个问题的各种参数描述的输入实例:* $\mathcal{D}\,$是匹配一个固定字符的字符的最大数量,* $\mathcal{S}\,$是匹配字符对的数量,* $\mathcal{I}\,$是不相交的字符的间隔,匹配模式$P$的$m$字符的总数。在我们的新的确定性上界$\mathcal{D}\,$和$\mathcal{S}\,$的核心在于一个更快的建设叠加代码,解决了一个开放的问题,在[FOCS'97,Indyk],可以独立的利益。最后,我们证明了$\texttt{GPM}$的第一个下界。我们首先表明,任何确定性或蒙特卡罗算法的$\texttt{GPM}$必须使用$Ω(\mathcal{S})$时间,然后继续显示组合算法的下限。这些界限表明,我们的算法几乎是最优的,除非开发一种全新的方法。
英文摘要:
In the problem of $\texttt{Generalised Pattern Matching}\ (\texttt{GPM})$ [STOC'94, Muthukrishnan and Palem], we are given a text $T$ of length $n$ over an alphabet $Σ_T$, a pattern $P$ of length $m$ over an alphabet $Σ_P$, and a matching relationship $\subseteq Σ_T \times Σ_P$, and must return all substrings of $T$ that match $P$ (reporting) or the number of mismatches between each substring of $T$ of length $m$ and $P$ (counting). In this work, we improve over all previously known algorithms for this problem for various parameters describing the input instance: * $\mathcal{D}\,$ being the maximum number of characters that match a fixed character, * $\mathcal{S}\,$ being the number of pairs of matching characters, * $\mathcal{I}\,$ being the total number of disjoint intervals of characters that match the $m$ characters of the pattern $P$. At the heart of our new deterministic upper bounds for $\mathcal{D}\,$ and $\mathcal{S}\,$ lies a faster construction of superimposed codes, which solves an open problem posed in [FOCS'97, Indyk] and can be of independent interest. To conclude, we demonstrate first lower bounds for $\texttt{GPM}$. We start by showing that any deterministic or Monte Carlo algorithm for $\texttt{GPM}$ must use $Ω(\mathcal{S})$ time, and then proceed to show higher lower bounds for combinatorial algorithms. These bounds show that our algorithms are almost optimal, unless a radically new approach is developed.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。