Papers
Topics
Authors
Recent
Search
2000 character limit reached

Suffix-Prefix Deletion Model

Updated 8 July 2026
  • The suffix-prefix deletion model is a framework that examines how deletion operations on strings and languages preserve structure under deterministic computation.
  • It analyzes prefix and suffix operations within formal language theory using deterministic multicounter machines to understand closure properties and resource bounds.
  • In string algorithms, the model enables efficient query processing on texts, facilitating optimal preprocessing and constant-time query techniques in applications like graph pattern matching.

The suffix-prefix deletion model denotes a family of constructions in which a word is analyzed through the prefix and suffix material that remains after some portion is deleted or existentially quantified away. In formal language theory, the model is expressed by the language operators Prefix(L)\mathrm{Prefix}(L) and Suffix(L)\mathrm{Suffix}(L) and by related quotient operations on languages accepted by deterministic machine families. In string algorithms, it appears as the query object Ti,j=T[0..i]∥T[j..n−1]T_{i,j}=T[0..i]\Vert T[j..n-1], with the task of reporting all occurrences of TT inside the retained prefix-suffix concatenation. Across both settings, the central issue is whether deletion preserves enough structure to admit deterministic recognition or optimal query answering (Eremondi et al., 2016, Pissis, 2024).

1. Scope and terminological usage

In the exposition derived from Eremondi, Ibarra, and McQuillan, deletion is treated as an operation on languages over an alphabet Σ\Sigma, with emphasis on deterministic reversal-bounded multicounter machines, deterministic pushdown automata, and finite automata. In the string-algorithmic setting of PrefSuf(i,j)PrefSuf(i,j), deletion is a query on a fixed text TT that removes a middle interval and asks whether the original string reappears in the concatenation of the surviving prefix and suffix (Eremondi et al., 2016, Pissis, 2024).

This suggests a common abstraction: a retained prefix and a retained suffix are composed after deletion, and the problem is to characterize the resulting language or the resulting occurrence set. The two settings, however, differ in their basic objects and technical goals.

Setting Basic object Retained form after deletion
Formal language theory L⊆Σ∗L\subseteq \Sigma^* Prefix(L)\mathrm{Prefix}(L) or Suffix(L)\mathrm{Suffix}(L)
String algorithms Suffix(L)\mathrm{Suffix}(L)0 Suffix(L)\mathrm{Suffix}(L)1

A recurrent misconception in the automata-theoretic setting is that deterministic families should generally fail to be closed under deletion operations. The cited results qualify that expectation: some deterministic multicounter families remain closed under prefix deletion and, in restricted forms, under suffix deletion, whereas stronger negative results appear once reversal or counter resources increase (Eremondi et al., 2016).

2. Language-theoretic formulation

Let Suffix(L)\mathrm{Suffix}(L)2 be an alphabet and Suffix(L)\mathrm{Suffix}(L)3 a language. The two basic deletion operators are

Suffix(L)\mathrm{Suffix}(L)4

Equivalently,

Suffix(L)\mathrm{Suffix}(L)5

The deterministic machine model used most prominently is the one-way deterministic Suffix(L)\mathrm{Suffix}(L)6-counter Suffix(L)\mathrm{Suffix}(L)7-reversal-bounded multicounter machine, denoted Suffix(L)\mathrm{Suffix}(L)8. A Suffix(L)\mathrm{Suffix}(L)9 is a tuple

Ti,j=T[0..i]∥T[j..n−1]T_{i,j}=T[0..i]\Vert T[j..n-1]0

where

Ti,j=T[0..i]∥T[j..n−1]T_{i,j}=T[0..i]\Vert T[j..n-1]1

is a partial deterministic transition function, and each of the Ti,j=T[0..i]∥T[j..n−1]T_{i,j}=T[0..i]\Vert T[j..n-1]2 counters may switch, over the whole run, between increasing and decreasing at most Ti,j=T[0..i]∥T[j..n−1]T_{i,j}=T[0..i]\Vert T[j..n-1]3 times. Configurations are Ti,j=T[0..i]∥T[j..n−1]T_{i,j}=T[0..i]\Vert T[j..n-1]4 with Ti,j=T[0..i]∥T[j..n−1]T_{i,j}=T[0..i]\Vert T[j..n-1]5, Ti,j=T[0..i]∥T[j..n−1]T_{i,j}=T[0..i]\Vert T[j..n-1]6 the unread suffix, and Ti,j=T[0..i]∥T[j..n−1]T_{i,j}=T[0..i]\Vert T[j..n-1]7. The exposition also recalls deterministic pushdown automata and deterministic finite automata as comparison classes (Eremondi et al., 2016).

