arXiv:2611.01761cs.DCNov 2026

Manuscript Offprint

arXiv:2611.01761

Computation in Anonymous Directed Dynamic Networks: Exact Worst-Case Termination Time and Network-Wise Intractability

Giuseppe A. Di Luna, Giovanni Viglietta

Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.

Abstract

We determine the exact round complexity of Counting in anonymous directed dynamic networks. Agents have no identifiers, but ℓ≥1\ell \geq 1 of them are designated as leaders. Every agent knows ℓ\ell and its own leader status, while the population size nn is unknown and has to be determined by the agents. Communication proceeds in synchronous rounds; the directed communication graph may change arbitrarily and unpredictably from one round to the next, but is assumed to remain strongly connected. We solve Counting with a distributed algorithm that makes every agent output nn and halt after a number of rounds equal to

{nif n=ℓ2n−1if n>ℓ and ℓ=12n−2if n>ℓ and ℓ≥2.\begin{cases}n & \text{if } n=\ell \\2n-1 & \text{if } n>\ell \text{ and } \ell=1 \\2n-2 & \text{if } n>\ell \text{ and } \ell\geq 2.\end{cases}

The algorithm works even for networks with loops and parallel arcs and even when agents learn their outdegree only after sending. We prove that this bound is worst-case tight over directed multigraphs for every nn and ℓ\ell with 1≤ℓ≤n1 \leq \ell \leq n. Moreover, the local computation is polynomial (provided that each communication multigraph has at most 2poly(n)2^{\text{poly}(n)} arcs): in every round, each agent solves at most one linear system with up to nn variables. By standard techniques, solving Counting also enables the evaluation of any computable function of the multiset of agents' input values within 2n−12n-1 communication rounds.

This is the first terminating Counting algorithm for the general directed network model that uses a polynomial number of communication rounds, improving the previous 2O(nlog⁡n)2^{O(n\log n)} bound to the exact linear optimum. This closes the exponential gap for directed networks and, in undirected networks, removes the quadratic dependence on the number of leaders in the previous upper bound and closes the gap between the 3n−23n-2 upper bound and the 2n−12n-1 lower bound for a single leader. Overall, our results improve earlier Counting bounds from papers appearing at JACM 2020, FOCS 2022, PODC 2024, SIROCCO 2024, and JACM 2026.

The bound above optimizes the worst case over all networks. For an individual network, we show that even deciding whether an agent already has enough local information to determine nn is coNP-complete (provided that the numbers of parallel arcs are encoded in binary). Thus, worst-case-optimal Counting admits polynomial local computation, whereas exact network-wise optimization is intractable under standard complexity assumptions.

Formal verification. Formal proofs in Lean of all results stated in this paper are available at https://github.com/gadiluna/ADDN_lean.

*Both authors contributed equally to this research.

Contents

1 Introduction 1
1.1 Contributions ..... 2
1.2 Technical Overview ..... 2
2 Model and History Trees 3
2.1 Properties of History Trees ..... 5
2.2 Flat Levels ..... 6
3 Worst-Case Terminating Counting 6
3.1 The Core Algorithm ..... 6
3.2 Sharp Bounds ..... 9
4 Network-Wise Complexity 12
4.1 Membership in coNP ..... 12
4.2 coNP-Hardness ..... 13
5 Related Work 15
6 Conclusions 17
A Solving a Flat Level 18
B Causal Support 18
C Sharp Upper Bounds 19
D Termination Lower Bounds 20
E Membership in coNP 23
E.1 The ATMOSTONEVISTA Problem ..... 24
E.2 Small Realizations ..... 24
E.3 Constructing the Network ..... 25
E.4 Compressing the History Tree ..... 26
E.5 Proof of Membership ..... 27
F coNP-Hardness 28
F.1 Encoding Exact Cover ..... 28
F.2 The Reference Network ..... 29
F.3 The Possible Network Sizes ..... 30
F.4 The Alternative Networks ..... 31

References (33)