# Mean Square Consensus of Nonlinear Multi-Agent Systems under Markovian Impulsive Attacks
## 3 Main Results  
**Theorem 1**. : _Under Assumptions 1 and 2, the mean square consensus of system (1) with controller (2) under the Markovian impulsive attacks can be reached if there exist symmetric positive definite matrix \(P\) and feedback gain \(K\) such that_  
\[\sum_{j=1}^{p}\max_{i\in\Gamma}\{p_{ij}\}\frac{\lambda_{j}v_{j}}{\lambda_{j}- \gamma}<1 \tag{6}\]  
_where \(\gamma=\rho\beta<\min_{j\in\Gamma}\{\lambda_{j}\}\), \(\rho=\frac{\lambda_{\max}(P)}{\lambda_{\min}(P)}\), \(\beta=\lambda_{\max}(\Pi)\), and \(\Pi=H^{T}+\kappa\bar{B}^{T}+PH+\kappa\bar{B}\)._  
Proof. : Consider the following Lyapunov function candidate  
\[V(t,e(t))=e^{T}(t)Pe(t). \tag{7}\]  
For \(t\in[t_{k-1},t_{k})\), one can obtain the derivatives of \(V(t,e(t))\):  
\[ \begin{split} D^{+}& V(t,e(t))\\ &=\dot{e}^{T}(t)Pe(t)+e^{T}(t)P\dot{e}(t)\\ &\leq e^{T}(t)\Big{(}H^{T}P+\kappa\bar{B}^{T}P+PH+\kappa P\bar{B }\Big{)}e(t)\\ &\leq\gamma V(t,e(t)).\end{split}  \tag{8}\]  
where \(\gamma=\rho\beta\). For \(t=t_{k}\), caused by the impulsive attacks, we have  
\[ \begin{split} V(t_{k},e(t_{k}))&=e^{T}(t_{k})Pe(t _{k})\\ &=\eta_{k}^{2}e^{T}(t_{k}^{-})Pe(t_{k}^{-})\\ &\leq\eta_{k}^{2}e^{\gamma\tau_{k}}V(t_{k-1},e(t_{k-1})).\end{split}  \tag{9}\]  
Since the items \(e^{\gamma\tau_{k}}\) and \(V(t_{k-1},e(t_{k-1}))\) are nonnegative random variables, by taking the expectation and utilizing the properties of the conditional expectations, we obtain  
\[ \begin{split}\mathbb{E}&[V(t_{k},e(t_{k}))]\\ &\leq\mathbb{E}[\mathbb{E}[\eta_{k}^{2}e^{\gamma\tau_{k}}V(t_{k- 1},e(t_{k-1}))|\mathcal{F}_{k-1}]]\\ &=\mathbb{E}[\mathbb{E}^{2}[\mathbb{E}^{1}[\eta_{k}^{2}e^{\gamma \tau_{k}}V(t_{k-1},e(t_{k-1}))|\mathcal{F}_{k-1}^{1}]|\mathcal{F}_{k-1}^{2}]\\ &=\mathbb{E}[V(t_{k-1},e(t_{k-1}))]\mathbb{E}[\mathbb{E}[\eta_{k} ^{2}e^{\gamma\tau_{k}}|r_{k-1}]].\end{split}  \tag{10}\]  
For \(t\in[t_{0},t_{1})\), it follows from (8) that we have  
\[\mathbb{E}[V(t,e(t))]\leq\mathbb{E}[\mathbb{E}[e^{\gamma\tau_{1}}|r_{0}]] \mathbb{E}[V(t_{0},e(t_{0}))]\]from which one can get that, for \(t=t_{1}\),  
\[\mathbb{E}[V(t_{1},e(t_{1}))]\leq\mathbb{E}[\mathbb{E}[\eta_{1}^{2}e^{\gamma\tau_ {1}}|r_{0}]]\mathbb{E}[V(t_{0},e(t_{0}))].\]  
For \(t\in[t_{1},t_{2})\), we obtain a similar result from (8) and (10):  
\[\mathbb{E}[V(t,e(t))]\leq\mathbb{E}[\mathbb{E}[e^{\gamma\tau_{2}}|r_{1}]] \mathbb{E}[V(t_{1},e(t_{1}))]\]  
from which one can get that, for \(t=t_{2}\),  
\[\mathbb{E}[V(t_{2},e(t_{2}))]\leq\prod_{l=1}^{2}\mathbb{E}[\eta_{l}^{2}e^{ \gamma\tau_{l}}|r_{l-1}]\mathbb{E}[V(t_{0},e(t_{0}))].\]  
By mathematical induction, one can finally obtain that, for \(t=t_{k}\),  
\[ \begin{split}\mathbb{E}[& V(t_{k},e(t_{k}))]\\ &\leq\mathbb{E}[V(t_{0},e(t_{0}))]\prod_{l=1}^{k}\mathbb{E}[ \mathbb{E}[\eta_{k}^{2}e^{\gamma\tau_{l}}|r_{l-1}]]\\ &=\mathbb{E}[V(t_{0},e(t_{0}))]\mathbb{E}[\prod_{l=1}^{k}\mathbb{ E}^{2}[\mathbb{E}^{1}[\eta_{k}^{2}]e^{\gamma\tau_{l}}|r_{l-1}].\end{split}  \tag{11}\]  
Let \(i_{l}\in\mathbb{I},l\in\mathbb{N}\). Since the impulsive sequence \(\{\eta_{k},r_{k},k\in\mathbb{N}^{+}\}\) with respect to \(t_{k}\) is a Markovian chain and the impulsive interval \(\tau(k)\sim Exp(\lambda_{i})\), then we have  
\[ \begin{split}&\mathbb{E}[\prod_{l=1}^{k}\mathbb{E}^{2}[\mathbb{E}^{ 1}[\eta_{l}^{2}]e^{\gamma\tau_{l}}|r_{l-1}]]\\ &=\sum_{i_{1}=1}^{p}\sum_{i_{2}=1}^{p}\dots\sum_{i_{k}=1}^{p}\prod _{m=1}^{k}\mathbb{E}^{2}[\mathbb{E}^{1}[\eta_{i_{m}}^{2}]e^{\gamma\tau_{lm}} ]|r_{i_{m-1}}]\\ &\qquad\times P(r_{i_{1}}=i_{1},r_{i_{2}}=i_{2},\dots,r_{i_{k}}=i _{k})\\ &\leq\sum_{i_{1}=1}^{p}\sum_{i_{2}=1}^{p}\dots\sum_{i_{k}=1}^{p} \prod_{m=1}^{k}\int_{0}^{+\infty}e^{\gamma s}\lambda_{i_{m}}e^{-\lambda_{i_{m} }s}ds\\ &\qquad\times\prod_{m=1}^{k}\max_{i\in\Gamma}\{p_{i_{lm}}\} \mathbb{E}^{1}[\eta_{i_{m}}^{2}]\\ &\leq\sum_{i_{1}=1}^{p}\sum_{i_{2}=2}^{p}\dots\sum_{i_{k}=1}^{p} \prod_{m=1}^{k}\frac{\lambda_{i_{m}}\mathbb{E}^{1}[\eta_{i_{m}}^{2}]}{\lambda _{i_{m}}-\gamma}\max_{i\in\Gamma}\{p_{i_{m}}\}\\ &=\theta^{k}.\end{split}