A quantum algorithm for string matching
Algorithms that search for a pattern within a larger data-set appear ubiquitously in text and image processing. Here, we present an explicit, circuit-level implementation of a quantum pattern-matching algorithm that matches a search string (pattern) of length M inside a longer text of length N. Our...
Saved in:
Published in | npj quantum information Vol. 7; no. 1 |
---|---|
Main Authors | , |
Format | Journal Article |
Language | English |
Published |
United States
Nature Partner Journals
16.02.2021
|
Subjects | |
Online Access | Get full text |
Cover
Loading…
Summary: | Algorithms that search for a pattern within a larger data-set appear ubiquitously in text and image processing. Here, we present an explicit, circuit-level implementation of a quantum pattern-matching algorithm that matches a search string (pattern) of length M inside a longer text of length N. Our algorithm has a time complexity of $\tildeO$($\sqrt{N}$), while the space complexity remains modest at O(N+ M). We report the quantum gate counts relevant for both pre-fault-tolerant and fault-tolerant regimes. |
---|---|
Bibliography: | USDOE Office of Science (SC) SC0019040; SC0020312 |
ISSN: | 2056-6387 2056-6387 |