An acceleration algorithm and device for photovoltaic hydrogen production capacity configuration optimization system

By establishing a two-layer optimization model for photovoltaic hydrogen production systems and combining it with GPU parallelism and parallel computing acceleration algorithms, the problem of high computational complexity in traditional photovoltaic hydrogen production optimization methods is solved, and efficient capacity configuration optimization of photovoltaic hydrogen production systems is achieved.

CN119382242BActive Publication Date: 2025-11-28HARBIN INST OF TECH
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411478225.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-10-22
Publication Date
2025-11-28
Estimated Expiration
2044-10-22

AI Technical Summary

Technical Problem

Traditional photovoltaic hydrogen production optimization methods have high computational complexity and long solution time. Existing acceleration algorithms cannot effectively optimize the capacity configuration of photovoltaic hydrogen production systems, resulting in insufficient economic efficiency and reliability.

Method used

A hybrid optimization algorithm combining differential particle swarm optimization and linear programming is adopted to optimize the capacity configuration of the photovoltaic hydrogen production system by establishing a two-layer optimization model and combining GPU parallelism and parallel computing acceleration algorithms.

Benefits of technology

It effectively reduces algorithm runtime, improves capacity configuration optimization efficiency, and makes optimization results more comprehensive and representative, meeting the economic and reliability requirements of photovoltaic hydrogen production systems.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119382242B_ABST
    Figure CN119382242B_ABST
Patent Text Reader

Abstract

The application discloses an acceleration algorithm and device for a photovoltaic hydrogen production capacity configuration optimization system, and comprises the following steps: a double-layer optimization model of a photovoltaic hydrogen production system is established, an upper-layer model of the double-layer optimization model takes the minimum unit hydrogen production cost in a whole life cycle as an upper-layer objective function, and a lower-layer model takes the minimum abandoned electricity rate as a lower-layer objective function; the photovoltaic hydrogen production system at least comprises a photovoltaic power generation system, a proton exchange membrane (PEM) electrolysis hydrogen production system, an alkaline electrolysis hydrogen production system, an energy storage battery and a hydrogen storage tank; the double-layer optimization model is solved to obtain the optimal capacity configuration of the photovoltaic hydrogen production system; wherein, the upper-layer model is solved by using a differential particle swarm hybrid optimization acceleration algorithm, and the lower-layer model is solved by using a linear programming problem solving method. Through a series of acceleration algorithms based on an original algorithm, the algorithm running time of the photovoltaic hydrogen production capacity configuration optimization system can be effectively reduced, and the capacity configuration optimization efficiency is improved.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of photovoltaic hydrogen production, in particular to an acceleration algorithm and device for a photovoltaic hydrogen production capacity configuration optimization system. BACKGROUND

[0002] With the growth of global energy demand and environmental pressure, the promotion of clean energy becomes increasingly important. Photovoltaic hydrogen production technology, which combines photovoltaic power generation technology and hydrogen production technology, can provide clean energy with high energy density. However, due to the instability of solar energy and wind energy, photovoltaic power generation is intermittent and volatile. In order to ensure the economy and reliability of photovoltaic hydrogen production, the system capacity configuration needs to be optimized.

[0003] However, traditional photovoltaic hydrogen production optimization methods such as linear programming, nonlinear programming, and dynamic programming are difficult to meet actual needs due to high computational complexity and long solution time. Existing acceleration algorithms in the field are mostly small-scale optimizations based on original algorithms, such as using crossover, mutation, and prediction methods, which cannot derive more suitable acceleration algorithms for current scenarios. SUMMARY

[0004] Therefore, the embodiments of the present application provide an acceleration algorithm and device for a photovoltaic hydrogen production capacity configuration optimization system, which improves the capacity configuration optimization efficiency by optimizing the algorithm during the capacity configuration optimization process.

[0005] The technical solutions provided by the embodiments of the present application are as follows:

[0006] A photovoltaic hydrogen production capacity configuration optimization method, comprising:

[0007] establishing a double-layer optimization model of a photovoltaic hydrogen production system, wherein the upper model of the double-layer optimization model takes the minimum unit hydrogen production cost of the whole life cycle as the upper objective function, and the lower model takes the minimum curtailment rate as the lower objective function; the photovoltaic hydrogen production system at least includes a photovoltaic power generation system, a proton exchange membrane (PEM) electrolysis hydrogen production system, an alkaline electrolysis hydrogen production system, an energy storage battery, and a hydrogen storage tank;

[0008] solving the double-layer optimization model to obtain the optimal capacity configuration of the photovoltaic hydrogen production system; wherein the upper model is solved by using a differential particle swarm hybrid optimization algorithm, and the lower model is solved by using a linear programming problem solving method; the differential particle swarm hybrid optimization algorithm is solved by using one of the following three acceleration algorithms:

[0009] Acceleration algorithm one: improved differential particle swarm hybrid optimization algorithm with reduced iteration graph output, short pause for updating graphics, vectorization operation, and simplified position and speed restriction processing;

[0010] The second acceleration algorithm is an optimization algorithm combined with GPU parallelism based on the first acceleration algorithm.

[0011] The third acceleration algorithm is an optimization algorithm combined with parallel computation based on the first acceleration algorithm.

[0012] An acceleration device for a photovoltaic hydrogen production capacity configuration optimization system, comprising:

[0013] A model establishing module is configured to establish a double-layer optimization model of a photovoltaic hydrogen production system, wherein an upper-layer model of the double-layer optimization model takes the minimum unit hydrogen production cost in a full life cycle as an upper-layer objective function, and a lower-layer model takes the minimum electricity rejection rate as a lower-layer objective function; the photovoltaic hydrogen production system at least includes a photovoltaic power generation system, a proton exchange membrane (PEM) electrolysis hydrogen production system, an alkaline electrolysis hydrogen production system, an energy storage battery, and a hydrogen storage tank.

[0014] A model solving module is configured to solve the double-layer optimization model to obtain an optimal capacity configuration of the photovoltaic hydrogen production system; wherein the upper-layer model is solved by using a differential particle swarm hybrid optimization algorithm, and the lower-layer model is solved by using a linear programming problem solving method; the differential particle swarm hybrid optimization algorithm includes one of the following three acceleration algorithms:

[0015] The first acceleration algorithm is an improved differential particle swarm hybrid optimization algorithm that reduces iteration graph output, temporarily pauses to update graphics, uses vectorization operation, and simplifies position and speed restriction processing.

[0016] The second acceleration algorithm is an optimization algorithm combined with GPU parallelism based on the first acceleration algorithm.

[0017] The third acceleration algorithm is an optimization algorithm combined with parallel computation based on the first acceleration algorithm.

[0018] As can be seen from the above solutions, the double-layer optimization model of the photovoltaic hydrogen production system is established, the objective functions of the upper-layer model and the lower-layer model in the double-layer optimization model are designed respectively, and the differential particle swarm hybrid optimization acceleration algorithm and the linear programming problem solving method are used to solve the upper-layer model and the lower-layer model respectively to obtain the optimal capacity configuration of the photovoltaic hydrogen production system. It can be seen that the algorithm optimization is performed in the capacity configuration optimization process, the algorithm running time is effectively reduced, and the capacity configuration optimization efficiency is improved; and the improved differential particle swarm hybrid optimization algorithm that reduces iteration graph output, temporarily pauses to update graphics, uses vectorization form, and simplifies position and speed restriction processing is used in combination with parallel computation, which is not simply limited to the small point optimization of the heuristic algorithm, so that the optimization result is more extensive and representative. BRIEF DESCRIPTION OF DRAWINGS

[0019] Figure 1is a flow chart of a photovoltaic hydrogen production capacity configuration optimization method provided by an embodiment of the present application.

[0020] Figure 2 is a flow chart of a solution of a double-layer optimization model of a photovoltaic hydrogen production system provided by an embodiment of the present application. DETAILED DESCRIPTION

[0021] In order to make the objects, technical solutions and advantages of the present application clearer, the specific embodiments of the present application are described in detail below with reference to the accompanying drawings. The examples of these preferred embodiments are illustrated in the accompanying drawings. The embodiments of the present application shown in the accompanying drawings and described according to the accompanying drawings are merely exemplary, and the present application is not limited to these embodiments.

[0022] Here, it also needs to be noted that, in order to avoid obscuring the focus of the present application due to unnecessary details, in the accompanying drawings, mainly the structures and / or processing steps closely related to the scheme according to the present application are shown, and part of other details not closely related to the present application are omitted.

[0023] The technical solutions in the embodiments of the present application are described in detail below.

[0024] An acceleration algorithm for a photovoltaic hydrogen production capacity configuration optimization system is provided by an embodiment of the present application, as shown in Figure 1 The acceleration algorithm includes the following steps:

[0025] Step 101, a double-layer optimization model of a photovoltaic hydrogen production system is established, the upper-layer model of the double-layer optimization model takes the minimum unit hydrogen production cost in the whole life cycle as an upper-layer objective function, and the lower-layer model takes the minimum abandoned electricity rate as a lower-layer objective function.

[0026] In an embodiment, the photovoltaic hydrogen production system at least includes a photovoltaic power generation system, a proton exchange membrane (PEM) electrolysis hydrogen production system, an alkaline electrolysis hydrogen production system, an energy storage battery and a hydrogen storage tank. The photovoltaic power generation system can include a photovoltaic array, the PEM electrolysis hydrogen production system can include a PEM electrolysis tank, and the alkaline electrolysis hydrogen production system can include an alkaline electrolysis tank.

