A fluid simulation method for complex structures

By converting complex structures into triangular element polyhedral model and simplifying them into pentahedral calculations using projection method, the calculation efficiency and accuracy problems when complex structures intersect with cuboid mesh are solved, and efficient and accurate fluid simulation is achieved.

CN116451493BActive Publication Date: 2025-08-15ZHEJIANG UNIV +1
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202310454924.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-04-25
Publication Date
2025-08-15
Estimated Expiration
2043-04-25

AI Technical Summary

Technical Problem

The prior art has low computational efficiency and low accuracy when dealing with intersecting complex structures with cuboid mesh, especially in fluid flow problems involving dynamic boundaries, resulting in unconserved fluid mass and false pressure fluctuations.

Method used

The complex structure is converted into a multihedral model composed of triangular elements, and the positional relationship with the cuboid mesh is judged. The intersection body is converted into a simple pentahedral for calculation through projection method, and the volume estimation is performed based on the outer normal direction and the projected base surface.

Benefits of technology

While ensuring the calculation accuracy, it greatly improves the calculation efficiency, reduces false pressure fluctuations, and improves the numerical simulation accuracy of the fluid simulation method.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116451493B_ABST
    Figure CN116451493B_ABST
Patent Text Reader

Abstract

The present invention discloses a fluid simulation method for complex structures, comprising the following steps: converting the complex structure into a polyhedron model composed of triangular face units; determining the positional relationship between the polyhedron model and a rectangular grid; re-dividing the intersecting body into a new polyhedron composed of triangular face units, and obtaining the external normal directions of all triangular face units; projecting all triangular face units onto one face of the rectangular grid; projecting the triangular face units onto the bottom surface of the grid, where the projected body is a pentahedron, and summing the volumes of the pentahedrons obtained by projecting all the triangular face units to obtain the volume of the intersecting body. The method of the present invention is used to solve the problem of how to accurately and efficiently solve the volume of the intersecting body when a complex structure intersects with a rectangular grid, and can significantly improve the calculation efficiency while ensuring the calculation accuracy.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of fluid physics testing, and in particular relates to a fluid simulation method for complex structures. Background Art

[0002] When using the lattice Boltzmann method (LBM) to solve fluid flow problems, complex boundaries—those with complex geometric structures—are often encountered. Researchers have proposed various methods to address fluid-structure interaction problems with complex boundaries, such as the immersed boundary method (IBM), the SBB (Simple Bounce-Back) method (based on the BB (Bounce-Back) method), and the IBB (Interpolated Bounce-Back) method. However, for fluid flow problems involving moving boundaries, most boundary methods can cause mass violations due to boundary motion, leading to spurious pressure fluctuations and ultimately affecting the numerical accuracy of the LBM simulation. To address this issue, researchers have proposed boundary methods that can improve the simulation accuracy of moving boundary problems, such as the Partially Saturated Method (PSM) and the IMB (Immersed Moving Boundary) method. These methods incorporate the solid fraction of the grid to modify the collision term in the lattice Boltzmann equation, ensuring mass conservation and avoiding spurious pressure fluctuations, thereby improving the numerical accuracy of the LBM simulation.

[0003] As mentioned above, when using methods such as PSM and IMB to address boundary problems, the solid content of each fluid grid must be determined. For some relatively simple boundaries, such as circular boundaries in two-dimensional space, the theoretical value of the solid content can be directly calculated. For solid boundaries with more complex geometric structures, researchers have previously used numerical integration methods to calculate the solid content of the grid, but the geometric structures of related research are still relatively simple, such as spherical boundaries in three-dimensional space. This phenomenon is related to the low computational efficiency of numerical integration methods, resulting in unacceptable computational efficiency for LBM numerical simulations involving very complex boundary geometries.

[0004] The academic paper "Fast computation of accurate sphere-cube intersection volume" [J]. Engineering Computations, 1984, discloses various methods for calculating the volume of large spherical particles mapped onto a Cartesian grid of smaller cells. It also proposes a more efficient linear relationship, which is included in this comparison to optimize the calculation process. However, all the estimation methods disclosed in this paper suffer from large errors and require repeated iterative calculations at each boundary, which is very time-consuming.

