# A GMM-Based Secure State Estimation Approach against Dynamic Malicious Adversaries

Authors: Cui Zhu; Zile Wang; Zeyuan Zang; Yuxuan Li; Huanming Zheng
Journal: Journal of Sensors
 (2022)

---

## Abstract

We consider the secure state estimation of linear time-invariant Gaussian systems subject to dynamic malicious attacks. An error compensator is proposed to reduce the impact of local error data on state estimation. Based on that, a new estimation algorithm based on the Gaussian mixture model (GMM) aiming at dynamic attacks is proposed, which can cluster the local state estimates autonomously and improve the remote estimation accuracy effectively. The superiority of the proposed algorithm is verified by numerical simulations.


---

## Body

## 1. Introduction

Cyberphysical systems (CPSs), such as transportation networks and smart grids, integrate sensing, computing, and control technologies with a communication infrastructure. Tight integration and cooperation between cyber and physical components are the features of CPSs [1]. However, CPSs are vulnerable to any successful attacks especially network attacks on the data and communication channels, which causes serious harms to the national economy and social security, for example, the Stuxnet storm reported in [2], StuxNet malware [3], power blackouts in Brazil [4], and Maroochy water bleach [5]. Due to the widespread application of CPSs in many real-life critical infrastructures [6], the security of CPSs has become an increasingly important issue which has attracted attention from many researchers in the past decades.In the recent literature, the secure state estimation is an important research direction of CPSs security. In [7], a distributed state estimation method based on parallelized stream computing is proposed, which can not only significantly improve the speed of state estimation calculation but also reduce the interregional convergence correlation and the residual pollution. In [8], a new sequential estimation method is proposed to improve the estimation accuracy, which sequentially estimates states by the particle filter (PF) and parameters by the separable natural evolution strategy (SNES). The state estimation of three-phase power system models is studied in [9]. In [10], a Bayesian network based on the wireless power transfer (WPT) system state estimation algorithm is proposed, which can estimate the WPT system states in a distributed way using the Bayesian tree structure. In [11], a robust generalized maximum likelihood (GM) estimator, which leverages modified projection statistics and a Huber convex score function, is designed to bound the influence of observation outliers while maintaining its high statistical estimation efficiency. In [12], a distributed dynamic state estimation method for microgrids incorporating distributed energy resources is presented. In [13], a robust generalized maximum-likelihood Koopman operator-based Kalman filter (GM-KKF) is designed, which can estimate the rotor angle and speed of synchronous generators. In [14], a correlation-aided robust adaptive unscented Kalman filter (UKF) for power system decentralized dynamic state estimation with unknown inputs is presented, which has lower requirement of number of measurements for dynamic state estimation while achieving better robustness against bad data. In [15, 16], the state estimation method based on undamaged sensors is studied. In [17, 18], the state estimation for different systems is studied based on the convex optimization methods. In [19], by modeling and adopting a variety of models, a random Bayesian approach is proposed to solve the state estimation against switching patterns and signal attacks. In [20], the state estimation against fixed target attacks, switched target attacks with disturbance, and sparse sensor attacks are considered, and the sufficient condition for the existence of the switched observer is given. In [21], a fusion algorithm based on the Gaussian mixture model is presented to solve the estimation of a linear time-invariant Gaussian system under stealth attacks. However, the dynamic attacks are not considered. In [22], a dynamic combination strategy and a distributed Kalman filter are proposed, which improve the robustness of the system against random error data injection and replay attacks.Most of the studies mentioned above have focused on static attacks. However, dynamic attacks are very common in real systems. Therefore, this paper considers the state estimation for a networked system suffering from dynamic adversaries as shown in Figure1. The different sensors are attacked randomly at each time instant, and it is assumed that the number of attached sensors does not exceed half of the sensors.Figure 1
The networked system under attacks.Inspired by [21], we have designed an error compensator to reduce the impact of incorrect data on state estimation. Based on that, a new GMM-based state estimation algorithm is presented, which can effectively improve the state estimation accuracy against the dynamic adversaries. The contributions of this article are listed as follows:
(1)
A new error compensator is proposed to alleviate the influence of wrong data on state estimation, which can judge whether the beliefs generated by the expectation-maximum (EM) algorithm are accurate based on the observability of the system, and correct the doubtful beliefs(2)
By introducing the error compensator, a new GMM-based estimation algorithm is presented, which can improve the estimation accuracy effectively. The proposed algorithm can fuse the local data by adopting the modified beliefs as the weights of the local data with the centralized Kalman filterThe rest of the paper is organized as follows. Section II formulates the model of the considered system and the problem of interest. Section III proposes the error compensator and the new GMM-based state estimation algorithm against dynamic adversaries. In Section IV, the effectiveness of the proposed algorithm is demonstrated by numerical simulations. Conclusions are given in Section V.Notation:ℕ and ℝ are the sets of positive integers and real numbers, respectively. ℝn denotes the n-dimensional Euclidean space. S+nS++n is the set of n×n positive semidefinite (definite) matrices. We write X≥0X>0 when X∈S+nS++n. X′ denotes the transpose of matrix X. E· is the expectation of a random variable. Nμ,Σ is the Gaussian distribution with mean μ and covariance matrix Σ, and X~Nμ,Σ denotes X follows the Gaussian distribution Nμ,Σ. Diag· denotes a block diagonal matrix.


