A grid generation method, device, equipment and storage medium based on a watertight grid framework
Through the multi-layer processing method of watertight grid frame, the problem of inefficient grid generation is solved, high-quality and high-speed grid generation is achieved, and user experience is improved.
Patent Information
- Application Number
- CN202510578763.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-07
- Publication Date
- 2025-07-22
- Estimated Expiration
- 2045-05-07
AI Technical Summary
The prior art is inefficient in the grid generation process, it is difficult to effectively deal with dirty geometry problems, and the lack of hierarchical frameworks leads to insufficient grid quality and speed.
Using a watertight grid framework method, the quality and speed of grid generation are improved through data processing and operation between real geometry layer, discrete geometry layer, virtual geometry layer and grid generation layer, including the storage of CAD objects, the generation of discrete data, virtual topology operation and the application of grid generation algorithms.
Improve the quality and speed of target grid generation and improve the user experience.
Smart Images

Figure CN120105645B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of computer image technology, and particularly relates to a grid generation method, device, equipment and storage medium based on a watertight grid framework. Background Art
[0002] Preprocessing is the main performance bottleneck in the numerical simulation of complex problems, and its efficiency highly depends on user experience. Among them, preprocessing mainly includes grid generation and CAD (Autodesk Computer Aided Design, a drawing tool software) preprocessing for grid generation. In practical applications, due to the accuracy differences and modeling among various modeling software, dirty geometry problems such as messy model boundaries and gaps between faces will occur during the process of automatically processing CAD models.
[0003] Currently, the geometric processing method is to directly change the real geometric structure of the solid model using digital model processing software, and the steps are usually very complex and costly. In addition, although some documents deal with dirty geometry problems on discrete grids, the conformality of the subsequent modified grids of this method can only reach the conformality of the initial grid generation, and there is no face information, the means of adjusting the grid density are few, the regional fine adjustment is difficult, and there is no concept of hierarchical framework.
[0004] As can be seen from the above, how to improve the efficiency of target grid generation during the grid generation process based on a watertight grid framework is an urgent problem to be solved currently. Summary of the Invention
[0005] In view of this, the purpose of the present invention is to provide a grid generation method, device, equipment and storage medium based on a watertight grid framework, which can improve the quality and speed of target grid generation during the grid generation process based on a watertight grid framework. The specific scheme is as follows:
[0006] In the first aspect, the present application provides a grid generation method based on a watertight grid framework, which is applied to a watertight grid framework including a preset real geometry layer, a preset discrete geometry layer, a preset virtual geometry layer and a preset grid generation layer. The method includes:
[0007] Store the CAD object to be generated with grids in the preset real geometry layer, and send the CAD object to be generated with grids to the preset discrete geometry layer; the CAD object to be generated with grids includes CAD digital model points, CAD digital model lines, CAD digital model faces and topological association information;
[0008] Process the CAD object of the mesh to be generated in the preset discrete geometry layer to obtain discrete data corresponding to the CAD object of the mesh to be generated, and send the discrete data to the preset virtual geometry layer; the discrete data includes discrete points, discrete edges, and discrete faces corresponding to the CAD object of the mesh to be generated.
[0009] Based on preset virtual topology operations, operate on the discrete data in the preset virtual geometry layer to obtain a virtual geometry operation processing object, and send the virtual geometry operation processing object to the preset mesh generation layer; the virtual geometry operation processing object includes virtual points, virtual edges, virtual loops, and virtual faces corresponding to the discrete data.
[0010] In the preset mesh generation layer, use a preset mesh generation algorithm to perform a mesh generation operation on the virtual geometry operation processing object to obtain a target mesh corresponding to the CAD object of the mesh to be generated.
[0011] Optionally, storing the CAD object of the mesh to be generated in the preset real geometry layer and sending the CAD object of the mesh to be generated to the preset discrete geometry layer includes:
[0012] Analyze the real geometry in the preset real geometry layer to obtain the CAD object of the mesh to be generated, and send the CAD object of the mesh to be generated to the preset discrete geometry layer; the CAD object of the mesh to be generated includes CAD digital model points, CAD digital model lines, CAD digital model faces, and topological association information.
[0013] Wherein, the CAD digital model point is a geometric shape unit corresponding to the real geometry, the CAD digital model line is a digital model line determined based on each CAD digital model point and used to describe the edges and contours of the real geometry, the CAD digital model face is a digital model face determined based on each CAD digital model line, and the topological association information is used to describe the connection relationships and hierarchical structures among the CAD digital model points, the CAD digital model lines, and the CAD digital model faces.
[0014] Optionally, processing the CAD object of the mesh to be generated in the preset discrete geometry layer to obtain discrete data corresponding to the CAD object of the mesh to be generated includes:
[0015] In the preset discrete geometry layer, process each CAD digital model point, each CAD digital model line, each CAD digital model face, and the corresponding topological association information respectively to obtain discrete points, discrete edges, and discrete faces corresponding to the CAD object of the mesh to be generated.
[0016] Among them, the discrete edge is a discrete edge formed based on a number of discrete points, the directions corresponding to each discrete point, and a preset end point, and the discrete surface is composed of discrete triangles and a boundary loop composed of a number of the discrete edges.
[0017] Optionally, operating on the discrete data in the preset virtual geometry layer based on the preset virtual topology operation to obtain a virtual geometry operation processing object includes:
[0018] Establishing virtual points, virtual edges, virtual loops, and virtual surfaces in the preset virtual geometry layer based on the topological association information and the discrete data, and operating on each of the virtual points, each of the virtual edges, each of the virtual loops, and each of the virtual surfaces in the preset virtual geometry layer based on the preset virtual topology operation to obtain a virtual geometry operation processing object;
[0019] Among them, the virtual topology operation includes performing splitting operations, merging operations, and deletion operations on each of the virtual points, each of the virtual edges, each of the virtual loops, and each of the virtual surfaces, and establishing topological connection relationships for each of the virtual edges.
[0020] Optionally, establishing a virtual edge in the preset virtual geometry layer based on the topological association information and the discrete data includes:
[0021] Deriving virtual edges constructed based on the corresponding discrete points in the preset virtual geometry layer based on the topological association information and the discrete data;
[0022] Or, deriving parametric lines at specific positions in a preset mathematical model in the preset virtual geometry layer to construct corresponding virtual edges based on the parametric lines;
[0023] Correspondingly, establishing a virtual surface in the preset virtual geometry layer based on the topological association information and the discrete data includes:
[0024] Deriving virtual surfaces with hole-filling properties and / or virtual surfaces with original digital model properties in the preset virtual geometry layer using a preset geometric model and based on the topological association information and the discrete data.
[0025] Optionally, the mesh generation operation on the virtual geometry operation processing object in the preset mesh generation layer using a preset mesh generation algorithm to obtain a target mesh corresponding to the CAD object of the mesh to be generated includes:
[0026] Performing a mesh generation operation on the virtual geometry operation processing object in the preset mesh generation layer using a preset mesh generation algorithm to obtain an initial mesh corresponding to the CAD object of the mesh to be generated; the initial mesh has boundary information and face information;
[0027] Optimize the quality of the initial mesh using a preset quality optimization algorithm and based on the boundary information and the face information corresponding to the initial mesh to obtain a target mesh.
[0028] Optionally, the operation of generating a mesh for the virtual geometry operation processing object using a preset mesh generation algorithm in the preset mesh generation layer to obtain a target mesh corresponding to the mesh CAD object to be generated includes:
[0029] In the preset mesh generation layer, perform a mesh generation operation on the virtual geometry operation processing object using a preset mesh generation algorithm to obtain a virtual geometry digital model corresponding to the mesh CAD object to be generated, and use the virtual geometry digital model and based on the mesh CAD object to be generated to generate a target mesh;
[0030] Among them, the preset mesh generation algorithm includes a boundary discretization algorithm and a surface mesh generation algorithm of Delaunay - AFT.
[0031] In a second aspect, the present application provides a mesh generation device based on a watertight mesh framework, which is applied to a watertight mesh framework including a preset real geometry layer, a preset discrete geometry layer, a preset virtual geometry layer, and a preset mesh generation layer. The device includes:
[0032] A mesh CAD object determination module, configured to store a mesh CAD object to be generated in the preset real geometry layer and send the mesh CAD object to be generated to the preset discrete geometry layer; the mesh CAD object to be generated includes CAD digital model points, CAD digital model lines, CAD digital model faces, and topological association information;
[0033] A discrete data determination module, configured to process the mesh CAD object to be generated in the preset discrete geometry layer to obtain discrete data corresponding to the mesh CAD object to be generated, and send the discrete data to the preset virtual geometry layer; the discrete data includes discrete points, discrete edges, and discrete faces corresponding to the mesh CAD object to be generated;
[0034] An operation processing object determination module, configured to perform an operation on the discrete data in the preset virtual geometry layer based on a preset virtual topology operation to obtain a virtual geometry operation processing object, and send the virtual geometry operation processing object to the preset mesh generation layer; the virtual geometry operation processing object includes virtual points, virtual edges, virtual loops, and virtual faces corresponding to the discrete data;
[0035] A target mesh generation module, configured to perform a mesh generation operation on the virtual geometry operation processing object using a preset mesh generation algorithm in the preset mesh generation layer to obtain a target mesh corresponding to the mesh CAD object to be generated.
[0036] In a third aspect, the present application provides an electronic device, including:
[0037] a memory for storing a computer program;
[0038] a processor for executing the computer program to implement the aforementioned mesh generation method based on a watertight mesh framework.
[0039] In a fourth aspect, the present application provides a computer-readable storage medium for storing a computer program, wherein when the computer program is executed by a processor, the aforementioned mesh generation method based on a watertight mesh framework is implemented.
[0040] As can be seen from the above, before performing mesh generation based on a watertight mesh framework in the present application, it is necessary to store the CAD object of the mesh to be generated in the preset real geometry layer and send the CAD object of the mesh to be generated to the preset discrete geometry layer; the CAD object of the mesh to be generated includes CAD digital model points, CAD digital model lines, CAD digital model surfaces, and topological association information; process the CAD object of the mesh to be generated in the preset discrete geometry layer to obtain discrete data corresponding to the CAD object of the mesh to be generated, and send the discrete data to the preset virtual geometry layer; the discrete data includes discrete points, discrete edges, and discrete surfaces corresponding to the CAD object of the mesh to be generated; perform operations on the discrete data in the preset virtual geometry layer based on preset virtual topology operations to obtain a virtual geometry operation processing object, and send the virtual geometry operation processing object to the preset mesh generation layer; the virtual geometry operation processing object includes virtual points, virtual edges, virtual loops, and virtual surfaces corresponding to the discrete data; use a preset mesh generation algorithm to perform a mesh generation operation on the virtual geometry operation processing object in the preset mesh generation layer to obtain a target mesh corresponding to the CAD object of the mesh to be generated.
[0041] Thus, it can be seen that the present application first needs to store the CAD object of the mesh to be generated in the preset real geometry layer and send the CAD object of the mesh to be generated to the preset discrete geometry layer; subsequently, process the CAD object of the mesh to be generated in the preset discrete geometry layer to obtain discrete data corresponding to the CAD object of the mesh to be generated, and send the discrete data to the preset virtual geometry layer; furthermore, perform operations on the discrete data in the preset virtual geometry layer based on preset virtual topology operations to obtain a virtual geometry operation processing object, and send the virtual geometry operation processing object to the preset mesh generation layer; finally, use a preset mesh generation algorithm to perform a mesh generation operation on the virtual geometry operation processing object in the preset mesh generation layer to obtain a target mesh corresponding to the CAD object of the mesh to be generated. In this way, the quality and speed of target mesh generation are improved, thereby enhancing the user experience. Description of the Drawings
[0042] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the following will briefly introduce the drawings required for the description of the embodiments or the prior art. Obviously, the drawings in the following description are only the embodiments of the present invention. For those of ordinary skill in the art, without creative efforts, other drawings can also be obtained based on the provided drawings.
[0043] Figure 1 Flowchart of a mesh generation method based on a watertight mesh framework disclosed in the present application;
[0044] Figure 2 Schematic diagrams of several dirty geometry problem phenomena; among them, Figure 2 a is a schematic diagram of the broken surface problem, Figure 2 b is a schematic diagram of the boundary clutter problem, Figure 2 c and Figure 2 d are schematic diagrams of the cracking problem, Figure 2 e is a schematic diagram of the inter - face slit problem, Figure 2 f is a schematic diagram of the non - corresponding face boundary problem;
[0045] Figure 3 Schematic diagram of the structure of a specific framework hierarchy diagram disclosed in the present application;
[0046] Figure 4 Flowchart of a specific process for deriving specific objects based on virtual edges and virtual faces disclosed in the present application;
[0047] Figure 5 Schematic diagram of the structure of a mesh generation device based on a watertight mesh framework disclosed in the present application;
[0048] Figure 6 Schematic diagram of the structure of an electronic device disclosed in the present application. Detailed implementation manners
[0049] The following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative efforts belong to the scope of protection of the present invention.
[0050] Currently, the geometric processing method directly changes the real geometric structure of the solid model using digital modeling software, and the steps are usually very complex and costly. In addition, although some literature deals with dirty geometry problems on discrete grids, the conformality of the subsequent modified grids can only reach the conformality of the initial grid generation, and there is no face information, few means to adjust the grid density, difficult to finely adjust the area, and there is no concept of a hierarchical framework. For this reason, the present application provides a grid generation method based on a watertight grid framework, which can improve the quality and speed of target grid generation.
[0051] See Figure 1 As shown, an embodiment of the present invention discloses a grid generation method based on a watertight grid framework, which is applied to a watertight grid framework including a preset real geometry layer, a preset discrete geometry layer, a preset virtual geometry layer, and a preset grid generation layer. The method includes:
[0052] Step S11: Store the CAD object to be meshed in the preset real geometry layer, and send the CAD object to be meshed to the preset discrete geometry layer; the CAD object to be meshed includes CAD digital model points, CAD digital model lines, CAD digital model faces, and topological association information.
[0053] In a specific embodiment, due to reasons such as the accuracy differences between various modeling software during the three-dimensional modeling of an aircraft, various dirty geometry problems such as messy boundaries and gaps between faces will occur during the composition of the model, and the schematic diagrams of the above various dirty geometry problems are as Figure 2 shown: Figure 2 a is the problem of fragmented faces, Figure 2 b is the problem of messy boundaries, Figure 2 c and Figure 2 d are the problems of cracking, Figure 2 e is the problem of narrow slits between faces, Figure 2 f is the problem of non-corresponding face boundaries.
[0054] It is worth mentioning that to solve the above-mentioned dirty geometry problems that occur during the three-dimensional modeling of an aircraft, the embodiment of the present application designs a framework hierarchy diagram, and the structural schematic diagram of the framework hierarchy diagram is as Figure 3 shown: from bottom to top are the real geometry layer, the discrete geometry layer, the virtual geometry layer, and the grid generation layer.
[0055] Among them, the real geometry layer is used to analyze the real geometry to obtain specific underlying CAD objects corresponding to the real geometry, such as CAD digital model points, CAD digital model lines, CAD digital model surfaces, and topological association information. Specifically, storing the CAD object of the mesh to be generated in the preset real geometry layer and sending the CAD object of the mesh to be generated to the preset discrete geometry layer may include: analyzing the real geometry in the preset real geometry layer to obtain the CAD object of the mesh to be generated, and sending the CAD object of the mesh to be generated to the preset discrete geometry layer; the CAD object of the mesh to be generated includes CAD digital model points, CAD digital model lines, CAD digital model surfaces, and topological association information; among them, the CAD digital model point is a geometric shape unit corresponding to the real geometry, the CAD digital model line is a digital model line determined based on each CAD digital model point and used to describe the edges and contours of the real geometry, the CAD digital model surface is a digital model surface determined based on each CAD digital model line, and the topological association information is used to describe the connection relationship and hierarchical structure among each CAD digital model point, each CAD digital model line, and each CAD digital model surface.
[0056] Step S12, process the CAD object of the mesh to be generated in the preset discrete geometry layer to obtain discrete data corresponding to the CAD object of the mesh to be generated, and send the discrete data to the preset virtual geometry layer; the discrete data includes discrete points, discrete edges, and discrete surfaces corresponding to the CAD object of the mesh to be generated.
[0057] In this embodiment, after obtaining the CAD object of the mesh to be generated corresponding to the real geometry during the three-dimensional modeling of the aircraft, the embodiment of the present application needs to construct discrete geometry layer objects and topological relationships according to the original digital model data corresponding to the real geometry, such as discrete geometry layer objects such as discrete points, discrete edges, and discrete surfaces. Among them, the data of each object comes from the real geometry, and each geometry layer object retains the necessary information for digital model display and mesh generation. It is worth mentioning that the data stored in the discrete geometry layer is the discrete data of specific geometric objects such as CAD points, lines, and surfaces obtained after analysis. In a specific implementation manner, the STL format data has no topological relationship information and edge information between patches, but only records the vertex information and the number of each vertex constituting the patch one by one, so as to reduce the complexity of the data and reduce the data volume. Specifically, processing the CAD object of the mesh to be generated in the preset discrete geometry layer to obtain discrete data corresponding to the CAD object of the mesh to be generated may include: processing each CAD digital model point, each CAD digital model line, each CAD digital model surface, and the corresponding topological association information in the preset discrete geometry layer to obtain discrete points, discrete edges, and discrete surfaces corresponding to the CAD object of the mesh to be generated; among them, the discrete edge is a discrete edge formed based on a plurality of discrete points, the directions corresponding to each discrete point, and a preset end point, and the discrete surface is composed of discrete triangles and a boundary loop composed of a plurality of discrete edges.
[0058] Step S13: Operate on the discrete data in the preset virtual geometry layer based on a preset virtual topology operation to obtain a virtual geometry operation processing object, and send the virtual geometry operation processing object to the preset mesh generation layer; the virtual geometry operation processing object includes virtual points, virtual edges, virtual loops, and virtual faces corresponding to the discrete data.
[0059] In this embodiment, after obtaining the discrete points, discrete edges, and discrete faces in the to-be-generated mesh CAD object corresponding to the three-dimensional modeling result of the aircraft, the embodiments of the present application need to send the discrete points, discrete edges, and discrete faces corresponding to the to-be-generated mesh CAD object to the virtual geometry layer to store the operation processing object and the preset virtual topology operation in the virtual geometry layer. Among them, the specific operation processing object of the virtual geometry is separated from the real geometry as a separate object. Specifically, operating on the discrete data in the preset virtual geometry layer based on a preset virtual topology operation to obtain a virtual geometry operation processing object may include: establishing virtual points, virtual edges, virtual loops, and virtual faces in the preset virtual geometry layer based on topological association information and discrete data, and operating on each virtual point, each virtual edge, each virtual loop, and each virtual face in the preset virtual geometry layer based on the preset virtual topology operation to obtain a virtual geometry operation processing object; among them, the virtual topology operation includes performing splitting operations, merging operations, and deletion operations on each virtual point, each virtual edge, each virtual loop, and each virtual face, and establishing topological connection relationships for each virtual edge.
[0060] In this embodiment, it is necessary to obtain the corresponding data from the objects and topological relationships in the discrete geometry layer to construct the objects in the virtual geometry layer, and at the same time perform corresponding processing on the data, that is, perform corresponding processing on the dirty geometry phenomenon that occurs during the process of three-dimensional modeling of the aircraft. In a specific implementation manner, when the dirty geometry phenomenon that occurs during the process of three-dimensional modeling of the aircraft is face merging, the embodiments of the present application can perform topological edge merging and discrete data merging. Further, in order to generate a watertight mesh in the mesh generation layer, the embodiments of the present application need to implement the topological connection relationship of the edges in the virtual geometry layer. In addition, in order to adapt to different dirty geometry scenarios, both virtual edges and virtual faces can derive specific objects adapted to different scenarios, such as Figure 4As shown: The virtual edges are derived from the virtual edges constructed based on discrete points and the virtual edges constructed based on the parametric lines corresponding to specific positions of the digital model. The virtual surfaces can be derived into the hole-filling property surfaces and the surfaces with the properties of the original digital model. Specifically, establishing virtual edges based on topological association information and discrete data in the preset virtual geometry layer may include: deriving the virtual edges constructed based on the corresponding discrete points in the preset virtual geometry layer based on topological association information and discrete data; or, deriving parametric lines using the preset digital model in the preset virtual geometry layer at specific positions of the preset digital model to construct the corresponding virtual edges based on the parametric lines; correspondingly, establishing virtual surfaces based on topological association information and discrete data in the preset virtual geometry layer includes: deriving the hole-filling property virtual surfaces and / or the virtual surfaces with the properties of the original digital model in the preset virtual geometry layer using the preset geometric model and based on topological association information and discrete data.
[0061] Step S14: Use a preset grid generation algorithm in the preset grid generation layer to perform a grid generation operation on the virtual geometry operation processing object to obtain a target grid corresponding to the CAD object of the grid to be generated.
[0062] In this embodiment, after obtaining the virtual geometry operation processing object corresponding to the three-dimensional modeling result of the aircraft, the embodiment of the present application needs to use a preset grid generation algorithm in the preset grid generation layer to perform a grid generation operation on the virtual geometry operation processing object to obtain a target grid corresponding to the CAD object of the grid to be generated. Specifically, using a preset grid generation algorithm in the preset grid generation layer to perform a grid generation operation on the virtual geometry operation processing object to obtain a target grid corresponding to the CAD object of the grid to be generated may include: using a preset grid generation algorithm in the preset grid generation layer to perform a grid generation operation on the virtual geometry operation processing object to obtain an initial grid corresponding to the CAD object of the grid to be generated; the initial grid has boundary information and face information; using a preset quality optimization algorithm and based on the boundary information and face information corresponding to the initial grid to perform quality optimization on the initial grid to obtain the target grid.
[0063] Further, after obtaining the target mesh corresponding to the mesh CAD object to be generated, the embodiment of the present application needs to optimize the quality of the target mesh corresponding to the three-dimensional modeling result of the aircraft. Specifically, in the preset mesh generation layer, using the preset mesh generation algorithm to perform a mesh generation operation on the virtual geometry operation processing object to obtain the target mesh corresponding to the mesh CAD object to be generated, which may include: in the preset mesh generation layer, using the preset mesh generation algorithm to perform a mesh generation operation on the virtual geometry operation processing object to obtain the virtual geometry digital model corresponding to the mesh CAD object to be generated, and using the virtual geometry digital model and based on the mesh CAD object to be generated to generate the target mesh; wherein, the preset mesh generation algorithm includes a boundary discretization algorithm and a surface mesh generation algorithm of Delaunay-AFT (Delaunay-Advancing Front Technique, which is a mesh generation algorithm).
[0064] It can be seen that the embodiment of the present application first needs to store the mesh CAD object to be generated in the preset real geometry layer and send the mesh CAD object to be generated to the preset discrete geometry layer; then, in the preset discrete geometry layer, process the mesh CAD object to be generated to obtain the discrete data corresponding to the mesh CAD object to be generated, and send the discrete data to the preset virtual geometry layer; furthermore, based on the preset virtual topology operation, operate on the discrete data in the preset virtual geometry layer to obtain the virtual geometry operation processing object, and send the virtual geometry operation processing object to the preset mesh generation layer; finally, in the preset mesh generation layer, use the preset mesh generation algorithm to perform a mesh generation operation on the virtual geometry operation processing object to obtain the target mesh corresponding to the mesh CAD object to be generated. In this way, the quality and speed of target mesh generation are improved.
[0065] Correspondingly, as shown in Figure 5 The present application further provides a mesh generation device based on a watertight mesh framework, which is applied to a watertight mesh framework including a preset real geometry layer, a preset discrete geometry layer, a preset virtual geometry layer, and a preset mesh generation layer. The device includes:
[0066] A mesh CAD object determination module 11, configured to store the mesh CAD object to be generated in the preset real geometry layer and send the mesh CAD object to be generated to the preset discrete geometry layer; the mesh CAD object to be generated includes CAD digital model points, CAD digital model lines, CAD digital model surfaces, and topological association information;
[0067] The discrete data determination module 12 is configured to process the to-be-generated mesh CAD object in the preset discrete geometry layer to obtain discrete data corresponding to the to-be-generated mesh CAD object, and send the discrete data to the preset virtual geometry layer; the discrete data includes discrete points, discrete edges, and discrete faces corresponding to the to-be-generated mesh CAD object.
[0068] The operation processing object determination module 13 is configured to perform operations on the discrete data in the preset virtual geometry layer based on a preset virtual topology operation to obtain a virtual geometry operation processing object, and send the virtual geometry operation processing object to the preset mesh generation layer; the virtual geometry operation processing object includes virtual points, virtual edges, virtual loops, and virtual faces corresponding to the discrete data.
[0069] The target mesh generation module 14 is configured to perform a mesh generation operation on the virtual geometry operation processing object in the preset mesh generation layer by using a preset mesh generation algorithm to obtain a target mesh corresponding to the to-be-generated mesh CAD object.
[0070] As can be seen from the above, before performing mesh generation based on the watertight mesh framework in the embodiments of the present application, it is first necessary to store the to-be-generated mesh CAD object in the preset real geometry layer and send the to-be-generated mesh CAD object to the preset discrete geometry layer; subsequently, process the to-be-generated mesh CAD object in the preset discrete geometry layer to obtain discrete data corresponding to the to-be-generated mesh CAD object, and send the discrete data to the preset virtual geometry layer; furthermore, perform operations on the discrete data in the preset virtual geometry layer based on a preset virtual topology operation to obtain a virtual geometry operation processing object, and send the virtual geometry operation processing object to the preset mesh generation layer; finally, perform a mesh generation operation on the virtual geometry operation processing object in the preset mesh generation layer by using a preset mesh generation algorithm to obtain a target mesh corresponding to the to-be-generated mesh CAD object. In this way, the quality and speed of target mesh generation are improved.
[0071] In some specific embodiments, the mesh CAD object determination module 11 may specifically include:
[0072] The grid CAD object determination subunit is used to analyze the real geometry in the preset real geometry layer to obtain the to-be-generated grid CAD object, and send the to-be-generated grid CAD object to the preset discrete geometry layer; the to-be-generated grid CAD object includes CAD digital model points, CAD digital model lines, CAD digital model surfaces, and topological association information; wherein, the CAD digital model point is a geometric shape unit corresponding to the real geometry, the CAD digital model line is a digital model line determined based on each CAD digital model point and used to describe the edges and contours of the real geometry, the CAD digital model surface is a digital model surface determined based on each CAD digital model line, and the topological association information is used to describe the connection relationships and hierarchical structures among each CAD digital model point, each CAD digital model line, and each CAD digital model surface.
[0073] In some specific embodiments, the discrete data determination module 12 may specifically include:
[0074] The discrete data determination subunit is used to process each CAD digital model point, each CAD digital model line, each CAD digital model surface, and the corresponding topological association information in the preset discrete geometry layer respectively to obtain discrete points, discrete edges, and discrete surfaces corresponding to the to-be-generated grid CAD object; wherein, the discrete edge is a discrete edge formed based on a plurality of discrete points, the directions corresponding to each discrete point, and a preset end point, and the discrete surface is composed of discrete triangles and a boundary loop formed by a plurality of the discrete edges.
[0075] In some specific embodiments, the operation processing object determination module 13 may specifically include:
[0076] The operation processing object determination subunit is used to establish virtual points, virtual edges, virtual loops, and virtual surfaces in the preset virtual geometry layer based on the topological association information and the discrete data, and perform operations on each virtual point, each virtual edge, each virtual loop, and each virtual surface in the preset virtual geometry layer based on preset virtual topology operations to obtain virtual geometry operation processing objects; wherein, the virtual topology operations include performing splitting operations, merging operations, and deletion operations on each virtual point, each virtual edge, each virtual loop, and each virtual surface, and establishing topological connection relationships for each virtual edge.
[0077] In some specific embodiments, the operation processing object determination module 13 may specifically include:
[0078] The first virtual edge determination unit is used to derive virtual edges constructed based on the corresponding discrete points in the preset virtual geometry layer based on the topological association information and the discrete data;
[0079] A second virtual edge determination unit, configured to derive parametric lines at specific positions of a preset digital model in a preset mathematical model in the preset virtual geometric layer, and construct corresponding virtual edges based on the parametric lines.
[0080] Correspondingly, in some specific embodiments, the operation processing object determination module 13 may further include:
[0081] A virtual surface determination unit, configured to derive virtual surfaces with hole-filling properties and / or virtual surfaces with original digital model properties in the preset virtual geometric layer by using a preset geometric model and based on the topological association information and the discrete data.
[0082] In some specific embodiments, the target mesh generation module 14 may specifically include:
[0083] An initial mesh determination unit, configured to perform a mesh generation operation on the virtual geometric operation processing object by using a preset mesh generation algorithm in the preset mesh generation layer, to obtain an initial mesh corresponding to the CAD object of the mesh to be generated; the initial mesh has boundary information and face information.
[0084] A target mesh generation subunit, configured to perform quality optimization on the initial mesh by using a preset quality optimization algorithm and based on the boundary information and the face information corresponding to the initial mesh, to obtain a target mesh.
[0085] In some specific embodiments, the target mesh generation module 14 may specifically include:
[0086] A virtual geometric digital model determination unit, configured to perform a mesh generation operation on the virtual geometric operation processing object by using a preset mesh generation algorithm in the preset mesh generation layer, to obtain a virtual geometric digital model corresponding to the CAD object of the mesh to be generated, and generate a target mesh by using the virtual geometric digital model and based on the CAD object of the mesh to be generated; wherein, the preset mesh generation algorithm includes a boundary discretization algorithm and a surface mesh generation algorithm of Delaunay-AFT.
[0087] Furthermore, an embodiment of the present application also discloses an electronic device. Figure 6 It is a structural diagram of an electronic device 20 shown according to an exemplary embodiment, and the content in the figure cannot be considered as any limitation to the scope of use of the present application. The electronic device 20 may specifically include: at least one processor 21, at least one memory 22, a power supply 23, a communication interface 24, an input / output interface 25, and a communication bus 26. Among them, the memory 22 is used to store a computer program, and the computer program is loaded and executed by the processor 21 to implement the relevant steps in the mesh generation method based on a watertight mesh framework disclosed in any of the foregoing embodiments. In addition, the electronic device 20 in this embodiment may specifically be an electronic computer.
[0088] In this embodiment, the power supply 23 is used to provide operating voltages for each hardware device on the electronic device 20; the communication interface 24 can create a data transmission channel between the electronic device 20 and external devices, and the communication protocol it follows can be any communication protocol applicable to the technical solution of this application, and no specific limitation is imposed thereon here; the input / output interface 25 is used to obtain external input data or output data to the outside, and its specific interface type can be selected according to specific application requirements, and no specific limitation is imposed here.
[0089] In addition, the memory 22, as a carrier for resource storage, can be a read-only memory, a random access memory, a magnetic disk, an optical disc, etc., and the resources stored thereon can include an operating system 221, a computer program 222, etc., and the storage method can be transient storage or permanent storage.
[0090] Among them, the operating system 221 is used to manage and control each hardware device and the computer program 222 on the electronic device 20, and it can be Windows Server, Netware, Unix, Linux, etc. In addition to the computer program capable of implementing the mesh generation method based on the watertight mesh framework executed by the electronic device 20 disclosed in any of the foregoing embodiments, the computer program 222 can further include computer programs capable of performing other specific tasks.
[0091] Furthermore, this application also discloses a computer-readable storage medium for storing a computer program; wherein, when the computer program is executed by a processor, it implements the foregoing disclosed mesh generation method based on the watertight mesh framework. For the specific steps of this method, reference can be made to the corresponding content disclosed in the foregoing embodiments, and details are not described herein again.
[0092] In this specification, the various embodiments are described in a progressive manner, and the key point of each embodiment is to illustrate the differences from other embodiments. For the same or similar parts between the various embodiments, reference can be made to each other. For the device disclosed in the embodiments, since it corresponds to the method disclosed in the embodiments, the description is relatively simple, and reference can be made to the description in the method part for related parts.
[0093] Those skilled in the art may further realize that the units and algorithm steps of each example described in connection with the embodiments disclosed herein can be implemented by electronic hardware, computer software, or a combination of the two. To clearly illustrate the interchangeability of hardware and software, the components and steps of each example have been generally described according to their functions in the above description. Whether these functions are executed in a hardware or software manner depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered to exceed the scope of this application.
[0094] The steps of the methods or algorithms described in connection with the embodiments disclosed herein can be directly implemented by hardware, software modules executed by a processor, or a combination of the two. The software modules can be placed in a random access memory (RAM), internal memory, read-only memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disk, removable disk, CD-ROM, or any other form of storage medium known in the art.
[0095] Finally, it should also be noted that in this document, relational terms such as "first" and "second" are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any actual relationship or order between these entities or operations. Moreover, the term "comprising", "including" or any other variation thereof is intended to cover non-exclusive inclusion, so that a process, method, article or device comprising a series of elements includes not only those elements, but also other elements not expressly listed, or elements inherent to such process, method, article or device. Without further limitation, an element defined by the statement "comprising an..." does not exclude the presence of additional identical elements in the process, method, article or device comprising the element.
[0096] The technical solutions provided in this application have been introduced in detail above. Specific examples are used herein to elaborate on the principles and implementation manners of this application. The description of the above embodiments is only used to help understand the method and its core idea of this application; at the same time, for those of ordinary skill in the art, according to the idea of this application, there will be changes in the specific implementation manners and application scopes. In summary, the content of this specification should not be construed as a limitation to this application.
Claims
1. A grid generation method based on a watertight grid framework, characterized in that, Applied to a watertight mesh framework including a preset real geometry layer, a preset discrete geometry layer, a preset virtual geometry layer, and a preset mesh generation layer, the method includes: Storing a CAD object to be meshed in the preset real geometry layer and sending the CAD object to be meshed to the preset discrete geometry layer; the CAD object to be meshed includes CAD digital model points, CAD digital model lines, CAD digital model surfaces, and topological association information; Processing the CAD object to be meshed in the preset discrete geometry layer to obtain discrete data corresponding to the CAD object to be meshed, and sending the discrete data to the preset virtual geometry layer; the discrete data includes discrete points, discrete edges, and discrete surfaces corresponding to the CAD object to be meshed; Operating on the discrete data in the preset virtual geometry layer based on preset virtual topology operations to obtain a virtual geometry operation processing object, and sending the virtual geometry operation processing object to the preset mesh generation layer; the virtual geometry operation processing object includes virtual points, virtual edges, virtual loops, and virtual surfaces corresponding to the discrete data; Performing a mesh generation operation on the virtual geometry operation processing object in the preset mesh generation layer using a preset mesh generation algorithm to obtain a target mesh corresponding to the CAD object to be meshed; Wherein, the operating on the discrete data in the preset virtual geometry layer based on preset virtual topology operations to obtain a virtual geometry operation processing object includes: establishing virtual points, virtual edges, virtual loops, and virtual surfaces in the preset virtual geometry layer based on the topological association information and the discrete data, and operating on each of the virtual points, each of the virtual edges, each of the virtual loops, and each of the virtual surfaces in the preset virtual geometry layer based on preset virtual topology operations to obtain a virtual geometry operation processing object; wherein, the preset virtual topology operations include performing splitting operations, merging operations, and deleting operations on each of the virtual points, each of the virtual edges, each of the virtual loops, and each of the virtual surfaces, and establishing topological connection relationships for each of the virtual edges.
2. The mesh generation method based on a watertight grid framework according to claim 1, wherein The storing a CAD object to be meshed in the preset real geometry layer and sending the CAD object to be meshed to the preset discrete geometry layer includes: Analyzing the real geometry in the preset real geometry layer to obtain the CAD object to be meshed, and sending the CAD object to be meshed to the preset discrete geometry layer; the CAD object to be meshed includes CAD digital model points, CAD digital model lines, CAD digital model surfaces, and topological association information; Wherein, the CAD digital model points are geometric shape units corresponding to the real geometry, the CAD digital model lines are digital model lines determined based on each of the CAD digital model points for describing the edges and contours of the real geometry, the CAD digital model surfaces are digital model surfaces determined based on each of the CAD digital model lines, and the topological association information is used to describe the connection relationships and hierarchical structures among each of the CAD digital model points, each of the CAD digital model lines, and each of the CAD digital model surfaces.
3. The mesh generation method based on a watertight grid framework according to claim 2, wherein Processing the CAD object with the mesh to be generated in the preset discrete geometry layer to obtain discrete data corresponding to the CAD object with the mesh to be generated, including: Processing each CAD digital model point, each CAD digital model line, each CAD digital model surface and the corresponding topological association information in the preset discrete geometry layer to obtain discrete points, discrete edges and discrete surfaces corresponding to the CAD object with the mesh to be generated; Wherein, the discrete edge is a discrete edge formed by a plurality of discrete points, the directions corresponding to the discrete points and preset end points, and the discrete surface is composed of discrete triangles and a boundary loop composed of a plurality of the discrete edges.
4. The mesh generation method based on a watertight grid framework according to claim 1, characterized in that, Establishing virtual edges based on the topological association information and the discrete data in the preset virtual geometry layer, including: Deriving virtual edges constructed based on the corresponding discrete points in the preset virtual geometry layer based on the topological association information and the discrete data; Or, in the preset virtual geometry layer, using the preset parameter line derived from a specific position of the preset digital model in the preset mathematical model to construct the corresponding virtual edge based on the parameter line; Correspondingly, establishing virtual surfaces based on the topological association information and the discrete data in the preset virtual geometry layer, including: In the preset virtual geometry layer, using the preset geometric model and deriving virtual surfaces with hole-filling properties and / or virtual surfaces with the properties of the original digital model based on the topological association information and the discrete data.
5. The mesh generation method based on a watertight grid framework according to any one of claims 1 to 4, characterized in that, Performing a mesh generation operation on the virtual geometry operation processing object by using a preset mesh generation algorithm in the preset mesh generation layer to obtain a target mesh corresponding to the CAD object with the mesh to be generated, including: Performing a mesh generation operation on the virtual geometry operation processing object by using a preset mesh generation algorithm in the preset mesh generation layer to obtain an initial mesh corresponding to the CAD object with the mesh to be generated; the initial mesh has boundary information and surface information; Using a preset quality optimization algorithm and optimizing the quality of the initial mesh based on the boundary information and the surface information corresponding to the initial mesh to obtain a target mesh.
6. The mesh generation method based on the watertight grid framework according to claim 5, characterized in that Performing a mesh generation operation on the virtual geometry operation processing object by using a preset mesh generation algorithm in the preset mesh generation layer to obtain a target mesh corresponding to the CAD object with the mesh to be generated, including: Performing a mesh generation operation on the virtual geometry operation processing object by using a preset mesh generation algorithm in the preset mesh generation layer to obtain a virtual geometry digital model corresponding to the CAD object with the mesh to be generated, and generating a target mesh by using the virtual geometry digital model and based on the CAD object with the mesh to be generated; Wherein, the preset mesh generation algorithm includes a boundary discretization algorithm and a surface mesh generation algorithm of Delaunay-AFT.
7. A grid generation device based on a watertight grid framework, characterized in that, Applied to a watertight mesh framework including a preset real geometry layer, a preset discrete geometry layer, a preset virtual geometry layer and a preset mesh generation layer, the device includes: A grid CAD object determination module, configured to store a grid CAD object to be generated in the preset real geometry layer, and send the grid CAD object to be generated to the preset discrete geometry layer; the grid CAD object to be generated includes CAD digital model points, CAD digital model lines, CAD digital model surfaces, and topological association information; A discrete data determination module, configured to process the grid CAD object to be generated in the preset discrete geometry layer to obtain discrete data corresponding to the grid CAD object to be generated, and send the discrete data to the preset virtual geometry layer; the discrete data includes discrete points, discrete edges, and discrete surfaces corresponding to the grid CAD object to be generated; An operation processing object determination module, configured to perform operations on the discrete data in the preset virtual geometry layer based on a preset virtual topology operation to obtain a virtual geometry operation processing object, and send the virtual geometry operation processing object to the preset grid generation layer; the virtual geometry operation processing object includes virtual points, virtual edges, virtual loops, and virtual surfaces corresponding to the discrete data; A target grid generation module, configured to perform a grid generation operation on the virtual geometry operation processing object in the preset grid generation layer by using a preset grid generation algorithm to obtain a target grid corresponding to the grid CAD object to be generated; Wherein, the apparatus is specifically further configured to perform operations on the discrete data in the preset virtual geometry layer based on a preset virtual topology operation to obtain a virtual geometry operation processing object, including: establishing virtual points, virtual edges, virtual loops, and virtual surfaces in the preset virtual geometry layer based on the topological association information and the discrete data, and performing operations on each of the virtual points, each of the virtual edges, each of the virtual loops, and each of the virtual surfaces in the preset virtual geometry layer based on a preset virtual topology operation to obtain a virtual geometry operation processing object; wherein, the preset virtual topology operation includes performing splitting operations, merging operations, and deletion operations on each of the virtual points, each of the virtual edges, each of the virtual loops, and each of the virtual surfaces, and establishing topological connection relationships for each of the virtual edges.
8. An electronic device, characterized in that, Including: A memory, configured to store a computer program; A processor, configured to execute the computer program to implement the grid generation method based on a watertight grid framework according to any one of claims 1 to 7.
9. A computer-readable storage medium, characterized in that, For storing a computer program, wherein the computer program, when executed by a processor, implements the grid generation method based on a watertight grid framework according to any one of claims 1 to 7.
Citation Information
Patent Citations
Curved surface grid generation method and device, equipment and storage medium
CN116720234A
Error-controllable parametric curved surface grid generation method
CN116797762A