[0005] The academic paper "A coupled 3-dimensional bonded discrete element and lattice Boltzmann method for fluid-solid coupling in cohesive geomaterials[J].International Journal for Numerical and Analytical Methods in Geomechanics, 2018, 42" describes a three-dimensional coupled discrete element and lattice Boltzmann method for solving complex fluid-solid coupling problems in geomaterials. To bridge the gap between theory and application, a three-dimensional immersed moving boundary scheme algorithm is proposed to resolve fluid-particle interactions. However, this method still requires repeated calculations during the boundary solution process. Since the results for each point are obtained through independent iterative calculations, the final results are not very accurate. Summary of the Invention

[0006] The purpose of the present invention is to find an algorithm that can accurately and efficiently solve the volume of the intersection of a complex structure and a rectangular grid.

[0007] In order to achieve the object of the present invention, the present invention provides a fluid simulation method for a complex structure, comprising the following steps:

[0008] For complex structures, a polyhedron model consisting of multiple triangular face units is constructed.

[0009] The polyhedron model is placed in a fluid test space composed of multiple square grids, and the positional relationship between the polyhedron model and the fluid test space is determined to obtain a first intersection body equal to the volume of a single square grid and a second intersection body partially intersecting with the single square grid.

[0010] For the second intersection body, an intersection polyhedron composed of a plurality of triangular surface units and the external normal directions of all triangular surface units in the intersection polyhedron are constructed.

[0011] Based on the preset projection base surface, the triangular surface units in all intersecting polyhedrons are projected in the same projection direction to obtain the pentahedron corresponding to each triangular surface unit.

[0012] All pentahedrons are merged according to the external normals and the projection direction to obtain estimated volumes of all intersecting polyhedrons.

[0013] The volume of the first intersecting body is added to the estimated volume to obtain a spatial volume parameter of the complex structure, and a fluid simulation is performed on the complex structure in the fluid test space to obtain a corresponding simulation result.

[0014] The present invention converts the original complex intersecting polyhedron into a simpler pentahedron for calculation by judging the positional relationship of each face of the intersecting body, thereby simplifying the volume estimation process while ensuring the accuracy of the final result.

[0015] Specifically, the intersecting polyhedron is composed of a cross section formed by a polyhedron model and a square mesh surface, and a plurality of intersecting surfaces intersecting with the square mesh surface.

[0016] Specifically, the cross-section acquisition process includes the following steps:

[0017] First, determine the edges formed by the intersection of the square mesh surface and the faces of the polyhedron model, select one of the edges as the first cross-sectional edge, and use the two endpoints of the first cross-sectional edge as a and b, then select the edge bc that contains the endpoint b and does not coincide with the first cross-sectional edge as the second cross-sectional edge of the cross-section, and repeat the connection point finding and connection process until a complete cross-sectional area is obtained.

[0018] Specifically, the process of obtaining the multiple intersecting surfaces includes the following steps:

[0019] First, arbitrarily select an edge of the intersecting surface as the first intersecting surface edge, then connect one endpoint of the first intersecting surface edge with other vertices of the intersecting surface, and determine the angle between each connecting line and the first intersecting surface edge. That is, the smaller the angle, the higher the order of the vertex. By connecting all the vertices of the intersecting surface in order, the shape of the intersecting surface can be determined.

[0020] Specifically, the merging process includes:

[0021] When the angle between the projection direction and the external normal direction is less than the threshold, the volume of the pentahedron corresponding to the triangular face is positive.

[0022] When the angle between the projection direction and the external normal direction is greater than the threshold, the volume of the pentahedron corresponding to the triangular face is negative.

[0023] When the angle between the projection direction and the external normal direction is equal to the threshold, the volume of the pentahedron corresponding to the triangular face is zero.

[0024] Specifically, the threshold is 90 degrees.

[0025] Specifically, if a triangular face of the intersecting polyhedron intersects a single face of the square grid, it is only necessary to project the opposite face of the projection base to obtain the corresponding pentahedron volume.

[0026] Specifically, if the intersecting polyhedron is a hollow structure, it is necessary to determine the positional relationship between the incenter of the triangle and the polyhedron model:

