Bidirectional Nested Weighted Automata
Nested weighted automata (NWA) present a robust and convenient automata-theoretic formalism for quantitative specifications. Previous works have considered NWA that processed input words only in the forward direction. It is natural to allow the automata to process input words backwards as well, for example, to measure the maximal or average time between a response and the preceding request. We therefore introduce and study bidirectional NWA that can process input words in both directions. First, we show that bidirectional NWA can express interesting quantitative properties that are not expressible by forward-only NWA. Second, for the fundamental decision problems of emptiness and universality, we establish decidability and complexity results for the new framework which match the best-known results for the special case of forward-only NWA. Thus, for NWA, the increased expressiveness of bidirectionality is achieved at no additional computational complexity. This is in stark contrast to the unweighted case, where bidirectional finite automata are no more expressive but exponentially more succinct than their forward-only counterparts.
💡 Research Summary
The paper introduces a new extension of nested weighted automata (NWA) that allows slave automata to move both forward and backward over the input word, called bidirectional NWA. Traditional NWA, as studied in earlier works, restrict slaves to forward walking only; consequently, they can express many quantitative properties but fail to capture specifications that inherently require looking backward, such as the time elapsed since the previous request or the freshness of a read relative to the last commit. By permitting backward‑walking slaves, the authors obtain a model that can naturally express such properties while retaining the compositional structure of NWA: a master automaton runs over an infinite word, and at each transition it spawns a slave automaton (either forward‑ or backward‑walking) that processes a finite sub‑word and returns an integer weight. The master aggregates these returned values using a value function for infinite sequences, typically the limit‑average (LimAvg).
Two illustrative examples are presented. The first is the average energy level: each position spawns a backward‑walking slave that sums the energy changes up to the current point; the master’s LimAvg then yields the long‑run average energy. The second is the data‑consistency property (DCP), where reads require the distance to the previous commit (backward‑walking) and writes require the distance to the next commit (forward‑walking). The average of these distances cannot be expressed by NWA with only forward or only backward slaves, but is captured by the bidirectional model.
From a theoretical standpoint, the authors prove three main results. (1) Expressiveness: forward‑only NWA and backward‑only NWA are incomparable; bidirectional NWA strictly subsume both. (2) Decidability: the emptiness problem (does there exist a word accepted with value below a threshold?) and the universality problem (are all words accepted with value below a threshold?) remain decidable for bidirectional NWA when the master uses LimAvg and slaves use standard finite‑word value functions such as min, max, sum, or bounded‑sum. (3) Complexity: the computational complexity of these decision problems matches that of forward‑only NWA. Specifically, emptiness and universality range from NLogSpace‑complete for very restricted cases, through PTime‑complete and PSPace‑complete, up to ExpSpace‑complete for the most general settings. The proofs rely on a reduction that transforms a backward‑walking slave into a forward‑walking one by reversing the input word, thereby allowing the existing decision procedures for forward‑only NWA to be reused without additional overhead.
A noteworthy contrast is drawn with the unweighted case. For ordinary finite automata, adding bidirectionality does not increase expressive power but yields exponential succinctness and raises decision‑problem complexity. In the weighted setting, however, bidirectionality both enlarges the class of definable quantitative properties and leaves the complexity landscape unchanged. This demonstrates that the quantitative dimension (weights and value functions) absorbs the added expressive power without a cost in algorithmic difficulty.
The paper also situates its contribution within related work on quantitative automata, monitor‑counter automata, and quantitative logics, highlighting that none of the prior frameworks allowed slaves to walk both directions while preserving decidability. The authors outline future directions, including tool support, optimization of bidirectional NWA, and extensions to richer value functions (e.g., mixed limit‑average and supremum). In summary, bidirectional NWA provide a powerful yet computationally tractable formalism for specifying and analyzing a broad range of quantitative system properties that were previously out of reach.
Comments & Academic Discussion
Loading comments...
Leave a Comment