Robot milling posture optimization and trajectory compensation method based on global stiffness model

By optimizing the robot's milling posture and trajectory using a global stiffness model, the problems of difficulty in stiffness prediction and strong hardware dependence in robot machining are solved, achieving efficient and low-cost improvement in machining accuracy and surface quality.

CN122165405APending Publication Date: 2026-06-09REHABILITATION UNIV (IN PREPARATION)
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
REHABILITATION UNIV (IN PREPARATION)
Filing Date
2026-03-27
Publication Date
2026-06-09

AI Technical Summary

Technical Problem

Industrial robots face challenges in milling large and complex components, including difficulties in predicting global stiffness, a single optimization objective, strong hardware dependence, and a lack of proactive compensation, resulting in insufficient machining accuracy and stability.

Method used

Based on the global stiffness model, a dynamic parameter prediction model is constructed through sparse sampling, multidimensional discrete testing and spatial interpolation modeling. Combined with toolpath analysis, morphology simulation and trajectory compensation, redundant angles and trajectories are optimized to achieve attitude optimization and trajectory compensation.

Benefits of technology

It achieves efficient and low-cost improvement in processing accuracy, is applicable to existing robots, reduces hardware dependence, improves surface quality and processing efficiency, and meets actual production needs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122165405A_ABST
    Figure CN122165405A_ABST
Patent Text Reader

Abstract

This invention discloses a robot milling posture optimization and trajectory compensation method based on a global stiffness model, belonging to the fields of robot precision machining and computer-aided manufacturing technology. It includes constructing a posture-dependent dynamic parameter prediction model for the entire workspace through sparse sampling, multidimensional discrete testing, and spatial interpolation modeling; completing redundant angle global planning based on surface topography prediction based on toolpath analysis, topography simulation, optimal search, and trajectory smoothing; and compensating for trajectory mirroring based on prediction errors through residual calculation, coordinate correction, and code generation. This invention, based on software algorithms, eliminates the need for expensive active / passive dampers or force sensors, making it applicable to various existing industrial robot machining units and facilitating low-cost upgrades of older production lines. Prediction efficiency is improved by orders of magnitude; the IDW interpolation-based modeling method reduces modeling time by more than 90%, making online process planning for complex surfaces possible.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of robot precision machining and computer-aided manufacturing technology, specifically referring to a robot milling posture optimization and trajectory compensation method based on a global stiffness model. Background Technology

[0002] Industrial robots are increasingly used in the milling of large and complex components, but their serial open-chain structure results in end-effector stiffness that is much lower than that of traditional CNC machine tools, and they also exhibit significant attitude dependence. That is, at the same machining position, the robot's dynamic stiffness and modal characteristics change drastically simply by changing the redundant angle of its rotation around the tool axis.

[0003] Existing technologies have the following limitations in solving the problem of robot machining accuracy: Difficulty in global prediction: The robot's workspace is vast and its posture changes continuously. Traditional finite element analysis is computationally intensive, while modal hammering experiments can only cover a very small number of discrete points, making it difficult to achieve rapid and continuous prediction of stiffness characteristics across the entire workspace; Single optimization objective: Existing posture optimization methods usually only target static stiffness or reachability, ignoring the direct impact of dynamic response during cutting on the final surface morphology; Strong hardware dependence: Common vibration suppression methods often rely on adding active or passive dampers, increasing system cost and integration difficulty; Lack of active compensation: Existing CAM software typically generates toolpaths that only contain theoretical coordinates, failing to perform feedforward path correction based on the tool deflection error predicted by the physical model. Therefore, a robot milling posture optimization and trajectory compensation method based on a global stiffness model is proposed. Summary of the Invention

[0004] The purpose of this invention is to provide a method for robot milling posture optimization and trajectory compensation based on a global stiffness model, so as to solve the problems mentioned in the background art.

[0005] To achieve the above objectives, the present invention provides the following technical solution: a method for robot milling posture optimization and trajectory compensation based on a global stiffness model, comprising the following steps:

[0006] S1. Construct a full workspace attitude-dependent dynamic parameter prediction model through sparse sampling, multidimensional discrete testing, and spatial interpolation modeling.