Within this framework, deletion is naturally related to quotients. The summary identifies

Ti,j=T[0..i]∥T[j..n−1]T_{i,j}=T[0..i]\Vert T[j..n-1]8

so suffix deletion is a special case of right quotient. The broader deletion program in the underlying paper also studies infix, outfix, and left and right quotient with languages from different families.

3. Closure mechanisms for deterministic multicounter machines

The strongest positive theorem in the language-theoretic exposition is that Ti,j=T[0..i]∥T[j..n−1]T_{i,j}=T[0..i]\Vert T[j..n-1]9 is closed under prefix deletion without increasing counters or reversal bounds. If TT0 and TT1 is an accepting machine for TT2, then TT3 is accepted by simulating TT4 on the input TT5 and accepting whenever TT6 would read its right end-marker. Formally,

TT7

The construction is operationally simple because no witness suffix must be generated explicitly (Eremondi et al., 2016).

A more delicate positive result holds for suffix deletion in the one-counter case: if TT8, then

TT9

The proof sketch proceeds by defining the right quotient Σ\Sigma0 and building an intermediate NCM that verifies, after reading a candidate suffix Σ\Sigma1, that there exists some Σ\Sigma2 such that Σ\Sigma3. Because the original machine has only one counter, the relevant unary counter-value language is regular. The NCM test can therefore be replaced by a DFA and integrated into the one-counter machine (Eremondi et al., 2016).

The general right-quotient theorem is broader. If Σ\Sigma4 and Σ\Sigma5 belongs to a reversal-bounded-counter-augmentable family, including NPCM or even context-free languages, then

Σ\Sigma6

for effectively computable Σ\Sigma7. The proof constructs, for each state of the original machine, an auxiliary NPCM that checks whether a continuation in Σ\Sigma8 exists from that state and those counter values, converts each auxiliary machine to DCM by semilinearity, and then simulates accordingly (Eremondi et al., 2016).

These constructions give the model a precise operational schema. Prefix deletion is realized directly on the original deterministic acceptor; suffix deletion is realized through precomputation of which states and counter values admit some completing prefix or suffix.

4. Canonical examples and non-closure boundaries

A standard example is

Σ\Sigma9

A one-counter machine for PrefSuf(i,j)PrefSuf(i,j)0 increments on each PrefSuf(i,j)PrefSuf(i,j)1 and decrements on each PrefSuf(i,j)PrefSuf(i,j)2, accepting iff the counter is PrefSuf(i,j)PrefSuf(i,j)3 at the end. For prefix deletion,

PrefSuf(i,j)PrefSuf(i,j)4

accepted by running the same machine on the input and accepting immediately upon end-of-input rather than checking that the counter returns to PrefSuf(i,j)PrefSuf(i,j)5. For suffix deletion,

PrefSuf(i,j)PrefSuf(i,j)6

and the right-quotient construction reduces the witness condition to the regular test PrefSuf(i,j)PrefSuf(i,j)7 (Eremondi et al., 2016).

The main negative result shows that additional reversals or counters destroy this favorable behavior. There exists PrefSuf(i,j)PrefSuf(i,j)8, and hence in PrefSuf(i,j)PrefSuf(i,j)9, such that

TT0

The construction uses a DCM encoding of a known non-semilinear language of the form

TT1

or, in the detailed example,

TT2

Its suffix language can recover a non-recursive set, so it is neither in DCM nor in TT3 (Eremondi et al., 2016).

The non-closure boundary extends further. Infix and outfix are not closed for machines with at least two reversal-bounded counters or at least three reversals on one counter. Deterministic pushdown automata are not closed under suffix or prefix deletion from the outset. The resulting closure chart is sharply stratified: TT4 is closed under prefix deletion within itself; TT5 is closed under suffix deletion within itself; TT6 is closed under suffix deletion in DCM, possibly with more counters; but TT7 for TT8 or TT9 is not closed under suffix deletion in L⊆Σ∗L\subseteq \Sigma^*0 or L⊆Σ∗L\subseteq \Sigma^*1 (Eremondi et al., 2016).

