English

Low-Latency Sliding Window Algorithms for Formal Languages

Formal Languages and Automata Theory 2022-10-03 v1 Data Structures and Algorithms

Abstract

Low-latency sliding window algorithms for regular and context-free languages are studied, where latency refers to the worst-case time spent for a single window update or query. For every regular language LL it is shown that there exists a constant-latency solution that supports adding and removing symbols independently on both ends of the window (the so-called two-way variable-size model). We prove that this result extends to all visibly pushdown languages. For deterministic 1-counter languages we present a O(logn)\mathcal{O}(\log n) latency sliding window algorithm for the two-way variable-size model where nn refers to the window size. We complement these results with a conditional lower bound: there exists a fixed real-time deterministic context-free language LL such that, assuming the OMV (online matrix vector multiplication) conjecture, there is no sliding window algorithm for LL with latency n1/2ϵn^{1/2-\epsilon} for any ϵ>0\epsilon>0, even in the most restricted sliding window model (one-way fixed-size model). The above mentioned results all refer to the unit-cost RAM model with logarithmic word size. For regular languages we also present a refined picture using word sizes O(1)\mathcal{O}(1), O(loglogn)\mathcal{O}(\log\log n), and O(logn)\mathcal{O}(\log n).

Keywords

Cite

@article{arxiv.2209.14835,
  title  = {Low-Latency Sliding Window Algorithms for Formal Languages},
  author = {Moses Ganardi and Louis Jachiet and Markus Lohrey and Thomas Schwentick},
  journal= {arXiv preprint arXiv:2209.14835},
  year   = {2022}
}

Comments

A short version will be presented at the conference FSTTCS 2022

R2 v1 2026-06-28T02:22:48.387Z