A method for drawing a two-dimensional flow field of a river channel based on a triangular mesh

Through a two-dimensional flow field rendering method based on triangular grids and the calculation of the trace buffer zone using the angle bisector method, the problem of synchronous changes in the density of flow field traces in the river channel is solved, the uniform distribution of flow field traces and the reflection of the flow field in key areas are achieved, and the data utilization efficiency and accuracy are improved.

CN120147464BActive Publication Date: 2025-10-17BUREAU OF HYDROLOGY CHANGJIANG WATER RESOURCES COMMISSION
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510176266.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-02-18
Publication Date
2025-10-17
Estimated Expiration
2045-02-18

AI Technical Summary

Technical Problem

Existing technologies make it difficult to achieve synchronous changes in the density of flow field traces and the density of grids in river flow field mapping, which makes it difficult to reflect the flow field conditions in key areas, and traces are prone to intersecting or repeated data collection.

Method used

A two-dimensional flow field rendering method for rivers based on triangular grids is adopted. The density of flow field traces changes synchronously with the density of the grid. The angle bisector method is used to calculate the trace buffer zone to ensure that the traces are evenly distributed and reflect the flow field conditions in key areas, avoiding trace intersection and repeated collection.

Benefits of technology

It achieves uniform distribution of flow field traces, reflects the flow field conditions in key areas, avoids trace intersection and repeated collection, and improves data utilization efficiency and accuracy.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120147464B_ABST
    Figure CN120147464B_ABST
Patent Text Reader

Abstract

The application discloses a kind of river two-dimensional flow field drawing methods based on triangular mesh, comprising the following steps: first, the center point of each triangular net is reconstructed as vertex, so that each vertex has flow field data;Then calculate the length and width of the outer package rectangle of grid range, set grid side length, generate grid point set;Then generate trace with grid point as seed point, by calculating flow field vector, azimuth and predicted point position, dynamically adjust the trace direction and step length;Trace buffer zone is calculated using angle bisector method to avoid trace intersection;Repeat the above steps until all points complete trace generation.The application can make the trace density change with the grid density, evenly distributed while reflecting the key attention area flow field situation, and the trace does not intersect, node spacing dynamically adjusts, expresses flow field details with least data, effectively optimizes data volume and calculation accuracy, provides efficient tool for river flow field research.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of geographic information system, and particularly relates to a river two-dimensional flow field drawing method based on a triangular mesh. BACKGROUND

[0002] The flow field refers to the phenomenon that the physical quantities such as the movement speed and direction of the fluid in a region change. The calculation of the flow field is usually performed in a meshed region, and the triangular mesh is a most commonly used unstructured mesh. The calculation of the water flow field in a certain river range by using the triangular mesh is a method for studying the influence of the water body on the river or the water-contacting building, and the drawing of the two-dimensional flow field is an important tool for intuitively understanding and analyzing the flow field. There are two methods for drawing the flow field, i.e., the streamlines and the streamlines. The streamlines are the curves composed of different flow points at the same time, and the streamlines are the curves formed by the same flow point at different times. The present application draws the river two-dimensional flow field based on the streamlines. Since the river flow field is generally used for studying or focusing on the flow field near a certain object range in the river, the triangular mesh with the dynamically adjusted density is usually used to optimize the data quantity and the calculation accuracy. The mesh gradually becomes dense near the key research region, and gradually becomes sparse away from the key research region. The center point of each mesh is the position point of the flow speed and flow direction data of the mesh. SUMMARY

[0003] The present application aims to provide a river two-dimensional flow field drawing method based on a triangular mesh. The density of the streamlines changes synchronously with the density of the mesh, so that the streamlines are uniformly distributed and the flow field conditions of the key attention region can be reflected.

[0004] To achieve the above object, the present application provides the following technical scheme: a river two-dimensional flow field drawing method based on a triangular mesh, comprising the following specific steps:

[0005] Step 1: reconstructing the triangular mesh with the center point of each triangular mesh as the vertex, so that each triangular vertex has flow field data;

