arXivDaily arXiv每日学术速递 周一至周五更新
感恩节,周五至周末无更新,大家顺遂。周一再来吧
arXiv 1706.00148cs.DS
收藏

树和DAG上的保序模式匹配

Order preserving pattern matching on trees and DAGs

Temma Nakamura, Shunsuke Inenaga, Hideo Bannai, Masayuki Takeda

摘要:

保序模式匹配(OPPM)问题是,给定一个模式串$p$和一个文本串$t$,找出$t$中与$p$具有相同相对顺序的所有子串.在本文中,我们考虑两个变种的OPPM问题,一组文本字符串作为一棵树或DAG。我们表明,OPPM问题的长度$m$和文本树$T$的大小$N$的单一模式$p$可以解决在$O(m+N)$时间,如果字符的$p$是从一个整数字母的多项式大小。如果模式$p$在一般有序字母表上,则时间复杂度变为$O(m \log m + N)$。然后,我们表明,OPPM问题的一个单一的模式和文本DAG是NP完全的。

英文摘要:

The order preserving pattern matching (OPPM) problem is, given a pattern string $p$ and a text string $t$, find all substrings of $t$ which have the same relative orders as $p$. In this paper, we consider two variants of the OPPM problem where a set of text strings is given as a tree or a DAG. We show that the OPPM problem for a single pattern $p$ of length $m$ and a text tree $T$ of size $N$ can be solved in $O(m+N)$ time if the characters of $p$ are drawn from an integer alphabet of polynomial size. The time complexity becomes $O(m \log m + N)$ if the pattern $p$ is over a general ordered alphabet. We then show that the OPPM problem for a single pattern and a text DAG is NP-complete.

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

↑