## 2. Problem Formulation

Consider the following networked system under attacks:(1)xk+1=Axk+wk,(2)yi,k=Cixk+vi,k+ai,k,where xk∈ℝn denotes the system state, yi,k∈ℝmi represents the measured value from sensor i at time k, and ai,k∈ℝmi is attack signal. The number of sensors is denoted by N. wk∈ℝn is the process noise, and wk~N0,Q. vi,k∈ℝmi is the measurement noise, and vi,k~N0,Ri. Meanwhile, it is assumed that Ewkwl′=δklQQ≥0, Evi,kvj,l′=δijδklRiRi>0, where i=ji≠j, δi,j=1δi,j=0. Ewkvi,l′=0,∀k,l∈ℕ, i,j=1,2,⋯,N. The initial state x0 is independent of wk and vi,k for all k≥0 and x0~N0,Π0. A,Ci and A,Q are detectable and controllable, respectively.The malicious attackai,k∈ℝmi satisfies the following assumptions:Assumption 1.
Anys (s≤N/2) sensors can be corrupted by the adversary, and the output values of the sensors are changed. Only when sensor i is unattacked, ai,k=0.Assumption 2.
The number of attacked sensorss is unknown, stochastic, and variable.Assumption 3.
The system parameters and noise statistics are known for the adversary.Assumption 4.
ai,k is statistically independent of wKK>k and vi,KK>k, respectively.Remark 1.
According to [23, 24], it is impossible to accurately reconstruct the state of a system when more than half the sensors are attacked. Thus, we assume that the maximum number of damaged sensors does not exceed N/2 in this paper, i.e., the upper limit of s is N/2.When the system is not attacked, the measurements at time instantk can be stacked as
(3)yk=Cxk+vk,where
(4)yk≜y1,k′y2,k′⋯yN,k′′,vk≜v1,k′v2,k′⋯vN,k′′,C≜C1′C2′⋯CN′′,R≜DiagR1,R2,⋯,RN.Then, we adopt a centralized Kalman filter as the remote estimator:(5)x^k−=Ax^k−1,Pk−=APk−1A′+Q,Kk=Pk−C′CPk−C′+R−1,x^k=x^k−+Kkyk−Cx^k−,Pk=I−KkCPk−,where x^k− and x^k are the priori and the posteriori estimation of the system state xk, respectively. Pk− and Pk are the priori and posteriori estimation error covariance, respectively. Kk is the Kalman filter gain.From [21], we know that the information-form Kalman filter can be expressed as
(6)x^k=x^k−+PkC′R−1yk−Cx^k−,(7)Pk−1=Pk−1−−1+C′R−1C.Similarly, the local Kalman filter for sensori can be written as
(8)x^i,k=x^i,k−+Pi,kCi′Ri−1yi,k−Cix^i,k−,Pi,k−1=Pi,k−1−−1+Ci′Ri−1Ci.It is noted thatPk and Pi,k can be calculated offline. According to [25], the Kalman filter converges from any initial condition exponentially when A,Ci and A,Q are detectable and controllable, respectively. The steady-state values of local and centralized Kalman filter are defined as
(9)P¯i≜limk⟶+∞Pi,k,P¯i−≜limk⟶+∞Pi,k−,P≜limk⟶+∞Pk,P−≜limk⟶+∞Pk−.It is assumed that the system starts from the steady state withPi,0=P¯i and P0=P, and the fixed-gain of local and centralized Kalman filters can be represented as:
(10)Ki=P¯iCi′Ri−1=P¯i−Ci′CiP¯i−Ci′+Ri−1,K=PC′R−1=P−C′CP−C′+R−1.The objective of this paper is to design a new GMM-based estimation method for systems suffering from dynamic adversaries.


## 3. The GMM-Based State Estimation

In this section, an error compensator and the GMM-based state estimation algorithm against dynamic adversaries are proposed.


### 3.1. Modeling and the EM Algorithm