[0006] Step 2: calculating the length and width of the outer rectangle of the range of all meshes, setting the length as a and the width as b, setting the mesh side length d, taking the lower left corner of the outer rectangle as the starting point, and generating the mesh Grid with the range not exceeding the outer rectangle, and defining the point set P on the mesh Grid as n ;

[0007] Step 3: taking the point P in the point set P n as the seed point to generate the streamlines;

[0008] Step 4: calculating the buffer area of the streamlines by using the angle bisector method, i.e., the outer package area of the streamlines;

[0009] Step 5: Repeat the above steps until the point set P n All points in have been used as seed points to complete the trajectory generation.

[0010] Specifically, define the point set on the grid Grid as P n Specifically: To round down the symbol, define the buffer set buffers to record the range covered by each trace, with P n Any point P(X P ,Y P ) is the seed point, and a trace with P as the starting point is generated.

[0011] Specifically, the trace starting from P is generated as follows:

[0012] Step 3.1: When the seed point P is inside a triangle (let this triangle be triangle Tin1) and is not inside any trace buffer, add P to the trace points of the trace. Calculate the flow vector A and flow azimuth β at P using the flow field data of the three vertices of triangle Tin1 and the position of P. Otherwise, return to step 2 to find the next seed point P.

[0013] Step 3.2: Predict the next position point Q of the trace, calculate the average length L of the three sides of triangle Tin1, take position P as the starting point, β as the azimuth, L as the length, and calculate the other endpoint Q (X Q ,Y Q ), where X Q =X P +L*Mathcosβ、Y Q =Y P +L*Mathsinβ;

[0014] Step 3.3: Determine whether point Q is within a triangle. If Q is not within any triangle, or line segment PQ intersects any buffer in the generated trace buffer set buffers, stop searching for the trace starting from P and return to step 2. If Q is within a triangle, let this triangle be triangle Tin2, and calculate the flow field vector B at Q based on the flow field data of each vertex of Tin2.

[0015] Step 3.4: Calculate the next actual position point R of the trace, calculate the vector A+B=C with P as the starting point, and obtain the azimuth angle γ of vector C. With P as the starting point, L as the length, and γ as the azimuth, calculate the other endpoint R(X R ,Y R ), where X R =X P +L*Mathcosβ、Y R =YP + L * Mathsinbeta;

[0016] Step 3.5: replace the P point coordinates with the R point coordinates, i.e. P = X R , Y P = Y R , repeat steps 3.1 to 3.4 until the stop condition is met.

[0017] Specifically, the specific method of calculating the trace buffer is: each point on the trace can be regarded as the vertex of an angle composed of two trace segments, the angle bisector is drawn with the node as the vertex, and the angle bisector is reversely extended, the length of the angle bisector and the reversely extended line is the average side length of the triangle in which the node is located, and the total length of the angle bisector is the width of the trace buffer at the point; the two end points of the angle bisector can be obtained for each node on the trace, and the points are sequentially connected, so that the buffer with dynamic width of the trace is obtained, and the buffer is recorded in the buffer set buffers.

[0018] The principle and beneficial effects of the technical solution are as follows:

[0019] (1) The density of the flow field trace changes synchronously with the density of the grid, and the flow field conditions of the key attention area can be reflected while the traces are uniformly distributed.

[0020] (2) The traces are ensured not to intersect.

[0021] (3) The distance between each node on the trace is dynamically adjusted, so that the flow field data in each grid passed through by the trace can be collected as uniformly as possible under the condition that the grid density is different, the grid is not missed in large quantities, and the flow field details at each part of the trace are expressed with as few data as possible. BRIEF DESCRIPTION OF DRAWINGS

[0022] Figure 1 is a schematic diagram of a trace and a buffer of a certain seed point P;

[0023] Figure 2 is a schematic diagram of a calculation process of a predicted position Q of a successor point of a certain point on the trace;

