When quoting this document, please refer to the following
DOI: 10.4230/OASIcs.SOSA.2018.10
URN: urn:nbn:de:0030-drops-83089
URL: http://drops.dagstuhl.de/opus/volltexte/2018/8308/
 Go to the corresponding OASIcs Volume Portal

### A Simple Algorithm for Approximating the Text-To-Pattern Hamming Distance

 pdf-format:

### Abstract

The algorithmic task of computing the Hamming distance between a given pattern of length m and each location in a text of length n, both over a general alphabet \Sigma, is one of the most fundamental algorithmic tasks in string algorithms. The fastest known runtime for exact computation is \tilde O(n\sqrt m). We recently introduced a complicated randomized algorithm for obtaining a (1 +/- eps) approximation for each location in the text in O( (n/eps) log(1/eps) log n log m log |\Sigma|) total time, breaking a barrier that stood for 22 years. In this paper, we introduce an elementary and simple randomized algorithm that takes O((n/eps) log n log m) time.

### BibTeX - Entry

@InProceedings{kopelowitz_et_al:OASIcs:2018:8308,
author =	{Tsvi Kopelowitz and Ely Porat},
title =	{{A Simple Algorithm for Approximating the Text-To-Pattern Hamming Distance}},
booktitle =	{1st Symposium on Simplicity in Algorithms (SOSA 2018)},
pages =	{10:1--10:5},
series =	{OpenAccess Series in Informatics (OASIcs)},
ISBN =	{978-3-95977-064-4},
ISSN =	{2190-6807},
year =	{2018},
volume =	{61},
editor =	{Raimund Seidel},
publisher =	{Schloss Dagstuhl--Leibniz-Zentrum fuer Informatik},