For a Gaussian mixture model withℚ components [21], the mean and covariance of the q-th component Qqq∈1,2,⋯,ℚ are expressed as μq and Σq, respectively. πq is the mixture component weights of Qq, and ∑q=1ℚπq=1. In this case, the mixture density of a Gaussian mixture model can be expressed as
(11)px=∑q=1ℚpx∣QqPrQq=∑q=1ℚπqfx;μq,Σq,where px∣Qq and PrQq are the Gaussian distribution density and weight of the q-th component, respectively. Function fx;μ,Σ is the probability density function (pdf) for Gaussian random variables:
(12)fx;μ,Σ=12πnΣexp−12x−μ′Σ−1x−μ.At time instantk, we denote the means of the state variables for sensor i as μk1 under the unattacked scenario and μk2 under the attacked-scenario, respectively. Σk1 and Σk2 represent the covariance when sensor i is unattacked and attacked, respectively. The local state estimation x^i,k follows different distributions depending on whether sensor i is attacked or not. According to the definition of GMM and the analysis of Kalman filtering in [25], it can be known that when sensor i is unattacked (defined as the first component), x^i,k follows the Gaussian distribution with the mean μk1 and the fixed covariance Σk1=P¯i, i.e., px^i,k∣Q1~Nμk1,P¯i,∀i∈N. When sensor i is attacked (defined as the second component), the exact distribution of x^i,k is unknown since the specific type and the starting time of attacks are unknown. In this case, similar to [21], we can adopt a Gaussian distribution with the first and second moments, i.e., px^i,k∣Q2~Nμk2,Σk2,∀i∈N, to approximate the distribution of all local estimates in the second component. Then, x^i,k can be described by the following 2-component Gaussian mixture model:
(13)px^i,k=∑q=12px^i,k∣QqPrQq=πk1px^i,k∣Q1+πk2px^i,k∣Q2=πk1fx^i,k;μk1,P¯i+πk2fx^i,k;μk2,Σk2,where πk1 and πk2 are the weights of the first and second components at time k, respectively.The observation data set is defined asZk=x^i,ki=1N. According to [26, 27], it is known that the expectation-maximization (EM) algorithm can be adopted to find the maximum likelihood estimates for the parameter Φk=πkq,μkq,Σk2q=12 using Zk=x^i,ki=1N. The log likelihood is shown as
(14)LΦk;Zk=∑i=1Nlogπk1fx^i,k;μk1,P¯i+πk2fx^i,k;μk2,Σk2.Generally, the EM algorithm is divided into two steps: the expectation and maximization step. First, initializing the parameterΦk at each time k, then the expectation step generates a belief γi,kqq=1,2 based on Φk and x^i,k for each sensor:
(15)γi,k1=πk1fx^i,k;μk1,Σk1πk1fx^i,k;μk1,Σk1+πk2fx^i,k;μk2,Σk2,(16)γi,k2=1−γi,k1,where γi,k1 and γi,k2 represent the probability of sensor i belonging to the component Q1 and Q2, respectively.Given all beliefsγi,k1 and γi,k2, the parameters πkq,μkq,Σk2q=12 are reestimated in the maximization step:
(17)πkq=∑i=1Nγi,kqN,(18)μkq=∑i=1Nγi,kqx^i,k∑i=1Nγi,kq,(19)Σk2=∑i=1Nγi,k2x^i,k−μk2x∧i,k−μk2′∑i=1Nγi,k2.The expectation and maximization steps iterate until they converge to a certain value. This iterative procedure maximizes the concave lower bound of the log likelihood in (14).


### 3.2. The Error Compensator

In this subsection, an error compensator is proposed to reduce the influence of incorrect data on the state estimation.According to 3.1, the EM algorithm can be used to calculate the GMM parameters and find the maximum likelihood estimation. However, the convergence and clustering results of the EM algorithm are affected by the initial parameters. In this paper, the first and second moments are adopted as the initial parameters of the second cluster. Due to the randomness of dynamic adversary and its specific type is unknown, the output of some attacked sensors may be similar to that of normal sensors at some moments. In this case,γi,k1 will be miscalculated as γi,k2 in the iterative process (15)-(19), since the observed data are considered to be closer to the second cluster by the EM algorithm. When the above case occurs, the estimation accuracy will be reduced seriously because the number of data available for fusion is less than N/2. On the other hand, the measurements that are similar to the true measurements can provide useful information for the remote state estimation, which means that the data belonging to the second cluster can be adopted to estimate system state. Hence, a compensator is designed to solve the above problem.γ¯k2 represents the average of all γi,k2 at time instant k, which can be calculated as follows:
(20)γ¯k2=∑i=1Nγi,k2N.According to the EM algorithm,γi,k2 tends to 1 if and only if sensor i is attacked, and the expectation step is accurate, which causes ∑i=1Nγi,k2 to approach s. When the expectation step is miscalculated, ∑i=1Nγi,k2 tends to N−s since γi,k2 approachs 0 for the attacked sensor i. According to Assumptions 1–4, the maximum number of damaged sensors does not exceed N/2 (namely, s≤N/2), which means N−s>N/2. Hence, it can be known that γi,k1 and γi,k2 are miscalculated if ∑i=1Nγi,k2>N/2. Based on the above analysis, the compensator is designed as follows:
(21)γ^i,k1=γi,k1,γ¯k2≤εγi,k2,γ¯k2>ε,γ^i,k2=1−γ^i,k1,where γ^i,k1 and γ^i,k2 are the modified beliefs, and ε≥s/N represents a threshold, which can be adjusted according to the performance requirements of the actual system.


