An Optimal Kalman-Consensus Filter for Distributed Implementation Over a Dynamic Communication Network

With the rising number of applications for sensor networks comes a need for more accurate cooperative fusion algorithms. In this paper, a distributed and optimal state estimator is presented for implementation through a dynamically switching, yet strongly connected, directed communication network to cooperatively estimate the state of a dynamic system. The Kalman-Consensus filter approach is used to incorporate a consensus protocol of neighboring state estimates into the traditional Kalman filter. It has been known that the main difficulty associated with implementing such an optimal solution is its fully coupled covariance matrix. Presented is a distributed computation of the covariance matrix at every node achieved by taking advantage of its independence from state estimates. Reductions to the distributed covariance computations are achieved through shared processing made available by the strongly connected digraph. Should the digraph change over time, a distributed topology estimation algorithm is included to facilitate the implementation of the proposed Kalman-Consensus filters. Together, these advances render a distributed and optimal solution to the consensus-based cooperative Kalman filter design problem. Convergence and stability of the proposed algorithms are analyzed and analytically concluded with performance verified through simulation of an illustrative example.


I. INTRODUCTION
The Kalman filter, introduced in [1], is a discrete-time, optimal, linear, and recursive algorithm developed for state estimation of a system through noisy measurements of the system's output.The Kalman filter has been used extensively [2] in industrial controls and monitoring, medical monitoring, navigation of dynamic systems, and prediction of economic growth and decline, just to name a few.The benefits and simplicity of the Kalman filter continue to drive research into new applications through adaptation of the original filter 60+ years after first publication.
One such adaptation to the Kalman filter has been made recently to take advantage of interconnected multi-node The associate editor coordinating the review of this manuscript and approving it for publication was Lin Zhang .sensor networks to achieve greater estimate accuracy than is achievable by a single node.Within the many different Kalman filter based solutions, the level of cooperation, network requirements, and computational complexity vary greatly.Three different levels of inter-node cooperation have appeared in literature.
The centralized Kalman filter, when applied to a sensor network, requires a primary node for which all sensor data is communicated.Once this primary node receives sensor data from all of the nodes, it then utilizes traditional Kalman filtering techniques to estimate the system state.This technique provides the most accurate state estimate available to the network but at the expense of having a single point of failure in the system, a requirement for all-to-all network connectivity, and a need for a single high performance processing center.
To avoid the single point of failure and to share the computational burden, a decentralized version has been analyzed.The decentralized Kalman filter requires each node to calculate independent state estimates with either full or partial knowledge of external sensor data.Algorithms such as those found in [3] and [4] aim to duplicate the centralized results at the expense of all-to-all network connectivity.Suboptimal approaches have been discussed to reduce these all-toall connectivity requirements at the expense of precision.To achieve a suboptimal, yet consistent, state estimator, [5] outlines a method of overestimating the unknown crosscovariances between nodes, allowing for only local communication among neighboring nodes in a strongly connected network.
Moving a step beyond centralized and decentralized approaches, distributed Kalman filter algorithms aim to cooperatively estimate the state of a system to achieve more accurate estimates.One such method of cooperation, with parallels to the cooperative control field [6], achieves a consensus of information across the connected agents.These consensus-based cooperative filters have been used for single target tracking as in [7] and [8] and multi-target tracking as in [9].Taking advantage of the shared target information, [10] utilizes the target tracking results to further aid in self localization of agents.In addition to target tracking, other applications requiring distributed and cooperative state estimation, like smart grids [11], can make use of these consensus-based Kalman filters.
All of these applications share a common vulnerability brought on by the presence of the communication network.These networks allow for False Data Injection (FDI) attacks whereby an adversary introduces erroneous, and oftentimes difficult to detect, data through interception and manipulation of data packets.Making use of the shared information and state consensus, methods such as [12] and [13] have been developed to detect these types of attacks and prevent them from disrupting the distributed state estimation.A detailed survey of how distributed state estimators, including some examples of consensus-based methods, can be used to thwart attacks can be found in [14].
Consensus based methods for distributed Kalman filtering can be categorized into three groups distinguished by the information for which a consensus is achieved.The first group, and the focus of this research, aims to achieve a consensus on state estimates.In this category, each node supports a global consensus of the state estimate of a common system through sharing of data and local measurements.The so-called Kalman-Consensus filter from [15] is one such approach in which a state consensus term is added to a traditional Kalman filter's state update equation.In this work, and that of [16], it is seen that the optimal solution for minimizing the local covariance at each node requires significant information about all nodes in the network.Multiple suboptimal solutions have been described in [15], [17], and [18] with varying approaches to overcome the needed information requirement.
A second approach to consensus-based distributed Kalman filtering is to use a consensus of measurements instead of states.This method is used to achieve a consensus on sensor data which is then used in traditional Kalman filtering for local state estimate updates.Examples of algorithms with measurement consensus can be found in [19], [20], and [21] where the information problem is solved via suboptimal methods or local calculation of every required piece of information.
Lastly, algorithms combining measurement and state consensus methods, typically implemented through the information form of the Kalman filter, can be found in [22], [23], and [24].
This research is focused on finding an optimal and distributed solution to the cooperative Kalman filter utilizing state consensus while avoiding all-to-all network connectivity requirements.The resulting Optimal Distributed Kalman-Consensus filter provides the following novel contributions: • The proposed form of the Kalman-Consensus filter integrates a distributed algorithm (Section II-B) for identifying the topology of the dynamically changing communication network.
• A method for distributing the required computations across the network of nodes (Section III-E) by taking advantage of the inherent separation between covariance and state estimate calculations is proposed.
• Each node's consensus terms are individually weighted according to the quality of measured data available to the respective neighbor.Also, a scalar gain to be optimized (Section III-A) is provided to better trade between optimality and ease of computation.
• The Kalman gain and the scalar consensus gains are calculated to minimize the local state estimate covariance while accounting for the inherent cross-covariances in the system (Section III-C).
• Given a potentially dynamic communication topology, and associated impacts on the filters, consensus convergence and filter stability are analyzed for the overall networked dynamic estimation scheme (Section III-D).
In short, the newly designed Kalman-Consensus filter is shown to simultaneously achieve both an optimal solution and a distributed implementation of all information exchanges and computations.This paper is organized such that Section II provides preliminaries and defines the problem.Section III proposes the Optimal Distributed Kalman-Consensus filter with stability results and implementation details.Simulation results comparing the performance of independent Kalman filters to the proposed algorithm are given in Section IV.Finally, conclusions are provided in Section V.

