{'fraction_non_alphanumeric': 0.04180088680031834, 'fraction_numerical': 0.010592337135710766, 'mean_word_length': 4.187241989384706, 'pattern_counts': {'":': 0, '<': 6, '<?xml version=': 0, '>': 8, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 9, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
On the detection and identification of edge disconnections in a multi-agent consensus network

In this paper we investigate the problem of the sudden disconnection of an edge in a discrete-time multi-agent consensus network. If the graph remains strongly connected, the multi-agent system still achieves consensus, but in general, unless the information exchange between each pair of agents is symmetric, the agents' states converge to a drifted value of the original consensus value. Consequently the edge disconnection can go unnoticed. In this paper the problems of detecting an edge disconnection and of identifying in a finite number of steps the exact edge that got disconnected are investigated. Necessary and sufficient conditions for both problems to be solvable are presented, both in case all the agents' states are available and in case only a subset of the agents' states is measured. Finally, an example of a network of 7 agents is provided, to illustrate some of the theoretical results derived in the paper.


I. INTRODUCTION
The technology advances of the last decades brought brand new opportunities in several engineering areas and stimulated a significant thrust of research in communications, information processing and control theory [1], [17], [45], The availability of miniaturized low-cost processing and integrated communication devices allowing peer-to-peer communication pushed a renewed interest in the analysis and design of distributed heterogeneous sensor networks and in the cooperative control of networks of autonomous agents [3], [8].
For a network of agents, consensus is a fundamental target, useful for coordination, and a key tool to achieve decentralized architectures [22], [33], [35]. Consensus refers to the situation when agents achieve a common decision on a local variable, which is updated performing local computation and exchanging local information [22]. Under the assumption that each agent follows a prescribed protocol, the use of such local variable makes the system behave as if the agents were fully connected (i.e. as if the communication graph were complete) [23], and this condition enables a variety of applications in a wide range of fields [6], [19], [34], [36], [42]. However, the adherence of each agent to the agreed protocol may fail for a number of reasons, and several research directions have been explored to achieve robust consensus in the presence of intermittent transmissions, transmission errors, faults or noise [20], [21], [30], [44].
Malfunctions in a network, may be temporary or intermittent, casual or intentional (for instance, they may be the results of a cyber-attack [28]), and a long stream of research G has been devoted to address fault-detection and identification (FDI) problems or fault-tolerant control strategies for multiagent systems, see [30, for an extensive literature review. FDI algorithms for multi-agent systems split into two classes: centralized and distributed ones. In the first case [9], [27], [32], a central unit gathers all the system information to perform the fault diagnosis algorithm. In the distributed case [11], [27], [38], all agents run some local fault detection algorithm, based on local information and on the signals received from neighbouring agents, and they coordinate to decide whether and where the fault occurred.
Most of the literature on FDI for multi-agent systems, however, assumes that faults act additively either on the stateupdate equations or on the signals exchanged by pairs of agents [11], [26], [27], [38]. Even if an edge disconnection can be modelled in this way, this set-up is too general and it does not exploit the correlation between the fault signal and the state evolution that characterizes faults resulting from edge disconnections. As a result, FDI conditions deduced in the general set-up do not exploit the special nature of these faults, thus leading to conservative conditions for a successful and prompt diagnosis when dealing with edge disconnection.
On the other hand, in general, the problem of detecting an edge disconnection has been investigated for multi-agent systems that are not necessarily consensus networks. For instance, in [4] and [29] the possibility of detecting an edge or a node disconnection in a multi-agent system is investigated, and the concepts of discernibility from the states or the outputs are investigated. In [43] the problem of detecting an edge disconnection is addressed for a diffusive network, by resorting to an impulsive input applied at one specific node. Simple graph conditions allow to determine whether the problem is solvable. The residual signal is generated at the specific node by assuming that the whole network topology is known, and it depends on the whole state trajectory. The authors of [9] use stochastic techniques and propose an algorithm based on the full state knowledge to promptly detect abrupt topological changes of the network such as a link failure, creation, or degradation. In [12], [13], [39] the detection of a link disconnection in a network from noisy measurements at a single node is investigated. By making use of a Maximum A Posteriori Probability technique, conditions for asymptotic detection, in terms of the network spectrum and graph, are derived. If the detector does not know the whole state of the system, perfect detection is not possible. Note, also, that none of the previous references explicitly addresses the identification problem.
Few contributions have specifically addressed the problem of detecting and/or identifying a link disconnection in a consensus network, by making use of the network properties and of the very specific change of the network description as it was done in the large majority of the aforementioned references, that the agents represent devices with limited functionalities. In general they have not the capability of detecting an edge disconnection, not even when they are directly affected by it (by this meaning that they are either the transmitter or the receiver at the extremes of the disconnected edge), and hence they cannot send an alarm signal. This assumption is extremely realistic when dealing with large networks of cheap sensors, for instance, whose software is configured to perform very basic tasks. Accordingly, we assume that the detection and identification of a broken edge cannot be performed at local level by means of a distributed algorithm that involves a subset of the agents and we propose centralised algorithms that are able to identify a link disconnection from the knowledge of either the entire state evolution or the state evolution of a subset of its agents. In fact, a distributed FDI is typically possible only under the condition that a selected group of agents is able to both generate a residual signal and to communicate with each other to reach a decision about the occurrence of a fault. This requires additional features with respect to the basic ones that are imposed by the consensus algorithm. In addition to the fact that for certain multi-agent systems, the physical nature of the devices does not offer alternatives, the choice of adopting a centralised approach has several motivations: first of all, what can be obtained in a centralised way always represents a benchmark that distributed solutions try to approach as much as they can, and since a clear analysis of this problem is not available yet in the literature, we believe that this is the first goal to achieve. Secondly, a centralised solution requires weaker properties in terms of observability/reconstructibility than the ones that a distributed solution would impose on the single agents. It is often the case that a wise choice of a small set of agents whose states need to be monitored in a centralised way allows an effective detection and identification, but those same agents would not be able to independently perform FDI. This aspect will be better clarified at the end of the paper. Finally, several distributed FDI algorithms rely on the estimate of the overall state vector, and this is extremely demanding from a computational point of view, as well as not realistic, since it presumes that single agents may have a complete knowledge of the overall system structure. Solutions that require the selected agents to estimate only portions of the state vector typically impose very strong conditions of the structural properties of the overall system and they are strongly dependent on the specific system structure.
The paper structure is the following one. Section II presents the class of discrete-time multi-agent systems and the general setting of the problem. In Section III the effects of the disconnection of a single link are explored. The problem of detecting an edge disconnection is tackled in Section IV, and it is split into four subsections. The discernibility of two networks, one of them obtained from the other as a result of the disconnection of a link, is studied in Subsection IV.A from a theoretical standpoint, assuming that the whole state vector is available for measurement. Some special situations that prevent discernibility are discussed. In Subsection IV.B an algorithm for link failure detection and isolation is introduced and it is shown that, if discernibility conditions are satisfied, the algorithm can detect each fault and isolate it under an additional condition. Section V is devoted to the discernibility problem when only a subset of nodes is available and in Subsection V.A an algorithm for detecting the edge disconnection under these conditions is provided. Also in this case, if discernibility conditions are satisfied, the algorithm is able to detect each fault, while fault isolation is ensured under an additional condition. In Section VI the case of a network of 7 nodes with only three states available for measurement is considered, and the results derived in the paper are illustrated for different edge disconnections.
The results provided in this paper have been inspired by [4], where the concept of discernibility of a multi-agent system from the (faulty) one resulting from an edge or a node disconnection have been first investigated. Compared to [4], we tailor our analysis to a consensus network and hence account for the fact that discernibility in a consensus network does not reduce to the observability of a special matrix pair associated with the healthy and the faulty systems. Indeed, the dominant eigenvalue/eigenvector that ensure consensus do not change after the edge disconnection and need to be separately accounted for. In addition we have explicitly addressed the identification problem and proposed an algorithm to identify which specific link of the system got disconnected. To achieve this goal we have proposed a residual generator that is based on a (full-order) dead-beat observer. This solution has the great advantage of zeroing the effects of the initial conditions in a finite number of steps, thus making it possible to promptly detect an edge disconnection in the minimal number of steps, even when the effects of such a disconnection are small and hence may be erroneously interpreted as the effect of disturbances. This manuscript extends the edge failure analysis first performed in [40] and then summarized in [41] (this latter paper presents some preliminary results about node disconnection and compares such results with those obtained in [40] for the edge disconnection) in the following way. First of all in this paper we address the case of a directed communication graph, rather than an undirected one. While Sections II and III represent slightly modified versions of the original Sections II and III in [40], the analysis in the following sections is sigificantly improved and extended compared to the one presented in [40]. The proof of Proposition 3 is new. The whole part of subsection IV.A, after Remark 6 (in particular, Proposition 7), and subsection IV.B (in particular, Proposition 8) are original. Since this last part deals with the problem of providing a method to detect and identify the specific edge that got disconnected, we believe that there is a significant added value with respect to the original conference paper [40]. Also, the proof of Proposition 9 in Section V is original, and the whole Subsection V.A, providing conditions for fault detection and identification of an edge disconnection when only a subset of the states is available, is original. Finally, Section VI provides a useful illustrative example and is new. We believe that the current results provide a first meaningful step toward the final goal of first determining necessary and sufficient conditions for detecting and identifying all kinds of edge/mode faults, for general classes of homogeneous multiagent systems, and then designing practical algorithms to perform their detection and identification.
Notation. Z + and R + denote the set of nonnegative integer and real numbers, respectively. Given k, n ∈ Z + , k < n, we denote by [k, n] the set of integers {k, k + 1, . . . , n}. We let e i denote the i-th element of the canonical basis in R k (k being clear from the context), with all entries equal to zero except for the i-th one which is unitary. 1 k and 0 k denote the k-dimensional real vector whose entries are all 1 or all 0, respectively. Given a real matrix A, the (i, j)-th entry of A is denoted either by a ij or by [A] ij , and its transpose by A . Given a vector v, the i-th entry of v is denoted by v i or by [v] i . The spectrum of A ∈ R n×n , denoted by σ(A), is the set of its eigenvalues and the spectral radius of A, denoted by ρ A , is the maximum modulus of the elements of σ(A). For a nonnegative matrix A ∈ R n×n + , i.e., a matrix whose entries are nonnegative real numbers, the spectral radius is always an eigenvalue. A nonnegative and nonzero matrix is called positive, while a matrix whose entries are all positive is called strictly positive. Nonnegative, positive and strictly positive vectors are analogously defined. A positive matrix A ∈ R n×n + , n > 1, is irreducible if no permutation matrix P can be found such that where A 11 and A 22 are square (non-vacuous) matrices. By the Perron-Frobenius theorem [5], [15], [22], for an irreducible positive matrix A the spectral radius ρ A is a simple real dominant eigenvalue, and the corresponding left and right eigenvectors are strictly positive. Positive eigenvectors of a positive irreducible matrix necessarily correspond to the spectral radius. A path connecting j and i is an ordered sequence of arcs (j, i 1 ), (i 1 , i 2 ), . . . , (i k−1 , i k ), (i k , i) ∈ E. A directed (resp. undirected) graph G is strongly connected (connected) if, for every pair of vertices j and i, there is a path connecting them. G is strongly connected (connected) if and only if its (symmetric) adjacency matrix W is irreducible. The Laplacian matrix [16] associated with the adjacency matrix W is defined as L := C − W, where C is the (diagonal) connectivity matrix, whose diagonal entries are the sums of the corresponding row entries of W, namely Clearly, by the way the Laplacian has been defined L1 N = 0 N . Also, L is irreducible if and only if W is irreducible. If G is undirected then the associated Laplacian L is symmetric.
is called a partition of the vertex set V. When so, V i is called the i-th cell of the partition π, and the vector x ∈ R N satisfying x = 1 if ∈ V i and x = 0 if / ∈ V i , i.e., x = ∈Vi e , is called the characteristic vector of the i-th cell V i . Finally, the matrix P π ∈ R N ×k , whose i-th column is the characteristic vector of the subset V i is called the characteristic matrix of π.

II. PROBLEM SETUP
Consider a multi-agent system consisting of N > 2 agents, each of them indexed in the integer set [1, N ]. The state of the i-th agent is described by the scalar variable x i that updates according to the following discrete-time linear statespace model [23]: where v i is the input of the i-th agent. The communication among the N agents is described by a fixed directed graph G with adjacency matrix adopts the (nearest neighbor linear) consensus protocol [23], which amounts to saying that the input v i takes the form: where κ > 0 is a given real parameter known as coupling strength 1 . If we stack the states of the agents in a single state vector x ∈ R N , the overall multi-agent system becomes where L = [ ij ] ∈ R N ×N is the Laplacian associated with the adjacency matrix W. It is easy to deduce the relationship between eigenvalues λ A ∈ σ(A) and λ L ∈ σ(L), namely In particular, System (2) can be used to describe a wide variety of situations where each agent/node shares information with its neighbours with the final goal of converging to a common decision. If so, we refer to the multi-agent system as to a consensus network. More formally, system (2) is a consensus network if for every initial state The constant α is called the consensus value [22] for system (2), corresponding to the given initial state. If the agents' communication graph is strongly connected, namely the Laplacian L is irreducible [22], and the coupling strength κ satisfies the following constraint: ii being the i-th diagonal entry of L, system (2) is a consensus network (see Theorem 2 in [22]). Moreover, the consensus value is where w A is the left eigenvector of A corresponding to 1 and satisfying w A 1 N = 1. In the special case when the graph is undirected and hence L and A are symmetric, w A = 1 N 1 N and hence the consensus value is the average value of the agents' initial conditions. Assumption 1. In the following we steadily assume that L is irreducible and κ satisfies the inequalities in (5). Consequently, A = I N −κL is a positive irreducible matrix. Perron-Frobenius theorem and condition A1 N = 1 N ensure that 1 is a simple dominant eigenvalue of A. The eigenspace associated with the unitary eigenvalue is 1 N , and the positive eigenvectors of A necessarily correspond to λ = 1 and hence belong to 1 N .
In this paper we investigate the effects of an edge disconnection on a consensus network, and the possibility of detecting and identifying such a failure.

III. CONSENSUS AFTER AN EDGE DISCONNECTION
If the communication from agent r to agent h is interrupted, namely the arc (r, h), r = h, is disconnected, then the LaplacianL of the new digraph 2Ḡ is related to the Laplacian L = [ ij ] of the original digraph G by the relationship where hr = −[W] hr < 0. Consequently, the new state-update matrix of the multi-agent system becomes In the specific case when the graph is undirected, the disconnection of the arc (r, h) implies also the disconnection of the arc (h, r). Consequentlȳ If the edge disconnection compromises the agents' mutual exchange of information, to the extent of destroying the graph connectivity, then consensus will not be reached, and the effects of the fault on the network will make fault detection eventually possible. On the other hand, an edge disconnection that does not affect the graph connectivity, will allow the system to still reach consensus but on a different value from the original one, and the fault may hence go unnoticed and seriously affect the system functioning. For these reasons, in this paper we will investigate the effects of a single edge disconnection by assuming that the strong connectedness of the communication graph is preserved after the failure. The following proposition, that makes use of some results derived in [23] for consensus networks with switching topologies, highlights that under this assumption we still have a consensus network, but in general the consensus value is preserved after the disconnection only if the communication graph is undirected.
Proposition 1. Let L be the Laplacian of a strongly connected graph G, and set A := I N − κL, where κ > 0 is a fixed coupling strength, that has been chosen in order to ensure that system (2) is a consensus network. LetL be the Laplacian of the graphḠ, obtained from G by removing the arc (r, h), and setĀ := I N − κL. IfḠ is still strongly connected, then i) the system and every time τ ≥ 0 at which the edge disconnection may occur, the new network converges to the same consensus value to which the original network would have converged before the disconnection; iii) if the graph G is directed, then for every τ ≥ 0 there are initial states x(0) corresponding to which the consensus value obtained by the new network, after the disconnection at t = τ , differs from the original one (6).
Proof. i) Since the original network is a consensus network, L is irreducible and κ satisfies the constraint (5). On the other hand, by assumption, the LaplacianL is still irreducible and if we denote by¯ ij the (i, j)-th entry ofL, then max i∈[1,N ]¯ ii ≤ max i∈ [1,N ] ii , thus ensuring that This is the case for both directed and undirected graphs. Consequently, also the new network is a consensus network. ii) and iii) Follow from the results obtained in [23] (see for instance Theorems 4 and 9) for the consensus of continuoustime systems described as integrators and with switching communication topologies.

