Suffix-Prefix Deletion Model
- 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 and and by related quotient operations on languages accepted by deterministic machine families. In string algorithms, it appears as the query object , with the task of reporting all occurrences of 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 , with emphasis on deterministic reversal-bounded multicounter machines, deterministic pushdown automata, and finite automata. In the string-algorithmic setting of , deletion is a query on a fixed text 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 | or | |
| String algorithms | 0 | 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 2 be an alphabet and 3 a language. The two basic deletion operators are
4
Equivalently,
5
The deterministic machine model used most prominently is the one-way deterministic 6-counter 7-reversal-bounded multicounter machine, denoted 8. A 9 is a tuple
0
where
1
is a partial deterministic transition function, and each of the 2 counters may switch, over the whole run, between increasing and decreasing at most 3 times. Configurations are 4 with 5, 6 the unread suffix, and 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
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 9 is closed under prefix deletion without increasing counters or reversal bounds. If 0 and 1 is an accepting machine for 2, then 3 is accepted by simulating 4 on the input 5 and accepting whenever 6 would read its right end-marker. Formally,
7
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 8, then
9
The proof sketch proceeds by defining the right quotient 0 and building an intermediate NCM that verifies, after reading a candidate suffix 1, that there exists some 2 such that 3. 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 4 and 5 belongs to a reversal-bounded-counter-augmentable family, including NPCM or even context-free languages, then
6
for effectively computable 7. The proof constructs, for each state of the original machine, an auxiliary NPCM that checks whether a continuation in 8 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
9
A one-counter machine for 0 increments on each 1 and decrements on each 2, accepting iff the counter is 3 at the end. For prefix deletion,
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 5. For suffix deletion,
6
and the right-quotient construction reduces the witness condition to the regular test 7 (Eremondi et al., 2016).
The main negative result shows that additional reversals or counters destroy this favorable behavior. There exists 8, and hence in 9, such that
0
The construction uses a DCM encoding of a known non-semilinear language of the form
1
or, in the detailed example,
2
Its suffix language can recover a non-recursive set, so it is neither in DCM nor in 3 (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: 4 is closed under prefix deletion within itself; 5 is closed under suffix deletion within itself; 6 is closed under suffix deletion in DCM, possibly with more counters; but 7 for 8 or 9 is not closed under suffix deletion in 0 or 1 (Eremondi et al., 2016).
5. The string query model 2
In the second usage, the suffix-prefix deletion model is a query problem on a fixed string
3
over an integer alphabet
4
For any 5, define the delete-middle string
6
The associated quantity is
7
The summary notes that in many cases one only needs to consider 8, because otherwise 9 and there are trivially 0 or 1 occurrences of 2 (Pissis, 2024).
The key structural lemma states that all occurrences of 3 in 4 can be encoded in 5 space. Let 6 be the smallest period of 7, and fix 8 with 9. Then 0 has an occurrence strictly inside
1
if and only if:
- 2 is periodic with 3, and
- 4.
In that case the set of all occurrences is exactly the arithmetic progression
5
with total of 6 positions. Otherwise there are at most two occurrences: a prefix match at 7 iff
8
and a suffix match at 9 iff
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 01 stores exactly two components: the period 02 if 03 is periodic, or a special 04-marker if 05 is aperiodic; and an 06-word LCE data structure on 07 supporting both 08 and 09 in 10. Preprocessing in the word-RAM with 11 consists of computing 12 via the optimal packed-string algorithm of Kociumaka et al., and building the Kempa–Kociumaka LCE-structure on 13 and on 14 to answer 15 and 16 in 17. The total space is 18 words, which is optimal since just reading 19 takes 20 words (Pissis, 2024).
The query algorithm is constant-time. If 21, it returns 22. If 23, it returns 24, because 25 has length 26 only. Otherwise let 27. If 28, 29, and 30, the answer is the arithmetic progression 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 32 time in the word-RAM (Pissis, 2024).
The principal application given is pattern matching on node-labeled bipartite graphs. Let 33, let each 34 have label 35, each 36 have label 37, and let 38 be a pattern of length 39. One reports every edge 40 for which there exists a decomposition
41
where 42 is a suffix of 43 and 44 is a prefix of 45; these are exactly the occurrences of 46 spanning the edge 47. The method preprocesses 48 in 49 time, runs KMP on 50 versus 51 to find the longest suffix of 52 matching a prefix of 53, runs KMP on 54 versus 55 to find the longest prefix of 56 matching a suffix of 57, and then invokes 58 in 59 time per edge. The total time is 60 for graph scanning plus 61 preprocessing, yielding an optimal 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 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.