Fast two-dimensional approximate pattern matching

被引:0
|
作者
BaezaYates, R [1 ]
Navarro, G [1 ]
机构
[1] Univ Chile, Dept Comp Sci, Santiago, Chile
来源
关键词
D O I
10.1007/BFb0054334
中图分类号
TP301 [理论、方法];
学科分类号
081202 ;
摘要
We address the problem of approximate string matching in two dimensions, that is, to find a pattern of size m x m in a text of size n x n with at most k errors (substitutions, insertions and deletions). Although the problem can be solved using dynamic programming in time O(m(2)n(2)), this is in general too expensive for small L. So we design a filtering algorithm which avoids verifying most of the text with dynamic programming. This filter is based on a one-dimensional multi-pattern approximate search algorithm. The average complexity of our resulting algorithm is O(n(2)k log(sigma) m /m(2)) for k < m(m + 1)/(5 log(sigma) m), which is optimal and matches the best previous result which allows only substitutions. For higher error levels, we present an algorithm with time complexity O(n(2)k/(w root sigma) (where w is the size in bits of the computer word and sigma is the alphabet size). This algorithm works for k < m(m+1)(1-e/root sigma), where e = 2.718..., a limit which is not possible to improve. These are the first good expected-case algorithms for the problem. Our algorithms work also for rectangular patterns and rectangular text and can even be extended to the case where each row in the pattern and the text has a different length.
引用
收藏
页码:341 / 351
页数:11
相关论文
共 50 条
  • [1] Analysis of two-dimensional approximate pattern matching algorithms
    Park, K
    THEORETICAL COMPUTER SCIENCE, 1998, 201 (1-2) : 263 - 273
  • [2] Optimal exact and fast approximate two dimensional pattern matching allowing rotations
    Fredriksson, K
    Navarro, G
    Ukkonen, E
    COMBINATORIAL PATTERN MATCHING, 2002, 2373 : 235 - 248
  • [3] Two-dimensional pattern matching with rotations
    Amir, A
    Butman, A
    Crochemore, M
    Landau, GM
    Schaps, M
    COMBINATORIAL PATTERN MATCHING, PROCEEDINGS, 2003, 2676 : 17 - 31
  • [4] Two-dimensional pattern matching with rotations
    Amir, A
    Butman, A
    Crochemore, M
    Landau, GM
    Schaps, M
    THEORETICAL COMPUTER SCIENCE, 2004, 314 (1-2) : 173 - 187
  • [5] Two-dimensional pattern matching by two-dimensional online tessellation automata
    Polcar, T
    Melichar, B
    IMPLEMENTATION AND APPLICATION OF AUTOMATA, 2005, 3317 : 327 - 328
  • [6] Faster two-dimensional pattern matching with rotations
    Amir, Amihood
    Kapah, Oren
    Tsur, Dekel
    THEORETICAL COMPUTER SCIENCE, 2006, 368 (03) : 196 - 204
  • [7] A TECHNIQUE FOR TWO-DIMENSIONAL PATTERN-MATCHING
    ZHU, RF
    TAKAOKA, T
    COMMUNICATIONS OF THE ACM, 1989, 32 (09) : 1110 - 1120
  • [8] On two-dimensional pattern matching by finite automata
    Zdárek, J
    Melichar, B
    IMPLEMENTATION AND APPLICATION OF AUTOMATA, 2006, 3845 : 329 - 340
  • [9] TWO-DIMENSIONAL PATTERN-MATCHING BY TWO-DIMENSIONAL ONLINE TESSELLATION ACCEPTORS
    TODA, M
    INOUE, K
    TAKANAMI, I
    THEORETICAL COMPUTER SCIENCE, 1983, 24 (02) : 179 - 194
  • [10] A structural matching for two-dimensional visual pattern inspection
    Koo, JH
    Yoo, SI
    1998 IEEE INTERNATIONAL CONFERENCE ON SYSTEMS, MAN, AND CYBERNETICS, VOLS 1-5, 1998, : 4429 - 4434