# Nonsingular Terminal Sliding Mode Based Finite-Time Dynamic Surface Control for a Quadrotor UAV
## 2 Quadrotor Model  
As shown in Figure 1, four motors are used to generate thrust for the quadrotor UAV. The four types of thrust can be expressed as \(F_{i}\) (\(i=1,\,2,\,3,\,4\)), and these can be controlled by adjusting the steering of the motors. The dynamics of the quadrotor UAV are represented as [40]:  
\[ \begin{cases}\ddot{x}=\frac{u_{F}}{m}(\text{cos}\phi\text{sin}\theta\text{ cos}\psi+\text{sin}\theta\text{sin}\psi)-\frac{k_{1}}{m}\dot{x}+d_{1}\\ \ddot{y}=\frac{u_{F}}{m}(\text{cos}\phi\text{sin}\theta\text{sin}\psi-\text{ sin}\phi\text{cos}\psi)-\frac{k_{2}}{m}\dot{y}+d_{2}\\ \ddot{z}=\frac{u_{F}}{m}(\text{cos}\phi\text{cos}\theta)-g-\frac{k_{3}}{m} \dot{z}+d_{3}\\ J_{1}\ddot{\phi}=-k_{4}l\dot{\phi}+d_{4}+lu_{1}-\Delta J_{1}\ddot{\phi}\\ J_{2}\ddot{\theta}=-k_{5}l\dot{\theta}+d_{5}+lu_{2}-\Delta J_{2}\ddot{\theta}\\ J_{3}\ddot{\psi}=-k_{6}\dot{\psi}+d_{6}+cu_{3}-\Delta J_{3}\ddot{\psi}\end{cases}  \tag{1}\]  
where \((x,\,y,\,z)\) and \((\phi,\,\theta,\,\psi)\) represent the position and attitude of the quadrotor UAV, respectively; \(\psi\in(-\pi,\,\pi)\) is yaw; \(\theta\in(-\pi/2,\,\pi/2)\) is pitch; \(\phi\in(-\pi/2,\,\pi/2)\) is roll; \(m\in\mathbb{R}^{+}\) is the mass of the quadrotor UAV; \(d_{i}\in\mathbb{R}(i=1,\,2,\,\,\dots,\,6)\) is the external disturbance; \(J_{i}\in\mathbb{R}^{+}\) (\(i=1,\,2,\,3\)) is the moment of inertia; \(k_{i}\in\mathbb{R}^{+}(i=1,\,2,\,\,\dots,\,6)\) represents the aerodynamic damping coefficient; \(\Delta J_{i}\in\mathbb{R}\) (\(i=1,\,2,\,3\)) is the uncertainty of the moment of inertia; \(l\in\mathbb{R}^{+}\) is the distance from the motor to the center of mass; \(c\in\mathbb{R}^{+}\) denotes the force-to-moment factor; and \(u_{F},\,u_{1},\,u_{2},\,u_{3}\) are the control inputs of the position and attitude subsystems, respectively. **Lemma 1** ([41]). : _Consider the following system_  
\[\dot{\delta}=f(\delta),\,\delta(0)=\delta_{0},\,f(0)=0,\,\delta\in\mathbb{R}^ {n} \tag{2}\]  
_where \(\delta=[\delta_{1},\,\delta_{2},\dots,\,\delta_{n}]^{\text{T}}\) is the state vector. Suppose there is a positive definite Lyapunov function \(V(\delta)\), which is defined on a neighborhood \(\mathbb{U}\subset\mathbb{R}^{n}\) of the origin. For any \(\delta\in\mathbb{U}\backslash\{0\}\), if the inequality_  
\[\dot{V}(\delta)+v_{1}V(\delta)^{p}\leqslant 0 \tag{3}\]  
Figure 1: The structure of the quadrotor UAV. is satisfied with \(v_{1}>0\), \(0<p<1\). The system is finite-time stable, and the settling time is_  
\[t_{1}\leq\frac{1}{v_{1}(1-p)}|V(\delta_{0})|^{1-p} \tag{4}\]  
**Lemma 2** ([42]). : _Consider the system in (2). For \(p\in(0,1)\), \(v_{1}>0\) and \(v_{2}>0\), suppose a positive definite Lyapunov function \(V(\delta)\) exists, which satisfies_  
\[\dot{V}(\delta)\leq-v_{1}V(\delta)-v_{2}V(\delta)^{p} \tag{5}\]  
_such that the origin of the system is finite-time stable. The settling time is_  
\[t_{2}\leq\frac{1}{v_{1}(1-p)}\ln\frac{v_{1}V(\delta_{0})^{1-p}+v_{2}}{v_{2}} \tag{6}\]  
**Lemma 3** ([43]). : _Consider the system in (2). If a Lyapunov function \(V(\delta)\) exists, which satisfies_  
\[\dot{V}(\delta)\leq-v_{1}V(\delta)^{p}+v_{2} \tag{7}\]  
_with \(p\in(0,1)\), \(v_{1}>0\), \(v_{2}>0\). The system is finite-time stable in a neighborhood of the origin. The settling time \(t_{3}\) is given by_  
\[t_{3}\leq\frac{V(\delta_{0})^{1-p}}{v_{1}\theta_{1}(1-p)},\ \theta_{1}\in(0,1) \tag{8}\]  
**Lemma 4** ([25]). : _Consider a general second-order system_  
\[ \begin{cases}\dot{\delta}_{1}=\delta_{2}\\ \dot{\delta}_{2}=f(t,\,\delta)+g(t,\,\delta)(u+d(t,\,\delta))\end{cases}  \tag{9}\]  
_where \(\delta=[\delta_{1},\,\delta_{2}]^{\mathrm{T}}\) is the state vector; \(u\) denotes the control input; \(f(t,\,\delta)\) and \(g(t,\,\delta)\) satisfy \(f(t,\,0)=0\) and \(g(t,\,\delta)\
eq 0\), respectively; and \(d(t,\,\delta)\) represents the lumped disturbance._  
_The following sliding mode variable is designed as_  
\[s=\delta_{2}+2\zeta\sqrt{|\arctan(\delta_{1})|}(1+\delta_{1}^{2})\mathrm{ sign}(\delta_{1}) \tag{10}\]  
_with \(\zeta>0\).