Abstract
Distributed consensus building promises to improve the robustness and reliability of sensor networks and thus is an active topic of research. Whereas extensive study has been done on the theoretical analysis of the asymptotic behavior of consensus building, one important issue that is crucial to the practical implementation of sensor networks was rarely explored, namely, the criteria to determine whether consensus has been attained. In this paper, we propose an approach that allows each node in a network to make the decision by itself, based on the second derivatives of its own state. The approach does not rely on the states of other nodes, leads to substantial saving of communication resources, and is resilient to connection failure. We perform a systematic analysis of the approach and, as a consequence, derive the optimal parameters that minimize the upper bound of the number of required iterations to reach consensus.
1. Introduction
In past decades, sensor networks have been widely applied in civilian, military, and industrial systems. Despite tremendous efforts that have been devoted to sensor techniques, it remains a great challenge to build a sensor system that works reliably and responsively under varying conditions. Distributed consensus building has emerged as an approach to address such shortcomings. Each individual node updates its “state” (e.g., view of local or global sensed values, actions to be taken, and/or network conditions) while exchanging information with others, until consensus of the state is attained. While individual sensors could have unreliable information or be vulnerable to environmental or network dynamics, all sensors in the network, via effective cooperation, can produce decisions that are higher in reliability because of the reached consensus. Since such consensus building enables the network to act locally based on distributed interactions, we contend that this approach can benefit networks that also involve actuation or otherwise interact with the physical world.
In previous work, there has been extensive theoretical study of the distributed consensus building problem. Xiao and Boyd [1] considered the convergence of a distributed averaging problem and proposed to seek the optimal updating weights by solving a semidefinite optimization problem. We note that the derivation in this work was based on the symmetric communication link assumption, which is not always satisfied in real networks. Olshevsky and Tsitsiklis [2] performed a more comprehensive investigation of this problem and derived lower bounds on the worst-case convergence time for different types of distributed consensus methods. Based on the theoretical analysis, they also developed an algorithm whose convergence time can essentially match these bounds. Olfati-Saber et al. [3, 4] developed a theoretical framework of information consensus over a multiagent network. They inspected various theoretical aspects of the problem and established the connections between the spectral properties of complex networks and the convergence rate of the consensus algorithms.
Whereas this previous work has laid down a solid theoretical foundation for the research on distributed consensus, it mostly focused on the analysis of asymptotic behaviors. As a consequence, practical issues, which are equally important to the effectiveness of sensor networks, have received less attention. In this paper, we particularly study one of these issues, namely, how might an individual node determine whether consensus (within a tolerable range) has been attained. This is motivated by the consideration that if the consensus status can be detected as soon as it is reached, the sensor network can then be put to rest earlier, which should lead to considerable energy saving.
Specifically, our goal here is to develop a consensus determining scheme with two desirable properties. First, it is self-aware, namely, each node in the network decides whether this scheme has reached consensus solely based on its own state, without resorting to the communication with other nodes. Compared to the schemes that detect consensus via information exchange with other nodes, a self-aware scheme does not consume extra communication bandwidth and tends to be more responsive. Second, the scheme should be resilient against noise as well as the variation of propagation delay and link weights. Our approach to achieve this target is inspired by the continuous-time work of Barbarossa et al. [5–7]. In their work, the network consensus is defined with respect to the first derivative of the states, rather than the states themselves. They showed that this new definition can result in improved robustness against noises, delays, and even topology changes. Hence, we adopt this formalism as the basis of our work.
The work presented here extends our earlier work [8] which initiates the basic idea of our approach. In that paper, we derived a discrete-time counterpart of the continuous-time formulation given in [5], making it implementable in physical, discrete-time hardware. We also verified the method through both numerical analysis and hardware implementation. In this paper, we further extend our previous exploration. Particularly, we consider the self-aware criterion given by where is the state of a node as a function of time and is the tolerance threshold. With this criterion, we obtain an upper bound of the number of iterations needed to achieve consensus and thereon derive the optimal step coefficient that minimizes this bound. Moreover, we examined how the optimal solution is related to different factors, including the spectrum of the graph Laplacian as well as the tolerance range, via both theoretical analysis and numerical simulation. We note that our analysis is not restricted to symmetric network, as opposed to some previous analysis, such as that in [1].
To sum up, the main contributions of this paper lies in the following aspects. First, we develop a self-aware criterion to detect consensus based on the discrete-time formulation presented in our earlier work [8]. It is simple, cost-effective, and robust to noises as well as network changes. Second, we perform theoretical analysis of the criterion for both symmetric and asymmetric networks and thereon obtain an upper bound of the number of iterations needed to reach consensus. Third, we derive an optimal updating weight and examine its relations to the spectral structure of the network as well as the tolerance threshold.
A brief outline of the rest of the paper follows. In Section 2, we formulate a discrete-time consensus model and analyzes its asymptotic behavior. In Section 3, we obtain an upper bound of the convergence time based on this model and thereon derive the optimal choice of . In Section 4, we give some numerical examples, illustrate the influence of to the consensus for both symmetric and asymmetric scenarios, and verify the analytical solution of . Finally, Section 5 concludes this work and identifies areas of future research.
2. The Formulation of Consensus Model
In this paper, we consider a sensor network with nodes (e.g., in Figure 1). Each node receives input from its sensors, and combines it with the states of its neighboring nodes to adjust its own state. These nodes constitute a dynamical system. Specifically, for each node , its dynamical behavior can be described by the following equation: Here, is the state of node as a function of time, is the corresponding input signal, is the set of neighboring nodes of , and is the coupling coefficient that reflects the contribution of node to the evolution of node . Note here that the coupling coefficients need not to be symmetric () in general. In this model, the change of is driven by a linear combination of the input signal and state differences from its neighbors. For simplicity, we assume that the input signals are static, that is, for each .
The model given in (2) can be rewritten into the following vectorized form: Here, , , and denotes the Laplacian matrix of the communication graph whose edge weights are given by the coupling coefficients . Particularly, we have We note that is symmetric if and only if the coupling coefficients are symmetric. A symmetric system implies that all communication links are bidirectional. However, this is not always the case due to packet drops, and different transmit powers and receiver sensitivities of the hardware.
2.1. Discrete-Time Formulation
To implement (3) on physical, discrete-time hardware, we reformulate the problem under discrete-time setting, via finite difference approximation, as We note that the updating at each step is controlled by an updating weight . Through recursively expanding the formula above, we find the analytic expression for , as where . From this, we further obtain a discrete version of the first derivative, as Here, refers to the discrete derivative obtained with updating weight .
2.2. The Conditions of Convergence
According to Barbarosa’s definition, the consensus is attained when the first derivatives of the states of all nodes converge to stationary values, which we denote by a vector , as illustrated by Figure 2. However, as we will show below, convergence is guaranteed only under specific conditions, but not in general.
Lemma 1. The first derivatives of the system given by (7) converge to stationary values with arbitrary input if and only if In this case, is finite, and the vector of stationary values is given by In particular, when , one has , which is independent of the initial states .
Here, is the spectral radius of , that is, the maximum absolute value of its eigenvalues.
Proof of Lemma 1. If , is a convergent sequence and thus so is due to continuity of linear operation. Otherwise, if , there exists an eigenvalue of such that . Since is arbitrary, we can choose such that , where is the eigenvector associated with . As a result, , which diverges. Therefore, the system converges for every if and only if .
The fact that converges implies that is finite. Again, by continuity of linear operation, we obtain
This completes the proof of the second statement.
Based on this lemma, we derive the conditions of convergence, which as we will see are closely related to the eigenvalues of , denoted by . Without losing generality, we assume that . The properties of these eigenvalues are summarized below.(1), where is the number of connected components of the communication graph. The number of null eigenvalues indicates the number of connected components.(2) has a null space which contains , that is, . In particular, when , the null space is a one-dimensional space spanned by .(3), the spectral radius of .(4)When is symmetric, are nonnegative real values.
The eigenvalues of are then given by . Hence, the spectral radius of is given by This immediately leads to an important condition of convergence, as given by the following corollary.
Corollary 2. The system given by (7) converges if and only if In particular, when is symmetric, all eigenvalues are real, and thus this condition is equivalent to
Proof of Corollary 2. By Lemma 1, the system converges if and only if . By (11), this is equivalent to , that is, for each . When is symmetric, all eigenvalues are real; hence, the maximum here can be either or . Recall that , thus . Therefore, the condition holds if and only if . Considering that , this is equivalent to .
Suppose that the condition of convergence given above is satisfied; we have the following discussions in regard to the matrices and .(1)Since , we have , implying that has an eigenvalue 1, which is associated with an eigenvector .(2)Suppose that the number of connected components of the communication graph is , then the geometric multiplicity of the eigenvalue 1 of is , meaning that the dimension of the eigenspace corresponding to the eigenvalue 1 is .(3) for each . Taking this sequence to the limit leads to an important result, namely, .
These results provide necessary basis for our later derivation.
2.3. Consensus over Connected Networks
In this paper, we focus on the case where the communication graph is connected and is diagonalizable. For this case, we derive the following results that characterize the asymptotic behavior of the dynamical system.
Lemma 3. Suppose that is the Laplacian matrix of a connected graph and is diagonalizable, such that , then where is a left eigenvector of associated with the eigenvalue that satisfies .
Proof of Lemma 3. Since is diagonalizable, it can be written as where is a diagonal matrix with , and is a matrix whose columns are the corresponding eigenvectors. Hence, Note that is also a diagonal matrix with . Under the condition of convergence, as , remains 1, while all other entries converge to 0. Consequently, Here, we use the notation to indicate the first column of a matrix. The first column of is the eigenvector associated with the eigenvalue , which is , while the first column of is a left eigenvector associated with the same eigenvalue, which we denote by . Consequently, we can write . Moreover, as we have discussed above, , thus , which implies that . The proof is completed.
Following this lemma, we derive the following results that characterize the asymptotic behaviors of the dynamical system on a connected communication network.
Theorem 4. Suppose that the dynamical system given by (7) is on a connected network and the Laplacian matrix is diagonalizable. If is chosen such that , then the first derivative of each node converges to a common stationary value given by Here, is a left eigenvector of associated with the eigenvalue that satisfies .
Here, convergence to a common stationary value means that all entries of are the same, that is, . In addition, we can see that the value is a weighted average of the input signals, which reflects the global consensus formed over the sensor network.
Proof of Theorem 4. From Lemma 3, we can see that, under the condition of convergence, converges to as . And since , . By Lemma 1, we know that the states converge to stationary values given by Let ; this can be further rewritten as . The proof is completed.
2.4. Determining Consensus
For any practical implementation, the stationary value is not available in advance; hence, one has to resort to other means to determine whether a sensor network has reached consensus. A natural idea is to compare the first derivatives of all nodes and see whether they are close to each other. However, implementation of this strategy might require a centralized process to collect information from every node, which could be expensive or even infeasible in practice.
In this paper, we take a different approach. Instead of relying on the first derivatives to detect consensus, we consider the second derivatives. Based on our discrete-time formulation, we define the vector of second derivatives to be
Suppose that the dynamical system is on a connected communication network with diagonalizable Laplacian matrix ; we have as . It immediately follows that
This observation suggests that we may decide whether consensus has been attained by examining whether the second derivatives vanish. Specifically, we devise the following rule. Given a tolerance threshold , a sensor network is regarded to reach consensus if Here, denotes the infinity norm. Intuitively, the network is considered to attain consensus when the magnitude of the second derivative at each node is below the given threshold .
It is worth noting that this rule is self-aware, meaning that each node can decide whether it meets the condition locally, without talking to other nodes. Compared to other rules, its main advantages are three-fold: (1) simplicity of implementation, (2) no consumption of extra communication energy, and (3) resilience to the changes of network conditions.
3. Convergence Time and Optimal
In the previous section, we have derived the conditions under which a sensor network is guaranteed to converge to the consensus status. The next important question is how long does it take to converge? In this section, we are going to seek an answer to this question.
For discrete-time implementations, the convergence time is measured by the number of iterations needed to reach consensus. Generally, it is impossible to obtain the exact value of this number in design stage, as it depends on both the initial states and the input signals. It is nonetheless possible to derive upper bounds, which would provide guidance for us to choose the optimal design.
Recall that we have obtained the analytic expression of the second derivatives, as given by
Given a tolerance threshold , our goal here is to derive an upper bound such that However, directly working with is difficult in general. Our basic idea is to first seek an upper bound of and then find such that Note here that we introduce as an argument of for the purpose of emphasizing the fact that such an upper bound is often closely related to the updating weight . Since , the condition given by (25) implies the one given by (24).
3.1. Upper Bound Based on Spectral Analysis
Our approach to obtain an upper bound is based on the concept of induced norm. Given a matrix , its induced norm, denoted by , is defined as follows: From this definition, we can immediately see that The induced norm is related to the spectral radius. In general, we have . Particularly, when is symmetric, the equality holds, that is, .
For induced norm, we also have the following result, which is important for our derivation.
Lemma 5. Given a real square matrix and , one has
This is a well-known result of linear algebra, which states that the induced norm of the matrix obtained by applying a polynomial to a matrix is upper bounded by the corresponding polynomial of with the coefficients replaces by their absolute values.
Coming back to our problem and considering the norm , we have the following result.
Theorem 6. Let be the states of a dynamical system on a connected network whose Laplacian matrix is diagonalizable. Then, one has Here, is a left eigenvector of associated with the eigenvalue that satisfies , and .
Proof of Theorem 6. We first rewrite as follows: Here, we make use of the fact that . With this expression, (29) in this theorem immediately follows from Lemma 5 and (27). The proof is completed.
From this theorem, it is not difficult to show that when The right-hand side of this inequality gives an upper bound of the number of iterations needed to attain consensus.
3.2. Optimal Choice of
To minimize the upper bound given by (31), one can choose the optimal updating weight that minimizes , as
3.2.1. Symmetric Cases
We first consider the cases where the underlying communication network is symmetric. In these cases, the Laplacian matrix is symmetric. Let be the eigenvalues of , which are all nonnegative real values. Since the component that corresponds to the eigenvalue 1 of is subtracted, the eigenvalues of are . Since is symmetric, we have Hence, the optimal choice of is given by Note that . According to Corollary 2, it follows, that with such an optimal choice, convergence is guaranteed. We also note that Xiao and Boyd [1] obtained similar results in different context.
3.2.2. Generic Diagonalizable Cases
In real applications the communication topology is not always symmetric due to difference of devices and deployment environment. Hence, the spectral radius does not necessarily equal the induced norm, we use the spectral radius in place of the induced norm; leading to the following objective in choosing optimal : In generic cases, the spectral radius is given by The eigenvalues here can be complex numbers. When solving this problem, it is important to contain the solution within the domain such that convergence is guaranteed. The domain is defined by Suppose that ; we have that if and only if Therefore, the valid range of is We note that there exists no analytic solution to this problem. However, the objective function is a piece-wise quadratic function, which can be readily solved by first delimiting the pieces and then comparing their respective minimum.
The derivation above provides an upper bound of the convergence time and a guideline for choosing the optimal . We can see that they are closely related to the spectral characteristics of the Laplacian matrix . In general, the network converges rapidly when the eigenvalues of (except the one that equals 1) are small.
3.3. More Accurate Analysis of the Convergence Time
As mentioned above, the actual convergence time also depends on the initial states , and the input signals , as well as the tolerance threshold . Here, we take a close examination of such dependency.
Suppose that is diagonalizable with eigenvalues . Let be the eigenvector associated with the eigenvalue for each . Since is diagonalizable, these eigenvectors span the entire state space, and as a consequence, the vector can be expressed as a linear combination of them, as Let be the range space of . Since the underlying network is connected, the null space of is one dimensional. Hence, has dimension and is spanned by . Clearly, the second derivatives and thus can be expressed to be a linear combination of , as We can see that the th term decreases geometrically with shrinking ratio . Asymptotically, the term with greatest shrinking ratio, namely, the one that attenuates most slowly, will dominate in a long run.
Let be a coordinate transform that maps each vector in to the coefficients with respect to the basis . This is a bijective linear map. For each vector , we define It can be easily shown that is a norm on . To characterize the relations between and , we define In other words, is the greatest real value that satisfies By the equivalence of norms on a finite dimensional vector space, we have ; that is, is a finite positive value. Consider the second derivatives . To have , it suffices to have From the definition of and (41), we get As a result, when, implying that the sensor network attains the consensus within the tolerable range. Based on this bound, the optimal choice is given by This result indicates that with the knowledge of input signals, one can derive an improved upper bound, and a proper choice for , which relates not only to the underlying graph, but also to the initial states, input signals, and the tolerance threshold .
However, directly applying this result in practice is infeasible, as the input signals are unavailable in advance; otherwise, we do not even have to deploy a sensor network to measure them. The true significance of this result lies is that it suggests that we can incorporate domain-specific knowledge to make a better design of the sensor network.
Specifically, while the exact input is unknown before we really perform the measurement, we generally have some rough knowledge about what the input might be, which could be formulated as a prior distribution of the input signals and then be exploited to guide the choice of . From such a prior model, one can derive the prior distribution of the coefficients , denoted by . Then, we obtain an upper bound of the expected convergence time, as With this model, one can choose an optimal that minimizes . Though it might be difficult to directly solve this problem, one can resort to various techniques to make further approximation.
4. Simulation
In this section, we will illustrate the following key results. First, the consensus rate and the choice of optimal iteration weight are dependent on the self-aware criterion for a sensor network where communication links are symmetric and asymmetric. Second, the analysis of determining the optimal provided in previous section is consistent with the simulation result with various ’s, which greatly helps designing efficient and energy-saving sensor network for different topologies.
4.1. Symmetric Topology
We first consider the symmetric network shown in Figure 1, which has 12 nodes and 24 links. This network was randomly generated with arbitrarily chosen initial state value and input as follows:
The coupling coefficient is defined to equal 1 if there is signal transmitted from node to node ; otherwise, . For the network shown in Figure 1, Figure 3 shows through simulation the number of iterations required to achieve consensus as a function of the weight parameter (—x-axis) and the self-aware criteria (—various curves). For this network, the best iteration weight found from earlier work by (34) is (illustrated in Figure 3 by the vertical line). However, we can see from Figure 3 that the three curves with , , and reach the lowest point at about 0.37, 0.36, and 0.35, which means setting the iteration weight to each of those values would get convergence by fewest iterations based on each network operator . Consensus with these values is achieved in significantly fewer iterations, and, most importantly, convergence is determined by local criterion. As increases, the whole curve moves to the left slightly. Though the change in the selection of is comparatively small with different threshold , we can find that the minimal iterations for reaching consensus drop largely, from 124 to 85, then fall off to 40. If one uses as determined by (34) and the criteria presented in [1], the system would require much more than 200 iterations to achieve consensus.
By solving (41) as a function of criterion , we found the relation between and minimal number of iterations and the relation between and optimal . As shown in Figures 4 and 5, the analytical results are very consistent with the simulation. we can see that the minimal number of iterations decreases as the threshold increases. When goes from 0.001 to 0.1, the minimal number of iterations keeps dropping from 125 to 40, which shows that achieving consensus with slightly different would make a difference in the number of communication iterations. There is a tradeoff between the consensus precision and the number of communications, or energy consuming. Realizing that, it is desirable to choose a larger criterion to make sensor nodes live longer, as long as it meets the specific application requirement of the sensor network.
4.2. Asymmetric Topology
Next, we consider another 12-node network shown in Figure 6 with an asymmetric communication topology. Using the same initial value and input as the above example, we show that the optimal iteration weight as well as the minimal number of iterations varies with different network operators ’s in Figure 7. Similar to the symmetric example, it can be seen that as increases, the corresponding would be reduced slightly, while the minimal number of iterations would decrease in a big way. For this asymmetric network, the theoretical best weight found from (35) is 0.3466, which is also denoted in Figure 7 by the vertical line. Again, this theoretical “best weight" is obviously different with the real practical best choice of ; applying the “best weight" to the practical systems would yield many more iterations for network to reach consensus. As illustrated by Figures 8 and 9, the performances of minimal number of iterations and optimal with for asymmetric topology present similar behaviors as those of symmetric topology.
5. Conclusion
In this work, the problem of achieving consensus among distributed sensor nodes has been considered. In particular, a potential answer to the question on how do individual nodes “know” when consensus is achieved is presented. The work introduces a local “self-aware” criterion, , which in practice is consensus rate of the parameter under consideration. The work illustrates (1) that , as expected, will influence the number of iterations required but more importantly (2) that existing criteria for the weighting functions is not appropriate for that will lead to an increased number of energy-consuming iterations. The work also considers the impact of nonsymmetric links on achieving consensus. These results address practical considerations regarding implementing distributed consensus building in “real" sensor networks. As such, it is hoped that this work will motivate others to consider implementation issues in this domain.