[0007] S2. Based on toolpath analysis, morphology simulation, optimal search and trajectory smoothing, complete the global planning of redundant angles based on surface morphology prediction;

[0008] S3. Trajectory mirroring compensation based on prediction error through residual calculation, coordinate correction and code generation.

[0009] Preferably, in S1, sparse sampling specifically involves: within the robot's workspace, based on the geometric boundary range of the workspace, the distribution of core areas involved in the processing task, the constraints of the robot's joint motion range, and the potential variation law of stiffness distribution, selecting several representative spatial locations that comprehensively characterize the stiffness characteristics of the entire workspace as anchor points; the selection of anchor points must meet the minimum accuracy threshold of inverse distance weighted interpolation modeling, while taking into account modeling efficiency and prediction accuracy, and densifying anchor points in the edge region of the workspace, the potential region of stiffness abrupt change, and the region with dense processing paths, while appropriately reducing the number of anchor points in regions with relatively uniform stiffness distribution, to ensure that anchor points cover the key dimensions of the workspace and the processing focus area.

[0010] Preferably, the multidimensional discrete test in S1 specifically involves: determining the feasible range of values ​​for the robot redundancy angle for each selected anchor point. The value range is defined based on the robot joint motion limits, link interference constraints, and manufacturing process requirements; subsequently, the redundant angle... Within the feasible range, the redundant angles of the robot are uniformly discretized and sampled at preset angle intervals to form several discrete redundant angle states. For the robot in each discrete state, a modal hammer test method is adopted. A force hammer is used to apply pulse excitation to a preset position of the robot's end effector, and the vibration response signal of the end effector is collected synchronously. After signal processing and analysis, the frequency response function (FRF) of the robot's end effector in each state is obtained, and the spatial position information, redundant angle parameters and corresponding frequency response function data of each anchor point are associated and stored in the database.

[0011] Preferably, the spatial interpolation modeling in S1 specifically involves: introducing an inverse distance weighting method, using the anchor point spatial locations, redundant angle parameters, and corresponding frequency response functions stored in the database as basic data, to establish spatial location... Redundant angle With frequency response function The nonlinear mapping relationship between them is expressed as follows:

[0012] ,

[0013] in, The weighting function is based on pose similarity. The calculation of the weighting function is determined by the spatial distance and the difference in redundancy angle between the current query pose and the poses of each anchor point. The closer the distance and the smaller the difference in redundancy angle, the larger the corresponding weight coefficient. A global stiffness model covering the entire workspace is generated through mapping relationship. The global stiffness model can realize millisecond-level dynamic stiffness query and frequency response function prediction based on the input spatial coordinates and redundancy angle parameters, and the error of the prediction result is controlled within the preset accuracy range.

[0014] Preferably, the toolpath analysis in S2 specifically involves: reading the toolpath file of the part to be machined, including but not limited to CL file and APT file. The toolpath file contains key information such as the tool type, cutting parameters, and theoretical toolpath coordinates for machining the part; extracting key geometric features and process parameters in the toolpath through a file parsing algorithm; and then discretizing the continuous theoretical toolpath into a series of ordered cutting point sequences according to a preset discretization accuracy threshold. Each cutting point contains three-dimensional spatial coordinates, a cutting direction vector, and complete information on the corresponding cutting parameters.

[0015] Preferably, the morphology simulation in S2 specifically involves: for each discretized cutting point, calling a pre-established surface morphology prediction model; the input parameters of the surface morphology prediction model include cutting parameters such as cutting speed, feed rate, and depth of cut at the current cutting point, as well as the dynamic stiffness data under the current pose predicted by the global stiffness model constructed in step S1; the model internally simulates the dynamic interaction process between the tool sweep surface and the workpiece blank during the cutting process through Boolean subtraction operations, and calculates the surface morphology error SLE and surface roughness index Ra of the workpiece under the current cutting state by combining the material removal mechanism and vibration response characteristics. The surface morphology error includes multiple error components such as tool deformation error caused by insufficient robot stiffness and ripple error caused by vibration, and the roughness index is calculated according to the detection method and evaluation system corresponding to the national standard.

