Theoretical Computer Science ( IF 0.9 ) Pub Date : 2020-11-19 , DOI: 10.1016/j.tcs.2020.11.023 Amihood Amir , Eitan Kondratovsky
Parameterized matching has proven to be an efficient and useful tool for detecting code duplications. This paper presents a technique for calculating parameterized Longest Common Prefix () in constant time based on the knowledge about the of the following suffixes. Using this technique, online p-suffix tree construction can be done in worst case time per input symbol. Searching for a pattern of length m in the resulting suffix tree takes time, where is the number of occurrences of the pattern, and depends on Π. For constant-sized Π, , for polynomial-sized Π, , and for unbounded Π, .
中文翻译:
迈向用于参数化最长公共前缀计算的实时算法
事实证明,参数化匹配是检测代码重复的有效工具。本文提出了一种计算参数化的最长公共前缀()基于有关以下后缀。使用此技术,可以在最坏的情况下完成在线p后缀树的构建每个输入符号。在结果后缀树中搜索长度为m的模式需要 时间,地点 是模式的出现次数,并且 取决于Π。对于恒定大小的Π,,对于多项式大小的Π, ,对于无界Π, 。