II. PROBLEM FORMULATION AND PRELIMINARIES
In this paper, we consider the problem of designing cooperative, distributed, and optimal Kalman filters for a group of sensor nodes observing a common dynamic system.Each node has its own independent sensors and shares its state estimate with its neighbors through a dynamic and local communication network.The goal is to design a set of optimal and consensus-based Kalman filters using local knowledge only.Additionally, these filters are to be adaptive to changes in their shared local communication network.In what follows, the observed system model and the communication network are defined.

A. OBSERVED SYSTEM MODEL
The system under observation is described by the following discrete-time, linear, and time-varying state-space equation where x k ∈ R n is the state vector, k ∈ R n×n is the state transition matrix, u k ∈ R m is the input to the system, B k ∈ R n×m is the control matrix, w k ∈ R n is the process noise, and G k ∈ R n×n is the process noise matrix all at time t = kT where T is the discrete-time step size and k is a integer step count.
Following the literature on classical and distributed Kalman filters [2], the process noise of the target system is assumed to be white Gaussian with zero mean and covariance matrix Q k , that is,

B. OBSERVATIONS AND DYNAMIC COMMUNICATION NETWORK
The communication network consists of a set of nodes, denoted by N , with cardinality N m = |N | connected through a strongly connected directional communication network.Each node is capable of independent, heterogeneous but regular, observation of the states of system (1) with the following measurement model: letting i ∈ N be the node index, where z i,k ∈ R p i is the measurement, H i,k ∈ R p i ×n is the measurement matrix, and v i,k ∈ R p i is the measurement noise.As in the case of the classical optimal Kalman filter, the pair { k , H i,k } is assumed to be uniformly observable for all k and for any i ∈ N .The measurement noise of each node i ∈ N is also assumed to be white Gaussian with zero mean and covariance matrix R i,k , that is, Using only its own observation, each node can implement a communication-free, independent Kalman filter summarized below.These independent Kalman filters provide the baseline to which the proposed filters are compared.
Lemma 1: An optimal independent Kalman filter is one that the ith node can use with only its locally available observations: where The fundamental issue studied in this paper is how to best improve the filtering performance by using a local communication network which may change over time.To this end, we choose to model the communication network as follows: • At t = 0, all the possibly participating nodes are assigned their index numbers, from 1 to N m as indicated above, and their measurement matrices H j,k and measurement covariance matrices R j,k for j ∈ N are made known to all nodes in the network.
• During the time interval t ∈ ((k − 1)T , kT ] with k a positive natural number, k ∈ ℵ + , the local communication network is assumed to be an invariant digraph described by its Laplacian matrix where D k is the degree matrix, and A k is the adjacency matrix.Specifically, A k (i, j) = 1 if node i receives the information sent by node j and A k (i, j) = 0 otherwise.The degree matrix is diagonal with Therefore, no matter how the communication network changes over time, its Laplacian matrix has the properties that L k 1 = 0 and where 1 is the vector of 1s, and matrix is invertible and its ith row is known to the ith node.
• During the interval t ∈ ((k − 1)T , kT ), the communication network is actively preparing for data sharing in the sense that a distributed algorithm is implemented to identify Laplacian matrix L k .This is achieved by distributively solving linear equation ( 3) for eigenvalues and eigenvectors of Q k , or equivalently Q −1 k .Such an algorithm is given by Lemma 2 below.
• At time t = kT , the data from the distributed Kalman filters, to be designed, are communicated.Lemma 2: If the sequence of digraphs, denoted by G k or its Laplacian matrix L k , are all strongly connected, Laplacian matrix L k is irreducible [25] for all k ∈ ℵ + and hence can be expressed as where λ k,l and v l,k are eigenvalues and right eigenvectors, respectively.Furthermore, the following algorithm from [26] can distributively determine the eigenvalues and eigenvectors to construct Laplacian matrix L k , and the rate of Qi (l) converging to Q k is exponential: where The iteration of equation ( 5) is done within the time interval t ∈ ((k − 1)T , kT ].It follows from ( 4) that local estimate of Laplacian matrix Li,k at node i is Since the convergence rate is exponential, a finite number of iterations would render Li,k being close enough to L k for the ith node to know Laplacian L k .This represents the overall network topology through the off diagonal elements of 0 and −1.Hence, a sequence of strongly connected digraphs can be appropriately determined online to implement the corresponding Optimal Distributed Kalman-Consensus filters over a piecewise-changing communication network.