[0016] Preferably, the optimal search in S2 specifically involves: at each cutting point, defining the feasible region of the redundant angle based on robot joint motion constraints, link interference avoidance conditions, and machining process requirements; then employing a comprehensive search algorithm to fully search the feasible region of the redundant angle; for each candidate redundant angle, calculating the corresponding surface topography error (SLE) using a surface topography prediction model; and finally selecting the redundant angle that minimizes the surface topography error. As an optimization objective, the target redundant angle that optimizes the machining quality at each cutting point is selected. If multiple redundant angles correspond to the same minimum error, the redundant angle that minimizes the energy consumption of the robot joint movement or makes the posture change smoothest is selected as the final target value.

[0017] Preferably, the trajectory smoothing in S2 specifically involves: for the target redundant angle sequence corresponding to all cutting points, firstly analyzing the continuity and abrupt changes of the sequence to identify redundant angle abrupt change points that cause impact on robot joint movement; then introducing robot joint acceleration constraints, which are determined based on the robot's maximum joint acceleration limit, motion stability requirements, and processing efficiency threshold; using a B-spline curve fitting algorithm to smooth the redundant angle sequence, adjusting the control point parameters of the B-spline curve to ensure that the fitted redundant angle change curve meets the joint acceleration constraints while preserving the optimization characteristics of the original optimal result to the greatest extent; and generating continuous robot joint motion commands based on the smoothed redundant angle sequence.

[0018] Preferably, the residual calculation in S3 specifically involves: under the optimal posture determined in step S2, based on the dynamic parameter prediction model constructed in step S1, inputting the cutting parameters of the current cutting point and the corresponding predicted cutting force value, obtaining them through empirical formulas or simulation models for cutting force, and calculating the steady-state tool deflection amount of the tool tip under the action of cutting force through dynamic simulation. The calculation of the cutting amount takes into account the deformation contribution of multiple components such as robot joint stiffness, linkage stiffness, and reducer stiffness, while also taking into account the fluctuation effect of dynamic load during the cutting process.

[0019] Preferably, the coordinate correction and code generation in S3 specifically involves: using the mirror compensation principle, based on the steady-state tool deflection amount calculated in step S3, adjusting the original target machining coordinate points... Corrected to compensated coordinate points The corrected formula is:

[0020] ;

[0021] After the coordinate correction is completed, the redundant angles optimized in step S2 and the corrected coordinate points are combined to generate the final robot machining instruction file according to the instruction format supported by the robot controller. The file contains complete information such as joint motion parameters, end position coordinates, and cutting parameters corresponding to each cutting point, ensuring that the robot can accurately execute the optimized machining task.

[0022] Compared with the prior art, the beneficial effects of the present invention are:

[0023] 1. This invention has zero hardware cost, strong versatility, and is entirely based on software algorithms. It does not require the installation of expensive active / passive dampers or force sensors, and is suitable for various existing industrial robot processing units, which is conducive to the low-cost upgrade of old production lines.

[0024] 2. The prediction efficiency of this invention is improved by orders of magnitude. Compared with traditional global finite element simulation or intensive experiments, the modeling method based on IDW interpolation reduces the modeling time by more than 90%, making online process planning for complex surfaces possible.

[0025] 3. This invention is quality-oriented and directly addresses pain points. The optimization target is no longer the abstract stability margin, but is directly related to the surface roughness and dimensional error of the final part, which is more in line with the quality control needs of actual production.

[0026] 4. This invention maximizes the rigidity potential of the robot body through posture optimization and eliminates the remaining tool deflection error through trajectory compensation. The two work together to achieve high-precision machining. Attached Figure Description

[0027] Figure 1 This is the operation flow of the robot milling posture optimization and trajectory compensation method based on the global stiffness model of the present invention. Figure 1 ;

[0028] Figure 2 This is the operation flow of the robot milling posture optimization and trajectory compensation method based on the global stiffness model of the present invention. Figure 2 ;

[0029] Figure 3 This is the operation flow of the robot milling posture optimization and trajectory compensation method based on the global stiffness model of the present invention. Figure 3 ;

[0030] Figure 4 This is the operation flow of the robot milling posture optimization and trajectory compensation method based on the global stiffness model of the present invention. Figure 4 . Detailed Implementation