[0024] Figure 3 is a schematic diagram of a calculation process of an actual position R of a successor point of a certain point on the trace;

[0025] Figure 4 is a schematic diagram of a calculation process of a trace buffer. DETAILED DESCRIPTION

[0026] The application will be further described in detail below in combination with the drawings and embodiments:

[0027] For example, Figure 1As shown, the present invention provides a method for rendering a two-dimensional flow field of a river channel based on a triangular mesh. In this embodiment, the flow field data of a river section calculated based on a triangular mesh is selected. The range is 15836m*12931m, and the average side length of all triangles is about 119m. The following steps are included:

[0028] The specific steps include:

[0029] Step 1: Reconstruct the triangulated network with the center point of each triangulated network as the vertex so that each triangle vertex has flow field data.

[0030] Step 2: Calculate the enclosing rectangle of all grid ranges, which is 15836m long and 12931m wide. Set the grid side length to the average side length of all triangles, 119m. Use the lower left corner of the enclosing rectangle as the starting point to generate a grid that does not exceed the enclosing rectangle. Define the point set on the grid as P. n , then Grid has List, rows, a total of 14606 nodes ( ( ) Define the buffer set buffers to record the range covered by each trace. n Any point P(X P ,Y P ) is the seed point, and the trace starting from P is generated by the following steps:

[0031] Step 3: If the current seed point coordinates P(X P ,Y P )=(608806,3354179), then generating the trace with this seed point is divided into 4 steps.

[0032] Step 3.1: If point P is in the triangle Tin1 with three vertex coordinates (608844, 3354303), (608761, 3354137), and (608920, 3354158), and is not in any trace buffer, then add the point to the trace point. The flow field vectors of the three vertices are (0.67, 0.205), (0.61, 0.2), and (0.6, 0.209). Through the three vertices of triangle Tin1 and the position of P, calculate the flow field vector A (0.62, 0.21) at P. The flow field azimuth β = 0.315. If point P is not in any triangle or in a buffer (such as Figure 1 , P n-1 In the buffer), return to step 2 to find the next seed point P.

[0033] Step 3.2: Calculate the average length of the three sides of triangle Tin1, L = 135.67, and calculate the coordinates of the other endpoint Q of the line segment with P as the starting point, β as the azimuth, and L as the length. Q =X P +L*Mathcosβ、Y Q =Y P +L*Mathsinβ, that is, Q(X Q ,Y Q )=(608935,3354221). Q is used as the prediction point for the next step of the trajectory calculation.

[0034] Step 3.3: Determine whether point Q is in a certain triangle. If Q is not in any triangle, stop looking for the trace starting from P and return to step 2. The coordinates of the three vertices of the triangle where Q is located are (608844, 3354303), (608920, 3354158), (608990, 3354351). According to the flow field vectors of the three vertices of Tin2 (0.67, 0.205), (0.6, 0.209), (0.67, 0.235), calculate the flow field vector B (0.62, 0.216) at Q (as shown in Figure 3). Figure 2 ).

[0035] Step 3.4: Calculate vector A+B=C with P as the starting point, and get the vector sum C(1.25,0.419) of the seed point P and the predicted point Q. Calculate the other endpoint R(X R ,Y R )=(608935,3354222), the azimuth angle γ is 0.324. Point R may become a new trace point on the trace (such as Figure 3 ). Use the coordinates of R to replace the coordinates of the seed point P, that is, X P =608935,Y P =3354222, repeat steps 3.1 to 3.4.

[0036] Step 4: Calculate the buffer zone of the currently generated trace. Use the angle bisector method to calculate the buffer zone of the trace. For example, at point R, the length of the forward and reverse angle bisectors is half of L, that is, 67.88m. Then the coordinates of the two endpoints are H1 (608918, 3354287) and H2 (608947, 3354154). Figure 4 ). Connect the endpoints of the angle bisectors on all nodes in sequence to form the buffer of the trace, and record the buffer into the buffer set buffers.

[0037] Repeat steps 3 and 4 until the point set P nAll points in the image have completed trace generation as seed points.