5. The string query model L⊆Σ∗L\subseteq \Sigma^*2

In the second usage, the suffix-prefix deletion model is a query problem on a fixed string

L⊆Σ∗L\subseteq \Sigma^*3

over an integer alphabet

L⊆Σ∗L\subseteq \Sigma^*4

For any L⊆Σ∗L\subseteq \Sigma^*5, define the delete-middle string

L⊆Σ∗L\subseteq \Sigma^*6

The associated quantity is

L⊆Σ∗L\subseteq \Sigma^*7

The summary notes that in many cases one only needs to consider L⊆Σ∗L\subseteq \Sigma^*8, because otherwise L⊆Σ∗L\subseteq \Sigma^*9 and there are trivially Prefix(L)\mathrm{Prefix}(L)0 or Prefix(L)\mathrm{Prefix}(L)1 occurrences of Prefix(L)\mathrm{Prefix}(L)2 (Pissis, 2024).

The key structural lemma states that all occurrences of Prefix(L)\mathrm{Prefix}(L)3 in Prefix(L)\mathrm{Prefix}(L)4 can be encoded in Prefix(L)\mathrm{Prefix}(L)5 space. Let Prefix(L)\mathrm{Prefix}(L)6 be the smallest period of Prefix(L)\mathrm{Prefix}(L)7, and fix Prefix(L)\mathrm{Prefix}(L)8 with Prefix(L)\mathrm{Prefix}(L)9. Then Suffix(L)\mathrm{Suffix}(L)0 has an occurrence strictly inside

Suffix(L)\mathrm{Suffix}(L)1

if and only if:

  1. Suffix(L)\mathrm{Suffix}(L)2 is periodic with Suffix(L)\mathrm{Suffix}(L)3, and
  2. Suffix(L)\mathrm{Suffix}(L)4.

In that case the set of all occurrences is exactly the arithmetic progression

Suffix(L)\mathrm{Suffix}(L)5

with total of Suffix(L)\mathrm{Suffix}(L)6 positions. Otherwise there are at most two occurrences: a prefix match at Suffix(L)\mathrm{Suffix}(L)7 iff

Suffix(L)\mathrm{Suffix}(L)8

and a suffix match at Suffix(L)\mathrm{Suffix}(L)9 iff

Suffix(L)\mathrm{Suffix}(L)00

(Pissis, 2024).

This characterization sharply limits the combinatorics of the deletion query. The only source of more than two occurrences is global periodicity of the original string with parameters aligned to the deleted interval.

6. Data-structural realization and graph application

The data structure for Suffix(L)\mathrm{Suffix}(L)01 stores exactly two components: the period Suffix(L)\mathrm{Suffix}(L)02 if Suffix(L)\mathrm{Suffix}(L)03 is periodic, or a special Suffix(L)\mathrm{Suffix}(L)04-marker if Suffix(L)\mathrm{Suffix}(L)05 is aperiodic; and an Suffix(L)\mathrm{Suffix}(L)06-word LCE data structure on Suffix(L)\mathrm{Suffix}(L)07 supporting both Suffix(L)\mathrm{Suffix}(L)08 and Suffix(L)\mathrm{Suffix}(L)09 in Suffix(L)\mathrm{Suffix}(L)10. Preprocessing in the word-RAM with Suffix(L)\mathrm{Suffix}(L)11 consists of computing Suffix(L)\mathrm{Suffix}(L)12 via the optimal packed-string algorithm of Kociumaka et al., and building the Kempa–Kociumaka LCE-structure on Suffix(L)\mathrm{Suffix}(L)13 and on Suffix(L)\mathrm{Suffix}(L)14 to answer Suffix(L)\mathrm{Suffix}(L)15 and Suffix(L)\mathrm{Suffix}(L)16 in Suffix(L)\mathrm{Suffix}(L)17. The total space is Suffix(L)\mathrm{Suffix}(L)18 words, which is optimal since just reading Suffix(L)\mathrm{Suffix}(L)19 takes Suffix(L)\mathrm{Suffix}(L)20 words (Pissis, 2024).