[0027] In an embodiment, the photovoltaic output data of the photovoltaic hydrogen production system in a preset time can be clustered, and one photovoltaic output scene is obtained according to each type of photovoltaic output data, so as to perform corresponding system optimization for different photovoltaic output scenes.

[0028] The photovoltaic output data generally refers to the data of the electric energy generated by the photovoltaic power generation system in a certain time, including but not limited to irradiance, ambient temperature, wind speed, humidity, cloud cover, sunshine time, theoretical power and actual power. In an example, the photovoltaic output data can be collected by a preset collection device, and the collected data can be summarized and processed for clustering.

[0029] In an example, the output power of the photovoltaic hydrogen production system can be calculated according to the temperature and the solar irradiance, and the output power can be further used as the photovoltaic output data. Specifically, the output power of the photovoltaic hydrogen production system can be calculated by formula (1):

[0030]

[0031] wherein, P PV represents the output power of the photovoltaic power generation system, and the unit is kW; P PV,rated represents the rated power of the photovoltaic power generation system, and the unit is kW; f represents the power generation efficiency of the photovoltaic power generation system, which is selected according to the actual situation, and 0.9 is taken in the embodiment; δ represents the temperature coefficient, which is generally taken as -0.47% / K; G and Gs represent the actual solar irradiance and the reference irradiance, and the unit is W / m 2 ; T and Ts represent the actual working temperature and the reference temperature, and the unit is K.

[0032] In an example, the existing clustering algorithm in the art can be used for data clustering. For example, the K-means algorithm can be used for clustering.

[0033] In an example, the photovoltaic output data of the whole year can be clustered to obtain the number of days of each photovoltaic scene. For example, if the K-means algorithm is used to cluster the photovoltaic output data, six clustering results are obtained, which correspond to six photovoltaic output scenes, and the number of days of each photovoltaic scene can be further counted. In a specific example, the number of days of the six photovoltaic scenes in the whole year is: 127 days, 86 days, 32 days, 32 days, 66 days and 22 days.

[0034] Before the double-layer optimization model of the photovoltaic hydrogen production system is established, in an embodiment, the hydrogen production model of the photovoltaic hydrogen production system is established according to the physical structure of the photovoltaic hydrogen production system and the efficiency characteristics. Specifically, the hydrogen production rate formula of the photovoltaic hydrogen production system is as follows:

[0035]

[0036]

[0037]

[0038] wherein, represents the hydrogen consumption power of the unit, in kWh / Nm 3 ; η el,ALK , η el,PEM , η el,Eb respectively represent the electrolysis efficiencies of the alkaline electrolytic hydrogen production system, the PEM electrolytic hydrogen production system and the energy storage battery; P ALK , P PEM , P Eb respectively represent the input powers of the alkaline electrolytic hydrogen production system, the PEM electrolytic hydrogen production system and the energy storage battery, in kW; respectively represent the hydrogen production rates of the alkaline electrolytic hydrogen production system, the PEM electrolytic hydrogen production system and the energy storage battery.

[0039] Regarding the double-layer optimization model established in this step 101, in an embodiment, the upper-layer objective function formula is as follows:

[0040]

[0041] wherein, C ALK represents the total life cycle cost of the alkaline electrolytic hydrogen production system, in yuan; C PEM represents the total life cycle cost of the PEM electrolytic hydrogen production system, in yuan; C Eb represents the total life cycle cost of the energy storage battery, in yuan; C Eh represents the total life cycle cost of the hydrogen storage tank, in yuan; C LOSE represents the penalty cost of abandoned electricity, in yuan; Q H2 represents the total hydrogen production amount of the system in the whole life cycle, in Nm 3 .

[0042] In an embodiment, the lower-layer objective function formula in this step 102 is as follows:

[0043]

[0044] wherein, P ALK (t) represents the input power of the alkaline electrolytic hydrogen production system at time t, in kW; P PEM (t) represents the input power of the PEM electrolytic hydrogen production system at time t, in kW; P PV (t) represents the output power of the photovoltaic power generation system at time t, in kW.

[0045] It should be noted that the specific upper-layer objective function and lower-layer objective function formulas given above are only examples, and those skilled in the art can make several changes without departing from the principles of the present application, which should all be considered as the protection scope of the present application.

[0046] Solving the double-layer optimization model to obtain the optimal capacity configuration of the photovoltaic hydrogen production system; wherein the upper model is solved by using a differential particle swarm hybrid optimization algorithm, and the lower model is solved by using a linear programming problem solving method.

[0047] In one embodiment, when solving the double-layer optimization model in this step 102, the upper model is solved by using a differential particle swarm hybrid optimization algorithm, which is a hybrid algorithm of differential evolution algorithm and particle swarm algorithm.

[0048] In some embodiments, when solving by using a differential particle swarm hybrid optimization algorithm, the following three acceleration algorithms can be used to improve the operation speed:

