A method for implicitly modeling a three-dimensional geological interface constrained by topography

By combining terrain data and geological profile data using implicit modeling methods, the terrain direction is calculated and adaptively processed to generate a three-dimensional geological interface model constrained by the terrain. This solves the problem of insufficient control over terrain undulation in traditional modeling methods and improves modeling efficiency and accuracy.

CN123181753APending Publication Date: 2026-11-27POWER CHINA KUNMING ENG CORP LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611176508.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-08-05
Publication Date
2026-11-27

AI Technical Summary

Technical Problem

Traditional geological interface modeling methods fail to effectively inherit the control effect of topographic relief on the burial depth of geological interfaces, resulting in models lacking geological rationality, requiring a large amount of manual intervention, being inefficient, and prone to errors.

Method used

An implicit modeling method is adopted, which combines topographic contour lines, engineering geological profiles and borehole data. The topographic direction data is calculated by PCA principal component analysis algorithm, and adaptive resampling and non-uniform dip attenuation processing are performed to create a three-dimensional geological interface model constrained by the terrain. Finally, Boolean operations are performed to generate the geological interface model.

Benefits of technology

It significantly reduces human intervention, improves the efficiency and accuracy of 3D geological modeling, and ensures that the model conforms to geological laws.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123181753A_ABST
    Figure CN123181753A_ABST
Patent Text Reader

Abstract

The application discloses a terrain-constrained three-dimensional geological interface implicit modeling method, belongs to the three-dimensional geological modeling technical field of the water conservancy and hydropower engineering geological survey industry, and comprises the following steps: extracting terrain contour lines, geological boundary lines in an engineering geological profile and geological boundary point data exposed by drilling in sequence; creating a terrain surface model by using implicit modeling according to the terrain contour lines; calculating terrain direction data by using a PCA algorithm and sequentially performing adaptive resampling, thinning and non-uniform inclination angle attenuation processing; creating a complete terrain-constrained geological boundary surface model by using implicit modeling and by using the geological boundary point data exposed by drilling, vertex data on the geological boundary lines in the engineering geological profile and the finally processed direction data; and finally performing Boolean operation on the terrain surface model and the complete geological boundary surface model to obtain a three-dimensional geological interface model under the terrain surface. The application embeds a terrain fluctuation control mechanism in a modeling process, significantly reduces manual intervention, and improves the efficiency and accuracy of geological interface modeling.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention discloses an implicit modeling method for three-dimensional geological interfaces constrained by terrain, belonging to the field of three-dimensional geological modeling technology in the geological exploration industry of water conservancy and hydropower projects. Background Technology

[0002] In 3D geological modeling for water conservancy and hydropower engineering geological exploration, the morphology of geological interfaces such as rock weathering interfaces, rock unloading interfaces, and groundwater levels is usually based primarily on borehole data revealing boundary points, and their spatial distribution is significantly constrained by topographic variations. Traditional geological interface modeling methods mainly rely on limited borehole data and manually drawn geological profile data, directly constructing them through surface fitting.

[0003] This type of method has the following prominent problems: Insufficient representation of geological laws: The geological interfaces generated by the fitting often only consider mathematical smoothness, but fail to effectively inherit the control of topographic relief on the burial depth of the geological interfaces, resulting in the model lacking geological rationality. The workload of manual intervention is large: In order to make the geological interface model meet the general geological laws, it is usually necessary to add a large number of auxiliary profile lines and virtual control points for repeated corrections, making the modeling process lengthy and cumbersome. Inefficient and error-prone: For complex terrain areas, multiple iterations and adjustments are required, which not only consumes manpower but also easily introduces human error, making it difficult to respond quickly to modeling needs. Summary of the Invention

[0004] To address the aforementioned problems, this invention provides an implicit modeling method for 3D geological interfaces constrained by terrain. Based on user-input terrain data, geological boundary point data revealed by boreholes, and existing geological profile boundary line data, this method rapidly constructs a geological interface model constrained by terrain within the engineering area through steps such as creating a terrain surface model, calculating and processing terrain direction data, creating geological interfaces, and Boolean operations. This invention effectively embeds a terrain undulation control mechanism into the modeling algorithm, significantly reducing manual intervention and greatly improving the efficiency and accuracy of 3D geological modeling, providing a powerful tool for 3D geological modeling work in water conservancy and hydropower projects.

[0005] To achieve the above objectives, the present invention provides the following technical solution: An implicit modeling method for 3D geological interfaces constrained by terrain includes the following steps: Step 1: Extract all vertex data from the geological boundary lines in the input topographic contour lines and engineering geological profiles, and read the geological boundary point data exposed by the boreholes. Step 2: Based on the vertex data on the topographic contour lines, create a topographic surface model of the engineering area using implicit modeling, which serves as the upper limit of the three-dimensional geological model; Step 3: Based on the vertex data on the terrain contour lines, terrain direction data is calculated using a custom PCA principal component analysis algorithm to characterize the undulations of the terrain. Step 4: Perform adaptive resampling and thinning on the terrain direction data to preserve the key morphological features of terrain undulations; Step 5: Apply non-uniform dip attenuation constraints to the terrain orientation data after adaptive resampling and thinning to provide the final processed orientation data for subsequent geological interface modeling; Step 6: Using the geological boundary point data revealed by the borehole, the point data on the geological boundary line in the engineering geological profile, and the final processed direction data obtained in Step 5, a complete geological interface model of the engineering area constrained by the terrain is created using implicit modeling. Step 7: Perform Boolean operations on the topographic surface model and the complete geological interface model of the engineering area constrained by the topography to obtain the geological interface model below the topographic surface of the engineering area, which is used in the 3D geological modeling workflow.

