## 1 Introduction

This paper is part of an ongoing research project aiming to develop a descriptive complexity theory for distributed computing.

In classical sequential computing, descriptive complexity is a well-established field that connects computational complexity classes to equi-expressive classes of logical formulas. It began in the 1970s, when Fagin showed in [6] that the graph properties decidable by nondeterministic Turing machines in polynomial time are exactly those definable in existential second-order logic. This provided a logical—and thus machine-independent—characterization of the complexity class $$\textsc {np}$$. Subsequently, many other popular classes, such as $$\textsc {p}$$, $$\textsc {pspace}$$, and $$\textsc {exptime}$$ were characterized in a similar manner (see for instance the textbooks [8, 12, 15]).

Of particular interest to us is a result due to Abiteboul, Vianu [1], and Vardi [19], which states that on structures equipped with a total order relation, the properties decidable in $$\textsc {pspace}$$ coincide with those definable in partial fixpoint logic. The latter is an extension of first-order logic with an operator that allows us to inductively define new relations of arbitrary arity. Basically, this means that new relations can occur as free (second-order) variables in the logical formulas that define them. Those variables are initially interpreted as empty relations and then iteratively updated, using the defining formulas as update rules. If the sequence of updates converges to a fixpoint, then the ultimate interpretations are the relations reached in the limit. Otherwise, the variables are simply interpreted as empty relations. Hence the term “partial fixpoint”.

While well-developed in the classical case, descriptive complexity has so far not received much attention in the setting of distributed network computing. As far as the authors are aware, the first step in this direction was taken by Hella et al. in [10, 11], where they showed that basic modal logic evaluated on finite graphs has the same expressive power as a particular class of distributed automata operating in constant time. Those automata constitute a weak model of distributed computing in arbitrary network topologies, where all nodes synchronously execute the same finite-state machine and communicate with each other by broadcasting messages to their neighbors. Motivated by this result, several variants of distributed automata were investigated by Kuusisto and Reiter in [14, 18] and [17] to establish similar connections with standard logics such as the modal $$\mu$$-calculus and monadic second-order logic. However, since the models of computation investigated in those works are based on anonymous finite-state machines, they are much too weak to solve many of the problems typically considered in distributed computing, such as leader election or constructing a spanning tree. It would thus be desirable to also characterize stronger models.

A common assumption underlying many distributed algorithms is that each node of the considered network is given a unique identifier. This allows us, for instance, to elect a leader by making the nodes broadcast their identifiers and then choose the one with the smallest identifier as the leader. To formalize such algorithms, we need to go beyond finite-state machines because the number of bits required to encode a unique identifier grows logarithmically with the number of nodes in the network. Recently, in [2, 3], Aiswarya, Bollig and Gastin introduced a synchronous model where, in addition to a finite-state controller, nodes also have a fixed number of registers in which they can store the identifiers of other nodes. Access to those registers is rather limited in the sense that their contents can be compared with respect to a total order, but their numeric values are unknown to the nodes. (This restriction corresponds precisely to the notion of order-invariant distributed algorithms, which was introduced by Naor and Stockmeyer in [16].) Similarly, register contents can be copied, but no new values can be generated. Since the original motivation for the model was to automatically verify certain distributed algorithms running on ring networks, its formal definition is tailored to that particular setting. However, the underlying principle can be generalized to arbitrary networks of unbounded maximum degree, which was the starting point for the present work.

Contributions. While on an intuitive level, the idea of finite-state machines equipped with additional registers might seem very natural, it does not immediately yield a formal model for distributed algorithms in arbitrary networks. In particular, it is not clear what would be the canonical way for nodes to communicate with a non-constant number of peers, if we require that they all follow the same, finitely representable set of rules.

