## 3 Kinematic Analysis
### Forward Kinematics
\begin{table}
\begin{tabular}{c c c c c c} \hline \hline
**Joint \(i\)** & **Length of Bar \(a_{i}\)** & **Knob Angle \(\alpha_{i}\)** & **Offset \(d_{i}\)** & **Joint Angle \(\theta_{i}\)** & **Angle Range** \\ \hline
1 & 0 & 90\({}^{\circ}\) & 235 mm & \(\theta_{1}\) (\(-90^{\circ}\)) & \(-90^{\circ}\)-\(30^{\circ}\) \\
2 & 0 & 90\({}^{\circ}\) & 20 mm & \(\theta_{2}\) (\(-90^{\circ}\)) & \(-90^{\circ}\)-\(45^{\circ}\) \\
3 & 0 & 90\({}^{\circ}\) & 420 mm & \(\theta_{3}\) (\(-90^{\circ}\)) & \(-80^{\circ}\)-\(45^{\circ}\) \\
4 & 0 & 90\({}^{\circ}\) & 0 & \(\theta_{4}\) (\(0^{\circ}\)) & \(0^{\circ}\)-\(135^{\circ}\) \\
5 & 0 & 90\({}^{\circ}\) & 265 mm & \(\theta_{5}\) (\(0^{\circ}\)) & \(-45^{\circ}\)-\(45^{\circ}\) \\
6 & 83 mm & 0\({}^{\circ}\) & 0 & \(\theta_{6}\) (\(-90^{\circ}\)) & \(-45^{\circ}\)-\(45^{\circ}\) \\ \hline \hline \end{tabular}
\end{table} 
Table 2: D-H parameters of upper limb rehabilitation robot. Figure 6: 3D rehabilitation robot. Figure 7: Denavit–Hartenberg (D-H) parameter model of robot. coordinate system \(\{O_{i-1}\}\) to coordinate system \(\{O_{i}\}\). Based on the robotics theory, the vector described in coordinate system \(\{O_{i}\}\) is mapped to coordinate system \(\{O_{i-1}\}\) by coordinate transformation:  
\[ \begin{split}{}^{i-1}T_{i}&=A_{i}=\text{Rot}(Z,\theta _{i})\times\text{Trans}(0,0,d_{i})\times\text{Trans}(a_{i},0,0)\times\text{Rot}(X,a_{i})\\ &=\left[\begin{array}{ccccc}\text{c}\theta_{i}&-\text{s} \theta_{i}&0&0\\ \text{s}\theta_{i}&\text{c}\theta_{i}&0&0\\ 0&0&1&0\\ 0&0&1&0\\ 0&0&0&1\end{array}\right]\left[\begin{array}{ccccc}1&0&0&0\\ 0&1&0&0\\ 0&0&1&d_{i}\\ 0&0&0&1\end{array}\right]\\ &=\left[\begin{array}{ccccc}\text{c}\theta_{i}&-\text{s}\theta_{i} \alpha_{i}&\text{s}\theta_{i}\alpha_{i}&a_{i}\text{c}\theta_{i}\\ \text{s}\theta_{i}&\text{c}\theta_{i}\alpha_{i}&-\text{c}\theta_{i}\alpha_{i} &a_{i}\text{s}\theta_{i}\\ 0&\text{s}\alpha_{i}&\text{c}\alpha_{i}&d_{i}\\ 0&0&0&1\end{array}\right]\end{split} \right]\end{split} \tag{1}\]  
where c means a cosine function and s represents sine function. For a wearable upper limb rehabilitation robot, when the coordinate system of each link is determined, the parameters of each link can be obtained. According to Formula (1), it can be known that the pose matrix \(A_{i}\) between the two rods is:  
\[A_{1}=\text{Rot}(Z,\theta_{1})\times\text{Trans}(0,0,d_{1})\times\text{Trans}( a_{1},0,0)\times\text{Rot}(X,\alpha_{1})=\left[ \begin{array}{ccccc}\text{c} \theta_{1}&0&\text{s}\theta_{1}&0\\ \text{s}\theta_{1}&0&-\text{c}\theta_{1}&0\\ 0&1&0&235\\ 0&0&0&1\end{array} \right]\]  
\[A_{2}=\text{Rot}(Z,\theta_{2})\times\text{Trans}(0,0,d_{2})\times\text{Trans}( a_{2},0,0)\times\text{Rot}(X,\alpha_{2})=\left[ \begin{array}{ccccc}\text{c} \theta_{2}&0&\text{s}\theta_{2}&0\\ \text{s}\theta_{2}&0&-\text{c}\theta_{2}&0\\ 0&1&0&20\\ 0&0&0&1\end{array} \right]\]  
\[A_{3}=\text{Rot}(Z,\theta_{3})\times\text{Trans}(0,0,d_{3})\times\text{Trans}( a_{3},0,0)\times\text{Rot}(X,\alpha_{3})=\left[ \begin{array}{ccccc}\text{c} \theta_{3}&0&\text{s}\theta_{3}&0\\ \text{s}\theta_{3}&0&-\text{c}\theta_{3}&0\\ 0&1&0&420\\ 0&0&0&1\end{array} \right]\]  
\[A_{4}=\text{Rot}(Z,\theta_{4})\times\text{Trans}(0,0,d_{4})\times\text{Trans}( a_{4},0,0)\times\text{Rot}(X,\alpha_{4})=\left[ \begin{array}{ccccc}\text{c} \theta_{4}&0&\text{s}\theta_{4}&0\\ \text{s}\theta_{4}&0&-\text{c}\theta_{4}&0\\ 0&1&0&0\\ 0&0&0&1\end{array} \right]\]  
\[A_{5}=\text{Rot}(Z,\theta_{5})\times\text{Trans}(0,0,d_{5})\times\text{Trans}( a_{5},0,0)\times\text{Rot}(X,\alpha_{5})=\left[ \begin{array}{ccccc}\text{c} \theta_{5}&0&\text{s}\theta_{5}&0\\ \text{s}\theta_{5}&0&-\text{c}\theta_{5}&0\\ 0&1&0&265\\ 0&0&0&1\end{array} \right]\]  
\[A_{6}=\text{Rot}(Z,\theta_{6})\times\text{Trans}(0,0,d_{6})\times\text{Trans}( a_{6},0,0)\times\text{Rot}(X,\alpha_{6})=\left[ \begin{array}{ccccc}\text{c} \theta_{6}&-\text{s}\theta_{6}&0&83\text{c}\theta_{6}\\ \text{s}\theta_{6}&\text{c}\theta_{6}&0&83\text{s}\theta_{6}\\ 0&0&1&0\\ 0&0&0&1\end{array}