[0006] Further, in step 1, the .dxf format file containing the terrain contour data in the specified path is read, and the model space is obtained; Traverse and determine the type of terrain contour lines; For contour lines of type "LWPOLYLINE", use the entity.dxf.elevation.z method to get the Z coordinate of the contour line, and use the entity.get_points() method to get the X and Y coordinates of each node of the contour line in turn; For contour lines of type "POLYLINE", obtain the coordinates of each vertex on the contour line in sequence; Store the vertex coordinates of all topographic contour lines into the array topography.

[0007] Furthermore, in step 1, the same method used to read the topographic contour file and save all vertex data on the topographic contour line is used to read the .dxf format file storing the geological boundary line data in the engineering geological profile, and the vertex data on the geological boundary line in the engineering geological profile is stored in the array profile; the .csv file storing the geological boundary point data exposed by the borehole is read and saved in the array points.

[0008] Furthermore, in step 2, using all vertex data on the terrain contour lines, an independent scalar field of the terrain surface is constructed through a piecewise linear interpolation implicit modeling algorithm, and the terrain surface model is expressed in the form of isosurfaces as the upper limit of the three-dimensional geological model; When performing piecewise linear interpolation, tetrahedral meshes are used to discretize the entire modeling region; By utilizing the shape function of the tetrahedral element, the unknown scalar values ​​of the four vertices of the tetrahedron are connected with the known scalar values ​​of point p through linear equations, and all the linear equations are combined to form a large, overdetermined sparse equation system. Regularization constraints are applied by establishing equations between each adjacent tetrahedral pair, forming a minimization problem, and then the least squares problem is solved to obtain the optimal scalar value for each grid node.

[0009] Furthermore, in step 3, using the terrain point data obtained in step 1, the search for terrain point data is accelerated by recursively dividing the three-dimensional space using a binary tree data structure. The orientation data of the terrain in the engineering area is calculated through a custom PCA principal component analysis algorithm, and the function of converting normal vector data into dip and dip angles and outputting terrain attitude data is supported. For each terrain point data, the k neighboring terrain points containing that terrain point are determined by setting parameters; For the direction calculation object point p and the k-1 neighboring terrain point data, the centroid calculation formula is used to calculate the center position, and then the centering process is performed to obtain the offset vector of each neighboring point relative to the centroid, and the covariance matrix is ​​constructed. Solve the covariance matrix to obtain the eigenvalues ​​and corresponding eigenvectors, and determine the normal vector of the approximate plane based on the solution results. Find the direction with the minimum variance in the result.

[0010] For the extracted terrain normal vector data, the function of outputting terrain attitude data is provided. The dip and dip angle data corresponding to each normal vector data are calculated and the terrain attitude data is output.

[0011] Furthermore, in step 4, the curvature of each normal vector position is calculated, and the terrain direction data is adaptively resampled and thinned according to the relationship of the eigenvalues ​​to ensure that more normal vector data is retained in areas with large terrain undulations and less normal vector data is retained in areas with small terrain undulations. The covariance matrix is ​​used to solve for the curvature values ​​at the data locations in each direction, which are the plane fitting residuals of the neighborhood point cloud, representing the surface roughness and variability. The curvature at each direction of the calculated data position is normalized to the probability of random sampling, and then adaptive resampling is performed. Furthermore, in step 5, the terrain orientation data obtained in step 4 after adaptive resampling and thinning is subject to non-uniform dip angle attenuation constraint, that is, the position and dip of each terrain orientation data are kept unchanged, and only the dip angle is subjected to non-uniform attenuation processing. The tilt angle calculation formula is used to calculate the tilt angle value corresponding to the normal vector data of each terrain, and the attenuation coefficient is designed according to the tilt angle value range. Iterate through all tilt angle data and determine the range of each tilt angle value to determine the corresponding attenuation coefficient, and multiply it by the corresponding tilt angle data to obtain the tilt angle data after non-uniform attenuation. Calculate the normal vector data in the X and Y directions after tilt attenuation, and obtain the normal vector data in the Z direction after tilt attenuation. Through steps 3-5, the topographic direction data of the engineering area is calculated using topographic point data. Adaptive resampling and thinning of the topographic direction data and non-uniform dip attenuation processing are then applied to ensure that areas with large topographic undulations retain more topographic direction data and have strong dip attenuation, while areas with small topographic undulations retain less topographic direction data and have weak dip attenuation. This provides the final processed direction data that conforms to geological laws for subsequent geological interface modeling.

[0012] Furthermore, in step 6, using the geological boundary point data exposed by the boreholes stored in step 1 and the vertex data of the geological boundary line in the engineering geological profile, as well as the final processed direction data obtained in step 5, an independent scalar field of the geological interface is created by piecewise linear interpolation implicit modeling, and the complete geological interface of the engineering area constrained by the terrain is expressed in the form of isosurfaces.

