摘要：In CNC machining, the tool path following G01 codes generally introduces large computations and inherent discontinuities.We derive the explicit expression for the Hausdorff distance between a line segment and a curve segment, and then propose a certified curve fitting algorithm for G01 polylines. Instead of the traditional two-stage model,we present a combined trajectory planning model with error constraints as well as dynamic constraints. Moreover, an effective and efficient algorithm is designed to solve this model. Collision avoidance is a fundamental problem in five-axis tool path planning. A two-step frame is widely used in tool path generation, that is, to determine C-spaces and then to design collision free pathes in the C-spaces. We present a feasible C-space computation algorithm for triangular mesh models based on collision-cone computation and stereographic projection.To generate a tool orientation using the graph-based method, we introduce a difference graph to find a smoother tool orientation.