[0049] Acceleration algorithm one: improved differential particle swarm hybrid optimization algorithm with reduced iteration figure output, short pause to update the figure, vectorization operation, and simplified position and speed limit processing. This optimization algorithm can reduce the number of loops and the time consumption caused by drawing operations.

[0050] The above acceleration algorithm one includes four parts of design: "reduced iteration figure output", "short pause to update the figure", "vectorization operation", and "simplified position and speed limit processing". Each part can reduce the operation time consumption and improve the operation speed. Specifically, the running time can be reduced in the following ways: adding a command in the algorithm to output an iteration figure once every several iterations (such as five times) to reduce the iteration figure output; replacing the original stop with a short pause to update the figure, which can effectively reduce the time consumption; using vectorization operation to effectively reduce the number of loops; using max and min functions to process the speed and position at one time to simplify the position and speed limit processing.

[0051] Acceleration algorithm two: combining the optimization algorithm of GPU parallel on the basis of acceleration algorithm one. This optimization algorithm can reduce the time consumption of the iteration task process to the greatest extent.

[0052] Specifically, acceleration algorithm two can package and transmit all data to the GPU end in the initial stage, update the population, calculate the fitness, and perform kernel processing of all iteration tasks only once. Only one data memory copy is needed before and after the algorithm parallel, and when drawing the fitness change figure, it is moved from GPU to CPU, which maximally reduces the time consumption of the process.

[0053] Acceleration algorithm three: combining the optimization algorithm of parallel calculation on the basis of acceleration algorithm one. This optimization algorithm can further speed up the calculation.

[0054] Specifically, the third acceleration algorithm can divide the calculation task into multiple parts and execute on multiple processors or computing cores to speed up the calculation, while checking whether the parallel computing pool has been opened after emptying the environment, and then using parallel computing to calculate the fitness value.

[0055] In one embodiment, the above three acceleration algorithms can be compared in advance, and finally the acceleration algorithm with the shortest running time, smaller fluctuation and faster and more stable convergence speed is selected as the optimal algorithm for capacity configuration of the photovoltaic hydrogen production system.

[0056] In one specific example, through comparison of running time, the third acceleration algorithm is finally selected for capacity configuration. By using the improved differential particle swarm hybrid optimization algorithm with reduced iteration graph output, temporary pause for updating the graph, vectorized form, and simplified position and speed restriction processing, and combining parallel computing, the optimization result is more extensive and representative, not simply limited to the small point optimization of heuristic algorithm.

[0057] In one embodiment, when solving the double-layer optimization model in this step 102, a linear programming problem solving method can be used for solving. Specifically, a mathematical optimization solver capable of solving linear programming problems can be used for solving. In one example, the lower layer model belongs to mixed integer linear programming, and existing optimization solving methods for mixed integer linear programming can be used for solving. For example, the CPLEX solver can be called through the YALMIP tool package of MATLAB for optimization solving.

[0058] In one embodiment, the upper layer constraint condition of the upper layer model includes the equipment capacity constraint, and the equipment capacity constraint formula is as follows:

[0059] P ALK,rated +P PEM,rated +P Eb,rated ≤P PV,rated (7)

[0060] P ALK,rated ≥0(8)

[0061] P PEM,rated ≥0(9)

[0062] P Eb,rated ≥0(10)

[0063] Wherein, P ALK,rated represents the capacity of the alkaline electrolysis hydrogen production system, with the unit of kW; P PEM,rated represents the capacity of the PEM electrolysis hydrogen production system, with the unit of kW; P Eb,rated represents the capacity of the energy storage battery, with the unit of kW.

[0064] In one embodiment, the lower-layer constraints of the lower-layer model include system power balance constraints, which are formulated as follows:

[0065] P ALK +P PEM +P l = P PV (11)

[0066] P ALK ≥ 0 (12)

[0067] P PEM ≥ 0 (13)

[0068] where P l represents the curtailed power.

[0069] In one embodiment, the lower-layer constraints of the lower-layer model include operating load range constraints, which are formulated as follows:

[0070]

[0071]

[0072]

[0073]

[0074] where, represents the minimum operable load of the alkaline electrolysis hydrogen production system; represents the maximum operable load of the alkaline electrolysis hydrogen production system; represents the minimum operable load of the PEM electrolysis hydrogen production system; represents the maximum operable load of the PEM electrolysis hydrogen production system; represents the minimum operable load of the energy storage battery; represents the maximum operable load of the energy storage battery; represents the minimum operable load of the hydrogen storage tank; represents the maximum operable load of the hydrogen storage tank; P Eh represents the input power of the hydrogen storage tank, in kW; P Eh,rated represents the capacity of the hydrogen storage tank, in kW.

[0075] In one embodiment, the lower-layer constraints of the lower-layer model include electrolyzer ramping constraints, which are formulated as follows:

[0076] -d ALK x P ALK,rated ≤ P ALK (t) - P ALK (t - 1) ≤ uALK xP ALK,rated (18)