[0013] Furthermore, in step 7, the Manifold3D method is used to perform Boolean operations on the topographic surface model of the engineering area obtained in step 2 and the complete geological interface model of the engineering area constrained by the terrain obtained in step 6 to obtain the geological interface model below the topographic surface of the engineering area, which is used in the three-dimensional geological modeling workflow. Boolean operations are based on the principle of signed distance fields, and the specific algorithm logic is as follows: For node data in the geological interface mesh, calculate the signed nearest distance to the topographic surface; Based on the signed distance of nodes in the geological interface mesh from the topographic surface, when all three vertices of the mesh triangle are located below the topographic surface, all node data and the mesh triangle they form are retained. When all three vertices of the meshing triangle are located above the terrain surface, discard all node data and the meshing triangle. When one or two vertices of the network triangle are located below the terrain surface, retain the node data located below the terrain surface and discard the node data located above the terrain surface.

[0014] For cases where one or two vertices of the geological interface network triangle are located below the topographic surface, linear interpolation is used to calculate the coordinates of the intersection points between the topographic surface and the sides of the geological interface network triangle. For the endpoints of the geological interface structure network edge The corresponding signed distance is The interpolation parameters are Obtain the coordinates of the intersection point. ; Triangulate the network triangles based on the number of vertices retained: If one vertex is retained, then that vertex and the two intersection points form a new triangle; If two vertices are retained, then a quadrilateral is formed with the two intersection points; Only all the mesh polygons located below the terrain surface are combined to form a terrain-constrained 3D geological interface model below the terrain surface, which is used in the 3D geological modeling workflow.

[0015] This invention discloses an implicit modeling method for 3D geological interfaces constrained by terrain, belonging to the field of 3D geological modeling technology in the geological exploration industry of water conservancy and hydropower engineering. The method includes: sequentially extracting topographic contour lines, geological boundary lines from engineering geological profiles, and geological boundary point data revealed by boreholes; creating a topographic surface model based on the topographic contour lines using implicit modeling; calculating topographic direction data using the PCA algorithm and sequentially performing adaptive resampling thinning and non-uniform dip attenuation processing; using the geological boundary point data revealed by boreholes, vertex data on the geological boundary lines in the engineering geological profiles, and the finally processed direction data, creating a complete geological interface model constrained by terrain using implicit modeling; and finally performing Boolean operations on the topographic surface model and the complete geological interface model to obtain a 3D geological interface model beneath the topographic surface. This invention embeds a terrain undulation control mechanism into the modeling process, significantly reducing manual intervention and improving the efficiency and accuracy of geological interface modeling. Attached Figure Description

[0016] Figure 1 This is a flowchart illustrating the implicit modeling method for a terrain-constrained three-dimensional geological interface, as claimed in an embodiment of the present invention. Figure 2 The topographic contour map of the engineering area of ​​a terrain-constrained three-dimensional geological interface implicit modeling method claimed in an embodiment of the present invention; Figure 3 A topographic surface model diagram of a terrain-constrained three-dimensional geological interface implicit modeling method claimed in an embodiment of the present invention; Figure 4The terrain direction data map is calculated based on all node data on the terrain contour lines, according to the terrain-constrained three-dimensional geological interface implicit modeling method claimed in the embodiments of the present invention. Figure 5 The terrain orientation data map after adaptive resampling thinning and non-uniform dip attenuation is provided for a terrain-constrained three-dimensional geological interface implicit modeling method claimed in the embodiments of the present invention. Figure 6 The geological boundary data and borehole-exposed geological boundary point data map of a terrain-constrained three-dimensional geological interface implicit modeling method claimed in this embodiment of the invention. Figure 7 A complete geological interface model diagram of a terrain-constrained three-dimensional geological interface implicit modeling method claimed in an embodiment of the present invention; Figure 8 A three-dimensional geological interface model diagram below the terrain surface of a terrain-constrained three-dimensional geological interface implicit modeling method claimed in an embodiment of the present invention. Detailed Implementation

[0017] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of the present invention, and not all of them. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative effort are within the scope of protection of the present invention.

[0018] The terms "first," "second," and "third" used in this invention are for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of indicated technical features. Thus, a feature defined as "first," "second," or "third" may explicitly or implicitly include at least one of that feature. In the description of this invention, "a plurality of" means at least two, such as two, three, etc., unless otherwise explicitly specified. All directional indications (such as up, down, left, right, front, back, etc.) in the embodiments of this invention are only used to explain the relative positional relationships and movements between components in a specific orientation (as shown in the figures). If the specific orientation changes, the directional indications also change accordingly. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover non-exclusive inclusion. For example, a process, method, system, product, or device that includes a series of steps or units is not limited to the listed steps or units, but may optionally include steps or units not listed, or may optionally include other steps or units inherent to these processes, methods, products, or devices.

[0019] In this document, the term "embodiment" means that a particular feature, structure, or characteristic described in connection with an embodiment may be included in at least one embodiment of the invention. The appearance of this phrase in various places throughout the specification does not necessarily refer to the same embodiment, nor is it a mutually exclusive, independent, or alternative embodiment. It will be explicitly and implicitly understood by those skilled in the art that the embodiments described herein can be combined with other embodiments.

