Microgrid distributed control method and system based on improved average consensus algorithm
The distributed control strategy established by improving the average consensus algorithm solves the global optimality problem of energy storage balance and economic dispatch in microgrids, realizes the economic operation and energy storage balance of microgrids, and reduces the total power generation cost.
Patent Information
- Application Number
- CN202311303795.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-10-10
- Publication Date
- 2026-11-27
- Estimated Expiration
- 2043-10-10
AI Technical Summary
Existing technologies struggle to achieve both energy storage capacity balance and global economic optimization in microgrids, and existing distributed control strategies often fail to effectively balance energy storage capacity and economic dispatch.
An improved average consensus algorithm is used to establish a distributed control strategy. By acquiring the cost data of the microgrid, a traditional optimal economic scheduling model is established, and the improved average consensus algorithm is used to realize the distributed economic optimal control of the microgrid. This includes the definition of the objective function and constraint function, as well as the information exchange and power calculation between agents.
It enables rapid balancing of the energy storage system with fewer iterations, ensuring the minimization of total power generation costs and achieving global power generation demand and energy storage balance, thereby improving the economic operating efficiency and global optimal solution of the microgrid.
Smart Images

Figure CN117595268B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of microgrid economic dispatch technology, specifically to a microgrid distributed control method and system based on an improved average consensus algorithm. Background Technology
[0002] With the increasing prevalence of renewable energy sources, the uncertainties of microgrids, particularly those from wind turbines and photovoltaic power generation, are growing. A microgrid is a collection of generators, energy storage systems (ESS), generator sets, and loads, and can operate in islanded or grid-connected modes. In islanded mode, due to the lack of grid power, the ESS can use its rapid power regulation capabilities to balance the unbalanced power and load variations generated by renewable energy sources within the microgrid. In traditional large-scale grid centralized control, the reliability requirements of the control center are very high; communication failures at the control center can lead to the entire microgrid system going out of control. In distributed point-to-point control, each node often lacks sufficient local information, making it impossible to achieve a globally optimal solution through economic scheduling between nodes.
[0003] For a long time, centralized control with a hierarchical structure has been commonly used in engineering to solve problems such as energy storage balance, charging and discharging power control, current distribution, and active and reactive power control. However, the inherent limitations of centralized control structures still exist. Distributed control based on multi-agent systems, on the other hand, combines the global optimality of centralized control with the characteristics of reliability, plug-and-play functionality, and point-to-point control, effectively solving the aforementioned problems. In recent years, distributed control has been widely applied in economic dispatching and load control.
[0004] In existing research, X. Lu et al. (X. Lu and J. Lai, “Communication Constraints for Distributed Secondary Control of Heterogeneous Microgrids: A Survey,” IEEE Trans. Ind. Appl, vol. 57, no. 6, pp. 5636-5648, 2021.) proposed a distributed secondary control strategy considering communication constraints. J. Lai et al. (J. Lai, X. Lu, A. Monti, and RWD Doncker, “Event-Driven Distributed Active and Reactive Power Dispatch for CCVSI-Based Distributed Generators in AC Microgrids,” IEEE Trans. Ind. Appl, vol. 56, no. 3, pp. 3125-3136, 2020.) proposed a distributed event-driven active and reactive power distribution strategy for AC microgrids. This strategy can achieve load balancing of all generators and reduce communication bandwidth requirements, but it does not consider energy storage capacity and economic dispatch. Many existing research results on energy storage power balancing are based on improved droop control, which makes it difficult to achieve global optimization of microgrids. SI Gkavanoudis et al. (SI Gkavanoudis, KO Oureilidis, and CSDemoulias, “An adaptive droop control method for balancing the SoC of distributed batteries in AC microgrids,” in 2016 IEEE 17th Workshop on Control and Modeling for Power Electronics (COMPEL), 27-30 June 2016) proposed an improved droop control strategy to achieve energy storage power balancing, but these strategies can lead to frequency deviations in the microgrid bus.The strategy proposed by Q. Wu et al. (Q. Wu, R. Guan, X. Sun, Y. Wang, and X. Li, “SoC Balancing Strategy for Multiple Energy Storage Units With Different Capacities in Islanded Microgrids Based on Droop Control,” IEEE J. Emerging Sel. Top. PowerElectron., vol. 6, no. 4, pp. 1932-1941, 2018) does not require communication and takes into account the different capacities of the battery, balancing the energy storage capacity through improved droop control and local information. Y. Guan et al. (Y.Guan, L. Meng, C. Li, JC Vasquez, and JM Guerrero, “A Dynamic ConsensusAlgorithm to Adjust Virtual Impedance Loops for Discharge Rate Balancing of AC Microgrid Energy Storage Units,” IEEE Trans. Smart Grid, vol. 9, no. 5, pp. 4847-4860, 2018.) proposed a distributed secondary energy storage power balance control strategy based on the dynamic consensus algorithm (DCA). Each cell estimates the global average energy storage capacity and calculates the difference between the average and actual energy storage capacity. The virtual impedance is corrected by a PI controller using the calculated difference as input, and then the cell output power is adjusted; however, this does not consider the economics of cell operation.
[0005] Therefore, achieving global economic optimization and economic dispatch among energy storage systems while balancing battery power in a microgrid has become a key issue. This paper proposes a distributed economic optimal control method for microgrids based on an improved average consensus algorithm to address the problem of achieving global economic optimization while considering energy storage power balance. Summary of the Invention
[0006] In view of the above-mentioned problems, the present invention is proposed.
[0007] Therefore, the technical problem solved by this invention is to describe the general economic optimal scheduling model, then establish a distributed control strategy model based on the improved average consensus algorithm, and finally realize the distributed economic optimal control of microgrids using the improved average consensus algorithm.
[0008] To solve the above-mentioned technical problems, the present invention provides the following technical solution: a microgrid distributed control method based on an improved average consensus algorithm, comprising: Obtain cost data for microgrids; Establish a traditional optimal economic scheduling model to minimize the total power generation cost; Establish the objective function and constraint function of the distributed control strategy based on the improved average consensus algorithm; An improved average consensus algorithm is used to achieve distributed economic optimal control of microgrids.
[0009] As a preferred embodiment of the microgrid distributed control method based on the improved average consensus algorithm described in this invention, the cost data includes generator cost, fuel cost, and energy storage cost.
[0010] As a preferred embodiment of the microgrid distributed control method based on the improved average consensus algorithm described in this invention, the microgrid has n buses, and the buses... The generator cost is The traditional optimal economic scheduling model is expressed as: in, Represents a node The active power; The constraints are: in, Represents a node The active power of the distributed generator, Represents a node The active power of the load; The unit's active power meets the power limit constraints: in, Represents controllable unit The lower limit of active power, Represents controllable unit The upper limit of active power; The cost of a generator in a power system can be expressed as a quadratic function: in, , and It is the cost coefficient.
[0011] As a preferred embodiment of the microgrid distributed control method based on the improved average consensus algorithm described in this invention, the objective function includes the globally optimal objective function as follows: The globally optimal objective function includes, Economic objectives: Including the costs of energy storage and micro gas turbines, the goal is to achieve optimal operation. The cost function for energy storage is: in, Indicates entering the node The active power of energy storage, The coefficients of the linear terms, Represents the coefficient of the quadratic term; Fuel costs of micro gas turbines: in, This indicates the active power of the micro gas turbine. The coefficients of the linear terms, Represents the coefficient of the quadratic term; Energy storage SOC balance target: The change in energy storage SOC is incorporated into the target for balancing SOC, ensuring the strong convexity of the objective function. The variance of all SOCs is used, and the weights are dynamically adjusted using the deviation between the SOC of energy storage i and the average SOC. The SOC balance target is defined as follows: in, This represents the basic weighting coefficients for the impact of SOC. Indicates energy storage SOC, Indicates energy storage The average value, Indicates the interval time. This indicates the capacity of BESS.
[0012] As a preferred embodiment of the microgrid distributed control method based on the improved average consensus algorithm described in this invention, the constraint function includes: Power flow constraints: Power generation and load should be balanced; Energy storage power constraint: The output power of energy storage should be within the allowable range; in, and These are the upper and lower limits of energy storage capacity, respectively. Energy storage SOC constraints: Considering the lifespan and security of energy storage, the range that the energy storage SoC can maintain; in, and These are the upper and lower limits of the energy storage SOC; Micro gas turbine constraints: the range within which the output power of the micro gas turbine is maintained; in, This indicates the upper limit of the processing capacity of the micro gas turbine.
[0013] As a preferred embodiment of the microgrid distributed control method based on the improved average consensus algorithm described in this invention, the control includes: system initialization: generating a weighting matrix W using a particle swarm optimization algorithm; in the improved average consensus algorithm, the weighting matrix is represented as... in, The value is generated by heuristic algorithms and particle swarm optimization algorithms; Agent initialization: Initialize the agent state as follows: After initialization, each agent transmits data to its neighboring agents.
[0014] As a preferred embodiment of the microgrid distributed control method based on the improved average consensus algorithm described in this invention, the control further includes: the agent locally calculating and estimating the average SOC. Update the Lagrange multipliers: Power calculation: Update local requirements: like An agent should send its state to neighboring agents; otherwise, the agent will... , Used as a power reference value.
[0015] A microgrid distributed control system based on an improved average consensus algorithm, employing the method described in this invention, is characterized by: The data acquisition module obtains cost data for the microgrid. The analysis module establishes a traditional optimal economic scheduling model to minimize the total power generation cost; and establishes the objective function and constraint function of a distributed control strategy based on an improved average consensus algorithm. The control module utilizes an improved average consensus algorithm to achieve distributed economic optimal control of microgrids.
[0016] A computer device includes: a memory and a processor; the memory stores a computer program, characterized in that: when the processor executes the computer program, it implements the steps of the method described in any one of the present invention.
[0017] A computer-readable storage medium having a computer program stored thereon, characterized in that: when the computer program is executed by a processor, it implements the steps of the method described in any one of the present invention.
[0018] The beneficial effects of this invention: The microgrid distributed control method based on an improved average consensus algorithm provided by this invention focuses on the economic dispatch and energy storage balance of microgrids. By establishing a traditional optimal economic scheduling model and implementing a distributed control strategy based on an improved average consensus algorithm, this method ensures the minimization of total generation cost. During implementation, each agent unit tends to quickly balance its energy storage system and achieve average state consensus in fewer iterations, thereby obtaining an accurate estimate of the average SOC more quickly. Furthermore, through information exchange with neighboring agents, this strategy achieves energy complementarity between nodes, eliminates power shortages, and satisfies global generation demand balance constraints. Therefore, this invention achieves significant beneficial effects in the economic operation, energy storage balance, and global optimal solution of microgrids. Attached Figure Description
[0019] To more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort. Wherein: Figure 1 The overall flowchart of the microgrid distributed control method based on the improved average consensus algorithm provided in the first embodiment of the present invention; Figure 2 The power topology diagram of a 6-node system in the microgrid distributed control method based on an improved average consensus algorithm provided in the second embodiment of the present invention; Figure 3 The second embodiment of the present invention provides a power curve diagram of each node in a 6-node system of a microgrid distributed control method based on an improved average consensus algorithm. Detailed Implementation
[0020] To make the above-mentioned objects, features, and advantages of the present invention more apparent and understandable, specific embodiments of the present invention will be described in detail below with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of the present invention, and not all of them. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort should fall within the protection scope of the present invention.
[0021] Example 1 Reference Figure 1 As an embodiment of the present invention, a microgrid distributed control method based on an improved average consensus algorithm is provided, comprising: S1: Obtain cost data for the microgrid. Establish a traditional optimal economic scheduling model to minimize the total generation cost.
[0022] Furthermore, the cost data includes generator costs, fuel costs, and energy storage costs.
[0023] Suppose there are n buses in the microgrid. The generator cost is The traditional optimal economic scheduling model can be described as follows: In the formula, Represents a node The active power.
[0024] Its constraints are: In the formula, and These are nodes The active power of distributed generators and loads.
[0025] The active power of the generating unit should meet its power limit constraints: In the formula, and These are controllable units The lower and upper limits of active power.
[0026] The cost of a generator in a power system can be expressed as a quadratic function, typically: In the formula, , and This refers to the cost factor. Traditional microgrid energy management systems address the aforementioned optimization problem by collecting load and renewable energy information from all nodes in the microgrid. In the proposed distributed control strategy, limited information is exchanged among neighbors, enabling distributed collaborative optimization through agents to minimize global cost.
[0027] S2: Establish the objective function and constraint function of the distributed control strategy based on the improved average consensus algorithm.
[0028] Furthermore, its globally optimal objective function is: It includes the following parts: Economic objectives: Achieving optimal operation, including the costs of energy storage and micro gas turbines. The cost function for energy storage is... In the formula, Is entering the node The active power of energy storage. , These are the coefficients of the linear term and the quadratic term, respectively.
[0029] The fuel cost of a micro gas turbine is In the formula, It is the active power of the micro gas turbine. and These are the coefficients of the linear term and the quadratic term, respectively.
[0030] Energy Storage SOC Balance Objective: The variation in energy storage SOC is incorporated into the objective of balancing SOC. Energy storage with a higher SOC will tend to discharge or charge at lower power, while energy storage with a lower SOC will conversely charge or discharge at higher power. To ensure the strong convexity of the objective function, the variance of all SOCs is used, and the weights are dynamically adjusted using the deviation between the SOC of energy storage i and the average SOC. The SOC balance objective is defined as: In the formula, It is the basic weighting coefficient for the impact of SOC. and They are energy storage SoC and average value It refers to the interval time. This indicates the capacity of BESS.
[0031] Furthermore, the main constraints are: power flow constraints, and the need for a balance between power generation and load. Energy storage power constraints: The output power of energy storage should be within its allowable range to maintain safety. In the formula, and These are the upper and lower limits of energy storage capacity, respectively.
[0032] Energy storage SOC constraints: Considering the lifespan and safety of energy storage, the energy storage SoC should be kept within an appropriate range.
[0033] In the formula, and These are the upper and lower limits of the energy storage SoC.
[0034] Micro gas turbine constraints: The output power of the micro gas turbine should be kept within the allowable range.
[0035] In the formula, This represents the upper limit of the processing capacity of a micro gas turbine.
[0036] S3: Achieving distributed economic optimal control of microgrids based on an improved average consensus algorithm.
[0037] System initialization: The weighting matrix W is generated using the particle swarm optimization algorithm. In the improved average consensus algorithm, the weighting matrix is written as follows: in, The value is generated by heuristic algorithms and particle swarm optimization.
[0038] Agent initialization: Initialize the agent state as follows: After initialization, each agent transmits data to its neighboring agents.
[0039] Local computation by the agent includes estimating the average SOC: Update the Lagrange multipliers: Power calculation: Update local requirements: Communication: If The agent should send its state to neighboring agents. Otherwise, the agent will... , Used as a power reference value.
[0040] On the other hand, a microgrid distributed control system based on an improved average consensus algorithm using the method described in this invention is characterized by: a data acquisition module for acquiring cost data of the microgrid; an analysis module for establishing a traditional optimal economic scheduling model to minimize the total power generation cost; establishing the objective function and constraint function of the distributed control strategy based on the improved average consensus algorithm; and a control module for achieving distributed economic optimal control of the microgrid using the improved average consensus algorithm.
[0041] Those skilled in the art will understand that all or part of the processes in the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium, and when executed, it can include the processes of the embodiments described above. Any references to memory, databases, or other media used in the embodiments provided in this application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory, magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory, magnetic variable memory, ferroelectric memory, phase change memory, graphene memory, etc. Volatile memory can include random access memory or external cache memory, etc. By way of illustration and not limitation, RAM can be in various forms, such as static random access memory or dynamic random access memory, etc. The databases involved in the embodiments provided in this application can include at least one of relational databases and non-relational databases. Non-relational databases can include blockchain-based distributed databases, etc., and are not limited thereto.
[0042] The processors involved in the various embodiments provided in this application may be general-purpose processors, central processing units, graphics processors, digital signal processors, programmable logic devices, quantum computing-based data processing logic devices, etc., and are not limited thereto.
[0043] Example 2 Reference Figure 2-3 As an embodiment of the present invention, a microgrid distributed control method based on an improved average consensus algorithm is provided. To verify the beneficial effects of the present invention, scientific demonstration is carried out through economic benefit calculation and simulation experiments.
[0044] Taking a certain 6-node system as an example, ignoring its line losses, its structure is as follows: Figure 2 As shown. The load curves for the six nodes are attached. Figure 3 As shown. In During this period, there will be almost no new energy output, and all electricity demand will be met by micro gas turbines and energy storage. Photovoltaics in It started to rise from the left and right, and at It reaches its highest point, then begins to decline until... .
[0045] The overall objective function of the microgrid is a weighted sum of energy storage operating costs, fuel costs, and SOC variance. The weights of agent i's SOC variance are corrected for the difference between the actual and estimated SOC values. When there is a large difference between the actual and average SOC, the agent tends to balance the SOC first.
[0046] To validate the distributed optimization algorithm, the agents were analyzed based on the state at t=150s. The average SOC estimate for each agent reached consensus after 8 iterations. It can be seen that, under the proposed improved average consensus algorithm, the agents can achieve average state consensus with fewer iterations and obtain an accurate estimate of the average SOC more quickly. As mentioned earlier, the accuracy and speed of the estimation affect the optimization and power sharing results.
[0047] Net power requirements of each intelligent agent After 10 iterations, the curves converge and move towards the global optimum. Through information exchange with neighboring agents, this strategy enables energy complementarity between nodes, ultimately eliminating power shortages and satisfying the global power generation demand balance constraint.
[0048] It should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and are not intended to limit it. Although the present invention has been described in detail with reference to preferred embodiments, those skilled in the art should understand that modifications or equivalent substitutions can be made to the technical solutions of the present invention without departing from the spirit and scope of the technical solutions of the present invention, and all such modifications or substitutions should be covered within the scope of the claims of the present invention.
Claims
1. A distributed control method for microgrids based on an improved average consensus algorithm, characterized in that, include: Obtain cost data for microgrids; Establish a traditional optimal economic scheduling model to minimize the total power generation cost; Establish the objective function and constraint function of the distributed control strategy based on the improved average consensus algorithm; Achieving distributed economic optimal control of microgrids using an improved average consensus algorithm; Control measures include system initialization: generating a weighted matrix W using the particle swarm optimization algorithm; in the improved average consensus algorithm, the weighted matrix is represented as follows: in, The value is generated by heuristic algorithms and particle swarm optimization algorithms; Agent initialization: Initialize the agent state as follows: After initialization, each agent transmits data to its neighboring agents; The control also includes local computation by the agent to estimate the average SOC: Update the Lagrange multipliers: Power calculation: Update local requirements: in, Indicates the interval time. This indicates the capacity of BESS. Indicates energy storage SOC, This represents the basic weighting coefficients for the impact of SOC. Indicates energy storage The average value, The coefficients of the quadratic and linear terms in the energy storage cost function are represented. The coefficients of the quadratic term in the energy storage cost function are represented. The coefficient representing the linear term of fuel cost in a micro gas turbine. The coefficient representing the quadratic term of the fuel cost of a micro gas turbine. Indicates the upper limit of the processing capacity of the micro gas turbine; like An agent should send its state to neighboring agents; otherwise, the agent will... , Used as a power reference value.
2. The microgrid distributed control method based on the improved average consensus algorithm as described in claim 1, characterized in that: The cost data includes generator costs, fuel costs, and energy storage costs.
3. The microgrid distributed control method based on the improved average consensus algorithm as described in claim 2, characterized in that: A microgrid has n buses. The cost of the generator is The traditional optimal economic scheduling model is expressed as: in, Represents a node The active power; The constraints are: in, Represents a node The active power of the distributed generator, Represents a node The active power of the load; The active power of the unit meets the power limit constraints: in, Represents controllable unit The lower limit of active power, Represents controllable unit The upper limit of active power; The cost of a generator in a power system can be expressed as a quadratic function: in, , and It is the cost coefficient.
4. The microgrid distributed control method based on the improved average consensus algorithm as described in claim 3, characterized in that: The objective function includes, among which the globally optimal objective function is: The globally optimal objective function includes, Economic objectives: Including the costs of energy storage and micro gas turbines, the goal is to achieve optimal operation. The cost function for energy storage is: in, Indicates entering the node The active power of energy storage; Fuel costs of micro gas turbines: in, This indicates the active power of the micro gas turbine; Energy storage SOC balance target: The change in energy storage SOC is incorporated into the target for balancing SOC, ensuring the strong convexity of the objective function. The variance of all SOCs is used, and the weights are dynamically adjusted using the deviation between the SOC of energy storage i and the average SOC. The SOC balance target is defined as follows: 。 5. The microgrid distributed control method based on the improved average consensus algorithm as described in claim 4, characterized in that: The constraint functions include, Power flow constraints: Power generation and load should be balanced; Energy storage power constraint: The output power of energy storage should be within the allowable range; in, and These are the upper and lower limits of energy storage capacity, respectively. Energy storage SOC constraints: Considering the lifespan and security of energy storage, the range that the energy storage SoC can maintain; in, and These are the upper and lower limits of the energy storage SOC; Micro gas turbine constraints: the range within which the output power of the micro gas turbine is maintained; in, This indicates the upper limit of the processing capacity of the micro gas turbine.
6. A microgrid distributed control system based on an improved average consensus algorithm, employing the method described in claims 1-5, characterized in that: The data acquisition module obtains cost data for the microgrid. The analysis module establishes a traditional optimal economic scheduling model to minimize the total power generation cost; and establishes the objective function and constraint function of a distributed control strategy based on an improved average consensus algorithm. The control module utilizes an improved average consensus algorithm to achieve distributed economic optimal control of microgrids.
7. A computer device, comprising: Memory and processor; The memory stores a computer program, characterized in that: when the processor executes the computer program, it implements the steps of the method according to any one of claims 1 to 5.
8. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 5.
Citation Information
Patent Citations
Real-time distributed economic dispatching method suitable for grid-connected microgrid
CN110048415A
Power distribution network fault recovery method considering island dynamic division
CN115986813A
