## 2 Dynamic Model of Quadrotor Aircrafts
\right., \tag{7}\]  
where \(I_{3\times 3}=diag(I_{x},I_{y},I_{z})\) is the inertia matrix; \(\tau^{B}=\left[\dot{\phi}\quad\dot{\theta}\quad\dot{\psi}\right]^{T}\) is the angular velocity; \(\varsigma^{B}\) is the resultant moment; \(P^{B}\) and \(Q^{B}\) are the pulling torque and reaction torque of the four-wheel drive motor, respectively; \(f_{2}^{B}=\left[-lk_{f}\dot{\phi}\quad-lk_{f}\dot{\phi}\quad-k_{f}\dot{\psi} \right]^{T}\) is the matrix of air resistance. \[P^{B}= \begin{bmatrix}b_{1}\sqrt{l^{2}-z_{2}^{2}}(-L_{1}+L_{2}+L_{3}-L_{4})\\ b_{1}\sqrt{l^{2}-z_{2}^{2}}(-L_{1}-L_{2}+L_{3}+L_{4})\\ 0\end{bmatrix} , \tag{8}\]  
\[Q^{B}= \begin{bmatrix}0\\ 0\\ b_{2}(L_{1}-L_{2}+L_{3}-L_{4})\end{bmatrix} . \tag{9}\]  
In summary, we can obtain attitude dynamics equation of the quadrotor. \[\left\{ \begin{array}{l}\ddot{\phi}=-lk_{f}\dot{\phi}/I_{x}+b_{1}\sqrt{l^{2} -z_{2}^{2}}(-L_{1}+L_{2}+L_{3}-L_{4})/I_{x}+(I_{y}-I_{z})\dot{\psi}\dot{\theta }/I_{x}\\ \ddot{\psi}=-k_{f}\dot{\psi}/I_{z}+b_{2}(L_{1}-L_{2}+L_{3}-L_{4})/I_{z}+(I_{x}- I_{y})\dot{\phi}\dot{\theta}/I_{z}\\ \ddot{\theta}=-lk_{f}\dot{\theta}/I_{y}+b_{1}\sqrt{l^{2}-z_{2}^{2}}(-L_{1}-L_{ 2}+L_{3}+L_{4})/I_{y}+(I_{z}-I_{x})\dot{\phi}\dot{\psi}/I_{y}\end{array} \right., \tag{10}\]  
where \(\psi\), \(\phi\), and \(\theta\) are the yaw angle, roll angle and pitch angle, respectively. To simplify the quadrotor dynamic equation, \((U_{1},U_{2},U_{3},U_{4})\) is used to represent the relevant parameters. \[ \begin{bmatrix}U_{1}\\ U_{2}\\ U_{3}\\ U_{4}\end{bmatrix} = \begin{bmatrix}\frac{1}{(M-\Delta M)}&\frac{1}{(M-\Delta M) }&\frac{1}{(M-\Delta M)}\\ -\frac{b_{1}}{I_{x}}&\frac{b_{1}}{I_{x}}&\frac{b_{1}}{I_{x}}&-\frac{b_{1}}{I_{x }}\\ -\frac{b_{1}}{I_{y}}&-\frac{b_{1}}{I_{y}}&\frac{b_{1}}{I_{y}}&\frac{b_{1}}{I_{y }}\\ \frac{b_{2}}{I_{x}}&-\frac{b_{2}}{I_{x}}&\frac{b_{2}}{I_{x}}&-\frac{b_{2}}{I_{x }}\end{bmatrix}\begin{bmatrix}L_{1}\\ L_{2}\\ L_{3}\\ L_{4}\end{bmatrix} . \tag{11}\]In summary, we can obtain the dynamic equation of the quadrotor. \[\left\{ \begin{array}{l}\ddot{x}=-k_{f}\dot{x}/(M-\Delta m)+U_{1}(\sin\phi\sin \psi+\cos\psi\cos\phi\sin\theta)\\ \ddot{y}=-k_{f}\dot{y}/(M-\Delta m)+U_{1}(-\sin\phi\cos\psi+\sin\psi\cos\phi \sin\theta)\\ \ddot{z}=-k_{f}\dot{z}/(M-\Delta m)-g+U_{1}\cos\phi\cos\theta\\ \ddot{\theta}=U_{3}\sqrt{l^{2}-z_{a}^{2}}+(I_{z}-I_{x})\dot{\phi}\dot{\psi}/I_ {y}-lk_{f}\dot{\phi}/I_{y}\\ \ddot{\phi}=U_{2}\sqrt{l^{2}-z_{a}^{2}}+(I_{y}-I_{z})\dot{\theta}\dot{\psi}/I_ {x}-lk_{f}\dot{\phi}/I_{x}\\ \ddot{\psi}=U_{4}+(I_{x}-I_{y})\dot{\phi}\dot{\theta}/I_{z}-k_{f}\dot{\psi}/I_ {z}\end{array} \right.. \tag{12}\]  
Equation (13) can also be written as [30]  
\[\left\{ \begin{array}{l}\dot{x}_{1}=x_{2}\\ \dot{x}_{2}=Au(n)+B+c\end{array} \right., \tag{13}\]  
\[\text{where}\;x_{1}= \begin{bmatrix}z&\phi&\theta&\psi\end{bmatrix} ^{T},u(n)= \begin{bmatrix}U_{1}&U_{2}&U_{3}&U_{4}\end{bmatrix} ^{T};\]  
\[A= \begin{bmatrix}\cos\theta\cos\phi&0&0&0\\ 0&\sqrt{l^{2}-z_{a}^{2}}&0&0\\ 0&0&\sqrt{l^{2}-z_{a}^{2}}&0\\ 0&0&0&1\end{bmatrix} B= \begin{bmatrix}-g-k_{f}\dot{z}/(M-\Delta M)\\ -lk_{f}\dot{\phi}/I_{x}+(I_{y}-I_{z})\dot{\psi}\dot{\theta}/I_{x}\\ -lk_{f}\dot{\theta}/I_{y}+(I_{z}-I_{x})\dot{\psi}\dot{\phi}/I_{y}\\ -k_{f}\dot{\psi}/I_{z}+(I_{x}-I_{y})\dot{\phi}\dot{\theta}/I_{z}\end{bmatrix} .\]