Surface partitioning and traveling salesman problem-based method for spray path planning of complex workpieces
Existing spraying methods often generate fixed pattern trajectories within equal arc length and time frames, which can easily induce nozzle distance fluctuations and edge overspray in regions of sudden curvature changes. This paper proposes a trajectory planning method for complex workpieces based on surface partitioning and an optimized traveling salesman problem approach, enabling high uniformity and low cycle time in automated spraying. Specifically, a fourstage segmentation module is designed based on dual curvature-normal thresholds: cylindrical hole removal, regional supersegmentation, plane merging, and high-density recovery. This sequentially eliminates cylindrical holes while preserving geometric details, providing continuous, smooth, and high-fidelity surface patches for trajectory planning. Subsequently, a visibility map is constructed for obstacle avoidance, boundary densification and retouching are implemented, and an open-loop TSP without return to origin is solved, unifying obstacle avoidance, edge reinforcement, and path minimization. Simulation experiments demonstrate that this method achieves an average absolute thickness fluctuation reduction of 21.26%, shortens the average spray path length by 43.74 mm, and improves coating thickness uniformity by 10.54% compared to the next-best approach. The proposed framework offers a novel solution for highquality robotic spraying of complex parts.