The model we propose here, dubbed distributed register automata, is an attempt at a solution. As in [2, 3], nodes proceed in synchronous rounds and have a fixed number of registers, which they can compare and update without having access to numeric values. The new key ingredient that allows us to formalize communication between nodes of unbounded degree is a local computing device we call transition maker. This is a special kind of register machine that the nodes can use to scan the states and register values of their entire neighborhood in a sequential manner. In every round, each node runs the transition maker to update its own local configuration (i.e., its state and register valuation) based on a snapshot of the local configurations of its neighbors in the previous round. A way of interpreting this is that the nodes communicate by broadcasting their local configurations as messages to their neighbors. Although the resulting model of computation is by no means universal, it allows formalizing algorithms for a wide range of problems, such as constructing a spanning tree (see Example 5) or testing whether a graph is Hamiltonian (see Example 6).

Nevertheless, our model is somewhat arbitrary, since it could be just one particular choice among many other similar definitions capturing different classes of distributed algorithms. What justifies our choice? This is where descriptive complexity comes into play. By identifying a logical formalism that has the same expressive power as distributed register automata, we provide substantial evidence for the naturalness of that model. Our formalism, referred to as functional fixpoint logic, is a fragment of the above-mentioned partial fixpoint logic. Like the latter, it also extends first-order logic with a partial fixpoint operator, but a weaker one that can only define unary functions instead of arbitrary relations. We show that on totally ordered graphs, this logic allows one to express precisely the properties that can be decided by distributed register automata. The connection is strongly reminiscent of Abiteboul, Vianu and Vardi’s characterization of $$\textsc {pspace}$$, and thus contributes to the broader objective of extending classical descriptive complexity to the setting of distributed computing. Moreover, given that logical formulas are often more compact and easier to understand than abstract machines (compare Examples 6 and 8), logic could also become a useful tool in the formal specification of distributed algorithms.

The remainder of this paper is structured around our main result:

### Theorem 1

When restricted to finite graphs whose nodes are equipped with a total order, distributed register automata are effectively equivalent to functional fixpoint logic.

After giving some preliminary definitions in Sect. 2, we formally introduce distributed register automata in Sect. 3 and functional fixpoint logic in Sect. 4. We then sketch the proof of Theorem 1 in Sect. 5, and conclude in Sect. 6.

## 2 Preliminaries

We denote the empty set by , the set of nonnegative integers by , and the set of integers by . The cardinality of any set S is written as and the power set as .

In analogy to the commonly used notation for real intervals, we define the notation for any such that . To indicate that an endpoint is excluded, we replace the corresponding square bracket with a parenthesis, e.g., . Furthermore, if we omit the first endpoint, it defaults to 0. This gives us shorthand notations such as and .

All graphs we consider are finite, simple, undirected, and connected. For notational convenience, we identify their nodes with nonnegative integers, which also serve as unique identifiers. That is, when we talk about the of a node, we mean its numerical representation. A is formally represented as a pair , where the set of is equal to , for some integer , and the set consists of undirected of the form such that . Additionally, must satisfy that every pair of nodes is connected by a sequence of edges. The restriction to graphs of size at least two is for technical reasons; it ensures that we can always encode Boolean values as nodes.

We refer the reader to [5] for standard graph theoretic terms such as , , , , and .

Graphs are used to model computer networks, where nodes correspond to processes and edges to communication links. To represent the current configuration of a system as a graph, we equip each node with some additional information: the current state of the corresponding process, taken from a nonempty finite set , and some pointers to other processes, modeled by a finite set of registers.

We call a and define a - as a tuple , where is a graph, called the graph of , is a that assigns to each node a state , and is a that associates with each node a . The set of all -configurations is denoted by . Figure 1 on page 6 illustrates part of a -configuration.

If , then we are actually dealing with a tuple , which we call a -. Accordingly, the elements of may also be called . A set of labeled graphs will be referred to as a . Moreover, if the labels are irrelevant, we set equal to the singleton , where is our dummy label. In this case, we identify with and call it an graph.

## 3 Distributed Register Automata

Many distributed algorithms can be seen as transducers. A leader-election algorithm, for instance, takes as input a network and outputs the same network, but with every process storing the identifier of the unique leader in some dedicated register . Thus, the algorithm transforms a -configuration into a -configuration. We say that it defines a . By the same token, if we consider distributed algorithms that decide graph properties (e.g., whether a graph is Hamiltonian), then we are dealing with a , where is some set of labels. The idea is that a graph will be accepted if and only if every process eventually outputs .

