# Robust Backstepping Control of Wing Rock Using Disturbance Observer
## 3 Design of Disturbance Observer  
### Design of Disturbance Observer for the First Subsystem  
According to (1), the first subsystem can be written as  
\[\dot{x}_{1}=f_{1}(x_{1})+g_{1}(x_{1})x_{2}+\Delta f_{1}\left(x_{1}\right)+d_{ 1}\left(t\right) \tag{12}\]  
In (12), the system uncertainty \(\Delta f_{1}\left(x_{1}\right)\) and external disturbance \(d_{1}(t)\) are considered simultaneously. In traditional ESO method, \(\Delta f_{1}\left(x_{1}\right)\) and \(d_{1}(t)\) are merged into a single equivalent uncertainty. To improve the disturbance estimation performance, it is necessary to introduce different mechanisms to handle the system uncertainty and the external disturbance separately. To efficiently tackle the unknown function vector \(\Delta f_{1}\left(x_{1}\right)\), the RBFNN is employed to approximate it. The approximation output of the RBFNN can be written as  
\[\Delta f_{1}\left(x_{1}\right)={W_{1}^{*}}^{T}S_{1}\left(J_{1}\right)+\iota_{ 1}^{*} \tag{13}\]  
where \(J_{1}=x_{1}\), \({W_{1}^{*}}^{T}=\left[{W_{11}^{*}},{W_{12}^{*}}\right]^{T}\in R^{2\times P_{1 }}\), \(S_{1}\left(J_{1}\right)\in R^{p_{1}}\), \(\iota_{1}^{*}\in R^{2\times 1}\). Substituting (13) into (12), we obtain  
\[\dot{x}_{1}=f_{1}(x_{1})+g_{1}(x_{1})x_{2}+{W_{1}^{*}}^{T}S_{1}\left(J_{1} \right)+D_{1} \tag{14}\]  
where \(D_{1}=d_{1}\left(t\right)+\iota_{1}^{*}\). Extending \(D_{1}\) as an additional state variable, i.e., defining \(x_{3}=D_{1}\), (14) can be rewritten as  
\[\dot{x}_{1} = f_{1}(x_{1})+g_{1}(x_{1})x_{2}+{W_{1}^{*}}^{T}S_{1}\left(J_{1} \right)+x_{3}\] \[\dot{x}_{3} = \hbar_{1}\left(t\right) \tag{15}\]  
where \(x_{3}=\left[x_{31},x_{32}\right]^{T}\); \(\hbar_{1}=\left[\hbar_{11},\hbar_{12}\right]^{T}\) is an unknown bounded time derivative function vector of \(D_{1}\). According to the structure of extended system (15), a linear ESO combined with the RBFNN can be constructed as  
\[\dot{x}_{1} = f_{1}(x_{1})+g_{1}(x_{1})x_{2}+\hat{W}_{1}^{T}S_{1}\left(J_{1} \right)+\hat{x}_{3}-l_{1s}\tilde{x}_{1}\] \[\dot{x}_{3} = -l_{2s}\tilde{x}_{1} \tag{16}\]  
where \(\hat{x}_{1}\), \(\hat{x}_{3}\) are the states of the observer (16); \(\hat{x}_{1}\) is the estimation of \(x_{1}\); \(\hat{W}_{1}^{T}=\left[\hat{W}_{11},\hat{W}_{12}\right]^{T}\in R^{2\times P_{1}}\) is the estimation of \(W_{1}^{*}\); \(\hat{x}_{3}\) is the estimation of \(x_{3}\); \(\tilde{x}_{1}=\hat{x}_{1}-x_{1}\); And \(l_{1s}=diag\{l_{1s1},l_{1s2}\}>0\), \(l_{2s}=diag\{l_{2s1},l_{2s2}\}>0\) are design matrixes. Invoking (15) and (16), we obtain  
\[\dot{\tilde{x}}_{1} = \hat{W}_{1}^{T}S_{1}\left(J_{1}\right)+\tilde{x}_{3}-l_{1s}\tilde{ x}_{1}\] \[\dot{\tilde{x}}_{3} = -l_{2s}\tilde{x}_{1}-\hbar_{1} \tag{17}\]Define \(\left[\varepsilon_{11},\varepsilon_{12}\right]^{T}=\left[\tilde{x}_{11},\tilde{x}_{1 2}\right]^{T}\), \(\left[\varepsilon_{31},\varepsilon_{32}\right]^{T}=\left[\frac{\tilde{x}_{31}}{ \omega_{11}},\frac{\tilde{x}_{32}}{\omega_{12}}\right]^{T}\). Then (17) can be written as  
\[\left[ \begin{array}{c}\dot{\varepsilon}_{1i}\\ \dot{\varepsilon}_{3i}\end{array} \right]=\omega_{1i}A_{si}\left[ \begin{array}[ ]{c}\varepsilon_{1i}\\ \varepsilon_{3i}\end{array} \right]+B_{si}\tilde{W}_{1i}^{T}S_{1}\left(I_{1} \right)-C_{si}\frac{h_{1i}}{\omega_{1i}}\quad i=1,2 \tag{18}\]  
where \(A_{si}=\left[ \begin{array}{cc}\frac{-I_{lsi}}{\omega_{1i}}&1\\ \frac{-I_{lsi}}{\omega_{1i}^{2}}&0\end{array} \right]\), \(B_{si}=\left[ \begin{array}{c}1\\ 0\end{array} \right]\), \(C_{si}=\left[ \begin{array}{c}0\\ 1\end{array} \right]\); And \(\omega_{1i}>0,i=1,2\) is a design constant. Hence, it can be easily proved that \(A_{si}\) is Hurwitz, if \(l_{1 si}=2k_{si}\omega_{1i}\), \(l_{2 si}=k_{si}^{2}\omega_{1i}^{2}\), \(i=1,2\), and \(k_{si}\) is a positive constant. Thus, there exists a positive definite matrix \(P_{si},i=1,2\) satisfying the following Lyapunov equation:  
\[A_{si}^{T}P_{si}+P_{si}A_{si}=-2I \tag{19}\]  
In this subsection, the disturbance observer (16) for the first subsystem (12) has been proposed.