Multi-agent-based energy node optimization adjustment method and device

By applying multi-agent deep reinforcement learning technology in microgrids and using the droop characteristic coefficients in action vectors to autonomously adjust energy nodes, the problem of unstable power supply of distributed energy sources in microgrids is solved, and voltage, frequency and load are realized. Distribution stability.

CN118868262APending Publication Date: 2024-10-29STATE GRID HEBEI ELECTRIC POWER CO LTD +2
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410890472.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-07-04
Publication Date
2024-10-29

AI Technical Summary

Technical Problem

There are many types of distributed energy resources in microgrids and various operating states. There are problems with unstable power supply. It is difficult to build a good optimized dispatching system and maintain the stability of power supply voltage, frequency and active and reactive power distribution ratio.

Method used

Using deep reinforcement learning technology based on multi-agent, the action vector is determined by inputting and processing the status vector of each energy device, and the active frequency droop characteristic coefficient and reactive voltage droop characteristic coefficient are used for optimal adjustment to maintain the microgrid. Stability of each node power, system frequency and voltage.

Benefits of technology

It achieves the stability of the power, system frequency and voltage of each node in the microgrid, ensures the proportional distribution of active and reactive loads among distributed power sources, has good stability and adaptability, and reduces the impact of unstable power sources.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118868262A_ABST
    Figure CN118868262A_ABST
Patent Text Reader

Abstract

The invention provides an energy node optimization adjustment method and device based on multiple agents, and belongs to the technical field of energy scheduling. The method is applied to a micro-grid system, the micro-grid system comprises a plurality of energy devices, and the devices comprise distributed power supplies, electrical loads and energy storage devices. The method comprises the following steps: for each energy device, forming a state vector of the energy device by operation parameters of the energy device in a micro-grid system; wherein the operation parameters comprise rated power, output angular frequency, current and voltage; for each energy device, inputting the state vector of the energy device into a built-in trained intelligent agent of the energy device, and determining an action vector of the energy device; wherein the action vector comprises an active frequency droop characteristic coefficient and a reactive voltage droop characteristic coefficient of the energy equipment; and based on each action vector, performing optimization adjustment on each energy device in the micro-grid system. According to the invention, the stability of node power, system frequency and voltage in the micro-grid can be maintained.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of energy scheduling, and in particular to a multi-agent-based energy node optimization and regulation method and device. Background Art

[0002] As energy crisis and environmental pollution become increasingly serious, research and development of green and clean renewable energy has become my country's energy development strategy and technical direction. Therefore, distributed energy including wind power, photovoltaics, energy storage units, etc. has developed rapidly and is widely used. Distributed energy represented by wind power and photovoltaics has the characteristics of intermittent, random and volatile, which brings great challenges to the grid connection and consumption of large-scale distributed energy and the optimal dispatching of power grids. Establishing a good microgrid dispatching system is of great significance to maintaining the stability of the power grid, ensuring the quality of power supply and reducing the cost of power generation.

[0003] However, there are many types of distributed power sources in microgrids, with various operating states, output characteristics and control methods, and there are many unstable power supplies. Therefore, it is imperative to build a good microgrid optimization dispatching system, maintain the stability of power supply voltage, frequency, and active and reactive power distribution ratio, integrate and complement multiple energy sources, and optimize them synergistically to build a comprehensive energy system. Summary of the invention

[0004] The embodiments of the present invention provide a method and device for optimizing and regulating energy nodes based on multi-agents to solve the problem of optimizing the scheduling of energy nodes in a microgrid.

[0005] In a first aspect, an embodiment of the present invention provides a multi-agent-based energy node optimization and adjustment method, which is applied to a microgrid system, wherein the microgrid system includes multiple energy devices, including distributed power sources, power loads, and energy storage devices; the method includes:

[0006] For each energy device, the operating parameters of the energy device in the microgrid system are combined into a state vector of the energy device; wherein the operating parameters include rated power, output angular frequency, current and voltage;

[0007] For each energy device, the state vector of the energy device is input into a trained intelligent agent built into the energy device to determine the action vector of the energy device; wherein the action vector includes an active frequency droop characteristic coefficient and a reactive voltage droop characteristic coefficient of the energy device;

[0008] Based on each action vector, each energy device in the microgrid system is optimized and adjusted.

