A Practical Index for Approximate Dictionary Matching with Few Mismatches

Authors

  • Aleksander Cisłak Warsaw University of Technology, Faculty of Mathematics and Information Science, 00-662 Warsaw
  • Szymon Grabowski Lodz University of Technology, Institute of Applied Computer Science, 90-924 Łódź

Keywords:

Approximate dictionary matching, Hamming distance, k-mismatches problem, split index, text indexing

Abstract

Approximate dictionary matching (checking if a pattern occurs in a collection of strings) is a classic problem with applications in e.g. spellchecking, online catalogs, and web searchers. We present a simple solution called split index, which is based on the Dirichlet principle, for matching a keyword with few mismatches, and experimentally show that it offers competitive space-time tradeoffs. Our implementation in the C++ language is focused mostly on data compaction, which is beneficial for the search speed. We compare our solution with other algorithms and we show that it is faster when the Hamming distance is used. Query times in the order of 1 microsecond were reported for one mismatch for a few-megabyte natural language dictionary on a medium-end PC. We also demonstrate that a basic compression technique consisting in q-gram substitution can significantly reduce the index size (up to 50 % of the input text size for the DNA sequences).

Downloads

Download data is not yet available.

Downloads

Published

2017-12-19

How to Cite

Cisłak, A., & Grabowski, S. (2017). A Practical Index for Approximate Dictionary Matching with Few Mismatches. Computing and Informatics, 36(5), 1088–1106. Retrieved from http://147.213.75.17/ojs/index.php/cai/article/view/2017_5_1088