Curved surface polishing track self-adaptive generation method and device and readable storage medium
By meshing the complex surface and planning the polishing trajectory on the two-dimensional plane, combined with parameterized mapping and reference point adjustment, the problem of the inability to generate complex surface polishing trajectories in the existing technology is solved, and the efficient surface processing is achieved Accuracy.
Patent Information
- Application Number
- CN202410980482.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-22
- Publication Date
- 2024-11-12
AI Technical Summary
The existing surface polishing trajectory generation method needs to be based on the surface equation of the surface to be processed, and the polishing trajectory on complex surfaces cannot be generated, resulting in the inability to process.
By discretizing the surface to be processed, a grid model is obtained, and polishing trajectory planning is performed on the two-dimensional plane. The surface trajectory points are calculated using the parameterized mapping inverse matrix, and the European-style reference point is adjusted until the residual height is removed by polishing. Less than or equal to the preset error, generate the target polishing track.
Without the surface equation of the surface to be processed, the generation and uniform coverage of the surface polishing trajectory are achieved, solving the problem of complex surface processing and improving machining accuracy and efficiency.
Smart Images

Figure CN118940404A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of polishing trajectory planning, and in particular to a method and device for adaptively generating a curved surface polishing trajectory, and a computer-readable storage medium. Background Art
[0002] Complex curved surface parts are widely used in aerospace and automobile fields. It is very important to perform high-precision machining on curved surfaces to obtain high-precision and high-quality curved surface parts. In the process of curved surface machining, polishing trajectory planning is closely related to machining accuracy and efficiency. Good trajectory planning can ensure that the polishing tool evenly covers and adapts to areas of different curvatures and shapes during the entire machining process, thereby improving the accuracy of curved surface parts. Therefore, curved surface polishing trajectory planning is an important guarantee for high-precision machining of curved surfaces.
[0003] The existing polishing trajectory planning methods mainly include the equal parameter method, the equal section line method and the projection method. Figure 1 As shown in the figure, the isoparametric method is to parametrically represent the surface to be processed using parameters u and v. The parameters u and v usually change in a finite interval. The various points on the surface to be processed can be generated by taking different values of u and v in the finite interval. When the equation of the surface to be processed is known, the isoparametric method directly generates the polishing trajectory by extracting a parameter in any direction of u and v of the surface, substituting the parameter into the surface equation to solve another parameter; Figure 2 As shown in the figure, the principle of the equal-section method is to use a set of parallel planes to intersect with the surface to be processed in Cartesian space, and solve the intersection line of the corresponding plane and the surface to be processed as the polishing trajectory. In the actual planning process, it is necessary to first obtain the surface equation of the surface to be processed, and then solve a set of plane equations and the surface equation simultaneously to obtain the coordinate points on the intersection line of the plane and the surface as trajectory points; Figure 3 As shown in the figure, the equal residual height method selects an area in the surface to be processed and extracts the boundary points of the area as initial data. From the selected initial data, a series of equally spaced plane trajectories are generated according to the coordinate values in two directions. The generated plane trajectories are then combined with the surface equations to solve the equations to determine the corresponding trajectory points on the surface, thereby obtaining the polishing trajectory. These polishing trajectory planning methods all need to obtain the surface equation of the surface to be processed first, but for some complex surfaces, their mathematical characteristics are difficult to obtain, resulting in the inability to establish the corresponding surface equation. Therefore, for some complex surfaces where the surface equation cannot be obtained, the existing methods cannot generate corresponding polishing trajectories, resulting in the inability to process the surface to be processed.
[0004] In summary, the existing surface polishing trajectory generation methods all need to generate polishing trajectories based on the surface equation of the surface to be processed. For complex surfaces for which the surface equation cannot be obtained, the corresponding polishing trajectory cannot be generated, resulting in the inability to process the surface to be processed. Summary of the invention
[0005] To this end, the technical problem to be solved by the present invention is to overcome the problem that the surface polishing trajectory generation method in the prior art needs to be based on the surface equation of the surface to be processed to generate the polishing trajectory. For complex surfaces for which the surface equation cannot be obtained, the corresponding polishing trajectory cannot be generated, which leads to the inability to process the surface to be processed.
[0006] In order to solve the above technical problems, the present invention provides a method for adaptively generating a curved surface polishing trajectory, comprising:
[0007] Discretizing the surface to be processed to obtain a mesh model of the surface to be processed, and extracting the vertex coordinates of each triangular mesh in the mesh model;
[0008] Mapping each triangular mesh in the mesh model to a two-dimensional plane to obtain a target triangular mesh corresponding to the triangular mesh, and acquiring vertex coordinates of the target triangular mesh;
[0009] Performing polishing trajectory planning on the two-dimensional plane to obtain an initial polishing trajectory, obtaining a target triangular mesh where each plane trajectory point on the initial polishing trajectory is located, and calculating a parameterized mapping inverse matrix of the target triangular mesh based on vertex coordinates of the target triangular mesh and vertex coordinates of a triangular mesh corresponding to the target triangular mesh;
[0010] Based on the coordinates of each plane trajectory point and the inverse matrix of the parameterized mapping of the target triangular mesh where the plane trajectory point is located, the coordinates of the plane trajectory point on the mesh model are calculated to obtain the surface trajectory point corresponding to the plane trajectory point;
[0011] For each surface trajectory point, on a surface trajectory adjacent to the surface trajectory where the surface trajectory point is located, a surface trajectory point with the closest Euclidean distance to the surface trajectory point is selected as a reference point, and the surface trajectory point is adjusted until the polishing removal residual height between the surface trajectory point and the reference point is less than or equal to a preset residual error, thereby obtaining a target surface trajectory point corresponding to the surface trajectory point;
[0012] The target polishing trajectory of the surface to be processed is obtained based on the target surface trajectory points corresponding to all the surface trajectory points.
[0013] Preferably, mapping each triangular mesh in the mesh model to a two-dimensional plane to obtain a target triangular mesh corresponding to the triangular mesh comprises:
[0014] Based on the total amount of changes in the internal angles of all triangle meshes in the mesh model before and after mapping, a triangle mesh angle deformation energy function is constructed;
[0015] Constructing a triangle mesh mapping model based on the triangle mesh angle deformation energy function, the triangle mesh validity constraint function, the validity constraint function and the reconstruction validity constraint function;
[0016] The triangular mesh mapping model is solved to obtain the triangular mesh internal angle mapping scale coefficient, and the internal angles of each triangular mesh in the mesh model are mapped based on the triangular mesh internal angle mapping scale coefficient, so as to map the triangular mesh to a two-dimensional plane and obtain a target triangular mesh corresponding to the triangular mesh.
[0017] Preferably, the triangle angle deformation energy function is:
[0018]
[0019] Where E(α) represents the triangle angle deformation energy function; I represents the number of triangle meshes; Represents the angle of the jth internal angle of the i-th triangle mesh before mapping; Represents the angle after mapping the jth internal angle of the i-th triangle mesh; represents the deformation energy weight of the jth internal angle of the i-th triangle mesh;
[0020] The validity constraint function of the triangle mesh is:
[0021]
[0022] Among them, C Tri (i) represents the triangle mesh validity constraint function of the i-th triangle mesh; Represents the angle of the first internal angle of the i-th triangle mesh before mapping; Represents the angle of the second inner angle of the i-th triangle mesh before mapping; It represents the angle of the third inner angle of the i-th triangle mesh before mapping; I represents the number of triangle meshes in the mesh model;
[0023] The plane validity constraint function is:
[0024]
[0025] Among them, C Plan (v) represents the plane validity constraint function of the vth vertex; v * represents the interior angles of all triangles adjacent to vertex v; V intRepresents the vertex set of all triangle meshes in the mesh model;
[0026] The reconstruction validity constraint function is:
[0027]
[0028] Among them, C Len (v) represents the reconstruction validity constraint function of the vth vertex;
[0029] The triangle mesh mapping model is expressed as:
[0030]
[0031] Where F(x) represents the triangle mesh mapping model; λ Tri Lagrange multiplier representing the validity constraint function of the triangular mesh; λ Plan represents the Lagrange multiplier of the plane validity constraint function; λ Len Lagrange multiplier representing the reconstruction validity constraint function; The Lagrange multiplier representing the triangle mesh validity constraint function of the i-th triangle mesh; Lagrange multiplier representing the plane validity constraint function of the vth vertex; Lagrange multiplier representing the reconstruction validity constraint function of the vth vertex.
[0032] Preferably, the calculation formula of the parameterized mapping inverse matrix of the target triangular mesh is:
[0033]
[0034] Among them, T represents the parameterized mapping inverse matrix of the target triangular mesh; A represents the first matrix constructed based on the vertex coordinates of the target triangular mesh; B represents the second matrix constructed based on the vertex coordinates of the triangular mesh corresponding to the target triangular mesh; (x1, y1, 0) represents the coordinates of the first vertex of the target triangular mesh; (x2, y2, 0) represents the coordinates of the second vertex of the target triangular mesh; (x3, y3, 0) represents the coordinates of the third vertex of the target triangular mesh; (X1, Y1, Z1) represents the coordinates of the first vertex of the triangular mesh corresponding to the target triangular mesh; (X2, Y2, Z2) represents the coordinates of the second vertex of the triangular mesh corresponding to the target triangular mesh; (X3, Y3, Z3) represents the coordinates of the third vertex of the triangular mesh corresponding to the target triangular mesh.
[0035] Preferably, the curved surface trajectory point corresponding to the plane trajectory point is expressed as:
[0036]
[0037] in, represents the surface trajectory point corresponding to the plane trajectory point p; (x, y, 1) represents the coordinates of the plane trajectory point p.
[0038] Preferably, the curved surface trajectory point is adjusted until the polishing removal residual height between the curved surface trajectory point and the reference point is less than or equal to a preset residual error, and obtaining the target curved surface trajectory point corresponding to the curved surface trajectory point includes:
[0039] Step 1: Calculate the polishing removal residual height between the surface trajectory point and the reference point, and determine the magnitude of the polishing removal residual height and a preset residual error;
[0040] Step 2: if the polishing removal residual height is greater than the preset residual error, setting the left boundary point and the right boundary point of the material removal profile at the reference point based on the polishing contact circle diameter at the reference point;
[0041] Step 3: Calculate the current line spacing using the left boundary point and the right boundary point of the material removal profile at the dichotomy reference point, and obtain a search vector by cross-producting the polishing tool forward direction at the reference point and the normal vector at the reference point, map the search vector to the two-dimensional plane to obtain a target search vector, and select a target plane trajectory point on the target search vector;
[0042] Step 4: Based on the coordinates of the target plane trajectory point and the parameterized mapping inverse matrix of the target triangular mesh where the target plane trajectory point is located, the coordinates of the target plane trajectory point on the mesh model are calculated to obtain the updated surface trajectory point, and the maximum material removal depth at the updated surface trajectory point is calculated;
[0043] Step 5: Determine whether the material removal profile of the updated surface trajectory point and the material removal profile at the reference point have an intersection. If no intersection exists, set the right boundary point of the material removal profile at the reference point equal to the current line spacing, and return to step 3 until the material removal profile of the updated surface trajectory point and the material removal profile at the reference point have an intersection.
[0044] Step 6: Determine whether the intersection of the material removal profile of the updated surface trajectory point and the material removal profile at the reference point is on the side of the reference point away from the surface trajectory point before the update; if not, set the left boundary point of the material removal profile at the reference point equal to the current line spacing, and return to step 3 until the intersection of the material removal profile of the updated surface trajectory point and the material removal profile at the reference point is on the side of the reference point away from the surface trajectory point before the update;
[0045] Step 7: Determine the size of the polishing removal residual height between the updated surface trajectory point and the reference point and the preset residual error. If the polishing removal residual height between the updated surface trajectory point and the reference point is greater than the preset residual error, set the right boundary point of the material removal profile at the reference point equal to the current line spacing, and return to step 3 until the polishing removal residual height between the updated surface trajectory point and the reference point is less than or equal to the preset residual error, and use the updated surface trajectory point as the target surface trajectory point.
[0046] Preferably, the calculation formula for the polishing removal residual height between the curved surface trajectory point and the reference point is:
[0047]
[0048] Wherein, δ represents the polishing removal residual height between the surface trajectory point and the reference point; d1 represents the maximum material removal depth at the surface trajectory point; d2 represents the maximum material removal depth at the reference point; L represents the distance between the center of the polishing circle at the surface trajectory point and the center of the polishing circle at the reference point; d L represents the intersection function value of the material removal depth function at L at the surface trajectory point and the reference point; x represents the x coordinate of the intersection of the material removal contour at the surface trajectory point and the material removal contour at the reference point.
[0049] Preferably, after extracting the vertex coordinates of each triangular mesh in the mesh model, the method further includes performing redundancy removal processing on the vertex coordinates of all the extracted triangular meshes, which specifically includes:
[0050] Initialize i=1;
[0051] Determine whether the vertex coordinates of the i-th triangle mesh coincide with the vertex coordinates contained in the first container;
[0052] If the vertex coordinates of the i-th triangle mesh coincide with the vertex coordinates contained in the first container, remove the vertex coordinates of the i-th triangle mesh that coincide with those in the first container, and determine whether the edge of the i-th triangle mesh coincides with the edge contained in the second container;
[0053] If the edge of the i-th triangular mesh coincides with the edge contained in the second container, the edge in the i-th triangular mesh that coincides with the edge in the second container is removed;
[0054] The remaining vertex coordinates of the i-th triangle mesh are stored in the first container in rows, and the row number of each vertex coordinate is used as the index value of the vertex coordinate;
[0055] Combine the index values of the two vertex coordinates corresponding to each remaining edge of the i-th triangular mesh as the data representation of the edge, and store the data representations of the remaining edges of the i-th triangular mesh in a row-by-row manner in the second container, and use the row number of the data representation of each edge as the index value of the edge;
[0056] Store the index values of the remaining vertex coordinates, the index values of the remaining edges and the normal vector of the i-th triangle mesh into a third container;
[0057] Update i=i+1, and return to determine whether the vertex coordinates of the i-th triangle mesh coincide with the vertex coordinates contained in the first container, until i=I, where I represents the number of triangle meshes in the mesh model.
[0058] The present invention also provides a device for adaptively generating a curved surface polishing trajectory, comprising:
[0059] A surface discretization module is used to discretize the surface to be processed, obtain a mesh model of the surface to be processed, and extract the vertex coordinates of each triangular mesh in the mesh model;
[0060] A mesh mapping module, used to map each triangular mesh in the mesh model to a two-dimensional plane, obtain a target triangular mesh corresponding to the triangular mesh, and obtain vertex coordinates of the target triangular mesh;
[0061] A parameterized inverse matrix calculation module is used to perform polishing trajectory planning on the two-dimensional plane to obtain an initial polishing trajectory, obtain a target triangular mesh where each plane trajectory point on the initial polishing trajectory is located, and calculate a parameterized mapping inverse matrix of the target triangular mesh based on the vertex coordinates of the target triangular mesh and the vertex coordinates of the triangular mesh corresponding to the target triangular mesh;
[0062] A trajectory point mapping module, used to calculate the coordinates of each plane trajectory point on the mesh model based on the coordinates of each plane trajectory point and the parameterized mapping inverse matrix of the target triangular mesh where the plane trajectory point is located, and obtain the surface trajectory point corresponding to the plane trajectory point;
[0063] A surface trajectory point adjustment module is used to select, for each surface trajectory point, a surface trajectory point with the closest Euclidean distance to the surface trajectory point on a surface trajectory adjacent to the surface trajectory where the surface trajectory point is located as a reference point, and adjust the surface trajectory point until the polishing removal residual height between the surface trajectory point and the reference point is less than or equal to a preset residual error, thereby obtaining a target surface trajectory point corresponding to the surface trajectory point;
[0064] The target polishing trajectory acquisition module is used to obtain the target polishing trajectory of the surface to be processed based on the target surface trajectory points corresponding to all the surface trajectory points.
[0065] The present invention also provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the steps of the above-mentioned method for adaptively generating a curved surface polishing trajectory are implemented.
[0066] The method for adaptively generating a curved surface polishing trajectory provided by the present application discretizes the surface to be processed, obtains a mesh model composed of multiple triangular meshes, then performs parameterized processing on each triangular mesh and maps it to a two-dimensional plane, obtains a two-dimensional plane composed of multiple target triangular meshes, and obtains an initial polishing trajectory by performing polishing trajectory planning on the two-dimensional plane; based on the parameterized mapping inverse matrix of the target triangular mesh where each plane trajectory point is located, maps the plane trajectory point to the mesh model to obtain a curved surface trajectory point; by reducing the dimension of the mesh model, performing trajectory planning on the plane after the dimension reduction, and then mapping the plane trajectory point back to the mesh model, the generation of the curved surface is ensured. Each trajectory point generated is the polishing trajectory point actually required on the surface to be processed; at the same time, in order to avoid the problem that the trajectory points generated on the plane cannot adapt to the curvature of the surface, for each surface trajectory point, the present application selects the surface trajectory point with the closest Euclidean distance to the surface trajectory point as the reference point on the surface trajectory adjacent to the surface trajectory where the surface trajectory point is located, and adjusts the surface trajectory point until the polishing removal residual height between the surface trajectory point and the reference point is less than or equal to the preset residual error. In combination with the material removal problem in the polishing process, the trajectory points are optimized, thereby realizing the generation and uniform coverage of the surface polishing trajectory without the surface equation of the surface to be processed. BRIEF DESCRIPTION OF THE DRAWINGS
[0067] In order to make the content of the present invention more clearly understood, the present invention is further described in detail below according to specific embodiments of the present invention in conjunction with the accompanying drawings, wherein:
[0068] Figure 1 Schematic diagram of the machining trajectory planning principle of the equal parameter method provided in this application;
[0069] Figure 2 Schematic diagram of the trajectory planning principle of the equal-section method provided for this application;
[0070] Figure 3 Schematic diagram of the trajectory planning principle of the equal residual height method provided for this application;
[0071] Figure 4 A flow chart of the method for adaptively generating a curved surface polishing trajectory provided in this application;
[0072] Figure 5 Schematic diagram of triangle validity constraint function and plane validity constraint function provided by this application;
[0073] Figure 6 A schematic diagram of the correction of the triangular mesh mapping result by the reconstruction validity constraint function provided in this application; wherein, Figure 6 (a) is a schematic diagram of the reconstruction validity constraint function. Figure 6 (b) is a schematic diagram of the corrected triangle mesh mapping result;
[0074] Figure 7 A schematic diagram of the curved surface trajectory points obtained by mapping the plane trajectory points on the initial polishing trajectory provided in the present application to the grid model;
[0075] Figure 8 Schematic diagram of the first container, the second container and the third container provided for this application;
[0076] Fig. 9 A schematic diagram of the principle of removing redundancy of triangle mesh vertex coordinates in a mesh model provided by the present application; wherein, Fig. 9 (a) is a schematic diagram showing that the current triangle mesh and the stored triangle mesh have no common points and common edges. Fig. 9 (b) is a schematic diagram showing that the current triangle mesh and the stored triangle mesh have a common point. Fig. 9 (c) is a schematic diagram showing that the current triangle mesh and the stored triangle mesh have two common points. Fig. 9 (d) is a schematic diagram showing that the current triangle mesh and the stored triangle mesh have two common points and one common edge. Fig. 9 (e) is a schematic diagram showing that the current triangle mesh and the stored triangle mesh have three common points. Fig. 9 (f) is a schematic diagram showing that the current triangle mesh and the stored triangle mesh have three common points and one common edge. Fig. 9 (g) is a schematic diagram showing that the current triangle mesh and the stored triangle mesh have three common points and two common edges. Fig. 9 (h) is a schematic diagram showing that the current triangle mesh and the stored triangle mesh have three common points and three common edges;
[0077] Fig.10 A schematic diagram of the coordinates of the triangle mesh vertices before and after redundancy removal provided in this application; wherein, Fig.10 (a) is a schematic diagram of the coordinates of the triangle mesh vertices after redundancy removal. Fig.10 (b) is a schematic diagram of the coordinates of the triangle mesh vertices before de-redundancy;
[0078] Fig.11 A schematic diagram of the principle of the method for adaptively generating a curved surface polishing trajectory provided in this application;
[0079] Fig.12A schematic diagram of a curved surface polishing trajectory generated using the method provided in this application;
[0080] Fig.13 This is a schematic diagram of the structure of the device for adaptively generating curved surface polishing trajectories provided in this application. DETAILED DESCRIPTION
[0081] The present invention is further described below in conjunction with the accompanying drawings and specific embodiments so that those skilled in the art can better understand the present invention and implement it, but the embodiments are not intended to limit the present invention.
[0082] See also Figure 4 , Figure 4 The present invention provides a flow chart of a method for adaptively generating a curved surface polishing trajectory, which specifically includes:
[0083] S10: discretizing the surface to be processed to obtain a mesh model of the surface to be processed, and extracting the vertex coordinates of each triangular mesh in the mesh model;
[0084] S20: Map each triangular mesh in the mesh model to a two-dimensional plane to obtain a target triangular mesh corresponding to the triangular mesh, and obtain vertex coordinates of the target triangular mesh;
[0085] S30: performing polishing trajectory planning on a two-dimensional plane to obtain an initial polishing trajectory, obtaining a target triangular mesh where each plane trajectory point on the initial polishing trajectory is located, and calculating a parameterized mapping inverse matrix of the target triangular mesh based on vertex coordinates of the target triangular mesh and vertex coordinates of a triangular mesh corresponding to the target triangular mesh;
[0086] S40: based on the coordinates of each plane trajectory point and the parameterized mapping inverse matrix of the target triangular mesh where the plane trajectory point is located, the coordinates of the plane trajectory point on the mesh model are calculated to obtain the surface trajectory point corresponding to the plane trajectory point;
[0087] S50: for each surface trajectory point, on a surface trajectory adjacent to the surface trajectory where the surface trajectory point is located, a surface trajectory point with the closest Euclidean distance to the surface trajectory point is selected as a reference point, and the surface trajectory point is adjusted until the polishing removal residual height between the surface trajectory point and the reference point is less than or equal to a preset residual error, thereby obtaining a target surface trajectory point corresponding to the surface trajectory point;
[0088] Specifically, the initial polishing trajectory is composed of I-circle polishing trajectory. After mapping the plane trajectory points on the initial polishing trajectory, I-circle surface trajectory will be obtained accordingly. Therefore, for each surface trajectory point, on the surface trajectory adjacent to the surface trajectory where the surface trajectory point is located, the surface trajectory point with the closest Euclidean distance to the surface trajectory point is selected as the reference point;
[0089] For example, for the jth surface trajectory point on the i-th surface trajectory, a surface trajectory point with the closest Euclidean distance to the jth surface trajectory point on the i-th surface trajectory is selected on the i-1th surface trajectory as the reference point of the jth surface trajectory point on the i-th surface trajectory;
[0090] S60: Obtaining a target polishing trajectory of the surface to be processed based on the target surface trajectory points corresponding to all the surface trajectory points.
[0091] The method for adaptively generating a curved surface polishing trajectory provided by the present application discretizes the surface to be processed, obtains a mesh model composed of multiple triangular meshes, then performs parameterized processing on each triangular mesh and maps it to a two-dimensional plane, obtains a two-dimensional plane composed of multiple target triangular meshes, and obtains an initial polishing trajectory by performing polishing trajectory planning on the two-dimensional plane; based on the parameterized mapping inverse matrix of the target triangular mesh where each plane trajectory point is located, maps the plane trajectory point to the mesh model to obtain a curved surface trajectory point; by reducing the dimension of the mesh model, performing trajectory planning on the plane after the dimension reduction, and then mapping the plane trajectory point back to the mesh model, the generation of the curved surface is ensured. Each trajectory point generated is the polishing trajectory point actually required on the surface to be processed; at the same time, in order to avoid the problem that the trajectory points generated on the plane cannot adapt to the curvature of the surface, for each surface trajectory point, the present application selects the surface trajectory point with the closest Euclidean distance to the surface trajectory point as the reference point on the surface trajectory adjacent to the surface trajectory where the surface trajectory point is located, and adjusts the surface trajectory point until the polishing removal residual height between the surface trajectory point and the reference point is less than or equal to the preset residual error. In combination with the material removal problem in the polishing process, the trajectory points are optimized, thereby realizing the generation and uniform coverage of the surface polishing trajectory without the surface equation of the surface to be processed.
[0092] Further, in some embodiments of the present application, the specific implementation process of step S20 includes:
[0093] S200: constructing a triangle mesh angle deformation energy function based on the total amount of changes of the inner angles of all triangle meshes in the mesh model before and after mapping;
[0094] Specifically, the triangle angle deformation energy function is:
[0095] E(α)=∑ i I =1 ∑ j 3 =1 (α j i -φ j i ) 2w j i ,
[0096]
[0097] Where E(α) represents the triangle angle deformation energy function; I represents the number of triangle meshes; Represents the angle of the jth internal angle of the i-th triangle mesh before mapping; Represents the angle after mapping the jth internal angle of the i-th triangle mesh; represents the deformation energy weight of the jth internal angle of the i-th triangle mesh;
[0098] S201: constructing a triangle mesh mapping model based on a triangle mesh angle deformation energy function, a triangle mesh validity constraint function, a validity constraint function, and a reconstruction validity constraint function;
[0099] Specifically, the triangle mesh validity constraint function is:
[0100]
[0101] Among them, C Tri (i) represents the triangle mesh validity constraint function of the i-th triangle mesh; Represents the angle of the first internal angle of the i-th triangle mesh before mapping; Represents the angle of the second inner angle of the i-th triangle mesh before mapping; It represents the angle of the third inner angle of the i-th triangle mesh before mapping; I represents the number of triangle meshes in the mesh model;
[0102] The plane validity constraint function is:
[0103]
[0104] Among them, C Plan (v) represents the plane validity constraint function of the vth vertex; v * represents the interior angles of all triangles adjacent to vertex v; V int Represents the vertex set of all triangle meshes in the mesh model;
[0105] The reconstruction validity constraint function is:
[0106]
[0107] Among them, C Len (v) represents the reconstruction validity constraint function of the vth vertex;
[0108] The triangle mesh mapping model is expressed as:
[0109]
[0110] Where F(x) represents the triangle mesh mapping model; λ Tri Lagrange multiplier representing the validity constraint function of the triangular mesh; λ Plan represents the Lagrange multiplier of the plane validity constraint function; λ Len Lagrange multiplier representing the reconstruction validity constraint function; The Lagrange multiplier representing the triangle mesh validity constraint function of the i-th triangle mesh; Lagrange multiplier representing the plane validity constraint function of the vth vertex; The Lagrange multiplier representing the reconstruction validity constraint function of the vth vertex;
[0111] S202: Solving the triangular mesh mapping model to obtain a triangular mesh internal angle mapping ratio coefficient, and mapping each internal angle of each triangular mesh in the mesh model based on the triangular mesh internal angle mapping ratio coefficient, thereby mapping the triangular mesh to a two-dimensional plane to obtain a target triangular mesh corresponding to the triangular mesh;
[0112] Specifically, Figure 5 As shown, the triangle mesh validity constraint function is used to ensure that the mapped internal angle data belongs to the same triangle mesh, and the plane validity constraint function is used to avoid missing all triangle meshes that coincide with any vertex during the mapping process; Figure 6 As shown in (a) in the figure, the reconstruction validity constraint function is used to constrain the edge length of the mapped target triangle mesh so as to reduce the distortion of the triangle mesh during the mapping process. That is, the triangle mesh is always in a closed state during the mapping process, as shown in Figure 6 (b) is a schematic diagram of the triangular mesh mapping result after being corrected by the reconstruction validity constraint function. Specifically, Figure 6 In (b), when l1=l6, we can get:
[0113] Specifically, when solving the triangular mesh mapping model, the constraint relationship in the above model is converted into a linear constraint by the Lagrange expansion method. First, the actual angle value of any triangular mesh interior angle before and after mapping can be calculated by the following formula:
[0114]
[0115] in, Represents the angle after mapping the jth internal angle of the i-th triangle mesh; Represents the angle of the jth internal angle of the i-th triangle mesh before mapping; express and The minimum difference of
[0116] Function Performing Taylor expansion and omitting higher-order quantities yields:
[0117]
[0118] The triangle angle deformation energy function can be transformed into the problem of solving the minimum value between the angle before and after the mapping of the internal angle of the triangle mesh, as shown in the following formula:
[0119]
[0120] make Simplify to get the linear equation Set the parameters at the same time At this time, solving the triangular mesh mapping model can be converted into solving r i According to the above formula, we can get the minimum value problem of:
[0121] e=D α r,
[0122] Among them, D α is a diagonal matrix At this point, the equation Ae=b can be further expressed as:
[0123] AD α r = b,
[0124] AD α =C, we can get the linear equation Cr = b, which has a unique analytical value:
[0125] r=C T (CC T ) -1 b,
[0126] Let x = (C T ) -1 r, solve the linear equation (CC T )x=b, the numerical relationship between the angle of the triangle mesh before mapping and the angle after mapping can be obtained, and the angle of the inner angle of all triangle meshes in the mesh model after mapping can be further obtained by combining the Newton iteration method;
[0127] Optionally, in some embodiments of the present application, a triangular mesh may be randomly selected in the mesh model as a reference triangular mesh. Assume that the internal angle of the reference triangular mesh after mapping is Then the relationship between the side lengths of the base triangle mesh after mapping is:
[0128]
[0129] Transform the above formula using the triangle mesh vertices to obtain:
[0130]
[0131] The above formula is a linear system, and the unknowns are the x and y coordinates of the vertices in the two-dimensional plane. For each triangular mesh, given the positions and angles of two vertices, the coordinates of the third vertex can be uniquely derived. Therefore, it is necessary to determine the coordinates of any two vertices after mapping each triangular mesh to remove the degrees of freedom of the linear system and obtain a unique solution.
[0132] like Figure 7 The figure shows a schematic diagram of mapping the plane track points on the initial polishing track to the mesh model to obtain the surface track points. Specifically, in this embodiment, the specific steps of parameterizing the inverse matrix of the target triangular mesh include:
[0133] Assuming the vertex coordinates of the target triangle mesh are p1(x1,y1), p2(x2,y2), and p3(x3,y3), use the vertex coordinates to construct the first matrix:
[0134]
[0135] The vertex coordinates of the triangle mesh corresponding to the target triangle mesh are P1(X1, Y1, Z1), P2(X2, Y2, Z2), and P3(X3, Y3, Z3). Construct the second matrix:
[0136]
[0137] Inverse mapping of the two-dimensional plane to the mesh model using the equation AT = B Describe it as follows, where T is the inverse matrix of the parameterized mapping. Based on the inverse matrix of the parameterized mapping, the coordinates of any plane trajectory point on the target triangle mesh on the mesh model (i.e., the coordinates of the surface trajectory point) can be calculated:
[0138]
[0139] in, represents the surface trajectory point corresponding to the plane trajectory point p; (x, y, 1) represents the coordinates of the plane trajectory point p;
[0140] Optionally, in some embodiments, considering the nonlinear characteristics of the transformation from a two-dimensional plane to a mesh model, a singular matrix may exist in the solution of the parameterized mapping inverse matrix, resulting in an unsolvable situation in the equation calculation. Therefore, the pseudo-inverse matrix of the parameterized mapping inverse matrix may be solved as the optimal solution of the equation. Specifically, the objective function is first defined as:
[0141] f tar =min‖AT-B‖ 2 ,
[0142] The singular value decomposition result of matrix A is A=UΣV -1 , where U is a 3×3 orthogonal matrix, matrix Σ is a 3×3 diagonal matrix (elements on the diagonal of matrix Σ are singular values), V -1 is the 3×3 conjugate transposed matrix, that is, the inverse matrix of matrix V; then the parameterized mapping inverse matrix can be expressed as:
[0143] T=V∑ + U -1 B.
[0144] Further, in some embodiments of the present application, the surface trajectory point is adjusted in step S50 until the polishing removal residual height between the surface trajectory point and the reference point is less than or equal to a preset residual error, and the target surface trajectory point corresponding to the surface trajectory point is obtained, including:
[0145] Step 1: Calculate the polishing removal residual height between the surface trajectory point and the reference point, and determine the magnitude of the polishing removal residual height and the preset residual error;
[0146] Step 2: If the polishing removal residual height is greater than the preset residual error, the left boundary point and the right boundary point of the material removal profile at the reference point are set based on the polishing contact circle diameter at the reference point;
[0147] Specifically, the left boundary point B of the material removal profile at the reference point in step 2 L =0, right boundary point B R =2W, W represents the diameter of the polishing contact area under dynamic contact state;
[0148] Step 3: Calculate the current line distance using the left boundary point and the right boundary point of the material removal profile at the dichotomy reference point, and obtain a search vector by cross-producting the polishing tool forward direction at the reference point and the normal vector at the reference point, map the search vector to the two-dimensional plane to obtain a target search vector, and select a target plane trajectory point on the target search vector;
[0149] Specifically, the calculation formula for the current line spacing is: L = (B L +B R ) / 2;
[0150] Step 4: Based on the coordinates of the target plane trajectory point and the parameterized mapping inverse matrix of the target triangular mesh where the target plane trajectory point is located, the coordinates of the target plane trajectory point on the mesh model are calculated to obtain the updated surface trajectory point, and the maximum material removal depth at the updated surface trajectory point is calculated;
[0151] Step 5: Determine whether the material removal contour of the updated surface trajectory point and the material removal contour at the reference point have an intersection. If no intersection exists, set the right boundary point of the material removal contour at the reference point equal to the current line spacing, and return to step 3 until the material removal contour of the updated surface trajectory point and the material removal contour at the reference point have an intersection.
[0152] Step 6: Determine whether the intersection of the material removal contour of the updated surface trajectory point and the material removal contour at the reference point is on the side of the reference point away from the surface trajectory point before the update. If not, set the left boundary point of the material removal contour at the reference point equal to the current line spacing, and return to step 3 until the intersection of the material removal contour of the updated surface trajectory point and the material removal contour at the reference point is on the side of the reference point away from the surface trajectory point before the update.
[0153] Step 7: Determine the size of the polishing removal residual height between the updated surface trajectory point and the reference point and the preset residual error. If the polishing removal residual height between the updated surface trajectory point and the reference point is greater than the preset residual error, set the right boundary point of the material removal profile at the reference point equal to the current line spacing, and return to step 3 until the polishing removal residual height between the updated surface trajectory point and the reference point is less than or equal to the preset residual error, and use the updated surface trajectory point as the target surface trajectory point.
[0154] Specifically, the calculation formula for the polishing removal residual height between the surface trajectory point and the reference point is:
[0155]
[0156] Wherein, δ represents the polishing removal residual height between the surface trajectory point and the reference point; d1 represents the maximum material removal depth at the surface trajectory point; d2 represents the maximum material removal depth at the reference point; L represents the distance between the center of the polishing circle at the surface trajectory point and the center of the polishing circle at the reference point; d L represents the intersection function value of the material removal depth function at L at the surface trajectory point and the reference point; x represents the x coordinate of the intersection of the material removal contour at the surface trajectory point and the material removal contour at the reference point.
[0157] In the embodiment of the present application, a material removal depth function is used to calculate the maximum material removal depth at the trajectory point and the reference point. The material removal depth function is expressed as:
[0158]
[0159] Where h(x) represents the material removal depth function; k abr represents the dimensionless wear constant in Akkad's wear law; V represents the relative sliding velocity at any position in the polishing contact area; Hv Indicates the surface hardness of the surface to be processed; v f represents the feed rate; W represents the polishing contact area diameter under dynamic contact state; F n Represents the contact force applied in the normal direction of the surface to be processed; E * represents the contact elastic modulus; R represents the curvature function, which is determined by the principal curvature ρ of the polishing tool 11 and polishing tool secondary curvature ρ 12 , and the principal curvature ρ of the surface at the trajectory point 21 and the curvature at the trajectory point is the secondary curvature ρ 22 Determine; k and ε are empirical parameters.
[0160] Since there are a large number of triangular meshes in the mesh model, in order to reduce the amount of calculation for mapping the triangular meshes to the two-dimensional plane and avoid the problem of too long calculation cycle caused by too many triangular meshes, in some embodiments of the present application, after extracting the vertex coordinates of each triangular mesh in the mesh model, it also includes de-redundancy processing of the vertex coordinates of all the extracted triangular meshes, which specifically includes:
[0161] Initialize i=1;
[0162] Determine whether the vertex coordinates of the i-th triangle mesh coincide with the vertex coordinates contained in the first container;
[0163] If the vertex coordinates of the i-th triangle mesh coincide with the vertex coordinates contained in the first container, remove the vertex coordinates of the i-th triangle mesh that coincide with those in the first container, and determine whether the edge of the i-th triangle mesh coincides with the edge contained in the second container;
[0164] If the edge of the i-th triangular mesh coincides with the edge contained in the second container, the edge in the i-th triangular mesh that coincides with the edge in the second container is removed;
[0165] The remaining vertex coordinates of the i-th triangle mesh are stored in the first container in rows, and the row number of each vertex coordinate is used as the index value of the vertex coordinate;
[0166] Combine the index values of the two vertex coordinates corresponding to each remaining edge of the i-th triangular mesh as the data representation of the edge, and store the data representations of the remaining edges of the i-th triangular mesh in a row-by-row manner in the second container, and use the row number of the data representation of each edge as the index value of the edge;
[0167] Store the index values of the remaining vertex coordinates, the index values of the remaining edges and the normal vector of the i-th triangle mesh into a third container;
[0168] Update i=i+1, and return to determine whether the vertex coordinates of the i-th triangle mesh coincide with the vertex coordinates contained in the first container, until i=I, where I represents the number of triangle meshes in the mesh model.
[0169] For example, Figure 8 Shown are schematic diagrams of a first container, a second container, and a third container; Fig. 9 The figure shows the principle of removing redundancy of the triangle mesh vertex coordinates in the mesh model; Fig. 9 (a) is a schematic diagram showing that the current triangle mesh and the stored triangle mesh have no common points and common edges. Fig. 9 (b) is a schematic diagram showing that the current triangle mesh and the stored triangle mesh have a common point. Fig. 9 (c) is a schematic diagram showing that the current triangle mesh and the stored triangle mesh have two common points. Fig. 9 (d) is a schematic diagram showing that the current triangle mesh and the stored triangle mesh have two common points and one common edge. Fig. 9 (e) is a schematic diagram showing that the current triangle mesh and the stored triangle mesh have three common points. Fig. 9 (f) is a schematic diagram showing that the current triangle mesh and the stored triangle mesh have three common points and one common edge. Fig. 9 (g) is a schematic diagram showing that the current triangle mesh and the stored triangle mesh have three common points and two common edges. Fig. 9 (h) is a schematic diagram showing that the current triangle mesh and the stored triangle mesh have three common points and three common edges; Fig.10 The figure shows the coordinate diagram of the triangle mesh vertices before and after redundancy removal; Fig.10 (a) is a schematic diagram of the coordinates of the triangle mesh vertices after redundancy removal. Fig.10 (b) is a schematic diagram of the coordinates of the triangle mesh vertices before de-redundancy;
[0170] from Fig.10 As can be seen from (a) in the figure, after removing redundancy, there are 5 vertex data remaining, which are represented by index values 1, 2, 3, 4, and 5 respectively. The vertex coordinate index values are arranged counterclockwise. First, according to the index values of the triangle mesh vertices [[1,2,5],[2,3,5],[3,4,5],[4,1,5]], Fig.10As can be seen from (b) in the figure, before de-redundancy, each triangle mesh is marked according to the vertex coordinate index value, and 12 marking matrices are obtained: [1,2], [2,3], [5,1], [2,3], [3,5], [5,2], [3,4], [4,5], [5,3], [4,1], [1,5], [5,4]. The repeated matrices in the marking matrix are eliminated according to whether the elements are repeated, and the marking matrix representing the boundary line is obtained: [1,2], [2,3], [3,4], [1,4]. According to the correspondence between the index value and the vertex coordinates in the marking matrix, the index values 1, 2, 3, 4 corresponding to the boundary points can be further obtained.
[0171] See also Fig.11 , Fig.11 The schematic diagram of the principle of the adaptive generation method of surface polishing trajectory provided in the present application performs parameterization on the de-redundant triangular mesh to reduce the dimensionality of the three-dimensional surface to a two-dimensional plane; generates a plane trajectory in the two-dimensional plane, and maps the two-dimensional trajectory points back to the three-dimensional mesh surface by solving the inverse matrix of the parameterized mapping matrix to obtain the surface trajectory; combines the material depth removal function to determine whether the actual residual height value of material removal between any adjacent polishing trajectories on the surface trajectory on the three-dimensional mesh meets the requirements, and further calculates the adjustment amplitude and adjustment direction required for each trajectory point adjustment; adjusts the existing polishing trajectory points according to the trajectory point adjustment direction and amplitude until the actual residual height value of material removal between adjacent polishing trajectories meets the requirements, thereby achieving uniform coverage of the polishing trajectory.
[0172] like Fig.12 Shown is a schematic diagram of the curved surface polishing trajectory generated by the method provided by the present application. It can be seen that the method provided by the present application can not only realize the generation of polishing trajectories on the curved surface to be processed, but also determine the overlap amount between adjacent polishing trajectories according to the actual residual height between adjacent polishing trajectories, thereby achieving uniform coverage of the polishing trajectories.
[0173] Based on the method for adaptively generating a curved surface polishing trajectory provided in the above embodiment, the embodiment of the present application also provides a device for adaptively generating a curved surface polishing trajectory, such as Fig.13 As shown, the device specifically includes:
[0174] The surface discretization module 10 is used to discretize the surface to be processed, obtain a mesh model of the surface to be processed, and extract the vertex coordinates of each triangular mesh in the mesh model;
[0175] A mesh mapping module 20 is used to map each triangular mesh in the mesh model to a two-dimensional plane, obtain a target triangular mesh corresponding to the triangular mesh, and obtain vertex coordinates of the target triangular mesh;
[0176] A parameterized inverse matrix calculation module 30 is used to perform polishing trajectory planning on a two-dimensional plane to obtain an initial polishing trajectory, obtain a target triangular mesh where each plane trajectory point on the initial polishing trajectory is located, and calculate a parameterized mapping inverse matrix of the target triangular mesh based on the vertex coordinates of the target triangular mesh and the vertex coordinates of the triangular mesh corresponding to the target triangular mesh;
[0177] A trajectory point mapping module 40 is used to calculate the coordinates of the plane trajectory point on the mesh model based on the coordinates of each plane trajectory point and the parameterized mapping inverse matrix of the target triangular mesh where the plane trajectory point is located, so as to obtain the surface trajectory point corresponding to the plane trajectory point;
[0178] The surface trajectory point adjustment module 50 is used for selecting, for each surface trajectory point, a surface trajectory point with the closest Euclidean distance to the surface trajectory point on a surface trajectory adjacent to the surface trajectory where the surface trajectory point is located as a reference point, and adjusting the surface trajectory point until the polishing removal residual height between the surface trajectory point and the reference point is less than or equal to a preset residual error, thereby obtaining a target surface trajectory point corresponding to the surface trajectory point;
[0179] The target polishing trajectory acquisition module 60 is used to obtain the target polishing trajectory of the surface to be processed based on the target curved surface trajectory points corresponding to all curved surface trajectory points.
[0180] The embodiment of the present application also provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the steps of the above-mentioned method for adaptively generating a curved surface polishing trajectory are implemented.
[0181] A mesh model of a complex surface is obtained through computer graphics software, and the vertex coordinates of all triangular meshes in the mesh surface are further read. After the complex surface model is meshed, the mathematical characteristics of the complex surface are expressed as a discrete set of several triangular meshes, and the vertex coordinates of each triangular mesh are recorded separately; three containers are established, the first container is used to store the vertex coordinates of each triangular mesh, and an index value is added to each vertex coordinate, the second container is used to store the index values corresponding to the vertex coordinates at both ends of each triangular mesh edge in container one, and the third container is used to store the index values corresponding to the three vertex coordinates of each triangular mesh in container one, as well as the normal vectors of the three edges; the vertex coordinates of the first triangular mesh are added to container 1, the row number of each point is used as the index value of the point in the list, the corresponding edge is represented by the index values of the coordinates of the two end points, and is added to container 2 in the form of a tuple, with each The row number to which the edge belongs is the index value of the edge in the list. Container 3 contains the index values of the three vertices, the index value of the edge, and calculates the normal vector of the triangle mesh referred to; if it is not the first triangle, determine whether there is duplicate data between the triangle mesh and all the existing coordinate points in point container 1, and determine the number of duplicate vertices and the number of duplicate edges in turn, remove the relevant data of the triangle mesh, store the processed results in container 1 and container 2 respectively, generate the corresponding triangle mesh index data in container 3, and calculate and enter the normal vector value of the corresponding mesh; after de-redundancy, the vertex data in the mesh model is described by the index value, and the vertex index value of each triangle mesh is rearranged in counterclockwise order, and the edge index value matrix is further obtained according to the vertex index value information. Without considering the arrangement order of the elements in the matrix, the duplicate matrix information with the same elements in the marking matrix is removed to obtain the marking matrix representing the boundary line;
[0182] Construct a triangular mesh angle deformation energy function to represent the total angle change of all triangular mesh internal angles on the mesh model before and after parameterization; construct an augmented objective function to further constrain and optimize the energy function; convert the energy function into a linear constraint by Lagrangian expansion, and convert the calculation of the deformation energy function into a problem of solving the minimum value between the original angle and the output angle by solving the logarithm and Taylor expansion; convert the result obtained in the previous step into an equation form, solve the unique solution of the linear equation, and combine the Newton iteration method to further obtain all the angles of the triangular mesh after parameterization. Randomly select a triangular mesh on the mesh model as a parameterized reference triangular mesh. When the angle values of all triangular internal angles after parameterization are known, extract the length value of any side of the reference triangular mesh, and solve the results of all triangular meshes after parameterization through divergent calculation; calculate the parameterized mapping matrix of the corresponding triangular mesh according to the vertex coordinate values before and after mapping of each triangular mesh, and further establish the mathematical relationship of the inverse mapping of the two-dimensional plane mesh to the three-dimensional space; perform trajectory planning on the mesh plane after parameterization, and convert the two-dimensional plane trajectory into a polishing trajectory on the mesh surface through inverse mapping;
[0183] According to the material removal depth formula, the polishing removal profile sections at adjacent trajectory points are calculated respectively; through the polishing removal profile section, the polishing removal residual height between adjacent trajectories is further derived; according to the polishing removal residual height between adjacent trajectories, the adjustment direction and amplitude of the current polishing trajectory point are determined, and the position of the trajectory point is adjusted using the dichotomy method. The polishing removal residual height is consistent with the set value. Through trajectory point generation and optimization, uniform coverage of the curved surface polishing trajectory is achieved, which effectively improves the polishing accuracy and obtains better polishing quality.
[0184] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems, or computer program products. Therefore, the present application may adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment in combination with software and hardware. Moreover, the present application may adopt the form of a computer program product implemented in one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) that include computer-usable program code.
[0185] The present application is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0186] These computer program instructions may also be stored in a computer readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer readable memory produce an article of manufacture including an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.
[0187] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.
[0188] Obviously, the above embodiments are merely examples for the purpose of clear explanation and are not intended to limit the implementation methods. For those skilled in the art, other different forms of changes or modifications can be made based on the above description. It is not necessary and impossible to list all the implementation methods here. The obvious changes or modifications derived therefrom are still within the scope of protection of the present invention.
Claims
1. A method for adaptively generating a curved surface polishing trajectory, characterized in that: include: Discretizing the surface to be processed to obtain a mesh model of the surface to be processed, and extracting the vertex coordinates of each triangular mesh in the mesh model; Mapping each triangular mesh in the mesh model to a two-dimensional plane to obtain a target triangular mesh corresponding to the triangular mesh, and acquiring vertex coordinates of the target triangular mesh; Performing polishing trajectory planning on the two-dimensional plane to obtain an initial polishing trajectory, obtaining a target triangular mesh where each plane trajectory point on the initial polishing trajectory is located, and calculating a parameterized mapping inverse matrix of the target triangular mesh based on vertex coordinates of the target triangular mesh and vertex coordinates of a triangular mesh corresponding to the target triangular mesh; Based on the coordinates of each plane trajectory point and the inverse matrix of the parameterized mapping of the target triangular mesh where the plane trajectory point is located, the coordinates of the plane trajectory point on the mesh model are calculated to obtain the surface trajectory point corresponding to the plane trajectory point; For each surface trajectory point, on a surface trajectory adjacent to the surface trajectory where the surface trajectory point is located, a surface trajectory point with the closest Euclidean distance to the surface trajectory point is selected as a reference point, and the surface trajectory point is adjusted until the polishing removal residual height between the surface trajectory point and the reference point is less than or equal to a preset residual error, thereby obtaining a target surface trajectory point corresponding to the surface trajectory point; The target polishing trajectory of the surface to be processed is obtained based on the target surface trajectory points corresponding to all the surface trajectory points.
2. The method for adaptively generating curved surface polishing trajectories according to claim 1, characterized in that: Mapping each triangular mesh in the mesh model to a two-dimensional plane to obtain a target triangular mesh corresponding to the triangular mesh includes: Based on the total amount of changes in the internal angles of all triangle meshes in the mesh model before and after mapping, a triangle mesh angle deformation energy function is constructed; Constructing a triangle mesh mapping model based on the triangle mesh angle deformation energy function, the triangle mesh validity constraint function, the validity constraint function and the reconstruction validity constraint function; The triangular mesh mapping model is solved to obtain the triangular mesh internal angle mapping scale coefficient, and the internal angles of each triangular mesh in the mesh model are mapped based on the triangular mesh internal angle mapping scale coefficient, so as to map the triangular mesh to a two-dimensional plane and obtain a target triangular mesh corresponding to the triangular mesh.
3. The method for adaptively generating curved surface polishing trajectories according to claim 1, characterized in that: The triangle angle deformation energy function is: Where E(α) represents the triangle angle deformation energy function; I represents the number of triangle meshes; Represents the angle of the jth internal angle of the i-th triangle mesh before mapping; Represents the angle after mapping the jth internal angle of the i-th triangle mesh; represents the deformation energy weight of the jth internal angle of the i-th triangle mesh; The triangle mesh validity constraint function is: Among them, C Tri (i) represents the triangle mesh validity constraint function of the i-th triangle mesh; Represents the angle of the first internal angle of the i-th triangle mesh before mapping; Represents the angle of the second inner angle of the i-th triangle mesh before mapping; It represents the angle of the third inner angle of the i-th triangle mesh before mapping; I represents the number of triangle meshes in the mesh model; The plane validity constraint function is: Among them, C Plan (v) represents the plane validity constraint function of the vth vertex; v * represents the interior angles of all triangles adjacent to vertex v; V int Represents the vertex set of all triangle meshes in the mesh model; The reconstruction validity constraint function is: Among them, C Len (v) represents the reconstruction validity constraint function of the vth vertex; The triangle mesh mapping model is expressed as: Where F(x) represents the triangle mesh mapping model; λ Tri Lagrange multiplier representing the validity constraint function of the triangular mesh; λ Plan represents the Lagrange multiplier of the plane validity constraint function; λ Len Lagrange multiplier representing the reconstruction validity constraint function; The Lagrange multiplier representing the triangle mesh validity constraint function of the i-th triangle mesh; Lagrange multiplier representing the plane validity constraint function of the vth vertex; Lagrange multiplier representing the reconstruction validity constraint function of the vth vertex.
4. The method for adaptively generating curved surface polishing trajectories according to claim 1, characterized in that: The calculation formula of the parameterized mapping inverse matrix of the target triangle mesh is: Among them, T represents the parameterized mapping inverse matrix of the target triangular mesh; A represents the first matrix constructed based on the vertex coordinates of the target triangular mesh; B represents the second matrix constructed based on the vertex coordinates of the triangular mesh corresponding to the target triangular mesh; (x1, y1, 0) represents the coordinates of the first vertex of the target triangular mesh; (x2, y2, 0) represents the coordinates of the second vertex of the target triangular mesh; (x3, y3, 0) represents the coordinates of the third vertex of the target triangular mesh; (X1, Y1, Z1) represents the coordinates of the first vertex of the triangular mesh corresponding to the target triangular mesh; (X2, Y2, Z2) represents the coordinates of the second vertex of the triangular mesh corresponding to the target triangular mesh; (X3, Y3, Z3) represents the coordinates of the third vertex of the triangular mesh corresponding to the target triangular mesh.
5. The method for adaptively generating curved surface polishing trajectories according to claim 4, characterized in that: The surface trajectory point corresponding to the plane trajectory point is expressed as: in, represents the surface trajectory point corresponding to the plane trajectory point p; (x, y, 1) represents the coordinates of the plane trajectory point p.
6. The method for adaptively generating curved surface polishing trajectories according to claim 1, characterized in that: The curved surface trajectory point is adjusted until the polishing removal residual height between the curved surface trajectory point and the reference point is less than or equal to a preset residual error, and the target curved surface trajectory point corresponding to the curved surface trajectory point is obtained, including: Step 1: Calculate the polishing removal residual height between the surface trajectory point and the reference point, and determine the magnitude of the polishing removal residual height and a preset residual error; Step 2: if the polishing removal residual height is greater than the preset residual error, setting the left boundary point and the right boundary point of the material removal profile at the reference point based on the polishing contact circle diameter at the reference point; Step 3: Calculate the current line spacing using the left boundary point and the right boundary point of the material removal profile at the dichotomy reference point, and obtain a search vector by cross-producting the polishing tool forward direction at the reference point and the normal vector at the reference point, map the search vector to the two-dimensional plane to obtain a target search vector, and select a target plane trajectory point on the target search vector; Step 4: Based on the coordinates of the target plane trajectory point and the parameterized mapping inverse matrix of the target triangular mesh where the target plane trajectory point is located, the coordinates of the target plane trajectory point on the mesh model are calculated to obtain the updated surface trajectory point, and the maximum material removal depth at the updated surface trajectory point is calculated; Step 5: Determine whether the material removal profile of the updated surface trajectory point and the material removal profile at the reference point have an intersection. If no intersection exists, set the right boundary point of the material removal profile at the reference point equal to the current line spacing, and return to step 3 until the material removal profile of the updated surface trajectory point and the material removal profile at the reference point have an intersection. Step 6: Determine whether the intersection of the material removal profile of the updated surface trajectory point and the material removal profile at the reference point is on the side of the reference point away from the surface trajectory point before the update; if not, set the left boundary point of the material removal profile at the reference point equal to the current line spacing, and return to step 3 until the intersection of the material removal profile of the updated surface trajectory point and the material removal profile at the reference point is on the side of the reference point away from the surface trajectory point before the update; Step 7: Determine the size of the polishing removal residual height between the updated surface trajectory point and the reference point and the preset residual error. If the polishing removal residual height between the updated surface trajectory point and the reference point is greater than the preset residual error, set the right boundary point of the material removal profile at the reference point equal to the current line spacing, and return to step 3 until the polishing removal residual height between the updated surface trajectory point and the reference point is less than or equal to the preset residual error, and use the updated surface trajectory point as the target surface trajectory point.
7. The method for adaptively generating curved surface polishing trajectories according to claim 6, characterized in that: The calculation formula for the polishing removal residual height between the surface trajectory point and the reference point is: Wherein, δ represents the polishing removal residual height between the surface trajectory point and the reference point; d1 represents the maximum material removal depth at the surface trajectory point; d2 represents the maximum material removal depth at the reference point; L represents the distance between the center of the polishing circle at the surface trajectory point and the center of the polishing circle at the reference point; d L represents the intersection function value of the material removal depth function at L at the surface trajectory point and the reference point; x represents the x coordinate of the intersection of the material removal contour at the surface trajectory point and the material removal contour at the reference point.
8. The method for adaptively generating curved surface polishing trajectories according to claim 1, characterized in that: After extracting the vertex coordinates of each triangular mesh in the mesh model, the method further includes performing redundancy removal processing on the vertex coordinates of all the extracted triangular meshes, which specifically includes: Initialize i=1; Determine whether the vertex coordinates of the i-th triangle mesh coincide with the vertex coordinates contained in the first container; If the vertex coordinates of the i-th triangle mesh coincide with the vertex coordinates contained in the first container, remove the vertex coordinates of the i-th triangle mesh that coincide with those in the first container, and determine whether the edge of the i-th triangle mesh coincides with the edge contained in the second container; If the edge of the i-th triangular mesh coincides with the edge contained in the second container, the edge in the i-th triangular mesh that coincides with the edge in the second container is removed; The remaining vertex coordinates of the i-th triangle mesh are stored in the first container in rows, and the row number of each vertex coordinate is used as the index value of the vertex coordinate; Combine the index values of the two vertex coordinates corresponding to each remaining edge of the i-th triangular mesh as the data representation of the edge, and store the data representations of the remaining edges of the i-th triangular mesh in a row-by-row manner in the second container, and use the row number of the data representation of each edge as the index value of the edge; Store the index values of the remaining vertex coordinates, the index values of the remaining edges and the normal vector of the i-th triangle mesh into a third container; Update i=i+1, and return to determine whether the vertex coordinates of the i-th triangle mesh coincide with the vertex coordinates contained in the first container, until i=I, where I represents the number of triangle meshes in the mesh model.
9. A device for adaptively generating a curved surface polishing trajectory, characterized in that: include: A surface discretization module is used to discretize the surface to be processed, obtain a mesh model of the surface to be processed, and extract the vertex coordinates of each triangular mesh in the mesh model; A mesh mapping module, used to map each triangular mesh in the mesh model to a two-dimensional plane, obtain a target triangular mesh corresponding to the triangular mesh, and obtain vertex coordinates of the target triangular mesh; A parameterized inverse matrix calculation module is used to perform polishing trajectory planning on the two-dimensional plane to obtain an initial polishing trajectory, obtain a target triangular mesh where each plane trajectory point on the initial polishing trajectory is located, and calculate a parameterized mapping inverse matrix of the target triangular mesh based on the vertex coordinates of the target triangular mesh and the vertex coordinates of the triangular mesh corresponding to the target triangular mesh; A trajectory point mapping module, used to calculate the coordinates of each plane trajectory point on the mesh model based on the coordinates of each plane trajectory point and the parameterized mapping inverse matrix of the target triangular mesh where the plane trajectory point is located, and obtain the surface trajectory point corresponding to the plane trajectory point; A surface trajectory point adjustment module is used to select, for each surface trajectory point, a surface trajectory point with the closest Euclidean distance to the surface trajectory point on a surface trajectory adjacent to the surface trajectory where the surface trajectory point is located as a reference point, and adjust the surface trajectory point until the polishing removal residual height between the surface trajectory point and the reference point is less than or equal to a preset residual error, thereby obtaining a target surface trajectory point corresponding to the surface trajectory point; The target polishing trajectory acquisition module is used to obtain the target polishing trajectory of the surface to be processed based on the target surface trajectory points corresponding to all the surface trajectory points.
10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the method for adaptively generating a curved surface polishing trajectory according to any one of claims 1 to 8 are implemented.
Citation Information
Cited By
Curved surface direct interpolation method, device and equipment based on parametric curved surface coverage trajectory
CN120722843A
Method, device and equipment for direct interpolation of surface based on parameter surface covering track
CN120722843B