[0009] In a possible implementation, for each energy device, the state vector of the energy device is input into a trained intelligent agent built into the energy device to determine the action vector of the energy device, including:

[0010] The state vector of the first energy device is input into the intelligent agent built into the first energy device, and the action vector of the first energy device is determined based on the state-action-value function corresponding to the trained intelligent agent built into the first energy device; wherein the first energy device is any energy device.

[0011] In a possible implementation, before inputting the state vector of each energy device into the intelligent agent built in the energy device to determine the action vector of the energy device, the method further includes:

[0012] Obtain the historical operating parameters of each energy device in the microgrid system and form a historical state vector;

[0013] Based on each historical state vector, each intelligent agent is reinforced trained to obtain multiple trained intelligent agents.

[0014] In a possible implementation, each agent is subjected to reinforcement training based on each historical state vector to obtain a plurality of trained agents, including:

[0015] Select multiple actors and multiple learners from each intelligent agent; each actor is used to perform different actions based on the historical state vector corresponding to the energy device where the actor is located, obtain the action and value corresponding to the historical state vector, and store them in the experience pool as experience; each learner is used to calculate the loss function value corresponding to each experience in the experience pool based on the constraint conditions, penalty function and loss function;

[0016] Based on the gradient descent method, the parameters of the state-action-value function of each intelligent agent are updated to determine the optimal state-action-value function of each intelligent agent, and multiple trained intelligent agents are obtained.

[0017] In one possible implementation, the optimal state*action*value function is:

[0018]

[0019] Among them, Q * (s t , a t ) is the optimal state-action-value function, s t is the state vector of the energy device at time t, a t is the action vector of the energy device at time t, π is the strategy value, E π is the expected long-term return generated by strategy π, rt+1 represents the penalty function at time t+1, and γ is the discount factor for future returns.

[0020] In a possible implementation, the constraints include:

[0021]

[0022] in, is the difference in output angular frequency between energy device i and energy device j at time t, δ0 is the output angular frequency difference threshold, is the output angular frequency of energy device i at time t, is the voltage difference between energy device i and energy device j at time t, is the voltage difference threshold, is the voltage of energy device i at time t, is the difference between the adjustable power ratios of energy device i and energy device j at time t, ε0 is the adjustable power ratio difference threshold, is the adjustable power ratio of energy device i at time t, is the rated power of energy device i, is the adjustable power of energy device i at time t.

[0023] In one possible implementation, the penalty function is:

[0024]

[0025] Among them, r t is the penalty function value of energy device i and energy device j at time t, α is the output angular frequency penalty coefficient, is the difference in output angular frequency between energy device i and energy device j at time t, β is the voltage penalty coefficient, is the voltage difference between energy device i and energy device j at time t, k is the power penalty coefficient, It is the difference between the adjustable power ratios of energy device i and energy device j at time t.

[0026] In one possible implementation, the loss function is:

[0027] L(θ)=E[(TargetQ-Q*(s, a, θ)) 2 ]

[0028]

[0029] Among them, L(θ) is the loss function, θ is the weight parameter, E[·] is the expectation, TargetQ is the target Q value, Q*(s, a, θ) is the optimal state-action-value function, r is the penalty function, and γ is the discount factor for future returns.

[0030] In a second aspect, an embodiment of the present invention provides an energy node optimization and adjustment device based on a multi-agent, which is applied to a microgrid system, wherein the microgrid system includes multiple energy devices, including distributed power sources, power loads, and energy storage devices; the device includes:

[0031] An acquisition module is used to, for each energy device, form a state vector of the energy device with the operating parameters of the energy device in the microgrid system; wherein the operating parameters include rated power, output angular frequency, current and voltage;

[0032] A calculation module is used for inputting the state vector of each energy device into a trained intelligent agent built into the energy device to determine the action vector of the energy device; wherein the action vector includes an active frequency droop characteristic coefficient and a reactive voltage droop characteristic coefficient of the energy device;

[0033] The regulation module is used to optimize and regulate various energy devices in the microgrid system based on various action vectors.