Let us now formalize the notion of transduction. For any two signatures and , a is a partial mapping such that, if defined, for some and . That is, a transduction does not modify the underlying graph but only the states and register valuations. We denote the set of all by and refer to and as the and of . By extension, and are called the sets of and , and and the sets of and . Similarly, any -configuration can be referred to as an of and as an .

Next, we introduce our formal model of distributed algorithms.

### Definition 2

(Distributed register automaton). Let and be two signatures. A (or simply ) with input signature and output signature is a tuple consisting of a nonempty finite set of , a finite set of that includes both and , an , a transition maker whose specification will be given in Definition 3 below, a set of , and an . The registers in are called .

Automaton computes a transduction . To do so, it runs in a sequence of synchronous rounds on the input configuration’s underlying graph . After each round, the automaton’s global configuration is a -configuration , i.e., the underlying graph is always . As mentioned before, for a node , we interpret as the current state of  and as the current register valuation of . Abusing notation, we let and say that is the of . In Fig. 1, the local configuration node 17 is .

For a given input configuration , the automaton’s is , where for all , we have if , and if . This means that every node is initialized to state , and ’s initial register valuation assigns ’s own identifier (provided by ) to all non-input registers while keeping the given values assigned by to the input registers.

Each subsequent configuration is obtained by running the transition maker  synchronously on all nodes. As we will see, computes a function

that maps from nonempty sequences of local configurations to local configurations. This allows the automaton to transition from a given configuration to the next configuration as follows. For every node of degree , we consider the list of ’s neighbors sorted in ascending (identifier) order, i.e., . (See Fig. 1 for an example, where  corresponds to node 17.) If is already in a halting state, i.e., if , then its local configuration does not change anymore, i.e., . Otherwise, we define , which we may write more suggestively as

Intuitively, node updates its own local configuration by using to scan a snapshot of its neighbors’ local configurations. As the system is synchronous, this update procedure is performed simultaneously by all nodes.

A configuration is called a if all nodes are in a halting state, i.e., if for all . We say that $$A\,halts$$ if it reaches a halting configuration.

The output configuration produced by a halting configuration is the , where for all and , we have . In other words, each node outputs the state and keeps in its output registers the values assigned by .

It is now obvious that defines a transduction . If receives the input configuration and eventually halts and produces the output configuration , then . Otherwise (if does not halt), is undefined.

Deciding graph properties. Our primary objective is to use distributed register automata as decision procedures for graph properties. Therefore, we will focus on automata that halt in a finite number of rounds on every input configuration, and we often restrict to input signatures of the form and the output signature . For example, for , we may be interested in the set of -labeled graphs that have exactly one a-labeled node (the “leader”). We stipulate that an input configuration with underlying graph if such that for all . Conversely,   if such that for some . This corresponds to the usual definition chosen in the emerging field of distributed decision [7]. Accordingly, a graph property is by if the automaton accepts all input configurations that satisfy and rejects all the others.

It remains to explain how the transition maker works internally.

### Definition 3

(Transition maker). Suppose that is a distributed register automaton. Then its consists of a nonempty finite set of , a finite set of that is disjoint from , an  , an , and an .

Basically, a transition maker is a sequential register automaton (in the spirit of [13]) that reads a nonempty sequence of local configurations of in order to produce a new local configuration . While reading this sequence, it traverses itself a sequence of , which each consist of an inner state and an , where the symbol represents an undefined value. For the initial inner configuration, we set and for all . Now for , when is in the inner configuration and reads the local configuration , it can compare all values assigned to the inner registers and registers by and (with respect to the order relation on ). In other words, it has access to the binary relation such that for and , we have if and only if , and analogously for , , and . In particular, if , then is incomparable with respect to . Equipped with this relation, transitions to by evaluating and computing such that if , and if , where and . Finally, after having read the entire input sequence and reached the inner configuration , the transition maker outputs the local configuration such that and implies . Here we assume without loss of generality that guarantees that for all .