IV. DETECTING AN EDGE DISCONNECTION
In the rest of the paper we will focus on the case when the communication graph is directed, and investigate in detail under what conditions we can detect the edge disconnection. We will also steadily make the following assumption. Assumption 2. The graphḠ, describing the communication network after the link failure, is strongly connected, and hencē A is still a positive irreducible matrix having 1 as dominant eigenvalue and 1 N as dominant eigenvector.
We distinguish the case when we can observe the states of all the agents and the case when we can observe the states of a subset of the agents. We also adjust the definitions introduced in [4] (for the continuous-time case), to keep into account that if the system has already reached consensus, which is an equilibrium point for both the original network and the faulty one, then every edge disconnection will not alter the consensus status, and hence will produce a fault that is necessarily undetectable. Consequently, we introduce the following definitions. Definition 1. Consider the multi-agent consensus network (2), and the network obtained from (2) upon disconnection of the edge from agent r to agent h: withĀ described as in (7). The two networks are said to be discernible if for every fault time τ ≥ 0 and every state x(τ ) ∈ 1 N , there exists t > τ such that the state trajectory of the faulty system (9) at time t, x(t) =Ā t−τ x(τ ), is different from the state trajectory of the original system at time t.
If only the states of p < N agents are available, and we assume without loss of generality that they are the first p agents, we say that the two networks are discernible from the observation of the first p agents if for every fault time τ ≥ 0 and every state x(τ ) ∈ 1 N , the first p entries of any state trajectory of the faulty system (9) at time t ≥ τ , x(t) =Ā t−τx τ , are different from the first p entries of the state trajectory of the original system at time t for at least one time instant t, namely for everyx τ ∈ R N there exists t ≥ τ such that Remark 2. If the edge fault is the outcome of an external attack, it is immediate to realise that the concept of discernibility is in perfect agreement with the property of a cyberphysical system to not be subjected to undetectable attacks, explored in [28]. Note that the concept of discernibility here adopted, and suitably adapted from the one given in [4], is different from the concept of "detectabilty" (of an edge) adopted in [31] that only requires that the state trajectories of the healthy and the faulty systems differ for at least one choice of the initial condition. Finally, discernibility is introduced here as a system theoretic property with exact definition and mathematical characterisation. It is clear that in a real-life environment, we need to account for disturbances and modeling errors, that require to modify the previous theoretical condition (10) to introduce a minimal threshold below which the disagreement of the measured output with respect to the expected one is not interpreted as the effect of a fault.