[0034] The embodiment of the present invention provides a multi-agent-based energy node optimization and adjustment method and device. Relying on the microgrid ecosystem and based on the distributed energy operation characteristics, a method is designed to integrate multi-agent deep reinforcement learning technology into distributed energy nodes, and the action vector of each energy node is determined respectively. The droop characteristic coefficient in the action vector is used to achieve autonomous adjustment and optimization, so as to maintain the stability of the power, system frequency and voltage of each node in the microgrid. BRIEF DESCRIPTION OF THE DRAWINGS

[0035] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0036] Figure 1 is a flowchart of an implementation of a multi-agent-based energy node optimization and adjustment method provided in an embodiment of the present invention;

[0037] Figure 2 is a schematic diagram of the structure of a deep convolutional neural network provided by an embodiment of the present invention;

[0038] Figure 3 is a flowchart for implementing preprocessing of a multi-agent system provided by an embodiment of the present invention;

[0039] Figure 4 It is a structural diagram of an energy node optimization and adjustment device based on multi-agents provided in an embodiment of the present invention. DETAILED DESCRIPTION

[0040] In the following description, specific details such as specific system structures, technologies, etc. are provided for the purpose of illustration rather than limitation, so as to provide a thorough understanding of the embodiments of the present invention. However, it should be clear to those skilled in the art that the present invention may be implemented in other embodiments without these specific details. In other cases, detailed descriptions of well-known systems, devices, circuits, and methods are omitted to prevent unnecessary details from obstructing the description of the present invention.

[0041] In order to make the purpose, technical solutions and advantages of the present invention more clear, specific embodiments will be described below in conjunction with the accompanying drawings.

[0042] Figure 1 The implementation flow chart of the multi-agent-based energy node optimization and adjustment method provided in the embodiment of the present invention is detailed as follows:

[0043] The method is applied to a microgrid system, which includes multiple energy devices, including distributed power sources, power loads and energy storage devices; the method includes:

[0044] Step 101, for each energy device, the operating parameters of the energy device in the microgrid system are combined into a state vector of the energy device; wherein the operating parameters include rated power, output angular frequency, current and voltage.

[0045] In this embodiment, the state vector st of energy device i can be expressed as:

[0046]

[0047] Among them, P i* is the rated power of energy device i, ω i* is the output angular frequency of the energy device i under rated conditions, and They are the real-time current and voltage of energy device i in period t. The current and voltage are time series data, including the entire complete cycle sequence of the microgrid from the start of operation to the end of adjustment.

[0048] Step 102, for each energy device, input the state vector of the energy device into a trained intelligent agent built into the energy device to determine the action vector of the energy device; wherein the action vector includes the active frequency droop characteristic coefficient and the reactive voltage droop characteristic coefficient of the energy device.

[0049] In this embodiment, the action vector a of energy device i t It can be expressed as:

[0050]

[0051] The energy nodes in the microgrid system use the droop control strategy to complete the action adjustment, where m is the active frequency droop characteristic coefficient, n is the reactive voltage droop characteristic coefficient, represents the active frequency droop characteristic coefficient of energy node i at time t, Represents the reactive voltage droop characteristic coefficient of energy node i at time t. This embodiment determines the action vector of each energy node according to the current state of the microgrid system, adjusts the droop coefficient respectively, and drives the system to operate autonomously.

[0052] Step 103: Optimize and adjust each energy device in the microgrid system based on each action vector.

[0053] In this embodiment, the state vector is input as a sequence into the deep neural network of each agent, passes through the fully connected layer, and finally obtains the approximate value in the output layer to determine the action vector a t , and control the energy nodes in the microgrid for autonomous regulation.

[0054] The embodiment of the present invention relies on the microgrid ecosystem and is based on the operating characteristics of distributed energy. It designs a method that integrates multi-agent deep reinforcement learning technology into distributed energy nodes, determines the action vector of each energy node respectively, and uses the droop characteristic coefficient in the action vector to achieve autonomous adjustment and optimization, thereby maintaining the stability of the power, system frequency and voltage of each node in the microgrid.

[0055] In a possible implementation, for each energy device, the state vector of the energy device is input into a trained intelligent agent built into the energy device to determine the action vector of the energy device, including:

[0056] The state vector of the first energy device is input into the intelligent agent built into the first energy device, and the action vector of the first energy device is determined based on the state-action-value function corresponding to the trained intelligent agent built into the first energy device; wherein the first energy device is any energy device.

