arXivDaily arXiv每日学术速递 周一至周五更新
arXiv周末暂无论文更新,休息一下吧,周末愉快~~
arXiv 1903.06289cs.DS
收藏

Trie树的参数化位置堆

The Parameterized Position Heap of a Trie

Noriki Fujisato, Yuto Nakashima, Shunsuke Inenaga, Hideo Bannai, Masayuki Takeda

摘要:

令$Σ$和$Π$是各自大小为$σ$和$π$的不相交字母表。如果存在双射$f:Σ\cup Π\rightarrow Σ\cup Π$,使得(1)$f$在$Σ$上是同一的,并且(2)$f$将一个字符串的字符映射到另一个字符串的字符,使得两个字符串变得相同,则称$Σ\cup Π$上的两个等长字符串参数化匹配(p匹配)。我们考虑的p-匹配问题(反向)特里$\mathcal{T}$和一个字符串模式$P$,这样的每一个路径,p-匹配$P$已被报告。令$N$为给定trie $\mathcal{T}$的大小。在本文中,我们提出了参数化的位置堆$\mathcal{T}$占用$O(N)$空间,并支持p-匹配查询在$O(m \log (σ+ π) + m π+ \mathit{pocc}))$时间,其中$m$是查询模式$P$的长度和$\mathit{pocc}$是路径的数量在$\mathcal{T}$报告。我们还提出了一个算法,构造一个给定的特里$\mathcal{T}$在$O(N (σ+ π))$时间和工作空间的参数化位置堆。

英文摘要:

Let $Σ$ and $Π$ be disjoint alphabets of respective size $σ$ and $π$. Two strings over $Σ\cup Π$ of equal length are said to parameterized match (p-match) if there is a bijection $f:Σ\cup Π\rightarrow Σ\cup Π$ such that (1) $f$ is identity on $Σ$ and (2) $f$ maps the characters of one string to those of the other string so that the two strings become identical. We consider the p-matching problem on a (reversed) trie $\mathcal{T}$ and a string pattern $P$ such that every path that p-matches $P$ has to be reported. Let $N$ be the size of the given trie $\mathcal{T}$. In this paper, we propose the parameterized position heap for $\mathcal{T}$ that occupies $O(N)$ space and supports p-matching queries in $O(m \log (σ+ π) + m π+ \mathit{pocc}))$ time, where $m$ is the length of a query pattern $P$ and $\mathit{pocc}$ is the number of paths in $\mathcal{T}$ to report. We also present an algorithm which constructs the parameterized position heap for a given trie $\mathcal{T}$ in $O(N (σ+ π))$ time and working space.

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

↑