A Dirty Composite Surface Mesh Generation Method
By performing subdivided mesh processing and topological repair on dirty composite surfaces, and combining indirect and direct methods to generate mesh, the problem of generating high-quality mesh in the existing technology is solved, and efficient and robust mesh generation effect is achieved.
Patent Information
- Application Number
- CN202311715705.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-12-14
- Publication Date
- 2025-04-29
- Estimated Expiration
- 2043-12-14
AI Technical Summary
The prior art is difficult to effectively generate high-quality dirty composite surface mesh, especially when dealing with geometric problems such as slits, overlaps, short sides, and thin surfaces, which makes it difficult to verify the effectiveness of mesh cells and low computational efficiency.
By obtaining dirty composite surfaces from the geometric model, performing subdivided mesh processing and topological repair, extracting boundary parameter curves for discrete and priority queue processing, and building mesh in parameter planes and three-dimensional space with indirect and direct methods to ensure the effectiveness of mesh cells.
It realizes efficient generation of high-quality mesh on dirty composite surfaces, improves the speed and robustness of mesh generation, solves the problem of grid cell effectiveness detection, and the generated mesh quality is better than that of existing commercial software COMSOL.
Smart Images

Figure CN117726769B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of numerical simulation, and in particular to a method for generating a dirty composite surface mesh. Background Art
[0002] Numerical simulation methods based on partial differential equations are often used in numerical simulation, such as finite volume method, finite difference method, finite element method and boundary element method. Before using these numerical methods to analyze the problem, the geometric area of the problem is generally divided into many basic units. This process is called mesh generation. The purpose of mesh generation is to divide the Euclidean space into a collection of linear mesh units to simulate many nonlinear problems in reality. However, due to the inconsistent goals of computer-aided modelers and numerical simulation personnel, the geometric model often contains some geometric problems such as slits, overlaps, short edges, and fine faces. These problems seriously affect the quality and effectiveness of the mesh. Therefore, through virtual topology technology, these surfaces can be topologically merged into a dirty composite surface, so that the frontier advancement technology can be applied on the dirty composite surface to generate high-quality meshes across the boundary curves, solving the obstacles to mesh generation caused by geometric problems such as slits, overlaps, short edges, and fine faces.
[0003] In the existing technology for processing dirty composite surface mesh generation, most industrial software mesh generation engines face practical engineering problems such as difficulty in detecting the validity of mesh units and failure to generate correct surface meshes, including:
[0004] (1) Dirty composite surfaces are composed of multiple different parametric surfaces. Each parametric surface has its own parameter space, and there may be defects such as gaps between surfaces. When generating meshes on multiple parametric surfaces, it is necessary to cross boundary curves, which makes it difficult to verify the validity of mesh units. How to ensure that mesh units across multiple parametric surfaces are valid is a challenging problem.
[0005] (2) During the generation of dirty composite surface meshes, the positions of ideal points need to be calculated, which is an operation involving crossing boundary curves. Therefore, its computational efficiency and robustness face great difficulties. This is also the reason why the correct surface mesh cannot be generated on dirty composite surfaces. Summary of the invention
[0006] In view of this, an embodiment of the present application provides a dirty composite surface mesh generation method to solve the problems existing in the background technology.
[0007] According to an embodiment of the present application, a dirty composite surface mesh generation method includes:
[0008] S1: obtaining a dirty composite surface from a geometric model, and processing the obtained dirty composite surface to obtain a subdivided mesh, wherein the geometric model is a model composed of multiple parametric surfaces and has geometric problems such as slits, overlaps, short edges, and thin surfaces;
[0009] S2: performing topological repair on the subdivided mesh and parameterizing it to obtain a parameter plane;
[0010] S3: extracting the boundary parameter curve of the dirty composite surface, connecting the end to the end to form a composite curve, discretizing the composite curve to obtain a set of frontier edges, and placing them into a priority queue according to the principle of shortest edge first;
[0011] S4: taking out the shortest front edge from the priority queue, constructing a new triangle on the dirty composite surface, projecting the new triangle onto the parameter plane for mesh validity verification, and updating the priority queue;
[0012] S5: Repeat step S4 until the priority queue is empty and output the dirty composite surface mesh.
[0013] The technical solution provided by the embodiments of the present application may have the following beneficial effects:
[0014] The present application solves the geometric problems of dealing with slits, overlaps, short edges, thin faces, etc., which seriously affect the quality and correctness of the mesh in the dirty composite surface mesh generation algorithm. The problem of validity detection of dirty composite surfaces is solved by a rigid transformation parameterization technology that guarantees bijection after being processed by topological hole filling technology, and the speed and robustness of mesh generation are improved by combining the indirect method with the direct method. Subdivided grids are used to assist in determining whether the ideal point generated by the indirect method crosses the boundary of the clipping curve and the index of the parametric surface that needs to be projected on the ideal point generated in the three-dimensional physical space by the direct method. Combining the above innovations, the surface mesh generation efficiency, effectiveness and quality of the algorithm of the present invention are better than those of the existing commercial software COMSOL. BRIEF DESCRIPTION OF THE DRAWINGS
[0015] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and, together with the description, serve to explain the principles of the present application.
[0016] Figure 1 The present invention is a flowchart of a method for generating a dirty composite surface mesh according to an exemplary embodiment.
[0017] Figure 2 is a schematic diagram of a dirty composite surface of a cover model according to an exemplary embodiment.
[0018] Figure 3is a schematic diagram of initial parameterization of a subdivided mesh of a dirty composite surface of a lid model according to an exemplary embodiment.
[0019] Figure 4 FIG. 4 is a parametric plane diagram of a subdivided mesh of a dirty composite surface of a lid model according to an exemplary embodiment.
[0020] Figure 5 is a schematic diagram of a discrete composite curve according to an exemplary embodiment.
[0021] Figure 6 It is a schematic diagram of the surface mesh effect generated by the commercial software COMSOL on a dirty composite surface according to an exemplary embodiment.
[0022] Figure 7 It is a schematic diagram showing the effect of generating a surface mesh on a dirty composite surface according to an exemplary embodiment of the present invention.
[0023] Figure 8 It is a comparison diagram of the surface mesh generation quality of commercial software and the present invention according to an exemplary embodiment. DETAILED DESCRIPTION
[0024] Exemplary embodiments will be described in detail herein, examples of which are shown in the accompanying drawings. When the following description refers to the drawings, the same numbers in different drawings represent the same or similar elements unless otherwise indicated. The implementations described in the following exemplary embodiments do not represent all implementations consistent with the present application. Instead, they are merely examples of devices and methods consistent with some aspects of the present application as detailed in the appended claims.
[0025] The terms used in this application are for the purpose of describing specific embodiments only and are not intended to limit this application. The singular forms of "a", "said" and "the" used in this application and the appended claims are also intended to include plural forms unless the context clearly indicates other meanings. It should also be understood that the term "and / or" used herein refers to and includes any or all possible combinations of one or more associated listed items.
[0026] In the design phase of industrial manufacturing, numerical simulation analysis is usually used to verify the indicators and performance of geometric models to reduce costs. However, when using computer-aided software for modeling, such as modeling in applications such as engines, semiconductor components, and aircraft, some geometric problems may occur, such as slits, overlaps, short edges, and thin faces. These geometric problems seriously hinder the generation of high-quality and effective surface meshes. Specifically, the present invention will use a mechanical component cover model as an exemplary embodiment to explain the specific implementation.
[0027] Figure 1is a flow chart of a method for generating a dirty composite surface mesh according to an exemplary embodiment. Figure 1 As shown, the method may include the following steps:
[0028] S1: Obtain a dirty composite surface from a geometric model, and process the obtained dirty composite surface to obtain a subdivided mesh, wherein the geometric model is a model composed of multiple parametric surfaces with slits, overlaps, short edges, and thin faces;
[0029] Specifically, the dirty composite surface is composed of multiple parametric surfaces. Some parametric surfaces have problems such as short edges and thin faces. In addition, there are problems such as slits and overlaps between some adjacent parametric surfaces. The frontier advancement technology is used to generate meshes for each parametric surface in the composite surface to obtain the triangular mesh corresponding to each parametric surface. The triangular meshes corresponding to all parametric surfaces contained in the composite surface are spliced to obtain a subdivided mesh.
[0030] As in Example 1, we use the algorithm of the present invention to verify the effect on the cover of a mechanical component. The geometric model contains 170 parametric surfaces, 10 slits or overlap errors, 20 thin faces, and 24 short edges. The 170 parametric surfaces of the geometric model are topologically merged into a dirty composite surface, and its style is as follows: Figure 2 As shown in FIG. 1 , the algorithm of the present invention is applied to the model to realize the fast and high-quality generation of dirty composite surface meshes. The ideal mesh size specified by the user is always 3.
[0031] S2: Topologically repair the subdivided mesh and parameterize it to obtain a parameter plane; this step includes the following sub-steps:
[0032] S21: finding the inner boundary ring of the subdivided grid by using a depth-first search technique;
[0033] Specifically, all mesh edges shared by only one triangle are found in the subdivided mesh. The rings formed by these mesh edges are found by depth-first search technology. The length of each ring is calculated, and the longest ring is deleted. The remaining rings are the internal boundary rings of the subdivided mesh.
[0034] S22: removing the internal boundary ring by using a topological hole filling technique to obtain the topologically correct subdivided mesh;
[0035] Specifically, for the internal boundary ring, we will perform a weighted average calculation on the coordinates of the points that make up the ring to obtain the coordinates of the average point, which is recorded as the topological point. The topological point is connected to all mesh edges on the corresponding internal boundary ring to form a topologically correct subdivided mesh;
[0036] S23: parameterizing the topologically correct subdivision grid to obtain a parameter plane;
[0037] Specifically, the points on the outer boundary ring of the topologically correct subdivision grid are orderly mapped to a unit circle on the plane, and the coordinates of the inner discrete triangle grid points are linear combinations of their neighbors, so that the initial bijective parameter plane can be obtained.
[0038] Furthermore, the topological points and the triangles connected to the topological points in the initial bijective parameter plane are deleted, and a rectangular bounding box consisting of 20 grid edges is constructed outside the initial bijective parameter plane, and all the empty parts in the bounding box are filled with triangles. The grid used for filling is recorded as an air grid, such as Figure 3 Shown in medium dark grid.
[0039] Furthermore, the boundary points of the bounding box are fixed, and the internal mesh is deformed using a rigid transformation technique, wherein the deformation target of the two-dimensional air mesh is itself, and the deformation target of the remaining two-dimensional meshes is the rigid mapping result of the corresponding three-dimensional subdivided mesh on the two-dimensional plane, and the deformation is continuously iterated until the parameter plane is obtained through convergence. As in Example 1, Figure 4 The parameter plane is shown.
[0040] S3: extracting the boundary parameter curve of the dirty composite surface, connecting the end to the end to form a composite curve, discretizing the composite curve to obtain a set of frontier edges, and placing them into a priority queue according to the principle of shortest edge first; this step includes the following sub-steps:
[0041] S31: Calculate the length of each boundary parameter curve using the composite Simpson method technology, and discretize from the starting point of one of the boundary parameter curves;
[0042] Specifically, a composite curve is composed of m parameter curves connected in the first place, and in Example 1, m is 4, such as Figure 5 As shown. The left and right endpoints of the i-th parameter curve are a i With b i , using the composite Simpson method to calculate the length of the i-th parameter curve that makes up the composite curve is l i If the composite curve is not a closed curve, one of the two endpoints on the composite curve is selected as the starting point. Otherwise, an endpoint of a parameter curve is randomly selected as the starting point.
[0043] S32: when discretizing to the current point, the remaining curve length is obtained by subtracting the discretized curve length from the boundary parameter curve length, and the user-specified ideal grid size is queried. If the ideal size is greater than the remaining curve length, the result of subtracting the remaining curve length from the ideal grid size is used as the new ideal size and the next boundary parameter curve is skipped to continue discretization. If the ideal size is less than the remaining curve length, the arc length integral is used to obtain the next point whose distance from the current point is the ideal size value.
[0044] Specifically, the size of the current point position is queried in the size field as x. In Example 1, the queried size value is 3. The index of the parameter curve where the current point is located is i, and the endpoint a of the parameter curve is i The distance to the current point is d i If l i Greater than x+d i , then the position of the next point on the i-th parametric curve is calculated using the arc length integral, and the arc length is x+d i ; if l i Less than x+d i , then the position of the next point is calculated using the arc length integral on the i+1th parametric curve, and the arc length is x+d0-l i .
[0045] S33: If the next point is the end point of the composite curve, a set of front edges is output; otherwise, the next point is used as the current point and steps S32-S33 are repeated.
[0046] Specifically, if the current point is on the last parametric curve, and l m Less than 1.5x+d m Then the next point is the end point of the mth curve, the composite curve discretization ends, and a set of mesh edges is output as the initial front edge of mesh generation.
[0047] S4: taking out the shortest front edge from the priority queue, constructing a new triangle on the dirty composite surface, projecting the new triangle onto the parameter plane for mesh validity verification, and updating the priority queue; this step includes the following sub-steps:
[0048] S41: Obtain the shortest front edge from the head of the priority queue, and query the user-specified ideal grid size at the midpoint of the shortest front edge;
[0049] Specifically, the shortest front edge is obtained from the head of the priority queue and the edge is deleted from the priority queue. The ideal size of the grid specified by the user at the midpoint of the shortest front edge is queried, and the ideal size is used as the expected length of the side of the generated triangle. In Example 1, the queried size is always 3.
[0050] S42: determining whether the shortest front edge is located inside a single parameter surface, if so, using an indirect method of the frontier advancement technique to calculate the ideal point according to the ideal size using a Newton iteration method, otherwise, using a direct method of the frontier advancement technique to directly calculate the ideal point according to the ideal size in a three-dimensional physical space;
[0051] Specifically, if the parametric surface where the two endpoints of the shortest front edge are located is the same, the indirect method is used. The Newton iteration method is used to find the position of the ideal point in the parameter plane corresponding to the parametric surface, and then the ideal point is projected onto the subdivided grid to determine whether the ideal point is within the trimming curve boundary of the parametric surface. If so, the generation is completed. If the ideal point calculated based on the indirect method is not within the trimming curve boundary of the parametric surface or the two endpoints of the shortest front edge are not on the same surface, the direct method is used. The position of the ideal point is calculated in three-dimensional space and projected onto the subdivided grid to find the index of the parametric surface closest to the ideal point, and then the ideal point is projected onto the parametric surface to complete the generation of the ideal point.
[0052] S43: adding other endpoints on the front edge whose distances to the ideal point are smaller than the ideal size to the candidate queue in ascending order of distance, and finally adding the ideal point to the candidate queue;
[0053] Specifically, all points on the front edge of a sphere with the ideal point as the center and the ideal size as the radius are found, the distances from these points to the ideal point are calculated, and the points are added to the candidate queue in ascending order of distance. Finally, the ideal point is added to the end of the candidate queue.
[0054] S44: taking a point from the candidate queue as a candidate point, and connecting it with the shortest front edge to form a new triangle. If the candidate point is the ideal point, the candidate point needs to be projected onto the parameter plane.
[0055] Specifically, a point is taken from the head of the candidate queue as a candidate point. If the point is not the ideal point, it is directly connected to the shortest front edge to form a new triangle. Otherwise, the ideal point is projected onto the parameter plane and connected to the shortest front edge to form a new triangle.
[0056] S45: Verify whether the new triangle is valid on the parameter plane. If valid, update the new front edge generated by the new triangle to the priority queue and delete the shortest front edge from the priority queue. Otherwise, repeat steps S44-S45.
[0057] Specifically, the parameter plane is used to detect whether the new triangle contains other triangles or front edges. If so, the new triangle is invalid. The parameter plane is used to detect whether the newly generated front edge of the new triangle intersects with other front edges of the parameter plane. If so, the new triangle is invalid. If the new triangle fails these two tests, the new triangle is invalid and S44 needs to be executed. Otherwise, the new triangle is valid. If the new triangle is valid, the shortest front edge is deleted from the priority queue and the new front edge generated by the new triangle is added to the priority queue.
[0058] S5: Repeat step S4 until the priority queue is empty and output the dirty composite surface mesh.
[0059] Specifically, it is detected whether the priority queue still contains a front edge, and if the priority queue is empty, the surface mesh is output, otherwise, step S4 is repeated. As in Example 1, Figure 6 The output surface mesh is shown. It can be seen that the mesh units span the defects such as slits, overlaps, short edges, and fine faces between the surfaces to generate a high-quality surface mesh. The number of cells generated in the end is 13160.
[0060] It can be seen from the above embodiments that the present application solves the geometric problems in the dirty composite surface mesh generation algorithm, such as processing slits, overlaps, short edges, and thin faces, which seriously affect the mesh quality and mesh correctness. The problem of validity detection of dirty composite surfaces is solved by a rigid transformation parameterization technology that guarantees bijection after being processed by a topological hole filling technology, and the speed and robustness of mesh generation are improved by combining the indirect method with the direct method. Subdivided grids are used to assist in determining whether the ideal point generated by the indirect method crosses the boundary of the clipping curve and the index of the parametric surface that needs to be projected on the ideal point generated in the three-dimensional physical space by the direct method. Combining the above innovations, the surface mesh generation efficiency, effectiveness, and quality of the algorithm of the present invention are better than those of the existing commercial software COMSOL.
[0061] In this embodiment, we compared the present invention with the mainstream commercial software COMSOL in the market in terms of efficiency, mesh effectiveness, and mesh quality in the mesh generation phase. Under the same user-specified ideal size, we conducted a comparative test on the same computer, which is a desktop computer (AMD Ryzen 75700G with Radeon Graphics, 3.80GHz, single-core operation). Figure 6 and Figure 7The surface mesh generation results of the COMSOL commercial software and the surface mesh generation results of the present invention are respectively shown. In terms of efficiency, the present invention successfully generated 13,160 triangular units and completed the mesh generation phase in 0.24 seconds. In contrast, the commercial software COMSOL generated 16,085 triangular units, and its mesh generation phase took 2.611 seconds. Therefore, the method proposed in the present invention has a higher generation efficiency of a single triangle than the commercial software COMSOL, and the speed is increased by 8.9 times. In terms of mesh validity, it can be found by observation that the method proposed in the present invention generates a valid surface mesh, while the commercial software COMSOL generates an incorrect surface mesh. In terms of mesh quality, Figure 8 The distribution of the mesh quality evaluation parameter equiangular skewness, which is of interest in numerical simulation, is shown. The closer the equiangular skewness is to 1, the worse the mesh quality is, and the closer it is to 0, the better the mesh quality is. Figure 8 It can be found that the method proposed by the present invention does not generate a difference unit between 0.4 and 1.0, while the commercial software COMSOL not only generates triangles with a quality of 0.4-0.7, but also the overall mesh quality distribution is significantly behind the method proposed by the present invention. It can be found from Example 1 that the method proposed by the present invention exceeds the commercial software COMSOL in terms of efficiency, mesh effectiveness, and mesh quality during the mesh generation stage.
[0062] Those skilled in the art will readily appreciate other embodiments of the present application after considering the description and practicing the contents disclosed herein. The present application is intended to cover any modification, use or adaptation of the present application, which follows the general principles of the present application and includes common knowledge or customary techniques in the art that are not disclosed in the present application. The description and examples are intended to be exemplary only, and the true scope and spirit of the present application are indicated by the claims.
[0063] It should be understood that the present application is not limited to the precise structures that have been described above and shown in the drawings, and that various modifications and changes may be made without departing from the scope thereof. The scope of the present application is limited only by the appended claims.
Claims
1. A dirty composite surface mesh generation method, characterized in that: The method is applied to the field of engines, semiconductor components or aircraft, and comprises: S1: obtaining a dirty composite surface from a geometric model, and processing the obtained dirty composite surface to obtain a subdivided mesh, wherein the geometric model is a model composed of multiple parametric surfaces and has geometric problems such as slits, overlaps, short edges, and thin surfaces; S2: performing topological repair on the subdivided mesh and parameterizing it to obtain a parameter plane; S3: extracting the boundary parameter curve of the dirty composite surface, connecting the end to the end to form a composite curve, discretizing the composite curve to obtain a set of frontier edges, and placing them into a priority queue according to the principle of shortest edge first; S4: taking out the shortest front edge from the priority queue, constructing a new triangle on the dirty composite surface, projecting the new triangle onto the parameter plane for mesh validity verification, and updating the priority queue; S5: repeat step S4 until the priority queue is empty and output the dirty composite surface mesh; The step of extracting the boundary parameter curve of the dirty composite surface, connecting the boundary parameter curves end to end to form a composite curve, discretizing the composite curve to obtain a set of frontier edges, and placing the frontier edges into a priority queue according to the principle of shortest edge first includes: S31: Calculate the length of each boundary parameter curve using the composite Simpson method technology, and discretize from the starting point of one of the boundary parameter curves; S32: when discretizing to the current point, the remaining curve length is obtained by subtracting the discretized curve length from the boundary parameter curve length, and the user-specified ideal grid size is queried. If the ideal size is greater than the remaining curve length, the result of subtracting the remaining curve length from the ideal grid size is used as the new ideal size and the next boundary parameter curve is skipped to continue discretization. If the ideal size is less than the remaining curve length, the arc length integral is used to obtain the next point whose distance from the current point is the ideal size value. S33: if the next point is the end point of the composite curve, output a set of front edges; otherwise, take the next point as the current point and repeat steps S32-S33; Taking the shortest leading edge from the priority queue, constructing a new triangle on the dirty composite surface, projecting the new triangle onto the parameter plane for mesh validity verification, and updating the priority queue, including: S41: Obtain the shortest front edge from the head of the priority queue, and query the user-specified ideal grid size at the midpoint of the shortest front edge; S42: determining whether the shortest front edge is located inside a single parameter surface, if so, using an indirect method of the frontier advancement technique to calculate the ideal point according to the ideal size using a Newton iteration method, otherwise, using a direct method of the frontier advancement technique to directly calculate the ideal point according to the ideal size in a three-dimensional physical space; S43: adding other endpoints on the front edge whose distances to the ideal point are smaller than the ideal size to the candidate queue in ascending order of distance, and finally adding the ideal point to the candidate queue; S44: taking a point from the candidate queue as a candidate point, and connecting it with the shortest front edge to form a new triangle. If the candidate point is the ideal point, the candidate point needs to be projected onto the parameter plane. S45: Verify whether the new triangle is valid on the parameter plane. If valid, update the new front edge generated by the new triangle to the priority queue and delete the shortest front edge from the priority queue. Otherwise, repeat steps S44-S45.
2. The method according to claim 1, characterized in that The subdivided mesh is topologically repaired and parameterized to obtain a parameter plane, including: S21: finding the inner boundary ring of the subdivided grid by using a depth-first search technique; S22: removing the internal boundary ring by using a topological hole filling technique to obtain the topologically correct subdivided mesh; S23: Parameterize the topologically correct subdivision grid to obtain a parameter plane.
Citation Information
Patent Citations
Triangular mesh reparameterization method for parameter curved surface fitting
CN109961517A
Curved surface grid generation method and device, equipment and storage medium
CN116720234A