### Remark 4

Recall that for any graph with n nodes. However, as registers cannot be compared with constants, this actually represents an arbitrary assignment of unique, totally ordered identifiers. To determine the smallest identifier (i.e., 0), the nodes can run an algorithm such as the following.

### Example 5

(Spanning tree). We present a simple automaton with input signature and output signature that computes a (breadth-first) spanning tree of its input graph , rooted at the node with the smallest identifier. More precisely, in the computed output configuration , every node will store the identifier of its tree parent in register and the identifier of the root (i.e., the smallest identifier) in register . Thus, as a side effect, also solves the leader election problem by electing the root as the leader.

The automaton operates in three phases, which are represented by the set of states . A node terminates as soon as it reaches the third phase, i.e., we set . Accordingly, the (trivial) input and output functions are and . In addition to the output registers, each node has an auxiliary register that will always store its own identifier. Thus, we choose . For the sake of simplicity, we describe the transition maker in Algorithm 1 using pseudocode rules. However, it should be clear that these rules could be relatively easily implemented according to Definition 3.

All nodes start in state 1, which represents the tree-construction phase. By , whenever an active node (i.e., a node in state 1 or 2) sees a neighbor whose register contains a smaller identifier than the node’s own register, it updates its and registers accordingly and switches to state 1. To resolve the nondeterminism in , we stipulate that  is chosen to be the neighbor with the smallest identifier among those whose register contains the smallest value seen so far.

As can be easily shown by induction on the number of communication rounds, the nodes have to apply no more than times in order for the pointers in register to represent a valid spanning tree (where the root points to itself). However, since the nodes do not know when rounds have elapsed, they must also check that the current configuration does indeed represent a single tree, as opposed to a forest. They do so by propagating a signal, in form of state 2, from the leaves up to the root.

By , if an active node whose neighbors all agree on the same root realizes that it is a leaf or that all of its children are in state 2, then it switches to state 2 itself. Assuming the pointers in the current configuration already represent a single tree, ensures that the root will eventually be notified of this fact (when all of its children are in state 2). Otherwise, the pointers represent a forest, and every tree contains at least one node that has a neighbor outside of the tree (as we assume the underlying graph is connected).

Depending on the input graph, a node can switch arbitrarily often between states 1 and 2. Once the spanning tree has been constructed and every node is in state 2, the only node that knows this is the root. In order for the algorithm to terminate, then makes the root broadcast an acknowledgment message down the tree, which causes all nodes to switch to the halting state 3.    $$\square$$

Building on the automaton from Example 5, we now give an example of a graph property that can be decided in our model of distributed computing. The following automaton should be compared to the logical formula presented later in Example 8, which is much more compact and much easier to specify.

### Example 6

(Hamiltonian cycle). We describe an automaton with input signature and output signature that decides if the underlying graph of its input configuration is Hamiltonian, i.e., whether contains a cycle that goes through each node exactly once. The automaton works under the assumption that  encodes a valid spanning tree of in the registers and , as constructed by the automaton from Example 5. Hence, by combining the two automata, we could easily construct a third one that decides the graph property of Hamiltonicity.

The automaton presented here implements a simple backtracking algorithm that tries to traverse  along a Hamiltonian cycle. Its set of states is , with the set of halting states . Each non-halting state consists of two components, the first one serving for the backtracking procedure and the second one for communicating in the spanning tree. The input function initializes every node to the state , while the output function simply returns the answers chosen by the nodes, i.e., . In addition to the input registers, each node has a register storing its own identifier and a register to point to its successor in a (partially constructed) Hamiltonian path. That is, . We now describe the algorithm in an informal way. It is, in principle, easy to implement in the transition maker , but a thorough formalization would be rather cumbersome.