[0020] According to the first embodiment of the present invention, referring to Figure 1 This invention claims protection for an implicit modeling method for three-dimensional geological interfaces constrained by terrain, comprising the following steps: Step 1: Extract all vertex data from the geological boundary lines in the input topographic contour lines and engineering geological profiles, and read the geological boundary point data exposed by the boreholes. Step 2: Based on the vertex data on the topographic contour lines, create a topographic surface model of the engineering area using implicit modeling, which serves as the upper limit of the three-dimensional geological model; Step 3: Based on the vertex data on the terrain contour lines, terrain direction data is calculated using a custom PCA principal component analysis algorithm to characterize the undulations of the terrain. Step 4: Perform adaptive resampling and thinning on the terrain direction data to preserve the key morphological features of terrain undulations; Step 5: Apply non-uniform dip attenuation constraints to the terrain orientation data after adaptive resampling and thinning to provide the final processed orientation data for subsequent geological interface modeling; Step 6: Using the geological boundary point data revealed by the borehole, the point data on the geological boundary line in the engineering geological profile, and the final processed direction data obtained in Step 5, a complete geological interface model of the engineering area constrained by the terrain is created using implicit modeling. Step 7: Perform Boolean operations on the topographic surface model and the complete geological interface model of the engineering area constrained by the topography to obtain the geological interface model below the topographic surface of the engineering area, which is used in the 3D geological modeling workflow.

[0021] Further, in step 1, the .dxf format file containing the terrain contour data in the specified path is read, and the model space is obtained; Traverse and determine the type of terrain contour lines; For contour lines of type "LWPOLYLINE", use the entity.dxf.elevation.z method to get the Z coordinate of the contour line, and use the entity.get_points() method to get the X and Y coordinates of each node of the contour line in turn; For contour lines of type "POLYLINE", obtain the coordinates of each vertex on the contour line in sequence; Store the vertex coordinates of all topographic contour lines into the array topography.

[0022] In this embodiment, reference is made to Figure 2 This is a topographic contour map of the project area; In step 1, the `doc = ezdxf.readfile()` method is used to read the `.dxf` format file containing the terrain contour data in the specified path; the `msp = doc.modelspace()` method is used to obtain the model space; the `forentity in msp` and `entity.dxftype() in ('LWPOLYLINE', 'POLYLINE')` methods are used to traverse and determine the type of terrain contour lines; for contour lines of type "LWPOLYLINE", the `entity.dxf.elevation.z` method is used to obtain the Z coordinate of the contour line, and the `point in entity.get_points()` and `topography.append((point[0], point[1]))` methods are used to obtain the X and Y coordinates of each node of each contour line; for contour lines of type "POLYLINE", the `point = vertex.dxf.location` and `topography.append((point.x,point.y, ...)` methods are used. The `point.z` method retrieves the coordinates of each vertex on each contour line; finally, the coordinates of all vertices on the terrain contour lines are stored in the array `topography`.

[0023] Further, in step 1, the .dxf format file storing geological boundary line data in the engineering geological profile is read using the same method as reading the topographic contour line file and saving all vertex data on the topographic contour line, and the vertex data on the geological boundary line in the engineering geological profile is stored in the array profile; the .csv file storing the geological boundary point data exposed by the borehole is read using the methods df = pd.read_csv(csv_path) and points = df[[x, y, z]].values.astype(np.float64) and saved to the array points.

[0024] Furthermore, in step 2, using all vertex data on the terrain contour lines, an independent scalar field of the terrain surface is constructed through a piecewise linear interpolation implicit modeling algorithm, and the terrain surface model is expressed in the form of isosurfaces as the upper limit of the three-dimensional geological model; When performing piecewise linear interpolation, tetrahedral meshes are used to discretize the entire modeling region; By utilizing the shape function of the tetrahedral element, the unknown scalar values ​​of the four vertices of the tetrahedron are connected with the known scalar values ​​of point p through linear equations, and all the linear equations are combined to form a large, overdetermined sparse equation system. Regularization constraints are applied by establishing equations between each adjacent tetrahedral pair, forming a minimization problem, and then the least squares problem is solved to obtain the optimal scalar value for each grid node.

[0025] In this embodiment, in step 2, using all vertex data from the terrain contour lines, an independent scalar field of the terrain surface is constructed through a piecewise linear interpolation implicit modeling algorithm. This terrain surface model is then expressed as an isosurface, serving as the upper bound of the three-dimensional geological model. Figure 3 As shown. The principle of piecewise linear interpolation is as follows: The entire modeling region is discretized using a tetrahedral mesh, with each tetrahedral T... k Inside the scalar field f(x), it can be represented as a linear function. , where (x, y, z) are spatial coordinates, and the parameters (a, b, c, d) are determined based on the known scalar values ​​at the four vertices of the tetrahedron.

[0026] Assume point p is located on tetrahedron T. k The interior of the tetrahedron is known to have a scalar value of b. Using the shape function of the tetrahedral element... ,pass The linear equations relate the unknown scalar values ​​v1, v2, v3, v4 at the four vertices of the tetrahedron to the known scalar value b at point p, thus combining all the linear equations into a large, overdetermined sparse system of equations. , where x is the unknown scalar value at all vertices of the tetrahedral mesh.

[0027] To ensure a smooth and continuous scalar field and prevent drastic fluctuations in the geological model that contradict geological laws, regularization constraints are applied by establishing equations between each pair of adjacent tetrahedra, ultimately forming... Minimize the problem, where Ax - b represents the data constraints, D is the regularization matrix, and λ is an important parameter controlling the smoothness; solve this least squares problem to obtain the optimal scalar value for each grid node.

[0028] Furthermore, in step 3, using the terrain point data obtained in step 1, the search for terrain point data is accelerated by recursively dividing the three-dimensional space using a binary tree data structure. The orientation data of the terrain in the engineering area is calculated through a custom PCA principal component analysis algorithm, and the function of converting terrain normal vector data into dip and dip angles and outputting terrain attitude data is supported. For each terrain point data, the k neighboring terrain points containing that terrain point are determined by setting parameters; For the direction calculation object point p and the k-1 neighboring terrain point data, the centroid calculation formula is used to calculate the center position, and then the centering process is performed to obtain the offset vector of each neighboring point relative to the centroid, and the covariance matrix is ​​constructed. Solve the covariance matrix to obtain the eigenvalues ​​and corresponding eigenvectors, and determine the normal vector of the approximate plane based on the solution results. Find the direction with the minimum variance in the result.

