# Analysis and Simulation of Polishing Robot Operation Trajectory Planning
## 2 Materials and Methods
### Spiral Arc Trajectory Planning of Quintic Polynomial Interpolation Algorithm
In conclusion, the displacement diagrams presented in Figure 7, particularly the zoomed-in views of joints 4 and 6, serve as compelling evidence of the superiority of the B-spline interpolation algorithm in achieving superior interpolation effects and generating smooth, predictable motion profiles for robotic systems. Using the B-spline interpolation algorithm, taking joint 6 as an example, the simulation curves of joint displacement, angular velocity, and angular acceleration are obtained through MATLAB programming, as shown in Figure 8d-f.  
Figure 8: Comparison of joint 6 motion characteristics using quintic polynomial and quintic B-spline interpolation techniques. (**a–c**) depict the angular displacement, velocity, and acceleration profiles, respectively, using a quintic polynomial interpolation. (**d–f**) show the same motion characteristics using a quintic B-spline interpolation, demonstrating smoother and more continuous motion profiles. Comparison of Trajectory Planning Between Quintic Polynomial Interpolation Algorithm and Quintic B-Spline Interpolation Algorithm  
To accurately capture the dynamics of each robotic joint, MATLAB was used as the primary tool to compute the crucial kinematic parameters: angular displacement, angular velocity, and angular acceleration. These computations are essential for understanding the behavior of the robotic system and ensuring smooth, predictable movements. We utilized line charts to depict the relationships between these variables and time, providing a clear and Intuitive representation of the data trends. We focused on comparing the performance of two interpolation methods: the conventional fifth-degree polynomial interpolation and the more advanced fifth-degree B-spline interpolation algorithm. To illustrate the differences, we chose joint 6 as a representative example and plotted its angular displacement, angular velocity, and angular acceleration over time for both interpolation methods, as shown in Figure 8.  
The simulated curve graphs in Figure 8a-c represent the joint displacement, angular velocity, and angular acceleration of joint 6, which were obtained using MATLAB programming with a quintic polynomial interpolation algorithm. Figure 8 presents a detailed comparison of two interpolation techniques, highlighting notable differences in the motion trajectories' smoothness and continuity. The quintic B-spline interpolation algorithm notably provides a smoother and more natural motion profile for joint 6, affecting its angular displacement, velocity, and acceleration. This superior performance is attributed to the B-spline curves' inherent smoothness and local control capabilities, allowing precise motion adjustments and reducing oscillations or discontinuities. Consequently, we chose the quintic B-spline interpolation algorithm for planning the spiral arc grinding trajectory, enhancing the robotic system's precision, reducing vibrations, and boosting overall performance. With these benefits, B-spline interpolation is ideal for complex, high-precision tasks, improving the robotic grinding process's reliability and efficiency. Regarding the robot's movement, the end-effector maintains a constant speed, ensuring consistent time intervals between consecutive nodes. With a radius of 100 mm and a pitch of 60 mm, we calculated an initial inclination angle of \(\varphi_{0}=0.0952\) and a maximum step angle of \(\alpha_{c}\leq 0.089\). The spatial segmentation includes 71 nodes, with a set velocity of 2 mm/s along the \(z\)-axis, resulting in a time of 0.4258 s between nodes. Figure 9 shows the corresponding end position values of the robot. As shown in Figures 8 and 9, it becomes evident that the adoption of the quintic B-spline interpolation algorithm for trajectory planning yields significant advantages in terms of smoothness and stability. Specifically, Figure 8 not only showcases the joint trajectory but also underscores the remarkable smoothness in the profiles of joint velocity and acceleration along the trajectory.