z-logo
open-access-imgOpen Access
On Obtaining the Boyer-Moore String-Matching Algorithm by Partial Evaluation
Author(s) -
Olivier Danvy,
Henning Korsholm Rohde
Publication year - 2005
Publication title -
brics report series
Language(s) - English
Resource type - Journals
eISSN - 1601-5355
pISSN - 0909-0878
DOI - 10.7146/brics.v12i14.21880
Subject(s) - boyer–moore string search algorithm , string searching algorithm , commentz walter algorithm , string (physics) , algorithm , character (mathematics) , heuristic , computer science , matching (statistics) , search algorithm , pattern matching , mathematics , artificial intelligence , statistics , geometry , mathematical physics
We present the first derivation of the search phase of the Boyer-Moore string-matching algorithm by partial evaluation of an inefficient string matcher. The derivation hinges on identifying the `bad-character-shift' heuristic as a binding-time improvement, bounded static variation. An inefficient string matcher incorporating this binding-time improvement specializes into the search phase of the Horspool algorithm, which is a simplified variant of the Boyer-Moore algorithm. Combining the bad-character-shift binding-time improvement with our previous results yields a new binding-time-improved string matcher that specializes into the search phase of the Boyer-Moore algorithm.

The content you want is available to Zendy users.

Already have an account? Click here to sign in.
Having issues? You can contact us here