A. Discernibility after edge disconnection
In order to characterize discernibility, we may exploit the analysis in [4], that refers to the matrices (11) It is worth observing, however, that discernibility analysis in [4] is carried out for homogeneous multi-agent systems, whose agents are generically described by the same linear state-space model, and it is defined in such a way that it coincides with the observability property of the pair (∆, Γ N ). Observability, however, is impossible to guarantee when the matrices A and A are expressed in terms of the Laplacian as in (2) and (8), and this is quite reasonable since the lack of observability is related to the fact that if the disconnection happens when the network is already in its steady state, then the fault cannot be detected, since the constant trajectory α1 N is compatible both with the original network and with the faulty one. We have modified the two definitions of discernibility just to rule out this case, that is unavoidable and cannot be regarded as a sign of bad performance. Clearly, this will lead to different characterizations of the two discernibility properties.
We can now provide the following result, that adjusts and extends the one given in Theorem 1 of [4]. are those in 1 N and they correspond to the unitary eigenvalue; iv) there is no eigenvalue-eigenvector pair (λ, v), with λ ∈ C and v = 0, except for λ = 1 and v ∈ 1 N , such that v) there is no eigenvalue-eigenvector pair (λ, v), with λ ∈ C and v = 0, common to A andĀ, except for λ = 1 and v ∈ 1 N .
Proof. i) ⇔ ii) Suppose that the networks (2) and (9) are not discernible. Then there exist x(0) ∈ 1 N such thatĀ t x(0) = A t x(0) for every t ≥ 0. This is equivalent to saying that is not observable for the pair (∆, Γ N ) and it does not belong to 1 2N . Conversely, suppose that there exists an unobservable state for every t ≥ τ , thus ruling out discernibility. ii) ⇔ iii) Condition ii) is easily seen to be equivalent to the following condition, expressed in terms of PBH observabilty then λ = 1 and v v ∈ 1 2N . Similarly, condition iii) is equivalent to saying that if λ ∈ C and v = 0 exist such that then λ = 1 and v ∈ 1 N . On the other hand, it is easily seen that (13) is equivalent to namely to Av = λv, Av = λv, and due to the relation between A andĀ, the previous two identities are, in turn, equivalent to that can be expressed in terms of the PBH observability criterion as in (14). This proves ii) ⇔ iii). iii) ⇔ iv) Obvious. iv) ⇔ v) It is easily seen that (12) holds if and only if Av = λv =Āv. So, the equivalence immediately follows.
Remark 4. Conditions ii), iii) and iv) in Proposition 3 could be equivalently expressed in terms of the matrices L andL (instead of A andĀ), and by replacing λ A = 1 with λ L = 0.
In the following, we consider some special cases of matrices A (or, equivalently, graph Laplacians L) for which condition iv) in Proposition 3 is violated. These situations rule out in advance discernibility.
If there exists λ ∈ σ(A), λ = 1, of geometric multiplicity greater than 1, then an eigenvector of A corresponding to λ can be found such that condition (12) is satisfied thus making the old network and the new network not discernible. So, a necessary condition for discernibility is that all the eigenvalues of A have unitary geometric multiplicity (A is cyclic [37] or, equivalently, non-derogatory [10]).
Lemma 5. If A has an eigenvalue λ = 1 of geometric multiplicity greater than 1, then there exists an eigenvector v corresponding to λ such that condition (12) holds.
Proof. If λ ∈ σ(A), λ = 1, has geometric multiplicity greater than 1, then there exist 2 linearly independent eigenvectors, say v 1 and v 2 , corresponding to λ. Suppose that neither of these eigenvectors has the r-th and the h-th entries that coincide.
If M r,h is nonsingular, there exist a 1 , a 2 ∈ R \ {0} such that In both cases the eigenvector v : Remark 6. If the graph G is undirected, A is symmetric and hence diagonalizable. Therefore algebraic multiplicities and geometric multiplicities coincide. So, a necessary condition for discernibility is that the N eigenvalues of A are all distinct.
We now further explore condition (12) of Proposition 3 and connect it to a topological condition on G. To this end, we need to introduce the concept of nontrivial almost equitable partition for a directed weighted graph G, by extending the analogous notion given for undirected unweighted graphs in [14]. Given a directed weighted graph G = (V, E, W), a partition π = {V 1 , .., V k } of the set of vertices V = [1, N ] is said to be an equitable partition for G if for every pair of cells V i , V j , i, j ∈ [1, k], and every node v of V i , the sum of the weights of all edges from the nodes in V j to the node v is a constant value that depends only on i and j, not on v. The partition π is said to be an almost (or relaxed) equitable partition if the above condition holds for every pair (i, j), i, j ∈ [1, k], with j = i.
In formal terms, a partition π is an almost equitable partition for the directed weighted graph G if for every V i , V j , i, j ∈ This amounts to saying that u∈Vj vu = d ij for every v ∈ V i and every j = i. Clearly, d ij < 0. Note that for any directed weighted graph G, two trivial almost equitable partitions always exist, namely (1) the one corresponding to k = 1 and V 1 = V, and (2) the one corresponding to k = N and each V i consisting of a single distinct node. In the following, when talking about almost equitable partitions, we will always rule out the two trivial ones.
The fact that u∈Vj vu = d ij for any v ∈ V i and j = i suggests that it is possible to define (an adjacency matrix and hence) a Laplacian L π ∈ R k×k for G, associated with π, as follows [7]: We now provide the following result that extends the analogous one for undirected unweighted graphs derived in [7].
Proposition 7. Given a directed weighted graph G = (V, E, W), let π = {V 1 , .., V k } be a partition of the set of vertices V and let P π be the characteristic matrix of π (see Notation in Section I). If π is a (nontrivial) almost equitable partition, then: i) LP π = P π L π ; ii) the spectra of L π and L satisfy σ(L π ) ⊂ σ(L) and the associated eigenvectors are related as follows u ∈ ker(λI k − L π ) ⇒ P π u ∈ ker(λI N − L); (18) iii) ∀λ ∈ σ(L π ) ⊂ σ(L), ∃v ∈ ker(λI N − L) such that ∀j ∈ [1, k] Proof. i) Set n i := |V i |, i ∈ [1, k]. It entails no loss of generality assuming that V 1 = [1, It is easily seen that It is immediate then to see that i) holds. ii) Let λ be arbitrary in σ(L π ). If u is an eigenvector of L π corresponding to λ, then L π u = λu. So, by making use of point i), we get LP π u = P π L π u = λP π u. This shows that λ ∈ σ(L) (and hence σ(L π ) ⊂ σ(L)), and that P π u is an eigenvector of L corresponding to λ. iii) By point ii) it is immediate to see that for every eigenvalue λ of L π there exists an eigenvector v of L corresponding to λ, taking the form v = P π u. Such an eigenvector clearly satisfies (19).
To highlight the impact of this condition on our objectives, consider Fig.1. As a consequence of Proposition 7, the multiagent system whose communication graph is depicted in Fig. 1 is subject to undetectable edge failures, which are highlighted in red. Indeed, according to Proposition 3 point iv), the failure of every link (r, h) such that the matrix A has an eigenvector (corresponding to some non-unitary eigenvalue) whose r-th and h-th entries coincide is not detectable because it produces a faulty network which is not discernible from the original one. If r and h belong to the same i-th cell of an almost equitable partition then it follows directly from Proposition 7 that for every non-unitary eigenvalue of A, related through (3) to a nonzero eigenvalue of L π , there exists an eigenvector of A whose r-th and h-th entries coincide.
Some of these undetectable links are critical and their failure may significantly change the network structure, as for example egde (1, 2) whose failure affects the network strong connectivity.