[0027] If the center point is located in the polyhedron model, the pentahedral volume of the triangular face is positive.

[0028] If the center point is outside the polyhedron model, the volume of the five faces of the triangle is negative.

[0029] Compared with the prior art, the present invention has the following beneficial effects:

[0030] By determining the positional relationship between the faces of the intersecting body, the original complex intersecting polyhedron is converted into a simpler pentahedron for calculation, thus solving the problem of how to accurately and efficiently solve the volume of the intersecting body when a complex structure intersects with a rectangular grid. This can greatly improve the calculation efficiency while ensuring the calculation accuracy. BRIEF DESCRIPTION OF THE DRAWINGS

[0031] Figure 1 Flowchart of the algorithm for calculating the volume of the intersection when a complex structure intersects a rectangular grid;

[0032] Figure 2 Schematic diagram of the intersection of the tetrahedron and the cuboid grid in Example 1;

[0033] Figure 3 Schematic diagram of the projection of the triangular surface on the intersecting body in Example 1;

[0034] Figure 4 Schematic diagram of the intersection of a sphere and a rectangular grid in Example 2;

[0035] Figure 5 This is a schematic diagram of the car rearview mirror model in Example 3;

[0036] Figure 6 This is a comparison chart of volume ratio deviations calculated by the algorithm and the numerical integration method in Example 3;

[0037] Figure 7 Schematic diagram of flow around a cylinder in Example 4;

[0038] Figure 8 The velocity distribution cloud diagram when the Reynolds number Re=10 in Example 4;

[0039] Figure 9 The velocity distribution cloud diagram when the Reynolds number Re=70 in Example 4;

[0040] Figure 10 The velocity distribution cloud diagram when the Reynolds number Re=100 in Example 4;

[0041] Figure 11 This is a comparison chart of the drag coefficient in Example 5. DETAILED DESCRIPTION

[0042] In order to make the technical means, creative features, objectives and effects achieved by the present invention easy to understand, the following implementation combines with the accompanying drawings to specifically explain an algorithm of the present invention for solving the intersection volume of a complex structure and a rectangular grid.

[0043] like Figure 1 The fluid simulation method for a complex structure comprises the following steps:

[0044] Convert complex structures into polyhedron models composed of triangular face units.

[0045] Determine the positional relationship between the polyhedron model and the cube mesh. If the mesh is outside the polyhedron model, the volume of the intersecting body is 0. If the mesh is inside the polyhedron, the volume of the intersecting body is the volume of the mesh. If the mesh intersects the polyhedron, the volume of the intersecting body is obtained by the following projection method.

[0046] The faces of intersecting bodies can be divided into two cases. The first is the intersecting faces obtained based on a single triangular face in the polyhedron model, including the faces formed by the intersection of a triangular face and a rectangular parallelepiped mesh, as well as the triangular faces that are completely within the mesh; the other is the cross-section obtained based on a single face of the mesh, including the faces formed by the intersection of a single face of the mesh and the polyhedron, as well as the cross-section that is completely within the polyhedron.

[0047] The intersecting surface obtained based on a single triangle in the polyhedron model: The judgment process is as follows: first, the positional relationship between each triangle of the original polyhedron model and the grid is judged. If the triangle is outside the grid, it will not be considered.

[0048] If the triangle is inside the mesh, then the triangle is a face of the intersection; if the triangle intersects the mesh, the shape of the intersection face must be determined.

[0049] For the intersection case, first arbitrarily select an edge of the intersecting surface; then, connect one endpoint of the edge to the other vertices of the intersecting surface, and determine the angle between each connecting line and this edge. The smaller the angle, the higher the order of the vertex. Finally, connect all the vertices of the intersecting surface in order to determine the shape of the intersecting surface.

[0050] Cross-sections obtained based on a single mesh face: First, determine the positional relationship between the mesh face and the polyhedron. If the mesh face is outside the polyhedron, it will not be considered.

[0051] If a mesh face is inside a polyhedron, then that mesh face is a face of the intersecting polyhedron.

