Shift-And Approach to Pattern Matching in LZW Compressed Text

  • Authors:
  • Takuya Kida;Masayuki Takeda;Ayumi Shinohara;Setsuo Arikawa

  • Affiliations:
  • -;-;-;-

  • Venue:
  • CPM '99 Proceedings of the 10th Annual Symposium on Combinatorial Pattern Matching
  • Year:
  • 1999

Quantified Score

Hi-index 0.00

Visualization

Abstract

This paper considers the Shift-And approach to the problem of pattern matching in LZW compressed text, and gives a new algorithm that solves it. The algorithm is indeed fast when a pattern length is at most 32, or the word length. After an O(m + |Σ|) time and O(|Σ|) space preprocessing of a pattern, it scans an LZW compressed text in O(n + r) time and reports all occurrences of the pattern, where n is the compressed text length, m is the pattern length, and r is the number of the pattern occurrences. Experimental results show that it runs approximately 1.5 times faster than a decompression followed by a simple search using the Shift-And algorithm. Moreover, the algorithm can be extended to the generalized pattern matching, to the pattern matching with k mismatches, and to the multiple pattern matching, like the Shift-And algorithm.