The query algorithm is constant-time. If Suffix(L)\mathrm{Suffix}(L)21, it returns Suffix(L)\mathrm{Suffix}(L)22. If Suffix(L)\mathrm{Suffix}(L)23, it returns Suffix(L)\mathrm{Suffix}(L)24, because Suffix(L)\mathrm{Suffix}(L)25 has length Suffix(L)\mathrm{Suffix}(L)26 only. Otherwise let Suffix(L)\mathrm{Suffix}(L)27. If Suffix(L)\mathrm{Suffix}(L)28, Suffix(L)\mathrm{Suffix}(L)29, and Suffix(L)\mathrm{Suffix}(L)30, the answer is the arithmetic progression Suffix(L)\mathrm{Suffix}(L)31. In the remaining case, there are at most two occurrences, obtained by the two LCE tests above. All steps—integer arithmetic, two LCE queries, and possibly returning the pair of positions—take Suffix(L)\mathrm{Suffix}(L)32 time in the word-RAM (Pissis, 2024).

The principal application given is pattern matching on node-labeled bipartite graphs. Let Suffix(L)\mathrm{Suffix}(L)33, let each Suffix(L)\mathrm{Suffix}(L)34 have label Suffix(L)\mathrm{Suffix}(L)35, each Suffix(L)\mathrm{Suffix}(L)36 have label Suffix(L)\mathrm{Suffix}(L)37, and let Suffix(L)\mathrm{Suffix}(L)38 be a pattern of length Suffix(L)\mathrm{Suffix}(L)39. One reports every edge Suffix(L)\mathrm{Suffix}(L)40 for which there exists a decomposition

Suffix(L)\mathrm{Suffix}(L)41

where Suffix(L)\mathrm{Suffix}(L)42 is a suffix of Suffix(L)\mathrm{Suffix}(L)43 and Suffix(L)\mathrm{Suffix}(L)44 is a prefix of Suffix(L)\mathrm{Suffix}(L)45; these are exactly the occurrences of Suffix(L)\mathrm{Suffix}(L)46 spanning the edge Suffix(L)\mathrm{Suffix}(L)47. The method preprocesses Suffix(L)\mathrm{Suffix}(L)48 in Suffix(L)\mathrm{Suffix}(L)49 time, runs KMP on Suffix(L)\mathrm{Suffix}(L)50 versus Suffix(L)\mathrm{Suffix}(L)51 to find the longest suffix of Suffix(L)\mathrm{Suffix}(L)52 matching a prefix of Suffix(L)\mathrm{Suffix}(L)53, runs KMP on Suffix(L)\mathrm{Suffix}(L)54 versus Suffix(L)\mathrm{Suffix}(L)55 to find the longest prefix of Suffix(L)\mathrm{Suffix}(L)56 matching a suffix of Suffix(L)\mathrm{Suffix}(L)57, and then invokes Suffix(L)\mathrm{Suffix}(L)58 in Suffix(L)\mathrm{Suffix}(L)59 time per edge. The total time is Suffix(L)\mathrm{Suffix}(L)60 for graph scanning plus Suffix(L)\mathrm{Suffix}(L)61 preprocessing, yielding an optimal Suffix(L)\mathrm{Suffix}(L)62-time algorithm for bipartite and hence two-node pattern matching in node-labeled graphs (Pissis, 2024).

The broader significance of the suffix-prefix deletion model is therefore domain-dependent. In automata theory, it measures how far deterministic acceptors retain closure under deletion, with precise thresholds in counter and reversal resources. In string algorithms, it yields a compact structural description of all occurrences surviving a middle deletion, enabling optimal preprocessing and Suffix(L)\mathrm{Suffix}(L)63 query time. The two lines of work are technically distinct, but both treat deletion not as arbitrary loss of information, but as a constrained operation whose residual prefix-suffix structure can still be characterized exactly.

Definition Search Book Streamline Icon: https://streamlinehq.com
References (2)

Topic to Video (Beta)

No one has generated a video about this topic yet.

Whiteboard

No one has generated a whiteboard explanation for this topic yet.

Follow Topic

Get notified by email when new papers are published related to Suffix-Prefix Deletion Model.