[0031] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0032] Example

[0033] Please see Figures 1-4 As shown, the present invention provides a technical solution comprising the following steps:

[0034] S1. Construct a full workspace attitude-dependent dynamic parameter prediction model through sparse sampling, multidimensional discrete testing, and spatial interpolation modeling.

[0035] S2. Based on toolpath analysis, morphology simulation, optimal search and trajectory smoothing, complete the global planning of redundant angles based on surface morphology prediction;

[0036] S3. Trajectory mirroring compensation based on prediction error through residual calculation, coordinate correction and code generation.

[0037] In this embodiment, sparse sampling in S1 specifically means: within the robot's workspace, based on the geometric boundary range of the workspace, the distribution of the core areas involved in the processing task, the constraints of the robot's joint motion range, and the potential variation law of stiffness distribution, selecting several representative spatial locations that comprehensively characterize the stiffness characteristics of the entire workspace as anchor points.

[0038] The selection of anchor points needs to meet the minimum accuracy threshold of inverse distance weighted interpolation modeling, while taking into account both modeling efficiency and prediction accuracy. Anchor points should be densified in the edge areas of the workspace, areas with potential stiffness abrupt changes, and areas with dense processing paths. The number of anchor points should be appropriately reduced in areas with relatively uniform stiffness distribution to ensure that anchor points cover the key dimensions of the workspace and the processing focus area.

[0039] In this embodiment, the multidimensional discrete test in S1 specifically involves: determining the feasible range of values ​​for the robot redundancy angle for each selected anchor point. The range of values ​​is defined based on the robot joint motion limits, link interference constraints, and machining process requirements.

[0040] Subsequently at the redundant angle Within the feasible range, the redundant angles of the robot are uniformly discretized and sampled at preset angle intervals to form several discrete redundant angle states. For the robot in each discrete state, a modal hammer test method is adopted. A force hammer is used to apply pulse excitation to a preset position of the robot's end effector, and the vibration response signal of the end effector is collected synchronously. After signal processing and analysis, the frequency response function (FRF) of the robot's end effector in each state is obtained, and the spatial position information, redundant angle parameters and corresponding frequency response function data of each anchor point are associated and stored in the database.

[0041] In this embodiment, the spatial interpolation modeling in S1 specifically involves introducing an inverse distance weighting method, such as Inverse Distance Weighting (IDW), based on the anchor point spatial location, redundant angle parameters, and corresponding frequency response functions stored in the database as the basic data.

[0042] Specifically, establishing spatial location Redundant angle With frequency response function The nonlinear mapping relationship between them is expressed as follows:

[0043] ,

[0044] in, The weight function is based on pose similarity. The weight function is calculated based on the spatial distance and redundancy angle difference between the current query pose and each anchor pose. The closer the distance and the smaller the redundancy angle difference, the larger the corresponding weight coefficient.

[0045] Specifically, a global stiffness model covering the entire workspace is generated through mapping relationships. The global stiffness model can achieve millisecond-level dynamic stiffness query and frequency response function prediction based on the input coordinates of any spatial location and redundant angular parameters, and the error of the prediction results is controlled within a preset accuracy range.

[0046] In this embodiment, the toolpath analysis in S2 specifically involves reading the toolpath file of the part to be processed, including but not limited to CL file and APT file. The toolpath file contains key information such as the tool type, cutting parameters, and theoretical toolpath coordinates for machining the part.

[0047] The key geometric features and process parameters in the toolpath are extracted by the file parsing algorithm. Then, according to the preset discretization accuracy threshold, the continuous theoretical toolpath is discretized into a series of ordered cutting point sequences. Each cutting point contains three-dimensional spatial coordinates, cutting direction vector, and complete information on the corresponding cutting parameters, such as cutting speed, feed rate, and depth of cut, to ensure that the discretized cutting point sequence can accurately reproduce the geometry and machining logic of the original toolpath.

[0048] In this embodiment, the morphology simulation in S2 specifically involves calling a pre-established surface morphology prediction model for each discretized cutting point. The input parameters of the surface morphology prediction model include cutting parameters such as cutting speed, feed rate, and cutting depth at the current cutting point, as well as the dynamic stiffness data under the current pose predicted by the global stiffness model constructed in step S1.