[0029] For the extracted terrain normal vector data, the function of outputting terrain attitude data is provided. The dip and dip angle data corresponding to each normal vector data are calculated and the terrain attitude data is output.

[0030] In this embodiment, in step 3, the terrain point data obtained in step 1 is used, and a binary tree data structure is used to recursively segment the three-dimensional space to accelerate the search for terrain point data. A custom PCA algorithm is then used to calculate the terrain orientation data of the engineering area. Figure 4 As shown, the specific steps are as follows.

[0031] For each terrain point, a KDTree is constructed using `tree = KDTree(points)`, and the `k_neighbors = k` parameter is used to determine the `k` neighboring terrain points containing that point. Note that if the value of `k` is too small, it becomes overly sensitive to terrain singularities, resulting in unstable normal vector data; if the value of `k` is too large, the normal vector data becomes too smooth, easily losing details. The advantages, disadvantages, and applicable scenarios for different ranges of `k` values ​​are shown in Table 1. Table 1. Advantages, disadvantages, and applicable scenarios of k-values.

[0032] This method reduces the query time complexity from O(N) to O(log N), thereby reducing the overall complexity from O(N) to O(log N). 2 The value is reduced to O(N log N).

[0033] For the direction calculation object point p and its k-1 neighboring terrain point data First, the centroid calculation formula is used. Calculate the center position, then use The formula is decentralized to obtain the offset vector of each neighborhood point relative to the centroid, and then the covariance matrix is ​​constructed. Where Q is a k×3 matrix, the expansion of the covariance matrix is:

[0034] use The formula solves for the covariance matrix, yielding three eigenvalues ​​λ1, λ2, and λ3 and their corresponding eigenvectors v1, v2, and v3. The normal vector of the approximate plane is determined based on the solution results. That is, the normal vector of the plane is the direction with the minimum variance of the point set. In the solution results, the direction with the minimum λ3 is the direction with the minimum variance, and v3 is the normal vector perpendicular to the fitted plane.

[0035] For the extracted terrain normal vector data, this invention provides a function to output the terrain orientation, specifically by using... formula and The formulas calculate the dip and dip angle data corresponding to each normal vector. The `output_df.to_csv()` method is then used to output the topographic dip data with column names "x", "y", "z", "azimuth", and "dip" respectively.

[0036] Furthermore, in step 4, the curvature of each normal vector position is calculated, and the terrain direction data is adaptively resampled and thinned according to the relationship of the eigenvalues ​​to ensure that more normal vector data is retained in areas with large terrain undulations and less normal vector data is retained in areas with small terrain undulations. The covariance matrix is ​​used to solve for the curvature values ​​at the data locations in each direction, which are the plane fitting residuals of the neighborhood point cloud, representing the surface roughness and variability. The curvature at each direction of the calculated data position is normalized to the probability of random sampling, and then adaptive resampling is performed. In this embodiment, in step 4, the curvature of each normal vector position is calculated, and the terrain direction data is adaptively resampled and thinned according to the relationship of eigenvalues ​​to ensure that more normal vector data is retained in areas with large terrain undulations and fewer normal vector data is retained in areas with small terrain undulations. The specific steps are as follows: Using the covariance matrix solution from step 3, The formula determines the curvature value at each data location, which is the planar fitting residual of the neighborhood point cloud, representing the surface roughness and variability. A larger curvature indicates greater terrain undulation at that point, while a smaller curvature indicates less terrain undulation. The relationship between curvature values ​​and terrain undulation is shown in Table 2. Table 2 Relationship between curvature values ​​and terrain relief

[0037] The calculated curvature at each directional data location is normalized to the probability of random sampling using the method `probabilities = curvature / sum(curvature)`. Adaptive resampling is then performed using the method `sampled_indices = np.random.choice(n, size=n_samples, p=probabilities)` to retain more directional data in areas with large terrain undulations and fewer in areas with small terrain undulations. The formula `n_samples = max(500, int(0.05)` is used to calculate the probability of random sampling. The `n_total)` method retains 500 directional data points or 5% of the directional data (whichever is greater), maximizing the preservation of key morphological features of terrain undulations while ensuring the speed of subsequent implicit modeling of geological interfaces.

[0038] Furthermore, in step 5, the terrain orientation data obtained in step 4 after adaptive resampling and thinning is subject to non-uniform dip angle attenuation constraint, that is, the position and dip of each terrain orientation data are kept unchanged, and only the dip angle is subjected to non-uniform attenuation processing. The tilt angle calculation formula is used to calculate the tilt angle value corresponding to the normal vector data of each terrain, and the attenuation coefficient is designed according to the tilt angle value range. Iterate through all tilt angle data and determine the range of each tilt angle value to determine the corresponding attenuation coefficient, and multiply it by the corresponding tilt angle data to obtain the tilt angle data after non-uniform attenuation. Calculate the normal vector data in the X and Y directions after tilt attenuation, and obtain the normal vector data in the Z direction after tilt attenuation. Through steps 3-5, the topographic direction data of the engineering area is calculated using topographic point data. Adaptive resampling and thinning of the topographic direction data and non-uniform dip attenuation processing are then applied to ensure that areas with large topographic undulations retain more topographic direction data and have strong dip attenuation, while areas with small topographic undulations retain less topographic direction data and have weak dip attenuation. This provides the final processed direction data that conforms to geological laws for subsequent geological interface modeling.

