Roof photovoltaic intelligent arrangement method based on multi-objective optimization and interactive feedback
By employing a multi-objective optimization and interactive feedback intelligent layout method, the problem of multi-objective global trade-offs and adaptive adjustments in the layout of rooftop photovoltaic modules in existing technologies has been solved. This has enabled efficient and compliant photovoltaic module layout, improved space utilization and annual power generation, and shortened the design cycle.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- 常州常供电力设计院有限公司
- Filing Date
- 2026-04-28
- Publication Date
- 2026-06-05
AI Technical Summary
Existing rooftop photovoltaic module layout technology lacks the ability to balance multiple objectives globally, cannot adaptively adjust spacing and azimuth angle, cannot balance multiple design objectives in real time, has poor ability to handle complex and irregular roofs and obstacles, has a broken interactive experience, and cannot understand the user's fine-tuning intentions.
An intelligent layout method based on multi-objective optimization and interactive feedback is adopted. It combines building roof geometry data, photovoltaic module parameters and user preference data, and generates the optimal solution set through hybrid initialization, fast non-dominated sorting and crowding distance calculation. It also supports user interaction to achieve adaptive layout.
It improved space utilization by 15% to 22%, increased annual power generation by 10.5% to 16.7%, shortened the design cycle by 75%, ensured design compliance, and achieved a Pareto optimal balance and efficient interactive experience for multiple objectives.
Smart Images

