Lune

FOCS2020顶会

Faster Approximate Pattern Matching: A Unified Approach

Panagiotis Charalampopoulos, Tomasz Kociumaka, Philip Wellnitz

摘要

In the approximate pattern matching problem, given a text T , a pattern P , and a threshold k, the task is to find (the starting positions of) all substrings of T that are at distance at most k from P . We consider the two most fundamental string metrics: Under the Hamming distance, we search for substrings of T that have at most k mismatches with P , while under the edit distance, we search for substrings of T that can be transformed to P with at most k edits.

Exact occurrences of P in T have a very simple structure: If we assume for simplicity that |P | < |T | ≤ 3 / 2 |P | and that P occurs both as a prefix and as a suffix of T , then both P and T are periodic with a common period. However, an analogous characterization for occurrences with up to k mismatches was proved only recently by Bringmann et al. [SODA'19]: Either there are O(k 2 ) k-mismatch occurrences of P in T , or both P and T are at Hamming distance O(k) from strings with a common string period of length O(m/k). We tighten this characterization by showing that there are O(k) k-mismatch occurrences in the non-periodic case, and we lift it to the edit distance setting, where we tightly bound the number of k-error occurrences by O(k 2 ) in the non-periodic case. Our proofs are constructive and let us obtain a unified framework for approximate pattern matching with respect to both considered distances. In particular, we provide meta-algorithms that only rely on a small set of primitive operations. We showcase the generality of our meta-algorithms with results for the following settings:

The fully compressed setting, where both T and P are given as straight-line programs of sizes n and m, respectively. Here, we obtain an Õ((n + m)k 2 )-time and an Õ((n + m)k 4 )-time algorithm for pattern matching with mismatches and edits, respectively. Note that while our algorithms are the first to work in the fully compressed setting (that is, without first decompressing the input), they also improve the state of the art for the setting where only the text is compressed: For pattern matching with mismatches, we improve the dependency on k from Õ((n + |P |)k 4 ) [Bringmann et al. SODA'19]; for pattern matching with edits, we improve the overall running time from Õ(n

The dynamic setting, where we maintain a collection of strings X of total length N using the data structure of Gawrychowski et al. [SODA'18], which supports each of the operations "split", "concatenate" and "insert a length-1 string" in O(log N ) time with high probability. Here, for any two strings T, P ∈ X , we can compute all occurrences of P in T with up to k mismatches in time Õ(|T |/|P | • k 2 ) or up to k edits in time Õ(|T |/|P | • k 4 ). The standard setting, where T and P are given explicitly. Here, we obtain an O(|T | + |T |/|P | • k 2 log log k)-time algorithm for the Hamming distance case (improving polylog |T | factors compared to the deterministic algorithm by Clifford et al. [SODA'18] and matching, up to the log log k factor, the randomized algorithm by Chan et al. [STOC'20], the state of the art for k ≤ |P |), and an O(|T | + |T |/|P | • k 4 )-time algorithm for the edit distance case (matching the algorithm by Cole and Hariharan [J. Comput.'02], the state of the art for k ≤ 3 |P |).

问 Lune

几分钟读透这篇 Paper,不用再花一下午。

Lune 能读完全文,也能读引用它的顶会 Paper,讲清它的结论、证据和局限,每一点都注明出自哪篇 Paper。不用硬啃,也不靠猜。

已有 16 篇顶会 Paper 引用了它。别等审稿人问起,先弄清它们发现了什么。

可以从这些问题问起

Lune 可以查阅

全文 · 引用它的顶会 Paper · 相关的 Paper

获取答案

免费开始,无需绑卡

脉络

  • Quantum Speed-ups for String Synchronizing Sets, Longest Common Substring, and k-mismatch Matching 引用了 Resolution of the Burrows-Wheeler Transform Conjecture
  • Collapsing the Hierarchy of Compressed Data Structures: Suffix Arrays in Optimal Compressed Space 引用了 Quantum Speed-ups for String Synchronizing Sets, Longest Common Substring, and k-mismatch Matching
  • Collapsing the Hierarchy of Compressed Data Structures: Suffix Arrays in Optimal Compressed Space 引用了 Resolution of the Burrows-Wheeler Transform Conjecture
  • Collapsing the Hierarchy of Compressed Data Structures: Suffix Arrays in Optimal Compressed Space 引用了 How Compression and Approximation Affect Efficiency in String Distance Measures
  • Small-space and streaming pattern matching with k edits 引用了 Approximating text-to-pattern Hamming distances
  • Small-space and streaming pattern matching with k edits 引用了 Resolution of the Burrows-Wheeler Transform Conjecture
  • Faster Pattern Matching under Edit Distance : A Reduction to Dynamic Puzzle Matching and the Seaweed Monoid of Permutation Matrices 引用了 Approximating text-to-pattern Hamming distances
  • Faster Pattern Matching under Edit Distance : A Reduction to Dynamic Puzzle Matching and the Seaweed Monoid of Permutation Matrices 引用了 Small-space and streaming pattern matching with k edits
  • How Compression and Approximation Affect Efficiency in String Distance Measures 引用了 Resolution of the Burrows-Wheeler Transform Conjecture
它引用的引用它的从左到右按年份排列,引用越多,位置越高。

引用它的顶会 Paper16

  1. Collapsing the Hierarchy of Compressed Data Structures: Suffix Arrays in Optimal Compressed SpaceDominik Kempa, Tomasz KociumakaFOCS 2023 · 20 次引用
  2. Small-space and streaming pattern matching with kk editsTomasz Kociumaka, Ely Porat, Tatiana StarikovskayaFOCS 2021 · 13 次引用
  3. Quantum Speed-ups for String Synchronizing Sets, Longest Common Substring, and k-mismatch MatchingCe Jin, Jakob NoglerSODA 2023 · 10 次引用
  4. Faster Pattern Matching under Edit Distance : A Reduction to Dynamic Puzzle Matching and the Seaweed Monoid of Permutation MatricesPanagiotis Charalampopoulos, Tomasz Kociumaka, Philip WellnitzFOCS 2022 · 8 次引用
  5. How Compression and Approximation Affect Efficiency in String Distance MeasuresArun Ganesh, Tomasz Kociumaka, Andrea Lincoln, Barna SahaSODA 2022 · 7 次引用

它引用的 Paper2

  1. Resolution of the Burrows-Wheeler Transform ConjectureDominik Kempa, Tomasz KociumakaFOCS 2020 · 32 次引用
  2. Approximating text-to-pattern Hamming distancesTimothy M. Chan, Shay Golan, Tomasz Kociumaka, Tsvi Kopelowitz 等STOC 2020 · 2 次引用

相关 Paper

  1. Near-Optimal-Time Quantum Algorithms for Approximate Pattern MatchingTomasz Kociumaka, Jakob Nogler, Philip WellnitzSODA 2025 · 1 次引用
  2. On the Communication Complexity of Approximate Pattern MatchingTomasz Kociumaka, Jakob Nogler, Philip WellnitzSTOC 2024 · 2 次引用
  3. Faster two-dimensional pattern matching with k mismatchesJonas Ellert, Pawel Gawrychowski, Adam Górkiewicz, Tatiana StarikovskayaSODA 2025 · 1 次引用
  4. Near-Optimal Property Testers for Pattern MatchingCe Jin, Tomasz KociumakaFOCS 2025 · 1 次引用
  5. Pattern Matching under Weighted Edit DistancePanagiotis Charalampopoulos, Tomasz Kociumaka, Philip WellnitzFOCS 2025 · 3 次引用
黄昏的海面,两侧是细线勾勒的悬崖