[0039] In this embodiment, in step 5, the terrain orientation data obtained in step 4 after adaptive resampling and thinning is subject to non-uniform tilt attenuation constraints, referring to... Figure 5 This means keeping the position and inclination of the terrain data unchanged, and only performing non-uniform attenuation processing on the dip angle. The specific method is as follows.

[0040] Use the formula for calculating the inclination angle Calculate the dip angle values ​​corresponding to the normal vector data of each terrain, and design an attenuation coefficient β(x,y)∈(0,1] based on the dip angle value range. This coefficient is a function of the dip angle data, and the formula is as follows:

[0041] In the formula, α represents the dip angle data corresponding to each terrain normal vector. This design ensures that dip angle attenuation is stronger in areas with large terrain undulations and weaker in areas with small terrain undulations.

[0042] The `df.iterrows()` function, along with the `if`, `elif`, and `else` methods, iterates through all dip angle data and determines the range of each dip angle value to identify the corresponding attenuation coefficient β(x,y). This coefficient is then multiplied by the corresponding dip angle data to obtain the non-uniformly attenuated terrain dip angle data α'. .

[0043] use , The formulas calculate the normal vector data in the X and Y directions after tilt attenuation, and based on n... z The sign of the vector is used to obtain the normal vector data in the Z direction after tilt attenuation, i.e., n. z When >0, n z When <0, Since the attenuation operation only changes the direction attribute field and does not transform the spatial position, the attenuated normal vector data still retains the original XYZ coordinates.

[0044] Through the specific practices in steps 3-5, the topographic direction data of the engineering area can be quickly calculated using topographic point data. Adaptive resampling and thinning of the topographic direction data and non-uniform dip attenuation processing are then applied to ensure that areas with large topographic undulations retain more topographic direction data and have stronger dip attenuation, while areas with small topographic undulations retain less topographic direction data and have weaker dip attenuation. This provides the final processed direction data that conforms to geological laws for subsequent geological interface modeling.

[0045] Furthermore, in step 6, using the geological boundary point data exposed by the boreholes stored in step 1 and the vertex data of the geological boundary line in the engineering geological profile, as well as the final processed direction data obtained in step 5, an independent scalar field of the geological interface is created by piecewise linear interpolation implicit modeling, and the complete geological interface of the engineering area constrained by the terrain is expressed in the form of isosurfaces.

[0046] In this embodiment, in step 6, the geological boundary point data revealed by the borehole stored in step 1 is used, such as... Figure 6As shown, using the vertex data of the geological boundary line in the engineering geological profile and the final processed direction data obtained in step 5, an independent scalar field of the geological interface is created using piecewise linear interpolation implicit modeling. This field is then expressed as isosurfaces, representing the complete geological interface of the engineering area constrained by the terrain. Figure 7 As shown. The principle behind the use of the final processed directional data in geological interface modeling is as follows: Gradient direction constraints can be hard or soft, and their purpose is to force the gradient direction at a point p in a scalar field to be parallel to the known normal vector at that point. For a tetrahedron T... k The gradient of the tetrahedron at point p inside the tetrahedron. As a constant, the directional constraint is equivalent to the requirement Or require and Maximize the dot product (soft constraint); add a quadratic penalty term. ,in It is perpendicular to The planar projection matrix, minimizing this term will make As parallel as possible In a global least squares system, this corresponds to adding to the regularization term. .

[0047] Gradient magnitude constraints are soft constraints, aiming to make the gradient magnitude of a local region approximately equal to the magnitude g0 of the known terrain normal vector at that location. For a tetrahedron T... k Add nonlinear constraints ,Will Expand as (Local linearization), or treat it as a quadratic penalty term. This is still non-convex, and it is solved using iterative reweighted least squares.

[0048] Furthermore, in step 7, the Manifold3D method is used to perform Boolean operations on the topographic surface model of the engineering area obtained in step 2 and the complete geological interface model of the engineering area constrained by the terrain obtained in step 6 to obtain the geological interface model below the topographic surface of the engineering area, which is used in the three-dimensional geological modeling workflow. Boolean operations are based on the principle of signed distance fields, and the specific algorithm logic is as follows: For node data in the geological interface mesh, calculate the signed nearest distance to the topographic surface; Based on the signed distance of nodes in the geological interface mesh from the topographic surface, when all three vertices of the mesh triangle are located below the topographic surface, all node data and the mesh triangle they form are retained. When all three vertices of the meshing triangle are located above the terrain surface, discard all node data and the meshing triangle. When one or two vertices of the network triangle are located below the terrain surface, retain the node data located below the terrain surface and discard the node data located above the terrain surface.

[0049] For cases where one or two vertices of the geological interface network triangle are located below the topographic surface, linear interpolation is used to calculate the coordinates of the intersection points between the topographic surface and the sides of the geological interface network triangle. For the endpoints of the geological interface structure network edge The corresponding signed distance is The interpolation parameters are Obtain the coordinates of the intersection point. ; Triangulate the network triangles based on the number of vertices retained: If one vertex is retained, then that vertex and the two intersection points form a new triangle; If two vertices are retained, then a quadrilateral is formed with the two intersection points; Only all the mesh polygons located below the terrain surface are combined to form a terrain-constrained 3D geological interface model below the terrain surface, which is used in the 3D geological modeling workflow.