III. KALMAN-CONSENSUS FILTER DESIGN FOR DISTRIBUTIVE IMPLEMENTATION
In this section, the proposed Kalman-Consensus filter design is developed and elaborated.In Section III-A, the proposed filter is introduced and, compared to earlier work in [15] and [16], it is more general due to its distinctive weighting matrices and gains for the distributed consensus terms.
In Section III-B, the difficulty of distributively calculating covariance matrices is discussed and overcome.This allows for the optimization of the proposed Kalman-Consensus filter in Section III-C for distributed implementation.Stability of the filter under a varying communication topology is analyzed in Section III-D with reduction of distributed computation explained in Section III-E.

A. DISTRIBUTED KALMAN-CONSENSUS FILTER
For a team of sensing nodes connected through a local communication network, the independent Kalman filters in Lemma 1 can be enhanced through introduction of a consensus term to the state update.In other words, the consensus term forms a weighted average of the estimated states across all of the neighboring nodes.This average primarily enhances the estimates of those nodes with larger measurement noises.
Specifically, the proposed Distributed Kalman-Consensus filters are of the form where x− i,k ∈ R n and x+ i,k ∈ R n are node i's propagated and updated state estimates, respectively, at time t = kT with Kalman gain K i,k and consensus matrices M ij,k , both of which are to be designed.The state propagation step (7) retains the same form as that found in the independent Kalman filter from Lemma 1.However, a state consensus term is added to the update step similar to [27] but with consensus gains M ij,k specific to each neighbors' estimate x− j,k .The information exchange for estimating the network topology and consensus of state estimates can be found in Figure 1.In the earlier paper [27] on continuous-time Kalman-Consensus filters, a single consensus matrix was used for each of the summations, that is, M ij,k = M i,k for all j ∈ N i,k , and the topology was assumed to be fixed.The same choices were made in [15] and [16] where discrete-time Kalman-Consensus filters are presented.Our proposed Kalman-Consensus filters differ from these by including distinct consensus matrices for each of the neighboring nodes, achieving better performance through consensus, as well as by allowing the communication network to vary.It is worth noting that, in our earlier paper [28], different weighting matrices were introduced into the continuous-time Kalman-Consensus filters but the design details remained open.
In order to design consensus weighting matrices M ij,k , the impacts to P d+ i,k and would monotonely increase (and approach a constant positive definite matrix in the limit) and ||K d i,k || would monotonely decrease (and approach zero in the limit).Accordingly, it makes sense to choose M ij,k such that less weighting is placed upon information from nodes with poor measurement noise.This lessens their contribution to the overall consensus, and accuracy of the consensus is increased.In particular, the consensus matrix M ij,k is chosen as where α i,k is a scalar gain to be optimized together with K i,k in Section III-C and T k−1 is included for the purpose of stability as will be shown in Section III-D.Nonetheless, before optimization and stability analysis can be performed, we must first address, in the subsequent subsection, the challenge of distributively calculating the covariance matrices associated with these new state estimates.