[0077] -d PEM xP PEM,rated ≤P PEM (t)-P PEM (t-1)≤u PEM xP PEM,rated (19)

[0078] wherein, d ALK represents the maximum unloading rate allowed by the alkaline electrolysis hydrogen production system; u ALK represents the maximum loading rate allowed by the alkaline electrolysis hydrogen production system; d PEM represents the maximum unloading rate allowed by the PEM electrolysis hydrogen production system; u PEM represents the maximum loading rate allowed by the PEM electrolysis hydrogen production system.

[0079] In one embodiment, the lower-layer constraint condition of the lower-layer model includes an electrolytic cell hydrogen production efficiency constraint, and the electrolytic cell hydrogen production efficiency constraint condition is as follows:

[0080]

[0081]

[0082] In one embodiment, the lower-layer constraint condition of the lower-layer model includes a storage battery and hydrogen storage tank constraint, and the storage battery and hydrogen storage tank constraint condition is as follows:

[0083]

[0084]

[0085] P Eb ≥ 0 (24)

[0086] P Eh ≥ 0 (25)

[0087] wherein, d Eb represents the maximum unloading rate allowed by the storage battery; u Eb represents the maximum loading rate allowed by the storage battery; d Eh represents the maximum unloading rate allowed by the hydrogen storage tank; u Eh represents the maximum loading rate allowed by the hydrogen storage tank; P Eb,ch represents the charging power of the storage battery, in units of kW; P Eb,dis represents the discharging power of the storage battery, in units of kW; P Eh,ch represents the charging power of the hydrogen storage tank, in units of kW; P Eh,dis represents the discharging power of the hydrogen storage tank, in units of kW.

[0088] In one embodiment, the lower-layer constraints of the lower-layer model include at least one of the system power balance constraint, the operating load range constraint, the electrolytic cell ramping constraint, the electrolytic cell hydrogen production efficiency constraint, and the energy storage battery and hydrogen storage tank constraint described above.

[0089] It should be noted that the specific constraint formulas of the upper-layer model and the lower-layer model given above are only examples, and those skilled in the art can make several changes without departing from the principles of the present application, which should be considered as the protection scope of the present application.

[0090] At this point, the description of the flow of Figure 1 is completed. Through the flow of Figure 1 , algorithm optimization can be performed in the capacity configuration optimization process, effectively reducing algorithm running time and improving capacity configuration optimization efficiency. In some embodiments, the improved differential particle swarm hybrid optimization algorithm is adopted by reducing iteration graph output, temporarily pausing to update the graph, vectorization form, and simplifying position and speed restrictions, and combined with parallel computing, not simply limited to small point optimization of heuristic algorithms, making the optimization result more extensive and representative.

[0091] The following Figure 2 will describe in detail how to solve the double-layer optimization model of the photovoltaic hydrogen production system to obtain the optimal capacity configuration of the photovoltaic hydrogen production system.

[0092] Figure 2 The present application embodiment provides a flowchart of solving a double-layer optimization model of a photovoltaic hydrogen production system.

[0093] As shown in Figure 2 , the flow includes the following steps:

[0094] Step 201, randomly initializing the position and speed of each particle in the population.

[0095] Specifically, this step 201 includes setting the device capacity of the photovoltaic hydrogen production system under the current calculation, and passing the device capacity parameter into the lower-layer model.

[0096] Step 202, parameter setting for the lower-layer model.

[0097] Specifically, the parameter setting here includes at least the setting of the device capacity parameter and the photovoltaic typical day output data. The photovoltaic typical day output data can be determined with reference to the photovoltaic output scene.

[0098] Step 203, setting lower-layer constraints for the lower-layer model.

[0099] The lower-layer model here has been pre-constructed, and the lower-layer model takes the minimum power abandonment rate as the objective function.

[0100] The lower constraint condition can be at least one of the system power balance constraint, the operating load range constraint, the electrolytic cell climbing constraint, the electrolytic cell hydrogen production efficiency constraint, and the energy storage battery and hydrogen storage tank constraint of the above example.

[0101] In step 204, CPLEX is called to optimize and solve the lower model, to obtain the optimal operating power of the alkaline electrolytic hydrogen production system and the PEM electrolytic hydrogen production system at each time, and return the optimal operating power to the upper model.

[0102] In step 205, the upper model takes the minimum unit hydrogen production cost in the whole life cycle as the upper objective function, calculates the individual fitness value of the population particle, and updates the population particle.

[0103] In step 206, if the maximum number of iterations is reached, the iteration is stopped, and the optimal capacity configuration of the photovoltaic hydrogen production system is output; otherwise, step 202 is returned to be executed.