Figure CN122154488A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of photovoltaic power plant design technology, and in particular to a method for intelligent rooftop photovoltaic layout based on multi-objective optimization and interactive feedback. Background Technology
[0002] With the rapid promotion of distributed photovoltaic (PV) power stations, the installed capacity of residential and commercial rooftop PV systems continues to grow. The layout design of rooftop PV arrays has become a key factor affecting the power generation efficiency, construction costs, and safety compliance of PV power stations. Currently, the automatic layout and counting of rooftop PV modules mainly adopts an array-based filling method based on single-objective optimization, which has the following drawbacks: 1. Lack of multi-objective global trade-off capability: Single-objective optimization cannot make a scientific trade-off between "installing one more panel but not significantly increasing power generation" and "installing one less panel but significantly reducing shading losses", often resulting in a scheme with high area utilization but not optimal actual power generation revenue or economic efficiency.
[0003] 2. The layout strategy is static and rigid, unable to adaptively adjust spacing and azimuth: Existing algorithms typically preset a fixed layout orientation (e.g., due south) and a fixed row spacing (e.g., the standard minimum spacing). However, in actual engineering projects, roof shapes are often irregular (L-shaped, U-shaped, with curved boundaries), and a fixed orientation will result in a large amount of unusable fragmented space in the edge areas. Existing technologies lack the computational capability to automatically search for the "optimal azimuth" and "variable spacing".
[0004] 3. Multiple decision-making objectives are isolated, making it impossible to generate a Pareto front: Current technologies postpone tasks such as power generation assessment, cost estimation, and compliance checks until after layout is completed, with the layout phase only considering maximizing area. When subsequent findings indicate unsatisfactory power generation or excessively high costs, a re-layout is required, forming an open-loop iteration of "layout → assessment → dissatisfaction → re-layout," making it impossible to balance multiple conflicting objectives in real time during optimization. Designers often end up overlooking some aspects: installing the most panels, yet power generation falls short of expectations due to shading; or leaving ample channels, yet wasting a significant amount of usable area.
[0005] 4. Poor adaptability to complex and irregular roofs and obstacles: Existing algorithms typically require simplifying the roof outline to a rectangle or convex polygon, exhibiting weak ability to handle real roofs with L-shapes, U-shapes, concave or curved boundaries. Rigid arrays simply "hollow out" obstacles, resulting in numerous unusable triangles or irregular fragmented areas around them. Furthermore, the algorithm cannot adjust the local arrangement direction according to the shape of the obstacle (e.g., realigning after bypassing ventilation shafts), significantly reducing space utilization.
[0006] 5. Disrupted Interactive Experience: The system cannot perceive the user's fine-tuning intentions. When users are dissatisfied with the automatically generated layout and make manual adjustments, the existing system only provides basic graphic displacement functions (move, rotate, delete). The system cannot understand the user's modification intentions (e.g., "I want this row of panels to move 2 meters to the left to avoid shadows" or "I want to rearrange this area"), nor can it perform secondary automatic optimization for the modified local areas. Users often need to adjust the photovoltaic panels one by one and manually fill in the blank areas created by the movement, a tedious process that is highly likely to introduce new violations.
[0007] Therefore, there is an urgent need for a smart rooftop photovoltaic layout method that combines multi-objective optimization and interactive feedback to achieve drag perception and local intelligent completion, take into account multi-dimensional design objectives, and solve the relevant defects of existing technologies. Summary of the Invention
[0008] The technical problem to be solved by the present invention is: in order to solve at least one technical problem existing in the prior art, the present invention provides a rooftop photovoltaic intelligent layout method based on multi-objective optimization and interactive feedback.
[0009] The technical solution adopted by this invention to solve its technical problem is: This invention provides a method for intelligent rooftop photovoltaic (PV) deployment based on multi-objective optimization and interactive feedback, comprising: S1. Obtain building roof geometry data, photovoltaic module parameters, and user preference data; S2. Combining building roof geometry data, photovoltaic module parameters, and user preference data, a hybrid initialization strategy is adopted to initialize the population of candidate layout schemes; S3. Calculate the objective functions of installed capacity, annual power generation and comprehensive cost for each candidate layout scheme in the initialized population. S4. Based on the objective function of installed capacity, annual power generation and comprehensive cost, perform fast non-dominated sorting and crowding distance calculation on the population. S5. Based on fast non-dominated sorting and crowding distance, the parent population is selected; S6. Perform crossover and mutation operations on the parent population to generate a new offspring population. Merge the parent and offspring populations to obtain an optimized population. S7. Select the optimal solution set from the optimization population according to the preset rules; S8. Users interact with the optimal solution set to obtain the final photovoltaic layout scheme.
[0010] Furthermore, the user preference data includes the search range of the layout azimuth angle, the search range of the layout spacing, and the target optimization weight tendency.
[0011] Furthermore, step S2 includes: S21. Randomly generate N candidate arrangement schemes; S22. Decompose each candidate arrangement scheme into global variables and local variables, and encode the global variables and local variables independently; S23. Generate a basic rule-based layout scheme based on the main direction of the roof and the minimum spacing specified in the code; S24. Perturb the parameters of the basic rule layout scheme to generate multiple variant layout schemes; S25. Merge the individuals of the randomly generated N candidate arrangement schemes, the basic rule arrangement schemes, and the variant arrangement schemes to obtain the initial population.
[0012] Furthermore, the objective function for the annual power generation is calculated as follows: [The method involves] calculating the actual annual power generation... and theoretical reference power generation By normalizing the ratio, we obtain the objective function for annual power generation. ; The actual annual power generation The calculation method is as follows: S301. Based on the solar position parameters on the winter solstice and the geometric parameters of the obstacle, calculate the shadow length and shadow direction of the obstacle on the horizontal plane; S302. Calculate the shading area ratio of the photovoltaic panel based on the shadow length and shadow direction; S303. Calculate the actual received irradiance of the photovoltaic panel by using the inclined plane irradiance calculation model and combining the shading area ratio. S304. Calculate the actual annual power generation based on the actual received irradiance. .
[0013] Furthermore, the objective function of the comprehensive cost is calculated as follows: the shadow occlusion loss rate, bracket cost and cable cost are combined and normalized to obtain the normalized comprehensive cost, and then the normalized comprehensive cost is subtracted from 1. The formula for calculating the cost of the stent is as follows: ; in, For stent cost; This refers to the number of photovoltaic panels; The cost is for the basic installation of a single photovoltaic panel; Linear material cost per unit area; For large-area photovoltaic panels, the nonlinear penalty coefficient is used. This refers to the area of a single photovoltaic panel; The threshold area.
[0014] Furthermore, the hybrid cross includes: Simulated binary crossover is performed on the global variables of the parent population, and multi-point crossover is performed on the local variables of the parent population.
[0015] Furthermore, the hybrid variation includes: Perform polynomial mutation on the global variables of the parent population, and perform heuristic mutation on the local variables of the parent population.
[0016] Furthermore, step S8 includes: S81. In response to the user's selection operation of the optimal solution set, load the data of the selected photovoltaic layout scheme into the photovoltaic layout editing canvas; S82, In response to the user's selection operation and locking command in the roof area, identify the photovoltaic panels in the selected area and add them to the locking set; S83. In response to the user's drag operation on a single photovoltaic panel, verify the spacing constraints of the drag target position and move the photovoltaic panel. S84. Using the geometric center point of the gap created after the photovoltaic panel is moved as the center, delineate a local area, and perform a gap filling operation on the unlocked photovoltaic panels in the local area. S85. Recalculate the power generation of the photovoltaic panels affected by drag operations and gap filling, and update the total power generation; S86. In response to the user's local optimization instruction, the photovoltaic panels within the locked set are treated as fixed constraints, and multi-objective optimization is performed only on photovoltaic panels outside the locked set.
[0017] Furthermore, the method for filling the gap includes: Starting from the geometric center of the empty position, search for the nearest photovoltaic panel to be adjusted in a spiral order, and move the nearest photovoltaic panel to the empty position; repeat the above steps until all empty positions in the local area are filled or there are no unlocked photovoltaic panels to be adjusted.
[0018] Furthermore, it also includes: During steps S4, S5 and S6, a constraint domination strategy is simultaneously applied to the population. The constraint control strategy includes: controlling the outline of each photovoltaic panel to be completely within the roof boundary; the distance between each photovoltaic panel and obstacles ≥ a first threshold; the distance between adjacent photovoltaic panels ≥ a second threshold; the photovoltaic module maintenance channel ≥ a third threshold; and the distance between the photovoltaic panel and the roof edge ≥ a fourth threshold.
[0019] The beneficial effects of this invention are: 1. By incorporating the azimuth angle, row spacing, and column spacing into the optimization variables and searching for the optimal orientation across the entire domain, it can adaptively fit irregular boundaries such as L-shapes, triangles, and pentagons, making full use of edge fragment space; compared with traditional fixed-orientation rigid arrays, the installed capacity of irregular roofs is increased by an average of 15%~22%, and the space utilization rate is greatly improved.
[0020] 2. Achieve a multi-objective Pareto optimal balance between annual power generation, installed capacity, and overall costs: Simultaneously optimize installed capacity, annual power generation, and overall costs, automatically and scientifically weighing between "more installed panels" and "less shading and higher power generation," and outputting multiple sets of uncontrollable candidate solutions; without reducing installed capacity, annual power generation is increased by 10.5% to 16.7%, significantly reducing shading losses and hot spot risks.
[0021] 3. Smooth and efficient interaction, significantly shortening the design cycle: Supports local locking, drag-and-drop awareness, intelligent completion and regional re-optimization. After manual fine-tuning, the system automatically fills in gaps and eliminates collisions. It only performs local calculations on the affected areas, with a response time of less than 200ms. User fine-tuning time is reduced by 75%. It balances human intent with algorithmic optimality and adapts to special on-site conditions (such as temporarily added roof pipelines).
[0022] 4. Strong compliance constraints, eliminating design violations: The optimization process enforces hard constraints such as roof boundary setback, obstacle spacing, inter-slab spacing, and operation and maintenance access. Violations are automatically repaired or eliminated, and the output solution is compliant throughout the process, completely solving common violations in manual design such as insufficient spacing, exceeding boundaries, and obstruction. Attached Figure Description
[0023] The present invention will be further described below with reference to the accompanying drawings and embodiments.
[0024] Figure 1 This is a flowchart of the intelligent rooftop photovoltaic layout method based on multi-objective optimization and interactive feedback of the present invention. Detailed Implementation
[0025] The present invention will now be described in further detail with reference to the accompanying drawings. These drawings are simplified schematic diagrams, illustrating only the basic structure of the invention, and therefore only show the components relevant to the invention.
[0026] Example 1: like Figure 1 As shown, this embodiment provides a rooftop photovoltaic smart layout method based on multi-objective optimization and interactive feedback, including: S1. Obtain building roof geometry data, photovoltaic module parameters, and user preference data. Building roof geometry data includes the building roof outline polygon and a set of polygons representing roof obstacle areas (each obstacle is a polygon). Photovoltaic module parameters include the length, width, peak power, open-circuit voltage, maximum power point voltage, and short-circuit current of the photovoltaic panels.
[0027] User preference data includes the search range for the azimuth angle of the array, the search range for the spacing between array panels, and the target optimization weight bias. The search range for the azimuth angle of the array is used to limit the allowable adjustment range for the overall orientation of the photovoltaic array. The search range for the spacing between array panels is used to limit the allowable adjustment range for the safe spacing between rows (columns) of photovoltaic panels. The target optimization weight bias is used to set the priority for the multi-objective optimization of the algorithm, so that the initial search is biased towards the indicators that users care about most.
[0028] S2. Combining building roof geometry data, photovoltaic module parameters, and user preference data, a hybrid initialization strategy is adopted to initialize the population of candidate layout schemes (i.e., the set of all candidate layout schemes).
[0029] In some feasible implementations, step S2 includes: S21. Based on the data obtained in step S1, randomly generate N candidate arrangement schemes (N is usually 100~200).
[0030] S22. Decompose each candidate arrangement scheme into global variables and local variables, and encode the global variables and local variables independently.
[0031] Specifically, the global variables include the arrangement azimuth angle, row spacing, and column spacing, while the local variables are two-dimensional arrays based on anchor point grids. Each element of the two-dimensional array corresponds to an anchor point grid cell, and the element values include: whether a photovoltaic panel is placed in the corresponding anchor point grid cell, the position of the photovoltaic panel when it is placed, and the rotation angle.
[0032] Specifically, different encoding methods are used for different variables. For example, for variables involving angles and spacing, real numbers are used directly to avoid conversion errors in binary encoding and improve computational efficiency. For whether photovoltaic panels are placed in the anchor grid cell, binary matrix encoding is used, which is intuitive and efficient.
[0033] S23. Generate a basic rule-based layout scheme based on the main direction of the roof and the minimum spacing specified in the code.
[0034] Specifically, the main direction of the building's roof outline is extracted as the initial value of the global layout azimuth angle. Based on the minimum row spacing and minimum column spacing required to meet fire protection, maintenance, and anti-shading requirements, a neat, orderly, and fully compliant photovoltaic array foundation layout scheme is generated.
[0035] S24. Perturb the parameters of the basic rule layout scheme to generate multiple variant layout schemes. That is, make small-scale fine adjustments to the basic rule layout scheme, including: adjusting the global layout azimuth angle within the preset azimuth angle search range, adjusting the row / column spacing based on the standard minimum spacing, and making local adjustments to the position and rotation angle of the photovoltaic panels around the obstacles, generating multiple variant layout schemes that are similar to the basic scheme but have different parameters.
[0036] Specifically, the fine-tuning examples are as follows: Azimuth fine-tuning: the base scheme is due south at 0°, and variants generate 5 schemes with different angles within the range of -5° to +5°; Row spacing fine-tuning: the base scheme is 0.8m (minimum standard value), and variants generate 4 schemes with different spacings within the range of 0.8m to 1.2m; Local fine-tuning: rotating the 3 photovoltaic panels around the roof obstacle by 5°, 10°, and 15° respectively, generating 3 variant schemes that avoid the obstacle. These angle fine-tunings ensured that the initial population covered multiple different orientations, providing a diversity basis for subsequent evolution.
[0037] S25. Merge the individuals of the randomly generated N candidate arrangement schemes, the basic rule arrangement schemes, and the variant arrangement schemes to obtain the initial population.
[0038] By using the above method, the algorithm can include high-quality candidate solutions in the initial stage, avoid iterating from completely random invalid solutions, significantly improve the convergence speed of the algorithm, and shorten the optimization time.
[0039] S3. Calculate the objective functions for installed capacity, annual power generation, and comprehensive cost for each candidate layout scheme in the initialized population.
[0040] In some feasible implementations, the objective function for installed capacity is calculated as: f1 = actual number of photovoltaic panels installed / theoretical maximum number of panels that can be installed. The theoretical maximum number of panels that can be installed is estimated by dividing the roof area by the area of a single panel.
[0041] In some feasible implementations, the objective function for annual power generation is calculated as follows: [The text abruptly ends here, so the translation stops.] and theoretical reference power generation By normalizing the ratio, we obtain the objective function for annual power generation. . The specific calculation formula is as follows: Theoretical reference power generation This represents the total power generation of all photovoltaic panels at their optimal tilt angle when there is no shading.
[0042] Specifically, theoretical reference power generation The calculation formula is as follows: ; ; In the formula, The maximum number of photovoltaic panels that can be arranged without shading can be estimated using a rectangular dense arrangement algorithm (such as a greedy algorithm) based on the roof outline area and the size of the photovoltaic panels. This represents the theoretical annual power generation of a single photovoltaic panel. This refers to the rated power of the photovoltaic panel. The annual equivalent full-load operating hours under the optimal tilt angle in the local area can be obtained from the meteorological database; The system loss coefficient represents the proportion of energy loss throughout the entire process of a photovoltaic power plant, from the output end of the modules to the grid connection point. Its value can be determined based on industry-standard system loss models and engineering experience data, with a preferred value of 0.13 to 0.2. As a preferred option, for regions at approximately 30° latitude, when using 450Wp photovoltaic panels... Approximately 44,900 kWh / 100 boards / year.
[0043] Specifically, the lightweight power generation assessment model is invoked, taking into input data such as the tilt angle of the photovoltaic panels, the azimuth angle of the photovoltaic panel arrangement, and the shadow distribution, and outputting the actual annual power generation. The specific calculation process of the lightweight power generation assessment model is as follows: S301. Based on the solar position parameters on the winter solstice and the geometric parameters of the obstacle, calculate the length and direction of the shadow cast by the obstacle on the horizontal plane.
[0044] ; ; ; In the formula, The length of the shadow cast by the obstacle on the horizontal plane; This represents the height of an obstacle; for each obstacle, it is simplified to having a certain height ( A vertical prism; The solar altitude angle; The latitude is obtained from a geographic database. The solar declination angle on the winter solstice is approximately -23.45°. For the hour angle, , True solar time; This is the solar azimuth angle.
[0045] The direction of a shadow, also known as the direction angle of the shadow ray, represents the direction in which the shadow extends on the horizontal plane. The direction of the shadow is opposite to the azimuth angle of the sun. Shadow direction = +180°.
[0046] S302. Calculate the shading area ratio of the photovoltaic panel based on the shadow length and shadow direction.
[0047] Specifically, the shadow offset vector is first calculated based on the shadow length and shadow direction. (The offset vector of the shadow on the horizontal plane), the algorithm is as follows: For each vertex of the polygon at the top of the obstacle, according to the shadow offset vector Translate the object to the ground (the z=0 plane), and connect the translated vertices in sequence to form the shadow polygon of the obstacle.
[0048] For the target photovoltaic panel, discretize it into a 10×10 grid. For each grid point, determine whether it falls within the shadow polygon of any obstacle. Let the number of obscured grid points be... ,but The occlusion area ratio at any given time is .
[0049] S303. Using the inclined plane irradiance calculation model and considering the shading area ratio, calculate the actual received irradiance of the photovoltaic panel. Specifically, obtain the total horizontal irradiance at various times from 9:00 to 15:00 on the winter solstice from the Typical Meteorological Year (TMY) database. and diffuse irradiance And convert it into the tilt angle of the photovoltaic panel. Azimuth angle of photovoltaic module arrangement Total irradiance of the inclined plane Then, by converting the shading area ratio, the actual received irradiance of the photovoltaic panel is obtained. .
[0050] ; ; ; ; ; In the formula, This refers to the actual irradiance received by the photovoltaic panel. This refers to the proportion of the area that is blocked. The total irradiance of the slope without shading; This refers to the direct irradiance on a horizontal plane. The total horizontal irradiance at various times from 9:00 to 15:00 on the winter solstice was obtained from a typical meteorological year database; The diffuse irradiance at various times from 9:00 to 15:00 on the winter solstice was obtained from a typical meteorological year database; The direct radiation tilt factor is used to convert the direct radiation intensity on a horizontal plane into the direct radiation intensity on a tilted photovoltaic panel. The tilt angle of the photovoltaic panels is determined by the roof slope. The ground reflectivity is preferably 0.2; The angle of incidence of sunlight onto the surface of the photovoltaic panel; The solar altitude angle; The azimuth of the sun; The azimuth angle for the arrangement of photovoltaic modules.
[0051] S304. Calculate the actual annual power generation based on the actual received irradiance. Specifically, the 13 times between 9:00 and 15:00 on the winter solstice are accumulated (with half an hour as a step) and extended to the whole year. Since the winter solstice is the typical day with the lowest solar altitude angle and the most severe shadow, it is assumed that the proportion of shading loss on other days of the year is the same as that on the winter solstice.
[0052] Specifically, actual annual power generation The calculation formula is as follows: ; ; In the formula, This represents the total actual annual power generation of the photovoltaic array. This refers to the number of photovoltaic panels in the current layout plan; Index for the number of photovoltaic panels; This represents the annual power generation of a single photovoltaic panel. This refers to the rated power of the photovoltaic panel. The comprehensive efficiency of the photovoltaic system is a comprehensive efficiency coefficient that includes temperature loss, inverter conversion efficiency, cable transmission loss, component matching loss and system miscellaneous losses. Its value ranges from 0.75 to 0.87. This simplification avoids temperature iteration and calculation of individual losses, with a very small amount of calculation and a very fast speed, making it suitable for a large number of iterative calculations in the optimization engine. This is a time index, corresponding to the calculation times from 9:00 to 15:00 on the winter solstice; This refers to the actual irradiance received by the photovoltaic panel. The time step is set to 0.5 hours in this embodiment; It represents the number of days in a year, which is 365 days.
[0053] In some feasible implementations, the objective function for the comprehensive cost takes into account the shading loss rate, bracket cost, and cable length cost. Specifically, the shading loss rate, bracket cost, and cable cost are combined, normalized, and then the normalized comprehensive cost is obtained. This normalized comprehensive cost is then subtracted from 1. The formula for calculating the objective function for the comprehensive cost is as follows: ; ; ; ; ; ; ; In the formula, The objective function is the comprehensive cost; This is the normalized overall cost; This is a combined value of shadow occlusion loss rate, bracket cost, and cable cost; The normalization factor is preferably 1.5 to ensure that most reasonable layout schemes are... It falls within the range of 0.5 to 1.2; The weighting coefficient for the shadow occlusion loss rate is preferably 1; This represents the total shadow occlusion loss rate; The weighting factor for stent cost is preferably 1; For stent cost; For reference, the cost of the brackets is taken when they are arranged according to the equal spacing rule (without any shadow avoidance); The weighting factor for cable cost is 1, preferably 1. For cable costs; For reference, the cable cost is taken when the cables are arranged according to the equal spacing rule (without any shadow avoidance); The comprehensive unit cost per length of cable (yuan / m), including cable and connector, is preferably 8; This refers to the number of photovoltaic panels; This refers to the available area of the roof.
[0054] In the formula, The preferred cost for single-board foundation installation is 50. The linear material cost per unit area is preferably 80; for; The nonlinear penalty coefficient for large-area photovoltaic panels is preferably 30; The non-linear threshold area is preferably 2.5. This preferred value is based on standard domestic market conditions, and users can adjust it according to their specific projects through the system interface. The bracket and installation cost of a single photovoltaic panel is calculated using a customized model that combines "basic cost + linear material cost + non-linear penalty term for large-area photovoltaic panels." When the photovoltaic panel area exceeds the threshold area... When additional costs increase quadratically, the cost can be more accurately reflected, avoiding the underestimation bias of linear models.
[0055] In the formula, Index for the number of photovoltaic panels; For time indexing; The total irradiance of the slope without shading; The shading loss rate of a single photovoltaic panel; This represents the percentage of the area that is obscured.
[0056] It should be noted that the cable cost is estimated using a simplified model. In a typical string layout, the total cable length is proportional to the square root of the number of photovoltaic panels and the square root of the roof size, which is a reasonable engineering approximation, and its rationality can be understood by those skilled in the art. In multi-objective optimization, the algorithm aims to maximize... Optimizing the direction is equivalent to minimizing the overall cost.
[0057] S4. Based on the objective function of installed capacity, annual power generation and comprehensive cost, perform fast non-dominated sorting and crowding distance calculation on the population.
[0058] Specifically, the NSGA-II (Non-Dominated Sorting Genetic Algorithm) framework is used to quickly sort the population using non-dominated sorting, resulting in Pareto front levels (Front1, Front2, Front3, etc.). Lower levels represent better overall performance of individuals. First, the dominance relationships between individuals are defined. Then, dominance relationships are determined through pairwise comparisons. Individuals not dominated by any individual are assigned to the first front (Front1) (i.e., non-dominated individuals that are not inferior to other solutions on multiple objectives are assigned to Front1). The dominated count is then updated layer by layer, and subsequent levels are defined until all individuals are classified. The final Pareto front output shows the trade-off curves between different objectives (e.g., "increasing capacity by 10% will lead to a 2% decrease in power generation"), providing a reference for user decision-making. For individuals within the same Pareto front, their crowding distance is calculated to measure the distribution density of individuals in the objective space, maintaining the diversity of the solution set and preventing premature convergence of the algorithm.
[0059] S5. Based on fast non-dominated sorting and crowding distance, select the parent population. Specifically, tournament selection is used, prioritizing individuals with low non-dominated levels and high crowding as the parent population.
[0060] S6. Perform crossover and mutation operations on the parent population to generate a new offspring population. Merge the parent and offspring populations to obtain an optimized population.
[0061] Specifically, simulated binary crossover is performed on the global variables of the parent population (PV array azimuth angle, row spacing, and column spacing), and multi-point crossover is performed on the local variables of the parent population. The control logic of simulated binary crossover is as follows: select parent individuals, calculate the expansion factor and perform weighted combination to generate offspring variables that satisfy engineering constraints. The control logic of multi-point crossover is as follows: use a multi-point rectangular crossover operator based on roof grid binary encoding, randomly select the intersection area between the parent array matrix and the rectangle (customizable), exchange and retain the excellent local layout pattern of the parent, generate offspring array schemes and repair infeasible solutions to achieve local optimization of the PV array.
[0062] Specifically, multinomial mutation is performed on the global variables of the parent population, while heuristic mutation is performed on the local variables of the parent population. Multinomial mutation (PM) achieves real-number encoding mutation operations by applying a multinomial distribution perturbation to the continuous variables of individuals with probability and performing boundary pruning, taking into account both global exploration and local search capabilities. The specific method of heuristic mutation in this embodiment is as follows: a set of photovoltaic panels located within 0.5m of the roof boundary or adjacent to obstacles (within 0.5m spacing) is selected; for the target photovoltaic panel, its azimuth angle is rotated ±90° (or adapted to local edge direction adjustment) with a preset probability (0.2); after rotation, the spacing constraints with neighboring panels and obstacles are rechecked, and if satisfied, the new direction is retained; otherwise, the original direction is restored. Compared with random rotation, heuristic mutation significantly reduces the number of invalid attempts.
[0063] S7. After iterative evolution to a preset number of generations (e.g., 200 generations), the optimal solution set is selected from the optimization population according to preset rules. Specifically, selection is made from the first frontier (Front1), typically outputting 3-5 representative solutions. Preset rules include: maximum power generation type ( The three objective functions are: highest, maximum capacity (f1 is the highest), and balanced (highest overall score, users can customize the weighting of the three objective functions).
[0064] S8. Users interact with the optimal solution set to obtain the final photovoltaic layout scheme.
[0065] In some feasible implementations, step S8 includes: S81. In response to the user's selection operation of the optimal solution set, load the data of the selected photovoltaic layout scheme into the photovoltaic layout editing canvas, and use the photovoltaic layout scheme as the current editing scheme.
[0066] S82. In response to the user's selection of the roof area and the locking command, identify the photovoltaic panels within the selected area and add them to the lock set. Locked photovoltaic panels become gray and semi-transparent on the interface and display a lock icon. The position, rotation, and existence of the locked panels remain unchanged during any subsequent automatic optimizations (such as clicking "Optimize Unlocked Area") or manual dragging (if configured to be non-draggable).
[0067] S83. Responding to the user's dragging operation on a single photovoltaic panel, the system verifies the spacing constraints of the dragged target position and moves the photovoltaic panel. Verifying spacing constraints means checking whether the dragged target position overlaps with other photovoltaic panels, roof boundaries, or obstacles, or whether the spacing is insufficient (according to photovoltaic layout specifications, the photovoltaic module layout spacing is preset). If a collision or insufficient spacing occurs, the system refuses to move and prompts the user; otherwise, the system accepts the target position. This significantly reduces the company's personnel training costs, freeing designers from tedious "brick-laying" work and improving the efficiency and quality of the overall design process.
[0068] S84. Using the geometric center point of the gap created by the movement of the photovoltaic panel as the center, a local area is defined, and the gaps of the unlocked photovoltaic panels within the local area are filled. This ensures that the solution after manual intervention can be quickly restored to the global optimal state, reducing the time for manual fine-tuning by the user (by 75%).
[0069] Specifically, it is executed according to the following logic: Determine the set of vacant positions: Take the original position of the photovoltaic panel before it is moved as the first vacant position, check whether there is an unlocked photovoltaic panel at the target position after it is moved. If there is, take the target position as the second vacant position, and add the first vacant position and / or the second vacant position to the set of vacant positions.
[0070] Delineate a local area: For each empty position in the set of empty positions, delineate a circular local area with the geometric center of the empty position as the center and a preset multiple of the photovoltaic panel spacing as the radius. Preferably, the preset multiple is 3 times.
[0071] Greedy filling: Starting from the geometric center of the current empty position, calculate the distance between all unlocked photovoltaic panels and the current empty position within the corresponding circular local area, select the closest unlocked photovoltaic panel, translate it to the current empty position, and add the original position of the moved photovoltaic panel as a new empty position to the empty position set.
[0072] Iterative execution: Repeatedly execute "define local area" and "greedy fill" until the set of empty positions is empty, or no unlocked photovoltaic panel can be found in the circular local area.
[0073] S85. Recalculate the power generation of the photovoltaic panels affected by drag operations and gap filling, and update the total power generation.
[0074] S86. Responding to the user's local optimization command, the system treats the photovoltaic panels within the locked set as fixed constraints and performs multi-objective optimization only on photovoltaic panels outside the locked set. Specifically, after the user clicks the "Optimize Unlocked Areas" button, the system extracts information (location, size, orientation) of all currently locked photovoltaic panels and uses it as fixed constraints. By retaining the parts that satisfy the user and avoiding global recalculation, the design iteration time is significantly reduced. This achieves human-machine collaborative partition optimization, utilizing both the algorithm's global search capability and respecting human experience.
[0075] In this embodiment, during steps S4, S5, and S6, a constraint domination strategy can also be simultaneously applied to the population. Specifically, this includes: ensuring that the outline of each photovoltaic panel is completely within the roof boundary; maintaining a distance between each photovoltaic panel and obstacles ≥ a first threshold (preferably 0.3m); maintaining a distance between adjacent photovoltaic panels ≥ a second threshold (preferably 0.02m); ensuring the photovoltaic module maintenance channel ≥ a third threshold (preferably 0.8m); and maintaining a distance between the photovoltaic panel and the roof edge ≥ a fourth threshold (preferably 0.5m). All of these constraints must be satisfied simultaneously. Based on the feasibility-first rule, during the non-dominated sorting process of multi-objective optimization, all individuals violating the constraints are prioritized lower than feasible individuals and are preferentially eliminated during population updates. This helps improve the proportion of feasible solutions in the population and the algorithm's convergence efficiency.
[0076] It is worth mentioning that this embodiment, through the synergistic effect of azimuth encoding, hybrid crossover operators, and hybrid mutation operators, completes the scanning and optimization of the orientation space of photovoltaic modules, realizing global azimuth scanning of the algorithm. Compared with traditional solutions, the installed capacity is increased by an average of 15% to 22%. Through adaptive orientation, the fragmented areas originally caused by bevel cutting are effectively utilized, maximizing the utilization of rooftop resources. This is especially suitable for photovoltaic renovation projects of old factories, irregular commercial roofs, and other buildings.
[0077] Example 2: Unlike Example 1, this approach uses the MOEA / D algorithm instead of the NSGA-II (Non-Dominated Sorting Genetic Algorithm) framework for multi-objective optimization. The multi-objective problem is decomposed into several single-objective sub-problems (each sub-problem corresponding to a set of weight vectors). By differentiating the weight vectors, the optimization focus of each sub-problem is clearly defined, and co-evolution is achieved through information exchange between adjacent sub-problems. This scheme converges faster when handling high-dimensional objectives (3 or more) and is easily parallelized. It is suitable for interactive scenarios requiring rapid response.
[0078] Example 3: Unlike Embodiment 1, this embodiment employs indirect encoding based on parameterized templates. Specifically, several advanced layout templates are pre-defined, primarily including standardized layout forms such as array along the long side (i.e., using the long side of the roof as the reference direction, with the array extending in a direction that conforms to the long side's trend), surrounding obstacles, and partitioned filling. Each layout template requires only a few parameters for control, with key control parameters including the starting coordinate point, layout direction angle, number of array rows, and number of array columns. In this embodiment, the layout template type and the corresponding control parameters for each template are used together as optimization variables for the algorithm.
[0079] This encoding method limits the scope of the search space through standardized templates, which greatly reduces the number of optimization variables, thereby reducing the search space dimension of the algorithm, reducing the amount of computation, and improving the solution efficiency. It is suitable for roof layout scenarios with regular shapes and boundaries.
[0080] Example 4: Unlike Example 1, the constraint domination strategy in this example employs backtracking repair based on the constraint satisfaction problem. Illegal solutions generated during the optimization process are treated as partially assigned constraint satisfaction problems. A backtracking search method (such as the minimum conflict heuristic) is used to adjust the arrangement of the illegal boards until all constraints are satisfied.
[0081] Based on the above-described preferred embodiments of the present invention, and through the foregoing description, those skilled in the art can make various changes and modifications without departing from the inventive concept. The technical scope of this invention is not limited to the contents of the specification, but must be determined according to the scope of the claims.
Claims
1. A method for intelligent rooftop photovoltaic (PV) deployment based on multi-objective optimization and interactive feedback, characterized in that, include: S1. Obtain building roof geometry data, photovoltaic module parameters, and user preference data; S2. Combining building roof geometry data, photovoltaic module parameters, and user preference data, a hybrid initialization strategy is adopted to initialize the population of candidate layout schemes; S3. Calculate the objective functions of installed capacity, annual power generation and comprehensive cost for each candidate layout scheme in the initialized population. S4. Based on the objective function of installed capacity, annual power generation and comprehensive cost, perform fast non-dominated sorting and crowding distance calculation on the population. S5. Based on fast non-dominated sorting and crowding distance, the parent population is selected; S6. Perform crossover and mutation operations on the parent population to generate a new offspring population. Merge the parent and offspring populations to obtain an optimized population. S7. Select the optimal solution set from the optimization population according to the preset rules; S8. Users interact with the optimal solution set to obtain the final photovoltaic layout scheme.
2. The rooftop photovoltaic intelligent layout method based on multi-objective optimization and interactive feedback as described in claim 1, characterized in that, The user preference data includes the search range of the azimuth angle of the layout, the search range of the layout spacing, and the target optimization weight tendency.
3. The rooftop photovoltaic intelligent layout method based on multi-objective optimization and interactive feedback as described in claim 1, characterized in that, Step S2 includes: S21. Randomly generate N candidate arrangement schemes; S22. Decompose each candidate arrangement scheme into global variables and local variables, and encode the global variables and local variables independently; S23. Generate a basic rule-based layout scheme based on the main direction of the roof and the minimum spacing specified in the code; S24. Perturb the parameters of the basic rule layout scheme to generate multiple variant layout schemes; S25. Merge the individuals of the randomly generated N candidate arrangement schemes, the basic rule arrangement schemes, and the variant arrangement schemes to obtain the initial population.
4. The rooftop photovoltaic intelligent layout method based on multi-objective optimization and interactive feedback as described in claim 1, characterized in that, The objective function for the annual power generation is calculated as follows: [Calculate the actual annual power generation...] and theoretical reference power generation By normalizing the ratio, we obtain the objective function for annual power generation. ; The actual annual power generation The calculation method is as follows: S301. Based on the solar position parameters on the winter solstice and the geometric parameters of the obstacle, calculate the shadow length and shadow direction of the obstacle on the horizontal plane; S302. Calculate the shading area ratio of the photovoltaic panel based on the shadow length and shadow direction; S303. Calculate the actual received irradiance of the photovoltaic panel by using the inclined plane irradiance calculation model and combining the shading area ratio. S304. Calculate the actual annual power generation based on the actual received irradiance. .
5. The rooftop photovoltaic intelligent layout method based on multi-objective optimization and interactive feedback as described in claim 1, characterized in that, The objective function for the comprehensive cost is calculated as follows: the shadow occlusion loss rate, bracket cost, and cable cost are combined and normalized to obtain the normalized comprehensive cost, and then the normalized comprehensive cost is subtracted from 1. The formula for calculating the cost of the stent is as follows: ; in, For stent cost; This refers to the number of photovoltaic panels; The cost is for the basic installation of a single photovoltaic panel; Linear material cost per unit area; For large-area photovoltaic panels, the nonlinear penalty coefficient is used. This refers to the area of a single photovoltaic panel; The threshold area.
6. The rooftop photovoltaic intelligent layout method based on multi-objective optimization and interactive feedback as described in claim 1, characterized in that, The hybrid cross includes: Simulated binary crossover is performed on the global variables of the parent population, and multi-point crossover is performed on the local variables of the parent population.
7. The rooftop photovoltaic intelligent layout method based on multi-objective optimization and interactive feedback as described in claim 1, characterized in that, The hybrid variants include: Perform polynomial mutation on the global variables of the parent population, and perform heuristic mutation on the local variables of the parent population.
8. The rooftop photovoltaic intelligent layout method based on multi-objective optimization and interactive feedback according to claim 1, characterized in that, Step S8 includes: S81. In response to the user's selection operation of the optimal solution set, load the data of the selected photovoltaic layout scheme into the photovoltaic layout editing canvas; S82, In response to the user's selection operation and locking command in the roof area, identify the photovoltaic panels in the selected area and add them to the locking set; S83. In response to the user's drag operation on a single photovoltaic panel, verify the spacing constraints of the drag target position and move the photovoltaic panel. S84. Using the geometric center point of the gap created after the photovoltaic panel is moved as the center, delineate a local area, and perform a gap filling operation on the unlocked photovoltaic panels in the local area. S85. Recalculate the power generation of the photovoltaic panels affected by drag operations and gap filling, and update the total power generation; S86. In response to the user's local optimization instruction, the photovoltaic panels within the locked set are treated as fixed constraints, and multi-objective optimization is performed only on photovoltaic panels outside the locked set.
9. The rooftop photovoltaic intelligent layout method based on multi-objective optimization and interactive feedback as described in claim 8, characterized in that, The method for filling the gap includes: Starting from the geometric center of the empty position, search for the nearest photovoltaic panel to be adjusted in a spiral order, and move the nearest photovoltaic panel to the empty position; repeat the above steps until all empty positions in the local area are filled or there are no unlocked photovoltaic panels to be adjusted.
10. The rooftop photovoltaic intelligent layout method based on multi-objective optimization and interactive feedback according to claim 1, characterized in that, Also includes: During steps S4, S5 and S6, a constraint domination strategy is simultaneously applied to the population. The constraint control strategy includes: controlling the outline of each photovoltaic panel to be completely within the roof boundary; the distance between each photovoltaic panel and obstacles ≥ a first threshold; the distance between adjacent photovoltaic panels ≥ a second threshold; the photovoltaic module maintenance channel ≥ a third threshold; and the distance between the photovoltaic panel and the roof edge ≥ a fourth threshold.