Paper record
W2024557852An Alphabet Independent Approach to Two-Dimensional Pattern Matching
Amihood Amir, Gary Benson, Martín Farach-Colton
- Year
- 1994
- Venue
- SIAM Journal on Computing
- References
- 24
- Cited by
- 91
Details and counts from OpenAlex.
Abstract
There are many solutions to the string matching problem that are strictly linear in the input size and independent of alphabet size. Furthermore, the model of computation for these algorithms is very weak: they allow only simple arithmetic and comparisons of equality between characters of the input. In contrast, algorithms for two-dimensional matching have needed stronger models of computation, most notably assuming a totally ordered alphabet. The fastest algorithms for two-dimensional matching have therefore had a logarithmic dependence on the alphabet size. In the worst case, this gives an algorithm that runs in with preprocessing. The authors show an algorithm for two-dimensional matching with an text-scanning phase. Furthermore, the text scan requires no special assumptions about the alphabet, i.e., it runs on the same model as the standard linear-time string-matching algorithm. The pattern preprocessing requires an ordered alphabet and runs with the same alphabet dependency as the previously known algorithms.