B. PROPAGATION AND COMPUTATION OF COVARIANCE MATRICES
As will be shown in the subsequent subsection, an optimal design of filter ( 7) and ( 8) calls for minimizing the trace of covariance matrix P + ii,k by the ith node, where As will be seen, the calculation of P + ii,k requires covariances from other nodes and cross-covariances between different nodes.These are defined by propagation and update equations given by respectively, where P ij,k is the cross-covariance between nodes i and j and P ii,k (with j = i) is the covariance of node i. Analytical expression of P + ij,k is given by Lemma 3. Its proof is omitted since it is analogous to that in [15] and [16], but with distinct M ij,k inside the summations.
Lemma 3: Suppose that the noises in measurement model (2) are independent with covariances denoted by Then, for the ith node, the covariance and cross-covariance updates are given by The addition of the consensus term to (8) produces a distributed state estimation algorithm, but also introduces complexities to the covariances as seen by comparing (13) with the covariance update equation from Lemma 1.These complexities are introduced by the sharing and combination of Gaussian random variables between nodes and are responsible for creating cross-covariances between each node in the network.As seen from ( 13), the calculation of the cross-covariances between node i and its neighbors requires knowledge of the cross-covariances between all nodes on the network.This means that the ith node needs to calculate, or have at its disposal, the covariance matrix P − k of the entire network, a kind of ''global information.'' The ''global'' nature of covariance matrix P + ij,k was first recognized in [15] and has been viewed as the dead end to developing a truly optimal distributed Kalman-Consensus filter.However, while this is a roadblock, it is not recognized in the existing literature that the ith node can calculate the whole covariance matrix if the node has knowledge of R j,k , H j,k , and the network topology (as shown in Lemma 2).This is because R j,k and H j,k do not change and because calculation of P + ij,k does not involve any real-time measurement information.
If every node calculates its own copy of the covariance matrix P − k for the entire network, the proposed Kalman-Consensus filters can be distributively implemented.This is one of the key advances in our proposed algorithm, while distributively identifying the varying network topology is another, and complementary.One may argue that such a calculation of P − k is costly, but it turns out that calculation of P − k can also be distributed among the neighboring nodes, as will be shown in Section III-E.With the problem of calculating P + ij,k solved, we are ready to conduct the design of the updated Kalman-Consensus filter.