[0104] For the convenience of understanding Figure 2 The flowchart shown, the differential particle swarm hybrid optimization algorithm adopted in the present application will be briefly described. The differential particle swarm hybrid optimization algorithm (DPSO) is based on the particle swarm algorithm, and introduces mutation and crossover operation in the differential evolution algorithm to update the speed and position of the particle. A group of random particles are initialized, and then the optimal solution is found through iteration. In each iteration, the particle updates itself by tracking the individual optimal point of the particle itself and the global optimal point of the population. Suppose that in a D-dimensional target search space, there are N particles to form a colony, and the position of the i-th particle is represented as a D-dimensional vector:

[0105] X i =(x i1 ,x i2 ,…,x iD ),i=1,2,…,N

[0106] The speed of the i-th particle is also a D-dimensional vector:

[0107] V i =(v i1 ,v i2 ,…,v iD ),i=1,2,…,N

[0108] The optimal position searched by the i-th particle so far is called the individual extreme value:

[0109] P best =(p i1 ,p i2 ,…,p iD ),i=1,2,…,N

[0110] The best position found by the whole population so far is a global extremum:

[0111] g best = (p g1 , p g2 ,..., p gD )

[0112] For each particle, its d-dimensional velocity value and position value are updated according to the following equations:

[0113]

[0114]

[0115] where ω represents the inertia weight; c1, c2 represent the learning factors; r1, r2 represent random uniform numbers in the range of [0, 1].

[0116] In one embodiment, the inertia weight ω is expressed as follows:

[0117]

[0118] ω = ω max , f > f avg (29)

[0119] where ω min , ω max represent the minimum and maximum values of the inertia weight; f represents the real-time fitness value of the particle; f avg , f min represent the average fitness value and the minimum fitness value of all particles at present.

[0120] In one embodiment, the position update formula of the particle is:

[0121] u ij = x r1,j + F(x r2,j - x r3,j ), rand < C R (30)

[0122] u ij = x r1,j , rand > C R (31)

[0123] where x r1,j , x r2,j , x r3,j represent three random individuals of the current population; F represents the scaling factor; C R represents the crossover probability.

[0124] In some embodiments, when selecting the optimization mode acceleration algorithm, three different optimization mode acceleration algorithms can be used, respectively: an improved differential particle swarm hybrid optimization algorithm that reduces iteration graph output, temporarily pauses to update the graph, uses vectorized operations, and simplifies the position and speed restriction processing is used for iterative cruise solution, thereby reducing the number of loops and the time consumption caused by the drawing operation; an optimization algorithm that combines GPU parallelism on the basis of the first optimization is used to minimize the time consumption of the iteration task process; an optimization algorithm that combines parallel computing on the basis of the first optimization is used to speed up the calculation. By comparing the three optimization mode acceleration algorithms, the optimization mode acceleration algorithm with the least running time, smaller fluctuations, faster and more stable convergence speed is finally selected as the optimal algorithm for capacity configuration. After comparison, the third algorithm is finally selected for capacity configuration. By using the improved differential particle swarm hybrid optimization algorithm that reduces iteration graph output, temporarily pauses to update the graph, uses vectorized form, and simplifies the position and speed restriction processing, and combining parallel computing, the optimization result is not simply limited to the small point optimization of the heuristic algorithm, and the optimization result is more extensive and representative.

[0125] In some embodiments, after step 206 completes the iteration, a sensitivity and economic analysis of the optimized configuration scheme of the photovoltaic hydrogen production system can also be performed to provide theoretical and scientific guidance for the configuration, construction and development of the renewable energy photovoltaic hydrogen production system.

[0126] At this point, the description of the flowchart shown in Figure 2 is completed.

[0127] Through the flowchart shown in Figure 2 , compared with the prior art, the solving speed of the optimization model can be effectively improved, thereby improving the capacity configuration efficiency.

[0128] In one embodiment, an acceleration device for a photovoltaic hydrogen production capacity configuration optimization system is provided, comprising:

[0129] A model establishment module is configured to establish a double-layer optimization model of a photovoltaic hydrogen production system, wherein an upper model of the double-layer optimization model takes the minimum unit hydrogen production cost in the whole life cycle as an upper objective function, and a lower model takes the minimum curtailment rate as a lower objective function; the photovoltaic hydrogen production system at least includes a photovoltaic power generation system, a proton exchange membrane (PEM) electrolysis hydrogen production system, an alkaline electrolysis hydrogen production system, an energy storage battery, and a hydrogen storage tank;

[0130] A model solving module is configured to solve the double-layer optimization model to obtain the optimal capacity configuration of the photovoltaic hydrogen production system; wherein the upper model is solved by using a differential particle swarm hybrid optimization algorithm, and the lower model is solved by using a linear programming problem solving method; the differential particle swarm hybrid optimization algorithm includes one of the following three acceleration algorithms:

[0131] Acceleration algorithm one: improved differential particle swarm hybrid optimization algorithm with reduced iteration graph output, short pause to update graphics, vectorization operation, and simplified position and speed limit processing;