[0052] If the mesh surface intersects with the polyhedron, the shape of the intersecting surface needs to be determined. For the intersection, first determine the edges formed by the intersection of the mesh surface and the faces of the polyhedron, select one of the edges as the first edge of the intersecting surface, and assume that the two endpoints of this edge are a and b respectively; then, select the edge bc that contains the endpoint b and does not coincide with the edge ab as the second edge of the intersecting surface; then, repeat the above steps to determine the other edges of the intersecting surface, such as the edge cd that does not coincide with both the edges ab and bc as the third edge of the intersecting surface; finally, connect all the edges in the above order to determine the shape of the intersecting surface. It should be noted that after the above steps are completed, there may still be edges that are not included in the above intersecting surfaces. This indicates that the mesh surface and the polyhedron intersect to generate multiple intersecting surfaces. At this time, the shapes of the other intersecting surfaces need to be determined. The determination process is the same as the steps for obtaining the intersecting surface based on a single triangle face in the polyhedron model, and will not be repeated here.

[0053] The intersecting body is re-divided into a new polyhedron composed of triangular face units, and the external normal directions of all triangular face units are obtained.

[0054] All triangular face units are projected onto one face of the cuboid mesh. The projected face is considered the bottom face of the mesh, and the mesh face opposite to the bottom face is called the top face of the mesh.

[0055] The projection of the triangular element onto the mesh base creates a pentahedron. To find the volume of the pentahedron, add the volumes of all the pentahedrons projected from the triangular elements to get the volume of the intersection.

[0056] In order to better illustrate the above technical solution, the intersection of tetrahedron and rectangular parallelepiped grid is further explained here.

[0057] Example 1

[0058] like Figure 2 and Figure 3 As shown, Figure 2 (a) is a schematic diagram of the intersection of tetrahedral AMNQ and rectangular grid. Figure 2(b) is the intersection of the two. The faces of the intersection can be divided into two categories. The first category is the faces obtained based on the single triangle face in the original polyhedron, including the faces ACDE obtained by intersecting the face AMN in the tetrahedron with the mesh, that is, Figure 3 (a) shows the surface AEFH obtained by intersecting the tetrahedron surface AMQ with the mesh, that is, Figure 3 (b) shows the surface ACBH obtained after the surface ANQ in the tetrahedron intersects with the grid, that is, Figure 3 (c) The second type is the surface obtained based on a single surface of the cuboid mesh, such as Figure 3 (d) shows the surface BGFH obtained by intersecting the upper surface of the mesh with the tetrahedron AMNQ.

[0059] For the first type of intersecting polygonal faces (see Figure 3 (a)~(c)), first divide the polygon into triangles, such as Figure 3 (a) Divide the intersecting polygon ACDE into triangles ACD and ADE. Figure 3 (b) Divide the intersecting polygon AEFH into triangular faces AEF and AFH, Figure 3 (c) Divide the intersecting polygon ACBH into triangular faces ACB and ABH, and determine the external normal vector n of each face. Project these triangular faces onto the base of the mesh and calculate the angle between the projection direction and the external normal vector n of the face. If the angle is less than 90 degrees, the projected volume of the triangular face is negative, as shown in the following example: Figure 3 (a); if the angle is greater than 90 degrees, the projected volume of the surface is positive, as shown in Figure 3 As shown in (b) and (c).

[0060] For the second type of intersecting polygonal faces (see Figure 3 (d)) Similarly, the polygon is first divided into triangles, namely triangle GFH and triangle GHB, and then the center of the triangle is determined. In this case, the center of triangle GFH and triangle GHB are both inside the tetrahedron, so the projected volume of the two triangles is positive. Finally, Figure 3 The volume of the intersecting volume is the sum of the volumes of all the projected volumes.

[0061] Example 2