[0057] In this embodiment, the operation space of the agent in this embodiment includes a state space and an action space. The state space includes the rated power P of each distributed energy node. i* , output angular frequency ω under rated conditions i* , real-time current and voltage Right now The current and voltage are time series data, including the entire cycle sequence of the microgrid from the start of operation to the end of adjustment.

[0058] The action space includes the distributed generation adjustment droop coefficient That is, the system adjusts the droop coefficient according to the current state of the microgrid system and drives the system to operate autonomously.

[0059] During the optimization and adjustment process, a penalty function is used to penalize the frequency, voltage imbalance and whether the distribution is proportional. The greater the deviation, the greater the penalty. If the deviation is within a certain range, the penalty is zero.

[0060] During the learning process, the state vector is used as a sequence as the input neural network and connected to the fully connected layer, and finally the approximated Q(m i , n i ) value, and each distributed energy source is dynamically adjusted according to the generated value.

[0061] In a possible implementation, before inputting the state vector of each energy device into the intelligent agent built in the energy device to determine the action vector of the energy device, the method further includes:

[0062] Obtain the historical operating parameters of each energy device in the microgrid system and form a historical state vector;

[0063] Based on each historical state vector, each intelligent agent is reinforced trained to obtain multiple trained intelligent agents.

[0064] In this embodiment, before using the intelligent agent to optimize the action of the energy device, it is necessary to perform preprocessing of the multi-agent system, including fusion sorting, structural integration and other operations. Figure 3 As shown, the details are as follows:

[0065] Construct a multi-agent, construct a deep convolutional neural network model based on the DQN algorithm, and train and update the deep convolutional neural network model based on the multi-agent and the output data; the structure of the deep convolutional neural network is as follows Figure 2 shown.

[0066] Construct constraints and penalty functions, optimize the deep convolutional neural network model based on the constraints and the penalty function, and use the deep convolutional neural network model that has completed training as an energy node autonomous adjustment model.

[0067] Deep reinforcement learning (DRL) combines the perception ability of deep learning with the decision-making ability of reinforcement learning. It can be controlled directly according to the input data. It is an artificial intelligence method that is closer to the human way of thinking. Deep learning uses representation learning to refine data. It does not need to select features, compress dimensions, convert formats, etc. to process data. It has stronger feature representation capabilities than traditional machine learning methods. It combines low-level features to form more abstract high-level features to achieve distributed representation of data. Reinforcement learning originated from the optimal control theory in cybernetics. It is mainly used to solve time-series decision-making problems. Through continuous interaction with the environment and trial and error, it finally obtains the optimal strategy for a specific task and maximizes the cumulative expected return of the task. Deep reinforcement learning combines the two and can solve decision-making problems well. In recent years, it has been widely used in video games, navigation, multi-agent collaboration, and recommendation systems.

[0068] In a possible implementation, each agent is subjected to reinforcement training based on each historical state vector to obtain a plurality of trained agents, including:

[0069] Select multiple actors and multiple learners from each intelligent agent; each actor is used to perform different actions based on the historical state vector corresponding to the energy device where the actor is located, obtain the action and value corresponding to the historical state vector, and store them in the experience pool as experience; each learner is used to calculate the loss function value corresponding to each experience in the experience pool based on the constraint conditions, penalty function and loss function;

[0070] Based on the gradient descent method, the parameters of the state-action-value function of each intelligent agent are updated to determine the optimal state-action-value function of each intelligent agent, and multiple trained intelligent agents are obtained.

[0071] In this embodiment, distributed training and decentralized execution are adopted, that is, during training, global observation information is introduced to guide the training, while during testing, only local observations are used to take actions.

[0072] The specific steps for training using a distributed architecture are:

[0073] Acquire a plurality of different actors and a plurality of learners based on the multi-agent;

[0074] Each actor copies a copy of the output data, and performs different actions in the same environment to obtain different experiences; the experiences of several actors interacting with the environment are stored in the experience pool; several learners calculate the gradient of the loss function by using the experience data stored in the experience pool; the gradient sent by the learner is received through the parameter server, and the parameters of the output data are updated by gradient descent to obtain the update result. The benefit corresponds to the penalty, and the benefit or penalty is obtained according to a certain action. The physical quantity reflected by the benefit here is the angular frequency difference, voltage difference, etc. within a reasonable range.