B. How to detect and identify an edge disconnection when the whole state vector is available
If the states of all the agents are available, it is possible to easily implement a residual based fault detection scheme to detect the disconnection of the edge (r, h). Specifically, assume, first, for the sake of simplicity that all the eigenvalues of A are real and that the Jordan form of A is where J i , i ∈ [2, n], is an elementary Jordan block (of size k i,max ) corresponding to the eigenvalue λ i , with |λ i | < 1. Note that we do not assume that λ i = λ j for i = j, but each λ i corresponds to a specific chain of generalised eigenvectors v i , is a generalised eigenvector of order k of A corresponding to λ i . Let T ∈ R N ×N be the nonsingular transformation matrix with columns Considering (20) and (22), it is easy to verify that W A − J A W = 0. Consequently, as far as the system is correctly functioning, namely x(t) = Ax(t−1), then the residual signal is identically zero. In the case when the matrix A has also complex conjugate eigenvalues, then we can follow the same procedure and reasoning as above, by replacing the Jordan form with the real Jordan form, and hence pairing together pairs of complex conjugate eigenvalues and replacing pairs of complex generalised eigenvectors of some order with equivalent pairs of real generalised eigenvectors of the same order (see e.g. [18], Section 3.4.1). The details are a little bit more involved from a notational viewpoint, but the substance of the result does not change. For this reason, we omit the details. We want to show, now, that under the discernibility assumption, unless x(τ ) ∈ 1 N , namely the disconnection of the edge (r, h) takes place at a time t = τ when the multi-agent system has already reached consensus, then it is not possible that r(t) is identically zero for t > τ . This allows one to detect the disconnection of the edge (r, h). Additionally, we propose conditions that ensure that the edge disconnection is not only detected but also identified, namely the specific broken edge can be identified from the sequence of residual vectors. To this end, it is convenient to replace the original notationĀ for the state-space matrix after disconnection with a more specific notation that indicates which specific edge got disconnected. Accordingly, we introduce the following notation: which is the state matrix of the system once the edge (j, i) gets disconnected for some i, j ∈ [1, N ], i = j, (in particular, for (j, i) = (r, h)). Proposition 8. Consider the networks (2) and (9), this latter obtained from the former after the disconnection of the edge (r, h) at some time t = τ . If Assumptions 1-2 hold, and the networks (2) and (9) are discernible (i.e., one of the equivalent conditions of Proposition 3 holds), then, unless x(τ ) ∈ 1 N , namely the network has already reached consensus, there exists t ∈ [τ + 1, τ + N ] such that r(t) = 0. Moreover, if for every j ∈ [1, N ] \ {r, h} (and not only for j = r), the following conditions hold: (i) the faulty network obtained by disconnecting (j, h) is still strongly connected and discernible from the original network, then it is possible to identify from the residual signal the edge (r, h) that got disconnected.
Proof. If the disconnection of edge (r, h) takes place at t = τ , then for every k ≥ 1 where we used the identitiesĀ hr = A − κ hr e h [e h − e r ] and W A −J A W = 0. Therefore r(τ + k) = 0 for every k ≥ 1 if and only if x(τ ) ∈ kerW hr , where This amounts to saying that there exist λ ∈ C and v = 0 such that the PBH observability matrix satisfies but this is easily seen to be equivalent to the existence of λ ∈ C and v = 0 such that and therefore to the existence of λ ∈ C and v = 0 such that Discernibility assumption rules out the possibility that the previous condition holds unless λ = 1 and v ∈ 1 N . On the other hand, if the previous condition holds only for λ = 1 and v ∈ 1 N , this means that x(τ ) ∈ 1 N , namely the disconnection had taken place after the network had reached consensus, a situation in which detection is not possible. This proves that there exists k ∈ [1, N ] such that r(τ + k) = 0.
Now we want to prove that under the assumptions that: (i) the disconnection of any edge (j, h) results in a new strongly connected network, discernible from the original one, and (ii) condition (23) holds, it is possible to uniquely identify the broken link from the residuals. By the previous part of the proof, if the disconnection takes place at t = τ and x(τ ) ∈ 1 N , then at least one of the values r(τ +k), k = 1, 2, . . . , N, must be nonzero. Set Then r(τ + k * ) = c k * · W e h , where By Lemma 12 in the Appendix, we can claim that this vector uniquely identifies the index h, namely one of the extremes of the edge that got disconnected. We now note that . . .
We have just proved that we can uniquely identify W e h from the first nonzero residual. Moreover, the block diagonal matrix having W e h as diagonal block is clearly of full column rank, and hence the vector Y = 0 such that . . .
is uniquely determined. Now, we want to show that under assumptions (i) and (ii) we can uniquely identify the index r such that If this were not the case, then there would be another index j = r (and j = h) such that and hence there would be two nonzero vectors z r and z j such that Clearly, neither z r nor z j can belong to 1 N , otherwise Y would be zero. Condition corresponds to saying that the unobservable subspace of the matrix pair includes the vector z r z j ∈ 1 2N . Clearly, by the irreducibility assumption onĀ hr andĀ hj , this cannot be an eigenvector corresponding to λ = 1. On the other hand, the fact that z r and z j are both nonzero implies that there is an eigenvalue λ = 1 common to σ(Ā hr ) and σ(Ā hj ). But this contradicts assumption (ii), and hence r is uniquely determined.
We want now to sketch an algorithm to identify the edge (r, h) that got disconnected. Suppose that at t = τ the edge (r, h) gets disconnected and that the first nonzero residual after t = τ is r(τ + k * ) = c k * · W e h , with k * > 0 and c k * = 0 defined as in (26) and (27), respectively. By the previous reasoning, we can claim that there exists a unique value of h ∈ [1, N ] such that r(τ + k * ) ∈ W e h , and this allows to uniquely identify h and hence the coefficient c k * . From the knowledge of h and c k * one can infer the identity of r by comparing the state value of each in-neighbour of h with the state value of the same node which produces the residual r(τ + k * ). Since it must hold r must belong to the following set If |R k * | = 1, then r is identified at the first step. If not, one can evaluate the set R k * +1 and then the intersection R k * ∩R k * +1 . By proceeding in this way, based on the previous proof, this procedure identifies in a finite number of steps the value of the index r that represents the first extreme of the edge that got disconnected, since there exists 0 ≤ d ≤ 2N − 1 such that the set ∩ d i=0 R k * +i consists of a single element. We now explore the more interesting case of discernibility from the observation of the first p agents.

