{'fraction_non_alphanumeric': 0.025093295586153648, 'fraction_numerical': 0.005018659117230729, 'mean_word_length': 4.535612535612535, 'pattern_counts': {'":': 0, '<': 0, '<?xml version=': 0, '>': 0, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
Research on cutting path optimization of sheet metal parts based on ant colony algorithm

In view of the disadvantages of the current cutting path optimization methods of sheet metal parts, a new method based on ant colony algorithm was proposed in this paper. The cutting path optimization problem of sheet metal parts was taken as the research object. The essence and optimization goal of the optimization problem were presented. The traditional serial cutting constraint rule was improved. The cutting constraint rule with cross cutting was proposed. The contour lines of parts were discretized and the mathematical model of cutting path optimization was established. Thus the problem was converted into the selection problem of contour lines of parts. Ant colony algorithm was used to solve the problem. The principle and steps of the algorithm were analyzed.


Introduction
In recent years, the cutting path optimization problem of sheet metal parts becomes a hot research topic in the field of computer-aided manufacturing and control. NC laser cutting machine has advantages of high speed and precision, but a large number of empty travel will be produced in the process of cutting the workpiece, which seriously affects the cutting efficiency. By the method of path optimization, shortening the distance of empty travel in the cutting process has the great practical significance to shorten the cutting time and improve machining efficiency.
In this field, the domestic and foreign scholars have made some related research. Han et al. [1] used the simulated annealing algorithm to optimize the cutting path problem of irregular parts, and considered the influence of cutting temperature. Pan et al. [2] proposed a 'punching -cutting' planning CAD/CAM system based on the knowledge base. Huixia Liu et al. [3] used the hierarchical planning three-step algorithm to solve the cutting path optimization problem. Huiping Sun et al. [4] transformed the cutting path optimization problem into the Traveling Salesman Problem by using the method of adding nodes, and used the genetic algorithm to solve the problem. Nini Li et al. [5] put forward a new laser cutting path optimization algorithm with the combination of the local search method and genetic algorithm.
These literatures studied the cutting path optimization problem from the different angles. However, their basic ideas were similar. They all transformed the problem into the TSP and used the relative algorithms to solve it according to the constraint rule of serial cutting. The constraint rule of serial cutting has shortcomings in solving the actual cutting path optimization problem.
In this paper, the cutting path optimization of sheet metal parts with no holes and public edges are taken as the research object. The cutting constraint rule and the associated optimization algorithm will be mainly discussed. The aim of this paper is resolving some key problems in the CNC laser cutting path optimization.

Description of cutting path optimization problem
As shown in figure 1, M parts with no holes and public edges in a sheet need to be cut. The laser head starts from the bottom left corner of the sheet (starting point O), in turn cuts out the contour shapes of each part, and then returns to the origin point O, thus the process of cutting all the parts is completed. In the process of cutting, the laser head is in the state of 'light-cutting' when it moves along the contour lines, and it is in the state of 'not-cutting' when it moves between the contour lines (that is empty travel). Because the length of the contours and the speed of the laser head are constant, the overall length of cutting paths can be reduced only by shortening the distance of empty travel between the contours. Therefore, the goal of cutting path optimization is to find a best laser operation path, so that the distance of empty travel is the shortest in the cutting process.

Constraint rules of parts cutting
In the most current literature, the constraint rules of serial cutting parts were adopted. The laser head must run along the contour of a part, and then cut the next part. So when the cutting path was optimized and analyzed, a point could be picked up from the contours as the punch point (cutting starting point and end point), and the point can replace the contour of parts. So the contours of parts to be cut can be simplified to a point set in the plate plane. The cutting path optimization problem was transformed into solving the shortest distance between point sets, known as the TSP [7]. Most of the literature first determined the punch points of the contours by the nearest neighbor algorithm, then used all kinds of related algorithm to solve the TSP problem. This method can make the cutting path optimization problem be resolved. But after the further study, it was found that the method could cause certain influence to the optimization results. As shown in figure 2 (a), there are two parts to be cut in a sheet. The vertices of part 1 are ( 1 , and the vertices of part 2 are ( 2 Using the nearest neighbor algorithm, the punch points can be determined: 1 1 P and 2 1 P . The complete cutting path can be expressed as: O→ 1 If not restricted by the constraint rules of serial cutting, the laser head can be allowed to cut other parts before a part is not yet finished. The cutting path was shown in figure 2 . It is obvious that the latter is shorter. Thus, under the influence of the constraint rules of serial cutting, the traditional algorithm sometimes can not find the optimal solution. Aimed at the problem, this paper put forward the constraint rules of cross cutting. Namely in the process of cutting parts, the laser head could freely transfer between the contours of the  .
According to the requirement of cutting parts, no matter what order, as long as the laser head walks along all the discretization contour lines of parts, all parts will be finished. At this point, the cutting path optimization problem was transformed into: how to plan the cutting order of the contour lines in order to make the empty travel become the shortest. According to certain rules, it is supposed that the cutting order sequence is obtained, as shown in So, the mathematical model of cutting path optimization problem is: , coordinate matrix of contour lines NPLM generating by (3).
Step2. Starting nc iterative calculation. Path and S are all set zero matrix, Step3. Traversing the ant colony. For ant k, its location is the origin point, Step4. Selecting the lines. The matrix of heuristic factor is obtained by formula (4), and then it is processed by formula (5).
The selecting probability matrix of line is obtained by formula (6) , and then it is processed by formula (7).
) (PK sum PK PK  (7) The index of line selected by ant is calculated by the roulette rules.
Step5. Triggering the event. Read the endpoint coordinates of selected lines. , and go to Step3. If u k  , then go to Step9.
Step9. Update the global optimal solution. Find the local optimal vectorY  and the optimal path matrix t PathBes  , and put Y  into RCourse .
Step10. Update the pheromone matrix by the formula (11).
Step11. Judge whether the iteration of algorithm is over. Step12. Output the coordinates points of the optimal path. The coordinates matrix of the optimal path XY PathBest _ is generated, and the calculated results is output.

Conclusion
The traditional CNC laser cutting path optimization method of sheet metal pieces was improved in this paper. The constraint rules of cross cutting and discretization method of contour lines were proposed. Based on these, the cutting path optimization mathematical model was established, and the optimization method was designed by the ant colony algorithm.