### 3.3. The GMM-Based State Estimation Approach against Dynamic Attacks

In this subsection, a GMM-based estimation algorithm is proposed to deal with the dynamic attacks, which can improve the estimation accuracy effectively.(22a)x^k−=Ax^k−1,(22b)Pk−=APk−1A′+Q,(22c)x^k=x^k−+∑i=1Nγ^i,k1PkCi′Ri−1yi,k−Cix^k−,(22d)Pk=Pk−−1+∑i=1Nγ∧i,k1Ci′Ri−1Ci−1,where the initial values x^0 and P0 are the steady-state values of the remote estimator when k≤0.Theorem 2.
Consider the linear time-invariant system (1)-(2) and the dynamic adversary satisfying Assumptions 1–4, and the remote state estimation x^k can be calculated byProof.
According to the Definition 2 in [16, 28], if ss≤N/2 sensors are attacked, the following system is still observable in the absence of attacks:
(23)xk+1=Axk+wk,ys¯,k=Cs¯xk+vs¯,k,where s¯⊆1,2,⋯,N is the set of unattacked sensors, and ys¯,k is the measurement stacked by the set s¯. Similarly, Cs¯ and vs¯,k are the system parameter and the measurement noise stacked by the set s¯, respectively. The pair A,Cs¯ is observable.
According to Section II, Equation (6) can be expanded as
(24)x^k==x^k−+PkC′R−1yk−Cx^k−=x^k−+PkC1′⋮CN′′R1000⋱000RN−1y1,k⋮yN,k−C1′⋮CN′x^k−=x^k−+PkC1′R1−1⋮CN′RN−1′y1,k−C1′x^k−⋮yN,k−CN′x^k−=x^k−+∑i=1NPkCi′Ri−1yi,k−Cix^k−,where the default weight of each sensor is equal to 1 when the sensor is not attacked.Based on the above analysis, we can calculate the remote state estimationx^k by adopting the undamaged sensors. The belief γ^i,k1 represents the probability that the sensor i is undamaged. Then, we can fuse the local data by adopting γ^i,k1 as the new weight of the local data, and then the Equations (22a)-(22d) can be obtained.The system is assumed to reach steady state before timek=0. The adversary can launch dynamic attacks at any time when k≥1. Starting from time k=1, the local state estimation x^i,k is calculated utilizing the measurement of sensor i at each time instant k. Based on that, the remote estimator clusters the local state estimates and calculates the parameter Φk by the EM algorithm according to Equation (15)-(19). Then, the error compensator is used to correct the error beliefs. Finally, based on the modified belief γ^i,k1, the local data can be fused by Theorem 2 to obtain the state estimation x^k. The whole process is summarized in Algorithm 1.Algorithm 1: The GMM-based state estimation against dynamic attacks.
1 // Run Kalman filter to steady state.2: Initializex^i,−∞=0,Pi,−∞=Πi,x^−∞=0,P−∞=Π;3:fork=−∞:0do4: // Local data reaches steady state.5:Fori=1:Ndo6:Pi,k=APi,k−1A′+Q−1+Ci′Ri−1Ci−1;7:x^i,k=Ax^i,k−1+Pi,kCi′R−1yi,k−CiAx^i,k−1;8:end for9: // The remote estimator reaches steady state.10:Pk=APk−1A′+Q−1+C′R−1C−1;11:x^k=Ax^k−1+PkC′R−1yk−CAx^k−1;12:end for13: // GMM clustering by the EM algorithm.14: SetP¯i=Pi,0,Σi1=Pi,015:fork=1:+∞do16:fori=1:Ndo17:x^i,k=Ax^i,k−1+P¯iCi′Ri−1yi,k−CiAx^i,k−1;18:end for19: // the EM algorithm.20: Initializeπk1,πk2,μk1,μk2,Σk2;21:whileLΦk;Zk not achieve the maximum likelihood estimates do22:  The expectation step: calculateγi,k1 and γi,k2 according to Equation (15)-(16).23:  The maximization step: calculateπkq,μkq,Σk2q=12 by Equation (17)-(19).24:end while25: // the error compensator.26:γ¯k2=∑i=1Nγi,k2/N27:fori=1:Ndo28:ifγ¯k2>εε⩾s/Nthen29:γ^i,k1=γi,k2;30:γ^i,k2=γi,k1;31:else32:γ^i,k1=γi,k1;33:γ^i,k2=γi,k2;34:end if35:end for36: // Remote state estimation.37:x^k−=Ax^k−1;38:Pk−=APk−1A′+Q;39:x^k=x^k−+∑i=1Nγ^i,k1PkCi′Ri−1yi,k−Cix^k−;40:Pk=Pk−−1+∑i=1Nγ∧i,k1Ci′Ri−1Ci−1;41:end for


