## 3 Control Design
### Adaptive Sliding Mode Control
: The Lyapunov function is selected as follows:  
\[V_{1}=\frac{1}{2}\mathbf{s}^{T}\mathbf{M}(\mathbf{x}_{1})\mathbf{s}+\frac{1}{ 2}\mathbf{\eta}^{-T}\mathbf{\kappa}_{1}^{-1}\mathbf{\kappa}_{2}^{-}\mathbf{ \eta} \tag{14}\]  
where \(\widetilde{\eta}_{i}=\eta_{i}^{*}-\hat{\eta}_{i}\), \((i=1,\ldots,n)\) are robust gain errors. **Assumption 3**. : _The robust gain error term (14) is bounded. The condition \(\underline{1}\underline{2}\mathbf{\eta}^{-T}\mathbf{\kappa}_{1}^{-1}\mathbf{ \kappa}_{2}^{-}\mathbf{\eta}\leq\zeta_{\eta}\) holds._  
Taking the derivative of the Lyapunov function, \(V_{1}\), with respect to time, we have  
\[\dot{V}_{1} =\mathbf{s}^{T}\mathbf{M}(\mathbf{x}_{1})\dot{\mathbf{s}}+ \frac{1}{2}\mathbf{s}^{T}\dot{\mathbf{M}}(\mathbf{x}_{1})\mathbf{s}+\mathbf{ \eta}^{-T}\mathbf{\kappa}_{1}^{-1}\mathbf{\kappa}_{2}^{-}\mathbf{\dot{\eta}} \tag{15}\] \[=\mathbf{s}^{T}\mathbf{M}(\mathbf{x}_{1})\big{(}\lambda\dot{ \mathbf{e}}+\mathbf{M}^{-1}(\mathbf{x}_{1})(\mathbf{B}\mathbf{u}-\mathbf{C}( \mathbf{x}_{1},\mathbf{x}_{2})\mathbf{x}_{2}-\mathbf{G}(\mathbf{x}_{1})- \mathbf{d}_{1}(t))\ -\ddot{\mathbf{x}}_{d}\big{)}\big{)}+\frac{1}{2}\mathbf{s}^{T}\dot{ \mathbf{M}}(\mathbf{x}_{1})\mathbf{s}+\mathbf{\eta}^{-T}\mathbf{\kappa}_{1}^{- 1}\mathbf{\kappa}_{2}^{-1}\mathbf{\dot{\eta}}\]By applying the control laws (9) and skew-matrix property in (15), the result is presented as follows:  
\[ \begin{array}{l}\dot{V}_{1}=\mathbf{s}^{T}\bigg{(}-\mathbf{k}\mathbf{s}- \overset{\star}{\eta}sign(\mathbf{s})-\mathbf{d}(t)\bigg{)}+\overset{\star}{ \eta}^{T}\mathbf{\kappa}_{1}^{-1}\mathbf{\kappa}_{2}\overset{\cdot}{\eta}\\ \leq-\mathbf{s}^{T}\mathbf{k}\mathbf{s}-\overset{n}{\underset{i=1}{\sum}}( \hat{\eta}_{i}-|d_{i}(t)|)|s_{i}|-\overset{n}{\underset{i=1}{\sum}}\tilde{ \eta}_{i}\kappa_{1i}^{-1}\kappa_{2i}\overset{\cdot}{\eta_{i}}\\ \leq-\overset{n}{\underset{i=1}{\sum}}\left(k_{i}s_{i}^{2}-\widetilde{\eta}_{ i}\Big{(}|s_{i}|-\kappa_{1i}^{-1}\kappa_{2i}\hat{\hat{\eta}}_{i}\Big{)}\right)\end{array}  \tag{16}\]  
Now, we take into account two adaptive cases: \(\left\|s\right\|_{\infty}\geq\varepsilon_{1}\) and \(\left\|s\right\|_{\infty}<\varepsilon_{1}\). In the first case, \(\left\|s\right\|_{\infty}\geq\varepsilon_{1}\), the differential Lyapunov function is presented as follows:  
\[\dot{V}_{1}=-\overset{n}{\underset{i=1}{\sum}}k_{i}s_{i}^{2}\leq-\overset{n} {\underset{i=1}{\sum}}k_{i}\varepsilon_{1}^{2} \tag{17}\]  
This result shows that \(V_{1}\) is decreasing and bounded since \(0\leq V_{1}(t)\leq V_{1}(0)\leq\infty\). It means that the sliding variable \(s_{i}\) reaches the small region of the sliding surface, i.e., \(|s_{i}|\leq\varepsilon_{1}\). In the other cases, \(\left\|s\right\|_{\infty}\leq\varepsilon_{1}\), it means that all sliding variables \(s_{i}\) approach the regions \(|s_{i}|\leq\varepsilon_{1}\), and they may move in or leave the regions because \(\dot{V}_{1}\) is not guaranteed to be semi-negative in the vicinity of the sliding manifold. If any sliding variable \(s_{i}\) moves out of the region \(|s_{i}|\leq\varepsilon_{1}\), then \(\dot{V}_{1}\) will become negative again. This result will force the variable to go back toward the sliding surfaces. When all the sliding variables, \(s_{i}\), stay in the region \(|s_{i}|\leq\varepsilon_{1}\), the upper bound of the sliding variable is computed as follows:  
\[\frac{1}{2}\mathbf{s}^{T}\mathbf{M}(\mathbf{x}_{1})\mathbf{s}\leq V_{1}\leq \frac{1}{2}\mathbf{s}^{T}\mathbf{M}(\mathbf{x}_{1})\mathbf{s}+\frac{1}{2} \overset{\star}{\eta}\mathbf{\kappa}_{1}^{-1}\mathbf{\kappa}_{2}\overset{ \cdot}{\eta} \tag{18}\]  
Since \(\frac{1}{2}\overset{\star}{\eta}\mathbf{\kappa}_{1}^{-1}\mathbf{\kappa}_{2} \overset{\cdot}{\eta}\) in (18) is bounded, we have  
\[V_{1}<\frac{1}{2}\lambda_{\text{max}}(M(x_{1}))n\varepsilon^{2}+\frac{1}{2} \zeta_{\eta} \tag{19}\]  
Based on (18) and (19), we obtain  
\[