C. OPTIMAL KALMAN AND CONSENSUS GAINS
The distributed Kalman-Consensus filters have two remaining design choices: Kalman gain K i,k and consensus gain α i,k .As in the case of the standard Kalman filter, the optimal design criteria is to minimize the covariance of the state estimate such that arg min for any i.The optimal solutions are given by the following lemma, and its proof is given in Appendix A.
Lemma 4: The optimal Kalman gain with respect to objective (15) is given by for any choice of consensus matrices M ij,k .If M ij,k is chosen according to (9), the optimal consensus gain is given by where

D. STABILITY CONDITION UNDER DYNAMIC NETWORK CHANGES
It is well known that, under any fixed topology, a Kalman filter is ensured to be stable by observability, that is, the estimate of an observable state is convergent.The same conclusion can be drawn for Kalman-Consensus filters since their Kalman gains are optimized to minimize covariance matrices P + ii,k which are natural Lyapunov functions to study and conclude stability from under a fixed topology.This implies that, for some > 0, Should the communication topology change, the Kalman-Consensus filter in (7) and ( 8) is adaptive to the changes.For such networked filters under dynamically changing topologies, their stability should be investigated to ensure the performance.This can be done using the following concept of passivity shortage, which has been shown to be a suitable tool for analyzing consensus stability of networked dynamical systems [29].
Definition 1: Dynamical subsystem e i,k = F i (e i,k−1 , ν i,k−1 ) is said to be input-feedforward passivity short (PS) [30], [31] if there is a storage function V i (•) such that, along the trajectory of the system, where e i,k is the state, ν i,k is the input, and constant i ≥ 0 is the so-called impact coefficient.
Using the above concept, we have the following result which is analogous to the consensus stability on cooperative control of networked systems [29].Its proof is included as Appendix B.
Lemma 5: Consider the Kalman-Consensus filter given by ( 7) and ( 8), and let its estimation error be defined as e i,k = E{x k − x+ i,k }.Then, each of the distributed Kalman-Consensus filters is passivity short from the consensus input to the output e i,k .Furthermore, there is a constant α > 0 such that, if α i,k ≤ α, the network of distributed Kalman-Consensus filters is asymptotically stable in the sense that e i,k → 0 for all i = 1, • • • , N m .