## 3.1. Modeling and the EM Algorithm

For a Gaussian mixture model withℚ components [21], the mean and covariance of the q-th component Qqq∈1,2,⋯,ℚ are expressed as μq and Σq, respectively. πq is the mixture component weights of Qq, and ∑q=1ℚπq=1. In this case, the mixture density of a Gaussian mixture model can be expressed as
(11)px=∑q=1ℚpx∣QqPrQq=∑q=1ℚπqfx;μq,Σq,where px∣Qq and PrQq are the Gaussian distribution density and weight of the q-th component, respectively. Function fx;μ,Σ is the probability density function (pdf) for Gaussian random variables:
(12)fx;μ,Σ=12πnΣexp−12x−μ′Σ−1x−μ.At time instantk, we denote the means of the state variables for sensor i as μk1 under the unattacked scenario and μk2 under the attacked-scenario, respectively. Σk1 and Σk2 represent the covariance when sensor i is unattacked and attacked, respectively. The local state estimation x^i,k follows different distributions depending on whether sensor i is attacked or not. According to the definition of GMM and the analysis of Kalman filtering in [25], it can be known that when sensor i is unattacked (defined as the first component), x^i,k follows the Gaussian distribution with the mean μk1 and the fixed covariance Σk1=P¯i, i.e., px^i,k∣Q1~Nμk1,P¯i,∀i∈N. When sensor i is attacked (defined as the second component), the exact distribution of x^i,k is unknown since the specific type and the starting time of attacks are unknown. In this case, similar to [21], we can adopt a Gaussian distribution with the first and second moments, i.e., px^i,k∣Q2~Nμk2,Σk2,∀i∈N, to approximate the distribution of all local estimates in the second component. Then, x^i,k can be described by the following 2-component Gaussian mixture model:
(13)px^i,k=∑q=12px^i,k∣QqPrQq=πk1px^i,k∣Q1+πk2px^i,k∣Q2=πk1fx^i,k;μk1,P¯i+πk2fx^i,k;μk2,Σk2,where πk1 and πk2 are the weights of the first and second components at time k, respectively.The observation data set is defined asZk=x^i,ki=1N. According to [26, 27], it is known that the expectation-maximization (EM) algorithm can be adopted to find the maximum likelihood estimates for the parameter Φk=πkq,μkq,Σk2q=12 using Zk=x^i,ki=1N. The log likelihood is shown as
(14)LΦk;Zk=∑i=1Nlogπk1fx^i,k;μk1,P¯i+πk2fx^i,k;μk2,Σk2.Generally, the EM algorithm is divided into two steps: the expectation and maximization step. First, initializing the parameterΦk at each time k, then the expectation step generates a belief γi,kqq=1,2 based on Φk and x^i,k for each sensor:
(15)γi,k1=πk1fx^i,k;μk1,Σk1πk1fx^i,k;μk1,Σk1+πk2fx^i,k;μk2,Σk2,(16)γi,k2=1−γi,k1,where γi,k1 and γi,k2 represent the probability of sensor i belonging to the component Q1 and Q2, respectively.Given all beliefsγi,k1 and γi,k2, the parameters πkq,μkq,Σk2q=12 are reestimated in the maximization step:
(17)πkq=∑i=1Nγi,kqN,(18)μkq=∑i=1Nγi,kqx^i,k∑i=1Nγi,kq,(19)Σk2=∑i=1Nγi,k2x^i,k−μk2x∧i,k−μk2′∑i=1Nγi,k2.The expectation and maximization steps iterate until they converge to a certain value. This iterative procedure maximizes the concave lower bound of the log likelihood in (14).


## 3.2. The Error Compensator

