## 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
To improve the fault-tolerant control scenario, the MFBVSC is represented as follows:  
\[U_{MFBVSC}=U_{VSC}+U_{B}+U_{PID-fuzzy}+U_{O},\] \[U_{VSC}=\hat{\alpha}\big{(}\hat{X}_{1}\big{)}\times\Big{[}\mu_{1 }sgn\big{(}X_{1}-\hat{X}_{1}\big{)}+\mu_{2}sgn\big{(}X_{2}-\hat{\hat{X}}_{1} \big{)}\Big{]}+\hat{\alpha}\big{(}\hat{X}_{1}\big{)}\times\] \[\Big{[}\hat{\beta}\big{(}\hat{\hat{X}}_{1}\quad\hat{\hat{X}}_{2} \big{)}+\hat{\gamma}\big{(}\hat{X}_{1}\big{)}+\mu_{1}\frac{d}{dt}\Big{(}\big{(} X_{1}-\hat{X}_{1}\big{)}+\Big{(}X_{2}-\hat{\hat{X}}_{1}\big{)}\Big{)}\Big{]}\times \hat{\alpha}^{-1}\big{(}\hat{X}_{1}\big{)}+\hat{\alpha}^{-1}\big{(}\hat{X}_{1 }\big{)}\hat{\Theta}_{ANHVSO}.\] \[U_{B}=\hat{\alpha}^{-1}\big{(}\hat{X}_{1}\big{)}\times\Big{[}\mu _{1}\big{(}X_{1}-\hat{X}_{1}\big{)}+\mu_{2}\Big{(}X_{2}-\hat{X}_{1}\big{)} \Big{]}+\Big{[}\hat{\alpha}\big{(}\hat{X}_{1}\big{)}+\hat{\beta}\big{(}\hat{ \hat{X}}_{1}\quad\hat{\hat{X}}_{2}\big{)}+\hat{\gamma}\big{(}\hat{X}_{1}\big{)} \Big{]}\] \[U_{F}=U_{PID-fuzzy}=U_{PD-fuzzy}+U_{PI-fuzzy}=U_{PD-fuzzy}+\int U_{ PD-fuzzy}\] \[U_{O}=\big{(}\epsilon^{T}\big{)}\hat{X}_{1}, \tag{56}\] \[\hat{X}_{1-ANHVSO}=\hat{\alpha}^{-1}\big{(}\hat{X}_{1}\big{)}\hat{ \epsilon}_{LPF,NNK}+\hat{\alpha}^{-1}\big{(}\hat{X}_{1}\big{)}\hat{\beta}\big{(} \hat{X}_{1}\quad\hat{X}_{2}\big{)}+\hat{\gamma}\big{(}\hat{X}_{1}\big{)}+\hat {\alpha}^{-1}\hat{\Theta}_{ANHVSO}+\] \[\mu_{2}sgn\big{(}\hat{X}_{1}-\hat{X}_{2}\big{)}+\mu_{6}\|X_{1}- \hat{X}_{1}\|^{2}sgn\big{(}\hat{X}_{1}-\hat{X}_{2}\big{)}-\Delta,\] \[\hat{\Delta}=-\mu_{5}sgn\big{(}X_{1}-\hat{X}_{1}\big{)},\]  
Here, \(U_{O}\) and \(U_{MFBVSC}\) are observation feedback to improve the performance of the fault-tolerant control algorithm in uncertain and unknown conditions and the output of the MFBVSC, respectively. In addition, to increase robustness and reduce chattering in uncertain and faulty conditions, an adaptive algorithm is used for the online tuning of the coefficients in the MFBVSC, thus defining the AMFBVSC. In this scenario, based on Equation (56), various coefficients are used to tune \(U_{FBVSC}\). Of these, the coefficients used to reduce chattering, increase stability and improve reliability of the variables in \(U_{VSC}\) play the main roles. Therefore, the adaptive technique is used for online tuning of \(\mu_{1}\) and \(\mu_{2}\). A fuzzy algorithm can be used to accomplish this. Therefore, the AMFBVSC is represented by the following equation:  
\[U_{MFBVSC}=U_{VSC}+U_{B}+U_{PID-fuzzy}+U_{O},\]0 \[U_{MFBVSC}=U_{VSC}+U_{B}+U_{PID-fuzzy}+U_{O},\]1 \[U_{MFBVSC}=U_{VSC}+U_{B}+U_{PID-fuzzy}+U_{O},\]2 \[U_{MFBVSC}=U_{VSC}+U_{B}+U_{PID-fuzzy}+U_{O},\]3 \[U_{MFBVSC}=U_{VSC}+U_{B}+U_{PID-fuzzy}+U_{O},\]4 \[U_{MFBVSC}=U_{VSC}+U_{B}+U_{PID-fuzzy}+U_{O},\]5 \[U_{MFBVSC}=U_{VSC}+U_{B}+U_{PID-fuzzy}+U_{O},\]6 \[U_{MFBVSC}=U_{VSC}+U_{B}+U_{PID-fuzzy}+U_{O},\]7  
A PD-like fuzzy algorithm is used for online tuning of the coefficients as in the following equation:  
\[\Big{\{} \begin{array}{c}\mu_{1(adaptive)}=\mu_{1}\times\hat{\sigma}_{f}\\ \mu_{2(adaptive)}=\mu_{2}\times\hat{\sigma}_{f}\end{array} . \tag{58}\]  
Here, \(U_{AMFBVSC},\ U_{AVSC},\ \big{(}\mu_{1(adaptive)}\&\ \mu_{2(adaptive)}\big{)}\), and \(\hat{\sigma}_{f}\) are the output of the proposed algorithm for fault-tolerant control of the robot manipulator, the output of the online tuning VSC technique, the online tuning coefficients to reduce chattering, the fuzzy output for tuning the coefficients based on the error, and the derivation of the error, respectively. This is a powerful algorithm for reducing the effects of faults in the robot manipulator, and is based on the variable structure observer, a backstepping technique, a fuzzy algorithm, the proposed observation method, and an adaptive algorithm. Algorithm 1 shows the 12 steps used to design the proposed algorithm for fault detection, estimation, identification and fault-tolerant control.