E. DISTRIBUTED IMPLEMENTATION AND COMPUTATION REDUCTION
As shown in Sections III-B and III-C, the ith node needs to know P − lm,k in order to calculate P + ij,k and subsequently K i,k and α ij,k for distributive implementation of the proposed Kalman-Consensus filters.In essence, every node needs to calculate the following global covariance matrix: Without reduction, this would be a big computational burden as each node would be required to calculate N 2 m covariances along with all associated parameters.Fortunately, matrix P − k in (20) has special properties which can substantially reduce the computational complexity.
First, it follows from definitions ( 10) and ( 11) that That is, matrix P − k in ( 20) is symmetric and only the upper (or lower) triangle of the matrix needs to be calculated.Calculation of only one triangle of the symmetric matrix reduces the required number of covariance calculations by almost half to N m + N m −1 l=1 l.Second, calculation of matrix P − k in ( 20) is independent from the measurements or information exchange of estimates at time t = kT .Instead, it depends upon the target model ii,0 = I , P + lm,0 = 0), and the sequence of topology changes up to time t = kT .Hence, computation of and should be done before t = kT , as should the topology identification, see Figure 8 in Appendix C for details of the timing.Furthermore, since every node needs to use the same matrix P − k , its computation can be distributed and shared among the locally connected nodes.
In the case of all-to-all communication topology, each node simply needs to compute its own row of matrix P + k−1 (minus the symmetric part) and the remaining elements can be received from all the other nodes.Once a full triangle of P + k−1 is collected, it can then be propagated to the required P − k immediately before time t = kT .With this network topology, the computational burden is reduced to N m covariances.
In the case of a sparsely connected topology, the interval ((k − 1)T , kT ) provides ample time for nodes on a modern communication network to share entries of P + k−1 amongst each other as seen in Figure 2.This data sharing can occur not just among directly connected neighbors, but also between neighbors' neighbors, and beyond.Given sufficient time in the interval, the computational burden of calculating P + k−1 approaches that of the all-to-all topology as more data sharing can occur, thus reducing the number of redundant calculations.The implementation of the Optimal Distributed Kalman-Consensus filter with network estimation culminates in Algorithm 1.The described algorithm implements one layer of shared calculations of the global P + k−1 between the nodes.These shared calculations can be extended to include neighbors' neighbors, and beyond, by implementing Step 15 within the While Loop such that each sub-iteration l brings additional information in from the rest of the network.
Strictly speaking, an abuse of notion is used in the above design and analysis.Specifically, if the communication topology is constant, everything above holds except that Subsections II-B and III-D are not applicable.Whenever the topology is changing, its estimation can be done as introduced in Subsection II-B, stability analysis in Subsection III-D becomes necessary, and the rest of the design and computation also hold except that N i,k should be replaced by Ni,k derived from (6).Since the substitution is simple and straightforward, it is omitted for the notional simplification.Nonetheless, Figure 8 is included in the Appendix C to show the whole process of distributively implementing both topology estimation and the proposed optimal Kalman-Consensus filter.

IV. SIMULATION SETUP AND RESULTS
A simulation to show different results using the proposed Optimal Distributed Kalman-Consensus filter was developed using a sensor network consisting of 5 nodes.These 5 nodes each independently measure the state of a target modeled by (1) with time-varying state transition matrix k = 1.0 + 0.025 sin(0.3k)−0.015 0.015 1.0 + 0.05 sin(0.5k)(21) and process noise given by The measurement noise covariance for each node is selected to be increasing with the unique index of the node such that allowing for the impact of each to be differentiated.
The accuracy of each simulated filter is quantified by the Root Mean Square Error using This provides a means of describing the error in the state estimate when compared to the true value of the state x k at any given time t = kT .Using the example target described above, the benchmark for comparison is shown in Figure 3 using independent Kalman filters at each node described in Lemma 1.These results depict the RMSE and trace of the state estimate covariance for each node.Next, the proposed Optimal Distributed Kalman-Consensus Filter in Algorithm 1 is introduced using a simple ring network as shown in Figure 5a.Using this static network topology, the RMSE of the filters is shown to be significantly reduced in Figure 4 as compared to the independent Kalman filter with no data sharing.Also, significant improvements can be seen to the covariances of nodes with poor measurement quality while not negatively affecting the covariances of those nodes with superior measurement capability.
With the overall benefit of the proposed Kalman-Consensus filter shown, the simulation is used next to illustrate the local optimality of the filters.To that end, the optimal consensus gain α i,k for node i = 3 was calculated using Lemma 4 and then scaled by ±10%.Table 1a shows values of tr{P + ii,k } for i = 3 at the last simulation iteration k = 500.As seen from the table, the smallest value of tr{P + ii,k } is achieved for a scale of 1.0 with larger values when a ±10% scale is applied.This illustrates that the chosen optimal consensus gain is at the trough of the surface representing the minimal solution and an optimal solution has been found.This was repeated for node i = 5 with similar results shown in table 1b.
Next, the switching network topology shown in Figure 5 was designed for analysis.The network starts with the same