[0075] After obtaining the deep convolutional neural network model based on the DQN algorithm and the above update results, the doubleDQN method is used to evaluate and decouple the deep convolutional neural network model.

[0076] In one possible implementation, the optimal state-action-value function is:

[0077]

[0078] Among them, Q * (s t , a t ) is the optimal state-action-value function, s t is the state vector of the energy device at time t, a t is the action vector of the energy device at time t, π is the strategy value, E π is the expected long-term return generated by strategy π, r t+1 represents the penalty function at time t+1, and γ is the discount factor for future returns.

[0079] In one possible implementation, the loss function is:

[0080] L(θ)=E[(TargetQ-Q*(s, a, θ)) 2 ]

[0081]

[0082] Among them, L(θ) is the loss function, θ is the weight parameter, E[·] is the expectation, TargetQ is the target Q value, and Q * (s, a, θ) is the optimal state-action-value function, r is the penalty function, and γ is the discount factor for future rewards.

[0083] In this embodiment, the distributed energy node autonomous adjustment and optimization problem model is represented as a quintuple (n, S, A, P, R), where: n represents the number of multi-agents, S represents the set of states, A represents the set of actions, P represents the state transition probability, and R represents the penalty function.

[0084] Under the strategy π, when the agent is in state S t Execute action a t and transfer to the next state S with probability P t+1 , while receiving feedback from the environment r t , that is, the penalty function. In order to reduce the impact of future returns on the current, the future returns need to be multiplied by the discount factor γ. The state-action value function Q π (s, a), that is, given the current state s and action a, the expected long-term return generated under the action of strategy π, the optimal state * action * value function Q * (s) is the value function with the largest value among all strategies, that is, the optimal strategy value function. Combined with the Bellman equation, the formula is as follows:

[0085]

[0086] Using the function approximation method to represent the value function, the DQN algorithm uses a deep convolutional neural network to approximate the Q function:

[0087]

[0088] The above formula indicates that the energy node state s at the current time t is known t and action a t vector, the expected long-term return E generated under the action of strategy π. π represents the strategy value, Q π (s, a) represents the state-action value function, r t represents the penalty function at time t, γ represents the future return discount factor, Q * (s, a) is the optimal state-action value function.

[0089] Among them, α represents the solution step size. When updating the value function, it is actually updating the parameter ω. The gradient descent method is used to solve the loss function to minimize the value. When the parameter ω is obtained, the training is completed and the optimal state-action-value function is obtained.

[0090] In a possible implementation, the constraints include:

[0091]

[0092] in, is the difference in output angular frequency between energy device i and energy device j at time t, δ0 is the output angular frequency difference threshold, is the output angular frequency of energy device i at time t, is the voltage difference between energy device i and energy device j at time t, is the voltage difference threshold, is the voltage of energy device i at time t, is the difference between the adjustable power ratios of energy device i and energy device j at time t, ε0 is the adjustable power ratio difference threshold, is the adjustable power ratio of energy device i at time t, is the rated power of energy device i, is the adjustable power of energy device i at time t.

[0093] In this embodiment, in order to maintain the stability of the system frequency and voltage in the microgrid, it is required to achieve proportional distribution of active and reactive loads among distributed power sources within a certain error range. The above constraints respectively indicate that at time t, the system frequency, voltage and adjustable power ratio of any two energy nodes are consistent.

[0094] In one possible implementation, the penalty function is:

[0095]

[0096] Among them, r t is the penalty function value of energy device i and energy device j at time t, α is the output angular frequency penalty coefficient, is the difference in output angular frequency between energy device i and energy device j at time t, β is the voltage penalty coefficient, is the voltage difference between energy device i and energy device j at time t, k is the power penalty coefficient, It is the difference between the adjustable power ratios of energy device i and energy device j at time t.

[0097] In this embodiment, the frequency, voltage imbalance and whether the distribution is proportional are penalized. The greater the deviation, the greater the penalty. If the deviation is within the range of 0.05, the penalty is zero. The specific penalty value is determined by the penalty coefficient.

