Method, device and equipment for generating terrain grid of wind farm
The N fork tree algorithm divides the grid layer by layer according to the change of terrain surface curvature value, which solves the problem of slow generation of terrain grids in the existing technology, and achieves more efficient grid generation and computing resource utilization.
Patent Information
- Application Number
- CN202010622950.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-06-30
- Publication Date
- 2024-12-06
- Estimated Expiration
- 2040-06-30
AI Technical Summary
The existing wind power plant terrain grid generation method uses structured grids, resulting in the grid generation speed being very slow and consumes a lot of computing resources and time.
The N forktree algorithm is used to divide the two-dimensional calculation areas layer by layer, and the segmentation depth of the grid cells is determined based on the change of the terrain surface curvature, and an unstructured grid is generated to adapt to the grid cell density of rugged and flat terrain areas.
It improves the speed and efficiency of grid generation, reduces the consumption of computing resources, and improves the expression accuracy of rugged terrain areas and the computing efficiency of flat terrain areas.
Smart Images

Figure CN113868968B_ABST
Abstract
Description
Technical Field
[0001] The embodiments of the present application relate to the field of wind power generation technology, and in particular to a method, device and equipment for generating a terrain grid of a wind farm. Background Art
[0002] CFD (Computational Fluid Dynamics) numerical simulation of near-surface flow fields is an important part of wind resource assessment, and gridding the calculation area for wind resource assessment is the basis of CFD calculation. The quality of gridding has a great influence on the accuracy, convergence and calculation efficiency of fluid simulation.
[0003] At present, the main method for dividing the computational area for wind resource assessment into grids is to divide the computational area into structured grids. Structured grids have a regular topological structure, and the number of grid nodes on each layer is equal. Therefore, dividing the computational area into structured grids requires the entire computational area to be meshed, which makes the number of grids generated based on the meshing of the computational area very large, which not only consumes computing resources, but also requires a long computing time, resulting in a very slow mesh generation speed.
[0004] Therefore, it is necessary to provide a new method, device and equipment for generating a terrain grid of a wind farm. Summary of the invention
[0005] The purpose of the embodiments of the present application is to provide a method, device and equipment for generating a terrain grid of a wind farm, so as to solve the technical problem that the existing grid generation speed is very slow.
[0006] In order to achieve the above-mentioned purpose, in a first aspect, an embodiment of the present application provides a method for generating a terrain grid of a wind farm, comprising: determining a two-dimensional calculation area for a grid to be generated based on a terrain geometry model; dividing the two-dimensional calculation area into layers of grids according to an N-ary tree algorithm, where N is a positive integer greater than 1; in the process of dividing each layer of grids, after dividing N grid units of the current layer, when it is determined that the terrain surface curvature change value between a grid unit of the current layer and an adjacent grid unit is greater than a preset threshold, continuing to divide the grid unit of the current layer into the next layer of grids until the terrain surface curvature change value is less than or equal to the preset threshold, thereby obtaining a plane grid.
[0007] Optionally, determining the two-dimensional calculation area for the grid to be generated based on the terrain geometry model includes: displaying a two-dimensional projection image of the terrain geometry model from a top-down perspective; upon receiving a selection instruction for at least one area in the two-dimensional projection image from a top-down perspective, determining the at least one area to be at least one target area; determining an area including all the target areas as a core area; and expanding outward based on the core area to obtain the two-dimensional calculation area.
[0008] Optionally, the gridding the two-dimensional calculation area layer by layer according to the N-ary tree algorithm includes: gridding each of the target areas in the two-dimensional calculation area layer by layer according to the N-ary tree algorithm; and when it is determined that the change value of the terrain surface curvature between a grid unit of the current layer and an adjacent grid unit is greater than a preset threshold, continuing to grid the grid units of the current layer to the next layer, including: in each of the target areas, when it is determined that the change value of the terrain surface curvature between a grid unit of the current layer and an adjacent grid unit is greater than a preset threshold, continuing to grid the grid units of the current layer to the next layer.
[0009] Optionally, after obtaining the plane grid, it also includes: projecting the plane grid onto the three-dimensional surface figure of the terrain geometric model to obtain a three-dimensional surface grid; determining the sweeping direction of each three-dimensional surface grid node and the sweeping length along the sweeping direction; and generating a three-dimensional space grid according to the sweeping direction and the sweeping length of each three-dimensional surface grid node.
[0010] Optionally, determining the sweeping direction of each three-dimensional surface grid node and the sweeping length along the sweeping direction includes: for each three-dimensional surface grid node, determining the sweeping direction of the three-dimensional surface grid node based on the normal of the three-dimensional surface grid unit adjacent to the three-dimensional surface grid node; and using the Fibonacci sequence as the number of layer-by-layer iterations in the grid sweeping to determine the sweeping length along the sweeping direction.
[0011] Optionally, determining the sweeping direction of the three-dimensional surface grid node based on the normals of the three-dimensional surface grid units adjacent to the three-dimensional surface grid node includes: determining the normals of all three-dimensional surface grids adjacent to the three-dimensional surface grid node; based on a preset weighting coefficient, performing weighted calculation on the normals of all three-dimensional surface grids adjacent to the three-dimensional surface grid node to determine the first sweeping direction of the three-dimensional surface grid node; the weighting coefficient is determined according to the area weight, angle weight, angle sine weight, center distance weight, or conformal mapping of all three-dimensional surface grids adjacent to the three-dimensional surface grid node.
[0012] Optionally, determining the sweeping direction of the three-dimensional surface grid node based on the normal of the three-dimensional surface grid unit adjacent to the three-dimensional surface grid node also includes: adjusting the first sweeping direction based on the sweeping directions of other three-dimensional surface grid nodes adjacent to the three-dimensional surface grid node, and using the adjusted first sweeping direction as the second sweeping direction of the three-dimensional surface grid node, so as to sweep according to the second sweeping direction.
[0013] In the second aspect, an embodiment of the present application also provides a device for generating a terrain grid of a wind farm, comprising: a determination module, used to determine a two-dimensional calculation area for a grid to be generated based on a terrain geometry model; a grid division module, used to perform layer-by-layer grid division on the two-dimensional calculation area according to an N-ary tree algorithm, where N is a positive integer greater than 1; in the process of each layer of grid division, after N grid units of the current layer are divided, when it is determined that a terrain surface curvature change value between a grid unit of the current layer and an adjacent grid unit is greater than a preset threshold, the next layer of grid division is continued for the grid unit of the current layer until the terrain surface curvature change value is less than or equal to the preset threshold, thereby obtaining a plane grid.
[0014] In a third aspect, an embodiment of the present application further provides a computer-readable storage medium, which is used to store a computer program. When the computer program is run on a computer, the method for generating a wind farm terrain grid as described in the first aspect above is implemented.
[0015] In a fourth aspect, an embodiment of the present application further provides a system for generating a terrain grid of a wind farm, comprising a memory and a processor that are communicatively connected; at least one program is stored in the memory, and is used to implement the method for generating a terrain grid of a wind farm as described in the first aspect above when executed by the processor.
[0016] Compared with the prior art, the technical solution of the embodiment of the present application has at least the following beneficial technical effects:
[0017] The embodiment of the present application adopts an N-ary tree algorithm to perform layer-by-layer grid division on the two-dimensional calculation area, where N is an integer greater than 1; in the process of each layer of grid division, after dividing N grid units of the current layer, when it is determined that the terrain surface curvature change value between a grid unit of the current layer and an adjacent grid unit is greater than a preset threshold, the grid unit of the current layer continues to be divided into the next layer of grids until the terrain surface curvature change value is less than or equal to the preset threshold, and a plane grid is obtained. The implementation of the present application divides the grid according to the terrain surface curvature change value, so that the grid unit size is smaller in the terrain area with relatively rugged terrain. The smaller grid unit size can effectively increase the density of the grid unit, and use a higher density of grid units to improve the expression accuracy of the rugged terrain area; the grid unit size is larger in the terrain area with relatively flat terrain, and the terrain change is smaller in the terrain area with relatively flat terrain. The use of larger grid unit representation has a basically negligible effect on the expression accuracy of the terrain area with relatively flat terrain. The larger grid unit size can effectively reduce the density of the grid unit, which is conducive to reducing the number of grid units in the two-dimensional calculation area, reducing computing resources in the grid division process, and reducing computing time, thereby improving the speed of grid generation.
[0018] Additional aspects and advantages of the present application will be partially given in the following description, which will become apparent from the following description, or will be understood through the practice of the present application. BRIEF DESCRIPTION OF THE DRAWINGS
[0019] The above and / or additional aspects and advantages of the present application will become apparent and easily understood from the following description of the embodiments in conjunction with the accompanying drawings, in which:
[0020] Figure 1 A schematic diagram of a flow chart of a method for generating a terrain grid for a wind farm provided in an embodiment of the present application;
[0021] Figure 2 A schematic flow chart of a specific method for determining a two-dimensional calculation area for generating a grid based on a terrain geometric model provided in an embodiment of the present application;
[0022] Figure 3 A schematic diagram of a flow chart of a specific method for meshing a two-dimensional computing area according to an N-ary tree algorithm provided in an embodiment of the present application;
[0023] Figure 4 A schematic diagram of a flow chart of a specific method for generating a three-dimensional space grid based on a plane grid provided in an embodiment of the present application;
[0024] Figure 5 A schematic flow chart of a specific method for determining a sweep direction and a sweep length provided in an embodiment of the present application;
[0025] Figure 6A flowchart of a specific method for determining a first sweeping direction provided in an embodiment of the present application;
[0026] Figure 7 A flowchart of a specific method for determining a second sweep direction provided in an embodiment of the present application;
[0027] Figure 8 This is a schematic diagram of expanding the target area into a two-dimensional calculation area in an embodiment of the present application;
[0028] Figure 9a This is a schematic diagram of a plane grid generated when the core area includes only one target area in the embodiment of the present application;
[0029] Figure 9b A schematic diagram of a plane grid generated when the core area includes two target areas in an embodiment of the present application;
[0030] Fig.10 A schematic diagram of gridding a target area based on a background grid in an embodiment of the present application;
[0031] Fig.11 Shown with Fig.10 A schematic diagram of meshing the grid cells in the target area whose curvature change value of the terrain surface is greater than a preset threshold based on the grid;
[0032] Fig.12 A schematic diagram of a three-dimensional surface grid in an embodiment of the present application;
[0033] Fig.13 A schematic diagram of determining a first sweep direction based on a normal of a three-dimensional surface grid cell adjacent to a three-dimensional surface grid node in an embodiment of the present application;
[0034] Fig.14a This is a schematic diagram of a lead line in which the first scanning direction is not adjusted in an embodiment of the present application;
[0035] Fig.14b A schematic diagram of leads in the second scanning direction in an embodiment of the present application;
[0036] Fig.15 A schematic cross-sectional view of a three-dimensional space grid in an embodiment of the present application;
[0037] Fig.16 A schematic diagram of the structure of a device for generating a terrain grid for a wind farm provided in an embodiment of the present application;
[0038] Fig.17 A schematic diagram of the structure of a device for generating a terrain grid for a wind farm provided in an embodiment of the present application. DETAILED DESCRIPTION
[0039] The embodiments of the present application are described in detail below, and examples of the embodiments are shown in the accompanying drawings, wherein the same or similar reference numerals throughout represent the same or similar elements or elements having the same or similar functions. The embodiments described below with reference to the accompanying drawings are exemplary and are only used to explain the present application, and cannot be interpreted as limiting the present application.
[0040] It will be understood by those skilled in the art that, unless otherwise defined, all terms (including technical and scientific terms) used herein have the same meaning as those generally understood by those skilled in the art to which this application belongs. It should also be understood that terms such as those defined in general dictionaries should be understood to have meanings consistent with those in the context of the prior art, and will not be interpreted with idealized or overly formal meanings unless specifically defined as here.
[0041] Those skilled in the art will appreciate that, unless otherwise stated, the singular forms "a", "an", "said" and "the" used herein may also include plural forms. It should be further understood that the term "comprising" used in the specification of the present application refers to the presence of the features, integers, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, integers, steps, operations, elements, components and / or groups thereof. The term "and / or" used herein includes all or any unit and all combinations of one or more associated listed items.
[0042] The inventors of the present application conducted research and found that when dividing the calculation area for wind resource assessment into grids, although dividing the calculation area into structured grids achieves grid division, due to the limitations of the structured grid's own properties (having a regular topological structure and the same number of grid nodes on each layer), the entire calculation area needs to be gridded, so that the number of grids generated based on the grid division of the calculation area is very large, which not only consumes computing resources, but also requires a long computing time, resulting in a very slow grid generation speed.
[0043] The method, device, equipment and storage medium for generating a terrain grid of a wind farm provided in the present application are intended to solve the above technical problems of the prior art.
[0044] The technical solution of the present application and how the technical solution of the present application solves the above-mentioned technical problems are described in detail below with specific embodiments. The following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments. The embodiments of the present application will be described below in conjunction with the accompanying drawings.
[0045] The embodiment of the present application provides a method for generating a terrain grid of a wind farm. The method can be specifically executed by an electronic device of the embodiment of the present application. Specifically, the electronic device can be any device that supports interface interaction, such as a mobile terminal, a PC (personal computer, personal computer). A user can use an electronic device to log in to a web client or an app client to obtain a terrain grid of a wind farm. A flow chart of a method for generating a terrain grid of a wind farm in the embodiment of the present application is shown in FIG. Figure 1 As shown, the following steps are included:
[0046] S101: Determine a two-dimensional calculation area for generating a grid based on a terrain geometry model.
[0047] Optionally, in the embodiment of the present application, a MAP format file (an image data call file that can simulate the scene of a wind farm) can be used to describe the geometric shape of the terrain. The terrain geometry model includes spatial position features and terrain attribute features. The terrain geometry model can be input by the user when performing a single project calculation, or it can be obtained from a pre-stored model according to the calculation needs. In the embodiment of the present application, after obtaining the terrain geometry model, a map will be displayed on the display interface according to the terrain geometry model. The user can select an area on the map as needed, and then determine the two-dimensional calculation area according to the area selected by the user. The two-dimensional calculation area can be a circular area or a rectangular area, and the shape of the two-dimensional calculation area can be set according to actual conditions. In one embodiment, the size of the two-dimensional calculation area is limited by the radius. After a certain area is selected, the area can also be expanded, and the expanded area can be used as the two-dimensional calculation area to improve the accuracy of generating a grid based on the two-dimensional calculation area.
[0048] S102: According to the N-ary tree algorithm, the two-dimensional calculation area is gridded layer by layer, where N is a positive integer greater than 1; in the process of each grid division, after N grid units of the current layer are divided, when it is determined that the terrain surface curvature change value between a grid unit of the current layer and an adjacent grid unit is greater than a preset threshold, the next grid division is continued for the grid unit of the current layer until the terrain surface curvature change value is less than or equal to the preset threshold, thereby obtaining a plane grid.
[0049] Optionally, specifically, the embodiment of the present application adopts the Cartesian method according to the N-tree algorithm to perform layer-by-layer grid division on the two-dimensional calculation area to form an unstructured grid. Among them, the N-tree algorithm can be a binary tree algorithm, a ternary tree algorithm, a quadtree algorithm, an octree algorithm, etc., which can be selected according to actual conditions. In the embodiment of the present application, the quadtree algorithm is preferred. The two-dimensional calculation area is used as the root node of the quadtree, and the two-dimensional calculation area is divided into four grid units to form four child nodes of the quadtree. By analogy, the two-dimensional area is divided layer by layer until the last layer of the quadtree structure. In one embodiment, the depth of the quadtree structure is determined by a terrain image, computer memory, terrain complexity, terrain geometric features, etc.; preferably, in the embodiment of the present application, the depth of the quadtree structure is determined based on the terrain surface curvature change value. Specifically, when it is determined that the terrain surface curvature change value of a grid unit of a current layer and an adjacent grid unit is greater than a preset threshold, the grid unit of a current layer continues to be grid divided into the next layer until the terrain surface curvature change value is less than or equal to the preset threshold, and a plane grid is obtained.
[0050] Alternatively, if Figure 2 As shown, in the above step S101, the specific method of determining the two-dimensional calculation area of the grid to be generated according to the terrain geometric model includes the following steps:
[0051] S201: Display a two-dimensional projection image of a terrain geometry model from a top-down perspective.
[0052] Optionally, after the terrain geometric model is acquired, a two-dimensional projection image of the terrain geometric model from a top-down perspective will be displayed on the display interface.
[0053] S202: upon receiving a selection instruction for at least one area in the two-dimensional projection image from a top-down perspective, determining the at least one area as at least one target area.
[0054] Optionally, the user can select at least one area on the two-dimensional projection image displayed on the display interface; the method for selecting the area includes: (1) selecting two coordinate points, and determining an area according to the two coordinate points located on the diagonal line, such as Figure 8 As shown in the figure, the user selects the coordinate point on the northwest corner and the coordinate point on the southeast corner, determines a square area based on the coordinate points on the diagonal, and then uses the area where the circumscribed circle of the square area is located as the target area; (2) selects two coordinate points, takes one of the coordinate points as the center of the circle, and the straight-line distance between the two coordinate points as the radius, and determines a circular area as the target area; (3) selects two coordinate points, takes the straight-line distance between the two coordinate points as the diameter, and determines a circular area as the target area. In one embodiment, in addition to using the area selected by the user as the target area, an area determined based on location information such as the wind tower coordinates and the wind turbine site coordinates can also be used as the target area.
[0055] S203: Determine an area including all target areas as a core area.
[0056] Optionally, when there is only one target region, the core region is the target region (e.g. Figure 9a ); When including two or more target areas, the core area is the circumscribed circle area of all target areas (such as Figure 9b In one embodiment, the core area including all target areas may be an area of any shape, which may be adjusted according to actual conditions and is not limited here.
[0057] S204: Expand outward based on the core area to obtain a two-dimensional calculation area.
[0058] Alternatively, if Figure 8 As shown, when the core area is a circular area, the expansion is based on the radius of the core area, increasing a preset length or extending the radius of the core area according to a preset ratio to obtain an expansion radius, and the expansion area is established based on the expansion radius, and the two-dimensional calculation area is the inscribed square area of the expansion area (adapting to the technical solution of using the Cartesian method to perform grid division using the quadtree algorithm in the embodiment of the present application, the two-dimensional calculation area is set as a square area). In one embodiment, the diagonal of the inscribed square area is greater than the diameter of the core area to ensure the accuracy of the generated grid.
[0059] In the embodiment of the present application, considering that the wind turbine sites are relatively scattered in some wind farm terrains, if only one area can be specified as the target area for grid division, it will lead to an increase in the number of unnecessary grids and a waste of computing resources; therefore, a solution is proposed to use multiple target areas as core areas to generate a two-dimensional calculation area, so as to effectively reduce the number of grids and the calculation time, and improve the speed of generating grids.
[0060] Alternatively, if Figure 3 As shown, step S102 divides the two-dimensional calculation area into grids layer by layer according to the N-ary tree algorithm, including:
[0061] S301: According to the N-ary tree algorithm, each target area in the two-dimensional calculation area is grid-divided layer by layer.
[0062] Optionally, according to the preset quadtree structure depth, the two-dimensional calculation area is grid-divided layer by layer to generate a background grid; based on the background grid, the grid occupied by the target area is grid-divided into the next layer, and this is used as the last layer of the preset quadtree structure (such as Fig.10). The preset quadtree structure depth may be a default value, such as four layers; or may be set according to parameters such as the complexity of the terrain and the computing power of the computer. In one embodiment, the process of dividing the target area into the next layer of grids based on the background grid may be understood as a first-level grid encryption (relative to the grid density of the layer where the background grid is located, the grid density of the layer where the target area is located is greater).
[0063] And, in step S102, when it is determined that the curvature change value of the terrain surface between a grid unit of the current layer and an adjacent grid unit is greater than a preset threshold, the grid unit of the current layer is further divided into a next layer of grids, including:
[0064] S302: In each target area, when it is determined that the terrain surface curvature change value between a grid unit of the current layer and an adjacent grid unit is greater than a preset threshold, the grid unit of the current layer is continuously divided into a next layer of grids.
[0065] Alternatively, if Fig.11 As shown, based on the grid generated in step S301, for each grid unit occupied by the target area, when it is determined that the change value of the terrain surface curvature between a grid unit of the current layer and an adjacent grid unit is greater than a preset threshold, the grid unit of the current layer continues to be meshed in the next layer, and the grid formed after meshing based on the change value of the terrain surface curvature is used as the last layer of the quadtree structure (finally determining the depth of the quadtree). That is, through the implementation of step S302, the position where the terrain surface curvature changes greatly is meshed (encrypted grid), ensuring uniform grid transition, and distinguishing the geometric structure characteristics of the model through the refinement process of layer-by-layer meshing. Specifically, the implementation of step S302 is a geometrically adaptive meshing process, and the judgment basis of geometric adaptation is that the change of the terrain surface curvature of adjacent grids is greater than the preset threshold, as shown in the following expression 1:
[0066] K cell -K cell_neighbor >ΔK…………………Expression 1
[0067] In expression 1, K cell represents the terrain surface curvature of the target grid cell, K cell_r The curvature of the terrain surface of the adjacent grid cells representing the target grid cell, ΔK is a preset threshold, generally not greater than 0, and the specific value can be determined according to the grid division requirements. In one embodiment, the grid based on step S301 can be used for the grid cells occupied by each target area. When it is determined that the change value of the terrain surface curvature between a grid cell of the current layer and an adjacent grid cell is greater than the preset threshold, the grid cell of the current layer is continued to be divided into the next layer of grids, which is understood as secondary grid encryption (relative to the grid density after the primary grid encryption, the grid density after the secondary grid encryption is greater).
[0068] Based on the implementation of the above embodiment, a Cartesian quadtree method is used to realize local adaptive grid division of a two-dimensional calculation area according to the complexity of the terrain, the location of the wind turbine, the location of the wind tower, etc., that is, the grid cells where the terrain complexity is high and the wind turbine location and the wind tower location are located are encrypted, which is beneficial to reduce the overall number of generated grids, reduce the calculation time, and improve the speed of generating grids; at the same time, a function of specifying multiple target areas is added to realize the function of local grid encryption in multiple target areas, further reducing the number of grids and the calculation time.
[0069] Alternatively, if Figure 4 As shown, after obtaining the plane grid in step S102, the embodiment of the present application further includes:
[0070] S401: Projecting the plane grid onto the three-dimensional surface graphics of the terrain geometry model to obtain a three-dimensional surface grid.
[0071] Alternatively, if Fig.12 As shown, the two-dimensional plane grid is projected onto the three-dimensional surface graphics, and the surface geometry model is parameterized (the parameterized model can map points on the plane to points on the surface). Since the parameterized model is discretized, the position of the point on the surface can be calculated by determining the surface quadrangle (grid unit) to which the point on the plane (grid node) belongs, so as to project the grid nodes on the plane grid to obtain a three-dimensional surface grid. That is, through the parameterized model of the surface geometry model, the position of each node on the plane grid on the surface is calculated, and by projecting one by one, the three-dimensional surface grid is generated based on the two-dimensional plane grid.
[0072] Optionally, in areas with large terrain gradients, projecting quadrilateral grid cells on a plane grid onto the terrain surface will form distorted grid cells or invalid grid cells. Therefore, after generating a three-dimensional surface grid, the three-dimensional surface grid is also checked for validity, and the grid cells in the three-dimensional surface grid are smoothed to convert distorted grid cells or invalid grid cells into valid grid cells.
[0073] S402: Determine the sweep direction and the sweep length along the sweep direction of each three-dimensional surface grid node.
[0074] S403: Generate a three-dimensional space grid according to the sweep direction and sweep length of each three-dimensional surface grid node.
[0075] In steps S402 and S403, the sweep direction of each three-dimensional surface grid node and the sweep length along the sweep direction are determined; according to the sweep direction and sweep length of each three-dimensional surface grid node, a three-dimensional space grid is generated. Specifically, a three-dimensional space grid (atmospheric boundary layer grid) is generated by sweeping based on the three-dimensional surface grid. In order to improve the quality of the atmospheric boundary layer grid, in the prior art, the sweep is generally performed along the normal direction of the three-dimensional surface grid. However, as the number of sweeps increases, the grid grows along the normal direction and is prone to self-intersection, which causes the generated atmospheric boundary layer grid to fail. Based on this, an embodiment of the present application proposes an optimized sweeping method, in order to prevent the grid from intersecting due to the surface pull-up perpendicular to the three-dimensional surface grid unit, the growth direction (sweeping direction) of the atmospheric boundary layer grid is adjusted during the sweeping process to ensure the effectiveness of the three-dimensional space grid generated in the area with a higher terrain gradient. Specifically, the grid cells on the three-dimensional surface grid are pushed outward along the preset direction to generate a prism grid near the ground. Each edge of the prism grid forms a lead line, and the grid nodes of the three-dimensional surface grid are projected along the lead line direction to generate a three-dimensional space grid (the cross section of the three-dimensional space grid is as follows: Fig.15 ), where the leader is determined by the sweep direction and sweep length.
[0076] In an embodiment of the present application, by optimizing the sweeping method, the sweeping direction and sweeping length of the three-dimensional surface grid stretched upward are determined, which is conducive to gradually extending the three-dimensional space grid that undulates with the surface to the same horizontal height.
[0077] Alternatively, if Figure 5 As shown, step S402 determines the sweep direction and the sweep length along the sweep direction of each three-dimensional surface grid node, including:
[0078] S501: For each three-dimensional surface grid node, determine a sweep direction of the three-dimensional surface grid node based on the normals of three-dimensional surface grid cells adjacent to the three-dimensional surface grid node.
[0079] Optionally, if the three-dimensional surface grid is divided based on a quadtree algorithm, the three-dimensional surface grid includes multiple grid nodes, such as four matrix-arranged grid units include at least one three-dimensional surface grid node; accordingly, one three-dimensional surface grid node includes four adjacent three-dimensional surface grids.
[0080] S502: Using the Fibonacci sequence as the number of iterations layer by layer in the grid sweeping, determining the sweeping length along the sweeping direction.
[0081] Optionally, in the embodiment of the present application, the Jacobi iteration method is used to complete the iteration in the sweeping process, which is conducive to the parallelization of mesh generation; wherein the number of iterations is limited by the Fibonacci sequence, that is, each time the Jacobi iteration method is used to iterate a layer of spatial mesh, the Fibonacci sequence is used to determine the sweep length of the layer of spatial mesh (such as Fig.15 As shown, the sweep length of each layer of the three-dimensional space grid is different). The total sweep length of the three-dimensional space grid finally generated is determined according to the convergence degree of the Jacobi iteration method when iterating the grid.
[0082] Alternatively, if Figure 6 As shown, step S501 determines the sweep direction of the three-dimensional surface grid node based on the normal of the three-dimensional surface grid unit adjacent to the three-dimensional surface grid node, including:
[0083] S601: Determine the normal directions of all three-dimensional surface grid cells adjacent to a three-dimensional surface grid node.
[0084] Optionally, for each three-dimensional surface grid node, all three-dimensional surface grid cells adjacent to the three-dimensional surface grid node are determined, and the normal of the three-dimensional surface grid cell is calculated.
[0085] S602: Based on a preset weighting coefficient, a weighted calculation is performed on the normals of all three-dimensional surface grid cells adjacent to the three-dimensional surface grid node to determine a first sweeping direction of the three-dimensional surface grid node; the weighting coefficient is determined according to the area weight, angle weight, angle sine weight, center distance weight, or conformal mapping of all three-dimensional surface grid cells adjacent to the three-dimensional surface grid node.
[0086] Alternatively, if Fig.13 As shown, assuming that the three-dimensional surface grid unit adjacent to the three-dimensional surface grid node is a triangular surface unit, there are 6 three-dimensional surface grid units adjacent to the three-dimensional surface grid node. After the normal of each three-dimensional surface grid unit is calculated in step S601, the initial sweep direction of the three-dimensional surface grid node can be determined by the following expression 2:
[0087]
[0088] in, represents the normal direction of the 3D surface grid node i, represents the unit normal of the triangular face element connected to the 3D surface grid node i, W j is the weighting coefficient, Fig.13 Medium iRepresents the position of the three-dimensional surface grid node i. The calculation methods of the weighting coefficient include area weighting method, angle weighting method, angle sine weighting method, centroid distance weighting method and conformal mapping method, etc. The embodiment of the present application selects the angle weighting method to calculate the weighting coefficient. For example, based on the perpendicular to the horizontal plane, the closer the normal perpendicular to the surface of the three-dimensional surface grid unit is to the basic normal, the larger the weighting coefficient is; the weighting coefficient can be adjusted according to actual conditions and is not limited here. By weighted calculation of the normals of all three-dimensional surface grid units adjacent to the three-dimensional surface grid node, the direction of the normal determined by the result of the weighted calculation is used as the first sweeping direction of the three-dimensional surface grid node, that is, the initial sweeping direction when sweeping based on the three-dimensional surface grid.
[0089] Alternatively, if Figure 7 As shown, step S501 determines the sweeping direction of the three-dimensional surface grid node based on the normal of the three-dimensional surface grid unit adjacent to the three-dimensional surface grid node, and on the basis of including the above steps S601 and S602, further includes the following steps:
[0090] S603: adjusting the first sweeping direction based on the sweeping directions of other three-dimensional surface grid nodes adjacent to the three-dimensional surface grid node, and using the adjusted first sweeping direction as the second sweeping direction of the three-dimensional surface grid node, so as to perform sweeping according to the second sweeping direction.
[0091] Optionally, considering that as the number of sweeps increases, the first sweep directions of the three-dimensional surface grid nodes determined in step S602 may intersect, resulting in the invalidity of the generated three-dimensional space grid (e.g. Fig.14a As shown in FIG. 1 , the first sweeping direction is adjusted at any time during the sweeping process. The adjustment method is as follows: the first sweeping direction is adjusted so as to be nearly parallel to the sweeping directions of other adjacent three-dimensional surface grid nodes (such as Fig.14b shown).
[0092] In the specific calculation process of adjusting the first sweep direction, in order to obtain The minimum value of is the direction most parallel to the lead vector of the surrounding three-dimensional surface grid nodes, combined with the following expression 3:
[0093]
[0094] Among them, n i is the number of the 3D surface grid node i, N is the number of 3D surface grid units adjacent to the 3D surface grid node i, and each lead vector is taken as a unit normal vector as a restriction condition, combined with the following expression 4:
[0095]
[0096] To ensure the validity of the normal, it is set that if and only if the second sweep direction of the 3D surface grid node i is visible to all adjacent grid cells, n i is valid, combined with the following expression 5:
[0097]
[0098] Among them, M i The set of grid cells adjacent to the 3D surface grid node i, is the unit normal vector of one of the grid cells.
[0099] In one embodiment, the second sweep direction at the three-dimensional surface grid node i can be obtained by Lagrange multiplier method. In the kth iteration step, the second sweep direction of the three-dimensional surface grid node i is (the Jacobi iteration method can be used to solve the following expression 6):
[0100]
[0101] After the second sweep direction of the three-dimensional mesh node is determined in step S603, sweeping is performed based on the second sweep direction and the sweep length.
[0102] Specifically, in one application example, a user can log in to the cloud platform to create a new computing project, upload map files, wind tower coordinate information, wind turbine site coordinate information, etc. After the device successfully parses the files and information, a terrain map will be displayed on the display interface. The user can select a target area on the terrain map (such as steps S201-S203); then set the horizontal resolution and vertical resolution for the target area, and select the sector calculation angle and thermal stability level, so that the calculation results are submitted to the background to generate relevant configuration files, and then the wind farm terrain grid generation method provided in the above embodiment (such as step S102) is used to generate a grid.
[0103] Based on the same inventive concept, Fig.16 As shown, the embodiment of the present application further provides a device 1600 for generating a terrain grid of a wind farm, comprising: a determination module 1601 and a grid division module 1602 .
[0104] The determination module 1601 is used to determine the two-dimensional calculation area of the grid to be generated according to the terrain geometric model.
[0105] The grid division module 1602 is used to perform grid division on the two-dimensional calculation area layer by layer according to the N-ary tree algorithm, where N is a positive integer greater than 1; in the process of each layer of grid division, after dividing N grid units of the current layer, when it is determined that the terrain surface curvature change value between a grid unit of the current layer and an adjacent grid unit is greater than a preset threshold, the next layer of grid division is continued for the grid unit of the current layer until the terrain surface curvature change value is less than or equal to the preset threshold, thereby obtaining a plane grid.
[0106] Optionally, the determination module 1601 includes: a display unit for displaying a two-dimensional projection image of a terrain geometric model from a top-down perspective; a first determination unit for determining at least one area as at least one target area upon receiving a selection instruction for at least one area in the two-dimensional projection image from a top-down perspective; a second determination unit for determining an area containing all target areas as a core area; and an expansion unit for expanding based on the core area to obtain a two-dimensional calculation area.
[0107] Optionally, the determination module 1601 includes: a first division unit, used to perform grid division layer by layer on each target area in the two-dimensional calculation area according to an N-ary tree algorithm; a second division unit, used in each target area, when it is determined that the terrain surface curvature change value between a grid unit of the current layer and an adjacent grid unit is greater than a preset threshold, to continue to perform grid division on the grid unit of the current layer to the next layer.
[0108] Optionally, device 1600 also includes: a projection module, used to project the plane grid onto the three-dimensional surface graphics of the terrain geometry model to obtain a three-dimensional surface grid; a calculation module, used to determine the sweeping direction of each three-dimensional surface grid node and the sweeping length along the sweeping direction; a sweeping module, used to generate a three-dimensional space grid according to the sweeping direction and sweeping length of each three-dimensional surface grid node.
[0109] Optionally, the calculation module includes: a sweeping direction unit, used to determine the sweeping direction of each three-dimensional surface grid node based on the normal of the three-dimensional surface grid cell adjacent to the three-dimensional surface grid node; a sweeping length unit, used to determine the sweeping length along the sweeping direction using the Fibonacci sequence as the number of layer-by-layer iterations in the grid sweeping.
[0110] Optionally, the sweeping direction unit includes: a determination subunit, used to determine the normals of all three-dimensional surface grid cells adjacent to the three-dimensional surface grid node; a calculation subunit, used to perform weighted calculation on the normals of all three-dimensional surface grid cells adjacent to the three-dimensional surface grid node based on a preset weighting coefficient, and determine the first sweeping direction of the three-dimensional surface grid node; the weighting coefficient is determined according to the area weight, angle weight, angle sine weight, center distance weight, or conformal mapping of all three-dimensional surface grid cells adjacent to the three-dimensional surface grid node.
[0111] Optionally, the sweeping direction unit also includes: an adjustment subunit, used to adjust the first sweeping direction based on the sweeping directions of other three-dimensional surface grid nodes adjacent to the three-dimensional surface grid node, and use the adjusted first sweeping direction as the second sweeping direction of the three-dimensional surface grid node to sweep according to the second sweeping direction.
[0112] The device for generating a wind farm terrain grid in the embodiment of the present application can execute a method for generating a wind farm terrain grid provided in the embodiment of the present application, and the implementation principle is similar. The actions performed by each module in the device for generating a wind farm terrain grid in each embodiment of the present application correspond to the steps in the method for generating a wind farm terrain grid in each embodiment of the present application. For the detailed functional description of each module in the device for generating a wind farm terrain grid, please refer to the description in the corresponding method for generating a wind farm terrain grid shown in the previous text, which will not be repeated here.
[0113] Based on the same inventive concept, an embodiment of the present application further provides a computer-readable storage medium, which is used to store a computer program. When the computer program runs on a computer, a method for generating a terrain grid of a wind farm is implemented.
[0114] Computer readable media include, but are not limited to, any type of disk (including floppy disks, hard disks, optical disks, CD-ROMs, and magneto-optical disks), ROMs, RAMs, EPROMs (Erasable Programmable Read-Only Memory), EEPROMs, flash memories, magnetic cards, or optical cards. In other words, readable media include any medium that can store or transmit information in a form that can be read by a device (e.g., a computer).
[0115] Based on the same inventive concept, a device for generating a terrain grid of a wind farm includes a memory and a processor that are communicatively connected; at least one program is stored in the memory and is used to implement a method for generating a terrain grid of a wind farm when executed by the processor.
[0116] Reference below Fig.17, which shows a schematic diagram of the structure of a device 1700 for generating a wind farm terrain grid suitable for implementing the embodiment of the present application. The device for generating a wind farm terrain grid in the embodiment of the present application (hereinafter referred to as an electronic device) may include but is not limited to devices such as a computer. Fig.17 The electronic device shown is merely an example and should not bring any limitation to the functions and scope of use of the embodiments of the present application.
[0117] The electronic device includes: a memory and a processor, wherein the processor here may be referred to as a processing device 1701 hereinafter, and the memory may include at least one of a read-only memory (ROM) 1702, a random access memory (RAM) 1703, and a storage device 1708 hereinafter, as specifically shown below:
[0118] like Fig.17 As shown, the electronic device 1700 may include a processing device (e.g., a central processing unit, a graphics processor, etc.) 1701, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 1702 or a program loaded from a storage device 1708 to a random access memory (RAM) 1703. In the RAM 1703, various programs and data required for the operation of the electronic device 1700 are also stored. The processing device 1701, the ROM 1702, and the RAM 1703 are connected to each other via a bus 1704. An input / output (I / O) interface 1705 is also connected to the bus 1704.
[0119] Typically, the following devices may be connected to the I / O interface 1705: input devices 1706 including, for example, a touch screen, a touchpad, a keyboard, a mouse, a camera, a microphone, an accelerometer, a gyroscope, etc. (a user may select a target area through the input device 1706); output devices 1707 including, for example, a liquid crystal display (LCD), a speaker, a vibrator, etc. (which may be used to display the generated grid); storage devices 1708 including, for example, a magnetic tape, a hard disk, etc.; and communication devices 1709. The communication device 1709 may allow the electronic device 1700 to communicate with other devices wirelessly or by wire to exchange data. Although Fig.17 The electronic device 1700 is shown with various devices, but it should be understood that it is not required to implement or possess all the devices shown. More or fewer devices may be implemented or possessed instead.
[0120] In particular, according to an embodiment of the present application, the process described above with reference to the flowchart can be implemented as a computer software program. For example, an embodiment of the present application includes a computer program product, which includes a computer program carried on a non-transitory computer-readable medium, and the computer program includes a program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from the network through the communication device 1709, or installed from the storage device 1708, or installed from the ROM 1702. When the computer program is executed by the processing device 1701, the above-mentioned functions defined in the method of the embodiment of the present application are executed.
[0121] Those skilled in the art will appreciate that the various operations, methods, steps, measures, and schemes in the processes discussed in this application may be alternated, altered, combined, or deleted. Further, other steps, measures, and schemes in the various operations, methods, and processes discussed in this application may also be alternated, altered, rearranged, decomposed, combined, or deleted. Further, the steps, measures, and schemes in the prior art that are similar to those disclosed in this application may also be alternated, altered, rearranged, decomposed, combined, or deleted.
[0122] The terms "first" and "second" are used for descriptive purposes only and are not to be understood as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Thus, features defined as "first" and "second" may explicitly or implicitly include one or more of the features. In the description of this application, unless otherwise specified, "multiple" means two or more. "Include" or "comprising" and similar words mean that the elements or objects appearing before the word include the elements or objects listed after the word and their equivalents, without excluding other elements or objects. "Connected" or "connected" and similar words are not limited to physical or mechanical connections, but may include electrical connections, whether direct or indirect.
[0123] It should be understood that, although the steps in the flowchart of the accompanying drawings are displayed in sequence as indicated by the arrows, these steps are not necessarily executed in sequence in the order indicated by the arrows. Unless otherwise specified herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least a part of the steps in the flowchart of the accompanying drawings may include multiple sub-steps or multiple stages, and these sub-steps or stages are not necessarily executed at the same time, but can be executed at different times, and their execution order is not necessarily sequential, but can be executed in turn or alternately with other steps or at least a part of the sub-steps or stages of other steps.
[0124] The above description is only a partial implementation method of the present application. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present application. These improvements and modifications should also be regarded as the scope of protection of the present application.
Claims
1. A method for generating a terrain grid of a wind farm, characterized in that: include: According to the terrain geometry model, determine the two-dimensional calculation area of the grid to be generated; According to the N-ary tree algorithm, the two-dimensional calculation area is grid-divided layer by layer, where N is a positive integer greater than 1; in the process of grid division of each layer, after N grid units of the current layer are divided, when it is determined that the terrain surface curvature change value between a grid unit of the current layer and an adjacent grid unit is greater than a preset threshold, the grid unit of the current layer is continuously grid-divided into the next layer until the terrain surface curvature change value is less than or equal to the preset threshold, thereby obtaining a plane grid; The step of determining the two-dimensional calculation area of the grid to be generated according to the terrain geometric model includes: A two-dimensional projection diagram showing the top-down perspective of the terrain geometric model; When receiving a selection instruction for at least one area in the top-view two-dimensional projection image, determining the at least one area as at least one target area; Determine an area including all the target areas as a core area; The two-dimensional calculation area is obtained by expanding outward based on the core area.
2. The method for generating a wind farm terrain grid according to claim 1, characterized in that: The step of dividing the two-dimensional calculation area into grids layer by layer according to the N-ary tree algorithm includes: According to the N-ary tree algorithm, each of the target areas in the two-dimensional calculation area is grid-divided layer by layer; And, when it is determined that the terrain surface curvature change value between a grid unit of the current layer and an adjacent grid unit is greater than a preset threshold, the grid unit of the current layer is continuously divided into a next layer of grids, including: In each of the target areas, when it is determined that the terrain surface curvature change value between a grid unit of a current layer and an adjacent grid unit is greater than a preset threshold, the grid unit of the current layer is continuously divided into a next layer of grids.
3. The method for generating a terrain grid of a wind farm according to claim 1, characterized in that: After obtaining the plane mesh, the method further includes: Projecting the plane grid onto the three-dimensional surface figure of the terrain geometric model to obtain a three-dimensional surface grid; Determine a sweep direction of each three-dimensional surface grid node and a sweep length along the sweep direction; A three-dimensional space grid is generated according to the sweep direction and the sweep length of each three-dimensional surface grid node.
4. The method for generating a terrain grid of a wind farm according to claim 3, characterized in that: The step of determining the sweep direction of each three-dimensional surface grid node and the sweep length along the sweep direction includes: For each three-dimensional surface grid node, determining a sweep direction of the three-dimensional surface grid node based on a normal direction of a three-dimensional surface grid unit adjacent to the three-dimensional surface grid node; The Fibonacci sequence is used as the number of iterations layer by layer in the grid sweeping to determine the sweeping length along the sweeping direction.
5. The method for generating a terrain grid of a wind farm according to claim 4, characterized in that: The step of determining the sweep direction of the three-dimensional surface grid node based on the normal of the three-dimensional surface grid unit adjacent to the three-dimensional surface grid node comprises: Determining the normal directions of all three-dimensional surface grid cells adjacent to the three-dimensional surface grid node; Based on a preset weighting coefficient, a weighted calculation is performed on the normals of all three-dimensional surface grid cells adjacent to the three-dimensional surface grid node to determine a first sweeping direction of the three-dimensional surface grid node; the weighting coefficient is determined according to the area weight, angle weight, angle sine weight, center distance weight, or conformal mapping of all three-dimensional surface grid cells adjacent to the three-dimensional surface grid node.
6. The method for generating a terrain grid of a wind farm according to claim 5, characterized in that: The step of determining the sweep direction of the three-dimensional surface grid node based on the normal of the three-dimensional surface grid unit adjacent to the three-dimensional surface grid node further includes: Based on the sweeping directions of other three-dimensional surface grid nodes adjacent to the three-dimensional surface grid node, the first sweeping direction is adjusted, and the adjusted first sweeping direction is used as the second sweeping direction of the three-dimensional surface grid node, so as to sweep according to the second sweeping direction.
7. A device for generating a terrain grid of a wind farm, characterized in that: include: A determination module is used to determine a two-dimensional calculation area of a grid to be generated according to a terrain geometric model; A grid division module is used to perform grid division layer by layer on the two-dimensional calculation area according to an N-ary tree algorithm, where N is a positive integer greater than 1; in the process of grid division of each layer, after dividing N grid units of the current layer, when it is determined that the terrain surface curvature change value between a grid unit of the current layer and an adjacent grid unit is greater than a preset threshold, continue to perform grid division of the grid unit of the current layer on the next layer until the terrain surface curvature change value is less than or equal to the preset threshold, thereby obtaining a plane grid; The determination module comprises: A display unit, used for displaying a two-dimensional projection image of a terrain geometric model from a top-down perspective; A first determining unit is configured to determine at least one area as at least one target area when receiving a selection instruction for at least one area in the two-dimensional projection image from a top-down perspective; A second determining unit is used to determine an area including all target areas as a core area; The expansion unit is used to expand outward based on the core area to obtain a two-dimensional computing area.
8. A computer-readable storage medium, characterized in that: The computer-readable storage medium is used to store a computer program. When the computer program is executed on a computer, the method for generating a terrain grid of a wind farm as described in any one of claims 1 to 6 is implemented.
9. A device for generating a terrain grid of a wind farm, characterized in that: including a memory and a processor in communication connection; At least one program is stored in the memory, and is used to implement the method for generating a terrain grid of a wind farm according to any one of claims 1 to 6 when executed by the processor.
Citation Information
Patent Citations
Nonuniform simplifying method for STL model of products
CN101510228A
Numerical simulation grid partitioning method and device of high-voltage transformer
CN107391835A
Method for solving effective characteristic line of non-rotary tool through discrete workpiece curved surface
CN109977999A
Method, apparatus and computer program for designing a corridor
US20170147716A1