TABLE 1. Selected results of the tr {P +
ii ,k } for optimal gain α i ,k with scaling of ±10% for nodes 3 and 5.
simple ring topology in Figure 5a and adds connections the node with the worst measurement noise, node 5, and nodes 2 and 3 at k = 200 as shown in Figure 5b.Then at k = 400, the topology changes again to the ring but now with added connections between the node with the least measurement noise, node 1, and nodes 3 and 4 shown in Figure 5c.
The proposed filters are simulated using the described switching network with results shown in Figure 6.From these results, it can be seen that the filters remain stable in the presence of the switches with no significant shift in RMSE observed.Furthermore, in review of the tr{P + ii,k }, it can be seen, especially at k = 400, that the additional distribution of node 1's (smallest sensor noise) state estimates to nodes 3 and 4 further reduce their respective covariances.
To better analyze the effects of the network switching, the time-varying perturbations of ( 21) are removed.As seen in Figure 7, the additional data received by nodes 2 and 3 at k = 200 further reduced the covariance of those estimates.This further reduction is due to the additional data confirming the accuracy of the state estimate.ii ,k (Lower) for proposed Kalman-Consensus filters using an LTI state transition matrix with a dynamic network topology.This is exaggerated further at k = 400 when nodes 3 and 4 receive the most accurate data from node 1.At this topology switch, it can be seen that not only do nodes 3 and 4 receive benefit, but so does node 2. This is due to the interconnection between nodes 2 and 3 such that the increase in accuracy of node 3 better supports node 2 in reducing its covariance.
An interesting observation from the switching network is that the RMSE of the different nodes are shown to have little to no effect from the changes in topology.This is due to the consensus having already reached a steady state prior to first switch at k = 200.Once the consensus is reached, little to no change in that consensus is observed due to the different topologies.

V. CONCLUSION
In this paper, an optimal and distributed solution to the discrete-time Kalman-Consensus filter, as applied to interconnected nodes within a switching network topology, was presented.Unique to this approach are independent consensus matrices assigned to each neighbor's information allowing for individualized control over its contribution to the overall consensus.Additionally, an algorithm for real-time estimation of the dynamic communication network topology was included in the filter design such that each node is aware of the overall network architecture as it changes in time.By taking advantage of the structure of the Kalman filter and the knowledge of the network architecture, a novel approach was found to distributively calculate the nodeto-node cross-covariances in a way that does not require all-to-all communication.With the unique structure to the consensus gains and knowledge of the estimated crosscovariances, the consensus and Kalman gain matrices were calculated optimally.Lastly, consensus convergence and filter stability were analytically confirmed and further verified in simulation to have significant performance improvements over independent Kalman filters.This proposed algorithm is a fully distributed, consensus-based, cooperative, and optimal state estimator with reasonable network and computational requirements.
Future research is needed to continue to reduce the computational complexity through further refinement of the distributed processing of the covariances and cross-covariances required for an optimal solution.In applications where a suboptimal solution would suffice, data-driven estimation methods could be explored to provide a consistent, but less overly conservative, estimate of the covariances and cross-covariances than is achievable through Covariance Intersection.Other further research topics could include a study of robustness against sensor covariance changes due to faulty sensors, extensions to nonlinear state estimation, as well as robustness to nodes joining or leaving the network.Lastly, as every application is unique, further study into the expanding range of uses such as cooperative localization, target tracking, fault detection, cybersecurity, and smart grids, just to name a few, could be explored.

APPENDIX A PROOF OF OPTIMIZATION LEMMA
It follows from (13) that ∂tr for any choice of M i,j,k .Setting the above gradient equal to zero yields the optimal Kalman gain in (16).Furthermore, it follows from (16) that, under the choice of M ij,k in (9), the optimal gain can be expressed as It then follows from (13)   Setting the above gradient to zero yields the optimal solution (17).