[0049] Specifically, the global stiffness model simulates the dynamic interaction between the cutting edge sweep surface and the workpiece blank during the cutting process through Boolean subtraction operations. Combining the material removal mechanism and vibration response characteristics, the surface morphology error SLE and surface roughness index Ra of the workpiece under the current cutting state are calculated. The surface morphology error includes multiple error components such as tool deflection deformation error caused by insufficient robot stiffness and ripple error caused by vibration. The roughness index is calculated according to the corresponding detection methods and evaluation systems of national standards.

[0050] In this embodiment, the optimal search in S2 specifically involves: at each cutting point, defining the feasible range of the redundant angle based on robot joint motion constraints, link interference avoidance conditions, and machining process requirements; then using an traversal search algorithm or intelligent optimization algorithm, such as particle swarm optimization algorithm or genetic algorithm, to comprehensively search the feasible range of the redundant angle, and for each candidate redundant angle, calculating the corresponding surface morphology error SLE through a surface morphology prediction model.

[0051] Specifically, the redundant angle that minimizes surface topography error. As an optimization objective, the target redundant angle that optimizes the machining quality at each cutting point is selected. If multiple redundant angles correspond to the same minimum error, the redundant angle that minimizes the energy consumption of the robot joint movement or makes the posture change smoothest is selected as the final target value.

[0052] In this embodiment, the trajectory smoothing in S2 specifically involves: for all the target redundant angle sequences corresponding to the cutting points, firstly analyzing the continuity and abrupt changes of the sequence to identify redundant angle abrupt change points that cause impact on the robot joint movement; then introducing robot joint acceleration constraints, which are determined based on the robot's maximum joint acceleration limit, motion stability requirements, and processing efficiency threshold.

[0053] Specifically, a B-spline curve fitting algorithm is used to smooth the redundant angle sequence. By adjusting the control point parameters of the B-spline curve, the fitted redundant angle change curve satisfies the joint acceleration constraint, while preserving the optimization characteristics of the original selection result to the greatest extent. Based on the smoothed redundant angle sequence, continuous robot joint motion commands are generated to ensure that the robot's posture changes smoothly and without impact during the processing, avoiding increased vibration or decreased processing accuracy caused by sudden posture changes.

[0054] In this embodiment, the residual calculation in S3 specifically involves: under the optimal posture determined in step S2, based on the dynamic parameter prediction model constructed in step S1, inputting the cutting parameters of the current cutting point and the corresponding predicted cutting force value, obtaining them through empirical formulas or simulation models of cutting force, and calculating the steady-state tool deflection amount of the tool tip under the action of cutting force through dynamic simulation. The calculation of the tool clearance takes into account the deformation contribution of multiple components such as robot joint stiffness, linkage stiffness, and reducer stiffness, while also taking into account the fluctuation of dynamic load during the cutting process, to ensure that the predicted tool clearance can truly reflect the magnitude of the error in actual machining.

[0055] In this embodiment, the coordinate correction and code generation in S3 specifically involves: using the mirror compensation principle, based on the steady-state tool deflection amount calculated in step S3, adjusting the original target machining coordinate points... Corrected to compensated coordinate points The corrected formula is:

[0056] ;

[0057] After the coordinate correction is completed, the redundant angles optimized in step S2 and the corrected coordinate points are combined to generate the final robot machining instruction file according to the instruction format supported by the robot controller, such as G-code or robot-specific scripting language. The file contains complete information such as joint motion parameters, end-effector position coordinates, and cutting parameters corresponding to each cutting point, ensuring that the robot can accurately execute the optimized machining task.

[0058] In this embodiment, a six-degree-of-freedom robot performs aluminum alloy planar milling:

[0059] Basic database construction:

[0060] Select above the robot workbench There are a total of 27 spatial anchor points. At each anchor point, the position of the blade tip remains unchanged, so as to... Modal testing was performed on the fourth, fifth, and sixth axes of the rotating robot at intervals (with varying redundancy angles) using a force hammer. The obtained frequency response function data was then stored in a database.

