## 3 Fault Diagnosis: Machine Learning-based Adaptive Neuro High-Order Variable Structure Observer
### Fault Tolerant Control Using an Adaptive Modern Fuzzy Backstepping Variable Structure Controller
\begin{array}{l}V_{1}=0.5{\delta_{1}}^{2}\\ \dot{V}_{1}=\delta_{1}(\delta_{2}+\alpha_{1})=\delta_{1}(\delta_{2}-\zeta_{1} \delta_{1})=-\zeta_{1}|\delta_{1}|^{2}+\delta_{1}\delta_{2}\end{array} \right., \tag{49}\]  
So, if \(\delta_{2}=0\), then \(\delta_{1}\) will be stable. The derivative of \(\delta_{2}\) is  
\[\dot{\delta}_{2}=\dot{S}_{2}-\dot{\alpha}_{1}=\delta_{3}+\alpha_{2}-\dot{ \alpha}_{1}\ =\delta_{3}+\alpha_{2}+\zeta_{1}S_{2}. \tag{50}\]  
The Lyapunov function and the derivative of the Lyapunov function are  
\[\left\{ \begin{array}{l}if\ \alpha_{2}=-\zeta_{2}\delta_{2}-\delta_{1}-\zeta_{1}S_{ 2}\\ V_{2}=V_{1}+0.5{(\delta_{2})}^{2}\\ \dot{V}_{2}=\dot{V}_{1}+\delta_{2}\dot{\delta}_{2}=-\zeta_{1}|\delta_{1}|^{2}+ \delta_{1}\delta_{2}+\delta_{2}(\delta_{3}-\zeta_{2}\delta_{2}-\delta_{1})=- \zeta_{1}|\delta_{1}|^{2}-\zeta_{2}|\delta_{2}|^{2}+\delta_{2}\delta_{3}\end{array}  \right., \tag{51}\]  
So, if \(\delta_{3}=0\), then \(\delta_{1}\) and \(\delta_{2}\) will be stable. The Lyapunov function is defined by the following equation. \[V_{3}=V_{2}+0.5{(\delta_{3})}^{2}. \tag{52}\]  
Based on Equations (46) and (47), the derivative of the Lyapunov function is defined by the following equation. \[ \begin{array}{l}\dot{V}_{3}=\dot{V}_{2}+\delta_{3}\dot{\delta}_{3}=&-\zeta_ {1}|\delta_{1}|^{2}-\zeta_{2}|\delta_{2}|^{2}+\delta_{2}\delta_{3}+\delta_{3} \times\{\frac{d}{dt}\big{(}k_{1}\dot{e}+k_{2}\\ &\times[\alpha^{-1}(X_{1})\tau_{LPF}+\alpha^{-1}(X_{1})\beta\Big{(}\begin{array} []{cc}X_{1}&X_{2}\end{array}\Big{)}+\gamma(X_{1})+\alpha^{-1}\Theta-\ddot{X} _{1}])-\dot{\alpha}_{2}\}\\ \end{array}  \tag{53}\]So,  
\[ \begin{split}\dot{V}_{3}=-\zeta_{1}|\vartheta_{1}|^{2}-\zeta_{2}| \vartheta_{2}|^{2}-\zeta_{3}|\vartheta_{3}|^{2}+\vartheta_{3}\\ \times\left[\frac{d}{dt}\left(k_{1}\dot{e}+k_{2}\times\left[ \alpha^{-1}(X_{1})\tau_{LPF}+\alpha^{-1}(X_{1})\beta\left(\begin{array}{cc}X _{1}&X_{2}\\ \end{array}\right)+\gamma(X_{1})+\alpha^{-1}\Theta-\tilde{X}_{1}\right]\right)- \dot{\omega}_{2}\right]\\ \leq-\zeta_{1}|\vartheta_{1}|^{2}-\zeta_{2}|\vartheta_{2}|^{2}-\zeta_{3}| \vartheta_{3}|^{2}-(\zeta_{1}+\zeta_{2})|\vartheta_{3}|\\ \leq-\zeta_{1}|\vartheta_{1}|^{2}-\zeta_{2}|\vartheta_{2}|^{2}-\zeta_{3}| \vartheta_{3}|^{2}\end{split}  \tag{54}\]  
So, the \(\vartheta_{1}\), \(\vartheta_{2}\) and \(\vartheta_{3}\) converge to the zero in the finite time. Therefore, it can be concluded that the BVSC is stable. To reduce the effects of uncertain conditions, a PID fuzzy technique is designed and implemented in the robot manipulator. The classical PID fuzzy technique has three inputs; i.e., error \((e)\), differential of the error \(\left(\dot{e}\right)\), and an integral of the error \(\left(\dot{\sum e}\right)\). Therefore, the number of rules in the classical PID fuzzy controller is dramatically increased, causing an increase in the computational load. To design a minimum, rule-based, PID fuzzy controller, the PD-fuzzy-plus-PI-fuzzy algorithm is introduced. If the number of linguistic variables for the error, the differential of the error, and the integral of the error, is defined by \((N)\), the number of rules for the classical PID fuzzy controller is \(\left(N^{3}\right)\), but the number of rules for the PD-fuzzy-plus-PI-fuzzy algorithm is \(\left(2N^{2}\right)\). Thus, by applying this technique, the number of rules is reduced. However, while the number of rules is reduced, the PD-fuzzy-plus-PI-fuzzy approach requires a separate technique to design the PD and PI rule tables. To address this, a PI-like fuzzy algorithm can be designed based on the PD fuzzy technique. In this method, the integral term is used to change the PD-like fuzzy controller into a PI-like fuzzy controller by implementing the following steps. The membership functions of the PD fuzzy set for the system estimation of the error \((e)\) in the interval \(\left[ \begin{array}{cc}-0.3,&0.3\\ \end{array}