[0062] like Figure 4 As shown in the figure, it is a schematic diagram of the intersection of a rectangular grid and a sphere. The volume of the intersection in the figure can be directly calculated to its theoretical value, such as Figure 4 The volume of the intersecting body of (a) and (b) can be calculated by the volume formula of a spherical segment. Figure 4 The intersection volume of (c) is one-fourth of the volume of the sphere. Its theoretical value is then compared with the numerical solution to verify the accuracy of the algorithm. Figure 4(a) Figure 4 (b) Figure 4 The theoretical values of the volume ratio of the intersecting body to the grid in (c) are 0.081812, 0.441776, and 0.065450, respectively. The volume ratios calculated by the algorithm proposed in the present invention are 0.081806, 0.441771, and 0.065447, respectively. By comparison, it can be seen that there is a certain error between the solution obtained by this algorithm and the theoretical value. This is mainly because the complex structures in this algorithm are composed of triangular face elements. Therefore, there will always be a certain deviation between the spherical structure in this algorithm and the real spherical structure, which in turn causes the above-mentioned error. But in general, the errors of the numerical solutions obtained by this algorithm relative to the theoretical values are very small, and the relative errors are all less than 0.001%, which can be ignored. In summary, the algorithm proposed in the present invention has very high accuracy in solving the volume of the intersecting body when a complex structure intersects with a rectangular grid.

[0063] Example 3

[0064] To test the computational efficiency of the numerical algorithm in this invention and further test its computational accuracy when processing complex structures, this case selected a car rearview mirror with a complex geometric structure for further verification.

[0065] like Figure 5 As shown, Figure 5 (a) is the car rearview mirror model, Figure 5 (b) Schematic diagram of the rearview mirror model divided into 9×15×15 rectangular grids.

[0066] Subsequently, we calculated the volume ratio of the rearview mirror model in each rectangular grid by numerical integration method and the algorithm proposed in this invention. The selected development application platform was VC++ and the processor model of the hardware platform was: Intel(R) Core(TM) i7-8565U CPU@1.80GHz.

[0067] The results are as follows Figure 6 The figure shows the deviation in volume ratio calculated by the two algorithms for a mesh with intersecting volumes. The two methods achieve essentially identical results, with an average deviation of only 0.0037% and a maximum deviation of only 0.0423%. However, there is a significant difference in computational efficiency between the two algorithms. The numerical integration method requires approximately 157 seconds, while this algorithm only takes approximately 20 seconds. In summary, this algorithm significantly improves computational efficiency while maintaining accuracy.

[0068] Example 4

[0069] The numerical algorithm proposed in this invention is applied to the classic flow experiments in the field of computational fluid dynamics, such as Figure 7As shown in the figure, this further verifies the application of this algorithm in computational fluid dynamics.

[0070] First, qualitative simulations were performed using the flow around a cylinder with Reynolds numbers Re = 10, 70, and 100. The simulation results are shown in Figure 2. Figures 8-10 As shown in Figure 2, the simulation results are basically consistent with the actual flow results.

[0071] In actual flow phenomena, the vortex formed by the fluid flow is closely related to the Reynolds number Re of the flow field.

[0072] like Figure 8 As shown in the figure, when the Reynolds number Re = 10, there are no large vortices in front of and behind the cylinder, the flow field motion is mainly laminar, the flow pattern is roughly symmetrically distributed, flow separation occurs on the leeward side of the obstacle cylinder, and there is a small amount of dead water area.

[0073] like Figure 9 As shown in Figure 2, at Re = 70, the flow separation behind the obstacle cylinder is more obvious, and the dead water area is elongated. The separated fluids merge downstream of the obstacle and form a clear and stable vortex trail.

[0074] like Figure 10 As shown in the figure, when Re=100, the fluid flowing along the obstacle surface quickly forms vortices in the dead water area after flow separation, and the vortex trails at low Reynolds numbers disappear and turn into a Karman vortex street formed by staggered vortices.

[0075] Example 5

[0076] The above-mentioned simulation test of flow around a cylinder preliminarily verifies the feasibility of this algorithm in flow field simulation applications by qualitatively analyzing the velocity cloud results of the flow field. This case will further quantitatively verify its accuracy in flow field calculation by calculating the drag coefficient Cd generated by the flow around obstacles of different shapes (sphere, ellipsoid, cube) in the flow field. The volume of the obstacle in the flow process is 1m 3 , the ratio of the long and short radii of the ellipsoid is 2. The drag coefficient values at different Reynolds numbers simulated by the improved PSM method of this algorithm are compared with the actual theoretical values.