[0098] As can be seen from the above, the present invention collects the output data of energy equipment and pre-processes the output data; constructs multi-agents, constructs a deep convolutional neural network model based on the DQN algorithm, trains and updates the deep reinforcement learning model based on the multi-agents and output data; constructs constraints and penalty functions, optimizes the model based on the constraints and penalty functions, and uses the model that has finished training as the energy node autonomous adjustment model; and autonomously adjusts the energy nodes in the microgrid based on the energy node autonomous adjustment model. The present invention relies on the microgrid ecosystem and designs a distributed energy node that incorporates multi-agent deep reinforcement learning technology based on the operating characteristics of distributed energy, realizes its autonomous adjustment and optimization, uses deep reinforcement learning to calculate the optimal state-action-value function Q for the agent, and adjusts the agent state to maintain the stability of the system frequency and voltage in the microgrid, and within a certain error range, realizes the proportional distribution of active and reactive loads among distributed power sources.

[0099] The double DQN method is used to effectively deal with the over-estimation problem, and the current state-action value function can be accurately obtained, so as to maintain the voltage, frequency, and active and reactive power distribution ratio well. It also has good stability and adaptability to unstable power supplies, and makes full use of computing resources using a distributed architecture to speed up the algorithm training speed, greatly reducing the training time.

[0100] The deep reinforcement learning network breaks the correlation between data through the experience replay mechanism and random small batch sampling, reducing the impact of unstable data such as wind power and photovoltaics.

[0101] In order to meet the requirements of the microgrid to maintain stable voltage, frequency, and active and reactive power distribution ratio, reasonable constraints are set and a penalty function for calculating the state-action value-function is customized. The larger the deviation, the greater the penalty for the power source, so the power source with large deviation can be corrected quickly.

[0102] It can reuse training models under low-redundancy training conditions, flexibly adapt to various power transmission network construction issues, and greatly reduce the problem of algorithm repetitive training caused by changes in task conditions.

[0103] It should be understood that the order of execution of the steps in the above embodiment does not necessarily mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiment of the present invention.

[0104] The following is an embodiment of the device of the present invention. For details not described in detail therein, reference may be made to the corresponding method embodiment described above.

[0105] Figure 4 The schematic diagram of the structure of the multi-agent based energy node optimization and adjustment device provided by the embodiment of the present invention is shown. For the convenience of explanation, only the part related to the embodiment of the present invention is shown, which is described in detail as follows:

[0106] like Figure 4 As shown, the multi-agent-based energy node optimization and regulation device 4 is applied to a microgrid system, which includes multiple energy devices, including distributed power sources, power loads and energy storage devices; the device includes:

[0107] An acquisition module 41 is used for, for each energy device, forming a state vector of the energy device with operating parameters of the energy device in the microgrid system; wherein the operating parameters include rated power, output angular frequency, current and voltage;

[0108] The calculation module 42 is used for inputting the state vector of each energy device into the trained intelligent agent built into the energy device to determine the action vector of the energy device; wherein the action vector includes the active frequency droop characteristic coefficient and the reactive voltage droop characteristic coefficient of the energy device;

[0109] The adjustment module 43 is used to optimize and adjust each energy device in the microgrid system based on each action vector.

[0110] In a possible implementation, the calculation module 42 is specifically configured to:

[0111] The state vector of the first energy device is input into the intelligent agent built into the first energy device, and the action vector of the first energy device is determined based on the state-action-value function corresponding to the trained intelligent agent built into the first energy device; wherein the first energy device is any energy device.

[0112] In a possible implementation, the acquisition module 41 is further configured to:

[0113] For each energy device, before inputting the state vector of the energy device into the intelligent agent built in the energy device and determining the action vector of the energy device, the historical operating parameters of each energy device in the microgrid system are obtained to form a historical state vector;

[0114] Based on each historical state vector, each intelligent agent is reinforced trained to obtain multiple trained intelligent agents.

[0115] In a possible implementation, the acquisition module 41 is specifically used to:

[0116] Select multiple actors and multiple learners from each intelligent agent; each actor is used to perform different actions based on the historical state vector corresponding to the energy device where the actor is located, obtain the action and value corresponding to the historical state vector, and store them in the experience pool as experience; each learner is used to calculate the loss function value corresponding to each experience in the experience pool based on the constraint conditions, penalty function and loss function;

[0117] Based on the gradient descent method, the parameters of the state-action-value function of each intelligent agent are updated to determine the optimal state-action-value function of each intelligent agent, and multiple trained intelligent agents are obtained.