In this subsection, an error compensator is proposed to reduce the influence of incorrect data on the state estimation.According to 3.1, the EM algorithm can be used to calculate the GMM parameters and find the maximum likelihood estimation. However, the convergence and clustering results of the EM algorithm are affected by the initial parameters. In this paper, the first and second moments are adopted as the initial parameters of the second cluster. Due to the randomness of dynamic adversary and its specific type is unknown, the output of some attacked sensors may be similar to that of normal sensors at some moments. In this case,γi,k1 will be miscalculated as γi,k2 in the iterative process (15)-(19), since the observed data are considered to be closer to the second cluster by the EM algorithm. When the above case occurs, the estimation accuracy will be reduced seriously because the number of data available for fusion is less than N/2. On the other hand, the measurements that are similar to the true measurements can provide useful information for the remote state estimation, which means that the data belonging to the second cluster can be adopted to estimate system state. Hence, a compensator is designed to solve the above problem.γ¯k2 represents the average of all γi,k2 at time instant k, which can be calculated as follows:
(20)γ¯k2=∑i=1Nγi,k2N.According to the EM algorithm,γi,k2 tends to 1 if and only if sensor i is attacked, and the expectation step is accurate, which causes ∑i=1Nγi,k2 to approach s. When the expectation step is miscalculated, ∑i=1Nγi,k2 tends to N−s since γi,k2 approachs 0 for the attacked sensor i. According to Assumptions 1–4, the maximum number of damaged sensors does not exceed N/2 (namely, s≤N/2), which means N−s>N/2. Hence, it can be known that γi,k1 and γi,k2 are miscalculated if ∑i=1Nγi,k2>N/2. Based on the above analysis, the compensator is designed as follows:
(21)γ^i,k1=γi,k1,γ¯k2≤εγi,k2,γ¯k2>ε,γ^i,k2=1−γ^i,k1,where γ^i,k1 and γ^i,k2 are the modified beliefs, and ε≥s/N represents a threshold, which can be adjusted according to the performance requirements of the actual system.


## 3.3. The GMM-Based State Estimation Approach against Dynamic Attacks

In this subsection, a GMM-based estimation algorithm is proposed to deal with the dynamic attacks, which can improve the estimation accuracy effectively.(22a)x^k−=Ax^k−1,(22b)Pk−=APk−1A′+Q,(22c)x^k=x^k−+∑i=1Nγ^i,k1PkCi′Ri−1yi,k−Cix^k−,(22d)Pk=Pk−−1+∑i=1Nγ∧i,k1Ci′Ri−1Ci−1,where the initial values x^0 and P0 are the steady-state values of the remote estimator when k≤0.Theorem 2.
Consider the linear time-invariant system (1)-(2) and the dynamic adversary satisfying Assumptions 1–4, and the remote state estimation x^k can be calculated byProof.
According to the Definition 2 in [16, 28], if ss≤N/2 sensors are attacked, the following system is still observable in the absence of attacks:
(23)xk+1=Axk+wk,ys¯,k=Cs¯xk+vs¯,k,where s¯⊆1,2,⋯,N is the set of unattacked sensors, and ys¯,k is the measurement stacked by the set s¯. Similarly, Cs¯ and vs¯,k are the system parameter and the measurement noise stacked by the set s¯, respectively. The pair A,Cs¯ is observable.
According to Section II, Equation (6) can be expanded as
(24)x^k==x^k−+PkC′R−1yk−Cx^k−=x^k−+PkC1′⋮CN′′R1000⋱000RN−1y1,k⋮yN,k−C1′⋮CN′x^k−=x^k−+PkC1′R1−1⋮CN′RN−1′y1,k−C1′x^k−⋮yN,k−CN′x^k−=x^k−+∑i=1NPkCi′Ri−1yi,k−Cix^k−,where the default weight of each sensor is equal to 1 when the sensor is not attacked.Based on the above analysis, we can calculate the remote state estimationx^k by adopting the undamaged sensors. The belief γ^i,k1 represents the probability that the sensor i is undamaged. Then, we can fuse the local data by adopting γ^i,k1 as the new weight of the local data, and then the Equations (22a)-(22d) can be obtained.The system is assumed to reach steady state before timek=0. The adversary can launch dynamic attacks at any time when k≥1. Starting from time k=1, the local state estimation x^i,k is calculated utilizing the measurement of sensor i at each time instant k. Based on that, the remote estimator clusters the local state estimates and calculates the parameter Φk by the EM algorithm according to Equation (15)-(19). Then, the error compensator is used to correct the error beliefs. Finally, based on the modified belief γ^i,k1, the local data can be fused by Theorem 2 to obtain the state estimation x^k. The whole process is summarized in Algorithm 1.Algorithm 1: The GMM-based state estimation against dynamic attacks.
1 // Run Kalman filter to steady state.2: Initializex^i,−∞=0,Pi,−∞=Πi,x^−∞=0,P−∞=Π;3:fork=−∞:0do4: // Local data reaches steady state.5:Fori=1:Ndo6:Pi,k=APi,k−1A′+Q−1+Ci′Ri−1Ci−1;7:x^i,k=Ax^i,k−1+Pi,kCi′R−1yi,k−CiAx^i,k−1;8:end for9: // The remote estimator reaches steady state.10:Pk=APk−1A′+Q−1+C′R−1C−1;11:x^k=Ax^k−1+PkC′R−1yk−CAx^k−1;12:end for13: // GMM clustering by the EM algorithm.14: SetP¯i=Pi,0,Σi1=Pi,015:fork=1:+∞do16:fori=1:Ndo17:x^i,k=Ax^i,k−1+P¯iCi′Ri−1yi,k−CiAx^i,k−1;18:end for19: // the EM algorithm.20: Initializeπk1,πk2,μk1,μk2,Σk2;21:whileLΦk;Zk not achieve the maximum likelihood estimates do22:  The expectation step: calculateγi,k1 and γi,k2 according to Equation (15)-(16).23:  The maximization step: calculateπkq,μkq,Σk2q=12 by Equation (17)-(19).24:end while25: // the error compensator.26:γ¯k2=∑i=1Nγi,k2/N27:fori=1:Ndo28:ifγ¯k2>εε⩾s/Nthen29:γ^i,k1=γi,k2;30:γ^i,k2=γi,k1;31:else32:γ^i,k1=γi,k1;33:γ^i,k2=γi,k2;34:end if35:end for36: // Remote state estimation.37:x^k−=Ax^k−1;38:Pk−=APk−1A′+Q;39:x^k=x^k−+∑i=1Nγ^i,k1PkCi′Ri−1yi,k−Cix^k−;40:Pk=Pk−−1+∑i=1Nγ∧i,k1Ci′Ri−1Ci−1;41:end for


