Consider a complete communication network on nodes, each of which is a state machine with states. In synchronous 2-counting, the nodes receive a common clock pulse and they have to agree on which pulses are "odd" and which are "even". We require that the solution is self-stabilising (reaching the correct operation from any initial state) and it tolerates Byzantine failures (nodes that send arbitrary misinformation). Prior algorithms are expensive to implement in hardware: they require a source of random bits or a large number of states . We use computational techniques to construct very compact deterministic algorithms for the first non-trivial case of . While no algorithm exists for , we show that as few as 3 states are sufficient for all values . We prove that the problem cannot be solved with only 2 states for , but there is a 2-state solution for all values .
View on arXiv