A control method for virtual synchronous generator in photovoltaic DC microgrid
By combining the virtual synchronous generator control method and the improved Archimedes optimization algorithm, the virtual synchronous generator parameters in the photovoltaic DC microgrid system are optimized, which solves the problem of poor stability in the external environment changes, and achieves better disturbance resistance and control performance.
Patent Information
- Application Number
- CN202210328274.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-03-31
- Publication Date
- 2025-05-02
- Estimated Expiration
- 2042-03-31
AI Technical Summary
The photovoltaic DC microgrid system is difficult to maintain stability when the external environment changes, and the parameter selection in the virtual synchronous generator control model is difficult, resulting in poor disturbance resistance of the system.
Combining the virtual synchronous generator control method and the improved Archimedes optimization algorithm, the parameters of the virtual synchronous generator are optimized, and the search capabilities of the algorithm are improved through Levy flight strategy, Gaussian mutation perturbation and elite strategies, and the optimal values of Km, Kn, and Ku in the virtual synchronous generator controller are found.
It improves the stability of the photovoltaic DC microgrid system under disturbance, enhances the anti-interference ability of the system, and improves the performance of the virtual synchronous generator controller.
Smart Images

Figure CN114784850B_ABST
Abstract
Description
Technical Field
[0001] The technical solution of the present invention belongs to the technical field of power systems, and specifically is a photovoltaic DC microgrid virtual synchronous generator control method. Background Art
[0002] The world is currently facing the threat of resource scarcity and environmental pollution. Distributed power generation technology in the form of renewable energy such as wind power and solar energy is developing rapidly. Among them, photovoltaic power generation has become one of the most promising renewable energy power generation methods due to its abundant resources and easy access. In order to further promote the development of distributed power sources, the concept of microgrid came into being.
[0003] A microgrid is a small distribution network that includes distributed power sources and energy storage devices. It can be integrated into a large power grid to provide it with the required energy, and it can also operate in an isolated island to meet the load requirements of the system. The introduction of microgrid technology can better adapt to the rapid development of distributed power generation. Compared with AC microgrids, DC microgrid systems have extremely high application value for some specific occasions such as family homes, ships, islands, and remote rural areas. However, new energy generation, especially photovoltaic power generation, is easily affected by the external environment such as temperature and light intensity. The output power is intermittent and volatile, and the rotating reserve energy is small, making it difficult to maintain active power balance, which seriously limits the development of distributed power generation. In addition, there are a large number of power electronic converters in photovoltaic DC microgrids. Although these devices have the advantages of flexible control, energy saving and high switching speed, they do not have inertia and damping characteristics. When the output of the photovoltaic array fluctuates due to sudden changes in the external environment, the photovoltaic power supply cannot maintain system stability through self-regulation like a synchronous generator. Therefore, it is very important to study the stability of the DC microgrid system during relevant disturbances to ensure reliable power supply.
[0004] Virtual synchronous generator technology can make the new energy system imitate the inertia and damping characteristics of synchronous generators. Its essence is to add the model of synchronous generator to the control of microgrid inverter, so that the inverter is consistent with the synchronous generator in output characteristics. Compared with the traditional droop control method, the inverter under the control of virtual synchronous generator can not only have the droop external characteristics of synchronous generator, complete primary frequency and voltage regulation, but also have inertia and damping characteristics, which can alleviate the impact of power fluctuation on DC bus voltage of microgrid DC side to a certain extent. However, there are multiple parameters in the control model of virtual synchronous generator, and each parameter affects and cooperates with each other. Inappropriate parameter selection will cause unnecessary oscillation, affect the operating performance of virtual synchronous generator and even make the system unable to work normally. Therefore, parameter selection is particularly important for virtual synchronous generator, while traditional calculation method is difficult to solve, large amount of calculation, and the obtained parameters are of limited utility. In recent years, researchers have developed many meta-heuristic algorithms, which have been applied to various multi-dimensional, nonlinear, and discontinuous problems and have achieved good optimization results. These artificial intelligence algorithms mostly use random search methods. Although they have fast solution speeds, they are prone to fall into local optimality and have poor convergence performance. They need to be improved before they can be applied to the solution of virtual synchronous generator parameter selection problems.
[0005] In summary, both traditional mathematical methods and intelligent algorithms have much room for improvement and cannot effectively solve the problem of virtual synchronous generator control in photovoltaic DC microgrids. Summary of the invention
[0006] The technical problem to be solved by the present invention is to provide a method for controlling a virtual synchronous generator in a photovoltaic DC microgrid. When a large number of power electronic devices are connected to the microgrid, resulting in reduced system inertia, poor anti-disturbance capability and stability, a virtual synchronous generator control model is established to provide inertia and damping characteristics for the system, thereby improving the stability of the system under relevant disturbances. The present invention combines the virtual synchronous generator control method with an improved Archimedean optimization algorithm, and proposes a method for controlling virtual synchronous generator parameters based on the improved Archimedean optimization algorithm. The regulation performance of the virtual synchronous generator controller is affected by the parameter K. m , K n and K u The influence of K m is the active power-frequency droop coefficient of the virtual synchronous generator, K n is the reactive power-voltage droop coefficient, K uis the integral coefficient; the improved Archimedean optimization algorithm introduces the Levy flight strategy, Gaussian variation disturbance and elite strategy into the classic Archimedean optimization algorithm, which can enable the virtual synchronous generator to achieve better control effect; finally, different types of interference are applied to the system to obtain the change of DC bus voltage, and compared with the droop control, it is verified that the present invention can solve the problems of low damping, low inertia and poor system stability in photovoltaic DC microgrids, which is helpful to improve the utilization rate of renewable energy.
[0007] The technical solution adopted by the present invention to solve the technical problem is: a photovoltaic DC microgrid virtual synchronous generator control method, which is a virtual synchronous generator control method optimized based on an improved Archimedean optimization algorithm, and its steps are as follows:
[0008] Step 1: Establish a virtual synchronous generator control model
[0009] The virtual synchronous generator control model includes an active power-frequency control model and a reactive power-voltage control model.
[0010] (1.1) Establishing the active power-frequency control model of virtual synchronous generator
[0011] In the power system, changes in load and active power output by the generator will cause deviations in the system frequency, endangering the safety and stability of the entire system operation and seriously affecting the user's power experience. The generator itself has an active frequency regulation function. Implanting this function into the virtual synchronous generator control of the inverter can make the output power of the inverter change with the change of load or photovoltaic power supply. The rotor motion equation of the synchronous generator is as follows:
[0012]
[0013] Where, D is the damping coefficient; J is the inertia constant of the synchronous generator; P m and P e are the mechanical power and electromagnetic power respectively; w and w0 are the virtual angular velocity and rated virtual angular velocity of the virtual synchronous generator respectively.
[0014] The active power-frequency control equation of the virtual synchronous generator is as follows:
[0015] P m =K m (f-f0)+P ref
[0016] Among them, K m is the droop coefficient; P ref is the given value of active power; f and f0 are the frequency and given initial frequency of the virtual synchronous generator respectively.
[0017] (1.2) Establishing a virtual synchronous generator reactive power-voltage control model
[0018] The system voltage is determined by the reactive power of the load in the system and the output reactive power of the synchronous generator. When the two suddenly change, the reactive power balance of the system is destroyed and the voltage fluctuates. In this case, the synchronous generator can adjust the excitation voltage to stabilize the voltage. According to the voltage regulation characteristics of the synchronous generator, the voltage regulation equation can be obtained as follows:
[0019]
[0020] Among them, U ref is the voltage given value; U m is the effective value of the output voltage of the virtual synchronous generator; k u is the integration coefficient.
[0021] According to the traditional droop characteristics:
[0022] U ref =k n (Q ref -Q)+U n
[0023] Among them, k n is the droop coefficient of the virtual synchronous generator; Q ref is the reactive power reference value; Q is the reactive power output by the inverter; U n is the rated voltage of the system. Combining the above two equations, the virtual electromotive force E of the virtual synchronous generator can be obtained as:
[0024]
[0025] Step 2: Establish the optimization objective function for minimizing bus voltage fluctuation of photovoltaic DC microgrid system
[0026] The optimization objective function of the bus voltage fluctuation minimization problem of the photovoltaic DC microgrid system is as follows:
[0027]
[0028] Among them, m1 and m2 are weighting coefficients; both are taken as 0.5; t sim is the total simulation time excluding transient time; t min is the transient start time; t max is the transient end time; ΔU is the system bus voltage fluctuation value.
[0029] Step 3: Improve the classic Archimedean optimization algorithm
[0030] The classic Archimedean optimization algorithm imitates the physical law Archimedean principle, which states that the buoyancy of an object in a liquid is equal to the weight of the liquid it displaces. During the optimization process, individuals in the population are objects immersed in liquid, with different densities, volumes, and accelerations, and each object is constantly moving to try to reach a state of equilibrium. The motion states of objects are divided into two types: the exploration phase (collision between objects) and the development phase (no collision between objects). Objects conduct global and local searches through exploration and development, and eventually converge. The present invention adopts an improved Archimedean optimization algorithm, introduces Gaussian mutation perturbation into the classic Archimedean optimization algorithm to improve the global search capability of the algorithm, and adopts an elite strategy to sort and optimize objects before and after the mutation to increase population diversity; introduces the Levy flight strategy to improve the local search capability of the algorithm and prevent the algorithm from falling into a local optimum;
[0031] (3.1) Introducing Gaussian mutation perturbation and elite strategy in the position update operation during the object exploration phase
[0032] The classic Archimedean optimization algorithm is prone to fall into local optimality at the beginning of iteration, resulting in a decrease in population diversity. To solve this problem, the present invention introduces a Gaussian mutation operator to perturb and mutate the current object to increase population diversity and avoid the algorithm from falling into a local optimal deadlock. The perturbation factor z is subject to the expectation μ and the variance σ 2 Normal distribution, that is, z~N(μ,σ 2 ), its probability density function can be expressed as follows:
[0033]
[0034] Here, the expectation of the Gaussian distribution is taken as zero, and the expression of the disturbance factor z is as follows:
[0035]
[0036] Among them, v is a random number between [0, 1]; u is a random variable related to the number of iterations, its range is between [0, 1], and its expression is as follows:
[0037]
[0038] Among them, rand is a random number between [0, 1]; t and t max Represent the current number of iterations and the maximum number of iterations respectively.
[0039] Gaussian mutation perturbation is performed on the objects in the exploration phase to increase individual diversity, and the object position update formula is obtained as follows:
[0040]
[0041] Among them, C1 is a constant with a value of 2; is the position of the i-th object at the t+1th iteration; is the optimal object position of the i-th object at the t-th iteration; is the percentage of steps that the i-th search agent will change at the t+1th iteration; x rand is the position of the random object; d t is the density factor of the t-th iteration, and its expression is as follows:
[0042]
[0043] In order to further improve the diversity of the population and the convergence accuracy of the algorithm, an elite strategy is adopted after the Gaussian mutation to convert the new individuals x generated after the mutation into i t* Compared with the individual x before mutation i t Sort them together, recalculate the fitness, and select the best individuals to retain.
[0044] (3.2) Introducing the Levy flight strategy in the position update operation during the object development phase
[0045] In order to increase the random behavior of the population and improve the convergence speed of the algorithm, the present invention introduces the Levy flight strategy into the object position update in the development stage. The Levy flight strategy is a non-Gaussian random search mode that obeys the Levy distribution. Using the Levy flight factor instead of the random number in the position update formula can significantly improve the convergence speed and help the algorithm jump out of the local optimal solution. The calculation formula of the Levy flight strategy is as follows:
[0046]
[0047] Among them, x is the dimension of the position vector; β is a constant, usually set to 1.5; r4 and r5 are both random numbers that satisfy the standard normal distribution; Γ(x)=(x-1)! .
[0048] The position update formula of the object development phase after the introduction of the Levy flight strategy is:
[0049]
[0050] Among them, C2 is a constant with a value of 6; TF is a transfer operator; t and t max Represent the current number of iterations and the maximum number of iterations respectively; T is proportional to the transfer operator, defined as T = C3 × TF, C3 is a constant, T increases with time, and a certain percentage is extracted from the optimal position to reduce the difference between the optimal position and the current position; is the percentage of steps that the i-th search agent will change at the t+1th iteration; x it+1 is the position of the i-th object at the t+1th iteration; is the optimal object position at the tth iteration; x best is the position of the global optimal object; F is used to change the direction of movement, and its expression is as follows:
[0051]
[0052] Wherein, P=2×rand-C4, C4 is a constant, and rand is a random number between [0, 1].
[0053] The improved algorithm expands the search range and enhances the local search capability by introducing the Levy flight strategy, thus avoiding the algorithm from falling into the local optimal solution.
[0054] Step 4: Construct a photovoltaic DC microgrid simulation model
[0055] In the PV DC microgrid model, in addition to the inverter unit under the control of the virtual synchronous generator, reasonable control methods should be adopted for the PV power generation unit and the hybrid energy storage system to ensure the normal operation of the system.
[0056] (4.1) Photovoltaic power generation unit control method
[0057] The photovoltaic array is the only power generation equipment in this system and one of the most basic power generation equipment in today's new energy power stations. Its output power is affected by factors such as external temperature, light intensity, and ambient humidity. In order to ensure the continuous maximum output of the photovoltaic array power, the photovoltaic unit must be stepped up through the Boost converter and a maximum power point tracking module must be set. When external factors change and the output of the photovoltaic cell becomes unstable and the system is out of the maximum power point, the tracking algorithm will make the system work at the maximum power point under the current conditions to ensure the maximum energy conversion efficiency of the photovoltaic array.
[0058] At present, the commonly used maximum power point tracking methods include constant voltage tracking method, perturbation observation method, conductance increment method, etc. Among them, the perturbation observation method has a simple principle, good tracking effect, and is the most widely used. The perturbation observation method includes the fixed step perturbation method and the variable step perturbation method. Compared with the fixed step perturbation method, the variable step perturbation method has the advantages of fast response speed and high accuracy, so the variable step perturbation observation method is selected for maximum power point tracking.
[0059] (4.1) Hybrid energy storage unit and control method thereof
[0060] The model of the hybrid energy storage system includes a lithium battery model and a supercapacitor model.
[0061] (1) Lithium battery model
[0062] As the most important energy storage device in the system, lithium batteries can effectively adjust the system voltage and frequency through the control of charging and discharging strategies, ensuring that the system with distributed power sources can achieve power balance and stable operation. The working characteristics of lithium batteries are determined by the state of charge SOC, the lithium battery terminal voltage V bat , discharge depth DOD, etc. Among them, terminal voltage and state of charge are two important physical quantities that show battery performance. The charging and discharging model of lithium battery is as follows:
[0063] Charging Model:
[0064]
[0065] Discharge model:
[0066]
[0067] Among them, V ch and V disch is the charging and discharging voltage of the lithium battery; V0 is the constant voltage; Q is the maximum capacity of the lithium battery; i is the battery current; i* is the low-frequency dynamic current; K, k, A are the inherent parameters of the battery.
[0068] The calculation formula for lithium battery SOC is as follows:
[0069]
[0070] (2) Supercapacitor model
[0071] In recent years, supercapacitors have played an increasingly important role in the field of energy storage devices due to their long cycle life and high power density. The classic RC equivalent model of supercapacitors has been widely used in practical engineering and simulation research due to its simple structure and obvious charging and discharging characteristics. The SOC equation of supercapacitors is as follows:
[0072]
[0073] Among them, Q t is time, and the energy stored in the supercapacitor; Q N is the total energy of the supercapacitor; U max , U min are the maximum voltage and minimum voltage of the supercapacitor respectively; U sc is the supercapacitor terminal voltage; I sc is the supercapacitor current; C is the ideal capacitance value; U0 is the initial voltage.
[0074] Supercapacitors store energy of
[0075]
[0076] (3) Hybrid energy storage system control model
[0077] The energy storage system model constructed by the present invention adopts a control strategy aimed at stabilizing the DC bus voltage. Only when the DC voltage is stable can a stable voltage be provided to the load. The lithium battery module and the supercapacitor maintain the power balance of the system through complementary charging and discharging. The low-pass filter divides the system power difference into low-frequency and high-frequency parts. The low-frequency part is absorbed and released by the lithium battery module to maintain the bus voltage; the high-frequency part is absorbed and released by the supercapacitor module, so that the system can respond quickly to sudden power fluctuations. When the DC bus voltage increases, the energy storage system absorbs excess energy and is in a charging state; when the DC bus voltage decreases, the energy storage system releases energy to supply the load and is in a discharging state. Both energy storage modules adopt voltage and current dual closed-loop control, and the charging and discharging process is controlled by a bidirectional DC / DC controller.
[0078] Step 5: Use the improved Archimedean optimization algorithm to find the K in the virtual synchronous generator controller of the photovoltaic DC microgrid. m , K n , K u The optimal value of
[0079] (5.1) Set the population size of the improved Archimedean optimization algorithm to N = 30 and the maximum number of iterations to t mmax =50, C1=2, C2=6, object acceleration normalization range u=0.9, l=0.1, initialize object characteristics, set parameter optimization range;
[0080] (5.2) Calculate the fitness of the initial population and retain the features of the object with the best fitness;
[0081] (5.3) Iteration starts, and the transfer operator TF is calculated. If TF>0.5, the Levy flight strategy is used to update the object position in the development phase; if TF≤0.5, the Gaussian mutation perturbation is introduced to update the object position in the exploration phase;
[0082] (5.4) Use the elite strategy to calculate the fitness value of the object before and after the mutation, sort it according to the size of the fitness value, and retain the object features with the best fitness value;
[0083] (5.5) Determine whether the number of iterations meets the requirements, that is, determine whether t ≥ t max Is it true? If not, the number of iterations t is increased by 1 and the process returns to step (5.3) to enter the next iteration. If t ≥ t max If it is established, the iteration is exited and the three optimal parameter values K of the virtual synchronous generator controller of the photovoltaic DC microgrid are output. m , K n and K u ;
[0084] (5.6) Substitute the parameters obtained by algorithm optimization into the PV DC microgrid virtual synchronous generator controller.
[0085] Step 6: Test the stability of the PV DC microgrid model
[0086] A disturbance is imposed on the system, that is, when the temperature and light intensity of the photovoltaic array in the photovoltaic DC microgrid suddenly change, or the load on the AC side suddenly changes, the change of the system bus voltage is tested and compared with the traditional droop control. The test results are compared and analyzed, which proves that the method of the present invention can improve the stability of the photovoltaic DC microgrid.
[0087] The method of inputting data into a computer in the above steps is a well-known method; the computer, display and MATLAB computer software used are all commercially available.
[0088] The beneficial effects of the present invention are:
[0089] (1) The present invention provides a method for controlling a virtual synchronous generator of a photovoltaic DC microgrid, which can solve the problem that the photovoltaic DC microgrid is easily affected by the external environment and has low stability. The virtual synchronous generator control is applied to the inverter control of the microgrid, which increases the inertia and damping characteristics of the system and improves the anti-interference ability of the system.
[0090] (2) The present invention combines the virtual synchronous generator control method with the improved Archimedean optimization algorithm, and proposes a virtual synchronous generator control method based on the improved Archimedean optimization algorithm. The Levy flight strategy, Gaussian variation disturbance and elite strategy are introduced into the classical Archimedean optimization algorithm. The improved Archimedean optimization algorithm has the advantages of fast convergence speed, high accuracy and strong robustness, and can find the optimal parameters of the virtual synchronous generator that are suitable for the entire system, that is, the active power-frequency droop coefficient K m , reactive power-voltage droop coefficient K n and the integral coefficient K u , the steps are simple and can improve the performance of the virtual synchronous generator controller.
[0091] (3) The present invention models the classic photovoltaic DC microgrid in practical applications, including photovoltaic power generation units, hybrid energy storage systems, etc., and designs reasonable control methods for them respectively, so that the improved Archimedean optimization algorithm can be used to optimize the bus voltage fluctuation as the fitness function, thereby improving the stability of the entire photovoltaic DC microgrid system and promoting the development of the new energy industry.
[0092] (4) The application scope of the photovoltaic DC microgrid virtual synchronous generator control method of the present invention is not limited to photovoltaic power generation systems, but can also be applied to other new energy power generation systems; the improved Archimedean optimization algorithm can also be extended to parameter optimization in other fields. BRIEF DESCRIPTION OF THE DRAWINGS
[0093] The present invention is further described below in conjunction with the accompanying drawings and embodiments.
[0094] Figure 1 It is a flow chart of a photovoltaic DC microgrid virtual synchronous generator control method of the present invention.
[0095] Figure 2 This is a simulation model diagram of the virtual synchronous generator controller in Example 1.
[0096] Figure 3 This is the overall simulation model diagram of the photovoltaic DC microgrid system in Example 1.
[0097] Figure 4 This is a simulation model diagram of the photovoltaic array variable step size perturbation observation method in Example 1.
[0098] Figure 5 This is a control block diagram of the hybrid energy storage system in Example 1.
[0099] Figure 6 This is a bus voltage waveform diagram obtained by using the method of the present invention when the light intensity and temperature suddenly change in Example 1.
[0100] Figure 7 This is a bus voltage waveform diagram obtained by using the droop control method when the light intensity and temperature suddenly change in Example 1.
[0101] Figure 8 This is a bus voltage waveform diagram obtained by using the method of the present invention when the load suddenly changes in Example 1.
[0102] Fig. 9 This is a bus voltage waveform diagram obtained by using the droop control method when the load suddenly changes in Example 1.
[0103] Fig.10 It is an overall flow chart of a photovoltaic DC microgrid virtual synchronous generator control method of the present invention. DETAILED DESCRIPTION
[0104] Figure 1 The program flow of the photovoltaic DC microgrid virtual synchronous generator control method of the present invention is: start → build a simulation model of the photovoltaic DC microgrid system → set the parameters of the improved Archimedean optimization algorithm → initialize the object position, density, speed, and acceleration → calculate the initial population fitness value → calculate the transfer operator TF → TF≤0.5? → Y, determine that the object is in the exploration stage, and use Gaussian mutation disturbance to update the object characteristics; N, determine that the object is in the development stage, and use Levy flight strategy to update the object position → calculate the fitness value of the object before and after the mutation, and sort the objects according to the fitness size → T>tmax ? →N, the number of iterations t increases by 1, and the next iteration begins; Y, output the object position with the best fitness value → the K obtained by optimization is m , K n and K u Substitute into the virtual synchronous controller → apply disturbance and run the simulation model, that is: under the same conditions, the temperature and light intensity of the photovoltaic power generation unit are suddenly changed, and the system bus voltage waveforms under the control of the method of the present invention and the droop control method are obtained respectively; under the same conditions, the AC side load is suddenly changed, and the system bus voltage waveforms under the control of the method of the present invention and the droop control method are obtained respectively → analyze and compare the effects of the two methods on the system bus voltage stability under different disturbances; end.
[0105] Example 1
[0106] The present invention provides a photovoltaic DC microgrid virtual synchronous generator control method, which uses a PC as a platform for model building, wherein the CPU is i5-3230M 2.60GHz, the installed memory is 8GB, the operating system is Windows 10-64 bit, and the MATLAB / Simulink R2021a version is used.
[0107] Step 1: Establish a virtual synchronous generator control model
[0108] The virtual synchronous generator control model is as follows Figure 2 As shown, it consists of an active power-frequency control module and a reactive power-voltage control module.
[0109] (1.1) Establishing the active power-frequency control model of virtual synchronous generator
[0110] In the power system, changes in load and active power output by the generator will cause deviations in the system frequency, endangering the safety and stability of the entire system operation and seriously affecting the user's power consumption experience. The generator itself has an active frequency regulation function. Implanting this function into the virtual synchronous generator control of the inverter can make the output power of the inverter change with the change of load or photovoltaic power supply. The rotor motion equation of the synchronous generator is shown in formula (1).
[0111]
[0112] Wherein, D is the damping coefficient, which is 25 in this implementation case; J is the inertia constant of the synchronous generator, which is 0.6; w and w0 are the virtual angular velocity and rated virtual angular velocity of the virtual synchronous generator respectively, w = 2πf, f is the frequency; P m and P e are mechanical power and electromagnetic power respectively, where P e is the output active power of the inverter under the control of the virtual synchronous generator; Pm It can be expressed by equation (2), which is the active power-frequency control equation of the virtual synchronous generator.
[0113] P m =K m (f-f0)+P ref (2)
[0114] Among them, K m is the droop coefficient, P ref is the given value of active power, which is 14500W in this case; f and f0 are the frequency of the virtual synchronous generator and the given initial frequency respectively, and f0=50Hz.
[0115] (1.2) Establishing a virtual synchronous generator reactive power-voltage control model
[0116] The system voltage is determined by the reactive power of the load in the system and the output reactive power of the synchronous generator. When the two suddenly change, the reactive power balance of the system is destroyed and the voltage fluctuates. In this case, the synchronous generator can adjust the excitation voltage to stabilize the voltage. According to the voltage regulation characteristics of the synchronous generator, the voltage regulation equation can be obtained as follows:
[0117]
[0118] Among them, U m is the effective value of the output voltage of the virtual synchronous generator, k u is the integration coefficient, U ref is the given voltage value, and its expression is shown in formula (4).
[0119] U ref =k n (Q ref -Q)+U n (4)
[0120] Among them, k n is the droop coefficient of the virtual synchronous generator; Q ref is the reactive power reference value, which is 0var; Q is the reactive power output by the inverter; U n The rated voltage of the system is 220V.
[0121] Combining the above two equations, we can get the virtual electromotive force E of the virtual synchronous generator as:
[0122]
[0123] Step 2: Establish the optimization objective function for minimizing bus voltage fluctuation of photovoltaic DC microgrid system
[0124] The optimization objective function of the bus voltage fluctuation minimization problem of the photovoltaic DC microgrid system is shown in formula (6).
[0125]
[0126] Among them, m1 and m2 are weighted coefficients, both of which are taken as 0.5; ΔU is the system bus voltage fluctuation value, ΔU=UV dc , U is the instantaneous value of bus voltage, V dc is the rated value of the bus voltage, which is 350V. In the algorithm optimization process of this implementation case, the total simulation time is 1s, and t sim is the total simulation time excluding transient time, which is 0.92s; t min is the transient start time, the value is 0.6s; t max It is the transient end time, and its value is 0.68s.
[0127] Step 3: Improve the classic Archimedean optimization algorithm
[0128] The classic Archimedean optimization algorithm imitates the physical law Archimedean principle, that is, the buoyancy of an object in a liquid is equal to the gravity of the liquid it displaces. During the optimization process, the individuals in the population are objects immersed in the liquid, with different densities, volumes and accelerations. Each object is constantly moving to try to reach a state of equilibrium. The motion state of the object is divided into two types: the exploration stage (collision between objects) and the development stage (no collision between objects). Objects conduct global and local searches through exploration and development, and finally reach convergence. The present invention adopts an improved Archimedean optimization algorithm, introduces the Levy flight strategy into the classic Archimedean optimization algorithm to improve the local search ability of the algorithm and avoid the algorithm from falling into the local optimum; introduces Gaussian mutation perturbation to improve the global search ability of the algorithm, and adopts an elite strategy to sort and optimize the objects before and after the mutation to increase the diversity of the population. The total dimension d of the improved Archimedean optimization algorithm is taken as 3, the initial population size, that is, the number of search agents N is 30, and the maximum number of iterations t max is 50.
[0129] (3.1) Introducing Gaussian mutation perturbation and elite strategy in the position update operation during the object exploration phase
[0130] The classic Archimedean optimization algorithm is prone to fall into local optimality at the beginning of iteration, resulting in a decrease in population diversity. To solve this problem, the present invention introduces a Gaussian mutation operator to perturb and mutate the current object to increase population diversity and avoid the algorithm from falling into a local optimal deadlock. The perturbation factor z follows a normal distribution with an expected value of 0 and a variance of 0.1, i.e., z~N(0, 0.1 2 ), its probability density function can be expressed as follows:
[0131]
[0132] The expression of the disturbance factor z is as follows:
[0133]
[0134] Among them, v is a random number between [0, 1]; u is a random variable related to the number of iterations, its range is between [0, 1], and its expression is as follows:
[0135]
[0136] Among them, rand is a random number between [0, 1]; t represents the current iteration number, t max =50.
[0137] Gaussian mutation perturbation is performed on the objects in the exploration phase to increase individual diversity, and the object position update formula is obtained as follows:
[0138]
[0139] Among them, C1 is a constant with a value of 2; x i t+1 is the position of the i-th object at the t+1th iteration; is the optimal object position of the i-th object at the t-th iteration; x rand is the position of the random object; d t is the density factor of the t-th iteration, and its expression is as follows:
[0140]
[0141] In order to further improve the diversity of the population and the convergence accuracy of the algorithm, an elite strategy is adopted after the Gaussian mutation to convert the new individuals x generated after the mutation into i t* Compared with the individual x before mutation i t Sort them together, recalculate the fitness, and select the best individuals to retain.
[0142] (3.2) Introducing the Levy flight strategy in the position update operation during the object development phase
[0143] In order to increase the random behavior of the population and improve the convergence speed of the algorithm, the present invention introduces the Levy flight strategy into the object position update in the development stage. The Levy flight strategy is a non-Gaussian random search mode that obeys the Levy distribution. Using the Levy flight factor instead of the random number in the position update formula can significantly improve the convergence speed and help the algorithm jump out of the local optimal solution. The calculation formula of the Levy flight strategy is as follows:
[0144]
[0145] Among them, x can be 1, 2, or 3, indicating the xth dimension of the position vector; β is a constant, usually set to 1.5; r4 and r5 are both random numbers that satisfy the standard normal distribution; Γ(x)=(x-1)! .
[0146] The position update formula of the object development phase after the introduction of the Levy flight strategy is:
[0147]
[0148] Among them, C2 is a constant with a value of 6; TF is the transfer operator; t represents the current number of iterations, t mmax =50; T is proportional to the transfer operator, defined as T = C3 × TF, C3 = 1, T increases with time, and a certain percentage is extracted from the optimal position to reduce the difference between the optimal position and the current position; is the percentage of steps that the i-th search agent will change at the t+1th iteration; x i t+1 is the position of the i-th object at the t+1th iteration; is the optimal object position at the tth iteration; x best is the position of the global optimal object; F is used to change the direction of movement, and the expression is as follows:
[0149]
[0150] Wherein, P=2×rand-C4, C4=2, and rand is a random number between [0, 1].
[0151] The improved algorithm expands the search range and enhances the local search capability by introducing the Levy flight strategy, thus avoiding the algorithm from falling into the local optimal solution.
[0152] Step 4: Construct a photovoltaic DC microgrid simulation model
[0153] The overall simulation model of the photovoltaic DC microgrid system in Example 1 is shown in FIG. Figure 3 In the PV DC microgrid model, in addition to the inverter unit under the control of the virtual synchronous generator, a reasonable control method should be adopted for the PV power generation unit and the hybrid energy storage system to ensure the normal operation of the system.
[0154] (4.1) Photovoltaic power generation unit control method
[0155] The photovoltaic array is the only power generation equipment in this system and one of the most basic power generation equipment in today's new energy power stations. Its output power is affected by factors such as external temperature, light intensity, and ambient humidity. In this implementation case, the photovoltaic array selects the existing photovoltaic array model in the Simulink software. In order to ensure the continuous maximum output of the photovoltaic array power, the photovoltaic unit must be boosted by the Boost converter and a maximum power point tracking module must be set. When external factors change and the output of the photovoltaic cell becomes unstable, and the system is out of the maximum power point, the tracking algorithm will make the system work at the maximum power point under the current conditions to ensure that the energy conversion efficiency of the photovoltaic array is maximized.
[0156] The commonly used maximum power point tracking methods currently include constant voltage tracking method, perturbation observation method, conductance increment method, etc. Among them, the perturbation observation method has a simple principle, good tracking effect, and is the most widely used. The perturbation observation method also includes a fixed-step perturbation method and a variable-step perturbation method. Compared with the fixed-step perturbation method, the variable-step perturbation method has the advantages of fast response speed and high accuracy. Therefore, the variable-step perturbation observation method is selected for maximum power point tracking. The simulation model diagram of the variable-step perturbation observation method for the photovoltaic array in Example 1 is shown in FIG. Figure 4 shown.
[0157] (4.1) Hybrid energy storage unit and control method thereof
[0158] The model of the hybrid energy storage system includes a lithium battery model and a supercapacitor model.
[0159] (1) Lithium battery model
[0160] As the most important energy storage device in the system, lithium batteries can effectively adjust the system voltage and frequency through the control of charging and discharging strategies, ensuring that the system with distributed power sources can achieve power balance and stable operation. The working characteristics of lithium batteries are determined by the state of charge SOC, the lithium battery terminal voltage V bat , discharge depth DOD, etc. Among them, terminal voltage and state of charge are two important physical quantities that show battery performance. The charging and discharging model of lithium battery is as follows:
[0161] Charging Model:
[0162]
[0163] Discharge model:
[0164]
[0165] Among them, V ch and V dischis the charging and discharging voltage of the lithium battery; V0 is the constant voltage; Q is the maximum capacity of the lithium battery; i is the battery current; i* is the low-frequency dynamic current; K, k, A are the inherent parameters of the battery. In this implementation case, the existing lithium battery model in Simulink software is selected, and its parameters are: Q = 10Ah, V0 = 300V, V ch =262.5V, V disch =381.09V, and the initial state of charge is set to 90%.
[0166] The calculation formula for lithium battery SOC is as follows
[0167]
[0168] (2) Supercapacitor model
[0169] In recent years, supercapacitors have played an increasingly important role in the field of energy storage devices due to their long cycle life and high power density. The classic RC equivalent model of supercapacitors has been widely used in practical engineering and simulation research due to its simple structure and obvious charging and discharging characteristics. The SOC equation of supercapacitors is as follows
[0170]
[0171] Among them, Q t Q is the energy stored in the supercapacitor at time t; N is the total energy of the supercapacitor; C is the ideal capacitance value; U max , U min are the maximum voltage and minimum voltage of the supercapacitor respectively; U sc is the supercapacitor terminal voltage; I sc is the supercapacitor current; U0 is the initial voltage. In this implementation case, the existing supercapacitor model in Simulink software is selected, and its main parameters are: C = 15.6F, U0 = 200V.
[0172] Supercapacitors store energy of
[0173]
[0174] (3) Hybrid energy storage system control model
[0175] The energy storage system model constructed by the present invention adopts a control strategy aimed at stabilizing the DC bus voltage. Only when the DC voltage is stable can a stable voltage be provided to the load. The lithium battery module and the supercapacitor maintain the power balance of the system through complementary charging and discharging. The low-pass filter divides the system power difference into low-frequency and high-frequency parts. The low-frequency part is absorbed and released by the lithium battery module to maintain the bus voltage; the high-frequency part is absorbed and released by the supercapacitor module, so that the system can respond quickly to sudden power fluctuations. When the DC bus voltage increases, the energy storage system absorbs excess energy and is in a charging state; when the DC bus voltage decreases, the energy storage system releases energy to supply the load and is in a discharging state. Both energy storage modules adopt voltage and current dual closed-loop control, and the charging and discharging process is controlled by a bidirectional DC / DC controller. The control block diagram of the hybrid energy storage system in Example 1 is shown as follows. Figure 5 shown.
[0176] Step 5: Use the improved Archimedean optimization algorithm to find the K in the virtual synchronous generator controller of the photovoltaic DC microgrid. m , K n , K u The optimal value of
[0177] (5.1) Set the population size of the improved Archimedean optimization algorithm to N = 30 and the maximum number of iterations to t max =50, C1=2, C2=6, object acceleration normalization range u=0.9, l=0.1, initialize the object's position, density, velocity and acceleration; set K m , K n , K u The optimization ranges are [5000, 100000], [0, 5000], and [5, 100] respectively;
[0178] (5.2) Calculate the fitness of the initial population and retain the features of the object with the best fitness;
[0179] (5.3) Iteration starts, and the transfer operator TF is calculated. If TF>0.5, the Levy flight strategy is used to update the object position in the development phase according to formula (10); if TF≤0.5, Gaussian mutation disturbance is introduced, and the object position in the exploration phase is updated according to formula (14);
[0180] (5.4) Use the elite strategy to calculate the fitness value of the object before and after the mutation, sort it according to the size of the fitness value, and retain the object features with the best fitness value;
[0181] (5.5) Determine whether the number of iterations meets the requirements, that is, determine whether t ≥ t max Is it true? If not, the number of iterations t is increased by 1 and the process returns to step (5.3) to enter the next iteration. If t ≥ t maxIf it is established, the iteration is exited and the three optimal parameter values K of the virtual synchronous generator controller of the photovoltaic DC microgrid are output. m =17712.04, K n =423.19, K u =25.19;
[0182] (5.6) Substitute the parameter values obtained by algorithm optimization into the PV DC microgrid virtual synchronous generator controller.
[0183] Step 6: Test the stability of the PV DC microgrid model
[0184] The disturbance is applied to the system, the change of the system bus voltage is tested and compared with the traditional droop control, and the test results are compared and analyzed to prove that the method of the present invention can improve the stability of the photovoltaic DC microgrid. The total simulation time is set to 2s during the test.
[0185] (6.1) When the temperature and light intensity of the photovoltaic array change suddenly
[0186] Set the light intensity of the photovoltaic array to 500W / m 2 , 1000W / m at 1~1.2s 2 , returns to 500W / m in 1.2~2s 2 ; The temperature is 25°C at 0-1.4s and 40°C at 1.4-2s. When the light intensity and temperature suddenly change in Example 1, the bus voltage waveform obtained by the method of the present invention is as follows: Figure 6 As shown in the figure, the bus voltage waveform obtained by the droop control method is as follows Figure 7 It can be seen from the analysis that under the two control methods, when the light intensity of the photovoltaic unit changes suddenly, the bus voltage fluctuates significantly. However, compared with the traditional droop control, the fluctuation amplitude of the DC bus voltage under the control of the method of the present invention is reduced by 2.6%-2.9%.
[0187] (6.2) When the AC side load suddenly changes
[0188] The DC bus voltage is still set to 350V, and the light intensity is constant at 500M / m 2 , the temperature is constant at 25°C, and a disturbance load R0 is connected in parallel on the AC load side at 1 second. In Example 1, when the load suddenly changes, the bus voltage waveform obtained by the method of the present invention is as follows: Figure 8 As shown in the figure, the bus voltage waveform obtained by the droop control method is as follows Fig. 9 As shown. Analysis shows that under the two control methods, when the AC side load changes suddenly, the bus voltage fluctuates significantly, but compared with the traditional droop control, the fluctuation amplitude of the DC bus voltage under the virtual synchronous generator control proposed in the present invention is reduced by 5.3%.
[0189] In all the above embodiments, the simulation method is a well-known method; the computer, display and MATLAB / Simulink computer software are all commercially available.
[0190] The above are only preferred implementation modes of the present invention, but the protection scope of the present invention is not limited thereto. Any technician familiar with the technical field can make equivalent replacements or changes according to the technical solutions and inventive concepts of the present invention within the technical scope disclosed by the present invention, which should be covered by the protection scope of the present invention.
Claims
1. A photovoltaic DC microgrid virtual synchronous generator control method, characterized in that: The following steps are involved: Step 1: Establish a virtual synchronous generator control model The virtual synchronous generator model includes an active power-frequency control model and a reactive power-voltage control model, wherein the active power-frequency control model is as follows: P m =K m (f-f0)+P ref Where D is the damping coefficient; J is the inertia constant; P m and P e are mechanical power and electromagnetic power respectively; w and w0 are the virtual angular velocity and rated virtual angular velocity of the virtual synchronous generator respectively; K m is the droop coefficient; P ref is the given value of active power; f and f0 are the frequency of the virtual synchronous generator and the given initial frequency respectively: The reactive power-voltage control model of the virtual synchronous generator is as follows: Where, E is the virtual electromotive force of the virtual synchronous generator; U m is the effective value of the output voltage of the virtual synchronous generator; k u is the integral coefficient; k n is the droop coefficient of the virtual synchronous generator; Q ref is the reactive power reference value; Q is the reactive power output of the inverter under the control of the virtual synchronous generator; U n is the system rated voltage; Step 2: Establish the objective function of minimizing the bus voltage fluctuation of the photovoltaic DC microgrid The objective function of the problem of minimizing bus voltage fluctuation of photovoltaic DC microgrid is: In the formula, m1 and m2 are weighting coefficients, both of which are 0.5; t sim is the total simulation time excluding transient time; t min is the transient start time; t max is the transient end time; ΔU is the system bus voltage fluctuation value; Step 3: Build a photovoltaic DC microgrid system simulation model Step 4: Use the improved Archimedean optimization algorithm to optimize the parameters K of the virtual synchronous generator of the photovoltaic DC microgrid. m , K n , K u Optimize and get the optimal controller parameter value The subdivision steps are as follows: Step 4.1, set the population size, maximum number of iterations, normalized range u and l of object acceleration of the improved Archimedean optimization algorithm, initialize the position, density, velocity and acceleration of the object, and set the parameter optimization range; Step 4.2, calculate the fitness of the initial population and retain the object features with the best fitness; Step 4.3, start iteration, calculate the transfer operator TF, if TF≤0.5, introduce Gaussian mutation disturbance to update the object position in the exploration phase; if TF>0.5, use Levy flight strategy to update the object position in the development phase, and the position update of all population individuals is completed; Step 4.4: Introduce the elite strategy to retain the optimal value of fitness; Step 4.5: Determine whether the number of iterations meets the requirements, that is, determine whether t≥t max Is it true? If not, the number of iterations t is increased by 1 and the process returns to step 4.3 to enter the next iteration. If t≥t max If it is established, the iteration is exited and the three optimal parameter values K of the virtual synchronous generator controller of the photovoltaic DC microgrid are output. m , K n and K u ; Step 4.6: Substitute the parameters obtained by algorithm optimization into the PV DC microgrid virtual synchronous generator controller.
2. A photovoltaic DC microgrid virtual synchronous generator control method according to claim 1, characterized in that: In step 4.3, after calculating the transfer operator TF value of each object, the object motion state is determined according to the TF value. When TF≤0.5, Gaussian mutation disturbance is introduced to update the object position in the exploration phase. The disturbance factor z has an expectation of μ and a variance of σ 2 Normal distribution, that is, z~N(μ,σ 2 ), its probability density function can be expressed as follows: Here, the expectation of the Gaussian distribution is taken as zero, and the expression of the disturbance factor z is as follows: Where v is a random number between [0, 1]; u is a random variable related to the number of iterations, which ranges between [0, 1] and is expressed as follows: Where rand is a random number between [0, 1]; t and t max Respectively represent the current number of iterations and the maximum number of iterations; Gaussian mutation perturbation is performed on the objects in the exploration phase to increase individual diversity, and the object position update formula is obtained as follows: In the formula, C1 is a constant with a value of 2; x i t+1 is the position of the i-th object at the t+1th iteration; is the optimal object position of the i-th object at the t-th iteration; is the percentage of steps that the i-th search agent will change at the t+1th iteration; x rand is the position of the random object; d t is the density factor of the t-th iteration, and its expression is as follows:
3. A photovoltaic DC microgrid virtual synchronous generator control method according to claim 1, characterized in that: In step 4.3, after calculating the transfer operator TF value of each object, if TF>0.5, the Levy flight strategy is used to update the object position in the development phase. The formula is as follows: Where x is the dimension of the position vector; β is a constant, set to 1.5; r4 and r5 are both random numbers that satisfy the standard normal distribution; Γ(x)=(x-1)!; The position update formula of the object development phase after the introduction of the Levy flight strategy is: Among them, C2 is a constant with a value of 6; TF is a transfer operator; t and t max Represent the current number of iterations and the maximum number of iterations respectively; T is proportional to the transfer operator, defined as T = C3 × TF, C3 is a constant, T increases with time, and a certain percentage is extracted from the optimal position to reduce the difference between the optimal position and the current position; is the percentage of steps that the i-th search agent will change at the t+1th iteration; x i t+1 is the position of the i-th object at the t+1th iteration; is the optimal object position at the tth iteration; x best is the position of the global optimal object; F is used to change the direction of movement, and its expression is as follows: Wherein, P=2×rand-C4, C4 is a constant, and rand is a random number between [0, 1].
4. A photovoltaic DC microgrid virtual synchronous generator control method according to claim 1, characterized in that: The step 4.4 introduces an elite strategy after all object positions are updated, retains the object positions before and after the Gaussian mutation, sorts the new individuals in the development phase after the update, the new individuals generated in the exploration phase after the mutation, and the individuals before the mutation according to the fitness size, selects the best individuals to retain, and further improves the population diversity.
Citation Information
Patent Citations
Wind and light energy storage hybrid system capacity configuration method based on gravity energy storage
CN114188938A
Charging and discharging scheduling method for electric vehicles in microgrid under time-of-use price
US20170337646A1