A Fast Algorithm Finding the Shortest Reset Words
In this paper we present a new fast algorithm finding minimal reset words for finite synchronizing automata. The problem is know to be computationally hard, and our algorithm is exponential. Yet, it is faster than the algorithms used so far and it works well in practice. The main idea is to use a bidirectional BFS and radix (Patricia) tries to store and compare resulted subsets. We give both theoretical and practical arguments showing that the branching factor is reduced efficiently. As a practical test we perform an experimental study of the length of the shortest reset word for random automata with $n$ states and 2 input letters. We follow Skvorsov and Tipikin, who have performed such a study using a SAT solver and considering automata up to $n=100$ states. With our algorithm we are able to consider much larger sample of automata with up to $n=300$ states. In particular, we obtain a new more precise estimation of the expected length of the shortest reset word $\approx 2.5\sqrt{n-5}$.
💡 Research Summary
The paper addresses the long‑standing computational challenge of finding the shortest reset word in a finite synchronizing automaton. While the problem is known to be computationally hard (exponential in the worst case), the authors propose a novel algorithm that dramatically improves practical performance. The core of the method combines a bidirectional breadth‑first search (BFS) with Patricia (radix) tries for compact storage and fast comparison of state subsets generated during the search.
In a traditional forward‑only BFS, the search starts from the full set of states and proceeds by applying input letters, generating a sequence of subsets until a singleton is reached. The number of generated subsets grows exponentially, quickly exhausting memory and time for automata with more than about 100 states. The authors’ bidirectional approach runs two simultaneous BFS processes: one forward from the full set and one backward from each singleton. When the two frontiers intersect, a concatenation of the forward and backward words yields a reset word. Because each side only needs to explore roughly half the depth of the shortest solution, the overall branching factor is effectively reduced from b^d to b^{d/2}, where b is the average branching factor and d is the length of the shortest reset word.
Patricia tries are employed to store each encountered subset as a compressed binary string. By merging common prefixes, the trie eliminates duplicate subsets and enables O(k) inclusion checks, where k is the trie depth (typically far smaller than the number of bits). This data structure dramatically cuts memory consumption compared with naïve bit‑vector or hash‑set implementations, and it allows rapid detection of already visited subsets on both the forward and backward sides.
The authors provide a theoretical analysis showing that, under reasonable assumptions about the distribution of subsets, the expected search depth on each side is O(log_b N) (N being the number of states). Consequently, the total number of explored nodes is bounded by O(b^{d/2}), a substantial improvement over the O(b^d) bound of a single‑direction BFS. Although the worst‑case time remains exponential, the constant factors are reduced enough to make the algorithm feasible for much larger instances.
Experimental evaluation focuses on random binary (two‑letter) automata. The authors replicate the experimental setup of Skvorsov and Tipikin, who used a SAT‑based method to study automata up to n = 100 states. With the new algorithm they extend the study to n = 300, processing tens of thousands of automata for each size. The results confirm that the algorithm consistently finds the true shortest reset word, while using significantly less time and memory than the SAT approach. Moreover, the large data set allows the authors to fit a new empirical formula for the expected length L(n) of the shortest reset word:
L(n) ≈ 2.5 √(n − 5).
This estimate is markedly lower than previously reported upper bounds (e.g., O(n³)) and suggests that, on average, synchronizing automata are far easier to reset than worst‑case constructions imply.
The paper’s contributions can be summarized as follows:
- Introduction of a bidirectional BFS framework tailored to the reset‑word problem, halving the effective search depth.
- Integration of Patricia tries for compact subset representation, enabling fast duplicate detection and inclusion testing.
- Theoretical analysis that quantifies the reduction in branching factor and provides expected‑case complexity bounds.
- Extensive empirical validation on random binary automata up to 300 states, demonstrating practical scalability.
- A new, more precise empirical law for the average shortest reset word length, enriching the statistical understanding of synchronizing automata.
Overall, the work bridges the gap between theoretical hardness and practical solvability, offering a tool that can be employed in further studies of synchronizing automata, related combinatorial problems, and applications where reset sequences are required (e.g., robotics, testing of reactive systems, and error‑recovery protocols).