V. DISCERNIBILITY FROM THE OBSERVATION OF THE
FIRST p AGENTS AFTER EDGE DISCONNECTION By referring to the second part of Definition 1, it is easily seen that discernibility of the two systems from the observation of the first p agents imposes the observability of the original system. If not, condition (10) would be contradicted for any unobservable state x(τ ) and x τ = 0. On the other hand, the lack of observability of the faulty system could lead to some pathological situations, since the output measurements could possibly lead to believe that the faulty network has already reached the consensus to some constant value, while it is still evolving. So, in the following we will assume: Assumption 3. Both the original system and the faulty one are observable from the first p agents, namely both (A, I p 0 ) and (Ā hr , I p 0 ) are observable.
Under this assumption, we will characterise discernibility from the observation of the first p agents in terms of the matrix pair (∆, Γ p ), with It is worth noticing that since A is a positive irreducible matrix, having 1 N as dominant eigenvector corresponding to the unitary eigenvalue, clearly 1 is always an observable eigenvalue of the pair (A, I p 0 ), and hence if the pair would not be observable, the eigenvalues of the non-observable subsystem would necessarily have modulus smaller than 1. The same reasoning applies toĀ hr , as far as it remains irreducible. Finally, the irreducibility assumption on both A andĀ hr ensures that the eigenspace of both A andĀ hr corresponding to λ = 1 is 1 N . So, the only unobservable eigenvectors of (∆, Γ p ) corresponding to the unitary eigenvalue are those belonging to 1 2N . Assumption 3 and the previous comments are fundamental to derive the following result, that extends Proposition 3 in [4].
Proposition 9. Consider the networks (2) and (9), this latter obtained from the former after the disconnection of the edge (r, h), and assume that Assumptions 1, 2 and 3 hold. The following facts are equivalent: i) the networks (2) and (9) are discernible from the observation of the first p agents; ii) the unobservable states of the pair (∆, Γ p ) are those in 1 2N and they correspond to the unitary eigenvalue; iii) for every λ ∈ σ(A) ∩ σ(Ā hr ), λ = 1, iv) there are no λ ∈ C and nonzero vectors v,v, except for λ = 1 and v =v ∈ 1 N , such that Av = λv,Ā hrv = λv Proof. i) ⇔ ii) Suppose that the networks (2) and (9) are not discernible from the observation of the first p agents. Then there exist x(0) ∈ 1 N andx 0 ∈ R N such that I p 0 Ā t x 0 = I p 0 A t x(0) for every t ≥ 0. This is equivalent to saying that x(0) x 0 , which does not belong to corresponding to some λ = 1 and satisfying Note that Assumption 3 ensures that both v 1 and v 2 are nonzero vectors. Since v 1 ∈ 1 n , if λ is real then we have found a state that contradicts discernibility from the observation of the first p agents. If λ is complex then we can simply use the real part of v 1 to disprove discernibility from the observation of the first p agents. ii) ⇔ iii) Condition ii) is easily seen to be equivalent to the following condition, expressed in terms of PBH observabilty then λ = 1 and v v ∈ 1 2N . Clearly any such λ must be in σ(∆). On the other hand, if λ would not be a common eigenvalue of A andĀ hr then either v orv would be zero and this would mean that either (A, I p 0 ) or (Ā hr , I p 0 ) are not observable. This would contradict Assumption 3. Therefore we have proved that ii) is equivalent to iii). iii) ⇔ iv) Obvious.
Remark 10. If the networks (2) and (9) are discernible from the observation of the first p agents, they are discernible. If not, a state x ∈ 1 N could be found such thatĀ t hr x = A t x for every t ≥ 0, and hence a fortiori I p 0 Ā t hr x = I p 0 A t x for every t ≥ 0. This implies that a necessary condition for discernibility from the observation of the first p agents is that all the nonunitary eigenvalues of A andĀ hr have unitary geometric multiplicity.
A. How to detect and identify an edge disconnection when the states of the first p agents are available Also in this case we may detect an edge disconnection by making use of the measurements of the states of the first p agents. Since the pair (A, I p 0 ) is observable, let L be a matrix in R N ×p such that A + L I p 0 is nilpotent. We can construct the closed-loop dead-beat observer of the state of the multi-agent system [24] aŝ Clearly, after a finite number of steps τ 0 3 that depends on the nilpotency index of A + L I p 0 , we havex(t) = x(t), and hence the residual signal is identically zero from t = τ 0 onward until a fault occurs. Now suppose that at t = τ ≥ τ 0 the disconnection of the edge (r, h) takes place 4 , and hence the multi-agent state updates according to (9). We want to show that, unless the multi-agent system has already reached consensus, under Assumptions 1, 2 and 3 and any of the equivalent conditions of Proposition 9 the residual signal will necessarily become nonzero at some time instant t > τ . 3 By exploiting the observability of the pair (A, Ip 0 ) and Rosenbrock's theorem, we can claim that the minimum τ 0 ranges in the interval N p , N − p + 1 . 4 In the transient phase, until the estimation error goes to zero, the residual signal may be not zero. As a result it is not possible to detect an edge disconnection in a reliable way. This is the reason why a dead-beat observer is preferable over an asymptotic observer, since this transient phase lasts a finite number of time instants.
To this goal it is sufficient to show that for the system obtained by putting together (9) and (32), namely the only unobservable states are those in 1 2N . Consider the PBH observability matrix By resorting to elementary operations on the rows of the matrix, it is easily seen that the previous matrix is of full column rank for λ ∈ C if and only if the PBH observability matrix  is of full column rank for that λ. Moreover when both PBH matrices have not full column rank, they have the same kernel. By the assumption that (2) and (9) are discernible from the observation of the first p agents it follows (see condition iii) of Proposition 9) that (36) is of full column rank for every λ = 1 and for λ = 1 its kernel is 1 2N . Therefore, the only unobservable states of the overall system are those in 1 2N , and this implies that the residual r(t) cannot remain zero after an edge disconnection. We now want to show that, under suitable assumptions, one can deduce from the residual the exact information about which edge got disconnected.
Proposition 11. Consider the networks (2) and (9), this latter obtained from the former after the disconnection of the edge (r, h) at some time t = τ ≥ τ 0 . Assume that for every edge (j, i), i, j ∈ [1, N ], j = i, (and not only for (j, i) = (r, h)) (i) the faulty network obtained by disconnecting (j, i) is strongly connected and discernible from the original network based on the observation of the first p states, (ii) Assumption 3 holds and hence (A, I p 0 ) and (Ā ij , I p 0 ) are observable, and (iii) Then, unless x(τ ) ∈ 1 N , namely the network has already reached consensus, it is possible to identify from the residual signal r(t), t ≥ τ , generated by (34), the edge (r, h) that got disconnected.
Proof. To prove that the previous observer-based residual generator produces distinct residual sequences corresponding to different faulty systems (provided that x(τ ), the state of the multi-agent system at the time of edge disconnection, is not in the equilibrium, yet, namely it is not a multiple of 1 N ), it is sufficient to prove that if (r, h) = (j, i) then the two systems generate distinct residual trajectories, provided that neither of them has already reached the equilibrium at the time the disconnection occurs. This amounts to saying that the only unobservable states of the system taking the form By making use of the PBH observability matrix: it is easily seen that a vector with the previous block structure belongs to the kernel of (39) for λ = 1 if and only if v hr is a common eigenvector (corresponding to λ = 1) of A andĀ hr and v ij is a common eigenvector (corresponding to λ = 1) of A andĀ ij . Therefore the overall vector belongs to On the other hand, if λ ∈ σ(Ā hr ), λ = 1, then it is easy to see that under the hypothesis (37) and by the observability of (A L , I p 0 ), we have λ ∈ σ(A ij ), and therefore it must be v ij = 0. But this means that v hr v hr should belong to the kernel of (35), but for λ = 1 the matrix (35) is of full column rank. Analogous reasoning holds if λ ∈ σ(Ā ij ), λ = 1.