In the first round, the root marks itself as and updates its register to point towards its smallest neighbor (the one with the smallest identifier). Similarly, in each subsequent round, any node that is pointed to by one of its neighbors marks itself as and points towards its smallest neighbor. However, if all neighbors are already , the node instead sends the signal to its predecessor and switches back to (in the following round). Whenever a node receives the signal from its , it tries to update its to the next-smallest neighbor. If no such neighbor exists, it resets its pointer to itself, propagates the signal to its predecessor, and becomes in the following round.

There is only one exception to the above rules: if a node that is adjacent to the root cannot find any neighbor, it chooses the root as its . This way, the constructed path becomes a cycle. In order to check whether that cycle is Hamiltonian, the root now broadcast a down the spanning tree. If the reaches an node, that node replies by sending the message towards the root. On the other hand, every leaf replies with the message . While is always forwarded up to the root, is only forwarded by nodes that receive this message from all of their children. If the root receives only , then it knows that the current cycle is Hamiltonian and it switches to the halting state . The information is then broadcast through the entire graph, so that all nodes eventually accept. Otherwise, the root sends the signal to its predecessor, and the search for a Hamiltonian cycle continues. In case there is none (in particular, if there is not even an arbitrary cycle), the root will eventually receive the signal from its greatest neighbor, which indicates that all possibilities have been exhausted. If this happens, the root switches to the halting state , and all other nodes eventually do the same.    $$\square$$

## 4 Functional Fixpoint Logic

In order to introduce functional fixpoint logic, we first give a definition of first-order logic that suits our needs. Formulas will always be evaluated on ordered, undirected, connected, -labeled graphs, where is a fixed finite set of labels.

Throughout this paper, let be an infinite supply of and be an infinite supply of ; we refer to them collectively as . The corresponding set of is generated by the grammar , where and . With this, the set of of over is given by the grammar

where and are terms, , and . As usual, we may also use the additional operators , , , to make our formulas more readable, and we define the notations , , and as abbreviations for , , and , respectively.

The sets of of a term and a formula  are denoted by and , respectively. While node variables can be bound by the usual quantifiers and , function variables can be bound by a partial fixpoint operator that we will introduce below.

To interpret a formula on an -labeled graph with , we are given a for the variables that occur freely in . This is a partial function such that if is a free node variable and if is a free function variable. We call and the of and under , and denote them by and , respectively. For a composite term , the corresponding interpretation under  is defined in the obvious way.

We write to denote that  satisfies  under assignment . If  does not contain any free variables, we simply write and refer to the set  of -labeled graphs that satisfy as the graph property by . Naturally enough, we say that two devices (i.e., automata or formulas) are if they specify (i.e., decide or define) the same graph property and that two classes of devices are equivalent if their members specify the same class of graph properties.

As we assume that the reader is familiar with first-order logic, we only define the semantics of the atomic formulas (whose syntax is not completely standard):

We now turn to . Syntactically, it is defined as the extension of first-order logic that allows us to write formulas of the form

where , , and are formulas. We use the notation “” to emphasize that may occur freely in  (possibly among other variables). The free variables of formula ($$*$$) are given by .

The idea is that the pfp binds the function variables . The  lines in square brackets constitute a system of function definitions that provide an interpretation of , using the special node variables and as helpers to represent input and output values. This is why also binds any free occurrences of and in , but not in .

To specify the semantics of ($$*$$), we first need to make some preliminary observations. As before, we consider a fixed -labeled graph with and assume that we are given a variable assignment  for the free variables of ($$*$$). With respect to  and , each formula  induces an operator that takes some interpretation of the function variables and outputs a new interpretation of , corresponding to the function graph defined by  via the node variables  and . For inputs on which does not define a functional relationship, the new interpretation of behaves like the identity function. More formally, given a variable assignment that extends with interpretations of , the operator maps to the function such that for all ,

Here, is the extension of interpreting as and as .

In this way, the operators give rise to an infinite sequence of tuples of functions, called , where the initial stage contains solely the identity function and each subsequent stage is obtained from its predecessor by componentwise application of the operators. More formally,

for . Now, since we have not imposed any restrictions on the formulas , this sequence might never stabilize, i.e, it is possible that for all $$k \ge 0$$. Otherwise, the sequence reaches a (simultaneous) fixpoint at some position k no greater than (the number of -tuples of functions on ).