## 4. Numerical Simulation

In this section, the effectiveness of the GMM-based estimation algorithm is verified through numerical simulations. Similar to literature [21], we consider a linear time-invariant dynamic process which is measured by 15 sensors. The system parameters A and Q are randomly generated from intervals [0.4, 0.99] and [0.5, 2], respectively. Matrices Ci and Ri, i∈N, are randomly generated from intervals [1, 2]. The system reaches steady state before t=30, and the attack signal starts from time t=31, assuming that s1≤s≤6 sensors are attacked by ai,k at each time instant tt≥31.


### 4.1. Example 1

In this example, the estimation accuracy of GMM-based method with and without compensator against dynamic attacks has been compared. Similar to [15], the attack signal ai,k can be assumed to be a linear function of the measurement noise:
(25)ai,k=βvi,k+Θ,where β and Θ are real number from the interval [-5, 5] and [-10, 10], respectively. Meanwhile, ai,k satisfies Assumptions 1–4.Set the thresholdε=0.45 in the following example. In Figure 2, the trajectories of the actual state and the states estimated by the GMM-based estimation method with and without compensator are plotted. It is shown that the estimated states of the GMM-based method with compensator (dotted line) are closer to the actual state than that without compensator (red line). Figure 3 shows the estimation error covariance for the GMM-based method with and without compensator, respectively. It is observed that the estimation error covariance of the method without compensator (red line) is larger than that with compensator (black line), which means that the error compensator proposed in this paper can effectively reduce the impact of faulty data on state estimation. According to Figures 2 and 3, the estimation accuracy of the GMM-based estimation method with the compensator is higher than that without the compensator against dynamic attacks.Figure 2
The actual states and its remote estimation with different approaches.Figure 3
Remote estimation error covariance of the GMM-based method with and without compensator.The number of attacked sensors at each moment whenT≥31 is plotted in Figure 4, and the state estimation and corresponding error covariance of the GMM-based algorithm when the compensator takes different thresholds are shown in Figures 5 and 6, respectively. It is seen that the state estimation accuracy is higher when ε=0.45 and 0.65 than ε=0.15 and 0.95, which is indicated that the performance of the remote estimator will deteriorate while ε is too large or too small. Hence, the threshold can be adjusted according to the actual performance requirements of the real system.Figure 4
The number of attacked sensors at each moment whenT⩾31.Figure 5
Comparison of the state estimation with different thresholds.Figure 6
Remote estimation error covariance with different thresholds.


### 4.2. Example 2

