Succinct 2D Dictionary Matching with No Slowdown

The dictionary matching problem seeks all locations in a given text that match any of the patterns in a given dictionary. Efficient algorithms for dictionary matching scan the text once, searching for all patterns simultaneously. This paper presents the first 2-dimensional dictionary matching algorithm that operates in small space and linear time. Given d patterns, D = {P1,...,Pd}, each of size m × m, and a text T of size n × n, our algorithm finds all occurrences of Pi, 1 ≤ i ≤ d, in T. The preprocessing stores the dictionary in entropy compressed form, in |D|Hk(D)+O(|D|) bits. Our algorithm uses O(dm log dm) bits of extra space. The time complexity of our algorithm is linear O(|D| + |T|).

[1]  G. Benson,et al.  An Alphabet Independent Approach to Two Dimensional Matching , 1994 .

[2]  Wojciech Rytter,et al.  On maximal suffixes, constant-space linear-time versions of KMP algorithm , 2003, Theor. Comput. Sci..

[3]  Michael A. Bender,et al.  The LCA Problem Revisited , 2000, LATIN.

[4]  M. Crochemore,et al.  On-line construction of suffix trees , 2002 .

[5]  Fabrizio Luccio,et al.  Structuring labeled trees for optimal succinctness, and beyond , 2005, 46th Annual IEEE Symposium on Foundations of Computer Science (FOCS'05).

[6]  Theodore P. Baker A Technique for Extending Rapid Exact-Match String Matching to Arrays of More Than One Dimension , 1978, SIAM J. Comput..

[7]  Wing-Kai Hon,et al.  Compressed indexes for dynamic text collections , 2007, TALG.

[8]  Wing-Kai Hon,et al.  Compressed Index for Dictionary Matching , 2008, Data Compression Conference (dcc 2008).

[9]  Leszek Gasieniec,et al.  Real-Time String Matching in Sublinear Space , 2004, CPM.

[10]  Zvi Galil,et al.  Time-space-optimal string matching (Preliminary Report) , 1981, STOC '81.

[11]  Maxime Crochemore,et al.  Two-way string-matching , 1991, JACM.

[12]  Wing-Kai Hon,et al.  Faster Compressed Dictionary Matching , 2010, SPIRE.

[13]  Michael G. Main,et al.  An O(n log n) Algorithm for Finding All Repetitions in a String , 1984, J. Algorithms.

[14]  Wojciech Plandowski,et al.  Two-Dimensional Pattern Matching in Linear Time and Small Space , 1995, STACS.

[15]  Robert E. Tarjan,et al.  Fast Algorithms for Finding Nearest Common Ancestors , 1984, SIAM J. Comput..

[16]  Wing-Kai Hon,et al.  Succinct Index for Dynamic Dictionary Matching , 2009, ISAAC.

[17]  R.S. Bird,et al.  Two Dimensional Pattern Matching , 1977, Inf. Process. Lett..

[18]  Dina Sokol,et al.  Small-Space 2D Compressed Dictionary Matching , 2010, CPM.

[19]  Djamal Belazzougui Succinct Dictionary Matching with No Slowdown , 2010, CPM.

[20]  Gaston H. Gonnet,et al.  LATIN 2000: Theoretical Informatics: 4th Latin American Symposium, Punta del Este, Uruguay, April 10-14, 2000 Proceedings , 2000, Lecture Notes in Computer Science.