# Path Planning Based on NURBS for Hyper-Redundant Manipulator Used in Narrow Space
## 4 The Tip-Following B-Spline Path Planning
\begin{array}{ccc}q_{0}{}^{2}+q_{1}{}^{2}-q_{2}{}^{2}-q_ {3}{}^{2}&2(q_{1}q_{2}-q_{0}q_{3})&2(q_{1}q_{3}-q_{0}q_{2})\\ 2(q_{1}q_{2}-q_{0}q_{3})&q_{0}{}^{2}-q_{1}{}^{2}+q_{2}{}^{2}-q_{3}{}^{2}&2(q_{2 }q_{3}-q_{0}q_{1})\\ 2(q_{1}q_{3}-q_{0}q_{2})&2(q_{2}q_{3}-q_{0}q_{1})&q_{0}{}^{2}+q_{1}{}^{2}-q_{2 }{}^{2}+q_{3}{}^{2}\end{array} \right] \tag{16}\]  
Assuming coordinate system \(O_{n-1}-x_{n-1}y_{n-1}z_{n-1}\) is known. According to the relative pose description, it can be known that the coordinates of \(O_{n}\) projected at the coordinate system are:  
\[{}_{n}^{n-1}Z=\left[{}_{n}^{n-1}X_{c,\ n}{}^{n-1}Y_{c,\ n}{}^{n-1}Z_{c}\right] ^{T} \tag{17}\]  
Figure 11: Three-dimensional vector rotation using quaternion. According to the transformation relationship between the relative coordinate systems, it can be known that the transformation matrix between two adjacent discrete points is:  
\[ \begin{array}{c}{n-1}T=\left[\begin{array}{cc}{\frac{n-1}{n}R}&{\frac{n-1}{n}Z} \\ 0&1\end{array}\right]\end{array}  \tag{18}\]  
The base coordinate system \(O_{0}-x_{0}y_{0}z_{0}\) of manipulator is given in advance, and described as:  
\[O_{0}-x_{0}y_{0}z_{0}=\left[ \begin{array}{ccc}1&0&0\\ 0&1&0\\ 0&0&1\end{array} \right],O_{0}=\left[ \begin{array}{ccc}0&0&0\end{array} \right] \tag{19}\]  
Find the first discrete point on the B-spline curve by dichotomy method in \(t\in[0,1]\). Suppose the corresponding parameter is \(t_{1}\). Then, compute the coordinate system \(O_{1}-x_{1}y_{1}z_{1}\) and record. Find the second discrete point on the B-spline curve by dichotomy method in \(t\in[t_{1},1]\). Similarly, the discrete points corresponding to the all UCR parallel mechanisms can be acquired. The steps for computing each UCR parallel mechanism are:  
1. Compute the rotation matrix between two adjacent discrete points. 2. Determine the parity of the index of the UCR parallel mechanism. If the index is an odd number, use the driving equation CalDrivingLength_10 to compute the length of chains; if the index is even, use the driving equation CalDrivingLength_20 to compute the length of three chains. Pseudo-code of CalDrivingLength_10 and CalDrivingLength_20 is introduced below. Pseudo-code of CalDrivingLength_10:  
``` ine FUNCTION: CalDrivingLength_1(\(T_{1},r\)) INPUT: \(T_{1}\)// Transformation matrix of moving platform \(r\)// The distance between \(P_{(1\_1)}\) and \(O_{1}\) OUTPUT: \(l_{(1\_1)}l_{(1\_2)}l_{(1\_3)}\)// The length of the three chains BEGIN \(1\). \(\left[\begin{array}{cccc}\begin{array}{cccc}\begin{array}{cccc}\begin{array}{ c}\begin{array}{cccc}\begin{array}{cccc}\begin{array}{c}\begin{array}{ c}\begin{array}{c}\begin{array}{c}\begin{array}



## 5 Simulations and Experiments

As shown in Figure 12, the arm has eight joints, with an initial length of 544 mm and a diameter of 40 mm. The schematic diagram of the simulation platform is shown in Figure 13, and the simulation platform consists of four parts: the simulation configuration environment, URC parallel mechanism, signal sensor and position sensor, and the position sensor is incorporated in moving platform. Figure 12: Mock-up of the robotic arm. Figure 13: Schematic diagram of simulation platform. The robot arm can move smoothly on the plane, as shown in Figure 14. The \"8\" shape drawn by the robot arm on the plane shows that the robot arm can perform a series of motions stably. As shown in Figure 15, the hyper-redundant robot can successfully automatically identify roadblocks in space and complete the obstacle avoidance movement through the algorithm. Because of the small size of the hyper-redundant robot designed in this paper, it can complete the task in the narrow space. As shown in Figure 16, the robot can automatically identify the path to complete the movement and complete the maintenance and other tasks in the pipeline. Figure 14: Schematic diagram of manipulator for tube obstacle avoidance. Figure 15: Schematic diagram of path obstacle avoidance manipulator.