# Neural Network-Enhanced Fault Diagnosis of Robot Joints
## Appendix A Robotic Arm Trajectory Planning  
The Denavit-Hartenberg (DH) parametric modelling method, which is widely used in both forward and inverse motion algorithms for robotic arms, solidly connects a position system to each link according to a set of rules, after which it is convenient to describe the transformation from one link position system to the next neighbouring link position system [21]. In essence, the transformation of neighbouring position systems is decomposed into several steps, each with a single parameter. The combination of the corresponding transformations of these steps completes the transformation from the robot base to the end-effector position systems. The UR10 robot consists of six rotational joints. The first three joints of the manipulator mainly control the end position, and the last three joints mainly control the end attitude, as shown in Figure A1. The homogeneous transformation matrix expression between adjacent link position systems is:  
\[ \begin{split}\overset{i-1}{i}T&=\text{Rot}_{z_{i-1} }(\theta_{i})\cdot\text{Trans}_{z_{i-1}}(d_{i})\cdot\text{Trans}_{x_{i}}(a_{i} )\cdot\text{Rot}_{x_{i-1}}(a_{i})\\ &=\left[\begin{array}{ccc}\cos\theta_{\text{i}}&-\sin\theta_{ \text{i}}\cos\alpha_{\text{i}}&\sin\theta_{\text{i}}\sin\alpha_{\text{i}}&a_{i} \cos\theta_{\text{i}}\\ \sin\theta_{\text{i}}&\cos\theta_{\text{i}}\cos\alpha_{\text{i}}&-\cos\theta _{\text{i}}\sin\alpha_{\text{i}}&a_{i}\sin\theta_{\text{i}}\\ 0&\sin\alpha_{\text{i}}&\cos\alpha_{\text{i}}&d_{i}\\ 0&0&0&1\end{array}\right]\end{split}  \tag{1}\]  
The pose transformation moment of the robot end effector position system relative to the base position system is shown in Equation (1). \[ \begin{split}\overset{0}{6}T&=T_{1}\cdot T_{2}\cdot T_{3} \cdot T_{4}\cdot T_{5}\cdot T_{6}=\left[\begin{array}{cccc}n_{x}&o_{x}&a_{x} &p_{x}\\ n_{y}&o_{y}&a_{y}&p_{y}\\ n_{z}&o_{z}&a_{z}&p_{z}\\ 0&0&0&1\end{array}\right]\end{split}  \tag{2}\]  
The equation includes the attitude information and position information of the end-effector with respect to the base in the world position system, the 3 \(\times\) 3 matrix in the upper left corner indicates the attitude of the actuator, and the 3 \(\times\) 1 matrix in the upper right corner indicates the position of the actuator, i.e., the \(x\)\(y\)\(z\) positions, which cannot be directly fed into the network training as raw data and need to be extracted for the features. The attitude of the end-effector of the robotic arm is expressed in terms of Euler angles, where pitch, yaw and roll can be obtained from Equation (1):  
\[ \begin{split}\text{Pitch }(\theta)&=\text{atan }2\Big{(}-a_{x}/\sqrt{a_{y}^{2}+a_{z}^{2}}\Big{)}\\ \text{roll }(\phi)&=\text{atan }2\big{(}a_{y}/a_{z}\big{)}\\ \text{Yaw }(\phi)&=\text{atan }2(\sigma_{x}/n_{x})\end{split}  \tag{3}\]  
where roll, pitch and yaw represent the attitude of rotation of the end-effector relative to the base around the x, y and z axes in the world position system [23], respectively, in angular units. The DH table of the robotic arm is shown in Table A1, which also indicates the parameters of the robot arm:The parameters and figure of the UR10 provide information about the specific function of each joint: the first joint controls the rotation of the robot's left side in the horizontal plane, the second joint controls the tilting of the robot backwards and forwards (i.e., it allows the robot to move its arm up and down), and the third joint controls the extension and retraction of the robot. The third joint controls the telescoping of the robot, which allows the robot's end-effector to move closer to or further away from the robot's base. The fourth joint controls the bending and straightening of the robot's wrist. The fifth joint controls the left and right rotation of the robot's wrist. The sixth joint controls the rotation of the robot's wrist around its own axis, which is the rotation of the robot's end-effector [22]. This information is crucial for the next step of feature selection and extraction.