Photovoltaic module layout method, device and equipment and storage medium
Through digital models and global optimization algorithms, the layout of photovoltaic power stations is optimized, and the problem of relying on manual experience in the site selection and layout of photovoltaic power stations is solved, and an automated, accurate and compact layout design is realized, which improves power generation efficiency.
Patent Information
- Application Number
- CN202411093886.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-09
- Publication Date
- 2024-11-22
- Estimated Expiration
- 2044-08-09
AI Technical Summary
The site selection and layout of photovoltaic power stations mainly rely on manual experience judgment, with strong subjectivity and inconsistent judgment standards, resulting in large site selection errors and numerous styles without unified standards.
By obtaining the elevation digital model of the preset area, establishing a triangular network surface, marking the infrastructure terrain surface, defining infrastructure blocks, defining photovoltaic arrays, substations, and energy storage power stations as charged particles, and optimizing cable layout using the global optimization algorithm , The purpose is to minimize the total cable length and repulsion sum, thereby determining the layout position of the photovoltaic module.
It has achieved automation and improved accuracy in the layout of photovoltaic power stations, the minimum cable usage, more compact layout, and the largest power generation per unit area, avoiding the subjectivity and inconsistent standards of manual judgment.
Smart Images

Figure CN119004822A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of electrical digital data processing, and in particular to a layout method, device, equipment and storage medium of a photovoltaic module. Background Art
[0002] A photovoltaic power station refers to a power generation system that utilizes solar energy and adopts special materials such as crystalline silicon panels, inverters and other electronic components. It is a photovoltaic power generation system that is connected to the power grid and transmits electricity to the power grid. A photovoltaic power station with a complete set of functions usually has one or more photovoltaic arrays for receiving solar energy, a transformer for converting the electricity generated by the photovoltaic array, and an energy storage device electrically connected to the transformer. The energy storage device stores the converted electricity that meets the requirements of the site and transmits it to external power-consuming equipment through the municipal power grid.
[0003] At present, the layout of various components and facilities of photovoltaic power stations is usually carried out through subjective judgment by humans for initial pre-construction operations such as site selection and layout, such as comprehensive consideration of geographical location, environmental factors, economic factors and technical factors. Specifically, the judgment criteria for geographical location selection are usually human judgments that areas with rich light resources, flat terrain and convenient transportation are preferred construction areas for photovoltaic power stations; the judgment criteria for environmental factors are usually human judgments of climate conditions, pollution levels, and land properties; the judgment criteria for economic factors are usually human judgments of cost-benefit analysis, market demand, and policy support; the judgment criteria for technical factors are usually human judgments of technical feasibility, equipment compatibility, and ease of operation and maintenance.
[0004] From the above, we can see that the site selection and layout of photovoltaic power stations are basically based on manual experience judgment, which is highly subjective and has inconsistent judgment standards. As a result, the site selection and layout of photovoltaic power stations have large subjective errors, various forms and styles, and no unified standards. Summary of the invention
[0005] The main purpose of the present application is to provide a layout method, device, equipment and storage medium for photovoltaic components to solve the problem that the site selection and layout of photovoltaic power stations in the prior art are based on manual experience judgment, which is highly subjective and has inconsistent judgment standards.
[0006] To achieve the above objectives, this application provides the following technical solutions:
[0007] A method for laying out a photovoltaic assembly, the photovoltaic assembly comprising a plurality of photovoltaic arrays erected in a preset area, at least one substation electrically connected to each photovoltaic array through a plurality of cables, and at least one energy storage power station electrically connected to the substation through at least one cable, the method comprising:
[0008] Step S1, obtaining a digital elevation model of the preset area, and establishing a triangulated surface of the preset area through a preset strategy;
[0009] Step S2, respectively obtaining the angle between each triangle in the triangulated surface and the horizontal plane, and marking the triangles whose angles do not exceed a preset angle threshold as constructible terrain surfaces;
[0010] Step S3, obtaining the boundary of the constructible terrain surface by a sliding window algorithm, and defining the constructible terrain surface with discontinuous boundaries as a constructible block;
[0011] Step S4, respectively defining each photovoltaic array as a first charged particle with a first charge, defining each substation as a second charged particle with a second charge, and defining each energy storage power station as a third charged particle with a third charge, and all first charged particles, all second charged particles, and all third charged particles have the same charge polarity;
[0012] Step S5, outputting all first charged particles, all second charged particles, and all third charged particles to the constructible block;
[0013] Step S6, initializing the positions of all first charged particles, all second charged particles, and all third charged particles, and obtaining the sum of repulsive forces of all first charged particles, all second charged particles, and all third charged particles;
[0014] Step S7, iteratively updating the real-time positions of all first charged particles, all second charged particles, and all third charged particles through a global optimization algorithm to obtain the minimum value of the total length of all cables and minimize the sum of the repulsive forces;
[0015] Step S8, obtaining all real-time positions when the sum of the repulsive forces reaches the minimum, and defining them as the layout positions of all photovoltaic arrays, all substations, and all energy storage power stations.
[0016] As a further improvement of the present application, step S3, obtaining the boundary of the constructible terrain surface by a sliding window algorithm, and defining the constructible terrain surface with discontinuous boundaries as a constructible block, includes:
[0017] Step S31, establishing a grid set in the constructible terrain surface, and assigning a value of 0 to each grid in the grid set, wherein the size of each grid is smaller than or equal to the size of each triangle;
[0018] Step S32, determining whether the triangle exists in each mesh, and assigning a value of 1 to the mesh where the triangle exists;
[0019] Step S33, defining the current grid and adjacent grids as a three-dimensional window, and obtaining the assigned values of all grids in each three-dimensional window respectively;
[0020] Step S34, determining whether there is a grid in each three-dimensional window whose assigned value is 0, if there is a grid in the current three-dimensional window whose assigned value is 0, executing step S35;
[0021] Step S35, extracting the three-dimensional windows with assigned values of 0 and marking them as edge windows;
[0022] Step S36, extracting triangles in each edge window and marking them as edge triangles;
[0023] Step S37, sequentially connecting adjacent edge triangles to form the boundary;
[0024] Step S38, determining whether the current boundary is closed, if the current boundary is closed, executing step S39;
[0025] Step S39, determining whether the current boundary has completely enclosed a constructible block.
[0026] As a further improvement of the present application, in step S33, the current grid and the adjacent grids are defined as a three-dimensional window, and the assigned values of all grids in each three-dimensional window are obtained respectively, including:
[0027] Step S331, defining the current grid and twenty-six grids adjacent to the current grid as a 3×3×3 stereoscopic window;
[0028] Step S332, determining whether there is a grid with an assigned value of 0 in each 3×3×3 stereoscopic window, if there is no grid with an assigned value of 0 in the current 3×3×3 stereoscopic window, executing step S333;
[0029] Step S333, deleting the 3×3×3 stereoscopic window with no grid and the assigned value of 0.
[0030] As a further improvement of the present application, step S37, sequentially connecting adjacent edge triangles to form the boundary, includes:
[0031] Step S371, obtaining the row and column values of each triangle in the current edge window and establishing a to-be-connected point matrix for each triangle according to the Kruskal algorithm;
[0032] Step S372, obtaining the minimum spanning tree of each to-be-connected point array respectively according to the Kruskal algorithm;
[0033] Step S373, extracting all triangles in the minimum spanning tree and using them as the edge triangles.
[0034] As a further improvement of the present application, step S7, iteratively updating the real-time positions of all first charged particles, all second charged particles, and all third charged particles through a global optimization algorithm to obtain the minimum value of the total length of all cables, while minimizing the sum of the repulsive forces, includes:
[0035] Step S71, according to formula (1), formula (2), and formula (3), at least two first random solutions are assigned to each first charged particle, at least two second random solutions are assigned to each second charged particle, and at least two third random solutions are assigned to each third charged particle, and the results of all the first random solutions, all the second random solutions, and all the third random solutions are defined as the total length of all the cables reaching the minimum value, and at the same time, all the first charged particles, all the second charged particles, and all the third charged particles are constrained based on Coulomb's law;
[0036]
[0037] Among them, X a is the set of all first random solutions for all first charged particles, x a1 ,x a2 ,...,x an are all the first random solutions of the ath first charged particle, n is the number of all the first random solutions of the current first charged particle, m is the number of all the first charged particles, V a is the set of velocities of all first random solutions, v a1 ,v a2 ,...,v an are all the velocities of all the first random solutions of the a-th first charged particle, is the set of all Coulomb forces for all first charged particles, are all the Coulomb forces on the ath first charged particle. The number of Coulomb forces on the current first charged particle is equal to the number of all the first random solutions of the current first charged particle. k is the Coulomb constant, q an-1 is the charge of the n-1th random solution of the ath first charged particle, q an The charge of the nth random solution of the ath first charged particle, r a,n-1,n is the Euclidean distance between the n-1th first random solution and the nth first random solution of the ath first charged particle, is the unit vector from the n-1th first random solution to the nth first random solution of the ath first charged particle;
[0038]
[0039] Among them, X bis the set of all second random solutions for all second charged particles, x b1 ,x b2 ,...,x bp is all the second random solutions of the bth second charged particle, p is the number of all the second random solutions of the current second charged particle, o is the number of all second charged particles, V b is the set of velocities of all second random solutions, v b1 ,v b2 ,...,v bp are all the velocities of all the second random solutions of the b-th second charged particle, is the set of all Coulomb forces for all second charged particles, is all the Coulomb forces on the bth second charged particle. The number of Coulomb forces on the current second charged particle is equal to the number of all the second random solutions of the current second charged particle. bp-1 is the charge of the p-1th second random solution of the bth second charged particle, q bp The charge of the pth random solution of the bth second charged particle, r b,p-1,p is the Euclidean distance between the p-1th second random solution and the pth second random solution of the bth second charged particle, is the unit vector from the p-1th second random solution to the pth second random solution of the bth second charged particle;
[0040]
[0041] Among them, X c is the set of all third random solutions for all third charged particles, x c1 ,x c2 ,...,x ct are all the third random solutions of the cth third charged particle, t is the number of all the third random solutions of the current third charged particle, s is the number of all third charged particles, V c is the set of velocities of all third random solutions, v c1 ,v c2 ,...,v ct are all the velocities of all third random solutions of the cth third charged particle, is the set of all Coulomb forces for all third charged particles, is all the Coulomb forces on the cth third charged particle. The number of Coulomb forces on the current third charged particle is equal to the number of all third random solutions of the current third charged particle. ct-1 is the charge of the t-1th third random solution of the cth third charged particle, q ctThe charge of the tth third random solution of the cth third charged particle, r c,t-1,t is the Euclidean distance between the t-1th third random solution and the tth third random solution of the cth third charged particle, is the unit vector from the t-1th third random solution to the tth third random solution of the cth third charged particle;
[0042] Step S72, respectively updating the position and speed of each first random solution, each second random solution, and each third random solution at a preset time interval according to formula (4):
[0043]
[0044] Among them, x ijd is the jth random solution of the ith charged particle, v ijd is the velocity of the jth random solution of the ith charged particle at the dth step, ω·v ijd-1 is the velocity inertia of the jth random solution of the ith charged particle at the d-1th step, ω is the inertia coefficient of the velocity inertia, C1·random()·(u best,ij -x ij ) is the self-perception representation of the jth random solution of the ith charged particle, C2·random()·(g best,ij -x ij ) is the social cognitive representation of the jth random solution of the ith charged particle; C1 and C2 are both learning factors, random() is a random number in the range of [0,1], u best,ij is the individual optimal solution obtained by the jth random solution of the ith charged particle, g best,ij is the global optimal solution obtained by the jth random solution of the i-th charged particle;
[0045] Step S73, iterate a preset number of times according to formula (4) to update each u best,ij And each g best,ij ;
[0046] Step S74, determine each u best,ij Compared with the first difference of the previous iteration, whether it is less than or equal to the first preset adaptation threshold, if so, executing step S75;
[0047] Step S75, determine each g best,ij Compared with the second difference of the previous iteration, whether it is less than or equal to the second preset adaptation threshold, if so, executing step S76;
[0048] Step S76, determining that the total length of all cables reaches the minimum value, and stopping the iteration of formula (4);
[0049] Step S77, obtaining the final positions of all first charged particles, all second charged particles, and all third charged particles after the iteration is completed.
[0050] As a further improvement of the present application, in step S73, the formula (4) is iterated a preset number of times to update each u best,ij And each g best,ij ,include:
[0051] Step S731, optimizing the inertia coefficient ω once in each iteration according to formula (5):
[0052]
[0053] Among them, ω ijd is the inertia coefficient of the jth random solution of the ith charged particle after optimization in the dth step, ω ini is the initial inertia coefficient, ω ijd-1 is the inertia coefficient of the jth random solution of the ith charged particle at the d-1th step, G k is the current iteration number, G max is the total number of iterations after the iteration is completed.
[0054] As a further improvement of the present application, step S8, obtaining all real-time positions when the sum of the repulsive forces reaches the minimum, and defining them as the layout positions of all photovoltaic arrays, all substations, and all energy storage power stations, then includes:
[0055] Step S10, obtaining the triangulated surface and performing color fading processing on the area that is not the constructible block to obtain a highlighted color triangulated surface;
[0056] Step S20, outputting the layout positions of all photovoltaic arrays, all substations, and all energy storage power stations on the emphasized color triangulated surface to form a visual layout model;
[0057] Step S30: outputting the visualization layout model to an external visualization terminal.
[0058] To achieve the above objectives, this application also provides the following technical solutions:
[0059] A photovoltaic assembly layout device, the layout device is applied to the above-mentioned layout method, the layout device comprises:
[0060] A triangulated surface building module, used to obtain the elevation digital model of the preset area and build the triangulated surface of the preset area through a preset strategy;
[0061] A construction-capable terrain surface marking module is used to obtain the angle between each triangle in the triangulated surface and the horizontal plane, and mark the triangles whose angles do not exceed a preset angle threshold as construction-capable terrain surfaces;
[0062] A construction block definition module is used to obtain the boundary of the construction terrain surface through a sliding window algorithm, and define the construction terrain surface with discontinuous boundaries as a construction block;
[0063] A charged particle definition module, used to define each photovoltaic array as a first charged particle with a first charge, each substation as a second charged particle with a second charge, and each energy storage power station as a third charged particle with a third charge, and all the first charged particles, all the second charged particles, and all the third charged particles have the same charge polarity;
[0064] A charged particle output module, used for outputting all first charged particles, all second charged particles, and all third charged particles to the constructible block;
[0065] A repulsive force sum acquisition module is used to initialize the positions of all first charged particles, all second charged particles, and all third charged particles, and to acquire the repulsive force sum of all first charged particles, all second charged particles, and all third charged particles;
[0066] A real-time position optimization module, used for iteratively updating the real-time positions of all first charged particles, all second charged particles, and all third charged particles through a global optimization algorithm to obtain the minimum value of the total length of all cables and minimize the sum of the repulsive forces;
[0067] The layout position definition module is used to obtain all real-time positions when the sum of the repulsive forces reaches the minimum, and define them as the layout positions of all photovoltaic arrays, all substations, and all energy storage power stations.
[0068] To achieve the above objectives, this application also provides the following technical solutions:
[0069] An electronic device comprises a processor and a memory coupled to the processor, wherein the memory stores program instructions executable by the processor; when the processor executes the program instructions stored in the memory, the above-mentioned layout method is implemented.
[0070] To achieve the above objectives, this application also provides the following technical solutions:
[0071] A storage medium stores program instructions, and when the program instructions are executed by a processor, the above-mentioned layout method can be implemented.
[0072] The present application obtains a digital elevation model of a preset area, and establishes a triangulated surface of the preset area through a preset strategy; obtains the angle between each triangle in the triangulated surface and the horizontal plane, and marks the triangles whose angles do not exceed a preset angle threshold as constructible terrain surfaces; obtains the boundary of the constructible terrain surface through a sliding window algorithm, and defines the constructible terrain surface with discontinuous boundaries as a constructible block; defines each photovoltaic array as a first charged particle with a first charge, defines each substation as a second charged particle with a second charge, and defines each energy storage power station as a third charged particle with a third charge, and all first charged particles, all second charged particles, and all third charged particles are respectively defined as first charged particles. The charged particles have the same charge polarity; all first charged particles, all second charged particles, and all third charged particles are output to the constructible block; the positions of all first charged particles, all second charged particles, and all third charged particles are initialized, and the sum of the repulsive forces of all first charged particles, all second charged particles, and all third charged particles is obtained; the real-time positions of all first charged particles, all second charged particles, and all third charged particles are iteratively updated through a global optimization algorithm to obtain the minimum value of the total length of all cables and minimize the sum of the repulsive forces; all real-time positions when the sum of the repulsive forces reaches the minimum are obtained, and defined as the layout positions of all photovoltaic arrays, all substations, and all energy storage power stations. This application uses the total length of the cables used in the photovoltaic power station as a layout indicator, and defines all photovoltaic modules as charged particles with the same polarity. The distance between each photovoltaic module can be adjusted by adjusting the charge of each charged particle, and the charge is proportional to the distance. The staff can adjust the charge of each charged particle in real time according to external indicators such as power generation and construction budget to achieve the spacing adjustment of each photovoltaic module. Under the mutual repulsion constraint of the aforementioned charged particles, the real-time position of each charged particle is iterated through a global optimization algorithm, and the total length of the used cables is obtained once in each iteration until the iteration is to After the total length of the cables used reaches the minimum value, it will no longer change. The real-time position of each charged particle obtained at this time is the layout position of each photovoltaic component. This application uses the most intuitive and important electrical connection cable as the layout indicator, and uses the mutual repulsion of equivalent charged particles as the spacing constraint to obtain the layout position of each photovoltaic component with the purpose of using the shortest cable. Less cable usage represents a neater and more compact layout, which maximizes the power generation per unit area of the photovoltaic power station. Compared with the traditional manual judgment method, this application is automatically calculated by software program throughout the process, and achieves a layout effect that cannot be achieved manually. BRIEF DESCRIPTION OF THE DRAWINGS
[0073] Figure 1 A schematic diagram of the steps of an embodiment of a photovoltaic assembly layout method of the present application;
[0074] Figure 2This is a schematic structural diagram of an embodiment of a photovoltaic assembly layout device of the present application;
[0075] Figure 3 This is a schematic diagram of the structure of an embodiment of the electronic device of the present application;
[0076] Figure 4 This is a schematic diagram of the structure of an embodiment of the storage medium of the present application. DETAILED DESCRIPTION
[0077] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.
[0078] The terms "first", "second" and "third" in this application are only used for descriptive purposes, and cannot be understood as indicating or implying relative importance or implicitly indicating the number of indicated technical features. Thus, the features defined as "first", "second" and "third" can explicitly or implicitly include at least one of the features. In the description of this application, the meaning of "multiple" is at least two, such as two, three, etc., unless otherwise clearly and specifically defined. All directional indications in the embodiments of the present application (such as up, down, left, right, front, back...) are only used to explain the relative position relationship, movement, etc. between the components under a certain specific posture (as shown in the accompanying drawings). If the specific posture changes, the directional indication also changes accordingly. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions. 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 optionally also includes steps or units that are not listed, or optionally also includes other steps or units inherent to these processes, methods, products or devices.
[0079] Reference to "embodiments" herein means that a particular feature, structure, or characteristic described in conjunction with the embodiments may be included in at least one embodiment of the present application. The appearance of the phrase in various locations in the specification does not necessarily refer to the same embodiment, nor is it an independent or alternative embodiment that is mutually exclusive with other embodiments. It is explicitly and implicitly understood by those skilled in the art that the embodiments described herein may be combined with other embodiments.
[0080] like Figure 1As shown, this embodiment provides an embodiment of a layout method of photovoltaic components. In this embodiment, the photovoltaic components include a plurality of photovoltaic arrays erected in a preset area, at least one substation electrically connected to each photovoltaic array through a plurality of cables, and at least one energy storage power station electrically connected to the substation through at least one cable.
[0081] Preferably, the design of this embodiment is intended to avoid uneven land such as slopes and mountains while automatically laying out the layout, thereby reducing or eliminating the amount of excavation and filling engineering, and further reducing the amount of infrastructure engineering.
[0082] Preferably, in order to facilitate the subsequent equivalent accuracy of charged particles, the styles of photovoltaic arrays, substations, and energy storage power stations are all axially symmetrical figures when viewed from a top-down perspective, and have two mutually perpendicular axes of symmetry, such as polygons with an even number of sides (rectangles, hexagons, octagons, etc.), circles, etc., to ensure layout accuracy. At the same time, each component can rotate about its own center, such as the unified orientation of the photovoltaic array.
[0083] Specifically, the layout method includes the following steps:
[0084] Step S1, obtaining an elevation digital model of a preset area, and establishing a triangulated surface of the preset area through a preset strategy.
[0085] Preferably, the DEM (digital elevation model) can be directly obtained from public channels (national high-precision 5m-12m-30m DEM terrain data download).
[0086] Preferably, after the DEM is loaded into Global Mapper and before the contour lines are generated, the DEM generally needs to be clipped to extract the DEM of the preset area.
[0087] Among them, the preset area data can be output using LSV (LocaSpaceViewer, a three-dimensional digital earth software that integrates images and three-dimensional terrain online services such as Google Earth and Tiandi Map. The underlying development technology uses C++ and OpenGL. The software can quickly browse, measure, analyze and annotate three-dimensional geographic information data and oblique photography real-life data), and then saved as KML (KML file is a landmark file created by Google to record the time, longitude, latitude, altitude and other geographic information data of a certain location or continuous locations) and imported into Global Mapper. The preset area can also be directly output in Global Mapper.
[0088] Preferably, after the preset area is created, the DEM layer can be polygonally clipped through the layer control center of Global Mapper. After the polygon clipping is completed, the contour line generation function of Global Mapper can be directly used (the line distance needs to be set). Finally, Gaussian projection can be performed on the preset area by loading the CGCS2000 standard in Global Mapper and then configuring the reference point.
[0089] Preferably, the preset strategy can directly convert the digital elevation model into a triangulated surface through the surface drawing function of Civil 3D.
[0090] Preferably, most of the existing drawing software have a surface control point function, such as Civil 3D, AutoCAD, Rhino, NURBS, etc. The surface control point file is generated based on the conventional generation method of the aforementioned drawing software, which will not be repeated in this embodiment.
[0091] Specifically, in Civil 3D, terrain surfaces can be divided into four types, namely triangulated surfaces, triangulated volume surfaces, grid surfaces, and grid volume surfaces. Among them, triangulated surfaces are composed of irregular triangles. When Civil 3D creates triangulated surfaces from three-dimensional space points, these three-dimensional space points are Delaunay triangulated. Through Delaunay triangulation, there are no points in the circle determined by the vertices of any triangle. In order to create triangulated lines, Civil 3D will connect batches of the closest surface points, that is, the triangulated surface connects the points in the file according to the closest distance to each other, and all the points are connected into many triangles, thus forming a triangulated surface.
[0092] Preferably, the Delaunay triangulation has the following definition:
[0093] Definition 1: Assume that V is a finite point set in the two-dimensional real number field, edge e is a closed line segment consisting of points in the point set as endpoints, and E is the set of e. Then a triangulation T = (V, E) of the point set V is a planar graph G that satisfies the following conditions:
[0094] ①Except for the endpoints, the edges in a planar graph do not contain any points in the point set.
[0095] ②There are no intersecting edges.
[0096] ③All faces in the plane graph are triangular faces, and the union of all triangular faces is the convex hull of the point set V.
[0097] Preferably, the Delaunay edge has the following definition:
[0098] ①Suppose there is an edge e in E (with two endpoints a and b). If e satisfies the following conditions, it is called a Delaunay edge.
[0099] ② There exists a circle on the Delaunay edge passing through points ab, and the circle does not contain any point in the point set V. This property is also called the empty circle property.
[0100] Preferably, the Delaunay triangulation also has the following definition:
[0101] ①If a triangulation T of a point set V contains only Delaunay edges, then the triangulation is called a Delaunay triangulation.
[0102] Step S2, respectively obtaining the angle between each triangle in the triangulated surface and the horizontal plane, and marking the triangles whose angles do not exceed a preset angle threshold as constructible terrain surfaces.
[0103] Preferably, the preset angle threshold can be set to 10°, that is, the angle between the triangle and the horizontal plane does not exceed 10°.
[0104] Step S3, obtaining the boundary of the constructible terrain surface by using a sliding window algorithm, and defining the constructible terrain surface with discontinuous boundaries as a constructible block.
[0105] For example, if the preset area has two mountains, a ravine between the two mountains, and a flat land around the two mountains, five buildable blocks are obtained after obtaining the boundaries through the sliding window algorithm, and the triangle angles of the five buildable blocks do not exceed 10°.
[0106] Step S4, respectively defining each photovoltaic array as a first charged particle with a first charge, defining each substation as a second charged particle with a second charge, and defining each energy storage power station as a third charged particle with a third charge, and all first charged particles, all second charged particles, and all third charged particles have the same charge polarity.
[0107] Preferably, the first charge, the second charge, and the third charge can increase successively so that the mutual repulsion among the three increases successively, that is, the spacing between all photovoltaic arrays is small, the spacing between all substations and all photovoltaic arrays is small, the spacing between all substations is moderate, the spacing between all energy storage power stations is large, and the spacing between all energy storage power stations and all substations and all photovoltaic arrays is large.
[0108] Step S5: output all first charged particles, all second charged particles, and all third charged particles to a constructible block.
[0109] Preferably, for non-infrastructure blocks whose angles exceed a preset angle threshold, an ignoring process or a fading process described below is performed, so that all first charged particles, all second charged particles, and all third charged particles do not appear on the non-infrastructure blocks.
[0110] Step S6, initializing the positions of all first charged particles, all second charged particles, and all third charged particles, and obtaining the sum of the repulsive forces of all first charged particles, all second charged particles, and all third charged particles.
[0111] Preferably, a random function may be used to initialize the positions of all first charged particles, all second charged particles, and all third charged particles.
[0112] Step S7, iteratively updating the real-time positions of all first charged particles, all second charged particles, and all third charged particles through a global optimization algorithm to obtain the minimum value of the total length of all cables and minimize the total repulsive force.
[0113] Step S8, obtaining all real-time positions when the sum of repulsive forces reaches the minimum, and defining them as the layout positions of all photovoltaic arrays, all substations, and all energy storage power stations.
[0114] In layman's terms, all the first charged particles, all the second charged particles, and all the third charged particles are balloons of increasing sizes, and the cables are ropes that tie the balloons. The global optimization algorithm is used to find the best position for each balloon while ensuring that the total length of the rope is the shortest.
[0115] Furthermore, in step S3, the boundary of the constructible terrain surface is obtained by a sliding window algorithm, and the constructible terrain surface with discontinuous boundaries is defined as a constructible block, including:
[0116] Step S31, establishing a grid set in the constructible terrain surface, and assigning a value of 0 to each grid in the grid set, wherein the size of each grid is smaller than or equal to the size of each triangle.
[0117] Preferably, with the support of computer computing power, the size of the grid can be set to be much smaller than the size of the triangle, for example, one triangle needs to be covered by at least 10 grids.
[0118] Step S32, determining whether there is a triangle in each mesh, and assigning a value of 1 to the meshes where there is a triangle.
[0119] Step S33, defining the current grid and adjacent grids as a three-dimensional window, and obtaining the assigned values of all grids in each three-dimensional window respectively.
[0120] Step S34, determining whether there is a grid in each three-dimensional window whose assigned value is 0, if there is a grid in the current three-dimensional window whose assigned value is 0, executing step S35.
[0121] Step S35 , extracting the three-dimensional windows with assigned values of 0 and marking them as edge windows.
[0122] It should be noted that the value assigned to the grid at the center of the edge window must be 1 to ensure the accuracy of subsequent estimation.
[0123] Step S36, extracting triangles in each edge window and marking them as edge triangles.
[0124] Step S37, sequentially connect adjacent edge triangles to form a boundary.
[0125] Step S38, determine whether the current boundary is closed, if the current boundary is closed, execute step S39.
[0126] Step S39, determining whether the current boundary has completely enclosed a constructible block.
[0127] Furthermore, in step S33, the current grid and the adjacent grids are defined as a three-dimensional window, and the assigned values of all grids in each three-dimensional window are obtained respectively, including:
[0128] Step S331, defining the current grid and twenty-six grids adjacent to the current grid as a 3×3×3 stereoscopic window.
[0129] Step S332, determining whether there is a grid with an assigned value of 0 in each 3×3×3 stereoscopic window, if there is no grid with an assigned value of 0 in the current 3×3×3 stereoscopic window, executing step S333.
[0130] Step S333, deleting the 3×3×3 stereoscopic window with no grid and the assigned value of 0.
[0131] Furthermore, step S37, sequentially connecting adjacent edge triangles to form a boundary, includes:
[0132] Step S371, obtaining the row and column values of each triangle in the current edge window and establishing a to-be-connected point matrix for each triangle according to the Kruskal algorithm.
[0133] Step S372, obtaining the minimum spanning tree of each to-be-connected lattice respectively according to the Kruskal algorithm.
[0134] Step S373, extract all triangles in the minimum spanning tree and use them as edge triangles.
[0135] Further, step S7, iteratively updating the real-time positions of all first charged particles, all second charged particles, and all third charged particles through a global optimization algorithm to obtain the minimum value of the total length of all cables and minimize the sum of repulsive forces, including:
[0136] Step S71, according to formula (1), formula (2), and formula (3), at least two first random solutions are assigned to each first charged particle, at least two second random solutions are assigned to each second charged particle, and at least two third random solutions are assigned to each third charged particle. The results of all first random solutions, all second random solutions, and all third random solutions are defined as the total length of all cables reaching the minimum value. At the same time, all first charged particles, all second charged particles, and all third charged particles are constrained based on Coulomb's law.
[0137]
[0138] Among them, X a is the set of all first random solutions for all first charged particles, x a1 ,x a2 ,...,x an are all the first random solutions of the ath first charged particle, n is the number of all the first random solutions of the current first charged particle, m is the number of all the first charged particles, V a is the set of velocities of all first random solutions, v a1 ,v a2 ,...,v an are all the velocities of all the first random solutions of the a-th first charged particle, is the set of all Coulomb forces for all first charged particles, are all the Coulomb forces on the ath first charged particle. The number of Coulomb forces on the current first charged particle is equal to the number of all the first random solutions of the current first charged particle. k is the Coulomb constant, q an-1 is the charge of the n-1th random solution of the ath first charged particle, q an The charge of the nth random solution of the ath first charged particle, r a,n-1,n is the Euclidean distance between the n-1th first random solution and the nth first random solution of the ath first charged particle, It is the unit vector from the n-1th first random solution to the nth first random solution of the ath first charged particle.
[0139]
[0140] Among them, X b is the set of all second random solutions for all second charged particles, x b1 ,xb2 ,...,x bp is all the second random solutions of the bth second charged particle, p is the number of all the second random solutions of the current second charged particle, o is the number of all second charged particles, V b is the set of velocities of all second random solutions, v b1 ,v b2 ,...,v bp are all the velocities of all the second random solutions of the b-th second charged particle, is the set of all Coulomb forces for all second charged particles, is all the Coulomb forces on the bth second charged particle. The number of Coulomb forces on the current second charged particle is equal to the number of all the second random solutions of the current second charged particle. bp-1 is the charge of the p-1th second random solution of the bth second charged particle, q bp The charge of the pth random solution of the bth second charged particle, r b,p-1,p is the Euclidean distance between the p-1th second random solution and the pth second random solution of the bth second charged particle, It is the unit vector from the p-1th second random solution to the pth second random solution of the bth second charged particle.
[0141]
[0142] Among them, X c is the set of all third random solutions for all third charged particles, x c1 ,x c2 ,...,x ct are all the third random solutions of the cth third charged particle, t is the number of all the third random solutions of the current third charged particle, s is the number of all third charged particles, V c is the set of velocities of all third random solutions, v c1 ,v c2 ,...,v ct are all the velocities of all third random solutions of the cth third charged particle, is the set of all Coulomb forces for all third charged particles, is all the Coulomb forces on the cth third charged particle. The number of Coulomb forces on the current third charged particle is equal to the number of all third random solutions of the current third charged particle. ct-1 is the charge of the t-1th third random solution of the cth third charged particle, q ct The charge of the tth third random solution of the cth third charged particle, r c,t-1,tis the Euclidean distance between the t-1th third random solution and the tth third random solution of the cth third charged particle, is the unit vector from the t-1th third random solution to the tth third random solution of the cth third charged particle.
[0143] Step S72, respectively updating the position and speed of each first random solution, each second random solution, and each third random solution at a preset time interval according to formula (4):
[0144]
[0145] Among them, x ijd is the jth random solution of the ith charged particle, v ijd is the velocity of the jth random solution of the ith charged particle at the dth step, ω·v ijd-1 is the velocity inertia of the jth random solution of the ith charged particle at the d-1th step, ω is the inertia coefficient of velocity inertia, C1·random()·(u best,ij -x ij ) is the self-perception representation of the jth random solution of the ith charged particle, C2·random()·(g best,ij -x ij ) is the social cognitive representation of the jth random solution of the ith charged particle; C1 and C2 are both learning factors, random() is a random number in the range of [0,1], u best,ij is the individual optimal solution obtained by the jth random solution of the ith charged particle, g best,ij is the global optimal solution obtained by the j-th random solution of the i-th charged particle.
[0146] Preferably, the value range of C1 is [0, 0.5], preferably 0.4; the value range of C2 is [0.5, 1], preferably 0.8.
[0147] It should be noted that a, b, and c in the above formulas (1), (2), and (3) may be equal or unequal. If they are equal, the same letters may be used. This embodiment uses different letters to prevent confusion between the three facilities. The purpose of using i to combine letters a, b, and c in formula (4) is to illustrate that formulas (1), (2), and (3) are definitions of three types of charged particles, respectively. The three types of charged particles need to be substituted into formula (4) for global optimization, and the same applies to n, p, and t.
[0148] Step S73, iterate a preset number of times according to formula (4) to update each u best,ij And each g best,ij .
[0149] Step S74, determine each ubest,ij Compared with the first difference of the previous iteration, whether it is less than or equal to the first preset adaptation threshold, if each u best,ij If the first difference compared to the previous iteration is less than or equal to the first preset adaptation threshold, step S75 is executed.
[0150] Step S75, determine each g best,ij Compared with the second difference of the previous iteration, whether it is less than or equal to the second preset adaptation threshold, if each g best,ij If the second difference compared to the previous iteration is less than or equal to the second preset adaptation threshold, step S76 is executed.
[0151] Step S76, determining that the total length of all cables has reached the minimum value, and stopping the iteration of equation (4).
[0152] Step S77, obtaining the final positions of all first charged particles, all second charged particles, and all third charged particles after the iteration is completed.
[0153] Preferably, in the iterative process, each time the best fitness is calculated, the change between the fitness and the best fitness in the previous iteration is calculated (taking the absolute value); the relative size of this change and the "function change tolerance" is determined. If the former is smaller, the counter is incremented by 1; otherwise, the counter is cleared to 0; this process is repeated continuously. If the maximum number of iterations has not been exceeded at this time, and the value of the counter exceeds the maximum count value, the iteration loop is jumped out and the search ends; if the maximum number of iterations has been reached at this time, the loop is directly jumped out and the search ends.
[0154] Further, in step S73, according to formula (4), iterate a preset number of times to update each u best,ij And each g best,ij ,include:
[0155] Step S731, in each iteration, the inertia coefficient ω is optimized once according to formula (5):
[0156]
[0157] Among them, ω ijd is the inertia coefficient of the jth random solution of the ith charged particle after optimization in the dth step, ω ini is the initial inertia coefficient, ω ijd-1 is the inertia coefficient of the jth random solution of the ith charged particle at the d-1th step, G k is the current iteration number, G max is the total number of iterations after the iteration is completed.
[0158] Further, in step S8, all real-time positions when the sum of repulsive forces reaches the minimum are obtained and defined as the layout positions of all photovoltaic arrays, all substations, and all energy storage power stations. After that, it includes:
[0159] Step S10, obtaining a triangulated mesh surface and performing color fading processing on the area that is not a constructible block to obtain a highlighted color triangulated mesh surface.
[0160] Step S20: output the layout positions of all photovoltaic arrays, all substations, and all energy storage power stations on the emphasized color triangulated surface to form a visual layout model.
[0161] Step S30: outputting the visualization layout model to an external visualization terminal.
[0162] This embodiment obtains the digital model of the elevation of the preset area, and establishes the triangulated surface of the preset area through a preset strategy; obtains the angle between each triangle in the triangulated surface and the horizontal plane, and marks the triangles whose angles do not exceed the preset angle threshold as the terrain surface that can be constructed; obtains the boundary of the terrain surface that can be constructed through a sliding window algorithm, and defines the terrain surface that can be constructed with discontinuous boundaries as a block that can be constructed; defines each photovoltaic array as a first charged particle with a first charge, defines each substation as a second charged particle with a second charge, and defines each energy storage power station as a third charged particle with a third charge, and all the first charged particles, all the second charged particles, and all the third charged particles are respectively defined as the first charged particles, the second charged particles, and the third charged particles. The charge polarity of the three charged particles is the same; all first charged particles, all second charged particles, and all third charged particles are output to the infrastructure block; the positions of all first charged particles, all second charged particles, and all third charged particles are initialized, and the sum of the repulsive forces of all first charged particles, all second charged particles, and all third charged particles are obtained; the real-time positions of all first charged particles, all second charged particles, and all third charged particles are iteratively updated through a global optimization algorithm to obtain the minimum value of the total length of all cables and minimize the sum of the repulsive forces; all real-time positions when the sum of the repulsive forces reaches the minimum are obtained, and defined as the layout positions of all photovoltaic arrays, all substations, and all energy storage power stations. In this embodiment, the total length of the cables used in the photovoltaic power station is used as a layout indicator, and all photovoltaic modules are defined as charged particles with the same polarity. The distance between each photovoltaic module can be adjusted by adjusting the charge of each charged particle, and the charge is proportional to the distance. The staff can adjust the charge of each charged particle in real time according to external indicators such as power generation and construction budget to achieve the spacing adjustment of each photovoltaic module. Under the mutual repulsion constraint of the charged particles mentioned above, the real-time position of each charged particle is iterated through the global optimization algorithm, and the total length of the cables used is obtained once in each iteration until the iteration reaches the desired value. After the total length of the cables reaches the minimum value, it will no longer change. At this time, the real-time positions of the charged particles obtained are the layout positions of the photovoltaic modules. This embodiment uses the most intuitive and important electrical connection cables as layout indicators, and uses the mutual repulsion of equivalent charged particles as spacing constraints to obtain the layout positions of the photovoltaic modules with the shortest cables. Less cable usage represents a neater and more compact layout, which maximizes the power generation per unit area of the photovoltaic power station. Compared with the traditional manual judgment method, this embodiment is automatically calculated by the software program throughout the process, and achieves a layout effect that cannot be achieved manually.
[0163] like Figure 2 As shown, this embodiment provides an embodiment of a layout device for photovoltaic components. In this embodiment, the layout device is applied to the layout method in the above embodiment.
[0164] Specifically, the layout device includes a triangulated surface establishment module 1, a buildable terrain surface marking module 2, a buildable block definition module 3, a charged particle definition module 4, a charged particle output module 5, a repulsive force sum acquisition module 6, a real-time position optimization module 7, and a layout position definition module 8, which are electrically connected in sequence.
[0165] Among them, the triangulated surface establishment module 1 is used to obtain the elevation digital model of the preset area, and establish the triangulated surface of the preset area through a preset strategy; the constructible terrain surface marking module 2 is used to respectively obtain the angle between each triangle in the triangulated surface and the horizontal plane, and mark the triangle whose angle does not exceed the preset angle threshold as the constructible terrain surface; the constructible block definition module 3 is used to obtain the boundary of the constructible terrain surface through a sliding window algorithm, and define the constructible terrain surface with discontinuous boundary as the constructible block; the charged particle definition module 4 is used to respectively define each photovoltaic array as a first charged particle with a first charge, define each substation as a second charged particle with a second charge, and define each energy storage power station as a third charged particle with a third charge, and all the first charged particles, all the second charged particles, and all the third charged particles are defined as the first charged particles. The charge polarity of the three charged particles is the same; the charged particle output module 5 is used to output all the first charged particles, all the second charged particles, and all the third charged particles to the infrastructure block; the repulsive force sum acquisition module 6 is used to initialize the positions of all the first charged particles, all the second charged particles, and all the third charged particles, and obtain the sum of the repulsive forces of all the first charged particles, all the second charged particles, and all the third charged particles; the real-time position optimization module 7 is used to iteratively update the real-time positions of all the first charged particles, all the second charged particles, and all the third charged particles through a global optimization algorithm to obtain the minimum value of the total length of all cables and minimize the sum of the repulsive forces; the layout position definition module 8 is used to obtain all real-time positions when the sum of the repulsive forces reaches the minimum, and define them as the layout positions of all photovoltaic arrays, all substations, and all energy storage power stations.
[0166] Furthermore, the constructible block definition module specifically includes a first constructible block definition submodule, a second constructible block definition submodule, a third constructible block definition submodule, a fourth constructible block definition submodule, a fifth constructible block definition submodule, a sixth constructible block definition submodule, a seventh constructible block definition submodule, an eighth constructible block definition submodule, and a ninth constructible block definition submodule, which are electrically connected in sequence; the first constructible block definition submodule is electrically connected to the constructible terrain surface marking module, and the ninth constructible block definition submodule is electrically connected to the charged particle definition module.
[0167] The first submodule for defining a buildable block is used to establish a grid set in the buildable terrain surface, and assign a value of 0 to each grid in the grid set, and the size of each grid is less than or equal to the size of each triangle; the second submodule for defining a buildable block is used to determine whether there is a triangle in each grid, and assign a value of 1 to the grid with a triangle; the third submodule for defining a buildable block is used to define the current grid and the adjacent grids as a three-dimensional window, and obtain the assigned values of all grids in each three-dimensional window; the fourth submodule for defining a buildable block is used to determine whether there is an assigned value of a grid in each three-dimensional window, and obtain the assigned value of all grids in each three-dimensional window; The value is 0; the fifth constructible block definition submodule is used for extracting the stereo window with the assigned value of 0 and marking it as the edge window if there is a grid with the assigned value of 0 in the current stereo window; the sixth constructible block definition submodule is used for extracting the triangles in each edge window respectively and marking them as edge triangles; the seventh constructible block definition submodule is used for connecting adjacent edge triangles in sequence to form a boundary; the eighth constructible block definition submodule is used for judging whether the current boundary is closed; the ninth constructible block definition submodule is used for judging that the current boundary has completed enclosing a constructible block if the current boundary is closed.
[0168] Furthermore, the third constructible block definition submodule specifically includes a first constructible block definition unit, a second constructible block definition unit, and a third constructible block definition unit which are electrically connected in sequence; the first constructible block definition unit is electrically connected to the second constructible block definition submodule, and the third constructible block definition unit is electrically connected to the fourth constructible block definition submodule.
[0169] Among them, the first constructible block definition unit is used to define the current grid and the twenty-six grids adjacent to the current grid as a 3×3×3 stereoscopic window; the second constructible block definition unit is used to determine whether there is a grid with an assigned value of 0 in each 3×3×3 stereoscopic window; the third constructible block definition unit is used to delete the 3×3×3 stereoscopic window with no grid and an assigned value of 0 if there is no grid with an assigned value of 0 in the current 3×3×3 stereoscopic window.
[0170] Furthermore, the seventh constructible block definition submodule specifically includes a first constructible block definition unit, a second constructible block definition unit, and a third constructible block definition unit which are electrically connected in sequence; the first constructible block definition unit is electrically connected to the sixth constructible block definition submodule, and the third constructible block definition unit is electrically connected to the eighth constructible block definition submodule.
[0171] Among them, the first buildable block definition unit is used to obtain the row and column values of each triangle in the current edge window and establish a to-be-connected point matrix for each triangle according to the Kruskal algorithm; the second buildable block definition unit is used to obtain the minimum spanning tree of each to-be-connected point matrix according to the Kruskal algorithm; the third buildable block definition unit is used to extract triangles in all minimum spanning trees and use them as edge triangles.
[0172] Furthermore, the real-time position optimization module specifically includes a first real-time position optimization sub-module, a second real-time position optimization sub-module, a third real-time position optimization sub-module, a fourth real-time position optimization sub-module, a fifth real-time position optimization sub-module, a sixth real-time position optimization sub-module, and a seventh real-time position optimization sub-module, which are electrically connected in sequence; the first real-time position optimization sub-module is electrically connected to the repulsive force sum acquisition module, and the seventh real-time position optimization sub-module is electrically connected to the layout position definition module.
[0173] Among them, the first real-time position optimization submodule is used to assign at least two first random solutions to each first charged particle, at least two second random solutions to each second charged particle, and at least two third random solutions to each third charged particle according to formula (1), formula (2), and formula (3) in sequence, and define the results of all first random solutions, all second random solutions, and all third random solutions as the total length of all cables reaching the minimum value, and at the same time constrain all first charged particles, all second charged particles, and all third charged particles based on Coulomb's law.
[0174]
[0175] Among them, X a is the set of all first random solutions for all first charged particles, x a1 ,x a2 ,…,x an are all the first random solutions of the ath first charged particle, n is the number of all the first random solutions of the current first charged particle, m is the number of all the first charged particles, V a is the set of velocities of all first random solutions, v a1 ,v a2 ,...,v an are all the velocities of all the first random solutions of the a-th first charged particle, is the set of all Coulomb forces for all first charged particles, are all the Coulomb forces on the ath first charged particle. The number of Coulomb forces on the current first charged particle is equal to the number of all the first random solutions of the current first charged particle. k is the Coulomb constant, q an-1 is the charge of the n-1th random solution of the ath first charged particle, q anThe charge of the nth random solution of the ath first charged particle, r a,n-1,n is the Euclidean distance between the n-1th first random solution and the nth first random solution of the ath first charged particle, It is the unit vector from the n-1th first random solution to the nth first random solution of the ath first charged particle.
[0176]
[0177] Among them, X b is the set of all second random solutions for all second charged particles, x b1 ,x b2 ,...,x bp is all the second random solutions of the bth second charged particle, p is the number of all the second random solutions of the current second charged particle, o is the number of all second charged particles, V b is the set of velocities of all second random solutions, v b1 ,v b2 ,...,v bp are all the velocities of all the second random solutions of the b-th second charged particle, is the set of all Coulomb forces for all second charged particles, is all the Coulomb forces on the bth second charged particle. The number of Coulomb forces on the current second charged particle is equal to the number of all the second random solutions of the current second charged particle. bp-1 is the charge of the p-1th second random solution of the bth second charged particle, q bp The charge of the pth random solution of the bth second charged particle, r b,p-1,p is the Euclidean distance between the p-1th second random solution and the pth second random solution of the bth second charged particle, It is the unit vector from the p-1th second random solution to the pth second random solution of the bth second charged particle.
[0178]
[0179] Among them, X c is the set of all third random solutions for all third charged particles, x c1 ,x c2 ,...,x ct are all the third random solutions of the cth third charged particle, t is the number of all the third random solutions of the current third charged particle, s is the number of all third charged particles, V c is the set of velocities of all third random solutions, v c1 ,v c2 ,...,v ctare all the velocities of all third random solutions of the cth third charged particle, is the set of all Coulomb forces for all third charged particles, is all the Coulomb forces on the cth third charged particle. The number of Coulomb forces on the current third charged particle is equal to the number of all third random solutions of the current third charged particle. ct-1 is the charge of the t-1th third random solution of the cth third charged particle, q ct The charge of the tth third random solution of the cth third charged particle, r c,t-1,t is the Euclidean distance between the t-1th third random solution and the tth third random solution of the cth third charged particle, is the unit vector from the t-1th third random solution to the tth third random solution of the cth third charged particle.
[0180] The second real-time position optimization submodule is used to update the position and speed of each first random solution, each second random solution, and each third random solution at a preset time interval according to formula (4):
[0181]
[0182] Among them, x ijd is the jth random solution of the ith charged particle, v ijd is the velocity of the jth random solution of the ith charged particle at the dth step, ω·v ijd-1 is the velocity inertia of the jth random solution of the ith charged particle at the d-1th step, ω is the inertia coefficient of velocity inertia, C1·random()·(u best,ij -x ij ) is the self-perception representation of the jth random solution of the ith charged particle, C2·random()·(g best,ij -x ij ) is the social cognitive representation of the jth random solution of the ith charged particle; C1 and C2 are both learning factors, random() is a random number in the range of [0,1], u best,ij is the individual optimal solution obtained by the jth random solution of the ith charged particle, g best,ij is the global optimal solution obtained by the j-th random solution of the i-th charged particle.
[0183] The third real-time position optimization submodule is used to iterate a preset number of times according to formula (4) to update each u best,ij And each g best,ij .
[0184] The fourth real-time location optimization submodule is used to determine each u best,ijCompared with the first difference of the previous iteration, whether it is less than or equal to the first preset adaptation threshold, if so, execute step S75.
[0185] The fifth real-time location optimization submodule is used to determine each g best,ij Compared with the second difference of the previous iteration, whether it is less than or equal to the second preset adaptation threshold, if so, execute step S76.
[0186] The sixth real-time position optimization submodule is used to determine whether the total length of all cables reaches the minimum value and stop the iteration of formula (4).
[0187] The seventh real-time position optimization submodule is used to obtain the final positions of all first charged particles, all second charged particles, and all third charged particles after the iteration is completed.
[0188] Furthermore, the third real-time position optimization submodule is specifically used to optimize the inertia coefficient ω once according to formula (5) in each iteration:
[0189]
[0190] Among them, ω ijd is the inertia coefficient of the jth random solution of the ith charged particle after optimization in the dth step, ω ini is the initial inertia coefficient, ω ijd-1 is the inertia coefficient of the jth random solution of the ith charged particle at the d-1th step, G k is the current iteration number, G max is the total number of iterations after the iteration is completed.
[0191] Furthermore, the layout device also includes a color-emphasized triangulated surface acquisition module, a visualization layout model generation module, and a visualization layout model output module, which are electrically connected in sequence.
[0192] Among them, the emphasized color triangulated mesh surface acquisition module is used to obtain the triangulated mesh surface and fade the color of the non-infrastructure-capable area to obtain the emphasized color triangulated mesh surface; the visualization layout model generation module is used to output the layout positions of all photovoltaic arrays, all substations, and all energy storage power stations on the emphasized color triangulated mesh surface to form a visualization layout model; the visualization layout model output module is used to output the visualization layout model to an external visualization terminal.
[0193] It should be noted that this embodiment is a functional module item embodiment based on the above method embodiment. For additional contents such as the optimization, expansion, and example description of this embodiment, please refer to the above method embodiment.
[0194] This embodiment obtains the digital model of the elevation of the preset area, and establishes the triangulated surface of the preset area through a preset strategy; obtains the angle between each triangle in the triangulated surface and the horizontal plane, and marks the triangles whose angles do not exceed the preset angle threshold as the terrain surface that can be constructed; obtains the boundary of the terrain surface that can be constructed through a sliding window algorithm, and defines the terrain surface that can be constructed with discontinuous boundaries as a block that can be constructed; defines each photovoltaic array as a first charged particle with a first charge, defines each substation as a second charged particle with a second charge, and defines each energy storage power station as a third charged particle with a third charge, and all the first charged particles, all the second charged particles, and all the third charged particles are respectively defined as the first charged particles, the second charged particles, and the third charged particles. The charge polarity of the three charged particles is the same; all first charged particles, all second charged particles, and all third charged particles are output to the infrastructure block; the positions of all first charged particles, all second charged particles, and all third charged particles are initialized, and the sum of the repulsive forces of all first charged particles, all second charged particles, and all third charged particles are obtained; the real-time positions of all first charged particles, all second charged particles, and all third charged particles are iteratively updated through a global optimization algorithm to obtain the minimum value of the total length of all cables and minimize the sum of the repulsive forces; all real-time positions when the sum of the repulsive forces reaches the minimum are obtained, and defined as the layout positions of all photovoltaic arrays, all substations, and all energy storage power stations. In this embodiment, the total length of the cables used in the photovoltaic power station is used as a layout indicator, and all photovoltaic modules are defined as charged particles with the same polarity. The distance between each photovoltaic module can be adjusted by adjusting the charge of each charged particle, and the charge is proportional to the distance. The staff can adjust the charge of each charged particle in real time according to external indicators such as power generation and construction budget to achieve the spacing adjustment of each photovoltaic module. Under the mutual repulsion constraint of the charged particles mentioned above, the real-time position of each charged particle is iterated through the global optimization algorithm, and the total length of the cables used is obtained once in each iteration until the iteration reaches the desired value. After the total length of the cables reaches the minimum value, it will no longer change. At this time, the real-time positions of the charged particles obtained are the layout positions of the photovoltaic modules. This embodiment uses the most intuitive and important electrical connection cables as layout indicators, and uses the mutual repulsion of equivalent charged particles as spacing constraints to obtain the layout positions of the photovoltaic modules with the shortest cables. Less cable usage represents a neater and more compact layout, which maximizes the power generation per unit area of the photovoltaic power station. Compared with the traditional manual judgment method, this embodiment is automatically calculated by the software program throughout the process, and achieves a layout effect that cannot be achieved manually.
[0195] Figure 3 Schematic diagram of the structure of an electronic device according to an embodiment of the present application. Figure 3 As shown, the electronic device 9 includes a processor 91 and a memory 92 coupled to the processor 91 .
[0196] The memory 92 stores program instructions for implementing a photovoltaic assembly layout method according to any one of the above embodiments.
[0197] The processor 91 is used to execute program instructions stored in the memory 92 to perform the layout of photovoltaic modules.
[0198] The processor 91 may also be referred to as a CPU (Central Processing Unit). The processor 91 may be an integrated circuit chip having the ability to process signals. The processor 91 may also be a general-purpose processor, a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field programmable gate array (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components. The general-purpose processor may be a microprocessor or the processor may also be any conventional processor, etc.
[0199] Further, Figure 4 This is a schematic diagram of the structure of a storage medium according to an embodiment of the present application. Figure 4 The storage medium 10 of the embodiment of the present application stores program instructions 101 that can implement all the above methods, wherein the program instructions 101 can be stored in the above storage medium in the form of a software product, including several instructions for enabling a computer device (which can be a personal computer, server, or network device, etc.) or a processor to execute all or part of the steps of the methods described in each embodiment of the present application. The aforementioned storage medium includes: various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk, or terminal devices such as a computer, a server, a mobile phone, and a tablet.
[0200] In the several embodiments provided in the present application, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of units is only a logical function division. There may be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interfaces, devices or units, which can be electrical, mechanical or other forms.
[0201] In addition, each functional unit in each embodiment of the present application 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 above integrated unit can be implemented in the form of hardware or in the form of software functional units. The above is only an implementation method of the present application, and does not limit the patent scope of the present application. Any equivalent structure or equivalent process transformation made using the contents of the specification and drawings of this application, or directly or indirectly used in other related technical fields, is also included in the patent protection scope of the present application.
Claims
1. A method for laying out a photovoltaic assembly, wherein the photovoltaic assembly comprises a plurality of photovoltaic arrays erected in a preset area, at least one substation electrically connected to each photovoltaic array through a plurality of cables, and at least one energy storage power station electrically connected to the substation through at least one cable, wherein: The layout method comprises: Step S1, obtaining a digital elevation model of the preset area, and establishing a triangulated surface of the preset area through a preset strategy; Step S2, respectively obtaining the angle between each triangle in the triangulated surface and the horizontal plane, and marking the triangles whose angles do not exceed a preset angle threshold as constructible terrain surfaces; Step S3, obtaining the boundary of the constructible terrain surface by a sliding window algorithm, and defining the constructible terrain surface with discontinuous boundaries as a constructible block; Step S4, respectively defining each photovoltaic array as a first charged particle with a first charge, defining each substation as a second charged particle with a second charge, and defining each energy storage power station as a third charged particle with a third charge, and all first charged particles, all second charged particles, and all third charged particles have the same charge polarity; Step S5, outputting all first charged particles, all second charged particles, and all third charged particles to the constructible block; Step S6, initializing the positions of all first charged particles, all second charged particles, and all third charged particles, and obtaining the sum of repulsive forces of all first charged particles, all second charged particles, and all third charged particles; Step S7, iteratively updating the real-time positions of all first charged particles, all second charged particles, and all third charged particles through a global optimization algorithm to obtain the minimum value of the total length of all cables and minimize the sum of the repulsive forces; Step S8, obtaining all real-time positions when the sum of the repulsive forces reaches the minimum, and defining them as the layout positions of all photovoltaic arrays, all substations, and all energy storage power stations.
2. The layout method according to claim 1, characterized in that: Step S3, obtaining the boundary of the constructible terrain surface by a sliding window algorithm, and defining the constructible terrain surface with discontinuous boundaries as a constructible block, including: Step S31, establishing a grid set in the constructible terrain surface, and assigning a value of 0 to each grid in the grid set, wherein the size of each grid is smaller than or equal to the size of each triangle; Step S32, determining whether the triangle exists in each mesh, and assigning a value of 1 to the mesh where the triangle exists; Step S33, defining the current grid and adjacent grids as a three-dimensional window, and obtaining the assigned values of all grids in each three-dimensional window respectively; Step S34, determining whether there is a grid in each three-dimensional window whose assigned value is 0, if there is a grid in the current three-dimensional window whose assigned value is 0, executing step S35; Step S35, extracting the three-dimensional windows with assigned values of 0 and marking them as edge windows; Step S36, extracting triangles in each edge window and marking them as edge triangles; Step S37, sequentially connecting adjacent edge triangles to form the boundary; Step S38, determining whether the current boundary is closed, if the current boundary is closed, executing step S39; Step S39, determining whether the current boundary has completely enclosed a constructible block.
3. The layout method according to claim 2, characterized in that: Step S33, defining the current grid and the adjacent grids as a three-dimensional window, and obtaining the assigned values of all grids in each three-dimensional window respectively, including: Step S331, defining the current grid and twenty-six grids adjacent to the current grid as a 3×3×3 stereoscopic window; Step S332, determining whether there is a grid with an assigned value of 0 in each 3×3×3 stereoscopic window, if there is no grid with an assigned value of 0 in the current 3×3×3 stereoscopic window, executing step S333; Step S333, deleting the 3×3×3 stereoscopic window with no grid and the assigned value of 0.
4. The layout method according to claim 2, characterized in that: Step S37, sequentially connecting adjacent edge triangles to form the boundary, includes: Step S371, obtaining the row and column values of each triangle in the current edge window and establishing a to-be-connected point matrix for each triangle according to the Kruskal algorithm; Step S372, obtaining the minimum spanning tree of each to-be-connected point matrix according to the Kruskal algorithm; Step S373, extracting all triangles in the minimum spanning tree and using them as the edge triangles.
5. The layout method according to claim 1, characterized in that: Step S7, iteratively updating the real-time positions of all first charged particles, all second charged particles, and all third charged particles through a global optimization algorithm to obtain the minimum value of the total length of all cables and minimize the sum of the repulsive forces, including: Step S71, according to formula (1), formula (2), and formula (3), at least two first random solutions are assigned to each first charged particle, at least two second random solutions are assigned to each second charged particle, and at least two third random solutions are assigned to each third charged particle, and the results of all the first random solutions, all the second random solutions, and all the third random solutions are defined as the total length of all the cables reaching the minimum value, and at the same time, all the first charged particles, all the second charged particles, and all the third charged particles are constrained based on Coulomb's law; Among them, X a is the set of all first random solutions for all first charged particles, x a1 ,x a2 ,...,x an are all the first random solutions of the ath first charged particle, n is the number of all the first random solutions of the current first charged particle, m is the number of all the first charged particles, V a is the set of velocities of all first random solutions, v a1 ,v a2 ,...,v an are all the velocities of all the first random solutions of the a-th first charged particle, is the set of all Coulomb forces for all first charged particles, are all the Coulomb forces on the ath first charged particle. The number of Coulomb forces on the current first charged particle is equal to the number of all the first random solutions of the current first charged particle. k is the Coulomb constant, q an-1 is the charge of the n-1th random solution of the ath first charged particle, q an The charge of the nth random solution of the ath first charged particle, r a,n-1,n is the Euclidean distance between the n-1th first random solution and the nth first random solution of the ath first charged particle, is the unit vector from the n-1th first random solution to the nth first random solution of the ath first charged particle; Among them, X b is the set of all second random solutions for all second charged particles, x b1 ,x b2 ,...,x bp is all the second random solutions of the bth second charged particle, p is the number of all the second random solutions of the current second charged particle, o is the number of all second charged particles, V b is the set of velocities of all second random solutions, v b1 ,v b2 ,...,v bp are all the velocities of all the second random solutions of the b-th second charged particle, is the set of all Coulomb forces for all second charged particles, is all the Coulomb forces on the bth second charged particle. The number of Coulomb forces on the current second charged particle is equal to the number of all the second random solutions of the current second charged particle. bp-1 is the charge of the p-1th second random solution of the bth second charged particle, q bp The charge of the pth random solution of the bth second charged particle, r b,p-1,p is the Euclidean distance between the p-1th second random solution and the pth second random solution of the bth second charged particle, is the unit vector from the p-1th second random solution to the pth second random solution of the bth second charged particle; Among them, X c is the set of all third random solutions for all third charged particles, x c1 ,x c2 ,...,x ct are all the third random solutions of the cth third charged particle, t is the number of all the third random solutions of the current third charged particle, s is the number of all third charged particles, V c is the set of velocities of all third random solutions, v c1 ,v c2 ,...,v ct are all the velocities of all third random solutions of the cth third charged particle, is the set of all Coulomb forces for all third charged particles, is all the Coulomb forces on the cth third charged particle. The number of Coulomb forces on the current third charged particle is equal to the number of all third random solutions of the current third charged particle. ct-1 is the charge of the t-1th third random solution of the cth third charged particle, q ct The charge of the tth third random solution of the cth third charged particle, r c,t-1,t is the Euclidean distance between the t-1th third random solution and the tth third random solution of the cth third charged particle, is the unit vector from the t-1th third random solution to the tth third random solution of the cth third charged particle; Step S72, respectively updating the position and speed of each first random solution, each second random solution, and each third random solution at a preset time interval according to formula (4): Among them, x ijd is the jth random solution of the ith charged particle, v ijd is the velocity of the jth random solution of the ith charged particle at the dth step, ω·v ijd-1 is the velocity inertia of the jth random solution of the ith charged particle at the d-1th step, ω is the inertia coefficient of the velocity inertia, C1·random()·(u best,ij -x ij ) is the self-perception representation of the jth random solution of the ith charged particle, C2·random()·(g best,ij -x ij ) is the social cognitive representation of the jth random solution of the ith charged particle; C1 and C2 are both learning factors, random() is a random number in the range of [0,1], u best,ij is the individual optimal solution obtained by the jth random solution of the ith charged particle, g best,ij is the global optimal solution obtained by the jth random solution of the i-th charged particle; Step S73, iterate a preset number of times according to formula (4) to update each u best,ij And each g best,ij ; Step S74, determine each u best,ij Compared with the first difference of the previous iteration, whether it is less than or equal to the first preset adaptation threshold, if so, executing step S75; Step S75, determine each g best,ij Compared with the second difference of the previous iteration, whether it is less than or equal to the second preset adaptation threshold, if so, executing step S76; Step S76, determining that the total length of all cables reaches the minimum value, and stopping the iteration of formula (4); Step S77, obtaining the final positions of all first charged particles, all second charged particles, and all third charged particles after the iteration is completed.
6. The layout method according to claim 5, characterized in that: Step S73, iterate a preset number of times according to formula (4) to update each u best,ij And each g best,ij ,include: Step S731, optimizing the inertia coefficient ω once in each iteration according to formula (5): Among them, ω ijd is the inertia coefficient of the jth random solution of the ith charged particle after optimization in the dth step, ω ini is the initial inertia coefficient, ω ijd-1 is the inertia coefficient of the jth random solution of the ith charged particle at the d-1th step, G k is the current iteration number, G max is the total number of iterations after the iteration is completed.
7. The layout method according to claim 1, characterized in that: Step S8, obtaining all real-time positions when the sum of the repulsive forces reaches the minimum, and defining them as the layout positions of all photovoltaic arrays, all substations, and all energy storage power stations, and then including: Step S10, obtaining the triangulated surface and performing color fading processing on the area that is not the constructible block to obtain a highlighted color triangulated surface; Step S20, outputting the layout positions of all photovoltaic arrays, all substations, and all energy storage power stations on the emphasized color triangulated surface to form a visual layout model; Step S30: outputting the visualization layout model to an external visualization terminal.
8. A photovoltaic assembly layout device, the layout device being applied to the layout method according to any one of claims 1 to 7, characterized in that: The layout device includes: A triangulated surface building module, used to obtain the elevation digital model of the preset area and build the triangulated surface of the preset area through a preset strategy; A construction-capable terrain surface marking module is used to obtain the angle between each triangle in the triangulated surface and the horizontal plane, and mark the triangles whose angles do not exceed a preset angle threshold as construction-capable terrain surfaces; A construction block definition module is used to obtain the boundary of the construction terrain surface through a sliding window algorithm, and define the construction terrain surface with discontinuous boundaries as a construction block; A charged particle definition module, used to define each photovoltaic array as a first charged particle with a first charge, each substation as a second charged particle with a second charge, and each energy storage power station as a third charged particle with a third charge, and all the first charged particles, all the second charged particles, and all the third charged particles have the same charge polarity; A charged particle output module, used for outputting all first charged particles, all second charged particles, and all third charged particles to the constructible block; A repulsive force sum acquisition module is used to initialize the positions of all first charged particles, all second charged particles, and all third charged particles, and to acquire the repulsive force sum of all first charged particles, all second charged particles, and all third charged particles; A real-time position optimization module, used for iteratively updating the real-time positions of all first charged particles, all second charged particles, and all third charged particles through a global optimization algorithm to obtain the minimum value of the total length of all cables and minimize the sum of the repulsive forces; The layout position definition module is used to obtain all real-time positions when the sum of the repulsive forces reaches the minimum, and define them as the layout positions of all photovoltaic arrays, all substations, and all energy storage power stations.
9. An electronic device, characterized in that: It comprises a processor and a memory coupled to the processor, wherein the memory stores program instructions executable by the processor; when the processor executes the program instructions stored in the memory, the layout method according to any one of claims 1 to 7 is implemented.
10. A storage medium, characterized in that: The storage medium stores program instructions, and when the program instructions are executed by a processor, the layout method according to any one of claims 1 to 7 can be implemented.
Citation Information
Patent Citations
Method, device and system for generating layout diagram of photovoltaic power generation system and storage medium
CN118278063A
Method and system for characterizing efficiency impact of interruption defects in photovoltaic cells
US20130035881A1
Cable path planning method and apparatus
US20230061400A1
Cited By
Layout method, device and equipment of flexible photovoltaic power station and storage medium
CN120124270A
A layout method, device, equipment and storage medium for a flexible photovoltaic power station
CN120124270B