[0050] In this embodiment, in step 7, the Manifold3D method is used to perform Boolean operations on the topographic surface model of the engineering area obtained in step 2 and the complete geological interface model of the engineering area constrained by the terrain obtained in step 6, thereby obtaining the geological interface model below the topographic surface of the engineering area, which is used in the 3D geological modeling workflow. The Boolean operation is based on the signed distance field principle, and the specific algorithm logic is as follows: For a node data P in the geological interface mesh, calculate its signed nearest distance to the topographic surface as follows: Where point Q is the point P that is closest to the terrain surface. When point P is above the terrain surface, the returned sign function... The value is positive; when point P is located below the terrain surface, the returned sign function is positive. It is a negative value.

[0051] Based on the signed distance of nodes in the geological interface mesh from the topographic surface, when all three vertices of the mesh triangle are located below the topographic surface (f<0), all node data and the mesh triangle formed by them are retained; when all three vertices of the mesh triangle are located above the topographic surface (f>0), all node data and the mesh triangle are discarded; when one or two vertices of the mesh triangle are located below the topographic surface, the node data located below the topographic surface is retained, and the node data located above the topographic surface is discarded.

[0052] For cases where one or two vertices of the geological interface network triangle are located below the topographic surface, linear interpolation is used to calculate the coordinates of the intersection points between the topographic surface and the sides of the geological interface network triangle. For the endpoints of the geological interface network sides... The corresponding signed distance is The interpolation parameters are Thus, the coordinates of the intersection point are obtained. The network triangles are triangulated based on the number of vertices retained: if one vertex is retained, it forms a new triangle with two intersection points; if two vertices are retained, they form a quadrilateral with two intersection points. Finally, only the portions located below the terrain surface are combined to form a three-dimensional geological interface model constrained by the terrain below the surface, as shown in the reference diagram. Figure 8 As shown, it is used in the 3D geological modeling workflow.

[0053] In the several embodiments provided by this invention, it should be understood that the disclosed systems, apparatuses, and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be an indirect coupling or communication connection between apparatuses or units through some interfaces, and may be electrical, mechanical, or other forms.

[0054] Furthermore, the functional units in the various embodiments of the present invention can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated units described above can be implemented in hardware or as software functional units. The above are merely embodiments of the present invention and do not limit the patent scope of the present invention. Any equivalent structural or procedural transformations made based on the description and drawings of the present invention, or direct or indirect applications in other related technical fields, are similarly included within the patent protection scope of the present invention.

[0055] The specific embodiments of the invention have been described in detail above, but these are merely examples, and the invention is not limited to the specific embodiments described above. For those skilled in the art, any equivalent modifications or substitutions to the invention are also within the scope of this invention. Therefore, all equivalent transformations, modifications, and improvements made without departing from the spirit and principles of this invention should be included within the scope of this invention.

Claims

1. A method for implicit modeling of three-dimensional geological interfaces constrained by terrain, characterized in that, Includes the following steps: Step 1: Extract all vertex data from the geological boundary lines in the input topographic contour lines and engineering geological profiles, and read the geological boundary point data exposed by the boreholes. Step 2: Based on the vertex data on the topographic contour lines, create a topographic surface model of the engineering area using implicit modeling, which serves as the upper limit of the three-dimensional geological model; Step 3: Based on the vertex data on the terrain contour lines, terrain direction data is calculated using a custom PCA principal component analysis algorithm to characterize the undulations of the terrain. Step 4: Perform adaptive resampling and thinning on the terrain direction data to preserve the key morphological features of terrain undulations; Step 5: Apply non-uniform dip attenuation constraints to the terrain orientation data after adaptive resampling and thinning to provide the final processed orientation data for subsequent geological interface modeling; Step 6: Using the geological boundary point data revealed by the borehole, the point data on the geological boundary line in the engineering geological profile, and the final processed direction data obtained in Step 5, a complete geological interface model of the engineering area constrained by the terrain is created using implicit modeling. Step 7: Perform Boolean operations on the topographic surface model and the complete geological interface model of the engineering area constrained by the topography to obtain the geological interface model below the topographic surface of the engineering area, which is used in the 3D geological modeling workflow.

2. The method according to claim 1, characterized in that: In step 1, the .dxf format file containing terrain contour data in the specified path is read, and the model space is obtained; Traverse and determine the type of terrain contour lines; For contour lines of type "LWPOLYLINE", use the entity.dxf.elevation.z method to get the Z coordinate of the contour line, and use the entity.get_points() method to get the X and Y coordinates of each node of the contour line in turn; For contour lines of type "POLYLINE", obtain the coordinates of each vertex on the contour line in sequence; Store the vertex coordinates of all topographic contour lines into the array topography.

3. The method according to claim 1, characterized in that: In step 1, the .dxf format file storing the geological boundary line data in the engineering geological profile is read using the same method as reading the topographic contour line file and saving all vertex data on the topographic contour line, and the vertex data on the geological boundary line in the engineering geological profile is stored in the array profile; Read the .csv file containing data on geological boundary points revealed by the boreholes and save it to the array points.