[0118] In one possible implementation, the optimal state-action-value function is:

[0119]

[0120] Among them, Q * (s t , a t) is the optimal state-action-value function, s t is the state vector of the energy device at time t, a t is the action vector of the energy device at time t, π is the strategy value, E π is the expected long-term return generated by strategy π, r t+1 represents the penalty function at time t+1, and γ is the discount factor for future returns.

[0121] In a possible implementation, the constraints include:

[0122]

[0123] in, is the difference in output angular frequency between energy device i and energy device j at time t, δ0 is the output angular frequency difference threshold, is the output angular frequency of energy device i at time t, is the voltage difference between energy device i and energy device j at time t, is the voltage difference threshold, is the voltage of energy device i at time t, is the difference between the adjustable power ratios of energy device i and energy device j at time t, ε0 is the adjustable power ratio difference threshold, is the adjustable power ratio of energy device i at time t, is the rated power of energy device i, is the adjustable power of energy device i at time t.

[0124] In one possible implementation, the penalty function is:

[0125]

[0126] Among them, r t is the penalty function value of energy device i and energy device j at time t, α is the output angular frequency penalty coefficient, is the difference in output angular frequency between energy device i and energy device j at time t, β is the voltage penalty coefficient, is the voltage difference between energy device i and energy device j at time t, k is the power penalty coefficient, It is the difference between the adjustable power ratios of energy device i and energy device j at time t.

[0127] In one possible implementation, the loss function is:

[0128] L(θ)=E[(TargetQ-Q*(s, a, θ)) 2 ]

[0129]

[0130] Among them, L(θ) is the loss function, θ is the weight parameter, E[·] is the expectation, TargetQ is the target Q value, and Q * (s, a, θ) is the optimal state-action-value function, r is the penalty function, and γ is the discount factor for future rewards.

[0131] The embodiment of the present invention relies on the microgrid ecosystem and is based on the operating characteristics of distributed energy. It designs a method that integrates multi-agent deep reinforcement learning technology into distributed energy nodes, determines the action vector of each energy node respectively, and uses the droop characteristic coefficient in the action vector to achieve autonomous adjustment and optimization, thereby maintaining the stability of the power, system frequency and voltage of each node in the microgrid.

[0132] In the above embodiments, the description of each embodiment has its own emphasis. For parts that are not described or recorded in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.

[0133] Those of ordinary skill in the art will appreciate that the templates, units, and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of the present invention.

[0134] If the module / unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the present invention implements all or part of the processes in the above-mentioned embodiment method, and can also be completed by instructing the relevant hardware through a computer program. The computer program can be stored in a computer-readable storage medium. When the computer program is executed by the processor, it can implement the steps of the above-mentioned various multi-agent-based energy node optimization and adjustment method embodiments. Among them, the computer program includes computer program code, and the computer program code can be in source code form, object code form, executable file or some intermediate form. The computer-readable medium may include: any entity or device that can carry the computer program code, recording medium, U disk, mobile hard disk, disk, optical disk, computer memory, read-only memory, random access memory, electrical carrier signal, telecommunication signal and software distribution medium.

[0135] The embodiments described above are only used to illustrate the technical solutions of the present invention, rather than to limit the same. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features may be replaced by equivalents. Such modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention, and should all be included in the protection scope of the present invention.

Claims

1. A multi-agent based energy node optimization and adjustment method, characterized in that: Applied to a microgrid system, the microgrid system includes a plurality of energy devices, the devices include a distributed power source, a power load and an energy storage device; the method includes: For each energy device, the operating parameters of the energy device in the microgrid system are combined into a state vector of the energy device; wherein the operating parameters include rated power, output angular frequency, current and voltage; For each energy device, the state vector of the energy device is input into a trained intelligent agent built into the energy device to determine the action vector of the energy device; wherein the action vector includes an active frequency droop characteristic coefficient and a reactive voltage droop characteristic coefficient of the energy device; Based on each action vector, each energy device in the microgrid system is optimized and adjusted.

2. The multi-agent based energy node optimization and adjustment method according to claim 1 is characterized in that: For each energy device, inputting the state vector of the energy device into a trained intelligent agent built into the energy device to determine the action vector of the energy device includes: The state vector of the first energy device is input into the intelligent agent built into the first energy device, and the action vector of the first energy device is determined based on the state-action-value function corresponding to the trained intelligent agent built into the first energy device; wherein the first energy device is any energy device.