[0061] Using the IDW algorithm in step S1, construct a resolution of and A global stiffness lookup table.

[0062] Path and topography planning:

[0063] Import tool position data for a straight-line milling task. The system automatically calculates the Dynamic Response Index (DRI) for each point on the path under different redundancy angles.

[0064] Calculations revealed that when the redundant angle At that time, the robot's Lowest directional stiffness, expected surface roughness ; and adjusted to At that time, the dynamic stiffness increases by 40%, and Ra is expected to decrease. The system automatically locks the robot's pose for that section of the path at [position]. nearby.

[0065] Software error compensation:

[0066] exist Under the optimal posture, the surface morphology prediction model shows that the tool is still affected by the cutting force and shifts outward by 0.05 mm (i.e., SLE value).

[0067] The system automatically modifies the path coordinates in the G-code, shifting all points inward by 0.05mm.

[0068] Processing verification:

[0069] The generated optimized code is input into the robot controller. The machined workpiece has a smooth surface with no obvious chatter marks, and the surface roughness Ra is measured to be [perfect / ideal]. The dimensional error was controlled within 0.02 mm, which verified the effectiveness of the method.

[0070] Although embodiments of the invention have been shown and described, it will be understood by those skilled in the art that various changes, modifications, substitutions and alterations can be made to these embodiments without departing from the principles and spirit of the invention, the scope of which is defined by the appended claims and their likenesses.

[0071] The present invention and its embodiments have been described above. This description is not restrictive, and the accompanying drawings are only one embodiment of the present invention; the actual structure is not limited thereto. In conclusion, if those skilled in the art are inspired by this description and design similar structures and embodiments without departing from the spirit of the invention, such designs should fall within the protection scope of the present invention.

Claims

1. A method for robot milling posture optimization and trajectory compensation based on a global stiffness model, characterized in that, Includes the following steps: S1. Construct a full workspace attitude-dependent dynamic parameter prediction model through sparse sampling, multidimensional discrete testing, and spatial interpolation modeling. S2. Based on toolpath analysis, morphology simulation, optimal search and trajectory smoothing, complete the global planning of redundant angles based on surface morphology prediction; S3. Trajectory mirroring compensation based on prediction error through residual calculation, coordinate correction and code generation.

2. The robot milling posture optimization and trajectory compensation method based on a global stiffness model according to claim 1, characterized in that: In S1, sparse sampling specifically involves: within the robot's workspace, based on the geometric boundary range of the workspace, the distribution of the core areas involved in the processing task, the constraints of the robot's joint motion range, and the potential variation law of stiffness distribution, selecting several representative spatial locations that comprehensively characterize the stiffness characteristics of the entire workspace as anchor points; and densifying the anchor points in the edge region of the workspace, the potential region of stiffness abrupt change, and the region with dense processing paths.

3. The robot milling posture optimization and trajectory compensation method based on a global stiffness model according to claim 2, characterized in that: The multidimensional discrete test in S1 specifically involves determining the feasible range of values ​​for the robot redundancy angle for each selected anchor point. The value range is defined based on the robot joint motion limits, link interference constraints, and manufacturing process requirements; subsequently, the redundant angle... Within the feasible range, the redundant angles of the robot are uniformly discretized and sampled at preset angle intervals to form several discrete redundant angle states. For the robot in each discrete state, a modal hammer test method is adopted. A force hammer is used to apply pulse excitation to a preset position of the robot's end effector, and the vibration response signal of the end effector is collected synchronously. After signal processing and analysis, the frequency response function (FRF) of the robot's end effector in each state is obtained, and the spatial position information, redundant angle parameters and corresponding frequency response function data of each anchor point are associated and stored in the database.

4. The robot milling posture optimization and trajectory compensation method based on the global stiffness model according to claim 3, characterized in that: The spatial interpolation modeling in S1 specifically involves: introducing an inverse distance weighting method, using the anchor point spatial locations, redundant angle parameters, and corresponding frequency response functions stored in the database as basic data, to establish spatial location... Redundant angle With frequency response function The nonlinear mapping relationship between them is expressed as follows: , in, The weight function is based on pose similarity. The weight function is calculated based on the spatial distance and redundancy angle difference between the current query pose and each anchor pose. The closer the distance and the smaller the redundancy angle difference, the larger the corresponding weight coefficient.

