Skip to main content
QUICK REVIEW

[Paper Review] Position Heaps for Parameterized Strings

Diptarama Diptarama, Takashi Katsura|arXiv (Cornell University)|Feb 8, 2017
Algorithms and Data Compression11 references6 citations
TL;DR

This paper introduces the parameterized position heap (PPH), a novel indexing structure for parameterized strings that enables efficient parameterized pattern matching. By extending the position heap data structure to handle parameterized strings using prev-encoding and augmented maximal-reach pointers, the authors present an online construction algorithm running in O(n log(|Σ| + |Π|)) time and a pattern matching algorithm running in O(m log(|Σ| + |Π|) + m|Π| + occ) time, where n is text length, m is pattern length, |Σ| and |Π| are alphabet sizes, and occ is the number of occurrences.

ABSTRACT

We propose a new indexing structure for parameterized strings, called parameterized position heap. Parameterized position heap is applicable for parameterized pattern matching problem, where the pattern matches a substring of the text if there exists a bijective mapping from the symbols of the pattern to the symbols of the substring. We propose an online construction algorithm of parameterized position heap of a text and show that our algorithm runs in linear time with respect to the text size. We also show that by using parameterized position heap, we can find all occurrences of a pattern in the text in linear time with respect to the product of the pattern size and the alphabet size.

Motivation & Objective

  • To address the need for efficient indexing structures for parameterized strings in applications such as software maintenance, plagiarism detection, and gene structure analysis.
  • To design a data structure that supports fast parameterized pattern matching by exploiting structural similarities between strings via bijective renaming of parameter symbols.
  • To extend the position heap concept to parameterized strings using prev-encoding and augmented pointers for maximal-reach information.
  • To achieve linear-time online construction of the indexing structure and efficient pattern matching with provable time complexity bounds.

Proposed method

  • Propose the parameterized position heap (PPH) as a sequence hash tree over prev-encoded suffixes of a parameterized string.
  • Use prev-encoding to normalize parameterized strings so that p-matches (bijective symbol mappings) yield identical encodings.
  • Introduce augmented position heap pointers (APPH) that store maximal-reach information to accelerate pattern matching.
  • Design an online construction algorithm based on Kucherov’s approach, processing the text from right to left and maintaining the PPH incrementally.
  • Develop a pattern matching algorithm that checks whether the prev-encoding of a pattern is directly represented in the PPH or splits the pattern into prefixes that are matched via maximal-reach pointers.
  • Leverage the structure of prev-encoding and the PPH’s tree hierarchy to efficiently locate all pattern occurrences in O(m log(|Σ| + |Π|) + m|Π| + occ) time.

Experimental results

Research questions

  • RQ1Can a position heap-like structure be adapted to support parameterized pattern matching with efficient construction and search?
  • RQ2What is the time complexity of constructing a parameterized position heap online for a parameterized string?
  • RQ3How can pattern matching be efficiently performed using the parameterized position heap, especially when the pattern’s prev-encoding is not directly represented?
  • RQ4What is the relationship between the parameterized position heap and other parameterized indexing structures like parameterized suffix arrays?

Key findings

  • The parameterized position heap can be constructed online in O(n log(|Σ| + |Π|)) time, where n is the length of the text and |Σ|, |Π| are the sizes of the constant and parameter symbol alphabets.
  • The pattern matching algorithm runs in O(m log(|Σ| + |Π|) + m|Π| + occ) time, where m is the pattern length and occ is the number of occurrences.
  • The use of augmented position heap pointers (APPH) enables efficient handling of patterns whose prev-encoding is not directly present in the PPH by splitting the pattern into prefixes that are matched incrementally.
  • The method correctly identifies all pattern occurrences by checking both direct node matches and descendants via maximal-reach pointers, ensuring correctness under the p-match definition.
  • The approach maintains linear dependence on the product of pattern length and parameter alphabet size, making it efficient for patterns with many parameter symbols.
  • The paper establishes a foundation for exploring connections between parameterized position heaps and parameterized suffix arrays, as suggested by prior work on standard position heaps and suffix arrays.

Better researchstarts right now

From reading papers to final review, dramatically reduce your research time.

No credit card · Free plan available

This review was created by AI and reviewed by human editors.