We define the of the operators to be the reached fixpoint if it exists, and the tuple of identity functions otherwise. That is, for ,

Having introduced the necessary background, we can finally provide the semantics of the formula presented in ($$*$$):

where is the extension of that interprets as , for . In other words, the formula can intuitively be read as

“if are interpreted as the partial fixpoint of , then  holds”.

### 4.1 Syntactic Sugar

Before we consider a concrete formula (in Example 8), we first introduce some “syntactic sugar” to make using functional fixpoint logic more pleasant.

Set variables. According to our definition of functional fixpoint logic, the operator can bind only function variables. However, functions can be used to encode sets of nodes in a straightforward manner: any set  may be represented by a function that maps nodes outside of  to themselves and nodes inside  to nodes distinct from themselves. Therefore, we may fix an infinite supply of , and extend the syntax of first-order logic to allow atomic formulas of the form , where  is a term and is a set variable in . Naturally, the semantics is that “ is an element of ”. To bind set variables, we can then write partial fixpoint formulas of the form , where , , and are formulas. The stages of the partial fixpoint induction are computed as before, but each set variable  is initialized to , and falls back to in case the sequence of stages does not converge to a fixpoint.

Quantifiers over functions and sets. Partial fixpoint inductions allow us to iterate over various interpretations of function and set variables and thus provide a way of expressing (second-order) quantification over functions and sets. Since we restrict ourselves to graphs whose nodes are totally ordered, we can easily define a suitable order of iteration and a corresponding partial fixpoint induction that traverses all possible interpretations of a given function or set variable. To make this more convenient, we enrich the language of functional fixpoint logic with second-order quantifiers, allowing us to write formulas of the form and , where , , and  is a formula. Obviously, the semantics is that “there exists a function , or a set , respectively, such that  holds”.

As a consequence, it is possible to express any graph property definable in monadic second-order logic, the extension of first-order logic with set quantifiers.

### Corollary 7

When restricted to finite graphs equipped with a total order, functional fixpoint logic is strictly more expressive than monadic second-order logic.

The strictness of the inclusion in the above corollary follows from the fact that even on totally ordered graphs, Hamiltonicity cannot be defined in monadic second-order logic (see, e.g., the proof in [4, Prp. 5.13]). As the following example shows, this property is easy to express in functional fixpoint logic.

### Example 8

(Hamiltonian cycle). The following formula of functional fixpoint logic defines the graph property of Hamiltonicity. That is, an unlabeled graph  satisfies this formula if and only if there exists a cycle in  that goes through each node exactly once.

Here, , , and . Intuitively, we represent a given Hamiltonian cycle by a function that tells us for each node , which of ’s neighbors we should visit next in order to traverse the entire cycle. Thus, actually represents a directed version of the cycle.

To ensure the existence of a Hamiltonian cycle, our formula states that there is a function satisfying the following two conditions. By the first line, each node  must have exactly one -predecessor and one -successor, both of which must be neighbors of . By the second line, if we start at any node  and collect into a set  all the nodes reachable from  (by following the path specified by ), then  must contain all nodes.    $$\square$$

## 5 Translating Between Automata and Logic

Having introduced both automata and logic, we can proceed to explain the first part of Theorem 1 (stated in Sect. 1), i.e., how distributed register automata can be translated into functional fixpoint logic.

### Proposition 9

For every distributed register automaton that decides a graph property, we can construct an equivalent formula of functional fixpoint logic.

### Proof

(sketch). Given a distributed register automaton deciding a graph property  over label set , we can construct a formula of functional fixpoint logic that defines . For each state , our formula uses a set variable  to represent the set of nodes of the input graph that are in state . Also, for each register , it uses a function variable to represent the function that maps each node  to the node  whose identifier is stored in ’s register . By means of a partial fixpoint operator, we enforce that on any -labeled graph , the final interpretations of  and represent the halting configuration reached by on . The main formula is simply

which states that all nodes end up in a halting state that outputs .