[0132] Acceleration algorithm two: optimization algorithm combining GPU parallelism on the basis of acceleration algorithm one;

[0133] Acceleration algorithm three: optimization algorithm combining parallel computing on the basis of acceleration algorithm one.

[0134] The implementation processes of the functions and roles of the various modules in the above device are specifically described in the implementation processes of the corresponding steps in the above method, and will not be described here.

[0135] In the description of the present specification, the description of the terms "one embodiment", "some embodiments", "an example", "a specific example", or "some examples" and the like means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are contained in at least one embodiment or example of the present application. In the present specification, the illustrative description of the above terms does not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described can be combined in any appropriate manner in any one or more embodiments or examples. Furthermore, different embodiments or examples described in the present specification and the features of different embodiments or examples can be combined and combined by those skilled in the art without contradiction.

[0136] Although the embodiments of the present application have been shown and described above, it can be understood that the above embodiments are exemplary and cannot be understood as limiting the present application, and those skilled in the art can make changes, modifications, replacements and variations to the above embodiments within the scope of the present application.

Claims

1. An acceleration algorithm for a photovoltaic hydrogen production capacity configuration optimization system, characterized in that, include: A two-layer optimization model for a photovoltaic hydrogen production system is established. The upper-layer model takes the minimum unit hydrogen production cost over the entire life cycle as its objective function, while the lower-layer model takes the minimum curtailment rate as its objective function. The photovoltaic hydrogen production system includes at least a photovoltaic power generation system, a proton exchange membrane (PEM) electrolysis hydrogen production system, an alkaline electrolysis hydrogen production system, an energy storage battery, and a hydrogen storage tank. The optimal capacity configuration of the photovoltaic hydrogen production system is obtained by solving the two-layer optimization model; wherein, the upper-layer model is solved using a differential particle swarm optimization algorithm, and the lower-layer model is solved using a linear programming problem-solving method; the differential particle swarm optimization algorithm includes using one of the following three acceleration algorithms: Acceleration Algorithm 1: An improved differential particle swarm optimization algorithm that reduces iterative graph output, briefly pauses to update the graph, employs vectorized operations, and simplifies the handling of position and velocity constraints; Acceleration Algorithm 2: Based on Acceleration Algorithm 1, it combines GPU parallel optimization algorithms; Acceleration Algorithm 3: Based on Acceleration Algorithm 1, it combines parallel computing optimization algorithms; The step of solving the two-layer optimization model to obtain the optimal capacity configuration of the photovoltaic hydrogen production system includes: Set the equipment capacity parameters of the photovoltaic hydrogen production system for the current calculation, and pass the equipment capacity parameters into the lower-level model; The lower-level model is configured with parameters, which include at least equipment capacity parameters and typical daily output data of photovoltaic power. The lower-level model is optimized by calling CPLEX to obtain the optimal operating power of the alkaline electrolysis hydrogen production system and the PEM electrolysis hydrogen production system at each time, and the optimal operating power is returned to the upper-level model. The upper-level model takes the minimum unit hydrogen production cost over the entire life cycle as the upper-level objective function, calculates the individual fitness value of the population particles, and updates the population particles. If the maximum number of iterations is reached, stop the iteration and output the optimal capacity configuration of the photovoltaic hydrogen production system; otherwise, return to execute the parameter setting of the lower-level model. The formula for the upper-level objective function is as follows: ; in, The total lifecycle cost of an alkaline electrolysis hydrogen production system is expressed in yuan. The total lifecycle cost of a PEM electrolysis hydrogen production system is expressed in yuan. This represents the total cost of energy storage batteries over their entire lifecycle, expressed in yuan. This represents the total lifecycle cost of the hydrogen storage tank, expressed in yuan. This represents the cost of penalties for power curtailment, expressed in yuan. This represents the total hydrogen production over the system's entire lifecycle, expressed in Nm³. 3 ; The formula for the lower-level objective function is as follows: ; in, This represents the output power of a photovoltaic power generation system, measured in kW. This represents the rated power of the photovoltaic power generation system, measured in kW. This represents the power generation efficiency of a photovoltaic power generation system; Represents the temperature coefficient; and Represents actual solar irradiance and reference irradiance, in units of W / m². 2 ; and This represents the actual operating temperature and reference temperature, in Kelvin (K). The input power of the alkaline electrolysis hydrogen production system at time t is expressed in kW. This represents the input power of the PEM electrolysis hydrogen production system at time t, expressed in kW.

2. The acceleration algorithm according to claim 1, characterized in that, The running times of acceleration algorithm one, acceleration algorithm two, and acceleration algorithm three are compared in advance, and the acceleration algorithm with the shortest running time is finally adopted.