APPENDIX B PROOF OF STABILITY LEMMA
Denoting the state estimation error as xi,k = x k − x+ i,k , we know from (1), ( 2), (7), and (8) that the error dynamics are represented by where e i,k = E[x i,k ] and ν i,k−1 is given by (19).By choosing the storage function to be V i (e i,k ) = 1 2 e T i,k e i,k , it follows that where It follows from inequality (18) that matrix S i,k is positive definite for some i > 0. Invoking S i,k > 0 in (22), we know that which shows passivity shortage.Substituting ( 19) into (23) yields × (e j,k−1 − e i,k−1 ) + where Note that L k is a Laplacian in which L k,ii is diagonal with positive diagonal elements and L k,ij (j = i) is also diagonal but with negative diagonal elements.It follows that ξ T k−1 L k ξ k−1 is positive semi-definite and that, unless the consensus is reached, ξ T k−1 L k ξ k−1 > 0 holds.There is a constant α > 0 such that, if α i,k ≤ α, i V i < 0 until e i,k reaches a consensus.It also follows from (22) that, whenever the consensus is reached, ν i,k−1 = 0 and hence which is negative definite according to (18).Hence, V i converges to zero in the limit of k → ∞.This completes the proof.
k denotes the neighboring set of node i over t ∈ ((k −1)T , kT ]; [L k +I ] i * and [I ] i * denote the ith row of (L k + I ) and I , respectively; Qi,k (l) ∈ R N m ×N m is the estimate of Q i,k at node i and with initial condition Qi,k (0) chosen as [L k + I ] i * Qi,k (0) = [I ] i * ; and

FIGURE 1 .
FIGURE 1. Real-time signal flow for distributed Kalman-Consensus filters (Black occurs at t = kT while Blue occurs multiple times in interval t ∈ ((k − 1)T , kT )).

FIGURE 2 .
FIGURE 2. Augmented signal flow for distributed Kalman-Consensus filters and their covariance computations (Black occurs at t = kT while Blue occurs multiple times in interval t ∈ ((k − 1)T , kT )).

Findto nodes receiving from i 23 :
im,k−1 ∀m ∈ N to nodes receiving from i 15: Receive P + lm,k−1 ∀{l ∈ N i,k−1 and m / ∈ N j,k−1 } from neighbors to complete P + Nl,k ∀l ∈ N from Li,k Receive x− j,k ∀j ∈ N i,k from neighbors 24: Take local state measurement z i,k 25:Calculate M lm,k ∀l, m ∈ N per(9) 26:

FIGURE 4 .
FIGURE 4. RMSE (Upper) and Trace P +ii ,k (Lower) for proposed Kalman-Consensus filters with a static network topology.

FIGURE 5 .
FIGURE 5.The network topologies analyzed in the switching topology.

FIGURE 6 .
FIGURE 6. RMSE (Upper) and Trace P +ii ,k (Lower) for proposed Kalman-Consensus filters with a dynamic network topology.

FIGURE 7 .
FIGURE 7. RMSE (Upper) and Trace P +ii ,k (Lower) for proposed Kalman-Consensus filters using an LTI state transition matrix with a dynamic network topology.

−
i2 H i,k j∈N i,k (P − ii,k − P − ij,k )M T ij,k − F i,k j∈N i,k (P − ii,k − P − ij,k ) R −1 ii,k R −1 ii,k R −1 jj,k (P − ii,k − P − is,k − P − ji,k + P − js,k )M T is,k + j∈N i,k s∈N i,k M ij,k (P − ii,k − P − is,k − P − ji,k + P − js,k ) R −1 ii,k R −1 ss,k T k−1 .Applying trace to the above expression and expanding matrices K i,k , F i,k and M ij,k , we obtain∂tr + ii,k K i,k ∂α i,k = trace[ i4 ] + α i,k trace[ i5 ].

FIGURE 8 .
FIGURE 8. Timing diagram for the optimal distributed Kalman-Consensus filter with network topology estimation.