# Time-Optimal Trajectory Planning for Woodworking Manipulators Using an Improved PSO Algorithm
## 4 Discussion  
For the woodworking manipulator, joints 1 and 2 are rectilinear motion joints, while joints 3 and 4 are revolute joints. Therefore, the limitations of joint velocity and acceleration are different. In the experiment of optimizing joint running time, joints 1 and 2 can be divided into one group experiment, and joints 3 and 4 are another group. From Table 5, the difference in total running time of joints 1 and 2 optimized by Golds-PSO is 0.1505 s, and the difference in total running time of joints 3 and 4 is 0.0257 s, which is smaller than the 0.2262 s and 0.0681 s of basic PSO and the 0.3993 s and 0.1992 s of Gold-SA, indicating that Golds-PSO has better stability. The simulation results in Section 3.3 show that the displacement and velocity curves of the manipulator maintain good operational smoothness. However, due to the trajectory being divided into three segments, there is a clear convergence in the operation patterns of the first and third segments, which may not be conducive to meeting the special needs of some machining tasks. Additionally, because of the different interpolation functions used, the acceleration curve can maintain continuity at the connection of two trajectories, but it is not smooth enough and can result in non-differentiable points. But in summary, the simulation results meet the working requirements of the woodworking manipulator.  
The method proposed in this paper achieved satisfactory results in time-optimal trajectory planning of woodworking manipulator. However, some areas must be considered for future research.  
Figure 13: The woodworking manipulator end-effector trajectory under optimal time (**a**) The end-effector at starting point A; (**b**) the end-effector at point B and the trajectory from A to B; (**c**) the end-effector at point C and the trajectory from A to C; (**d**) the end-effector at end point D and the trajectory from A to D.  
Firstly, from the perspective of the proposed GoldS-PSO algorithm, further testing is needed to evaluate the effectiveness of different parameter combinations that may need strict mathematical derivations [43]. Moreover, currently we only applied GoldS-PSO to time-optimal trajectory planning of woodworking manipulators. More experiments are needed to assess the effectiveness of other optimization problems in agricultural and forestry engineering, which may require adjustments to the algorithm structure again. Then, after completing the time-optimal trajectory planning, it is necessary to comprehensively consider the effect of energy consumption, impact, and other factors on the operation and carry out multi-objective optimization [44,45] of the trajectory to enhance the general performance of manipulator. The design of the manipulator control system and trajectory tracking control is also the focus of subsequent studies.  
Recently, some advanced technologies, such as machine vision, image processing, artificial intelligence algorithms, etc., have been integrated into automated manipulator and robot systems, which has provided unprecedented opportunities for traditional agriculture and forestry industries to achieve an automate decision-making processes and improve efficiency [46,47]. In this process, the GoldS-PSO algorithm proposed in this paper can be used for the training of neural networks and optimization of control model structure in the intelligent control system [48,49], as well as for the optimization of target recognition, positioning, and tracking technology in visual detection systems [50,51]. Meanwhile, some relevant studies indicate that it has great potential in optimizing forestry management structure [52].