[0038] The above is only the embodiment of the present application, and the specific technical solutions or common knowledge in the scheme are not described in detail. For those skilled in the art, without departing from the technical solutions of the present application, several modifications and improvements can be made, which should also be considered as the protection scope of the present application, and these will not affect the effect and practicality of the present application. The protection scope claimed in the present application should be subject to the content of its claims, and the specific implementation mode and the like recorded in the specification can be used to explain the content of the claims.

Claims

1. A method for rendering a two-dimensional flow field of a river channel based on a triangular grid, characterized in that: The specific steps include: Step 1: Reconstruct the triangulated network with the center point of each triangulated network as the vertex so that each triangle vertex has flow field data; Step 2: Calculate the length and width of the outer rectangle of all grid ranges. Let the length be a, the width be b, and the grid side length be d. With the lower left corner of the outer rectangle as the starting point, d is the grid side length. Generate a grid that does not exceed the outer rectangle. Define the point set on the grid as P. n ; Step 3: Take point set P n The point P in is the seed point, and the trace is generated as follows: Step 3.1: When the seed point P is inside a triangle (let this triangle be triangle Tin1) and is not inside any trace buffer, add P to the trace points of the trace. Calculate the flow vector A and flow azimuth β at P using the flow field data of the three vertices of triangle Tin1 and the position of P. Otherwise, return to step 2 to find the next seed point P. Step 3.2: Predict the next position point Q of the trace, calculate the average length L of the three sides of triangle Tin1, take P as the starting point, β as the azimuth, L as the length, and calculate the other endpoint Q (X Q ,Y Q ), where X Q =X P +L*Mathcosβ、Y Q =Y P +L*Mathsinβ; Step 3.3: Determine whether point Q is within a triangle. If Q is not within any triangle, or line segment PQ intersects any buffer in the generated trace buffer set buffers, stop searching for the trace starting from P and return to step 2. If Q is within a triangle, let this triangle be triangle Tin2, and calculate the flow field vector B at Q based on the flow field data of each vertex of Tin2. Step 3.4: Calculate the next actual position point R of the trace, calculate the vector A+B=C with P as the starting point, and obtain the azimuth angle γ of vector C. With P as the starting point, L as the length, and γ as the azimuth, calculate the other endpoint R(X R ,Y R ), where X R =X P +L*Mathcosβ、Y R =Y P +L*Mathsinβ; Step 3.5: Replace the coordinates of point P with the coordinates of point R, i.e. X P =X R , Y P =Y R , repeat steps 3.1 to 3.4 until the stopping condition is met; Step 4: Use the angle bisector method to calculate the buffer zone of the trace, which is an outer area of ​​the trace; Step 5: Repeat the above steps until the point set P n All points in have been used as seed points to complete the trajectory generation.

2. The method for rendering a two-dimensional flow field of a river channel based on a triangular grid according to claim 1, characterized in that: Define the point set on the grid Grid as P n Specifically: To round down the symbol, define the buffer set buffers to record the range covered by each trace, with P n Any point P(X P ,Y P ) is the seed point, and a trace with P as the starting point is generated.

3. The method for rendering a two-dimensional flow field of a river channel based on a triangular grid according to claim 1, characterized in that: The specific method for calculating the trace buffer is as follows: except for the first and last nodes, each point on the trace can be regarded as the vertex of the angle formed by two trace segments. An angle bisector is drawn with the node as the vertex and extended in the opposite direction. The length of the angle bisector and the reverse extension line are both the average side length of the triangle where the node is located. The total length of the angle bisector is the width of the trace buffer at that point; the two endpoints of the angle bisector of each node on the trace are calculated, and these points are connected in sequence to form a buffer with dynamic width for the trace, which is recorded in the buffer set buffers.

Citation Information

Patent Citations

  • Dual control grid-based streamline placement method for two-dimensional flow fields

    CN102930563A

  • Dynamic drawing method with boundary plane flow field

    CN104318591A