## 3 Kinematics Analysis
### Inverse Kinematics
 \tag{6}\]  
The transformation matrices \({}^{O_{B}}\mathbf{T}_{O_{0i}}\) and \({}^{O_{P}}\mathbf{T}_{O_{0i}}\) are determined by the geometric parameters of the mobile and base platforms and the corresponding coordinate system definitions. Given the pose of the mobile platform in \(O_{B}-X_{B}Y_{B}Z_{B}\), the transformation matrix \({}^{O_{0i}}\mathbf{T}_{O_{0i}}\) can also be determined, and the following relationship exists:  
\[{}^{O_{0i}}\mathbf{T}_{O_{0i}}= \begin{pmatrix}{}^{O_{B}}\mathbf{T}_{O_{0i}}\\ \end{pmatrix} ^{-1}\cdot{}^{O_{B}}\mathbf{T}_{O_{0}}\cdot{}^{O_{P}}\mathbf{T}_{O_{0i}} \tag{7}\]  
Each element of the transformation matrix \({}^{O_{0i}}\mathbf{T}_{O_{0i}}\) is known and \({}^{0}\mathbf{T}_{6(i)}={}^{O_{0i}}\mathbf{T}_{O_{0i}}\). Therefore:  
\[\mathbf{T}_{i}={}^{0}\mathbf{T}_{6(i)}-{}^{O_{0i}}\mathbf{T}_{O_{0i}}  
The inverse kinematics problem involves solution of six nonlinear equations, where each leg corresponds to a nonlinear equation group, and the corresponding nonlinear equations of the \(i_{th}\) leg contain the unknown parameters \(S_{1i}\), \(\theta_{2i}\), \(\theta_{3i}\), \(\theta_{4i}\), \(\theta_{5i}\), and \(\theta_{6i}\). The six matrix elements in the matrix \(T_{i}\) are selected to form a system of nonlinear equations that contains six equations that correspond to the \(i_{th}\) leg. The expression for these nonlinear equations is given as follows:  
\[\left\{ \begin{array}{l}\Phi_{1i}(S_{1i},\theta_{2i},\theta_{3i},\theta_{4i}, \theta_{5i},\theta_{6i})=T_{i}(2,1)=0\\ \Phi_{2i}(S_{1i},\theta_{2i},\theta_{3i},\theta_{4i},\theta_{5i},\theta_{6i})=T _{i}(2,2)=0\\ \Phi_{3i}(S_{1i},\theta_{2i},\theta_{3i},\theta_{4i},\theta_{5i},\theta_{6i})=T _{i}(1,3)=0\\ \Phi_{4i}(S_{1i},\theta_{2i},\theta_{3i},\theta_{4i},\theta_{5i},\theta_{6i})=T _{i}(2,3)=0\\ \Phi_{5i}(S_{1i},\theta_{2i},\theta_{3i},\theta_{4i},\theta_{5i},\theta_{6i})=T _{i}(1,4)=0\\ \Phi_{6i}(S_{1i},\theta_{2i},\theta_{3i},\theta_{4i},\theta_{5i},\theta_{6i})=T _{i}(3,4)=0\\ \end{array} \right. \tag{9}\]  
The Newton-Raphson numerical iterative method is used to solve the nonlinear equations given as Equation (9). Solutions can be derived for the unknown parameters \(S_{1i}\), \(\theta_{2i}\), \(\theta_{3i}\), \(\theta_{4i}\), \(\theta_{5i}\), and \(\theta_{6i}\) using the following iterative format:  
\[\left[ \begin{array}{c}S_{1i}\\ \theta_{2i}\\ \theta_{3i}\\ \theta_{4i}\\ \theta_{5i}\\ \theta_{6i}\end{array} \right]_{(n+1)}=\left[ \begin{array}{c}S_{1i}\\ \theta_{2i}\\ \theta_{3i}\\ \theta_{4i}\\ \theta_{5i}\\ \theta_{6i}\end{array} \right]_{(n)}-\left[ \begin{array}{c}\frac{\partial \Phi_{1i}}{\partial\Phi_{1i}}\frac{\partial\Phi_{1i}}{\partial\Phi_{2i}} \ldots\frac{\partial\Phi_{i}}{\partial\theta_{6i}}\\ \vdots\\ \frac{\partial\Phi_{4i}}{\partial\Phi_{5i}}\frac{\partial\Phi_{5i}}{\partial \theta_{5i}}\ldots\frac{\partial\Phi_{6i}}{\partial\theta_{6i}}\end{array}  \right]^{-1}_{(n)}\cdot\left[ \begin{array}{c}\Phi_{1i}\\ \Phi_{2i}\\ \Phi_{3i}\\ \Phi_{4i}\\ \Phi_{5i}\\ \Phi_{6i}\end{array} \right]_{(n)} \tag{10}\]  
In addition to establishing an iterative format to solve these nonlinear equations, the initial value of the required solution variable is also given. The initial valuesS\({}_{1i}\)\({}^{(0)}\), \(\theta_{2i}\)\({}^{(0)}\), \(\theta_{3i}\)\({}^{(0)}\), \(\theta_{4i}\)\({}^{(0)}\), \(\theta_{5i}\)\({}^{(0)}\), and \(\theta_{6i}\)\({}^{(0)}\) can be variables of the \(i_{th}\) leg when the mobile platform is at the zero position. The flow chart for the iterative solution to the inverse kinematics of the platform when using the D-H parameter method is shown in Figure 9.  
Figure 9: Solution procedure for the forward kinematics.