arrow
Return

String Matching with a Dynamic Pattern

delete2026-01-01
delete0
PRE
AI
B
Bruno Monteiro *
V
Vinícius F. dos Santos
DOI:10.1007/978-3-032-05228-5_17delete
deleteOriginal
deleteOriginal request for help
deleteShare
deleteSave
Abstract

Abstract

En 中文
In this work, we tackle a natural variation of the String Matching Problem on the case of a dynamic pattern, that is, given a static text T and a pattern P, we want to support character insertions and deletions to the pattern, and after each operation compute how many times it occurs in the text. We show a simple and practical algorithm using Suffix Arrays that achieves O( log |T|) update time, after O(|T|) preprocessing time. We show how to extend our solution to support substring deletion, transposition (moving a substring to another position of the pattern), and copy (copying a substring and pasting it in a specific position), in the same time complexities. Our solution can also be extended to support an online text (inserting characters to one end of the text), maintaining the same amortized bounds.
Keywords:
Strings
Algorithms
Suffix array
String matching

Journal

S
STRING PROCESSING AND INFORMATION RETRIEVAL, SPIRE 2025
IF:
0
Papers:
22
Citations:
0

Organization

U
universidade federal de minas gerais
Scholars:
4.3K
Papers: 1.5K
Citations: 0
Cited Papers

Cited Papers

Optimal Dynamic Strings
err2018-01-01
err0
PREAI
errGawrychowski,Paweł; Karczmarz,Adam; Kociumaka,Tomasz; Łącki,Jakub; Sankowski,Piotr
errShare
errSave
Approximate string matching using compressed suffix arrays
err2006-03-01
err0
errOAAI
errTrinh N.D. Huynh; Wing-Kai Hon; Tak-Wah Lam; Wing-Kin Sung
errShare
errSave
The LCA Problem Revisited
err2007-04-12
err0
PREAI
errMichael A. Bender; Martín Farach-Colton
errShare
errSave
errShare
errSave
Linear-Time Longest-Common-Prefix Computation in Suffix Arrays and Its Applications
err2001-06-13
err0
PREAI
errToru Kasai; Gunho Lee; Hiroki Arimura; Setsuo Arikawa; Kunsoo Park
errShare
errSave
errShare
errSave
errShare
errSave
Making data structures persistent
err1989-02-01
err0
errOAAI
errJames R. Driscoll; Neil Sarnak; Daniel D. Sleator; Robert E. Tarjan
errShare
errSave
researcher View more