[0077] Specific results such as Figure 11 As shown in the figure, it can be seen from the results that under different shapes, the drag coefficient results of this algorithm when simulating the flow process are very close to the actual theoretical value, which is consistent with the actual situation of the simulated fluid.

[0078] The description herein, in conjunction with the accompanying drawings and specific embodiments, is intended only to facilitate understanding of the method and core concepts of the present invention. The method described herein is not limited to the embodiments described in the specific embodiments. Other implementations derived by those skilled in the art based on the method and concepts of the present invention also fall within the scope of the technical innovation of the present invention. This description should not be construed as limiting the present invention.

Claims

1. A fluid simulation method for complex structures, characterized in that: The following steps are involved: For complex structures, a polyhedron model consisting of multiple triangular face units is constructed; Placing the polyhedron model in a fluid test space composed of a plurality of square grids, and determining a positional relationship between the polyhedron model and the fluid test space to obtain a first intersecting volume having a volume equal to that of a single square grid and a second intersecting volume partially intersecting the single square grid; For the second intersecting body, construct an intersecting polyhedron consisting of a plurality of triangular face units and the external normal directions of all triangular face units in the intersecting polyhedron; Based on a preset projection base plane, a projection operation is performed on the triangular face units in all intersecting polyhedrons in the same projection direction to obtain a pentahedron corresponding to each triangular face unit, wherein the intersecting polyhedron is composed of a cross section formed by the polyhedron model and the square mesh surface, and a plurality of intersecting faces intersecting with the square mesh surface; All pentahedrons are merged according to the external normal and the projection direction to obtain the estimated volumes of all intersecting polyhedrons, wherein the merging process specifically includes: When the angle between the projection direction and the external normal direction is less than the threshold, the volume of the pentahedron corresponding to the triangular face is positive; When the angle between the projection direction and the external normal direction is greater than the threshold, the volume of the pentahedron corresponding to the triangular face is negative; When the angle between the projection direction and the external normal direction is equal to the threshold, the volume of the pentahedron corresponding to the triangular face is zero; If the intersecting polyhedron is a hollow structure, it is necessary to determine the positional relationship between the incenter of the triangle and the polyhedron model: If the center point is located in the polyhedron model, the volume of the five faces of the triangle is positive; If the center point is outside the polyhedron model, the volume of the five faces of the triangle is negative; The volume of the first intersecting body is added to the estimated volume to obtain a spatial volume parameter of the complex structure, and a fluid simulation is performed on the complex structure in the fluid test space to obtain a corresponding simulation result.

2. The fluid simulation method for complex structures according to claim 1, characterized in that: The cross-section acquisition process includes the following steps: First, determine the edges formed by the intersection of the square mesh surface and each face of the polyhedron model, select one of the edges as the first cross-sectional edge, and use the two endpoints of the first cross-sectional edge as the a 、 b , then select Include Endpoints b and does not coincide with the first cross-section edge bc The edge is used as the second cross-section edge of the cross section, and the connection point finding and connection process are repeated until a complete cross section is obtained.

3. The fluid simulation method for complex structures according to claim 1, characterized in that: The process of obtaining the plurality of intersecting surfaces comprises the following steps: First, arbitrarily select an edge of the intersecting surface as the first intersecting surface edge, then connect one endpoint of the first intersecting surface edge with other vertices of the intersecting surface, and determine the angle between each connecting line and the first intersecting surface edge. That is, the smaller the angle, the higher the order of the vertex. By connecting all the vertices of the intersecting surface in order, the shape of the intersecting surface can be determined.

4. The fluid simulation method for complex structures according to claim 1, characterized in that: The threshold is 90 degrees.

5. The fluid simulation method for complex structures according to claim 1, characterized in that: If a triangular face of the intersecting polyhedron intersects a single face of the square mesh, then it is only necessary to project the opposite face of the projection base to obtain the corresponding pentahedron volume.

Citation Information

Patent Citations

  • Self-adaptive Cartesian grid generation method for three-dimensional streaming problem of any shape

    CN113505443A

  • Parallel hexahedron volume averaging conformal mesh generation method based on CAD

    CN115984511A