Basically, the subformulas  and  can be constructed in such a way that for all , the $$(i + 1)$$-th stage of the partial fixpoint induction represents the configuration reached by in the i-th round. To achieve this, each of the subformulas contains a nested partial fixpoint formula describing the result computed by the transition maker  between two consecutive synchronous rounds, using additional set and function variables to encode the inner configurations of  at each node. Thus, each stage of the nested partial fixpoint induction corresponds to a single step in the transition maker’s sequential scanning process.    $$\square$$

Let us now consider the opposite direction and sketch how to go from functional fixpoint logic to distributed register automata.

### Proposition 10

For every formula of functional fixpoint logic that defines a graph property, we can construct an equivalent distributed register automaton.

### Proof

(sketch). We proceed by structural induction: each subformula  will be evaluated by a dedicated automaton , and several such automata can then be combined to build an automaton for a composite formula. For this purpose, it is convenient to design centralized automata, which operate on a givenspanning tree (as computed in Example 5) and are coordinated by the root in a fairly sequential manner. In , each free node variable  of  is represented by a corresponding input register  whose value at the root is the current interpretation  of . Similarly, to represent a function variable , every node  has a register storing . The nodes also possess some auxiliary registers whose purpose will be explained below. In the end, for any formula  (potentially with free variables), we will have an automaton computing a transduction , where and are supposed to constitute a spanning tree. The computation is triggered by the root, which means that the other nodes are waiting for a signal to wake up. Essentially, the nodes involved in the evaluation of  collect some information, send it towards the root, and go back to sleep. The root then returns  or , depending on whether or not  holds in the input graph under the variable assignment provided by the input registers. Centralizing in that way makes it very convenient (albeit not efficient) to evaluate composite formulas. For example, in , the root will first run , and then in case returns .

The evaluation of atomic formulas is straightforward. So let us focus on the most interesting case, namely when . The root’s program is outlined in Algorithm 2. Line 1 initializes a counter that ranges from 0 to , where n is the number of nodes in the input graph. This counter is distributed in the sense that every node has some dedicated registers that together store the current counter value. Every execution of  will increment the counter by 1, or return  if its maximum value has been exceeded. Now, in each iteration of the loop starting at Line 2, all registers and  are updated in such a way that they represent the current and next stage, respectively, of the partial fixpoint induction. For the former, it suffices that every node copies, for all i, the contents of to (Line 3). To update , Line 4 calls a subroutine whose effect is that for all i, where is the operator defined in Sect. 4. Line 5 checks whether we have reached a fixpoint: The root asks every node to compare, for all i, its registers and . The corresponding truth value is propagated back to the root, where is given preference over . If the result is , we exit the loop and proceed with calling to evaluate  (Line 8). Otherwise, we try to increment the global counter by executing  (Line 6). If the latter returns , the fixpoint computation is aborted because we know that it has reached a cycle. In accordance with the partial fixpoint semantics, all nodes then write their own identifier to every register (Line 7) before  is evaluated (Line 8).    $$\square$$

## 6 Conclusion

This paper makes some progress in the development of a descriptive distributed complexity theory by establishing a logical characterization of a wide class of network algorithms, modeled as distributed register automata.

In our translation from logic to automata, we did not pay much attention to algorithmic efficiency. In particular, we made extensive use of centralized subroutines that are triggered and controlled by a leader process. A natural question for future research is to identify cases where we can understand a distributed architecture as an opportunity that allows us to evaluate formulas faster. In other words, is there an expressive fragment of functional fixpoint logic that gives rise to efficient distributed algorithms in terms of running time? What about the required number of messages? We are then entering the field of automatic synthesis of practical distributed algorithms from logical specifications. This is a worthwhile task, as it is often much easier to declare what should be done than how it should be done (cf. Examples 6 and 8).

As far as the authors are aware, this area is still relatively unexplored. However, one noteworthy advance was made by Grumbach and Wu in [9], where they investigated distributed evaluation of first-order formulas on bounded-degree graphs and planar graphs. We hope to follow up on this in future work.