3. The multi-agent based energy node optimization and adjustment method according to claim 1 is characterized in that: Before inputting the state vector of each energy device into the intelligent agent built in the energy device to determine the action vector of the energy device, the method further includes: Obtaining historical operating parameters of each energy device in the microgrid system and forming a historical state vector; Based on each historical state vector, each intelligent agent is reinforced trained to obtain multiple trained intelligent agents.

4. The multi-agent based energy node optimization and adjustment method according to claim 3 is characterized in that: The method further comprises performing intensive training on each intelligent agent based on each historical state vector to obtain a plurality of trained intelligent agents, including: Select multiple actors and multiple learners from each intelligent agent; each actor is used to perform different actions based on the historical state vector corresponding to the energy device where the actor is located, obtain the action and value corresponding to the historical state vector, and store them in the experience pool as experience, and each learner is used to calculate the loss function value corresponding to each experience in the experience pool based on the constraint conditions, penalty function and loss function; Based on the gradient descent method, the parameters of the state-action-value function of each intelligent agent are updated to determine the optimal state-action-value function of each intelligent agent, and multiple trained intelligent agents are obtained.

5. The multi-agent based energy node optimization and adjustment method according to claim 4 is characterized in that: The optimal state-action-value function is: Among them, Q * (s t ,a t ) is the optimal state-action-value function, s t is the state vector of the energy device at time t, a t is the action vector of the energy device at time t, π is the strategy value, E π is the expected long-term return generated by strategy π, r t+1 represents the penalty function at time t+1, and γ is the discount factor for future returns.

6. The multi-agent based energy node optimization and adjustment method according to claim 4 is characterized in that: The constraints include: in, is the difference in output angular frequency between energy device i and energy device j at time t, δ0 is the output angular frequency difference threshold, is the output angular frequency of energy device i at time t, is the voltage difference between energy device i and energy device j at time t, is the voltage difference threshold, is the voltage of energy device i at time t, is the difference between the adjustable power ratios of energy device i and energy device j at time t, ε0 is the adjustable power ratio difference threshold, is the adjustable power ratio of energy device i at time t, is the rated power of energy device i, is the adjustable power of energy device i at time t.

7. The multi-agent based energy node optimization and adjustment method according to claim 4 is characterized in that: The penalty function is: Among them, r t is the penalty function value of energy device i and energy device j at time t, α is the output angular frequency penalty coefficient, is the difference in output angular frequency between energy device i and energy device j at time t, β is the voltage penalty coefficient, is the voltage difference between energy device i and energy device j at time t, k is the power penalty coefficient, It is the difference between the adjustable power ratios of energy device i and energy device j at time t.

8. The multi-agent based energy node optimization and adjustment method according to claim 4 is characterized in that: The loss function is: L(θ)=E[(TargetQ-Q * (s,a,θ)) 2 ] Among them, L(θ) is the loss function, θ is the weight parameter, E[·] is the expectation, TargetQ is the target Q value, and Q * (s,a,θ) is the optimal state-action-value function, r is the penalty function, and γ is the discount factor for future returns.

9. An energy node optimization and adjustment device based on multi-agent, characterized in that: Applied to a microgrid system, the microgrid system includes multiple energy devices, the devices include distributed power sources, power loads and energy storage devices; the devices include: An acquisition module is used to, for each energy device, form a state vector of the energy device with the operating parameters of the energy device in the microgrid system; wherein the operating parameters include rated power, output angular frequency, current and voltage; A calculation module is used for inputting the state vector of each energy device into a trained intelligent agent built into the energy device to determine the action vector of the energy device; wherein the action vector includes an active frequency droop characteristic coefficient and a reactive voltage droop characteristic coefficient of the energy device; The adjustment module is used to optimize and adjust each energy device in the microgrid system based on each action vector.

10. The multi-agent based energy node optimization and adjustment device according to claim 9, characterized in that: The calculation module is specifically used for: The state vector of the first energy device is input into the intelligent agent built into the first energy device, and the action vector of the first energy device is determined based on the state-action-value function corresponding to the trained intelligent agent built into the first energy device; wherein the first energy device is any energy device.