# An Adaptive Control Based on Improved Gray Wolf Algorithm for Mobile Robots
## 3 Design of the Adaptive Controller
\begin{array}{ll}\dot{V}&=&-\frac{1}{2}\widetilde{z}^{T}(t)\Big{(}\frac{1}{2 }PBR^{-1}B^{T}P+\frac{1}{2}\dot{A}^{-T}Q\dot{A}^{-1}\Big{)}\widetilde{z}^{T}( t)\\ &-\xi^{T}K_{\epsilon}\xi+\xi^{T}\varepsilon+\xi^{T}\widetilde{\Lambda}\Psi\\ &+tr\Big{(}\widetilde{\Lambda}^{T}Q^{-1}\dot{\Lambda}\Big{)}+\widetilde{f}r_ {4}\upsilon_{t}+\eta\widetilde{f}\widetilde{f}\widetilde{f}\\ &+\alpha\Big{\|}r^{T}\|tr\Big{\{}\widetilde{\delta}^{T}\dot{\delta}\Big{\}}- tr\Big{\{}\widetilde{\delta}diag\left[\left|\widetilde{z}^{T}(t)PB\right|\right] \right\}\\ &=&-\frac{1}{2}\widetilde{z}^{T}(t)\Big{(}\frac{1}{2}PBR^{-1}B^{T}P+\frac{1}{2 }\dot{A}^{-T}Q\dot{A}^{-1}\Big{)}\widetilde{z}^{T}(t)\\ &-\xi^{T}K_{\epsilon}\xi+\xi^{T}\varepsilon+tr\Big{(}\widetilde{\Lambda}^{T}Q ^{-1}\dot{\Lambda}+\widetilde{\Lambda}\Psi\xi^{T}\Big{)}\\ &+\widetilde{f}r_{4}\upsilon_{t}+\eta\widetilde{f}\widetilde{f}+f^{T}\Big{[} -\delta^{T}sign\left(B^{T}P_{2}^{\sim}(t)\right)+\varphi\Big{]}\\ &+\alpha\Big{\|}\Big{[}fB^{T}P_{2}^{\sim}(t)\Big{]}^{T}\Big{\|}tr\left\{ \widetilde{\delta}^{T}\dot{\delta}\right\}\end{array}  \tag{36}\]  
Using the Cauchy-Schwarz inequality, one can obtain  
\[ \begin{array}{ll}&f^{T}\Big{[}-\delta^{T}sign\Big{(}B^{T}P_{2}^{\sim}(t) \Big{)}+\varphi\Big{]}\\ &\leq&\|f^{T}\|\Big{(}-\lambda_{min}\{\delta\}+\Big{\|}B^{T}P_{2}^{\sim}(t) \Big{\|}\Big{)}\\ &\leq&0\end{array}  \tag{37}\]  
by virtue of the previous assumptions. Moreover, according to the Frobenius norm \(\|\cdot\|_{F}\), one can obtain  
\[ \begin{array}{ll}tr\bigg{\{}\widetilde{\delta}^{T}\dot{\delta}\bigg{\}}&=tr \bigg{\{}\widetilde{\delta}^{T}\Big{(}\delta-\widetilde{\delta}\Big{)} \bigg{\}}=tr\bigg{\{}\widetilde{\delta}^{T}\dot{\delta}\bigg{\}}-\left\| \widetilde{\delta}^{T}\right\|_{F}^{2}\\ &\leq&\left\|\widetilde{\delta}^{T}\right\|_{F}\bigg{(}\|\delta\|_{F}-\left\| \widetilde{\delta}^{T}\right\|_{F}\bigg{)}\\ &\leq&\left\|\widetilde{\delta}^{T}\right\|_{F}\bigg{(}\delta_{b}-\left\| \widetilde{\delta}^{T}\right\|_{F}\bigg{)}\end{array}  \tag{38}\]  
where \(\left\|\delta\right\|_{F}\leq\delta_{b}<\infty\). Substituting (37) and (38) into (36) yields  
\[ \begin{array}{ll}\dot{V}\leq-\|f\|\bigg{[}\lambda_{min}\{F\}\|f\|+\alpha \bigg{\|}\widetilde{\delta}^{T}\bigg{\|}_{F}\bigg{(}\left\|\widetilde{\delta}^ {T}\right\|_{F}-\delta_{b}\bigg{)}\bigg{]}\\ &-\xi^{T}K_{\epsilon}\xi+n\|\xi\|tr\Big{[}\widetilde{\Lambda}^{T}\bigg{(} \Lambda-\widetilde{\Lambda}\bigg{)}\bigg{]}+M\end{array}  \tag{39}\]where \(M=\overset{\sim}{fr_{4}}v_{l}-\eta\overset{\sim\sim\sim}{ff}\), \(\left\|\overset{\sim}{z}\right\|^{2}=\left\|r\right\|^{2}+\left\|rf\right\|^{2}\). To ensure that \(M\leq 0\), the following definition is made  
\[\overset{\sim}{f}= \begin{cases}\eta^{-1}r_{4}v_{l},r_{4}v_{l}>0\\ \eta^{-1}r_{4}v_{l},r_{4}v_{l}\leq 0,\overset{\sim}{f}>f\\ \eta^{-1},r_{4}v_{l}\leq 0,\overset{\sim}{f}\leq f\end{cases}  \tag{40}\]  
Substituting (40) into the \(M\) function, one can obtain (i) If \(r_{4}v_{l}>0\), then \(M=0\). (ii) If \(r_{4}v_{l}\leq 0\) and \(\overset{\sim}{f}>f\), then \(M=0\). (iii) Since \(r_{4}v_{l}\leq 0\), \(\overset{\sim}{f}\leq f\) and \(\overset{\sim}{f}=f-\overset{\sim}{f}>0\), then \(M\leq 0\).