4. The method according to claim 1, characterized in that: In step 2, using all vertex data on the terrain contour lines, an independent scalar field of the terrain surface is constructed through a piecewise linear interpolation implicit modeling algorithm, and the terrain surface model is expressed in the form of isosurfaces, serving as the upper limit of the three-dimensional geological model; When performing piecewise linear interpolation, tetrahedral meshes are used to discretize the entire modeling region; By utilizing the shape function of the tetrahedral element, the unknown scalar values ​​of the four vertices of the tetrahedron are connected with the known scalar values ​​of point p through linear equations, and all the linear equations are combined to form a large, overdetermined sparse equation system. Regularization constraints are applied by establishing equations between each adjacent tetrahedral pair, forming a minimization problem, and then the least squares problem is solved to obtain the optimal scalar value for each grid node.

5. The method according to claim 1, characterized in that: In step 3, the terrain point data obtained in step 1 is used to accelerate the search for terrain point data by recursively dividing the three-dimensional space using a binary tree data structure. The orientation data of the terrain in the engineering area is calculated by a custom PCA principal component analysis algorithm, and the function of converting normal vector data into dip and dip angles and outputting terrain attitude data is supported. For each terrain point data, the k neighboring terrain points containing that terrain point are determined by setting parameters; For the direction calculation object point p and the k-1 neighboring terrain point data, the centroid calculation formula is used to calculate the center position, and then the centering process is performed to obtain the offset vector of each neighboring point relative to the centroid, and the covariance matrix is ​​constructed. Solve the covariance matrix to obtain the eigenvalues ​​and corresponding eigenvectors, and determine the normal vector of the approximate plane based on the solution results, and find the direction with the minimum variance in the result; For the extracted terrain normal vector data, the function of outputting terrain attitude data is provided. The dip and dip angle data corresponding to each normal vector data are calculated and the terrain attitude data is output.

6. The method according to claim 1, characterized in that: In step 4, the curvature of each normal vector position is calculated, and the terrain direction data is adaptively resampled and thinned according to the relationship of the eigenvalues ​​to ensure that more normal vector data is retained in areas with large terrain undulations and less normal vector data is retained in areas with small terrain undulations. The curvature values ​​at the data locations in each direction are determined using the covariance matrix solution, which is the plane fitting residual of the neighborhood point cloud, representing the surface roughness and variability. The curvature at each direction of the calculated data position is normalized to the probability of random sampling, and then adaptive resampling is performed.

7. The method according to claim 1, characterized in that: In step 5, the terrain orientation data obtained in step 4 after adaptive resampling and thinning is subject to non-uniform dip angle attenuation constraint, that is, the position and dip of each terrain orientation data are kept unchanged, and only the dip angle is subjected to non-uniform attenuation processing. The tilt angle calculation formula is used to calculate the tilt angle value corresponding to the normal vector data of each terrain, and the attenuation coefficient is designed according to the tilt angle value range. Iterate through all tilt angle data and determine the range of each tilt angle value to determine the corresponding attenuation coefficient, and multiply it by the corresponding tilt angle data to obtain the tilt angle data after non-uniform attenuation. Calculate the normal vector data in the X and Y directions after tilt attenuation, and obtain the normal vector data in the Z direction after tilt attenuation. Through steps 3-5, the topographic direction data of the engineering area is calculated using topographic point data. The topographic direction data is then subjected to adaptive resampling and thinning, as well as non-uniform dip attenuation processing. This ensures that areas with large topographic undulations retain more direction data and have strong dip attenuation, while areas with small topographic undulations retain less direction data and have weak dip attenuation. This provides the final processed direction data that conforms to geological laws for subsequent geological interface modeling.

8. The method according to claim 1, characterized in that: In step 6, using the geological boundary point data exposed by the boreholes stored in step 1 and the vertex data of the geological boundary line in the engineering geological profile, as well as the final processed direction data obtained in step 5, an independent scalar field of the geological interface is created by piecewise linear interpolation implicit modeling, and the complete geological interface of the engineering area constrained by the terrain is expressed in the form of isosurfaces.

9. The method according to claim 1, characterized in that: In step 7, the Manifold3D method is used to perform Boolean operations on the topographic surface model of the engineering area obtained in step 2 and the complete geological interface model of the engineering area constrained by the terrain obtained in step 6 to obtain the geological interface model below the topographic surface of the engineering area, which is used in the three-dimensional geological modeling workflow. Boolean operations are based on the principle of signed distance fields, and the specific algorithm logic is as follows: For node data in the geological interface mesh, calculate the signed nearest distance to the topographic surface; Based on the signed distance of nodes in the geological interface mesh from the topographic surface, when all three vertices of the mesh triangle are located below the topographic surface, all node data and the mesh triangle they form are retained. When all three vertices of the meshing triangle are located above the terrain surface, discard all node data and the meshing triangle. When one or two vertices of the network triangle are located below the terrain surface, retain the node data located below the terrain surface and discard the node data located above the terrain surface. For cases where one or two vertices of the geological interface network triangle are located below the topographic surface, linear interpolation is used to calculate the coordinates of the intersection points between the topographic surface and the sides of the geological interface network triangle. For the endpoints of the geological interface structure network The corresponding signed distance is The interpolation parameters are Obtain the coordinates of the intersection point. ; Triangulate the network triangles based on the number of vertices retained: If one vertex is retained, then that vertex and the two intersection points form a new triangle; If two vertices are retained, then a quadrilateral is formed with the two intersection points; Only all the mesh polygons located below the terrain surface are combined to form a terrain-constrained 3D geological interface model below the terrain surface, which is used in the 3D geological modeling workflow.