Approximating Edit Distance in Truly Subquadratic Time: Quantum and MapReduce

The edit distance between two strings is defined as the smallest number of insertions, deletions, and substitutions that need to be made to transform one of the strings to another one. Approximating edit distance in subquadratic time is "one of the biggest unsolved problems in the field of combinatorial pattern matching". Our main result is a quantum constant approximation algorithm for computing the edit distance in truly subquadratic time. More precisely, we give an $O(n^{1.858})$ quantum algorithm that approximates the edit distance within a factor of $7$. We further extend this result to an $O(n^{1.781})$ quantum algorithm that approximates the edit distance within a larger constant factor. Our solutions are based on a framework for approximating edit distance in parallel settings. This framework requires as black box an algorithm that computes the distances of several smaller strings all at once. For a quantum algorithm, we reduce the black box to \textit{metric estimation} and provide efficient algorithms for approximating it. We further show that this framework enables us to approximate edit distance in distributed settings. To this end, we provide a MapReduce algorithm to approximate edit distance within a factor of $3$, with sublinearly many machines and sublinear memory. Also, our algorithm runs in a logarithmic number of rounds.

[1]  Rajeev Motwani,et al.  Randomized Algorithms , 1995, SIGA.

[2]  Piotr Indyk,et al.  Edit Distance Cannot Be Computed in Strongly Subquadratic Time (unless SETH is false) , 2014, STOC.

[3]  Esko Ukkonen,et al.  Algorithms for Approximate String Matching , 1985, Inf. Control..

[4]  Peter W. Shor,et al.  Algorithms for quantum computation: discrete logarithms and factoring , 1994, Proceedings 35th Annual Symposium on Foundations of Computer Science.

[5]  Mikhail J. Atallah,et al.  Efficient Parallel Algorithms for String Editing and Related Problems , 1990, SIAM J. Comput..

[6]  Silvio Lattanzi,et al.  Filtering: a method for solving graph problems in MapReduce , 2011, SPAA '11.

[7]  Alexandr Andoni,et al.  Parallel algorithms for geometric graph problems , 2013, STOC.

[8]  Ashley Montanaro,et al.  On Exact Quantum Query Complexity , 2011, Algorithmica.

[9]  Alexander Russell,et al.  Quantum Fourier Transforms and the Complexity of Link Invariants for Quantum Doubles of Finite Groups , 2012, ArXiv.

[10]  Aran Nayebi,et al.  Quantum algorithms for shortest paths problems in structured instances , 2014, ArXiv.

[11]  Gad M. Landau,et al.  Incremental String Comparison , 1998, SIAM J. Comput..

[12]  Stacey Jeffery,et al.  Nested Quantum Walks with Quantum Data Structures , 2012, SODA.

[13]  M. Sipser,et al.  Invariant quantum algorithms for insertion into an ordered list , 1999, quant-ph/9901059.

[14]  Mike Paterson,et al.  A Faster Algorithm Computing String Edit Distances , 1980, J. Comput. Syst. Sci..

[15]  Alexandr Andoni,et al.  Approximating edit distance in near-linear time , 2009, STOC '09.

[16]  Mehdi Mhalla,et al.  Quantum Query Complexity of Some Graph Problems , 2004, SIAM J. Comput..

[17]  Sergei Vassilvitskii,et al.  A model of computation for MapReduce , 2010, SODA '10.

[18]  M. Sipser,et al.  Limit on the Speed of Quantum Computation in Determining Parity , 1998, quant-ph/9802045.

[19]  Robert Beals,et al.  Quantum computation of Fourier transforms over symmetric groups , 1997, STOC '97.

[20]  Aleksandrs Belovs,et al.  Learning-Graph-Based Quantum Algorithm for k-Distinctness , 2012, 2012 IEEE 53rd Annual Symposium on Foundations of Computer Science.

[21]  Gilles Brassard,et al.  Tight bounds on quantum searching , 1996, quant-ph/9605034.

[22]  Latifur Khan,et al.  Calculating Edit Distance for Large Sets of String Pairs using MapReduce , 2014 .

[23]  Robert Krauthgamer,et al.  Approximating edit distance efficiently , 2004, 45th Annual IEEE Symposium on Foundations of Computer Science.

[24]  Alexandr Andoni,et al.  The smoothed complexity of edit distance , 2008, TALG.

[25]  Rafail Ostrovsky,et al.  Low distortion embeddings for edit distance , 2005, STOC '05.

[26]  Silvio Lattanzi,et al.  MapReduce Meets Fine-Grained Complexity: MapReduce Algorithms for APSP, Matrix Multiplication, 3-SUM, and Beyond , 2019, ArXiv.

[27]  Piotr Indyk,et al.  Algorithmic applications of low-distortion geometric embeddings , 2001, Proceedings 2001 IEEE International Conference on Cluster Computing.

[28]  Alexandr Andoni,et al.  Polylogarithmic Approximation for Edit Distance and the Asymmetric Query Complexity , 2010, 2010 IEEE 51st Annual Symposium on Foundations of Computer Science.

[29]  François Le Gall,et al.  Improved Quantum Algorithm for Triangle Finding via Combinatorial Arguments , 2014, 2014 IEEE 55th Annual Symposium on Foundations of Computer Science.

[30]  G. Brassard,et al.  Quantum Amplitude Amplification and Estimation , 2000, quant-ph/0005055.

[31]  Funda Ergün,et al.  Oblivious string embeddings and edit distance approximations , 2006, SODA '06.

[32]  Andris Ambainis,et al.  Quantum lower bounds by quantum arguments , 2000, STOC '00.

[33]  Lov K. Grover A fast quantum mechanical algorithm for database search , 1996, STOC '96.