A texture-constrained optimization method for singularity and kinematic smoothness of five-axis milled surfaces
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-05-20
- Publication Date
- 2026-08-11
AI Technical Summary
[0004]为了解决现有五轴铣削加工中奇异优化及机床运动学光顺空间转换复杂,缺乏考虑刀具姿态变化对微观纹理形貌的影响,优化过程难以保证加工表面纹理形貌整体一致性与完整性的问题,本发明提出一种纹理约束的五轴铣削曲面奇异及运动学光顺优化方法,解决上述问题
(1)本发明在考虑五轴铣削加工中刀具姿态变化对纹理形貌的影响基础上,在纹理约束的姿态可行域下,实现五轴铣削自由曲面奇异优化及机床运动学光顺优化。
Smart Images

Figure CN122546879A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of five-axis milling surface morphology technology, and in particular to a method for optimizing the singularity and kinematic smoothness of five-axis milling surfaces with texture constraints. Background Technology
[0002] Freeform surfaces are widely used in high-end equipment manufacturing fields such as aerospace, automotive manufacturing, and mold processing. The texture and quality of the machined surface directly affect the aerodynamic performance, friction and wear characteristics, and fatigue life of the parts. Five-axis milling, with its high spatial degrees of freedom and high machining quality and efficiency, has become one of the commonly used machining techniques for complex freeform surfaces. However, during five-axis simultaneous machining, when the axes of the two rotary axes of the machine tool tend to be collinear or parallel, kinematic singularities can easily be induced, leading to violent abrupt changes in motion or even instantaneous loss of control of the rotary axes. This affects the integrity of the texture and morphology of the machined surface and deteriorates the surface quality. At the same time, non-smooth machine tool rotary axis motion may cause sudden velocity changes and acceleration shocks, reducing the quality of the machined surface.
[0003] To address the aforementioned issues, existing research typically employs singularity avoidance through tool axis vector adjustment and optimizes machine tool kinematic smoothness to improve the surface morphology quality of five-axis milling. However, most studies constrain the tool axis vector change rate in the workpiece coordinate system to achieve overall path smoothness and singularity avoidance, neglecting the geometric impact of tool axis vector changes on the micro-texture morphology of the machined surface in the tool contact point's local coordinate system. Furthermore, during singularity optimization or machine tool rotary axis kinematic smoothing, the tool axis vector lacks reasonable constraints; improper adjustment can disrupt the overall consistency and integrity of the machined surface texture. Moreover, in existing research, singularity optimization and machine tool kinematic smoothing are usually solved separately in geometric space and machine space, respectively. The spatial transformation between these two spaces is complex during optimization, and achieving unified constraints and optimization is difficult. Summary of the Invention
[0004] To address the problems in existing five-axis milling processes, such as the complexity of singular optimization and machine tool kinematic smoothing spatial transformations, the lack of consideration for the impact of tool posture changes on micro-texture morphology, and the difficulty in ensuring the overall consistency and integrity of the texture morphology on the machined surface during the optimization process, this invention proposes a texture-constrained five-axis milling surface singular and kinematic smoothing optimization method to solve the above problems.
[0005] This application discloses a texture-constrained method for optimizing singularities and kinematic smoothness of five-axis milled surfaces, including the following steps: S1. Obtain the tool axis vector of each tool point in the cutting path, project the tool axis vector onto the preset texture constraint surface to obtain the two-dimensional tool axis direction point, and identify singular points and singular intervals based on the two-dimensional tool axis direction point to construct the singular adjustment interval. S2. Determine the feasible region of texture-constrained posture for each tool point in the singular adjustment interval, and perform Boolean difference operation with the singular region to establish a feasible region of posture without singular texture constraints. S3. With the feasible region of pose without singular texture constraints as constraints, and the local tool axis vector change rate in the tool contact point coordinate system as the optimization objective, a hierarchical directed acyclic graph model is constructed, and a weighted state transition optimization strategy is used to perform singular optimization to obtain the initial path of singular optimization. S4. Perform B-spline fitting on the machine tool rotation axis angle in the singular optimization initial path, and combine constraint violation risk scoring and adaptive constraint iteration to achieve smooth kinematic optimization of the machine tool rotation axis.
[0006] Preferably, S1 includes: S11. Calculate the tool axis vector at the tool position point by combining the tool attitude angle and the surface geometric parameters at the tool position point; S12. Project the tool axis vector onto the texture constraint surface to obtain the corresponding two-dimensional tool axis direction point; S13. Identify singular points sequentially in the tool axis direction point sequence, and a series of consecutive singular points constitute a singular interval. S14. Extend the knife point outside the two ends of the singular interval as a buffer zone, and merge the singular interval and its corresponding buffer zone into a singular adjustment interval.
[0007] Preferably, S2 includes: S21. Determine the range of tool attitude angles corresponding to the specified texture; S22. Based on the four boundaries of the range of attitude angles of each continuous tool, establish a set of discrete points for each boundary and calculate the two-dimensional tool axis direction points of each boundary discrete point to form a set of boundary tool axis direction points, thereby constructing a feasible region of texture constraint attitude. S23. Perform Boolean difference operations on the feasible region of pose with texture constraints and the singular region to establish the feasible region of pose without singular texture constraints:
[0008] in, This represents the feasible region for pose without singular texture constraints. The feasible region for pose constraints is defined by texture. For the strange realm, It is an empty set.
[0009] Preferably, S3 includes: S31. Map each knife point within the singular adjustment interval sequentially to the corresponding level of the layered graph structure; S32. Obtain the candidate tool axis direction point set for each tool position and use it as a node at the corresponding level; S33. Construct directed edges between adjacent level nodes, establish a hierarchical graph structure, and perform feasibility screening and state transition cost calculation, using the tool axis vector change rate in the local coordinate system of the tool contact point. As a cost of state transition; If the knife points of two adjacent layers are both fixed anchor points, establish a unique feasible directed edge; If only one of the two adjacent knife point layers has a fixed anchor point, and the fixed anchor point is a singular point, then the edge with the minimum state transition cost is selected as the only feasible directed edge, and the original non-fixed anchor point is fixed as the anchor point. If only one of the two adjacent tool points is a fixed anchor point, and the fixed anchor point is a non-singular point or there is no fixed point: if there is no feasible directed edge, then the feasible region of pose without singular texture constraint is expanded level by level for the non-anchor tool point and discretized to obtain the tool axis direction point set. The expanded tool axis direction point set is added to the candidate point set. If there is a feasible directed edge, the expansion is stopped. If there are still no feasible edges after extending to all feasible regions of pose without singular texture constraints, select the directed edge closest to the boundary of the singular region and fix the non-anchor point tool point as the anchor point. S34. Based on the constructed hierarchical graph structure, a weighted state transition optimization strategy is adopted to perform path search to obtain the globally optimal singular optimization initial path.
[0010] Preferably, S34 includes: S341. Establish the weighting coefficients for each tool point in the singular adjustment interval:
[0011] in, As the initial weights, Stiffness weight; In the formula:
[0012] in, The stiffness weights for points in the singular interval. For maximum stiffness weight, This is the distance from the current tool position to the nearest boundary of the singular interval. This is the total length of the buffer. It is the attenuation factor; S342. Based on the layer-by-layer state transition calculation and the accumulation of weighted costs, the state transition path with the minimum accumulated cost is searched, and the globally optimal tool axis sequence is extracted through path backtracking. The state transition equation is as follows:
[0013] in, For level numbering, Number the nodes. Indicates the first Layer The minimum cumulative cost of nodes, Indicates the first The first layer The node to the first The first layer The cost of state transitions for each node.
[0014] Preferably, S4 includes: S41. Establish the normalized parameter sequence of each tool position in the singular adjustment interval, and calculate the machine tool rotation axis angle of each tool position in the singular adjustment interval in the initial path of singular optimization. S42. Under the constraints of texture-constrained pose feasible region, solve the control point parameters and node vectors of the rotation axis angle fitting curve, and establish a unified B-spline fitting of the machine tool rotation axis angle at the tool position point in the singular adjustment interval. S43. Calculate the constraint violation risk score for each non-anchor point tool position in the singular adjustment interval, and determine the constraint point set based on the risk score using a hierarchical strategy. S44. Using the control point parameters of the fitting curve of the rotation axis as optimization parameters, apply texture constraints and attitude feasible domain constraints to the tool position of the constraint point set. Combine the tool axis vector change rate constraints and machine tool kinematic constraints, and take the kinematic smoothness of the machine tool rotation axis as the optimization objective to perform adaptive constraint iterative optimization solution. S45. An iterative solution is performed using an adaptive texture constraint extension nonlinear optimization method that violates the driving principle. Under the condition that all tool positions in the singular adjustment interval satisfy the texture constraint attitude feasible region constraint, the optimal path for smooth kinematics of the machine tool rotary axis is obtained.
[0015] Preferably, S42 includes: S421. Set the number of curve fitting iterations. Establish the normalized parameter sequence of the tool position point. And set the maximum number of iterations for the optimized solver. ; S422. Set the minimum number of control points. With maximum number of control points Initialize the number of control points ; S423, Based on the current number of control points Construct node vectors and calculate B-spline basis function matrix. Combine A rotation axis angle and C rotation axis angle to construct linear equation system to solve control point parameters and obtain global analytical solution under unconstrained conditions. S424. Using the global analytical solution as the initial solution, the feasible region of the pose constrained by the texture of the anchor point and the feasible region of the pose without singular texture constraint of the non-anchor point are used as constraints. The sum of the fitting residual of the rotation axis angle data and the curve smoothness is used as the optimization objective function, and the optimal solution under the current number of control points is output. The overall objective function is established by adding a complexity penalty term:
[0016] in, To optimize the objective function, This is the complexity penalty coefficient. To control the number of points; The optimization rate of the overall objective function is calculated, and the number of control points is increased and iterated based on the comparison with the preset threshold. Finally, the control point parameters of the singular optimization result fitting curve are obtained.
[0017] Preferably, S43 includes: S431. Set the minimum number of constraint points. Add the two endpoints of the singular adjustment interval to the initial constraint point set; S432. Calculate the texture constraint pose feasible region violation risk index values for other non-anchor point tool positions. The risk index includes constraint size and constraint margin. The constraint scale reflects the constraint including the width of the C-axis rotation angle interval and the area of the pose feasible region without singular texture constraints, and the constraint margin includes the C-axis rotation constraint margin and the pose feasible region constraint margin without singular texture constraints. After normalizing each indicator, the risk score for each cutter site was calculated:
[0018] in, This is the normalized result for the width of the C-axis rotation angle interval. The result is the normalized area of the pose feasible region without singular texture constraints. This is the normalized result of the constraint margin for the C rotation axis. The result is the normalized result of the pose feasible region constraint margin without singular texture constraints. The incision sites were sorted in descending order based on risk scores; S433. Traverse the node intervals of the B-spline curve, and select the tool point with the highest risk score in each interval to add it to the constraint point set, thereby obtaining the current number of constraint point sets. ; like Then, constraint points are added to the constraint point set in descending order of risk score, and the interval between each constraint point satisfies the minimum interval constraint.
[0019] Preferably, S44 includes: S441. Construct optimization constraints, including: Apply texture constraints and pose feasible region constraints to the tool positions in the constraint point set; Apply a periodic jump constraint to the rotation axis angle of C; Apply a relative tolerance constraint to the rate of change of the tool axis vector between tool points; Apply an equality constraint to the rotation axis angle of the fixed anchor point; Based on the jerk limit value of the machine tool's rotary axis motion, apply kinematic constraints to the size of the control points of the rotary axis angle fitting curve; S442. Construct the kinematic smoothing optimization objective function for the rotation axis:
[0020] in, For smooth weight, For smoothing the objective function term, For the weight of the regularization term, For regularization terms, This is a penalty item for degradation.
[0021] Preferably, S45 includes: S451. Use the control points of the fitted curve from the singular optimization result as the initial solution: Set the maximum number of iterations. and the number of extended constraint points ; S452, Regarding the set of constraint points Texture constraints and pose feasible region constraints are applied to the tool position points in the algorithm, and the nonlinear optimization problem is solved using a sequential quadratic programming algorithm to obtain the current solution. S453. Perform texture constraint pose feasible region violation detection on all tool point sets in the singular adjustment interval to obtain the violation point set. ; like If empty, terminate the iteration and output. As the final optimal solution; like Not empty, extract Not in the set of constraint points point set : like Empty or maximum number of iterations reached ,save The first stage is the optimal solution and proceeds to S454; like If not empty and the maximum number of iterations has not been reached, then All tool points are added to the constraint point set. And return to S452; S454. Add texture constraints and pose feasible region constraints to the set of all tool points in the singular adjustment interval. Use the optimal solution of the first stage as the initial solution and perform optimization to obtain the final optimized solution.
[0022] The beneficial effects of this invention are: (1) Based on the influence of tool posture changes on texture morphology in five-axis milling, this invention realizes singular optimization of free surface in five-axis milling and smooth optimization of machine tool kinematics under the feasible domain of posture constrained by texture.
[0023] (2) The present invention can improve the surface morphology quality of the processed surface while ensuring the overall texture morphology quality and integrity. Attached Figure Description
[0024] Figure 1 This is a flowchart of the five-axis milling surface singularity and kinematic smoothing optimization method with texture constraints according to an embodiment of the present invention. Figure 2 This is a schematic diagram of the texture constraint surface mechanism according to an embodiment of the present invention; Figure 3 This is a schematic diagram of the feasible region for texture-constrained pose according to an embodiment of the present invention; Figure 4 This is a schematic diagram of the feasible region of pose without singular texture constraints according to an embodiment of the present invention; Figure 5 This is a schematic diagram of infeasible edges according to an embodiment of the present invention; Figure 6 This is a schematic diagram of the local tool axis vector change at adjacent tool positions according to an embodiment of the present invention; Figure 7 This is the singular optimization direction curve for the singular adjustment interval of path 30 in this embodiment of the invention; Figure 8 This is a schematic diagram of the fitting result under the texture constraint of the singular adjustment interval of path 30 in an embodiment of the present invention; Figure 9 This is a schematic diagram of the smoothing optimization results for the singular adjustment interval of path 30 in an embodiment of the present invention; Figure 10 This is a schematic diagram of the optimization results of the rotation axis motion jerk in the singular adjustment interval of path 30 according to an embodiment of the present invention; Figure 11 This is a schematic diagram of the optimized toolpath according to an embodiment of the present invention; Figure 12 This is a schematic diagram of the Vericut simulation results of an embodiment of the present invention; Figure 13 This is a visualization diagram of a local singular region in an embodiment of the present invention; Figure 14This is a schematic diagram of the optimized digital model of the texture and morphology of a local singular region according to an embodiment of the present invention. Detailed Implementation
[0025] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided with reference to the accompanying drawings and embodiments.
[0026] This application discloses a method for optimizing singularity and kinematic smoothness of texture-constrained five-axis milling surfaces, the process of which is as follows: Figure 1 As shown, it includes the following S1-S4.
[0027] S1. Set the cutting parameters and tool attitude angle, establish the cutting path, and obtain the two-dimensional direction points of the projection of the tool axis vector of each tool position point onto the texture constraint surface. For example, this embodiment uses the isoparametric method to establish 100 cutting paths, and establishes 100 tool positions on each cutting path.
[0028] S11, Combined with tool attitude angle Calculate the tool axis vector at the tool position point using the surface geometric parameters at the tool position point. .in, The tool rotation angle, The tool tilt angle is the surface geometry at the tool position point, including the normal vector. Feed direction vector and perpendicular to the vector with vector vector In this embodiment, the following settings are provided. , .
[0029] S12, Change the tool axis vector Projecting onto the texture constraint surface yields the corresponding 2D tool axis direction point. As shown in the following formula:
[0030] Texture constraint surface is the workpiece coordinate system A plane at point =1 that is parallel to the XOY plane.
[0031] Arrange the tool axis direction points of all tool positions along the cutting path into a sequence of tool axis direction points.
[0032] S13. Identify singular points sequentially along the tool axis direction. A series of consecutive singular points constitutes a singular interval. Wherein: a singular point is located in a singular domain. Internal directional points, strange realm For the workpiece coordinate system X in the texture constraint surface W Y W Z W Central point OW With center at and radius at, A circle, like Figure 2 As shown in the figure. X W Let X be the workpiece coordinate system and Y be the coordinate system. W Let Y be the workpiece coordinate system and Z be the workpiece coordinate system. W O is the Z-axis of the workpiece coordinate system. W This is the origin of the workpiece coordinate system.
[0033]
[0034] In this embodiment .
[0035] S14. Extend the singular interval outside both endpoints. For each tool position, a buffer zone is established. A singular interval and its corresponding buffer zones at both ends constitute a singular adjustment interval. Singular adjustment intervals that intersect on a cutting path are merged to obtain all the final singular adjustment intervals for that cutting path.
[0036] S2. Determine the feasible region of pose without singular texture constraints for each tool point in the singular adjustment interval.
[0037] S21. Determine the range of tool attitude angles corresponding to the texture based on the tool attitude angle. , , , This represents the number of intervals within a continuous range of attitude angles corresponding to the texture. The initial interval is the initial tool attitude angle. The area in which it is located The larger the value, the farther the interval is from the initial interval. Tool tilt angle The minimum value, Tool tilt angle The maximum value, Tool rotation angle The minimum value, Tool rotation angle The maximum value.
[0038] In this embodiment, the texture corresponds to the range of tool attitude angles. : , , ; , , .
[0039] S22. Obtain the range of attitude angles for each continuous tool. , Four boundaries are defined, and a set of discrete points for each boundary is established. Based on S12, the two-dimensional tool axis direction points of each boundary discrete point are calculated, forming a set of boundary tool axis direction points. :
[0040] in, The two-dimensional tool axis direction point is the projection of the tool axis vector onto the texture constraint surface.
[0041] The four boundary tool axis direction point sets are connected sequentially to form a closed boundary. :
[0042] Establish such as Figure 3 The texture constraint pose feasible region is shown. :
[0043] in, This represents the interior of the set. In the diagram, C represents the tool contact point at the tool position.
[0044] S23, Feasible region for constrained pose of texture With Strange Realms Perform Boolean difference operations to establish a feasible region for pose without singular texture constraints. Specifically, this includes three situations: Texture-constrained pose feasible region Strange Realm There is an intersection, that is ( (is an empty set), and ,but Zhongyu Non-intersecting regions are feasible regions for pose without singular texture constraints. ,like Figure 4 As shown in (a) and (b).
[0045] Texture-constrained pose feasible region Strange Realm There is no intersection, that is Then the feasible region of texture-constrained pose That is, the feasible region of pose without singular texture constraints. , ,like Figure 4 As shown in (c).
[0046] Texture-constrained pose feasible region Belongs to the Strange Realm ,Right now Therefore, there is no feasible region for pose without singular texture constraints. ,like Figure 4 As shown in (d).
[0047] Feasible region of pose without singular texture constraints As shown in the following formula:
[0048] S3. With the feasible region of pose without singular texture constraints as constraints, and the local tool axis vector change rate in the tool contact point coordinate system as the optimization objective, a hierarchical directed acyclic graph model is constructed. A weighted state transition optimization strategy is adopted to perform singular optimization on the tool axis direction of each tool point in the singular adjustment interval to obtain the initial singular optimization path.
[0049] S31. Map each knife point within the singular adjustment interval sequentially to the corresponding level of the layered graph structure.
[0050] S32. Obtain the candidate tool axis direction point set for each tool position and use it as a node at the corresponding level.
[0051] S321. Set the non-singular first and last knife points of the singular adjustment interval as fixed anchor points.
[0052] S322. If there is a feasible region of pose without singular texture constraints at the tool position, then the first non-empty feasible region of pose without singular texture constraints is discretized to obtain a set of candidate tool axis direction points.
[0053] If there is no feasible region of pose without singular texture constraints at the tool position, then all feasible regions of pose with texture constraints are discretized to obtain a set of discrete points. The point closest to the boundary of the singular region is selected as the tool axis direction point of the tool position and set as a fixed anchor point.
[0054] S33. Construct directed edges between adjacent level nodes, establish a hierarchical graph structure, and perform feasibility screening and state transition cost calculation.
[0055] Feasible directed edges satisfy the following conditions: the difference in C-axis rotation angle between adjacent nodes is less than a set threshold (40° in this embodiment); the C-axis rotation angle is the angle between the line connecting the tool axis direction point and the origin and the X-axis; the minimum distance from the line segment connecting the directed edges to the origin is greater than the radius of the singular circle to avoid crossing the singular domain. Two infeasible edge cases are as follows: Figure 5 As shown.
[0056] like Figure 6 As shown, the rate of change of the tool axis vector in the local coordinate system of the tool contact point As the cost of state transition.
[0057]
[0058]
[0059] in, The tool contact point at the tool position point, For local tool axis vectors, Number the knife point.
[0060] If the knife points of two adjacent layers are both fixed anchor points, establish a unique feasible directed edge.
[0061] If only one of the two adjacent knife point layers has a fixed anchor point, and the fixed anchor point is a singular point, then the edge with the minimum state transition cost is selected as the only feasible directed edge, and the original non-fixed anchor point is fixed as the anchor point.
[0062] If only one of the two adjacent tool points is a fixed anchor point, and the fixed anchor point is a non-singular point or there is no fixed point: if there is no feasible directed edge, then the feasible region of pose without singular texture constraints is expanded level by level for the non-anchor tool points and discretized to obtain the tool axis direction point set. The expanded tool axis direction point set is added to the candidate point set. If there is a feasible directed edge, the expansion stops.
[0063] If there are still no feasible edges after extending to all feasible regions without singular texture constraints, select the directed edge closest to the boundary of the singular region and fix the non-anchor point tool point as the anchor point.
[0064] S34. Based on the constructed hierarchical graph structure, a weighted state transition optimization strategy is adopted to perform path search to obtain the globally optimal singular optimization initial path.
[0065] S341. Establish the weight coefficients of each knife point in the singular adjustment interval.
[0066] The stiffness weight of the tool position within the buffer is determined by the normalized distance from the boundary of the singular interval. :
[0067] in, The stiffness weights for points in the singular interval. For maximum stiffness weight, This is the distance from the current tool position to the nearest boundary of the singular interval. This is the total length of the buffer. This is the attenuation factor.
[0068] Calculate the weighting coefficients of each tool point in the singular adjustment interval. :
[0069] in, These are the initial weights.
[0070] S342. Based on the layer-by-layer state transition calculation and weighted cost accumulation, search for the state transition path with the minimum accumulated cost, and extract the globally optimal tool axis sequence through path backtracking. The state transition equation is as follows:
[0071] in, For level numbering, Number the nodes. Indicates the first Layer The minimum cumulative cost of each node. Indicates the first The first layer The node to the first The first layer The cost of state transitions for each node.
[0072] like Figure 7 The diagram shows the singular optimization direction curve for path 30 (the 30th cutting path planned in S1) in this embodiment, illustrating the singular optimization results for a path with singularities. The original direction curve is a curve drawn from the two-dimensional tool axis direction points obtained in S1. The initial direction curve after singular optimization is a curve drawn from the two-dimensional tool axis direction points at the tool position of the initial singular optimization path. Direction points outside the singular adjustment interval are the two-dimensional tool axis direction points outside the singular adjustment interval, and direction points inside the singular adjustment interval are the two-dimensional tool axis direction points within the singular adjustment interval.
[0073] S4. Kinematic smoothing optimization of machine tool rotary axes with texture constraints and pose feasible domain constraints.
[0074] S41. Establish the normalized parameter sequence for each cutter point in the singular adjustment interval. Calculate the machine tool rotation axis angle at each tool position point in the singular adjustment interval of the initial path for singular optimization.
[0075] The rotation axis angle C is as follows:
[0076] The rotation axis angle is as follows:
[0077]
[0078] S42. Under the constraints of texture-constrained pose feasible region, solve for the control point parameters of the A and C rotation axis angle fitting curve. And node vectors, establish singular adjustment interval tool position point machine tool rotation axis angle unified B-spline fitting.
[0079]
[0080] in, The parameters for the control points of the curve fitting the rotation axis angle are: These are the control point parameters for the C-axis rotation angle fitting curve. The number of control point parameters for the A and C-axis rotation angle fitting curves are equal, and the node vectors for the A and C-axis rotation angle fitting curves are consistent.
[0081] S421. Set the number of curve fitting iterations. Establish the parameter sequence of the tool position point. Set the maximum number of iterations for the optimized solver. , Achieve lightweight optimization by taking the smaller value.
[0082] S422. Set the minimum number of control points. Set the maximum number of control points based on the number of tool points. Initial number of control points .
[0083] S423, Based on the current number of control points Construct node vectors and calculate the B-spline basis function matrix. Combine the rotation axis angles (A and C) to construct a system of linear equations to solve for the control point parameters, obtaining the unconstrained global analytical solution. .
[0084] S424. Use the unconstrained global analytical solution as the initial solution: Anchor points are constrained by texture constraints on their pose feasible region, while non-anchor points are constrained by non-singular texture constraints on their pose feasible region. The sum of the fitting residuals of the rotation axis angle data and the curve smoothness is used as the objective function for curve fitting optimization. The anchor points are given a large weight so that the fitted curve prioritizes the fitting accuracy of the anchor points, and the optimal solution with the current number of control points is output.
[0085] The objective function for rotation axis A is as follows:
[0086] The objective function for the C-axis of rotation is as follows:
[0087] in, Weights for the residuals fitted to the data. Let A be the basis function matrix of the rotation axis. Let C be the basis function matrix of the rotation axis. Let A be the rotation axis angle. Let C be the rotation axis angle. The weights are for the smoothness penalty function. This is the smoothness penalty function.
[0088] Fitting and optimizing the objective function :
[0089] To further balance fitting accuracy and model size, a complexity penalty term is added to establish the overall objective function. :
[0090] in, This is the complexity penalty coefficient.
[0091] Calculate the overall objective function optimization rate :
[0092] in, This is the result of the objective function from the previous round.
[0093] If the optimization rate is less than a preset threshold, stop the iteration and use the result of the previous round as the solution to obtain the control point parameters of the singular optimization result fitting curve. .
[0094] If the optimization rate is greater than the preset threshold, then .like Stop the iteration and take the result of this round of optimization as the final solution. .like Repeat S424.
[0095] like Figure 8 The diagram shows the fitting results under texture constraints in the singular adjustment interval of path 30. It illustrates the rendering of the two-dimensional tool axis direction points at the tool positions within the singular adjustment interval under the pose feasible region without singular texture constraints, based on the A and C rotation axis fitting curves. The A and C rotation axis angles at each tool position are calculated, and then the two-dimensional tool axis direction points are calculated. The results show that the two-dimensional tool axis direction points at each tool position after initial singular optimization (corresponding to the two-dimensional tool axis direction points after initial singular optimization in the diagram) and the two-dimensional tool axis direction points at each tool position obtained after the A and C rotation axis fitting curves (corresponding to the tool position direction points at the fitting curves in the diagram) basically coincide, indicating that the fitting curve has high accuracy.
[0096] S43. Calculate the constraint violation risk score for each non-anchor point tool position in the singular adjustment interval, and determine the constraint point set based on the risk score using a hierarchical strategy. .
[0097] S431. Set the minimum number of constraint points. Add the endpoints of the singular adjustment interval to the initial constraint point set. .
[0098] S432. Calculate the texture constraint pose feasible region violation risk index values for other non-anchor point tool positions. The risk index includes two main categories: constraint size and constraint margin.
[0099] The constraint size reflects the size of the constraint interval, including: the width of the C-axis rotation angle interval. and feasible region of pose without singular texture constraints .
[0100]
[0101]
[0102] in, For the minimum C-axis rotation angle, The maximum rotational angle of axis C.
[0103] Constraint margin reflects the distance from the initial point to the constraint boundary, including: C-axis rotation constraint margin. And pose feasible region constraint margin without singular texture constraints .
[0104]
[0105]
[0106] in, Let C be the rotation axis angle.
[0107] Based on the minimum and maximum values of each violation risk indicator at the singular adjustment interval cutter point, normalization is performed to unify the dimensions of each indicator. Based on the normalized values of each indicator, the risk score for each cutter point is calculated. :
[0108] in, This is the normalized result for the width of the C-axis rotation angle interval. The result is the normalized area of the pose feasible region without singular texture constraints. This is the normalized result of the constraint margin for the C rotation axis. The result is the normalized result of the pose feasible region constraint margin without singular texture constraints.
[0109] The incision sites were sorted in descending order based on risk scores.
[0110] S433. Traverse the node intervals of the B-spline curve, and select the highest-risk cutting point in each interval to add it to the constraint point set. Obtain the current set of constraint points quantity .
[0111] like Constraint points are added to the constraint point set in descending order of risk score. The intervals between each constraint point satisfy the minimum interval constraint.
[0112] S44. Control point parameters for fitting the curve with rotation axes A and C. As optimization parameters, for the set of constraint points Texture constraints and pose feasible domain constraints are applied to the tool position point. Combined with tool axis vector change rate constraints and machine tool kinematic constraints, adaptive constraint iterative optimization is performed with the kinematic smoothness of the machine tool rotary axis as the optimization objective.
[0113] S441. Construct optimization constraints.
[0114] For the set of constraint points Texture constraints and pose feasible regions are applied to the tool position point, and this constraint is a single constrained feasible region containing its initial path point. The tool axis direction point of the tool position Should be in the feasible region Inside:
[0115] in, This is the state indication function for the feasible region constraint of the tool position texture constraint.
[0116] Constrain the C-axis rotation angle to prevent periodic jumps:
[0117] Rate of change of tool axis vector between tool setting points Apply constraints:
[0118] in, The rate of change of the tool axis vector between the tool positions on the initial path. To allow for relative violations of tolerance.
[0119] Apply equation constraints to the rotation axis angles of the fixed anchor point A and C.
[0120] Based on the jerk limits of the A and C rotary axes of the machine tool, the size of the control points of the angle fitting curves of the A and C rotary axes are constrained to achieve kinematic constraints on the machine tool.
[0121] S442. Construct the kinematic smoothing optimization objective function for the rotation axis.
[0122] Establish the kinematic normalization objective function for the rotation axis angle. :
[0123] in, Integral the accelerometer of the rotation axis in the singular adjustment interval. Add jerk to the rotational axis at the junction of the singular adjusted interval and the unadjusted interval. Integral accelerometer on the rotation axis of the singular adjustment interval of the initial path. Add jerk to the rotation axis at the junction of the singular adjusted and unadjusted intervals of the initial path. Normalize the values based on the initial path to eliminate differences in the dimensions and numerical scales of the objective functions for different rotation axes.
[0124] Constructing a smooth objective function term :
[0125] in, It is a smoothing relaxation factor. Let A be the kinematic normalization objective function for the rotation axis angle. Let C be the objective function for normalizing the kinematics of the rotation axis angle.
[0126] Establish regularization terms This helps to prevent the optimization results from deviating significantly from the initial optimization path.
[0127]
[0128]
[0129] in, This represents the total number of control points for the curve fitting the rotation axis angle. Number the control points. After smoothing optimization, the first Parameters of each control point The first curve fitted to the singular optimization result Parameters for each control point.
[0130] Establish degradation penalty items This avoids the final optimization result degrading relative to the initial value under multiple constraints.
[0131]
[0132] in, To penalize the weighting coefficients, the maximum value is taken, thus imposing a large penalty on the variation in optimization. Let C be the kinematic normalization objective function for the rotation axis angle. Let A be the objective function for kinematic normalization of the rotation axis angle.
[0133] Final objective function as follows:
[0134] in, For smooth weight, The weight is the regularization term weight.
[0135] S45. Based on the construction of optimization variables, constraints and objective function, the adaptive texture constraint extended nonlinear optimization method with violation of the driving force is used for iterative solution. Under the condition that all tool positions in the singular adjustment interval satisfy the texture constraint attitude feasible region constraint, the optimal path for kinematic smoothing of the machine tool rotary axis is obtained.
[0136] S451. Use the control points of the fitted curve from the singular optimization result as the initial solution: Set the maximum number of iterations. and the number of extended constraint points .
[0137] S452, Regarding the set of constraint points Texture constraints and pose feasible region constraints are applied to the tool position points. The nonlinear optimization problem is solved using the Sequential Quadratic Programming (SQP) algorithm to obtain the current solution. .
[0138] S453, Set of all tool points in the singular adjustment interval Perform texture constraint pose feasible region violation detection and obtain the violation point set. The violation detection method is: determine the set of all tool position points. To determine whether the two-dimensional tool axis direction points violate the inequality constraints in S441, we obtain the set of violation points. .
[0139] like If empty, terminate the iteration and output. As the final optimal solution.
[0140] like Not empty: Extract Not in the set of constraint points point set .
[0141] like Empty, or the current iteration count has reached the set maximum iteration count. ,save The optimal solution for the first stage Enter S454.
[0142] like If not empty and the maximum number of iterations has not been reached, then All tool points are added to the constraint point set. And return to S452.
[0143] S454, Set of all tool points in the singular adjustment interval Add texture constraints and pose feasible region constraints to obtain the optimal solution in the first stage. As the initial solution, we perform optimization to obtain the final optimized solution. .
[0144] like Figure 9 This diagram illustrates the smoothing optimization results for the singular adjustment interval of path 30, showcasing the kinematic smoothing results of the singular adjustment interval in the 30th cutting path planned by S1. In the diagram, the smoothed 2D tool axis direction points are the 2D tool axis direction points at the tool position points in the singular adjustment interval after kinematic smoothing, while the original singular adjustment interval direction point curves are curves plotted from the 2D tool axis direction points at the tool position points in the 30th cutting path planned by S1. The results show that all 2D tool axis direction points are within their feasible pose region without singular texture constraints after smoothing.
[0145] like Figure 10 This diagram illustrates the optimization results of the jerk acceleration of the rotary axis motion in the singular adjustment interval of cutting path 30 in the S1 planned cutting path. It shows the optimization results of the rotary axis angle jerk acceleration after kinematic smoothing in the singular adjustment interval. The results show that the jerk acceleration of rotary axis A is significantly optimized, and the jerk acceleration of rotary axis C is also optimized, but the optimization range is not large. This is because the kinematic smoothness of rotary axis C was already good before optimization. Figure 11 To optimize the toolpath after the tool position, Figure 12 The results of Vericut simulation of the original and optimized path processing texture topography are presented. Figure 12 (a) is , Machining results under constant tool attitude angle Figure 12 In the middle (b), the result of singular optimization kinematic smoothing with texture constraints is shown.
[0146] Figure 13 This demonstrates a comparison of the original and optimized texture morphology in localized singular regions. Figure 14 The paper presents a comparison of the original and optimized digital models of texture morphology in local singular regions. Figure 12 and Figure 13 The results showed that the uneven texture morphology caused by the singularity problem in the singular region was improved. Figure 14 Within the same singular region, the optimized texture morphology maintains consistency in texture features and trends under the constraints of the pose angle feasible region.
[0147] The foregoing has shown and described the basic principles, main features, and advantages of the present invention. Those skilled in the art should understand that the present invention is not limited to the above embodiments. The embodiments and descriptions in the specification are merely illustrative of the principles of the invention. Various changes and modifications can be made to the invention without departing from its spirit and scope, and all such changes and modifications fall within the scope of the present invention as claimed. The scope of protection of this invention is defined by the appended claims and their equivalents.
Claims
1. A method for optimizing singularity and kinematic smoothness of texture-constrained five-axis milling surfaces, characterized in that, Includes the following steps: S1. Obtain the tool axis vector of each tool point in the cutting path, project the tool axis vector onto the preset texture constraint surface to obtain the two-dimensional tool axis direction point, and identify singular points and singular intervals based on the two-dimensional tool axis direction point to construct the singular adjustment interval. S2. Determine the feasible region of texture-constrained posture for each tool point in the singular adjustment interval, and perform Boolean difference operation with the singular region to establish a feasible region of posture without singular texture constraints. S3. With the feasible region of pose without singular texture constraints as constraints, and the local tool axis vector change rate in the tool contact point coordinate system as the optimization objective, a hierarchical directed acyclic graph model is constructed, and a weighted state transition optimization strategy is used to perform singular optimization to obtain the initial path of singular optimization. S4. Perform B-spline fitting on the machine tool rotation axis angle in the singular optimization initial path, and combine constraint violation risk scoring and adaptive constraint iteration to achieve smooth kinematic optimization of the machine tool rotation axis.
2. The method of claim 1, wherein, S1 includes: S11. Calculate the tool axis vector at the tool position point by combining the tool attitude angle and the surface geometric parameters at the tool position point; S12. Project the tool axis vector onto the texture constraint surface to obtain the corresponding two-dimensional tool axis direction point; S13. Identify singular points sequentially in the tool axis direction point sequence, and a series of consecutive singular points constitute a singular interval. S14. Extend the knife point outside the two ends of the singular interval as a buffer zone, and merge the singular interval and its corresponding buffer zone into a singular adjustment interval.
3. The method of claim 2, wherein, S2 includes: S21. Determine the range of tool attitude angles corresponding to the specified texture; S22. Based on the four boundaries of the range of attitude angles of each continuous tool, establish a set of discrete points for each boundary and calculate the two-dimensional tool axis direction points of each boundary discrete point to form a set of boundary tool axis direction points, thereby constructing a feasible region of texture constraint attitude. S23. Perform Boolean difference operations on the feasible region of pose with texture constraints and the singular region to establish the feasible region of pose without singular texture constraints: wherein, is the singular texture constraint pose feasible region, is the texture constraint pose feasible region, is the singular region, is the empty set.
4. The method of claim 3, wherein, S3 includes: S31. Map each knife point within the singular adjustment interval sequentially to the corresponding level of the layered graph structure; S32. Obtain the candidate tool axis direction point set for each tool position and use it as a node at the corresponding level; S33. Construct directed edges between adjacent level nodes, establish a hierarchical graph structure, and perform feasibility screening and state transition cost calculation, using the tool axis vector change rate in the local coordinate system of the tool contact point. As a cost of state transition; If the knife points of two adjacent layers are both fixed anchor points, establish a unique feasible directed edge; If only one of the two adjacent knife point layers has a fixed anchor point, and the fixed anchor point is a singular point, then the edge with the minimum state transition cost is selected as the only feasible directed edge, and the original non-fixed anchor point is fixed as the anchor point. If only one of the two adjacent tool points is a fixed anchor point, and the fixed anchor point is a non-singular point or there is no fixed point: if there is no feasible directed edge, then the feasible region of pose without singular texture constraint is expanded level by level for the non-anchor tool point and discretized to obtain the tool axis direction point set. The expanded tool axis direction point set is added to the candidate point set. If there is a feasible directed edge, the expansion is stopped. If there are still no feasible edges after extending to all feasible regions of pose without singular texture constraints, select the directed edge closest to the boundary of the singular region and fix the non-anchor point tool point as the anchor point. S34. Based on the constructed hierarchical graph structure, a weighted state transition optimization strategy is adopted to perform path search to obtain the globally optimal singular optimization initial path.
5. The method of claim 4, wherein, S34 includes: S341. Establish the weighting coefficients for each tool point in the singular adjustment interval: wherein, is an initial weight, is a stiffness weight; In the formula: wherein, is the stiffness weight for the singular interval point, is the maximum stiffness weight, is the distance from the current tool position to the nearest boundary of the singular interval, is the total length of the buffer zone, is the decay factor; S342. Based on the layer-by-layer state transition calculation and the accumulation of weighted costs, the state transition path with the minimum accumulated cost is searched, and the globally optimal tool axis sequence is extracted through path backtracking. The state transition equation is as follows: in, For level numbering, Number the nodes. Indicates the first Layer The minimum cumulative cost of nodes, Indicates the first The first layer The node to the first The first layer The state transition cost of each node.
6. The method for optimizing singularity and kinematic smoothness of texture-constrained five-axis milling surfaces according to claim 5, characterized in that, S4 includes: S41. Establish the normalized parameter sequence of each tool position in the singular adjustment interval, and calculate the machine tool rotation axis angle of each tool position in the singular adjustment interval in the initial path of singular optimization. S42. Under the constraints of texture-constrained pose feasible region, solve the control point parameters and node vectors of the rotation axis angle fitting curve, and establish a unified B-spline fitting of the machine tool rotation axis angle at the tool position point in the singular adjustment interval. S43. Calculate the constraint violation risk score for each non-anchor point tool position in the singular adjustment interval, and determine the constraint point set based on the risk score using a hierarchical strategy. S44. Using the control point parameters of the fitting curve of the rotation axis as optimization parameters, apply texture constraints and attitude feasible domain constraints to the tool position of the constraint point set. Combine the tool axis vector change rate constraints and machine tool kinematic constraints, and take the kinematic smoothness of the machine tool rotation axis as the optimization objective to perform adaptive constraint iterative optimization solution. S45. An iterative solution is performed using an adaptive texture constraint extension nonlinear optimization method that violates the driving principle. Under the condition that all tool positions in the singular adjustment interval satisfy the texture constraint attitude feasible region constraint, the optimal path for smooth kinematics of the machine tool rotary axis is obtained.
7. The method for optimizing singularity and kinematic smoothness of texture-constrained five-axis milling surfaces according to claim 6, characterized in that, S42 includes: S421. Set the number of curve fitting iterations. Establish the normalized parameter sequence of the tool position point. And set the maximum number of iterations for the optimizer. ; S422. Set the minimum number of control points. With the maximum number of control points Initialize the number of control points ; S423, Based on the current number of control points Construct node vectors and calculate B-spline basis function matrix. Combine A rotation axis angle and C rotation axis angle to construct linear equation system to solve control point parameters and obtain global analytical solution under unconstrained conditions. S424. Using the global analytical solution as the initial solution, the feasible region of the pose constrained by the texture of the anchor point and the feasible region of the pose without singular texture constraint of the non-anchor point are used as constraints. The sum of the fitting residual of the rotation axis angle data and the curve smoothness is used as the optimization objective function, and the optimal solution under the current number of control points is output. The overall objective function is established by adding a complexity penalty term: in, To optimize the objective function, This is the complexity penalty coefficient. To control the number of points; The optimization rate of the overall objective function is calculated, and the number of control points is increased and iterated based on the comparison with the preset threshold. Finally, the control point parameters of the singular optimization result fitting curve are obtained.
8. The method for optimizing singularity and kinematic smoothness of texture-constrained five-axis milling surfaces according to claim 7, characterized in that, S43 includes: S431. Set the minimum number of constraint points. Add the two endpoints of the singular adjustment interval to the initial constraint point set; S432. Calculate the texture constraint pose feasible region violation risk index values for other non-anchor point tool positions. The risk index includes constraint size and constraint margin. The constraint scale reflects the constraint including the width of the C-axis rotation angle interval and the area of the pose feasible region without singular texture constraints, and the constraint margin includes the C-axis rotation constraint margin and the pose feasible region constraint margin without singular texture constraints. After normalizing each indicator, the risk score for each cutter site was calculated: in, This is the normalized result for the width of the C-axis rotation angle interval. The result is the normalized area of the pose feasible region without singular texture constraints. This is the normalized result of the constraint margin for the C rotation axis. The result is the normalized result of the pose feasible region constraint margin without singular texture constraints. The incision sites were sorted in descending order based on risk scores; S433. Traverse the node intervals of the B-spline curve, and select the tool point with the highest risk score in each interval to add it to the constraint point set, thereby obtaining the current number of constraint point sets. ; like Then, constraint points are added to the constraint point set in descending order of risk score, and the interval between each constraint point satisfies the minimum interval constraint.
9. The method for optimizing singularity and kinematic smoothness of texture-constrained five-axis milling surfaces according to claim 8, characterized in that, S44 includes: S441. Construct optimization constraints, including: Apply texture constraints and pose feasible region constraints to the tool positions in the constraint point set; Apply a periodic jump constraint to the rotation axis angle of C; Apply a relative tolerance constraint to the rate of change of the tool axis vector between tool points; Apply an equality constraint to the rotation axis angle of the fixed anchor point; Based on the jerk limit value of the machine tool's rotary axis motion, apply kinematic constraints to the size of the control points of the rotary axis angle fitting curve; S442. Construct the kinematic smoothing optimization objective function for the rotation axis: in, For smooth weight, For smoothing the objective function term, For the weight of the regularization term, For regularization terms, This is a penalty item for degradation.
10. The method for optimizing singularity and kinematic smoothness of texture-constrained five-axis milling surfaces according to claim 9, characterized in that, The S45 includes: S451. Use the control points of the fitted curve from the singular optimization result as the initial solution: Set the maximum number of iterations. and the number of extended constraint points ; S452, Regarding the set of constraint points Texture constraints and pose feasible region constraints are applied to the tool position points in the algorithm, and the nonlinear optimization problem is solved using a sequential quadratic programming algorithm to obtain the current solution. S453. Perform texture constraint pose feasible region violation detection on all tool point sets in the singular adjustment interval to obtain the violation point set. ; like If empty, terminate the iteration and output. As the final optimal solution; like Not empty, extract Not in the set of constraint points point set : like Empty or maximum number of iterations reached ,save The first stage is the optimal solution and proceeds to S454; like If not empty and the maximum number of iterations has not been reached, then All tool points are added to the constraint point set. And return to S452; S454. Add texture constraints and pose feasible region constraints to the set of all tool points in the singular adjustment interval. Use the optimal solution of the first stage as the initial solution and perform optimization to obtain the final optimized solution.