VI. AN ILLUSTRATIVE EXAMPLE
We now apply the previous results to the case of a network of 7 agents, whose communication graph is depicted in Figure  2 assuming that each agent is described as a discrete-time integrator and runs the algorithm (1) with κ = 0.25. All the weights of the graph are equal to 1. The set of the observed nodes is {1, 2, 3}, and we apply the strategy described in Section V. The resulting system matrix is and it is easily verified that the pair (A, I 3 0 ) is observable. A dead beat state observer has been derived following three  (40) It is worth noticing that there is a transient phase, due to the presence of an estimation error, consisting of 3 time steps, after which the residual becomes zero (i.e., τ 0 = 3). Two simulation results are plotted in Figure 3. The three curves represent, in both cases, the multi-agent system outputs, namely the states of the first three agents. On the other hand, instead of reporting the values of the residual r(t), we have chosen to represent with black circles the detection signal d(t) which is unitary if r(t) = 0 and 0 if r(t) = 0. In both simulations we have disconnected the edge (6,5) in the interval [10,14], and the edge (5,7) in the interval [20,24]. It is worth noticing that A andĀ 7,5 do not have common eigenvalues (apart from 1), so the original and the faulty networks are discernible, while A andĀ 5,6 have λ = 0.5 and the corresponding eigenvector in common, so this case fails to satisfy condition (v) of Proposition 3 and, in turn, condition (iv) of Proposition 9 and condition (i) of Proposition 11.
In the first simulation, corresponding to the upper plot of Figure 3, it is assumed x(0) = [10 − 1 1 8 5 5 12] and x(0) = 0. After an initial transient of 3 steps, the estimated statex(3) is equal to the real state x(3) (while x(t) =x(t) for t < 3, and this is the reason why the estimation signal is nonzero), and the detection signal is zero up to t = 11 when the disconnection of the edge (6, 5) is detected. Then the link is restored, and the disconnection of the edge detection signal is zero up to time t = 22, when the second edge disconnection is detected, and this shows that the first link disconnection remains undetected because of the special structure of the graph topology and the specific value of the system state at the time of the disconnection.