3. The acceleration algorithm according to claim 1, characterized in that, The upper-level constraints of the upper-level model include equipment capacity constraints, and the formula for the equipment capacity constraints is as follows: ; ; ; ; in, This represents the capacity of an alkaline electrolysis hydrogen production system, measured in kW. This represents the capacity of the PEM electrolysis hydrogen production system, measured in kW. This represents the capacity of the energy storage battery, measured in kW.

4. The acceleration algorithm according to claim 1, characterized in that, The method further includes: establishing a hydrogen production model for a photovoltaic hydrogen production system, wherein the hydrogen production model includes at least: ; ; ; in, The unit of electricity consumption for hydrogen is kWh / Nm³. 3 ; , , These represent the electrolysis efficiencies of alkaline electrolysis hydrogen production systems, PEM electrolysis hydrogen production systems, and energy storage batteries, respectively. , , These represent the input power of the alkaline electrolysis hydrogen production system, the PEM electrolysis hydrogen production system, and the energy storage battery, respectively, in kW. , , These represent the hydrogen production rates of the alkaline electrolysis hydrogen production system, the PEM electrolysis hydrogen production system, and the energy storage battery, respectively.

5. The acceleration algorithm according to claim 1, characterized in that, The photovoltaic output data of the photovoltaic hydrogen production system within a preset time period are clustered, and a photovoltaic output scenario is obtained for each type of photovoltaic output data obtained from the clustering.

6. An acceleration device for a photovoltaic hydrogen production capacity configuration optimization system, characterized in that, include: The model building module is used to build a two-layer optimization model for the photovoltaic hydrogen production system. The upper-layer model of the two-layer optimization model takes the minimum unit hydrogen production cost over the entire life cycle as the upper-layer objective function, and the lower-layer model takes the minimum curtailment rate as the lower-layer objective function. The photovoltaic hydrogen production system includes at least a photovoltaic power generation system, a proton exchange membrane (PEM) electrolysis hydrogen production system, an alkaline electrolysis hydrogen production system, an energy storage battery, and a hydrogen storage tank. The model solving module is used to solve the two-layer optimization model to obtain the optimal capacity configuration of the photovoltaic hydrogen production system. Specifically, the upper-layer model is solved using a differential particle swarm optimization algorithm, and the lower-layer model is solved using a linear programming problem-solving method. The differential particle swarm optimization algorithm solution includes using one of the following three acceleration algorithms: Acceleration Algorithm 1: An improved differential particle swarm optimization algorithm that reduces iterative graph output, briefly pauses to update the graph, employs vectorized operations, and simplifies the handling of position and velocity constraints; Acceleration Algorithm 2: Based on Acceleration Algorithm 1, it combines GPU parallel optimization algorithms; Acceleration Algorithm 3: Based on Acceleration Algorithm 1, it combines parallel computing optimization algorithms; The model solving module is further configured to: Set the equipment capacity parameters of the photovoltaic hydrogen production system for the current calculation, and pass the equipment capacity parameters into the lower-level model; The lower-level model is configured with parameters, which include at least equipment capacity parameters and typical daily output data of photovoltaic power. The lower-level model is optimized by calling CPLEX to obtain the optimal operating power of the alkaline electrolysis hydrogen production system and the PEM electrolysis hydrogen production system at each time, and the optimal operating power is returned to the upper-level model. The upper-level model takes the minimum unit hydrogen production cost over the entire life cycle as the upper-level objective function, calculates the individual fitness value of the population particles, and updates the population particles. If the maximum number of iterations is reached, stop the iteration and output the optimal capacity configuration of the photovoltaic hydrogen production system; otherwise, return to execute the parameter setting of the lower-level model. The formula for the upper-level objective function is as follows: ; in, The total lifecycle cost of an alkaline electrolysis hydrogen production system is expressed in yuan. The total lifecycle cost of a PEM electrolysis hydrogen production system is expressed in yuan. This represents the total cost of energy storage batteries over their entire lifecycle, expressed in yuan. This represents the total lifecycle cost of the hydrogen storage tank, expressed in yuan. This represents the cost of penalties for power curtailment, expressed in yuan. This represents the total hydrogen production over the system's entire lifecycle, expressed in Nm³. 3 ; The formula for the lower-level objective function is as follows: ; in, This represents the output power of a photovoltaic power generation system, measured in kW. This represents the rated power of the photovoltaic power generation system, measured in kW. This represents the power generation efficiency of a photovoltaic power generation system; Represents the temperature coefficient; and Represents actual solar irradiance and reference irradiance, in units of W / m². 2 ; and This represents the actual operating temperature and reference temperature, in Kelvin (K). The input power of the alkaline electrolysis hydrogen production system at time t is expressed in kW. This represents the input power of the PEM electrolysis hydrogen production system at time t, expressed in kW.

7. The acceleration device according to claim 6, characterized in that, The acceleration algorithms 1, 2, and 3 were compared in advance, and the one with the shortest running time, less fluctuation, and faster and more stable convergence speed was finally adopted.