<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE article PUBLIC "-//NLM//DTD Journal Publishing DTD v2.3 20070202//EN" "journalpublishing.dtd">
<article article-type="research-article" dtd-version="2.3" xml:lang="EN" xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink">
<front>
<journal-meta>
<journal-id journal-id-type="publisher-id">Front. Mech. Eng</journal-id>
<journal-title>Frontiers in Mechanical Engineering</journal-title>
<abbrev-journal-title abbrev-type="pubmed">Front. Mech. Eng</abbrev-journal-title>
<issn pub-type="epub">2297-3079</issn>
<publisher>
<publisher-name>Frontiers Media S.A.</publisher-name>
</publisher>
</journal-meta>
<article-meta>
<article-id pub-id-type="publisher-id">1361929</article-id>
<article-id pub-id-type="doi">10.3389/fmech.2024.1361929</article-id>
<article-categories>
<subj-group subj-group-type="heading">
<subject>Mechanical Engineering</subject>
<subj-group>
<subject>Original Research</subject>
</subj-group>
</subj-group>
</article-categories>
<title-group>
<article-title>Optimization of machining path for integral impeller side milling based on SA-PSO fusion algorithm in CNC machine tools</article-title>
<alt-title alt-title-type="left-running-head">Zhao</alt-title>
<alt-title alt-title-type="right-running-head">
<ext-link ext-link-type="uri" xlink:href="https://doi.org/10.3389/fmech.2024.1361929">10.3389/fmech.2024.1361929</ext-link>
</alt-title>
</title-group>
<contrib-group>
<contrib contrib-type="author" corresp="yes">
<name>
<surname>Zhao</surname>
<given-names>Yu</given-names>
</name>
<xref ref-type="corresp" rid="c001">&#x2a;</xref>
<uri xlink:href="https://loop.frontiersin.org/people/2614987/overview"/>
<role content-type="https://credit.niso.org/contributor-roles/conceptualization/"/>
<role content-type="https://credit.niso.org/contributor-roles/data-curation/"/>
<role content-type="https://credit.niso.org/contributor-roles/formal-analysis/"/>
<role content-type="https://credit.niso.org/contributor-roles/investigation/"/>
<role content-type="https://credit.niso.org/contributor-roles/methodology/"/>
<role content-type="https://credit.niso.org/contributor-roles/resources/"/>
<role content-type="https://credit.niso.org/contributor-roles/writing-original-draft/"/>
<role content-type="https://credit.niso.org/contributor-roles/Writing - review &#x26; editing/"/>
</contrib>
</contrib-group>
<aff>
<institution>School of Intelligent Manufacturing</institution>, <institution>Chongqing Industry &#x26; Trade Polytechnic</institution>, <addr-line>Fuling</addr-line>, <country>China</country>
</aff>
<author-notes>
<fn fn-type="edited-by">
<p>
<bold>Edited by:</bold> <ext-link ext-link-type="uri" xlink:href="https://loop.frontiersin.org/people/1688154/overview">Wan-Chun Chuang</ext-link>, National Cheng Kung University, Taiwan</p>
</fn>
<fn fn-type="edited-by">
<p>
<bold>Reviewed by:</bold> <ext-link ext-link-type="uri" xlink:href="https://loop.frontiersin.org/people/1268093/overview">Ding Zhang</ext-link>, Guangdong University of Technology, China</p>
<p>
<ext-link ext-link-type="uri" xlink:href="https://loop.frontiersin.org/people/1267283/overview">Zhongmei Gao</ext-link>, Wuhan University of Technology, China</p>
</fn>
<corresp id="c001">&#x2a;Correspondence: Yu Zhao, <email>zhaoyu821122@163.com</email>
</corresp>
</author-notes>
<pub-date pub-type="epub">
<day>07</day>
<month>06</month>
<year>2024</year>
</pub-date>
<pub-date pub-type="collection">
<year>2024</year>
</pub-date>
<volume>10</volume>
<elocation-id>1361929</elocation-id>
<history>
<date date-type="received">
<day>27</day>
<month>12</month>
<year>2023</year>
</date>
<date date-type="accepted">
<day>21</day>
<month>05</month>
<year>2024</year>
</date>
</history>
<permissions>
<copyright-statement>Copyright &#xa9; 2024 Zhao.</copyright-statement>
<copyright-year>2024</copyright-year>
<copyright-holder>Zhao</copyright-holder>
<license xlink:href="http://creativecommons.org/licenses/by/4.0/">
<p>This is an open-access article distributed under the terms of the Creative Commons Attribution License (CC BY). The use, distribution or reproduction in other forums is permitted, provided the original author(s) and the copyright owner(s) are credited and that the original publication in this journal is cited, in accordance with accepted academic practice. No use, distribution or reproduction is permitted which does not comply with these terms.</p>
</license>
</permissions>
<abstract>
<p>The five axis linkage Computer Numerical Control machine tool for integral impeller can achieve blade machining through side milling, which is of great significance for improving the machining accuracy, production efficiency, and long-term stability of integral impeller blades. This study is based on non-uniform rational B-spline curves and aims to reduce the surface over cutting or under cutting of integral turbine blades. The path planning of non deployable ruled surfaces was analyzed in depth through side milling, and the path planning model of the side milling cutter axis was solved through a fusion algorithm of simulated annealing algorithm and particle swarm optimization algorithm, in order to find the optimal path through iterative process. As the number of iterations increased, the error values of particle swarm optimization algorithm and simulated annealing particle swarm optimization fusion algorithm gradually decreased, with convergence times of about 7 and 6, respectively. The stable error value of the fusion algorithm was 0.253, which is 30.45% lower than that of the particle swarm optimization algorithm. The optimal number of iterations for solving the model using particle swarm optimization algorithm and fusion algorithm was the 7th, with range values of 0.0213 and 0.0165 mm, respectively. The tool axis trajectory surface optimized by the fusion algorithm was closer to the tool axis motion state compared to the initial tool axis trajectory surface. The range of the sum of mean squared deviations for single and global cutting was 0.0011&#x2013;0.0198 and 0.046&#x2013;0.0341, but the overall error value was relatively small. This study effectively reduces the envelope error of machining tools and improves machining accuracy, thereby solving the principle error of non expandable ruled surfaces in the motion trajectory of the blade axis of the integral turbine. This provides new research ideas for the intelligent development of Computer Numerical Control machining technology.</p>
</abstract>
<kwd-group>
<kwd>SA</kwd>
<kwd>PSO</kwd>
<kwd>integrated impeller</kwd>
<kwd>non expandable straight surface</kwd>
<kwd>NURBS</kwd>
</kwd-group>
<custom-meta-wrap>
<custom-meta>
<meta-name>section-at-acceptance</meta-name>
<meta-value>Mechatronics</meta-value>
</custom-meta>
</custom-meta-wrap>
</article-meta>
</front>
<body>
<sec id="s1">
<title>1 Introduction</title>
<p>In recent years, the machine tool manufacturing industry has developed rapidly, and Computer Numerical Control machine tools (CNC-MT) have covered all manufacturing industries. Digital control utilizes digital technology to manage the movement and cutting of machine tools, including mechanical manufacturing, inspection, automatic control, and computer technology, with advantages such as high machining accuracy and fast machining efficiency. With the rapid development of aerospace, national defense, new energy and other fields, industries with complex structures are rapidly rising (<xref ref-type="bibr" rid="B8">Kiswanto, 2020</xref>; <xref ref-type="bibr" rid="B11">Liu et al., 2021</xref>; <xref ref-type="bibr" rid="B7">Guo et al., 2023</xref>). Integrated turbine blades (ITB), as complex thin-walled components, are widely used in fields such as water conservancy and aviation, and their proportion in aviation generators reaches 30%. Against the backdrop of increasing demand in the national defense market, the production requirements of ITB are developing towards high precision and efficiency. Different from open and semi open, due to the thinner ITB blades and narrower distance between blades, there is not enough machining space for the cutting tools during the blade machining process. At the same time, due to the existence of non expandable ruled surfaces (NERS) with fundamental errors, it is difficult for the tool edge to fully fit with the blade surface, resulting in insufficient or excessive cutting between the NERS and the tool envelope surfaces (TES), which greatly increases the difficulty of ITB machining. The methods of machining complex surfaces can be divided into point milling and side milling. The former is accurate in machining, but the tool path range is small, so the consistency of surface machining of parts is low (<xref ref-type="bibr" rid="B1">Cheng et al., 2020</xref>; <xref ref-type="bibr" rid="B5">Franciosa et al., 2020</xref>; <xref ref-type="bibr" rid="B18">Wei Y. et al., 2021</xref>). Therefore, this study will be based on Non Uniform Rational B-Spline (NURBS) curves, with the goal of reducing over cutting or under cutting on the surface of ITB blades, and conduct in-depth analysis of NERS path planning through side milling. In addition, the path planning model is solved by integrating Simulated Annealing (SA) and Particle Swarm Optimization (PSO) algorithms to iteratively find the optimal path. The innovation of the research can be mainly summarized as the following two points. One is to construct NER based on NURBS and analyze the principle error of NER in the motion trajectory of ITB tool axis. The second is to use the SA-PSO fusion algorithm to solve the path planning model of NERS for side milling in this study. This study will elaborate on it from the following four aspects. Part 1 elaborates on the current research status of CNC-MT technology and ITB side milling at home and abroad. Part 2 introduces the NERS path planning for ITB side milling, with a focus on the SA-PSO fusion algorithm. Part 3 analyzed the effectiveness and feasibility of the NERS path planning for ITB side milling. Part 4 summarizes the research results and proposes the development direction for the next step of research.</p>
</sec>
<sec id="s2">
<title>2 Related works</title>
<p>CNC technology has been widely applied in various manufacturing fields such as aerospace. At the same time, some achievements have been made in the research of blade path planning and impeller models. Wei and other researchers proposed trajectory planning for conical cutter side milling of integral impellers, obtaining the cutting and expanding tool trajectories through NURBS curves. At the same time, the five axis side milling method was used for precision machining of the blades of the integral turbine. The virtual simulation system of the machining center confirmed that compared to the ball end milling cutter, the tool path trajectory was finer, the machining accuracy was higher, and it was easier to optimize the tool path. The machining accuracy error was 0.007&#x2013;0.012&#xa0;mm (<xref ref-type="bibr" rid="B17">Wei J. et al., 2021</xref>). Yu et al. proposed a new calculation method for the error of the R-offset tool axis for the tool axis trajectory planning problem of NERS machining with conical cutting tools, and derived an accurate analysis using a formula. This method could obtain the theoretical machining error of each point on the straight generatrix, and the test results further verified this conclusion. The difference between the machining error and the theoretical error was almost 0 (<xref ref-type="bibr" rid="B20">Yu et al., 2021</xref>). Feng et al. proposed a U-shaped milling method that combines traditional cycloidal milling and side milling. This method defined the feature parameters of the path and used the concatenated micro arc mapping algorithm to map the three-dimensional boundaries to obtain the distribution pattern of tool contact points. The three-axis milling groove test showed that the peak and average cutting forces decreased by 25% and 60%, respectively. Therefore, this method could reduce the instability of cutting force, improve machining efficiency, and reduce the degree of tool wear (<xref ref-type="bibr" rid="B4">Feng et al., 2021</xref>). Zhao et al. proposed a structure that utilizes NiAl based high-temperature alloy for milling precision of narrow blade turbine impellers to achieve the milling accuracy of typical thin-walled structural components of turbine engines. It determined optimization parameters through milling force and tool wear behavior, and proposed a flexible iterative compensation method to reduce machining errors in impeller milling. The milling accuracy of turbine impeller had significantly improved (<xref ref-type="bibr" rid="B22">Zhao et al., 2020</xref>). Fan et al. proposed a five axis milling method based on NURBS curves and applied it to centrifugal impellers with crowns. They also analyzed the calculation method of the final section. The machining accuracy of the crown centrifugal impeller was significantly reduced, and this method had certain feasibility in the machining field (<xref ref-type="bibr" rid="B3">Fan et al., 2020</xref>).</p>
<p>Yan&#x2019;s team analyzed the path planning problem of conical tool side milling method and proposed a solution algorithm using immune PSO and least squares method. The objective function was set as the error measurement function for each tool position, and the initial tool position was determined by the two-point offset method. The machining error of this method was reduced by 86% relative to the specified error (<xref ref-type="bibr" rid="B19">Yan et al., 2021</xref>). Serin et al. conducted in-depth analysis on integrated energy-saving machining of rotating impellers and optimized the objective function using PSO intelligent algorithm. This scheme could achieve precision machining of turbine blades (<xref ref-type="bibr" rid="B13">Serin et al., 2020</xref>). Researchers such as T&#xfc;chler used a hybrid algorithm of PSO and genetic algorithm to optimize the rotor shape profile, wall thickness, and number of channels of a wave rotor. This confirmed that the numerical optimization method has more advantages compared to traditional methods (<xref ref-type="bibr" rid="B15">T&#xfc;chler and Copeland, 2021</xref>). Guo and other scholars analyzed the optimization model of surface roughness and cutting force using multi-objective PSO to achieve the accuracy and speed of nickel based high-temperature alloy processing. The relative error between the true value of tangential cutting force and the predicted value of the model was 8.14% (<xref ref-type="bibr" rid="B6">Guo et al., 2022</xref>).</p>
<p>Based on the current research status of integrated impeller CNC machining both domestically and internationally, in-depth research has been conducted on the design and accuracy improvement of various tool paths. The commonly used four point bias method and particle swarm optimization algorithm have better matching performance compared to other algorithms. However, the four point equidistant offset method may suffer damage from the previous tool&#x2019;s machining position and cannot achieve the expected machining effect. Therefore, it cannot be used for actual CNC-MT machining. This study will take the side milling machining method as an example and solve the path planning model of the side milling cutter axis using the SA-PSO fusion algorithm, in order to achieve the maximum approximation of TES to the design surface.</p>
</sec>
<sec id="s3">
<title>3 SA-PSO fusion algorithm in CNC machining of integral impeller</title>
<p>High speed machining technology has evolved from three-axis machining to five axis machining. Five axis machining is currently an important means of machining complex surfaces. The CNC machining machine tool for turbine blades differs from ordinary machine tools in that it has high precision and manufacturing efficiency. And it has an impeller digital processing module, which can complete the processing of different types of surfaces such as ruled surfaces, NER surfaces, and complex surfaces. There are two problems in current research, namely, the design of surfaces and TES deviations for single tool path planning, as well as the high computational complexity and low computational efficiency of the constructed mathematical model. This study will take the side milling machining method as an example and solve the side milling cutter axis path planning model using the SA-PSO fusion algorithm. The key to this model is to find the machining pose at each moment, so that the envelope surface of the tool is consistent with the design surface.</p>
<sec id="s3-1">
<title>3.1 NERS fitting and error determination function</title>
<p>For NER, NURBS has the following advantages compared to Bezier curves. Firstly, once the number of vertices of the feature polygon is determined, it also determines the order of the curve. The more vertices there are, the higher the order, and the more complex the curve generation becomes. When the Bessel curve passes through <inline-formula id="inf1">
<mml:math id="m1">
<mml:mrow>
<mml:mi>n</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> data points, it will generate <inline-formula id="inf2">
<mml:math id="m2">
<mml:mrow>
<mml:mi>n</mml:mi>
<mml:mo>&#x2212;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:math>
</inline-formula> degree curves, and the computer generation speed will be slow and the stability will be poor. Secondly, if the position of a vertex is changed, the shape of the global Bezier curve will change. In addition, the stitching of Bezier curves and surfaces is quite complex. Compared to the Bezier curve, NURBS curves overcome the aforementioned drawbacks. Changing the vertex position does not affect the global curve shape and has good plasticity. The schematic diagram of a NURBS surface is <xref ref-type="fig" rid="F1">Figure 1</xref>. The graph refers to a bivariate piecewise rational vector function <inline-formula id="inf3">
<mml:math id="m3">
<mml:mrow>
<mml:mi>S</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>u</mml:mi>
<mml:mo>,</mml:mo>
<mml:mi>v</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula> that moves <inline-formula id="inf4">
<mml:math id="m4">
<mml:mrow>
<mml:mi>p</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> and <inline-formula id="inf5">
<mml:math id="m5">
<mml:mrow>
<mml:mi>q</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> times in the <inline-formula id="inf6">
<mml:math id="m6">
<mml:mrow>
<mml:mi>u</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> and <inline-formula id="inf7">
<mml:math id="m7">
<mml:mrow>
<mml:mi>v</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> directions, respectively.<disp-formula id="e1">
<mml:math id="m8">
<mml:mrow>
<mml:mi>S</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>u</mml:mi>
<mml:mo>,</mml:mo>
<mml:mi>v</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>&#x3d;</mml:mo>
<mml:mfrac>
<mml:mrow>
<mml:mstyle displaystyle="true">
<mml:munderover>
<mml:mo>&#x2211;</mml:mo>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mo>&#x3d;</mml:mo>
<mml:mn>0</mml:mn>
</mml:mrow>
<mml:mi>n</mml:mi>
</mml:munderover>
</mml:mstyle>
<mml:mstyle displaystyle="true">
<mml:munderover>
<mml:mo>&#x2211;</mml:mo>
<mml:mrow>
<mml:mi>j</mml:mi>
<mml:mo>&#x3d;</mml:mo>
<mml:mn>0</mml:mn>
</mml:mrow>
<mml:mi>m</mml:mi>
</mml:munderover>
</mml:mstyle>
<mml:msub>
<mml:mi>N</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mo>,</mml:mo>
<mml:mi>p</mml:mi>
</mml:mrow>
</mml:msub>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>u</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:msub>
<mml:mi>N</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mo>,</mml:mo>
<mml:mi>q</mml:mi>
</mml:mrow>
</mml:msub>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>v</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:msub>
<mml:mi>&#x3c6;</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mo>,</mml:mo>
<mml:mi>j</mml:mi>
</mml:mrow>
</mml:msub>
<mml:msub>
<mml:mi>P</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mo>,</mml:mo>
<mml:mi>j</mml:mi>
</mml:mrow>
</mml:msub>
</mml:mrow>
<mml:mrow>
<mml:mstyle displaystyle="true">
<mml:munderover>
<mml:mo>&#x2211;</mml:mo>
<mml:mrow>
<mml:mi>k</mml:mi>
<mml:mo>&#x3d;</mml:mo>
<mml:mn>0</mml:mn>
</mml:mrow>
<mml:mi>n</mml:mi>
</mml:munderover>
</mml:mstyle>
<mml:mstyle displaystyle="true">
<mml:munderover>
<mml:mo>&#x2211;</mml:mo>
<mml:mrow>
<mml:mi>l</mml:mi>
<mml:mo>&#x3d;</mml:mo>
<mml:mn>0</mml:mn>
</mml:mrow>
<mml:mi>m</mml:mi>
</mml:munderover>
</mml:mstyle>
<mml:msub>
<mml:mi>N</mml:mi>
<mml:mrow>
<mml:mi>k</mml:mi>
<mml:mo>,</mml:mo>
<mml:mi>p</mml:mi>
</mml:mrow>
</mml:msub>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>u</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:msub>
<mml:mi>N</mml:mi>
<mml:mrow>
<mml:mi>l</mml:mi>
<mml:mo>,</mml:mo>
<mml:mi>q</mml:mi>
</mml:mrow>
</mml:msub>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>v</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:msub>
<mml:mi>&#x3c6;</mml:mi>
<mml:mrow>
<mml:mi>k</mml:mi>
<mml:mo>,</mml:mo>
<mml:mi>l</mml:mi>
</mml:mrow>
</mml:msub>
</mml:mrow>
</mml:mfrac>
</mml:mrow>
</mml:math>
<label>(1)</label>
</disp-formula>
</p>
<fig id="F1" position="float">
<label>FIGURE 1</label>
<caption>
<p>Schematic diagram of NURBS surface.</p>
</caption>
<graphic xlink:href="fmech-10-1361929-g001.tif"/>
</fig>
<p>In Eq. <xref ref-type="disp-formula" rid="e1">1</xref>, <inline-formula id="inf8">
<mml:math id="m9">
<mml:mrow>
<mml:msub>
<mml:mi>&#x3c6;</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mo>,</mml:mo>
<mml:mi>j</mml:mi>
</mml:mrow>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula> refers to the weight factor. The control vertex is <inline-formula id="inf9">
<mml:math id="m10">
<mml:mrow>
<mml:msub>
<mml:mi>P</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mo>,</mml:mo>
<mml:mi>j</mml:mi>
</mml:mrow>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula>. The normal B-spline basis functions on node vector <inline-formula id="inf10">
<mml:math id="m11">
<mml:mrow>
<mml:mi>U</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> of degree <inline-formula id="inf11">
<mml:math id="m12">
<mml:mrow>
<mml:mi>p</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> and node vector <inline-formula id="inf12">
<mml:math id="m13">
<mml:mrow>
<mml:mi>V</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> of degree <inline-formula id="inf13">
<mml:math id="m14">
<mml:mrow>
<mml:mi>q</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> are <inline-formula id="inf14">
<mml:math id="m15">
<mml:mrow>
<mml:msub>
<mml:mi>N</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mo>,</mml:mo>
<mml:mi>p</mml:mi>
</mml:mrow>
</mml:msub>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>u</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula> and <inline-formula id="inf15">
<mml:math id="m16">
<mml:mrow>
<mml:msub>
<mml:mi>N</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mo>,</mml:mo>
<mml:mi>q</mml:mi>
</mml:mrow>
</mml:msub>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>v</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula>, respectively.</p>
<p>The blade roughness of the integral impeller model is 0.4, and the roughness of other parts is 0.8. By using the parameter function in UG software to partition the mesh, mesh surfaces can be generated. The point set function is utilized to select points on the grid and convert them into point coordinates using an NX. grx file. <xref ref-type="table" rid="T1">Table 1</xref> shows the coordinates of some blade root and top lines.</p>
<table-wrap id="T1" position="float">
<label>TABLE 1</label>
<caption>
<p>The coordinates of the root line and the top line of the blade.</p>
</caption>
<table>
<thead valign="top">
<tr>
<th rowspan="2" align="center">Data point</th>
<th colspan="3" align="center">Leaf crest line</th>
<th colspan="3" align="center">Leaf root line</th>
</tr>
<tr>
<th align="center">X axle</th>
<th align="center">Y axle</th>
<th align="center">Z axle</th>
<th align="center">X axle</th>
<th align="center">Y axle</th>
<th align="center">Z axle</th>
</tr>
</thead>
<tbody valign="top">
<tr>
<td align="center">1</td>
<td align="center">10.18</td>
<td align="center">&#x2212;1.452</td>
<td align="center">85.362</td>
<td align="center">15.242</td>
<td align="center">&#x2212;4.251</td>
<td align="center">90.568</td>
</tr>
<tr>
<td align="center">2</td>
<td align="center">14.251</td>
<td align="center">&#x2212;0.785</td>
<td align="center">82.354</td>
<td align="center">17.462</td>
<td align="center">&#x2212;1.025</td>
<td align="center">87.425</td>
</tr>
<tr>
<td align="center">3</td>
<td align="center">8.596</td>
<td align="center">&#x2212;1.725</td>
<td align="center">88.635</td>
<td align="center">15.423</td>
<td align="center">&#x2212;4.425</td>
<td align="center">90.456</td>
</tr>
<tr>
<td align="center">4</td>
<td align="center">13.256</td>
<td align="center">&#x2212;0.956</td>
<td align="center">82.345</td>
<td align="center">14.852</td>
<td align="center">&#x2212;4.926</td>
<td align="center">90.435</td>
</tr>
<tr>
<td align="center">5</td>
<td align="center">7.894</td>
<td align="center">&#x2212;2.125</td>
<td align="center">89.685</td>
<td align="center">16.725</td>
<td align="center">&#x2212;2.352</td>
<td align="center">88.635</td>
</tr>
<tr>
<td align="center">6</td>
<td align="center">6.586</td>
<td align="center">&#x2212;1.025</td>
<td align="center">84.253</td>
<td align="center">14.536</td>
<td align="center">&#x2212;5.362</td>
<td align="center">91.425</td>
</tr>
<tr>
<td align="center">7</td>
<td align="center">10.852</td>
<td align="center">&#x2212;2.732</td>
<td align="center">91.625</td>
<td align="center">16.257</td>
<td align="center">&#x2212;3.042</td>
<td align="center">91.556</td>
</tr>
<tr>
<td align="center">8</td>
<td align="center">9.365</td>
<td align="center">&#x2212;1.365</td>
<td align="center">86.325</td>
<td align="center">17.452</td>
<td align="center">&#x2212;1.536</td>
<td align="center">89.325</td>
</tr>
</tbody>
</table>
</table-wrap>
<p>The fitting curve of the data points is an interpolation curve. This study used NURBS interpolation to fit data points to form the blade baseline. Firstly, to generate NER using UG software, divide the mesh into surface patches, and represent the data points on them in the form of coordinates. Using MATLAB software to reverse calculate control points and node vectors, while generating blade curves. Surface patches were obtained by connecting the corresponding points of the blades, and finally to evaluate the continuity and smoothness of the blade model. Assuming a NURBS curve has <inline-formula id="inf16">
<mml:math id="m17">
<mml:mrow>
<mml:mi>U</mml:mi>
<mml:mo>&#x3d;</mml:mo>
<mml:mrow>
<mml:mfenced open="[" close="]" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>u</mml:mi>
<mml:mn>0</mml:mn>
</mml:msub>
<mml:mo>,</mml:mo>
<mml:msub>
<mml:mi>u</mml:mi>
<mml:mn>1</mml:mn>
</mml:msub>
<mml:mo>,</mml:mo>
<mml:mn>L</mml:mn>
<mml:mo>&#x2009;</mml:mo>
<mml:mo>,</mml:mo>
<mml:msub>
<mml:mi>u</mml:mi>
<mml:mrow>
<mml:mi>n</mml:mi>
<mml:mo>&#x2b;</mml:mo>
<mml:mi>p</mml:mi>
<mml:mo>&#x2b;</mml:mo>
<mml:mn>2</mml:mn>
</mml:mrow>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula> node vectors, <inline-formula id="inf17">
<mml:math id="m18">
<mml:mrow>
<mml:mi>n</mml:mi>
<mml:mo>&#x2b;</mml:mo>
<mml:mn>2</mml:mn>
</mml:mrow>
</mml:math>
</inline-formula> control points, and <inline-formula id="inf18">
<mml:math id="m19">
<mml:mrow>
<mml:msub>
<mml:mi>&#x3c6;</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula> weight factors. The methods for determining node vectors include cumulative chord length parameterization (CCLP), centripetal parameterization, and uniform parameterization. Due to the varying chord lengths of the polygons controlled by cubic non-uniform rational B-spline curves, the uniform parameterization method is not suitable. Therefore, this article adopts the CCLP for calculation, which can be expressed using Eq. <xref ref-type="disp-formula" rid="e2">2</xref>.<disp-formula id="e2">
<mml:math id="m20">
<mml:mrow>
<mml:mfenced open="{" close="" separators="&#x7c;">
<mml:mrow>
<mml:mtable columnalign="left">
<mml:mtr>
<mml:mtd>
<mml:mrow>
<mml:msub>
<mml:mi>u</mml:mi>
<mml:mn>0</mml:mn>
</mml:msub>
<mml:mo>&#x3d;</mml:mo>
<mml:msub>
<mml:mi>u</mml:mi>
<mml:mn>1</mml:mn>
</mml:msub>
<mml:mo>&#x3d;</mml:mo>
<mml:msub>
<mml:mi>u</mml:mi>
<mml:mn>2</mml:mn>
</mml:msub>
<mml:mo>&#x3d;</mml:mo>
<mml:msub>
<mml:mi>u</mml:mi>
<mml:mn>3</mml:mn>
</mml:msub>
<mml:mo>&#x3d;</mml:mo>
<mml:mn>0</mml:mn>
</mml:mrow>
</mml:mtd>
</mml:mtr>
<mml:mtr>
<mml:mtd>
<mml:mrow>
<mml:msub>
<mml:mi>u</mml:mi>
<mml:mrow>
<mml:mi>n</mml:mi>
<mml:mo>&#x2b;</mml:mo>
<mml:mn>2</mml:mn>
</mml:mrow>
</mml:msub>
<mml:mo>&#x3d;</mml:mo>
<mml:msub>
<mml:mi>u</mml:mi>
<mml:mrow>
<mml:mi>n</mml:mi>
<mml:mo>&#x2b;</mml:mo>
<mml:mn>3</mml:mn>
</mml:mrow>
</mml:msub>
<mml:mo>&#x3d;</mml:mo>
<mml:msub>
<mml:mi>u</mml:mi>
<mml:mrow>
<mml:mi>n</mml:mi>
<mml:mo>&#x2b;</mml:mo>
<mml:mn>4</mml:mn>
</mml:mrow>
</mml:msub>
<mml:mo>&#x3d;</mml:mo>
<mml:msub>
<mml:mi>u</mml:mi>
<mml:mrow>
<mml:mi>n</mml:mi>
<mml:mo>&#x2b;</mml:mo>
<mml:mn>5</mml:mn>
</mml:mrow>
</mml:msub>
<mml:mo>&#x3d;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:mtd>
</mml:mtr>
<mml:mtr>
<mml:mtd>
<mml:mrow>
<mml:msub>
<mml:mi>u</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:mo>&#x3d;</mml:mo>
<mml:msub>
<mml:mi>u</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mo>&#x2212;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:msub>
<mml:mo>&#x2b;</mml:mo>
<mml:mrow>
<mml:mrow>
<mml:mfenced open="|" close="|" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>p</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:mo>&#x2212;</mml:mo>
<mml:msub>
<mml:mi>p</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mo>&#x2212;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>/</mml:mo>
<mml:mrow>
<mml:mstyle displaystyle="true">
<mml:munderover>
<mml:mo>&#x2211;</mml:mo>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mo>&#x3d;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
<mml:mi>n</mml:mi>
</mml:munderover>
</mml:mstyle>
<mml:mrow>
<mml:mfenced open="|" close="|" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>p</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:mo>&#x2212;</mml:mo>
<mml:msub>
<mml:mi>p</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mo>&#x2212;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:mrow>
</mml:mrow>
</mml:mtd>
</mml:mtr>
</mml:mtable>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:math>
<label>(2)</label>
</disp-formula>
</p>
<p>In Eq. <xref ref-type="disp-formula" rid="e2">2</xref>, <inline-formula id="inf19">
<mml:math id="m21">
<mml:mrow>
<mml:msub>
<mml:mi>p</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula> refers to the data point. Boundary conditions include tangent conditions, free endpoint conditions, and closed curve conditions. The tangent condition refers to fixing the tangent lines at the beginning and end, represented by Eq. <xref ref-type="disp-formula" rid="e3">3</xref>.<disp-formula id="e3">
<mml:math id="m22">
<mml:mrow>
<mml:mfenced open="{" close="" separators="&#x7c;">
<mml:mrow>
<mml:mtable columnalign="left">
<mml:mtr>
<mml:mtd>
<mml:mrow>
<mml:msub>
<mml:mi>d</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:mo>&#x2212;</mml:mo>
<mml:msub>
<mml:mi>d</mml:mi>
<mml:mn>0</mml:mn>
</mml:msub>
<mml:mo>&#x3d;</mml:mo>
<mml:mfrac>
<mml:mrow>
<mml:msub>
<mml:mo>&#x394;</mml:mo>
<mml:mn>3</mml:mn>
</mml:msub>
</mml:mrow>
<mml:mrow>
<mml:mn>3</mml:mn>
</mml:mrow>
</mml:mfrac>
<mml:msubsup>
<mml:mi>p</mml:mi>
<mml:mn>0</mml:mn>
<mml:mo>&#x2032;</mml:mo>
</mml:msubsup>
</mml:mrow>
</mml:mtd>
</mml:mtr>
<mml:mtr>
<mml:mtd>
<mml:mrow>
<mml:msub>
<mml:mi>d</mml:mi>
<mml:mrow>
<mml:mi>n</mml:mi>
<mml:mo>&#x2b;</mml:mo>
<mml:mn>2</mml:mn>
</mml:mrow>
</mml:msub>
<mml:mo>&#x2212;</mml:mo>
<mml:msub>
<mml:mi>d</mml:mi>
<mml:mrow>
<mml:mi>n</mml:mi>
<mml:mo>&#x2b;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:msub>
<mml:mo>&#x3d;</mml:mo>
<mml:mfrac>
<mml:mrow>
<mml:msub>
<mml:mo>&#x394;</mml:mo>
<mml:mrow>
<mml:mi>n</mml:mi>
<mml:mo>&#x2b;</mml:mo>
<mml:mn>2</mml:mn>
</mml:mrow>
</mml:msub>
</mml:mrow>
<mml:mrow>
<mml:mn>3</mml:mn>
</mml:mrow>
</mml:mfrac>
<mml:msubsup>
<mml:mi>p</mml:mi>
<mml:mi>n</mml:mi>
<mml:mo>&#x2032;</mml:mo>
</mml:msubsup>
</mml:mrow>
</mml:mtd>
</mml:mtr>
</mml:mtable>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:math>
<label>(3)</label>
</disp-formula>
</p>
<p>In Eq. <xref ref-type="disp-formula" rid="e3">3</xref>, the tangent vectors of the starting and ending breakpoints are <inline-formula id="inf20">
<mml:math id="m23">
<mml:mrow>
<mml:msubsup>
<mml:mi>p</mml:mi>
<mml:mn>0</mml:mn>
<mml:mo>&#x2032;</mml:mo>
</mml:msubsup>
</mml:mrow>
</mml:math>
</inline-formula> and <inline-formula id="inf21">
<mml:math id="m24">
<mml:mrow>
<mml:msubsup>
<mml:mi>p</mml:mi>
<mml:mi>n</mml:mi>
<mml:mo>&#x2032;</mml:mo>
</mml:msubsup>
</mml:mrow>
</mml:math>
</inline-formula>, <inline-formula id="inf22">
<mml:math id="m25">
<mml:mrow>
<mml:msub>
<mml:mi>d</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula> and <inline-formula id="inf23">
<mml:math id="m26">
<mml:mrow>
<mml:msub>
<mml:mi>d</mml:mi>
<mml:mn>0</mml:mn>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula> refer to the control vertices and control roots, and <inline-formula id="inf24">
<mml:math id="m27">
<mml:mrow>
<mml:msub>
<mml:mo>&#x394;</mml:mo>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:mo>&#x3d;</mml:mo>
<mml:msub>
<mml:mi>u</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mo>&#x2b;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:msub>
<mml:mo>&#x2212;</mml:mo>
<mml:msub>
<mml:mi>u</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula>. The free endpoint condition is that the curvature of the first and last endpoints is 0, which can be represented by Eq. <xref ref-type="disp-formula" rid="e4">4</xref>.<disp-formula id="e4">
<mml:math id="m28">
<mml:mrow>
<mml:mfenced open="{" close="" separators="&#x7c;">
<mml:mrow>
<mml:mtable columnalign="left">
<mml:mtr>
<mml:mtd>
<mml:mrow>
<mml:msub>
<mml:mi>d</mml:mi>
<mml:mn>0</mml:mn>
</mml:msub>
<mml:mo>&#x3d;</mml:mo>
<mml:msub>
<mml:mi>d</mml:mi>
<mml:mrow>
<mml:mi>n</mml:mi>
<mml:mo>&#x2b;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:msub>
</mml:mrow>
</mml:mtd>
</mml:mtr>
<mml:mtr>
<mml:mtd>
<mml:mrow>
<mml:msub>
<mml:mi>d</mml:mi>
<mml:mn>0</mml:mn>
</mml:msub>
<mml:mo>&#x3d;</mml:mo>
<mml:msub>
<mml:mi>d</mml:mi>
<mml:mrow>
<mml:mi>n</mml:mi>
<mml:mo>&#x2b;</mml:mo>
<mml:mn>2</mml:mn>
</mml:mrow>
</mml:msub>
</mml:mrow>
</mml:mtd>
</mml:mtr>
</mml:mtable>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:math>
<label>(4)</label>
</disp-formula>
</p>
<p>A NURBS cubic open curve requires two boundary conditions to meet the requirements, with a repeatability of 4. The solution process of control point inverse calculation is carried out by calculating node vectors using MATLAB software and parameterizing data points through CCLP. Finally, the control points are back calculated using tangent boundary conditions, ensuring that the fixed value points and the initial and final endpoints of the control vertices coincide. Curve fitting is obtained through the theory of generating ruled surfaces. The surface smoothness check is obtained through the built-in lighting and curvature check methods of UG software. Previous studies have focused on local path optimization, without approaching the envelope surface and transforming the tool path planning problem into a tool path optimization problem under a single tool path (<xref ref-type="bibr" rid="B10">Ladj et al., 2021</xref>; <xref ref-type="bibr" rid="B16">Weckx et al., 2022</xref>). This study will take side milling as an example for analysis, and the definitions of tool position, design surface, envelope surface, and blade offset surface are as follows. The tool position refers to the trajectory formed by the movement of the tool&#x2019;s upper points during the milling process. The tool axis and tool center jointly determine the position of the tool in space. The surface design is the impeller blade surface, which is a NURBS surface. The envelope surface refers to the trajectory surface obtained through the control of CNC-MT related programs. Blade offset surface refers to a design surface that is offset by a tool radius in the forward direction. The method for determining the initial tool position and posture in this study is the three-point offset method. For the principle error of NER S, this study established an error determination function. The tool axis is discretized by setting the point on the tool axis as <inline-formula id="inf25">
<mml:math id="m29">
<mml:mrow>
<mml:mi>Q</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> and the discrete points are set as <inline-formula id="inf26">
<mml:math id="m30">
<mml:mrow>
<mml:msub>
<mml:mi>Q</mml:mi>
<mml:mn>1</mml:mn>
</mml:msub>
<mml:mo>,</mml:mo>
<mml:msub>
<mml:mi>Q</mml:mi>
<mml:mn>2</mml:mn>
</mml:msub>
<mml:mo>,</mml:mo>
<mml:msub>
<mml:mi>Q</mml:mi>
<mml:mn>3</mml:mn>
</mml:msub>
<mml:mo>,</mml:mo>
<mml:mn>L</mml:mn>
<mml:mo>&#x2009;</mml:mo>
<mml:mo>,</mml:mo>
<mml:msub>
<mml:mi>Q</mml:mi>
<mml:mi>n</mml:mi>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula>. Drawing a perpendicular line towards the design surface through discrete points, with the perpendicular points denoted by <inline-formula id="inf27">
<mml:math id="m31">
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>o</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:mo>,</mml:mo>
<mml:msub>
<mml:mi>y</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:math>
</inline-formula> and the perpendicular feet denoted by <inline-formula id="inf28">
<mml:math id="m32">
<mml:mrow>
<mml:msub>
<mml:mi>P</mml:mi>
<mml:mn>1</mml:mn>
</mml:msub>
<mml:mo>,</mml:mo>
<mml:msub>
<mml:mi>P</mml:mi>
<mml:mn>2</mml:mn>
</mml:msub>
<mml:mo>,</mml:mo>
<mml:msub>
<mml:mi>P</mml:mi>
<mml:mn>3</mml:mn>
</mml:msub>
<mml:mo>,</mml:mo>
<mml:mn>L</mml:mn>
<mml:mo>&#x2009;</mml:mo>
<mml:mo>,</mml:mo>
<mml:msub>
<mml:mi>P</mml:mi>
<mml:mi>n</mml:mi>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula>. Assuming that the blade axis poses are all located at the optimal position, each blade axis pose can be represented by Eq. <xref ref-type="disp-formula" rid="e5">5</xref>.<disp-formula id="e5">
<mml:math id="m33">
<mml:mrow>
<mml:mrow>
<mml:mfenced open="|" close="|" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>Q</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:msub>
<mml:mi>P</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>&#x3d;</mml:mo>
<mml:msub>
<mml:mi>r</mml:mi>
<mml:mi>c</mml:mi>
</mml:msub>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>Q</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
<label>(5)</label>
</disp-formula>
</p>
<p>In Eq. <xref ref-type="disp-formula" rid="e5">5</xref>, the distance between different positions on the tool axis and the design surface is <inline-formula id="inf29">
<mml:math id="m34">
<mml:mrow>
<mml:mfenced open="|" close="|" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>Q</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:msub>
<mml:mi>P</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:math>
</inline-formula>, and the tool radius at different positions on the tool axis is <inline-formula id="inf30">
<mml:math id="m35">
<mml:mrow>
<mml:msub>
<mml:mi>r</mml:mi>
<mml:mi>c</mml:mi>
</mml:msub>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>Q</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula>. In practical situations, the values of <inline-formula id="inf31">
<mml:math id="m36">
<mml:mrow>
<mml:mfenced open="|" close="|" separators="&#x7c;">
<mml:mrow>
<mml:mrow>
<mml:mfenced open="|" close="|" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>Q</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:msub>
<mml:mi>P</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>&#x2212;</mml:mo>
<mml:msub>
<mml:mi>r</mml:mi>
<mml:mi>c</mml:mi>
</mml:msub>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>Q</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:math>
</inline-formula> all exceed 0, in which case the problem can be transformed into an <inline-formula id="inf32">
<mml:math id="m37">
<mml:mrow>
<mml:mfenced open="|" close="|" separators="&#x7c;">
<mml:mrow>
<mml:mrow>
<mml:mfenced open="|" close="|" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>Q</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:msub>
<mml:mi>P</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>&#x2212;</mml:mo>
<mml:msub>
<mml:mi>r</mml:mi>
<mml:mi>c</mml:mi>
</mml:msub>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>Q</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:math>
</inline-formula> minimum problem. If the <inline-formula id="inf33">
<mml:math id="m38">
<mml:mrow>
<mml:mfenced open="|" close="|" separators="&#x7c;">
<mml:mrow>
<mml:mrow>
<mml:mfenced open="|" close="|" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>Q</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:msub>
<mml:mi>P</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>&#x2212;</mml:mo>
<mml:msub>
<mml:mi>r</mml:mi>
<mml:mi>c</mml:mi>
</mml:msub>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>Q</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:math>
</inline-formula> value is the minimum for each single cutting position, then the envelope surface generated by the tool cutting is infinitely close to the design surface, which can minimize the principle error value. The error measurement function <inline-formula id="inf34">
<mml:math id="m39">
<mml:mrow>
<mml:mi>f</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>t</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula> is expressed as Eq. <xref ref-type="disp-formula" rid="e6">6</xref>.<disp-formula id="e6">
<mml:math id="m40">
<mml:mrow>
<mml:mi>f</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>t</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>&#x3d;</mml:mo>
<mml:msup>
<mml:mrow>
<mml:mstyle displaystyle="true">
<mml:munderover>
<mml:mo>&#x2211;</mml:mo>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mo>&#x3d;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
<mml:mi>n</mml:mi>
</mml:munderover>
</mml:mstyle>
<mml:mrow>
<mml:mfenced open="[" close="]" separators="&#x7c;">
<mml:mrow>
<mml:mrow>
<mml:mfenced open="|" close="|" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>Q</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:msub>
<mml:mi>P</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>&#x2212;</mml:mo>
<mml:msub>
<mml:mi>r</mml:mi>
<mml:mi>c</mml:mi>
</mml:msub>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>Q</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
<mml:mn>2</mml:mn>
</mml:msup>
</mml:mrow>
</mml:math>
<label>(6)</label>
</disp-formula>
</p>
<p>In Eq. <xref ref-type="disp-formula" rid="e6">6</xref>, the position and attitude of the tool axis are <inline-formula id="inf35">
<mml:math id="m41">
<mml:mrow>
<mml:mi>t</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>, and the optimal position and attitude of the tool axis are <inline-formula id="inf36">
<mml:math id="m42">
<mml:mrow>
<mml:msup>
<mml:mi>t</mml:mi>
<mml:mo>&#x2a;</mml:mo>
</mml:msup>
</mml:mrow>
</mml:math>
</inline-formula>. The optimal condition can be represented by Eq. <xref ref-type="disp-formula" rid="e7">7</xref>.<disp-formula id="e7">
<mml:math id="m43">
<mml:mrow>
<mml:msup>
<mml:mi>t</mml:mi>
<mml:mo>&#x2a;</mml:mo>
</mml:msup>
<mml:mo>&#x3d;</mml:mo>
<mml:mi>argmin</mml:mi>
<mml:mi>f</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>t</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
<label>(7)</label>
</disp-formula>
</p>
<p>The optimal tool position posture is the minimum sum of the squared distances from any point on the tool axis to the tool surface and the design surface. The foot drop point <inline-formula id="inf37">
<mml:math id="m44">
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>o</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:mo>,</mml:mo>
<mml:msub>
<mml:mi>y</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:math>
</inline-formula> satisfies Eq. <xref ref-type="disp-formula" rid="e8">8</xref>.<disp-formula id="e8">
<mml:math id="m45">
<mml:mrow>
<mml:mfenced open="{" close="" separators="&#x7c;">
<mml:mrow>
<mml:mtable columnalign="left">
<mml:mtr>
<mml:mtd>
<mml:mrow>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>Q</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:mo>&#x2212;</mml:mo>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>o</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:mo>,</mml:mo>
<mml:msub>
<mml:mi>y</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:msub>
<mml:mi>r</mml:mi>
<mml:mi>o</mml:mi>
</mml:msub>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>o</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:mo>,</mml:mo>
<mml:msub>
<mml:mi>y</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>&#x3d;</mml:mo>
<mml:mn>0</mml:mn>
</mml:mrow>
</mml:mtd>
</mml:mtr>
<mml:mtr>
<mml:mtd>
<mml:mrow>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>Q</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:mo>&#x2212;</mml:mo>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>o</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:mo>,</mml:mo>
<mml:msub>
<mml:mi>y</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:msub>
<mml:mi>r</mml:mi>
<mml:mi>y</mml:mi>
</mml:msub>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>o</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:mo>,</mml:mo>
<mml:msub>
<mml:mi>y</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>&#x3d;</mml:mo>
<mml:mn>0</mml:mn>
</mml:mrow>
</mml:mtd>
</mml:mtr>
</mml:mtable>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:math>
<label>(8)</label>
</disp-formula>
</p>
<p>In Eq. <xref ref-type="disp-formula" rid="e8">8</xref>, the tangential vectors of point <inline-formula id="inf38">
<mml:math id="m46">
<mml:mrow>
<mml:msub>
<mml:mi>Q</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula> on the tool axis in direction <inline-formula id="inf39">
<mml:math id="m47">
<mml:mrow>
<mml:mi>o</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> and direction <inline-formula id="inf40">
<mml:math id="m48">
<mml:mrow>
<mml:mi>y</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> are <inline-formula id="inf41">
<mml:math id="m49">
<mml:mrow>
<mml:msub>
<mml:mi>r</mml:mi>
<mml:mi>o</mml:mi>
</mml:msub>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>o</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:mo>,</mml:mo>
<mml:msub>
<mml:mi>y</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula> and <inline-formula id="inf42">
<mml:math id="m50">
<mml:mrow>
<mml:msub>
<mml:mi>r</mml:mi>
<mml:mi>y</mml:mi>
</mml:msub>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>o</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:mo>,</mml:mo>
<mml:msub>
<mml:mi>y</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula>, respectively. The solving process of Eq. <xref ref-type="disp-formula" rid="e8">8</xref> is relatively complex, and this study uses numerical methods to solve it. The error measurement function is actually solving a function minimum problem, and under existing conditions, it is difficult to determine the explicit function expression. Traditional methods are difficult to solve, but intelligent algorithms have significant advantages in this regard. Intelligent algorithms only need to build mathematical models in MATLAB, search a fixed area, call error measurement functions multiple times for error discrimination, without the need for complex calculations, with short time consumption, large search range, and high accuracy. Therefore, the study proposes a strategy based on SA-PSO to transform the process of infinite approximation of the tool envelope surface to a non expandable ruled surface into a process of particle optimization using MATLAB. Firstly, generate the initial population in MATLAB, then use the SA-PSO hybrid algorithm to search for the range of the population, and finally calculate the envelope error to obtain the optimized tool axis trajectory surface.</p>
</sec>
<sec id="s3-2">
<title>3.2 SA-PSO fusion algorithm for solving lateral milling cutter axis trajectory planning model</title>
<p>Given the complexity of traditional solving methods for the trajectory planning model of side milling cutter axes, this study proposes to use the SA-PSO fusion algorithm to solve the model. The core of the SA algorithm is that there is no rule that the recently generated solution is better than the current solution. The SA algorithm originated from the solid-state annealing process. Solid annealing is the process of first heating a solid to a certain temperature, then slowly lowering the temperature of the solid to make the particle arrangement inside the solid more uniform, thereby changing the properties of the solid. The SA algorithm first sets an initial temperature, and as the temperature continues to decrease, it stays at each temperature and accepts new values. Combined with probability jumps, it continuously optimizes. The SA algorithm can cross the current optimal value to find the global optimal solution, requiring a large solution space, weak local search ability, and multiple iterations. This method can effectively solve the problem of difficulty in obtaining global optima due to the rapid convergence of population individuals, reflecting its advantage of easily getting rid of local minima. PSO is based on social information sharing and achieves rapid convergence by comparing the current individual&#x2019;s fitness with the historical optimal fitness, comparing the current fitness with the global optimal fitness. But it is prone to rapid convergence and stagnation in the later stage (<xref ref-type="bibr" rid="B14">Tao et al., 2022</xref>; <xref ref-type="bibr" rid="B2">Chinthamu and Karukuri, 2023</xref>; <xref ref-type="bibr" rid="B9">Kumar et al., 2023</xref>). In view of this, this study proposes an optimization method based on SA-PSO. This method first utilizes the global convergence of SA, and then combines the fast local search ability of PSO to determine the optimal position of the tool axis. <xref ref-type="fig" rid="F2">Figure 2</xref> is the flowchart of the SA-PSO algorithm.</p>
<fig id="F2" position="float">
<label>FIGURE 2</label>
<caption>
<p>Flowchart of SA-PSO fusion algorithm.</p>
</caption>
<graphic xlink:href="fmech-10-1361929-g002.tif"/>
</fig>
<p>The core of SA is the Monte Carlo criterion, and the current minimum value criterion can be represented by Eq. <xref ref-type="disp-formula" rid="e9">9</xref>.<disp-formula id="e9">
<mml:math id="m51">
<mml:mrow>
<mml:mi>M</mml:mi>
<mml:mo>&#x3d;</mml:mo>
<mml:mrow>
<mml:mfenced open="{" close="" separators="&#x7c;">
<mml:mrow>
<mml:mtable columnalign="left">
<mml:mtr>
<mml:mtd>
<mml:mrow>
<mml:mn>1</mml:mn>
<mml:mo>,</mml:mo>
<mml:msub>
<mml:mi>E</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mo>&#x2b;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:msub>
<mml:mo>&#x3c;</mml:mo>
<mml:msub>
<mml:mi>E</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mtd>
</mml:mtr>
<mml:mtr>
<mml:mtd>
<mml:mrow>
<mml:msup>
<mml:mi>e</mml:mi>
<mml:mfrac>
<mml:mrow>
<mml:mo>&#x2212;</mml:mo>
<mml:msub>
<mml:mi>E</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mo>&#x2b;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:msub>
<mml:mo>&#x2212;</mml:mo>
<mml:msub>
<mml:mi>E</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
<mml:mrow>
<mml:mi>h</mml:mi>
<mml:mi>T</mml:mi>
</mml:mrow>
</mml:mfrac>
</mml:msup>
<mml:mo>,</mml:mo>
<mml:msub>
<mml:mi>E</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mo>&#x2b;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:msub>
<mml:mo>&#x2265;</mml:mo>
<mml:msub>
<mml:mi>E</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mtd>
</mml:mtr>
</mml:mtable>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
<label>(9)</label>
</disp-formula>
</p>
<p>In Eq. <xref ref-type="disp-formula" rid="e9">9</xref>, the probability of accepting a new solution is <inline-formula id="inf43">
<mml:math id="m52">
<mml:mrow>
<mml:mi>M</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>. The current solution and iterative solution are <inline-formula id="inf44">
<mml:math id="m53">
<mml:mrow>
<mml:msub>
<mml:mi>E</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula> and <inline-formula id="inf45">
<mml:math id="m54">
<mml:mrow>
<mml:msub>
<mml:mi>E</mml:mi>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mo>&#x2b;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula>, respectively. The initial temperature is <inline-formula id="inf46">
<mml:math id="m55">
<mml:mrow>
<mml:mi>T</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>. The cooling coefficient is <inline-formula id="inf47">
<mml:math id="m56">
<mml:mrow>
<mml:mi>h</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>. According to the formula, when the new value is less than the current value, the new value must be accepted; When the new value is greater than the current value, there is a certain probability of acceptance; When the cooling coefficient and initial temperature remain constant, the more new values exceed the current value, the lower the probability of the new solution being accepted. The core of the SA algorithm is to not force the latest generated solution to be superior to the current solution. Due to the introduction of this concept, it avoids the problem of not being able to obtain the global optimal solution due to the fast convergence speed of population particles, demonstrating its superiority in easily jumping out of local extremum. The particle swarm optimization algorithm is based on social information sharing and compares its current fitness value with the best historical fitness value; Compare the current fitness value with the global best fitness value to achieve rapid convergence, but it is easy to encounter situations where the convergence speed is too fast in the later stage, leading to iteration stagnation. This study uses the SA-PSO fusion algorithm to first utilize the global convergence of the SA algorithm, and then use the fast local convergence speed of the PSO algorithm to find the optimal tool axis position. The process of SA-PSO algorithm is to first generate an initial solution <inline-formula id="inf48">
<mml:math id="m57">
<mml:mrow>
<mml:msub>
<mml:mi>x</mml:mi>
<mml:mn>0</mml:mn>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula>, and then set the initial temperature of the population particles, the termination temperature of the algorithm, the rate of temperature decrease, and the number of iterations <inline-formula id="inf49">
<mml:math id="m58">
<mml:mrow>
<mml:mi>L</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> of the isothermal process. The second step is to generate the difference between the current solution and the new solution, which can be represented by Eq. <xref ref-type="disp-formula" rid="e10">10</xref>.<disp-formula id="e10">
<mml:math id="m59">
<mml:mrow>
<mml:mo>&#x394;</mml:mo>
<mml:mi>E</mml:mi>
<mml:mo>&#x3d;</mml:mo>
<mml:mi>E</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>x</mml:mi>
<mml:mi>j</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>&#x2212;</mml:mo>
<mml:mi>E</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>x</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
<label>(10)</label>
</disp-formula>
</p>
<p>In Eq. <xref ref-type="disp-formula" rid="e10">10</xref>, the function values of the current solution and the new solution are represented by <inline-formula id="inf50">
<mml:math id="m60">
<mml:mrow>
<mml:mi>E</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>x</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula> and <inline-formula id="inf51">
<mml:math id="m61">
<mml:mrow>
<mml:mi>E</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>x</mml:mi>
<mml:mi>j</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula>, respectively. The third step is to determine whether the new solution can be accepted. If <inline-formula id="inf52">
<mml:math id="m62">
<mml:mrow>
<mml:mo>&#x394;</mml:mo>
<mml:mi>E</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> is lower than 0, it can be considered that the new solution is acceptable. Otherwise, the probability of the new solution being accepted is Eq. <xref ref-type="disp-formula" rid="e11">11</xref>.<disp-formula id="e11">
<mml:math id="m63">
<mml:mrow>
<mml:mi>z</mml:mi>
<mml:mo>&#x3d;</mml:mo>
<mml:msup>
<mml:mi>e</mml:mi>
<mml:mfrac>
<mml:mrow>
<mml:mo>&#x2212;</mml:mo>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>E</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>x</mml:mi>
<mml:mi>j</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>&#x2212;</mml:mo>
<mml:mi>E</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>x</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
<mml:msub>
<mml:mi>T</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mfrac>
</mml:msup>
</mml:mrow>
</mml:math>
<label>(11)</label>
</disp-formula>
</p>
<p>In Eq. <xref ref-type="disp-formula" rid="e11">11</xref>, <inline-formula id="inf53">
<mml:math id="m64">
<mml:mrow>
<mml:mi>z</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> represents probability, <inline-formula id="inf54">
<mml:math id="m65">
<mml:mrow>
<mml:msub>
<mml:mi>T</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula> refers to the current temperature. The fourth step is to reach the termination condition of the algorithm, as shown in Eq. <xref ref-type="disp-formula" rid="e12">12</xref>.<disp-formula id="e12">
<mml:math id="m66">
<mml:mrow>
<mml:mi>f</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>t</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>&#x3d;</mml:mo>
<mml:msup>
<mml:mrow>
<mml:mstyle displaystyle="true">
<mml:munderover>
<mml:mo>&#x2211;</mml:mo>
<mml:mrow>
<mml:mi>i</mml:mi>
<mml:mo>&#x3d;</mml:mo>
<mml:mn>1</mml:mn>
</mml:mrow>
<mml:mi>n</mml:mi>
</mml:munderover>
</mml:mstyle>
<mml:mrow>
<mml:mfenced open="[" close="]" separators="&#x7c;">
<mml:mrow>
<mml:mrow>
<mml:mfenced open="|" close="|" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>Q</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
<mml:msub>
<mml:mi>P</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
<mml:mo>&#x2212;</mml:mo>
<mml:msub>
<mml:mi>r</mml:mi>
<mml:mi>c</mml:mi>
</mml:msub>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:msub>
<mml:mi>Q</mml:mi>
<mml:mi>i</mml:mi>
</mml:msub>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
<mml:mn>2</mml:mn>
</mml:msup>
<mml:mo>&#x3c;</mml:mo>
<mml:mi>&#x3b5;</mml:mi>
</mml:mrow>
</mml:math>
<label>(12)</label>
</disp-formula>
</p>
<p>In Eq. <xref ref-type="disp-formula" rid="e12">12</xref>, <inline-formula id="inf55">
<mml:math id="m67">
<mml:mrow>
<mml:mi>&#x3b5;</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> refers to a sufficiently small positive number. The fifth is to assign a particle swarm. The sixth step is to calculate the fitness value of each particle. The seventh is to update the sub location status. The eighth step is to terminate the calculation when the maximum number of iterations is reached.</p>
<p>The population size of SA is 100, with a minimum and maximum temperature of 0.01 and 1,000, respectively, and a cooling rate of 0.9. The temperature decreases 10 times per iteration, and the constraint is to generate a sphere with a radius of 2&#xa0;mm. Random perturbations are independent variables, i.e., particle positions. The center is the coordinate of the center of the ball on both sides of the tool axis. In the PSO algorithm, the particle motion speed is 1, the learning factor is all 1.5, and the maximum number of iterations is 100. During the machining stage, different positions on the tool axis constantly change at the vertical points of the design surface, and the normal vector is also constantly adjusted accordingly. The TES formed by processing is <inline-formula id="inf56">
<mml:math id="m68">
<mml:mrow>
<mml:mi>S</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>, the design surface is <inline-formula id="inf57">
<mml:math id="m69">
<mml:mrow>
<mml:mi>S</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>u</mml:mi>
<mml:mo>,</mml:mo>
<mml:mi>v</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula>, and the inner and outer equidistant surfaces of the design surface are <inline-formula id="inf58">
<mml:math id="m70">
<mml:mrow>
<mml:msub>
<mml:mi>S</mml:mi>
<mml:mn>1</mml:mn>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula> and <inline-formula id="inf59">
<mml:math id="m71">
<mml:mrow>
<mml:msub>
<mml:mi>S</mml:mi>
<mml:mn>2</mml:mn>
</mml:msub>
</mml:mrow>
</mml:math>
</inline-formula>. The scope of their inclusive domain is <inline-formula id="inf60">
<mml:math id="m72">
<mml:mrow>
<mml:msub>
<mml:mi>S</mml:mi>
<mml:mn>1</mml:mn>
</mml:msub>
<mml:mi>S</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>u</mml:mi>
<mml:mo>,</mml:mo>
<mml:mi>v</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula> and <inline-formula id="inf61">
<mml:math id="m73">
<mml:mrow>
<mml:msub>
<mml:mi>S</mml:mi>
<mml:mn>2</mml:mn>
</mml:msub>
<mml:mi>S</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>u</mml:mi>
<mml:mo>,</mml:mo>
<mml:mi>v</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula>. The over cutting error and under cutting error are <inline-formula id="inf62">
<mml:math id="m74">
<mml:mrow>
<mml:msub>
<mml:mi>S</mml:mi>
<mml:mn>1</mml:mn>
</mml:msub>
<mml:mi>S</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>u</mml:mi>
<mml:mo>,</mml:mo>
<mml:mi>v</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula> and <inline-formula id="inf63">
<mml:math id="m75">
<mml:mrow>
<mml:msub>
<mml:mi>S</mml:mi>
<mml:mn>2</mml:mn>
</mml:msub>
<mml:mi>S</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>u</mml:mi>
<mml:mo>,</mml:mo>
<mml:mi>v</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula>, respectively, and the overall optimization goal is to ensure the minimum range of the inclusion domain. <xref ref-type="fig" rid="F3">Figure 3A</xref> is the envelope error diagram of cylindrical cutter side milling. <xref ref-type="fig" rid="F3">Figure 3B</xref> is the calculation of side milling machining errors.</p>
<fig id="F3" position="float">
<label>FIGURE 3</label>
<caption>
<p>Error diagram of cylindrical cutter side milling envelope and calculation of side milling machining error. <bold>(A)</bold>: Error diagram of cylindrical cutter side milling envelope; <bold>(B)</bold>: Calculation of side milling machining error.</p>
</caption>
<graphic xlink:href="fmech-10-1361929-g003.tif"/>
</fig>
<p>The tool sidewall and design curve <inline-formula id="inf64">
<mml:math id="m76">
<mml:mrow>
<mml:mi>S</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>u</mml:mi>
<mml:mo>,</mml:mo>
<mml:mi>v</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula> pass through the perpendicular of the tool axis point <inline-formula id="inf65">
<mml:math id="m77">
<mml:mrow>
<mml:msup>
<mml:mi>A</mml:mi>
<mml:mo>&#x2032;</mml:mo>
</mml:msup>
</mml:mrow>
</mml:math>
</inline-formula> to obtain points <inline-formula id="inf66">
<mml:math id="m78">
<mml:mrow>
<mml:mi>A</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> and <inline-formula id="inf67">
<mml:math id="m79">
<mml:mrow>
<mml:mi>B</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>, which are extended to intersect with point <inline-formula id="inf68">
<mml:math id="m80">
<mml:mrow>
<mml:mi>C</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula> on the tool sidewall. The machining error is <inline-formula id="inf69">
<mml:math id="m81">
<mml:mrow>
<mml:mi>B</mml:mi>
<mml:mi>C</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>. When <inline-formula id="inf70">
<mml:math id="m82">
<mml:mrow>
<mml:mi>A</mml:mi>
<mml:mo>&#x2032;</mml:mo>
<mml:mi>C</mml:mi>
<mml:mo>&#x3e;</mml:mo>
<mml:mi>A</mml:mi>
<mml:mo>&#x2032;</mml:mo>
<mml:mi>B</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>, the design surface and the tool are excessively cut, and if <inline-formula id="inf71">
<mml:math id="m83">
<mml:mrow>
<mml:mi>A</mml:mi>
<mml:mo>&#x2032;</mml:mo>
<mml:mi>C</mml:mi>
<mml:mo>&#x3c;</mml:mo>
<mml:mi>A</mml:mi>
<mml:mo>&#x2032;</mml:mo>
<mml:mi>B</mml:mi>
</mml:mrow>
</mml:math>
</inline-formula>, the cutting between the two is too little. The error equation for the cutting position is Eq. <xref ref-type="disp-formula" rid="e13">13</xref>.<disp-formula id="e13">
<mml:math id="m84">
<mml:mrow>
<mml:mi>E</mml:mi>
<mml:mi>r</mml:mi>
<mml:mi>r</mml:mi>
<mml:mi>o</mml:mi>
<mml:mi>r</mml:mi>
<mml:mo>&#x3d;</mml:mo>
<mml:mi>A</mml:mi>
<mml:mo>&#x2032;</mml:mo>
<mml:mi>C</mml:mi>
<mml:mo>&#x2212;</mml:mo>
<mml:mi>A</mml:mi>
<mml:mo>&#x2032;</mml:mo>
<mml:mi>B</mml:mi>
</mml:mrow>
</mml:math>
<label>(13)</label>
</disp-formula>
</p>
<p>The calculation of envelope error is carried out by making a perpendicular point towards the design surface <inline-formula id="inf72">
<mml:math id="m85">
<mml:mrow>
<mml:mi>S</mml:mi>
<mml:mrow>
<mml:mfenced open="(" close=")" separators="&#x7c;">
<mml:mrow>
<mml:mi>u</mml:mi>
<mml:mo>,</mml:mo>
<mml:mi>v</mml:mi>
</mml:mrow>
</mml:mfenced>
</mml:mrow>
</mml:mrow>
</mml:math>
</inline-formula> at a given discrete point on the cutter axis, and using MATLAB software for numerical calculation to determine the coordinate position of the perpendicular point. The coordinate position of the point is extended to calculate the magnitude of the envelope error and determine whether it is over tangent or under tangent.</p>
</sec>
</sec>
<sec id="s4">
<title>4 Application effect of integrated impeller CNC machining technology</title>
<p>The original data of the blades in this study was obtained from a certain enterprise&#x2019;s integral impeller. A single blade was divided into 10 blade surfaces, and the third blade surface was selected as an example. The parameters include the wires and busbars of the curved surface. Select 8 tool positions uniformly on the second curved surface, and select eight points uniformly on the axis in the direction of the generatrix as the judgment positions for error measurement. Simulate using a column cutter with a diameter of 6&#xa0;mm. <xref ref-type="fig" rid="F4">Figures 4A,B</xref> show the control points for the top and bottom wires in NURBS, respectively.</p>
<fig id="F4" position="float">
<label>FIGURE 4</label>
<caption>
<p>Control points of top and bottom traverse in NURBS. <bold>(A)</bold>: Top wire; <bold>(B)</bold>: Bottom wire.</p>
</caption>
<graphic xlink:href="fmech-10-1361929-g004.tif"/>
</fig>
<p>
<xref ref-type="fig" rid="F5">Figures 5A,B</xref> show the training curves for single blade position SA and SA-PSO, respectively. In <xref ref-type="fig" rid="F5">Figure 5A</xref>, it can be seen that under the control of the PSO algorithm, after 25 rounds of training for a single tool position, it repeatedly falls into the local optimal solution, with stable error values of 1.210, 1.302, and 1.345, respectively. <xref ref-type="fig" rid="F5">Figure 5B</xref> shows that after adjusting the error using the SA-PSO algorithm, a single tool position avoids the phenomenon of getting stuck in local optimal solutions multiple times. The final value range is &#x2212;0.416 to 0.421. In the subsequent training process, it is necessary to increase the maximum step distance of a single step and reduce the cutting amount of the tool under some training times. The result of a single tool path has certain significance for the final ITB CNC machining technology, as it can directly determine the machining quality of ITB and the operating efficiency of the tool.</p>
<fig id="F5" position="float">
<label>FIGURE 5</label>
<caption>
<p>Trapping into local optimum and avoiding local optimum are two training curves. <bold>(A)</bold>: PSO; <bold>(B)</bold>: SA-PSO.</p>
</caption>
<graphic xlink:href="fmech-10-1361929-g005.tif"/>
</fig>
<p>
<xref ref-type="fig" rid="F6">Figures 6A,B</xref> show the optimization results and optimization time of PSO and SA-PSO algorithms at different iteration times, respectively. As the number of iterations increases, the error values of both PSO and SA-PSO algorithms gradually decrease, with convergence times of approximately 7 and 6, respectively. The stable error value of SA-PSO algorithm is 0.253, which is 30.45% lower than PSO algorithm. For optimization time, the stable values of PSO and SA-PSO algorithms are 3.2 and 3.3 s, respectively. This indicates that although the iteration process of SA-PSO algorithm is not as fast as that of a single PSO algorithm, it is still within a reasonable numerical range and the numerical difference is not significant. Therefore, due to the significant advantage of the SA-PSO algorithm proposed by the research institute in terms of error value and the smaller difference in running time compared to the PSO algorithm, the overall performance is better.</p>
<fig id="F6" position="float">
<label>FIGURE 6</label>
<caption>
<p>Optimization results and optimization time of PSO and SA-PSO under different iterations. <bold>(A)</bold>: PSO; <bold>(B)</bold>: SA-PSO.</p>
</caption>
<graphic xlink:href="fmech-10-1361929-g006.tif"/>
</fig>
<p>
<xref ref-type="fig" rid="F7">Figure 7</xref> shows the envelope error diagram of the tool at its initial position When the tool is in its initial position, the range of envelope error is &#x2212;0.5 to 0&#xa0;mm. This indicates that there is a situation of over cutting between the design surface and the tool. Therefore, the design surface needs to be adjusted through numerical algorithms to match the actual motion trajectory.</p>
<fig id="F7" position="float">
<label>FIGURE 7</label>
<caption>
<p>Envelope error diagram of tool in initial position.</p>
</caption>
<graphic xlink:href="fmech-10-1361929-g007.tif"/>
</fig>
<p>
<xref ref-type="fig" rid="F8">Figure 8</xref> shows the impact of different algorithms on the calculation results of envelope errors. <xref ref-type="fig" rid="F8">Figures 8A,B</xref> show the single tool position envelope error diagrams for PSO and SA-PSO algorithms, respectively. In <xref ref-type="fig" rid="F8">Figure 8A</xref>, the range of envelope error values is &#x2212;0.018 to 0.018&#xa0;mm. The results of the single tool position envelope error graphs for both SA-PSO algorithms show that the range of envelope error values is &#x2212;0.01 to 0.01&#xa0;mm. Therefore, after optimizing the trajectory model of the side milling cutter axis using two algorithms, the relationship between the design surface and the tool is still distributed between the over cut and undercut states. However, the SA-PSO fusion algorithm has significantly reduced the envelope error after optimization.</p>
<fig id="F8" position="float">
<label>FIGURE 8</label>
<caption>
<p>Influence of different algorithms on the calculation results of envelope error. <bold>(A)</bold>: PSO; <bold>(B)</bold>: SA-PSO.</p>
</caption>
<graphic xlink:href="fmech-10-1361929-g008.tif"/>
</fig>
<p>
<xref ref-type="table" rid="T2">Table 2</xref> shows the envelope error of the single tool path for PSO and SA-PSO algorithms. When the calculation reaches the 7th iteration, both optimization algorithms have reached the optimal solution. The range values of PSO and SA-PSO algorithms are 0.0213 and 0.0165 mm, respectively. The range mean of the SA-PSO fusion algorithm is reduced by about 15% compared to a single optimization algorithm.</p>
<table-wrap id="T2" position="float">
<label>TABLE 2</label>
<caption>
<p>Envelope error of single tool position of PSO and SA-PSO algorithms.</p>
</caption>
<table>
<thead valign="top">
<tr>
<th rowspan="2" align="center">Frequency</th>
<th colspan="3" align="center">PSO</th>
<th colspan="3" align="center">SA-PSO</th>
</tr>
<tr>
<th align="center">Overcut</th>
<th align="center">Undercut</th>
<th align="center">Extreme difference</th>
<th align="center">Overcut</th>
<th align="center">Undercut</th>
<th align="center">Extreme difference</th>
</tr>
</thead>
<tbody valign="top">
<tr>
<td align="center">1</td>
<td align="center">0.0128</td>
<td align="center">0.0117</td>
<td align="center">0.0245</td>
<td align="center">0.0091</td>
<td align="center">0.0084</td>
<td align="center">0.0175</td>
</tr>
<tr>
<td align="center">2</td>
<td align="center">0.0119</td>
<td align="center">0.0123</td>
<td align="center">0.0242</td>
<td align="center">0.01</td>
<td align="center">0.0088</td>
<td align="center">0.0188</td>
</tr>
<tr>
<td align="center">3</td>
<td align="center">0.0108</td>
<td align="center">0.0135</td>
<td align="center">0.0243</td>
<td align="center">0.0081</td>
<td align="center">0.0095</td>
<td align="center">0.0176</td>
</tr>
<tr>
<td align="center">4</td>
<td align="center">0.0117</td>
<td align="center">0.0116</td>
<td align="center">0.0233</td>
<td align="center">0.0085</td>
<td align="center">0.0084</td>
<td align="center">0.0169</td>
</tr>
<tr>
<td align="center">5</td>
<td align="center">0.0128</td>
<td align="center">0.0118</td>
<td align="center">0.0246</td>
<td align="center">0.0091</td>
<td align="center">0.0082</td>
<td align="center">0.0173</td>
</tr>
<tr>
<td align="center">6</td>
<td align="center">0.0125</td>
<td align="center">0.0118</td>
<td align="center">0.0243</td>
<td align="center">0.0088</td>
<td align="center">0.0091</td>
<td align="center">0.0179</td>
</tr>
<tr>
<td align="center">7</td>
<td align="center">0.0105</td>
<td align="center">0.0108</td>
<td align="center">0.0213</td>
<td align="center">0.0083</td>
<td align="center">0.0082</td>
<td align="center">0.0165</td>
</tr>
<tr>
<td align="center">8</td>
<td align="center">0.0126</td>
<td align="center">0.0108</td>
<td align="center">0.0234</td>
<td align="center">0.0087</td>
<td align="center">0.0083</td>
<td align="center">0.017</td>
</tr>
<tr>
<td align="center">9</td>
<td align="center">0.0125</td>
<td align="center">0.0105</td>
<td align="center">0.023</td>
<td align="center">0.0098</td>
<td align="center">0.0087</td>
<td align="center">0.0185</td>
</tr>
<tr>
<td align="center">10</td>
<td align="center">0.0155</td>
<td align="center">0.0111</td>
<td align="center">0.0266</td>
<td align="center">0.0085</td>
<td align="center">0.01</td>
<td align="center">0.0185</td>
</tr>
</tbody>
</table>
</table-wrap>
<p>
<xref ref-type="fig" rid="F9">Figures 9A,B</xref> show the top and bottom positions of the initial and SA-PSO optimized tool axis trajectory surfaces, respectively. The tool axis trajectory surface optimized by SA-PSO is closer to the actual trajectory, and the processed blades better meet the quality requirements of ITB. The initial and optimized tool axis trajectory surfaces exhibit significant errors in the <italic>Y</italic>-axis direction, which may be caused by CNC-MT. After optimizing the PSO algorithm through the SA algorithm, this method can effectively solve the problem of difficulty in obtaining global optima due to the rapid convergence of population individuals, and is easy to overcome the advantage of local minima.</p>
<fig id="F9" position="float">
<label>FIGURE 9</label>
<caption>
<p>Initial tool axis trajectory surface and SA-PSO optimized tool axis trajectory surface. <bold>(A)</bold>: Initial tool axis trajectory surface and SA-PSO optimized tool axis trajectory surface; <bold>(B)</bold>: Bottom wire-Initial tool axis trajectory surface.</p>
</caption>
<graphic xlink:href="fmech-10-1361929-g009.tif"/>
</fig>
<p>
<xref ref-type="fig" rid="F10">Figures 10A,B</xref> show the training results of using wire overlap as the target in both single and global cutting scenarios, respectively. Overall, after each training period, the sum of the normal and position mean squared deviations of the target model and the initial blank shows a large fluctuation range. The range of the sum of mean squared deviations for single and global cutting is 0.0011&#x2013;0.0198 and 0.046&#x2013;0.0341, but the overall error value is relatively small. This indicates that only some position target models match the normal direction, but the solution algorithm of the designed side milling cutter axis trajectory planning model can achieve good iterative operation results.</p>
<fig id="F10" position="float">
<label>FIGURE 10</label>
<caption>
<p>Target training results for single and global cutting scenarios. <bold>(A)</bold>: Single cutting; <bold>(B)</bold>: Global cutting.</p>
</caption>
<graphic xlink:href="fmech-10-1361929-g010.tif"/>
</fig>
<p>To further validate the application effect of SA-PSO algorithm in lateral milling cutter axis trajectory planning, this study compared it with other similar studies, including references (<xref ref-type="bibr" rid="B12">Lu et al., 2022</xref>; <xref ref-type="bibr" rid="B21">Zhao et al., 2023</xref>; <xref ref-type="bibr" rid="B23">Zou et al., 2022</xref>). A comparison of the trajectory planning effects of the integral impeller side milling cutter shaft was conducted on a five axis machine tool model HS5AXIS 350, with indicators including average error and over cutting rate. The results are shown in <xref ref-type="table" rid="T3">Table 3</xref>. It can be clearly seen from <xref ref-type="table" rid="T3">Table 3</xref> that the over cutting rate and machining error of the SA-PSO algorithm are 46.32% and 0.142 mm, respectively, and the required time is only 4.512 s. Compared with other studies, the SA-PSO algorithm has better efficiency and effectiveness in planning the axis trajectory of side milling cutters.</p>
<table-wrap id="T3" position="float">
<label>TABLE 3</label>
<caption>
<p>Comparison results of lateral milling cutter axis trajectory planning.</p>
</caption>
<table>
<thead valign="top">
<tr>
<th align="center">Method</th>
<th align="center">Average error/mm</th>
<th align="center">Overshoot rate/%</th>
<th align="center">Time/s</th>
</tr>
</thead>
<tbody valign="top">
<tr>
<td align="center">
<xref ref-type="bibr" rid="B12">Lu et al. (2022)</xref>
</td>
<td align="center">0.0177</td>
<td align="center">52.43</td>
<td align="center">7.516</td>
</tr>
<tr>
<td align="center">
<xref ref-type="bibr" rid="B21">Zhao et al. (2023)</xref>
</td>
<td align="center">0.0229</td>
<td align="center">60.25</td>
<td align="center">7.118</td>
</tr>
<tr>
<td align="center">
<xref ref-type="bibr" rid="B23">Zou et al. (2022)</xref>
</td>
<td align="center">0.0258</td>
<td align="center">64.97</td>
<td align="center">5.956</td>
</tr>
<tr>
<td align="center">SA-PSO</td>
<td align="center">0.0142</td>
<td align="center">46.32</td>
<td align="center">4.512</td>
</tr>
</tbody>
</table>
</table-wrap>
</sec>
<sec sec-type="conclusion" id="s5">
<title>5 Conclusion</title>
<p>The problem of deviation design between the design surface and TES when planning a single tool position. To solve the mathematical model through reasonable numerical methods to reduce computational complexity and improve operational efficiency, this study proposed to use the SA-PSO optimization algorithm to solve the trajectory planning model of the side milling cutter axis. After 25 rounds of training with a single blade position, it repeatedly fell into the local optimal solution, with stable error values of 1.210, 1.302, and 1.345, respectively. After adjusting the error through the SA algorithm, a single tool position avoided the phenomenon of getting stuck in local optimal solutions multiple times. The final value range was &#x2212;0.416 to 0.421. For optimization time, the stable values of PSO and SA-PSO algorithms were 3.2 and 3.3 s, respectively. When the tool was in its initial position, the range of envelope error was &#x2212;0.5 to 0 mm, and there was a situation of over cutting between the design surface and the tool. The range of single tool position envelope errors for PSO and SA-PSO algorithms was &#x2212;0.018 to 0.018&#xa0;mm and &#x2212;0.01 to 0.01 mm, respectively. When the calculation reached the 7th iteration, both PSO and SA-PSO optimization algorithms had reached the optimal solution, with range values of 0.0213 and 0.0165 mm, respectively. The range mean of the SA-PSO fusion algorithm was reduced by about 15% compared to a single optimization algorithm. The tool axis trajectory surface optimized by SA-PSO was closer to the actual trajectory, and the processed blades better met the quality requirements of ITB. The target model at some positions matched the normal direction, but the solution algorithm of the designed lateral milling cutter axis trajectory planning model could achieve good operational results and find the optimal path with the minimum error in a fixed area. This study has shown good results in the field of principle error resolution, but there are still shortcomings. In the subsequent ITB CNC operation process, it is necessary to consider the impact of machine tool driven tool vibration and impeller defects on the actual effect.</p>
</sec>
</body>
<back>
<sec sec-type="data-availability" id="s6">
<title>Data availability statement</title>
<p>The original contributions presented in the study are included in the article/supplementary material, further inquiries can be directed to the corresponding author.</p>
</sec>
<sec id="s7">
<title>Author contributions</title>
<p>YZ: Conceptualization, Data curation, Formal Analysis, Investigation, Methodology, Resources, Writing&#x2013;original draft, Writing&#x2013;review and editing.</p>
</sec>
<sec sec-type="funding-information" id="s8">
<title>Funding</title>
<p>The author(s) declare that no financial support was received for the research, authorship, and/or publication of this article.</p>
</sec>
<sec sec-type="COI-statement" id="s9">
<title>Conflict of interest</title>
<p>The author declares that the research was conducted in the absence of any commercial or financial relationships that could be construed as a potential conflict of interest.</p>
</sec>
<sec sec-type="disclaimer" id="s10">
<title>Publisher&#x2019;s note</title>
<p>All claims expressed in this article are solely those of the authors and do not necessarily represent those of their affiliated organizations, or those of the publisher, the editors and the reviewers. Any product that may be evaluated in this article, or claim that may be made by its manufacturer, is not guaranteed or endorsed by the publisher.</p>
</sec>
<ref-list>
<title>References</title>
<ref id="B1">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Cheng</surname>
<given-names>D. J.</given-names>
</name>
<name>
<surname>Zhang</surname>
<given-names>J.</given-names>
</name>
<name>
<surname>Hu</surname>
<given-names>Z. T.</given-names>
</name>
<name>
<surname>Xu</surname>
<given-names>S. H.</given-names>
</name>
<name>
<surname>Fang</surname>
<given-names>X. F.</given-names>
</name>
</person-group> (<year>2020</year>). <article-title>A digital twin-driven approach for on-line controlling quality of marine diesel engine critical parts</article-title>. <source>Int. J. Precis. Eng. Manuf.</source> <volume>21</volume> (<issue>1</issue>), <fpage>1821</fpage>&#x2013;<lpage>1841</lpage>. <pub-id pub-id-type="doi">10.1007/s12541-020-00403-y</pub-id>
</citation>
</ref>
<ref id="B2">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Chinthamu</surname>
<given-names>N.</given-names>
</name>
<name>
<surname>Karukuri</surname>
<given-names>M.</given-names>
</name>
</person-group> (<year>2023</year>). <article-title>Data science and applications</article-title>. <source>J. Data Sci. Intelligent Syst.</source> <volume>1</volume> (<issue>1</issue>), <fpage>83</fpage>&#x2013;<lpage>91</lpage>. <pub-id pub-id-type="doi">10.47852/bonviewjdsis3202837</pub-id>
</citation>
</ref>
<ref id="B3">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Fan</surname>
<given-names>H. Z.</given-names>
</name>
<name>
<surname>Cao</surname>
<given-names>Y. L.</given-names>
</name>
<name>
<surname>Xi</surname>
<given-names>G.</given-names>
</name>
</person-group> (<year>2020</year>). <article-title>Judging of machining feasibility and calculation of midsection for the five-axis milling of shrouded centrifugal impeller</article-title>. <source>J. Industrial Prod. Eng.</source> <volume>37</volume> (<issue>7</issue>), <fpage>360</fpage>&#x2013;<lpage>369</lpage>. <pub-id pub-id-type="doi">10.1080/21681015.2020.1802620</pub-id>
</citation>
</ref>
<ref id="B4">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Feng</surname>
<given-names>J.</given-names>
</name>
<name>
<surname>Wei</surname>
<given-names>Z.</given-names>
</name>
<name>
<surname>Wang</surname>
<given-names>M.</given-names>
</name>
<name>
<surname>Wang</surname>
<given-names>X.</given-names>
</name>
<name>
<surname>Guo</surname>
<given-names>M.</given-names>
</name>
</person-group> (<year>2021</year>). <article-title>Tool path planning for five-axis U-pass milling of an impeller</article-title>. <source>Int. J. Adv. Manuf. Technol.</source> <volume>117</volume> (<issue>11-12</issue>), <fpage>3379</fpage>&#x2013;<lpage>3391</lpage>. <pub-id pub-id-type="doi">10.1007/s00170-021-07947-x</pub-id>
</citation>
</ref>
<ref id="B5">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Franciosa</surname>
<given-names>P.</given-names>
</name>
<name>
<surname>Sokolov</surname>
<given-names>M.</given-names>
</name>
<name>
<surname>Sinha</surname>
<given-names>S.</given-names>
</name>
<name>
<surname>Sun</surname>
<given-names>T.</given-names>
</name>
<name>
<surname>Ceglarek</surname>
<given-names>D.</given-names>
</name>
</person-group> (<year>2020</year>). <article-title>Deep learning enhanced digital twin for Closed-Loop In-Process quality improvement</article-title>. <source>CIRP Ann.</source> <volume>69</volume> (<issue>1</issue>), <fpage>369</fpage>&#x2013;<lpage>372</lpage>. <pub-id pub-id-type="doi">10.1016/j.cirp.2020.04.110</pub-id>
</citation>
</ref>
<ref id="B6">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Guo</surname>
<given-names>C.</given-names>
</name>
<name>
<surname>Chen</surname>
<given-names>X.</given-names>
</name>
<name>
<surname>Li</surname>
<given-names>Q.</given-names>
</name>
<name>
<surname>Ding</surname>
<given-names>G.</given-names>
</name>
<name>
<surname>Yue</surname>
<given-names>H.</given-names>
</name>
<name>
<surname>Zhang</surname>
<given-names>J.</given-names>
</name>
</person-group> (<year>2022</year>). <article-title>Milling optimization of GH4169 nickel&#x2013;based superalloy under minimal quantity lubrication condition based on multi-objective particle swarm optimization algorithm</article-title>. <source>Int. J. Adv. Manuf. Technol.</source> <volume>123</volume> (<issue>11-12</issue>), <fpage>3983</fpage>&#x2013;<lpage>3994</lpage>. <pub-id pub-id-type="doi">10.1007/s00170-022-10461-3</pub-id>
</citation>
</ref>
<ref id="B7">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Guo</surname>
<given-names>M.</given-names>
</name>
<name>
<surname>Fang</surname>
<given-names>X.</given-names>
</name>
<name>
<surname>Hu</surname>
<given-names>Z.</given-names>
</name>
<name>
<surname>Li</surname>
<given-names>Q.</given-names>
</name>
</person-group> (<year>2023</year>). <article-title>Design and research of digital twin machine tool simulation and monitoring system</article-title>. <source>Int. J. Adv. Manuf. Technol.</source> <volume>124</volume> (<issue>11-12</issue>), <fpage>4253</fpage>&#x2013;<lpage>4268</lpage>. <pub-id pub-id-type="doi">10.1007/s00170-022-09613-2</pub-id>
</citation>
</ref>
<ref id="B8">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Kiswanto</surname>
<given-names>G.</given-names>
</name>
</person-group> (<year>2020</year>). <article-title>Digital twin approach for tool wear monitoring of micro-milling</article-title>. <source>Procedia CIRP</source> <volume>93</volume>, <fpage>1532</fpage>&#x2013;<lpage>1537</lpage>. <pub-id pub-id-type="doi">10.1016/j.procir.2020.03.140</pub-id>
</citation>
</ref>
<ref id="B9">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Kumar</surname>
<given-names>V. T. R. P.</given-names>
</name>
<name>
<surname>Arulselvi</surname>
<given-names>M.</given-names>
</name>
<name>
<surname>Sastry</surname>
<given-names>K. B. S.</given-names>
</name>
</person-group> (<year>2023</year>). <article-title>Comparative assessment of colon cancer classification using diverse deep learning approaches</article-title>. <source>J. Data Sci. Intelligent Syst.</source> <volume>1</volume> (<issue>2</issue>), <fpage>128</fpage>&#x2013;<lpage>135</lpage>. <pub-id pub-id-type="doi">10.47852/bonviewjdsis32021193</pub-id>
</citation>
</ref>
<ref id="B10">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Ladj</surname>
<given-names>A.</given-names>
</name>
<name>
<surname>Wang</surname>
<given-names>Z.</given-names>
</name>
<name>
<surname>Meski</surname>
<given-names>O.</given-names>
</name>
<name>
<surname>Belkadi</surname>
<given-names>F.</given-names>
</name>
<name>
<surname>Ritou</surname>
<given-names>M.</given-names>
</name>
<name>
<surname>Da Cunha</surname>
<given-names>C.</given-names>
</name>
</person-group> (<year>2021</year>). <article-title>A knowledge-based Digital Shadow for machining industry in a Digital Twin perspective</article-title>. <source>J. Manuf. Syst.</source> <volume>58</volume> (<issue>1</issue>), <fpage>168</fpage>&#x2013;<lpage>179</lpage>. <pub-id pub-id-type="doi">10.1016/j.jmsy.2020.07.018</pub-id>
</citation>
</ref>
<ref id="B11">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Liu</surname>
<given-names>S.</given-names>
</name>
<name>
<surname>Lu</surname>
<given-names>S.</given-names>
</name>
<name>
<surname>Li</surname>
<given-names>J.</given-names>
</name>
<name>
<surname>Sun</surname>
<given-names>X.</given-names>
</name>
<name>
<surname>Lu</surname>
<given-names>Y.</given-names>
</name>
<name>
<surname>Bao</surname>
<given-names>J.</given-names>
</name>
</person-group> (<year>2021</year>). <article-title>Machining process-oriented monitoring method based on digital twin via augmented reality</article-title>. <source>Int. J. Adv. Manuf. Technol.</source> <volume>113</volume> (<issue>1</issue>), <fpage>3491</fpage>&#x2013;<lpage>3508</lpage>. <pub-id pub-id-type="doi">10.1007/s00170-021-06838-5</pub-id>
</citation>
</ref>
<ref id="B12">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Lu</surname>
<given-names>Z.</given-names>
</name>
<name>
<surname>Yang</surname>
<given-names>X.</given-names>
</name>
<name>
<surname>Zhao</surname>
<given-names>J.</given-names>
</name>
</person-group> (<year>2022</year>). <article-title>Tool-path planning method for kinematics optimization of blade machining on five-axis machine tool</article-title>. <source>Int. J. Adv. Manuf. Technol.</source> <volume>121</volume> (<issue>1</issue>), <fpage>1253</fpage>&#x2013;<lpage>1267</lpage>. <pub-id pub-id-type="doi">10.1007/s00170-022-09271-4</pub-id>
</citation>
</ref>
<ref id="B13">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Serin</surname>
<given-names>G.</given-names>
</name>
<name>
<surname>Ozbayoglu</surname>
<given-names>M.</given-names>
</name>
<name>
<surname>Unver</surname>
<given-names>H. O.</given-names>
</name>
</person-group> (<year>2020</year>). <article-title>Integrated energy-efficient machining of rotary impellers and multi-objective optimization</article-title>. <source>Mater. Manuf. Process.</source> <volume>35</volume> (<issue>4</issue>), <fpage>478</fpage>&#x2013;<lpage>490</lpage>. <pub-id pub-id-type="doi">10.1080/10426914.2019.1605177</pub-id>
</citation>
</ref>
<ref id="B14">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Tao</surname>
<given-names>F.</given-names>
</name>
<name>
<surname>Xiao</surname>
<given-names>B.</given-names>
</name>
<name>
<surname>Qi</surname>
<given-names>Q.</given-names>
</name>
<name>
<surname>Cheng</surname>
<given-names>J.</given-names>
</name>
<name>
<surname>Ji</surname>
<given-names>P.</given-names>
</name>
</person-group> (<year>2022</year>). <article-title>Digital twin modeling</article-title>. <source>J. Manuf. Syst.</source> <volume>64</volume>, <fpage>372</fpage>&#x2013;<lpage>389</lpage>. <pub-id pub-id-type="doi">10.1016/j.jmsy.2022.06.015</pub-id>
</citation>
</ref>
<ref id="B15">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>T&#xfc;chler</surname>
<given-names>S.</given-names>
</name>
<name>
<surname>Copeland</surname>
<given-names>C. D.</given-names>
</name>
</person-group> (<year>2021</year>). <article-title>Numerical optimisation of a micro-wave rotor turbine using a quasi-two-dimensional CFD model and a hybrid algorithm</article-title>. <source>Shock Waves</source> <volume>31</volume>, <fpage>271</fpage>&#x2013;<lpage>300</lpage>. <pub-id pub-id-type="doi">10.1007/s00193-020-00979-4</pub-id>
</citation>
</ref>
<ref id="B16">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Weckx</surname>
<given-names>S.</given-names>
</name>
<name>
<surname>Robyns</surname>
<given-names>S.</given-names>
</name>
<name>
<surname>Baake</surname>
<given-names>J.</given-names>
</name>
<name>
<surname>Kikken</surname>
<given-names>E.</given-names>
</name>
<name>
<surname>De Geest</surname>
<given-names>R.</given-names>
</name>
<name>
<surname>Birem</surname>
<given-names>M.</given-names>
</name>
<etal/>
</person-group> (<year>2022</year>). <article-title>A cloud-based digital twin for monitoring of an adaptive clamping mechanism used for high performance composite machining</article-title>. <source>Procedia Comput. Sci.</source> <volume>200</volume> (<issue>1</issue>), <fpage>227</fpage>&#x2013;<lpage>236</lpage>. <pub-id pub-id-type="doi">10.1016/j.procs.2022.01.221</pub-id>
</citation>
</ref>
<ref id="B17">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Wei</surname>
<given-names>J.</given-names>
</name>
<name>
<surname>Hou</surname>
<given-names>X.</given-names>
</name>
<name>
<surname>Xu</surname>
<given-names>G.</given-names>
</name>
<name>
<surname>Zhang</surname>
<given-names>G.</given-names>
</name>
<name>
<surname>Fan</surname>
<given-names>H.</given-names>
</name>
</person-group> (<year>2021b</year>). <article-title>Modeling and machining of integral impeller based on NURBS curve</article-title>. <source>Int. J. Adv. Manuf. Technol.</source> <volume>113</volume>, <fpage>2243</fpage>&#x2013;<lpage>2255</lpage>. <pub-id pub-id-type="doi">10.1007/s00170-021-06704-4</pub-id>
</citation>
</ref>
<ref id="B18">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Wei</surname>
<given-names>Y.</given-names>
</name>
<name>
<surname>Hu</surname>
<given-names>T.</given-names>
</name>
<name>
<surname>Zhou</surname>
<given-names>T.</given-names>
</name>
<name>
<surname>Ye</surname>
<given-names>Y.</given-names>
</name>
<name>
<surname>Luo</surname>
<given-names>W.</given-names>
</name>
</person-group> (<year>2021a</year>). <article-title>Consistency retention method for CNC machine tool digital twin model</article-title>. <source>J. Manuf. Syst.</source> <volume>58</volume> (<issue>1</issue>), <fpage>313</fpage>&#x2013;<lpage>322</lpage>. <pub-id pub-id-type="doi">10.1016/j.jmsy.2020.06.002</pub-id>
</citation>
</ref>
<ref id="B19">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Yan</surname>
<given-names>Y.</given-names>
</name>
<name>
<surname>Zhang</surname>
<given-names>L.</given-names>
</name>
<name>
<surname>Gao</surname>
<given-names>J.</given-names>
</name>
</person-group> (<year>2021</year>). <article-title>Tool path planning for flank milling of non-developable ruled surface based on immune particle swarm optimization algorithm</article-title>. <source>Int. J. Adv. Manuf. Technol.</source> <volume>115</volume> (<issue>4</issue>), <fpage>1063</fpage>&#x2013;<lpage>1074</lpage>. <pub-id pub-id-type="doi">10.1007/s00170-021-07263-4</pub-id>
</citation>
</ref>
<ref id="B20">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Yu</surname>
<given-names>D. Y.</given-names>
</name>
<name>
<surname>Ding</surname>
<given-names>Z.</given-names>
</name>
<name>
<surname>Tian</surname>
<given-names>X. Q.</given-names>
</name>
</person-group> (<year>2021</year>). <article-title>High-precision machining technology based on analytical method for integral impeller with flank milling</article-title>. <source>Int. J. Adv. Manuf. Technol.</source> <volume>114</volume>, <fpage>2309</fpage>&#x2013;<lpage>2319</lpage>. <pub-id pub-id-type="doi">10.1007/s00170-021-06931-9</pub-id>
</citation>
</ref>
<ref id="B21">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Zhao</surname>
<given-names>P.</given-names>
</name>
<name>
<surname>Liu</surname>
<given-names>Z.</given-names>
</name>
<name>
<surname>Li</surname>
<given-names>Z.</given-names>
</name>
<name>
<surname>Cao</surname>
<given-names>Z.</given-names>
</name>
</person-group> (<year>2023</year>). <article-title>Research on tool axis vector optimization when face milling complex surfaces</article-title>. <source>Int. J. Adv. Manuf. Technol.</source> <volume>128</volume> (<issue>11-12</issue>), <fpage>5081</fpage>&#x2013;<lpage>5099</lpage>. <pub-id pub-id-type="doi">10.1007/s00170-023-12031-7</pub-id>
</citation>
</ref>
<ref id="B22">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Zhao</surname>
<given-names>Z.</given-names>
</name>
<name>
<surname>Wang</surname>
<given-names>Y.</given-names>
</name>
<name>
<surname>Qian</surname>
<given-names>N.</given-names>
</name>
<name>
<surname>Su</surname>
<given-names>H.</given-names>
</name>
<name>
<surname>Fu</surname>
<given-names>Y.</given-names>
</name>
</person-group> (<year>2020</year>). <article-title>A framework for accuracy enhancement in milling thin-walled narrow-vane turbine impeller of NiAl-based superalloy</article-title>. <source>Int. J. Adv. Manuf. Technol.</source> <volume>108</volume>, <fpage>3925</fpage>&#x2013;<lpage>3938</lpage>. <pub-id pub-id-type="doi">10.1007/s00170-020-05554-w</pub-id>
</citation>
</ref>
<ref id="B23">
<citation citation-type="journal">
<person-group person-group-type="author">
<name>
<surname>Zou</surname>
<given-names>X.</given-names>
</name>
<name>
<surname>Shi</surname>
<given-names>K.</given-names>
</name>
<name>
<surname>Xu</surname>
<given-names>H. Y.</given-names>
</name>
<name>
<surname>Tam</surname>
<given-names>H. Y.</given-names>
</name>
</person-group> (<year>2022</year>). <article-title>Tool orientation optimization based on spatial tractrix method for five-axis CNC machining with ball end cutters</article-title>. <source>Commun. Math. Statistics</source> <volume>10</volume> (<issue>4</issue>), <fpage>705</fpage>&#x2013;<lpage>737</lpage>. <pub-id pub-id-type="doi">10.1007/s40304-021-00255-6</pub-id>
</citation>
</ref>
</ref-list>
</back>
</article>