5. The robot milling posture optimization and trajectory compensation method based on the global stiffness model according to claim 4, characterized in that: The toolpath analysis in S2 specifically involves: reading the tool position file of the part to be processed; extracting key geometric features and process parameters in the toolpath using a file parsing algorithm; and then discretizing the continuous theoretical toolpath into a series of ordered cutting point sequences according to a preset discretization accuracy threshold. Each cutting point contains complete information on three-dimensional spatial coordinates, cutting direction vector, and corresponding cutting parameters.

6. The robot milling posture optimization and trajectory compensation method based on a global stiffness model according to claim 5, characterized in that: The morphology simulation in S2 specifically involves calling a pre-established surface morphology prediction model for each discretized cutting point. The input parameters of the surface morphology prediction model include cutting parameters such as cutting speed, feed rate, and cutting depth at the current cutting point, as well as dynamic stiffness data under the current pose predicted by the global stiffness model constructed in step S1. The model simulates the dynamic interaction between the cutting edge and the workpiece blank during the cutting process through Boolean subtraction. Combining the material removal mechanism and vibration response characteristics, the surface morphology error SLE and surface roughness index Ra of the workpiece under the current cutting state are calculated.

7. The robot milling posture optimization and trajectory compensation method based on a global stiffness model according to claim 6, characterized in that: The optimal search in S2 specifically involves: at each cutting point, defining the feasible region of the redundant angle based on robot joint motion constraints, link interference avoidance conditions, and machining process requirements; then, using a comprehensive search algorithm to fully search the feasible region of the redundant angle; for each candidate redundant angle, calculating the corresponding surface topography error (SLE) using a surface topography prediction model; and finally, selecting the redundant angle that minimizes the surface topography error. As an optimization objective, the target redundant angle that optimizes the machining quality at each cutting point is selected. If multiple redundant angles correspond to the same minimum error, the redundant angle that minimizes the energy consumption of the robot joint movement or makes the posture change smoothest is selected as the final target value.

8. The robot milling posture optimization and trajectory compensation method based on a global stiffness model according to claim 7, characterized in that: The trajectory smoothing in S2 specifically involves: for the target redundant angle sequence corresponding to all cutting points, firstly analyzing the continuity and abrupt changes of the sequence to identify redundant angle abrupt change points that cause impact on robot joint movement; then introducing robot joint acceleration constraints, which are determined based on the robot's maximum joint acceleration limit, motion stability requirements, and processing efficiency threshold; using a B-spline curve fitting algorithm to smooth the redundant angle sequence, adjusting the control point parameters of the B-spline curve to ensure that the fitted redundant angle change curve meets the joint acceleration constraints while preserving the optimization characteristics of the original optimal result to the greatest extent; and generating continuous robot joint motion commands based on the smoothed redundant angle sequence.

9. The robot milling posture optimization and trajectory compensation method based on a global stiffness model according to claim 8, characterized in that: The residual calculation in S3 specifically involves: under the optimal posture determined in step S2, based on the dynamic parameter prediction model constructed in step S1, inputting the cutting parameters of the current cutting point and the corresponding predicted cutting force value, and obtaining the steady-state tool deflection amount of the tool tip under the action of the cutting force through dynamic simulation calculation. The calculation of the cutting amount takes into account the deformation contribution of multiple components such as robot joint stiffness, link stiffness, and reducer stiffness, while also taking into account the fluctuation effect of dynamic load during the cutting process.

10. The robot milling posture optimization and trajectory compensation method based on a global stiffness model according to claim 9, characterized in that: The coordinate correction and code generation in S3 specifically involve: using the mirror compensation principle, based on the steady-state tool deflection amount calculated in step S3, and adjusting the original target machining coordinate points... Corrected to compensated coordinate points The corrected formula is: ; After the coordinate correction is completed, the redundant angles optimized in step S2 and the corrected coordinate points are combined to generate the final robot machining instruction file according to the instruction format supported by the robot controller. The file contains complete information on the joint motion parameters, end position coordinates, and cutting parameters corresponding to each cutting point.