Distributed and centralizedχ2 false-data detectors are common, and they determine whether an attack exists based on the statistical characteristics of the innovation yi,k−Cix^i,k− and yk−Cx^k−, respectively. From [21], a well-designed dynamic attack can successfully bypass the distributed χ2 detector but fails to remain stealthy to the centralized χ2 false-data detector. In this subsection, we have compared the proposed approach and the estimation methods based on different χ2 false-data detectors.Similar to [21], the attack signal ai,k is set as
(26)ai,k=−2yi,k+2Cix^k−,where ai,k satisfies Assumptions 1–4.In Figure7, the trajectories of the actual state and the state estimated by estimation methods based on different detectors are plotted, respectively. It is seen that the GMM-based state estimation (black line) is closer to the actual state than the state estimation based on the distributed and centralized χ2 detector (red and green). Figure 8 shows the estimation error covariance of the corresponding methods, and it is observed that the GMM-based estimation error covariance is much smaller than that based on the distributed and centralized χ2 detector. It can be seen that the GMM-based estimation approach proposed in this paper can improve the performance effectively.Figure 7
The actual states and its remote estimation based on different methods.Figure 8
Remote estimation error covariance based on different methods.


## 4.1. Example 1

In this example, the estimation accuracy of GMM-based method with and without compensator against dynamic attacks has been compared. Similar to [15], the attack signal ai,k can be assumed to be a linear function of the measurement noise:
(25)ai,k=βvi,k+Θ,where β and Θ are real number from the interval [-5, 5] and [-10, 10], respectively. Meanwhile, ai,k satisfies Assumptions 1–4.Set the thresholdε=0.45 in the following example. In Figure 2, the trajectories of the actual state and the states estimated by the GMM-based estimation method with and without compensator are plotted. It is shown that the estimated states of the GMM-based method with compensator (dotted line) are closer to the actual state than that without compensator (red line). Figure 3 shows the estimation error covariance for the GMM-based method with and without compensator, respectively. It is observed that the estimation error covariance of the method without compensator (red line) is larger than that with compensator (black line), which means that the error compensator proposed in this paper can effectively reduce the impact of faulty data on state estimation. According to Figures 2 and 3, the estimation accuracy of the GMM-based estimation method with the compensator is higher than that without the compensator against dynamic attacks.Figure 2
The actual states and its remote estimation with different approaches.Figure 3
Remote estimation error covariance of the GMM-based method with and without compensator.The number of attacked sensors at each moment whenT≥31 is plotted in Figure 4, and the state estimation and corresponding error covariance of the GMM-based algorithm when the compensator takes different thresholds are shown in Figures 5 and 6, respectively. It is seen that the state estimation accuracy is higher when ε=0.45 and 0.65 than ε=0.15 and 0.95, which is indicated that the performance of the remote estimator will deteriorate while ε is too large or too small. Hence, the threshold can be adjusted according to the actual performance requirements of the real system.Figure 4
The number of attacked sensors at each moment whenT⩾31.Figure 5
Comparison of the state estimation with different thresholds.Figure 6
Remote estimation error covariance with different thresholds.


## 4.2. Example 2

Distributed and centralizedχ2 false-data detectors are common, and they determine whether an attack exists based on the statistical characteristics of the innovation yi,k−Cix^i,k− and yk−Cx^k−, respectively. From [21], a well-designed dynamic attack can successfully bypass the distributed χ2 detector but fails to remain stealthy to the centralized χ2 false-data detector. In this subsection, we have compared the proposed approach and the estimation methods based on different χ2 false-data detectors.Similar to [21], the attack signal ai,k is set as
(26)ai,k=−2yi,k+2Cix^k−,where ai,k satisfies Assumptions 1–4.In Figure7, the trajectories of the actual state and the state estimated by estimation methods based on different detectors are plotted, respectively. It is seen that the GMM-based state estimation (black line) is closer to the actual state than the state estimation based on the distributed and centralized χ2 detector (red and green). Figure 8 shows the estimation error covariance of the corresponding methods, and it is observed that the GMM-based estimation error covariance is much smaller than that based on the distributed and centralized χ2 detector. It can be seen that the GMM-based estimation approach proposed in this paper can improve the performance effectively.Figure 7
The actual states and its remote estimation based on different methods.Figure 8
Remote estimation error covariance based on different methods.


## 5. Conclusion

This paper studies the state estimation problem against dynamic malicious attacks. An error compensator is presented, which can reduce the influence of local error data on state estimation effectively. Based on that, a new GMM-based state estimation algorithm is proposed to improve the estimation accuracy for the system suffering from dynamic attacks. Finally, the effectiveness of the proposed algorithm is verified by numerical simulations. We will extend the GMM-based approach further to systems with parametric uncertainties in the future.



---

*Source: 2127102-2022-01-29.xml*