VII. CONCLUSIONS
In this paper we have addressed the problem of detecting and identifying an edge disconnection in a discrete-time consensus network, by assuming that the link failure does not compromise the strong connectedness of the underlying directed communication network. The cases when the states of all the agents are available and when only a proper subset of them is available are both considered, and sufficient conditions ensuring that the problem is solvable are provided. An example concludes the paper, illustrating both the case when detection from the measurement of the states of 3 of the 7 agents is possible and the case when it is not.
It is worth noticing that we have solved the discernibility problem from the first p states by resorting to a full order deadbeat observer, but due to the structure of the state to output matrix the use of a reduced-order dead-beat observer would be straightforward, and it would ensure the same performance in terms of nilpotency index.
Future research efforts will aim at finding an algorithm to efficiently identify the disconnected edge when only p of the N states are available, as it has been done here in the case when all the agents are measured. Also, the case of noisy measurements and/or modelling errors needs to be addressed.
As mentioned in the Introduction, distributed fault detection and identification algorithms have been proposed by assuming that faults are additive. It would be of extreme interest to adapt such algorithms to the specific case when the fault is an edge disconnection, without losing the information about the specific nature and structure of the fault.
APPENDIX: A TECHNICAL LEMMA Lemma 12. Consider the positive irreducible matrix A = I N − κL ∈ R N ×N and let J A be its (real) Jordan form. Let T ∈ R N ×N be the nonsingular transformation matrix such that Since T is a nonsingular matrix, there exists a vector c = 0 such that αe i + βe h = T c. By replacing this expression in the previous identity we obtain This amounts to saying that c = γe 1 for some γ = 0 and αe i + βe h = T γe 1 = γ1 N . But this is clearly not possible, since the vector on the left hand side has two nonzero entries, while the one on the right hand side has all nonzero (and identical) entries.