# Path Planning Optimization of the Load Transport Process Using Heuristic Algorithms
## 6 Conclusions  
This paper presents the problem of optimizing the duty cycle of a rotary crane. Optimization was performed using the genetic and the PSO algorithm. As an objective function, minimization of the trajectory of the carried load was selected. Numerical simulations were performed for various parameters of the analyzed algorithms. On the basis of the shortest trajectory obtained, the position kinematics and the orientation of the crane members during the duty cycle were determined by solving the inverse kinematics problem. This task was solved using the geometric method and the algorithm for temporarily limiting the movement of specific kinematic pairs. Due to the structure of the crane, the movement of the last member was limited, i.e., the length of the rope remained constant. The shortest trajectory during numerical simulations was obtained for the following parameters of the PSO algorithm: population number = 50, number of auxiliary points = 5, and the number of iterations in the range from 75 to 100. The presented algorithm works best for a larger number of auxiliary points (\(i\) = 5) and iterations (\(it\) > 75). In this case, the computation time is extended (even four times) in relation to a smaller number of iterations or auxiliary points. Increasing the number of populations also increases the computational time, but a shorter trajectory can be obtained as a result. For optimization studies, especially those involving more complex environments, using more auxiliary points and iterations would significantly improve the precision of the solution, although at the cost of increased computational time. This balance between accuracy and time efficiency is crucial when applying these methods to real lifting operations. For optimization tests similar to those presented in this paper, increasing the parameters of the PSO algorithm will lead to obtaining more favorable results with a slight increase in the computation time. On the other hand, for studies with a much greater degree of complexity, increasing the parameters of the PSO algorithm will result in a significant increase in the computationtime while improving the obtained results by several percent. One of the most important parameters of the particle swarm algorithm is the number of auxiliary points. In the case presented in this work (when the working area is limited by three obstacles), it is advisable to use the same or more auxiliary points than the number of obstacles. If this condition is not met, the trajectory course differs significantly from the optimal trajectory, which is related to the construction of the B-spline curve. The optimal trajectory obtained using the genetic algorithm was only 2 mm shorter compared to that determined using the PSO algorithm. This small difference suggests that both algorithms can be used interchangeably in applications where small deviations are acceptable. However, in industrial contexts where computational efficiency is crucial, the PSO algorithm has a significant advantage. Therefore, it can be concluded that during optimization tests concerning the minimization of the load trajectory, it is possible to use both methods, because the results obtained from their use do not differ significantly from each other. The only advantage of the PSO algorithm in this case is the shorter calculation time of the optimal trajectory. Among the parameters of the genetic algorithm, the probability of mutation and the population number have the greatest influence on obtaining the shortest path. The obtained solution of inverse kinematics allows for determining the configuration coordinates for each point in the working area of the machine. In the analyzed case, it was found that the crane is able to reach all positions for the trajectory determined in the optimization process. Furthermore, the efficiency gains achieved with inverse kinematic solutions have direct implications for extending the crane's operational reach while reducing mechanical stress.