Multi-energy micro-grid energy regulation and control method and device and storage medium

By using the Stackelberg game model and rolling model predictive control in multi-energy microgrids, MEMG solves the problem of balancing power service income and power purchase costs, and realizes the control of renewable distributed generation and multi-energy loads. Effective management ensures reliable operation of the system and balanced power transactions.

CN118554455AInactive Publication Date: 2024-08-27STATE GRID ZHEJIANG ELECTRIC POWER CO MARKETING SERVICE CENT +2
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410524007.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-04-29
Publication Date
2024-08-27
Estimated Expiration
Not applicable · inactive patent

AI Technical Summary

Technical Problem

Multi-energy microgrid (MEMG) is difficult to balance between maximizing the benefits of providing power services to users and minimizing power purchase costs for users. It also needs to deal with the uncertainty of renewable distributed generation and multi-energy loads to ensure the stability of the system. Reliable operation.

Method used

A data-driven chance constraint is constructed based on the quantile forecasting method, combined with the Stackelberg game model and a distributed iterative algorithm integrating dichotomy, to realize strategic games in internal day-ahead market transactions, and use rolling in the real-time control phase. Model predictive control method supports real-time energy control of multi-energy microgrids.

Benefits of technology

It achieves the balance of power transactions between MEMG and users without violating privacy, effectively copes with the uncertainty of the upstream power market, RDG, and multi-energy loads, ensuring the supply and demand balance of the internal real-time market and the reliable operation of the system.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118554455A
    Figure CN118554455A
Patent Text Reader

Abstract

The invention discloses a multi-energy micro-grid energy regulation and control method and device and a storage medium. The method comprises the following steps: constructing a data-driven opportunity constraint based on a quantile prediction method, including users in an internal day-ahead market transaction, and including uncertainty of renewable distributed power generation and multi-energy loads in a multi-energy micro-grid; based on the internal day-ahead market of the Stackelberg game, a strategy game between an operator and a user in the multi-energy micro-grid is captured, and oscillation in an iteration process is eliminated by adopting a distributed iteration algorithm fused with a dichotomy to promote game convergence; and in the real-time regulation and control stage, a rolling model prediction control method is adopted to realize real-time energy regulation and control of the multi-energy micro-grid and a plurality of producers so as to support internal real-time market transactions. According to the invention, a real-time energy regulation and control model based on rolling model predictive control is established in a real-time regulation and control stage, and an actual operation scheme of the multi-energy microgrid and all users is determined to support internal real-time market transactions, so that real-time supply and demand balance is ensured.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of multi-energy microgrids, and in particular to a multi-energy microgrid energy control method, device and storage medium. Background Art

[0002] As a green and efficient energy utilization form that integrates multiple heterogeneous energy sources, Multi-Energy Micro-Grid (MEMG) has shown great potential in meeting diversified energy needs, reducing energy costs, and promoting the consumption of renewable distributed generation (RDG). MEMG not only manages flexible resources within its jurisdiction, but also plays the role of providing electricity services to surrounding users as a retailer. Therefore, MEMG will participate in the upstream electricity market as an intermediary on behalf of users. With the development of power technology, users have gradually begun to configure resources such as RDG and electric energy storage systems (ESS), and have transformed from a simple consumer to a prosumer, so that they no longer simply consume the electricity provided by MEMG but interact with it. Therefore, MEMG can provide a platform for coordinating energy sharing between it and users and between users to improve the overall energy utilization efficiency. However, MEMG and these users generally belong to different interest entities, so they have privacy protection requirements for their information. Moreover, MEMG and users will present competing interests, among which MEMG hopes to maximize the benefits of providing electricity services to users, while users hope to reduce the cost of purchasing electricity as much as possible. Therefore, constructing a reasonable internal electricity market to balance the interests of various entities while considering privacy protection is crucial to achieving optimal energy sharing and energy management of the entire MEMG.

[0003] In addition to participating in internal electricity market transactions, MEMG must also participate in the upstream electricity market to obtain stable electricity support from the outside world. Therefore, the energy management of the energy-sharing MEMG must take into account the uncertainty of the upstream electricity market and coordinate the upstream real-time market participation decision-making and internal electricity market transaction plans.

[0004] It is also important that the energy management strategy of the entire MEMG must be able to properly handle the uncertainties originating from RDG and multi-energy loads to ensure the reliable operation of MEMG and users. Summary of the invention

[0005] The main technical problem solved by the present invention is to provide a multi-energy microgrid energy control method to solve the problem of balancing the benefits of MEMG in providing power services to users to the maximum extent possible and the users in reducing the electricity purchase costs to the maximum extent possible.

[0006] In order to solve the above technical problems, a technical solution adopted by the present invention is to provide a multi-energy microgrid energy control method, comprising the steps of:

[0007] Step S1: Construct data-driven opportunity constraints based on the quantile forecasting method, incorporate users in the internal day-ahead market transactions, and include the uncertainties of renewable distributed generation and multi-energy loads in the multi-energy microgrid;

[0008] Step S2: Based on the internal day-ahead market of Stackelberg game, the strategic game between operators and users in the multi-energy microgrid is captured, and the distributed iterative algorithm of fusion dichotomy is used to eliminate the oscillation in the iteration process and promote the convergence of the game;

[0009] Step S3: In the real-time control stage, the rolling model predictive control method is used to realize the real-time energy control of multi-energy microgrids and multiple prosumers to support internal real-time market transactions.

[0010] Preferably, the strategic interaction between the MEMG operator and the user during the game, the SG model (Stackelberg game model) has the following elements:

[0011] (1) Participants: MEMG operators (leaders) and users (multiple followers);

[0012] (2) Strategy set: The leader’s strategy set is the internal day-ahead market price clearing scheme based on the followers’ trading protocol. Including the electricity price sold by the MEMG operator to the i-th user in the l-th hour and electricity purchase price The strategy set of multiple followers is the power trading protocol they formulate based on the leader's power price clearing plan. Includes the electricity sold by the i-th user to the MEMG operator in the l-th hour and purchased electricity

[0013] (3) Utility function: The utility functions of MEMG operators and users are the objective functions of their respective day-ahead scheduling models.

[0014] Preferably, the objective function of the leader model under a specific real-time electricity price scenario s is formulated as follows:

[0015]

[0016] where F m,s represents the total operating cost of MEMG in the sth scenario; C DA represents the day-ahead bidding cost of MEMG in the upstream wholesale electricity market; and They represent the electricity purchase cost and penalty cost of MEMG in the upstream real-time market in the sth scenario respectively; represents the natural gas procurement cost of MEMG in the sth scenario; and They represent the decay costs of ESS and thermal storage system (TSS) in MEMG under the s-th scenario respectively; and They respectively represent the electricity purchasing cost and electricity selling revenue of MEMG in the internal day-ahead market.

[0017] Preferably, the objective function of the MEMG operator model must satisfy the pricing constraints shown in equations (4-17), (4-18) and (4-19) and the operational constraints described in (2)-(6) below;

[0018] (1) MEMG operator pricing constraints: The customized electricity price that the MEMG operator clears for each user and In this model, it is a decision variable, and the constraints it must satisfy are shown in the following equations (4-17), (4-18) and (4-19):

[0019]

[0020]

[0021]

[0022] in and They represent the lower and upper limits of the electricity price that MEMG sells to users in the first hour, which can be formulated with reference to the day-ahead electricity price in the upstream competitive power market; L represents the total number of hours in the entire time range; μ av is the average price of electricity sold by MEMG to users; ε represents the price coefficient of electricity purchased by MEMG to users and ε<1; Ω H ={1,2,...,24};

[0023] (2) CHP (combined heat and power unit) operation constraints:

[0024]

[0025]

[0026] in P CHP and They represent the lower and upper limits of the CHP output electric power respectively; represents the output thermal power of CHP at the tth moment in the sth scenario; b is the thermal-electric ratio of CHP; represents the output power of the CHP unit at the tth moment in the sth scenario;

[0027] (3)EB operation constraints:

[0028]

[0029]

[0030] in H EB and They represent the lower and upper limits of the thermal power output of the electric boiler (EB) respectively; and They represent the output thermal power and electrical power consumed by EB at the tth moment in the sth scenario respectively; η EB is the electricity-to-heat efficiency of EB;

[0031] (4) GB operation constraints:

[0032]

[0033] in H GB and They represent the lower and upper limits of the thermal power output of the gas boiler (GB) respectively; represents the output thermal power of the gas boiler at the tth moment in the sth scenario;

[0034] (5) ESS operation constraints:

[0035]

[0036]

[0037]

[0038]

[0039] Where Q m,s,t represents the amount of electricity stored in the ESS in the MEMG at the tth moment in the sth scenario; and They represent the charging and discharging efficiency of ESS in MEMG, respectively; P m,ESS and They represent the lower and upper limits of the charging and discharging power of the ESS in the MEMG, respectively; is a binary variable used to avoid simultaneous charging and discharging of ESS in MEMG at time t in the sth scenario; Q m and They represent the lower and upper limits of the amount of electricity that can be stored in the ESS in the MEMG respectively; and They represent the discharge and charging power of the electric energy storage system in the multi-energy microgrid at the tth moment in the sth scenario; Δt represents the duration of a moment;

[0040] (6)TSS operation constraints:

[0041]

[0042]

[0043]

[0044]

[0045] Among them, H m,s,t represents the heat stored in TSS in MEMG at the tth time in the sth scenario; and are the heat charging and heat releasing efficiencies of TSS in MEMG, respectively; h m,TSS and They represent the lower and upper limits of TSS charging and releasing powers in MEMG, respectively; is a binary variable used to avoid simultaneous charging and discharging of heat by TSS in MEMG at time t in the sth scenario; H m and They represent the lower and upper limits of the amount of heat that can be stored in the TSS in the MEMG, respectively; and They represent the heat release and heat charging power of the thermal energy storage system in the multi-energy microgrid at the tth moment in the sth scenario respectively;

[0046] (7) Power balancing opportunity constraints:

[0047]

[0048]

[0049] in and They represent the power of photovoltaic (PV) generation, wind turbine (WT) generation, electric load and thermal load in MEMG at the tth moment respectively; represents the transmission power between the multi-energy microgrid and the power grid at the tth moment in scenario s; and They represent the sales and purchase of electric power by the i-th user from the multi-energy microgrid operator at the tth moment in the internal day-ahead market; Ω PSRepresents the set of all users; in view of the uncertainty introduced by random RDG and fluctuating multi-energy load in the operation of MEMG, the reliability of energy supply of MEMG is guaranteed according to the power balance opportunity constraint; the power balance constraint formula (4-33) and formula (4-34) can be expressed as follows under the opportunity constraint framework:

[0050]

[0051]

[0052] in and They represent the net electricity supply and heat supply of MEMG at the tth moment in the sth scenario and can be calculated according to the following formulas (4-37) and (4-38) respectively; represents the net power load of MEMG at the tth moment, which can be calculated according to formula (4-39); η m and β m are the confidence levels of the electric and thermal power balance opportunity constraints in MEMG, respectively;

[0053]

[0054]

[0055]

[0056] Convert the chance constraints (4-35) and (4-36) into deterministic inequality constraints as shown in the following equations (4-40) and (4-41);

[0057]

[0058]

[0059] in and Denote random variables and The inverse function of the cumulative distribution function (CDF) is in η m and β m The function value at .

[0060] Preferably, the user's goal is to determine the optimal electricity purchasing strategy in the internal market according to the electricity price cleared by the MEMG operator to minimize their respective operating costs. The user's operating costs include the decay cost of the ESS and the costs and benefits of participating in the internal market. The user model objective function can be formulated as follows:

[0061]

[0062] where F i represents the total operating cost of the i-th user; is the decay cost of ESS in the i-th user; and They represent the cost and benefit of the i-th user in the internal day-ahead market respectively; the calculation method and corresponding constraints of each item in formula (4-47) are as follows:

[0063] (1) ESS: ESS is also configured in some users. Its dynamic model and calculation method of decay cost are similar to those of ESS in MEMG, as shown below:

[0064]

[0065]

[0066]

[0067]

[0068]

[0069] in is the decay cost coefficient of the ESS configured in the i-th user; and They represent the charging and discharging power of ESS in the i-th user at the t-th moment respectively; Q i,t is the amount of electricity stored in the ESS of the i-th user at the t-th moment; and denote the charging and discharging efficiencies of ESS in the i-th user, respectively; P i,ESS and They represent the lower and upper limits of the ESS charging and discharging power in the i-th user respectively; is a binary variable used to avoid simultaneous charging and discharging of the ESS in the i-th user at time t; Q i and They represent the lower and upper limits of the amount of electricity that can be stored in the ESS of the i-th user; Ω TS ={1,2,...,96};

[0070] (2) Transaction costs and benefits of users in the internal day-ahead market: In day-ahead scheduling, users need to optimally determine the day-ahead transaction agreement based on the internal day-ahead market electricity price cleared by MEMG. The transaction costs and benefits of users in the internal day-ahead market can be expressed as the following equations (4-53) and (4-54), respectively, where and In the user model, it is treated as a parameter. and is the decision variable;

[0071]

[0072]

[0073] (3) Power balance opportunity constraint: Each user must also ensure the balance between supply and demand of electric power during operation, as shown in the following equation (4-55);

[0074]

[0075] in and They represent the power of PV generation, WT generation and electric load in the i-th user at the t-th moment respectively.

[0076] Preferably, the supply-demand balance constraint is established as a chance constraint and is equivalently converted into a deterministic constraint as shown below using a quantile prediction method based on GBRT (gradient boosted regression tree algorithm):

[0077]

[0078]

[0079]

[0080] in represents the net electricity supply of the i-th user at the t-th moment; is the net load of the ith user at the tth moment; η i is the confidence level of the power balancing opportunity constraint in the i-th user; Represents a random variable The inverse function of the CDF is in η i The function value at .

[0081] Preferably, the goal of MEMG real-time energy control is to minimize the operating cost on the basis of ensuring that all operating constraints are met. st The objective function of the real-time energy regulation model for a rolling cycle is shown in Equation (4-72), which includes the upstream real-time market participation cost, the internal real-time market participation cost and income, the natural gas procurement cost, and the decline cost of ESS and TSS;

[0082]

[0083]

[0084]

[0085]

[0086]

[0087]

[0088]

[0089]

[0090]

[0091]

[0092] Among them l st Indicates the start hour of the current scroll cycle; For MEMG st The objective function of the real-time energy control model for one hour; and Respectively represent MEMG in the first st Real-time electricity purchase costs, penalty costs and natural gas purchase costs in real-time energy regulation within 24 hours; and are ESS and TSS in MEMG in the first st The decay cost in real-time energy regulation over a period of hours; Indicates that the MEMG operator is in the first st The electricity purchase cost and electricity sales revenue in the internal real-time market in the real-time energy regulation of one hour is equal to the sum of the inverse of the electricity purchase cost and revenue of all users in the internal real-time market; it should be noted that this item is a parameter in the MEMG real-time energy regulation model, and it is listed in the objective function to clearly illustrate the cost item included in the MEMG real-time energy regulation, which has no effect on the optimization result; Indicates that the i-th user is in the l-th st The electricity purchase cost and electricity sales revenue in the internal real-time market during the real-time energy regulation within 24 hours; ΔE is the real-time power consumption of MEMG in the upstream real-time market at the first hour; l The deviation between the real-time power consumption of MEMG and the bid power of the day before in the first hour; is the day-ahead bid electricity of MEMG in the lth hour (a known parameter in this model); L MPC is the rolling MPC (model predictive control) window size; The fine that MEMG needs to pay to the upstream real-time market at the first hour; To represent ΔE l Auxiliary variable of absolute value; P tCHP and They represent the output electric power and thermal power of CHP and GB in MEMG at the tth moment, respectively; and They represent the discharge and charge power of ESS in MEMG at the tth moment respectively; and They represent the heat release and heat charging power of TSS in MEMG at the tth moment respectively; P t grid represents the transmission power between the multi-energy microgrid and the power grid at the tth moment; represents the real-time electricity price of the upstream real-time market at the lth hour; p is the penalty price; r represents the deviation ratio allowed from the day-ahead bid electricity; v gas is the natural gas price; η CHP and η GB represents the conversion efficiency of natural gas into electricity and heat in the cogeneration unit and gas boiler, respectively; ρ m,ESS represents the decay cost coefficient of the electric energy storage system in the multi-energy microgrid; ρ m,TSS It represents the decay cost coefficient of thermal energy storage system in multi-energy microgrid.

[0093] Preferably, the goal of user real-time energy regulation is to minimize the respective operating costs on the basis of ensuring that all operating constraints are met, including the internal real-time market participation costs and benefits and the decay costs of ESS. st The objective function of the real-time energy control model with a rolling cycle can be established as follows:

[0094]

[0095]

[0096]

[0097]

[0098]

[0099] in Indicates that the i-th user is in the l-th st The objective function of the real-time energy control model for one hour; is the ESS of the i-th user in the l-th st The decay cost in real-time energy regulation over a period of hours; represents the power deviation of the i-th user in the l-th hour; represents the real-time power consumption of the i-th user in the l-th hour; and They represent the day-ahead power purchase and sales transaction agreement of the i-th user in the l-th hour (regarded as parameters in this model); represents the actual electric power obtained by the i-th user from the multi-energy microgrid at the t-th time; and They respectively represent the electricity selling price and electricity purchasing price of the multi-energy microgrid operator to the ith user in the lth hour.

[0100] The present invention also provides a computer device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the steps of the method when executing the computer program.

[0101] The present invention also provides a computer-readable storage medium having a computer program stored thereon, wherein the computer program implements the steps of the method when executed by a processor.

[0102] The beneficial effects of the present invention are as follows: the present invention proposes an energy-sharing MEMG energy management strategy based on internal two-stage electricity market transactions. The strategy models the internal day-ahead market as an SG model to support electricity transactions between MEMG and users while balancing multilateral interests, and at the same time uses a distributed iterative algorithm that incorporates the dichotomy method to achieve game equilibrium solution without infringing privacy. In addition, the strategy uses opportunity constraints and stochastic optimization methods with risk criteria in the day-ahead stage to respectively address the challenges caused by RDG and multi-energy loads and upstream wholesale market uncertainties. In the real-time stage, a real-time energy control model based on rolling MPC is established, and the actual operation plans of MEMG and all users are determined to support internal real-time market transactions, thereby ensuring real-time supply and demand balance. BRIEF DESCRIPTION OF THE DRAWINGS

[0103] Figure 1 is a flow chart according to an embodiment of the present invention;

[0104] Figure 2 is a strategy interaction diagram between a MEMG operator and a user according to an embodiment of the present invention;

[0105] Figure 3 It is an execution flow chart of MEMG day-ahead scheduling based on SG-based transaction energy sharing according to an embodiment of the present invention. DETAILED DESCRIPTION

[0106] In order to facilitate the understanding of the present invention, the present invention is described in more detail below in conjunction with the accompanying drawings and specific embodiments. Preferred embodiments of the present invention are provided in the accompanying drawings. However, the present invention can be implemented in many different forms and is not limited to the embodiments described in this specification. On the contrary, the purpose of providing these embodiments is to make the understanding of the disclosure of the present invention more thorough and comprehensive.

[0107] It should be noted that, unless otherwise defined, all technical and scientific terms used in this specification have the same meaning as those commonly understood by those skilled in the art of the present invention. The terms used in the specification of the present invention are only for the purpose of describing specific embodiments and are not intended to limit the present invention. The term "and / or" used in this specification includes any and all combinations of one or more related listed items.

[0108] Figure 1 An embodiment of the multi-energy microgrid energy control method of the present invention is shown, comprising:

[0109] Step S1: Construct data-driven opportunity constraints based on the quantile forecasting method, incorporate users in the internal day-ahead market transactions, and include the uncertainties of renewable distributed generation and multi-energy loads in the multi-energy microgrid;

[0110] Step S2: Based on the internal day-ahead market of Stackelberg game, the strategic game between operators and users in the multi-energy microgrid is captured, and the distributed iterative algorithm of fusion dichotomy is used to eliminate the oscillation in the iteration process and promote the convergence of the game;

[0111] Step S3: In the real-time control stage, the rolling model predictive control method is used to realize the real-time energy control of multi-energy microgrids and multiple prosumers to support internal real-time market transactions.

[0112] In a competitive power market environment, the present invention proposes an energy sharing MEMG energy management strategy based on internal two-stage power market transactions. In the day-ahead stage, the strategy adopts stochastic optimization and chance constraints integrated with risk criteria to consider the uncertainties from the upstream wholesale market, RDG and multi-energy loads respectively. In the real-time stage, the rolling model predictive control (MPC) method is adopted to realize the real-time energy regulation of MEMG and multiple prosumers to support internal real-time market transactions.

[0113] In this strategy, an internal electricity market with a consistent two-settlement structure with the upstream wholesale market is established to balance multilateral interests and promote internal energy sharing. The internal day-ahead market is modeled as a Stackelberg game (SG) model to effectively capture the strategic interaction between prosumers and MEMG operators, and a distributed iterative algorithm that integrates dichotomy is used to achieve SG equilibrium solution without infringing privacy. The internal real-time market directly adopts the upper and lower limits of the day-ahead pricing range to urge prosumers to formulate more precise transaction agreements in the internal day-ahead market, while improving the transaction efficiency of the internal real-time market.

[0114] Figure 2The operation mode of the MEMG for trading energy sharing is demonstrated. MEMG runs in the wholesale power market and is managed by the MEMG operator. In addition to managing its own resources, MEMG also provides power services to surrounding users. Since the user capacity is small and cannot meet the entry threshold of the upstream wholesale power market, MEMG also plays the role of aggregating users to participate in the upstream power market to obtain stable power support from the main power grid. These users and MEMG belong to different interest entities and are also equipped with flexible resources such as RDG and energy storage. Therefore, they are both power consumers and have power production capabilities, so they are called prosumers and are governed and controlled by their respective prosumer energy management systems (PEMS). MEMG and users can achieve trading energy sharing through power trading in a reasonable internal power market, thereby improving the energy utilization efficiency of the entire MEMG and all users. Because MEMG operators and users belong to different interest entities and have their own interests, the construction of the internal power market must not only achieve a multilateral balance of interests, but also their data privacy must be reasonably protected during the power trading process. In summary, the roles played by MEMG operators and PEMS in the operation of the MEMG for trading energy sharing can be summarized as follows:

[0115] (1) MEMG operators: a) manage the operation of all equipment within their jurisdiction; b) participate in the upstream wholesale electricity market on behalf of users; c) interact with users as an electricity retailer and clear internal market electricity prices to coordinate energy sharing between MEMG and users.

[0116] (2) PEMS: a) Formulate the optimal operation plan for users based on the internal market electricity price released by the MEMG operator; b) Submit the user's electricity trading decision in the internal market to the MEMG operator.

[0117] Internal power market pricing scheme: The reasonable setting of internal market electricity prices can promote users to participate in collaborative energy sharing. In order to coordinate with the two settlement mechanisms of the upstream competitive power market, the present invention establishes an internal power market with two settlement structures. The internal power market constructed by the present invention consists of a day-ahead market and a real-time market. In the internal day-ahead market, settlement is performed based on the electricity price released by the MEMG operator and the transaction agreement submitted by the user, while in the real-time market, settlement is performed based on the imbalanced electricity between the actual power consumption of the user and the day-ahead transaction agreement to promote energy supply and demand balance.

[0118] In the internal day-ahead power market, MEMG operators clear customized electricity prices according to different power trading agreements of each user to increase their own electricity sales revenue, while users adjust their respective trading agreements in response to the electricity prices to reduce the cost of purchasing electricity, which in turn affects the electricity price clearing plan of MEMG operators. MEMG operators and users pursue their competing interests through continuous strategy adjustments. This transaction energy sharing process can be modeled as an SG model. The strategic interaction between MEMG operators and users in the game process is as follows: Figure 2 As detailed in , the SG model has the following elements.

[0119] (1) Participants: MEMG operators (leaders) and users (multiple followers).

[0120] (2) Strategy set: The leader’s strategy set is the internal day-ahead market price clearing scheme based on the followers’ trading protocol. Including the electricity price sold by the MEMG operator to the i-th user in the l-th hour and electricity purchase price The strategy set of multiple followers is the power trading protocol they formulate based on the leader's power price clearing plan. Includes the electricity sold by the i-th user to the MEMG operator in the l-th hour and purchased electricity It is worth noting that the electricity price released by the MEMG operator to users is time-varying and the price released to different users in the same hour is also different depending on the different transaction agreements of each user.

[0121] (3) Utility function: The utility functions of MEMG operators and users are the objective functions of their respective day-ahead scheduling models.

[0122] In order to protect the privacy of MEMG operators and users' data during the strategic game, the present invention adopts a distributed iterative algorithm combined with dichotomy to solve the game equilibrium solution.

[0123] In the internal real-time market, the price of electricity sold by the MEMG operator to the i-th user at the l-th hour is and electricity purchase price The upper and lower limits of the pricing range set by the MEMG operator in the internal day-ahead market are used respectively. Directly using the upper and lower limits of the pricing range to execute transactions in the internal real-time market can, on the one hand, urge users to formulate more accurate transaction agreements in the internal day-ahead market to avoid unexpected operating costs for MEMG operators and users; on the other hand, it can effectively avoid the increase in computational complexity caused by iterative calculations, thereby meeting the requirements for the speed of real-time transactions and improving the transaction efficiency of the internal real-time market.

[0124] The present invention provides a MEMG day-ahead dispatching model for energy sharing based on SG, including a day-ahead bidding of a leading MEMG operator to an upstream wholesale power market and an internal day-ahead market electricity price clearing model, as well as a day-ahead transaction agreement decision model for users.

[0125] Leader model of MEMG operators: Since one of the roles of MEMG operators is to aggregate all users to participate in the upstream competitive electricity market, the operation of MEMG faces challenges caused by the uncertainty of the upstream electricity market. In order to properly handle such uncertainties, the present invention characterizes the uncertainty of real-time electricity prices through representative scenarios. In addition, the goal of MEMG operators is to minimize the total operating costs while maximizing the benefits of providing electricity services to users on the basis of satisfying all operating constraints. Therefore, the leader model objective function under a specific real-time electricity price scenario s can be formulated as the following formula (4-1).

[0126]

[0127] where F m,s represents the total operating cost of MEMG in the sth scenario; C DA represents the day-ahead bidding cost of MEMG in the upstream wholesale electricity market; and They represent the electricity purchase cost and penalty cost of MEMG in the upstream real-time market in the sth scenario respectively; represents the natural gas procurement cost of MEMG in the sth scenario; and They represent the decay costs of ESS and thermal storage system (TSS) in MEMG under the s-th scenario respectively; and They represent the electricity purchase cost and electricity sales revenue of MEMG in the internal day-ahead market respectively. The calculation methods of each item in formula (4-1) are as follows.

[0128] (1) Upstream competitive electricity market participation costs:

[0129]

[0130]

[0131]

[0132]

[0133]

[0134]

[0135]

[0136]

[0137] in represents the day-ahead electricity price in the upstream real-time market at the lth hour; It represents the day-ahead bid electricity of MEMG in the first hour; represents the real-time electricity price of the upstream real-time market in the lth hour under the sth scenario; ΔE s,l Indicates the real-time power consumption deviation of MEMG in the lth hour under the sth scenario; represents the actual power consumption of MEMG in the upstream real-time market in the lth hour under the sth scenario; represents the transmission power; Δt is the duration of a moment; is the penalty cost of MEMG in the lth hour under the sth scenario; To represent ΔE s,l Auxiliary variable of absolute value; λ p is the penalty price; r represents the deviation ratio allowed from the day-ahead bid electricity; Ω H ={1,2,...,24}.

[0138] (2) Natural gas procurement cost:

[0139]

[0140] where v gas is the price of natural gas; and Respectively represent the output electric power and thermal power of the combined heat and power unit (CHP) and the gas boiler (GB) at the tth moment in the sth scenario; η CHP and η GB Represents the conversion efficiency of natural gas to electricity and heat energy of CHP and GB respectively; Ω TS ={1,2,...,96}.

[0141] (3) ESS degradation cost:

[0142]

[0143] where ρ m,ESS represents the decay cost coefficient of ESS in MEMG; and They represent the discharge and charging power of ESS in MEMG at the tth moment in the sth scenario respectively.

[0144] (4) TSS decline cost:

[0145]

[0146] where ρ m,TSS represents the decay cost coefficient of TSS in MEMG; and They represent the heat release and heat charging power of TSS in MEMG at the tth moment in the sth scenario respectively.

[0147] (5) Transaction costs and benefits of MEMG in the internal day-ahead market: Given a user (multiple followers), the transaction protocol in the internal day-ahead market is optimized and ( and Respectively represent the sales and purchase of electricity by the i-th user from the MEMG operator in the l-th hour) and the transaction agreement is regarded as a parameter in the MEMG operator model, then the cost and benefit of the MEMG operator in the internal day-ahead market can be expressed as the following formula (4-14). Similarly, hourly electricity settlement and 15-minute energy regulation are also considered in the internal market, so the relationship between the transaction electricity and transmission power between the user and MEMG is shown in the following formula (4-16).

[0148]

[0149]

[0150]

[0151]

[0152] Where Ω PS Represents the set of all users; and They represent the sales and purchases of electric power by the i-th user from the MEMG operator at the t-th moment in the internal day-ahead market.

[0153] The objective function of the MEMG operator model must satisfy the pricing constraints shown in (4-19) and the operating constraints shown in (4-41).

[0154] (1) MEMG operator pricing constraints: The customized electricity price that the MEMG operator clears for each user and In this model, it is a decision variable, and the constraints that must be satisfied are shown in the following equations (4-17), (4-18) and (4-19). Equation (4-17) constrains the electricity sales price set by MEMG every hour to be within a certain range. Equation (4-18) limits the average electricity sales price over the entire time range to a constant to avoid MEMG always setting an upper limit on the electricity sales price in order to pursue maximum profit, thereby protecting the user's willingness to participate in energy sharing. Equation (4-19) ensures that the priority of users' internal electricity self-consumption is higher than selling electricity to MEMG operators.

[0155]

[0156]

[0157]

[0158] in and They represent the lower and upper limits of the electricity price that MEMG sells to users in the first hour, which can be formulated with reference to the day-ahead electricity price in the upstream competitive power market; L represents the total number of hours in the entire time range; μ av is the average price of electricity sold by MEMG to users; ε represents the electricity purchase price coefficient of MEMG to users and ε<1.

[0159] (2) CHP operation constraints:

[0160]

[0161]

[0162] in P CHP and They represent the lower and upper limits of the CHP output electric power respectively; represents the output thermal power of CHP at the tth moment in the sth scenario; b is the thermal-electric ratio of CHP.

[0163] (3)EB operation constraints:

[0164]

[0165]

[0166] in H EB and They represent the lower and upper limits of the thermal power output of the electric boiler (EB) respectively; and They represent the output thermal power and electrical power consumed by EB at the tth moment in the sth scenario respectively; ηEB is the electrical-to-heat efficiency of EB.

[0167] (4) GB operation constraints:

[0168]

[0169] in H GB and They respectively represent the lower and upper limits of the thermal power output of the gas boiler (GB).

[0170] (5) ESS operation constraints:

[0171]

[0172]

[0173]

[0174]

[0175] Where Q m,s,t represents the amount of electricity stored in the ESS in the MEMG at the tth moment in the sth scenario; and They represent the charging and discharging efficiency of ESS in MEMG, respectively; P m,ESS and They represent the lower and upper limits of the charging and discharging power of the ESS in the MEMG, respectively; is a binary variable used to avoid simultaneous charging and discharging of ESS in MEMG at time t in the sth scenario; Q m and They represent the lower and upper limits of the amount of electricity that can be stored in the ESS in the MEMG.

[0176] (6)TSS operation constraints:

[0177]

[0178]

[0179]

[0180]

[0181] Among them, H m,s,t represents the heat stored in TSS in MEMG at the tth time in the sth scenario; and are the heat charging and heat releasing efficiencies of TSS in MEMG, respectively; hm,TSS and They represent the lower and upper limits of TSS charging and releasing powers in MEMG, respectively; is a binary variable used to avoid simultaneous charging and discharging of heat by TSS in MEMG at time t in the sth scenario; H m and They represent the lower and upper limits of the amount of heat that can be stored in TSS in MEMG.

[0182] (7) Power balancing opportunity constraints:

[0183]

[0184]

[0185] in and Respectively represent the power of photovoltaic (PV) power generation, wind turbine (WT) power generation, electric load and thermal load in MEMG at the tth moment. In view of the uncertainty introduced by random RDG and fluctuating multi-energy load in MEMG operation, the present invention guarantees the energy supply reliability of MEMG according to the power balance opportunity constraint. The power balance constraint formula (4-33) and formula (4-34) can be respectively expressed as:

[0186]

[0187]

[0188] in and They represent the net electricity supply and heat supply of MEMG at the tth moment in the sth scenario and can be calculated according to the following equations (4-37) and (4-38) respectively; represents the net power load of MEMG at the tth moment, which can be calculated according to formula (4-39); η m and β m are the confidence levels of the electric and thermal power balance opportunity constraints in MEMG, respectively.

[0189]

[0190]

[0191]

[0192] In order to efficiently solve optimization problems with chance constraints, the chance constraints (4-35) and (4-36) are equivalently converted into deterministic inequality constraints shown in the following equations (4-40) and (4-41).

[0193]

[0194]

[0195] in and Denote random variables and The inverse function of the cumulative distribution function (CDF) is in η m and β m The function value at .

[0196] In order to take into account all potential real-time electricity price scenarios in the upstream wholesale market in the MEMG operator model, the MEMG operator model can be formulated in a form under the stochastic optimization framework as shown in Equation (4-42). For the sake of brevity, only the compact form of the model is shown here.

[0197]

[0198] stx∈χ

[0199] y s ∈γ(x,d s ) (4-42)

[0200] Where Ω s Represents the set of all real-time electricity price scenarios; π s represents the occurrence probability of the sth real-time electricity price scenario.

[0201] It can be observed that the decision variables in equation (4-42) can be divided into two groups, namely x and y s The first group x is called the “here and now” decision, which is independent of the real-time electricity price scenario and includes the day-ahead bidding plan submitted by MEMG to the upstream real-time market. and the clearing price in the internal day-ahead market and The second group s It is called the “wait-and-see” decision, which includes all the remaining decision variables (such as the transmission power between MEMG and the grid). The decision of this group of variables depends on the specific real-time electricity price scenario and will be affected by the “here and now” decision. In addition, χ and γ(x,d s ) represent x and y respectively s The feasible domain of γ(x,d s ) also specifies y s is between x and the specific real-time electricity price scenario d s Optimization decision-making under certain conditions.

[0202] By solving the optimization model (4-42), the optimal x can be obtained.* , which minimizes the expected cost of MEMG operators in all typical real-time electricity price scenarios.

[0203] However, x * There may be a risk of being too optimistic, which may lead to unexpected cost increases in some adverse scenarios. MEMG operators are risk-averse to the uncertainty of the wholesale power market, so the present invention also introduces the conditional value at risk (CVaR) risk standard in the MEMG operator model to achieve risk avoidance. Therefore, the objective function in the model formula (4-42) can be modified to the following formula (4-43) to achieve the purpose of risk avoidance using CVaR.

[0204]

[0205] where F m Represents the final objective function of the MEMG operator; γ≥0 is a weight parameter set by the MEMG operator according to its risk aversion preference. When γ=0, it indicates risk neutrality, and when γ>0, it indicates risk aversion. The larger the γ, the more the MEMG operator pays attention to the risk. CVaR α represents the CVaR value of the MEMG operator at the confidence level α∈(0,1). According to the CVaR theory, it can be calculated according to formula (4-44). In order to facilitate the solution of the optimization problem, formula (4-44) can be added by adding auxiliary variables V s Linearized into equations (4-45) and (4-46).

[0206]

[0207] F m,s The s in the lower right corner refers to the situation under scenario s, where z is called the VaR value of MEMG; [] + Represents a mapping.

[0208]

[0209] V s ≥0,V s ≥F m,s -z (4-46)

[0210] User follower model: The user's goal is to determine its optimal electricity purchasing strategy in the internal market based on the electricity price cleared by the MEMG operator, so as to minimize its respective operating costs. The user's operating costs include the degradation cost of the ESS and the costs and benefits of participating in the internal market. Therefore, the user model objective function can be formulated as follows (4-47).

[0211]

[0212] where Fi represents the total operating cost of the i-th user; is the decay cost of ESS in the i-th user; and They represent the cost and benefit of the ith user in the internal day-ahead market respectively. The calculation method and corresponding constraints of each item in formula (4-47) are described as follows.

[0213] (1) ESS: ESS is also configured in some users. Its dynamic model and calculation method of decay cost are similar to those of ESS in MEMG, as shown in Equations (4-48) to (4-52).

[0214]

[0215]

[0216]

[0217]

[0218]

[0219] in is the decay cost coefficient of the ESS configured in the i-th user; and They represent the charging and discharging power of ESS in the i-th user at the t-th moment respectively; Q i,t is the amount of electricity stored in the ESS of the i-th user at the t-th moment; and denote the charging and discharging efficiencies of ESS in the i-th user, respectively; P i,ESS and They represent the lower and upper limits of the ESS charging and discharging power in the i-th user respectively; is a binary variable used to avoid simultaneous charging and discharging of the ESS in the i-th user at time t; Q i and They represent the lower and upper limits of the amount of electricity that can be stored in the ESS of the i-th user.

[0220] (2) Transaction costs and benefits of users in the internal day-ahead market: In day-ahead scheduling, users need to optimally determine the day-ahead transaction agreement based on the internal day-ahead market electricity price cleared by MEMG. The transaction costs and benefits of users in the internal day-ahead market can be expressed as the following equations (4-53) and (4-54), respectively, where and In the user model, it is treated as a parameter. and is the decision variable.

[0221]

[0222]

[0223] (3) Power balance opportunity constraint: Each user must also ensure the balance between supply and demand of electric power during operation, as shown in the following formula (4-55).

[0224]

[0225] in and They represent the power of PV generation, WT generation and electric load in the i-th user at the t-th moment respectively.

[0226] In order to deal with the uncertainty introduced by random RDG and fluctuating power load in user operation, the supply and demand balance constraint (4-55) can also be established as a chance constraint and converted into the deterministic constraints shown in the following equations (4-56), (4-57) and (4-58) using the quantile prediction method based on the gradient boosting regression tree algorithm (GBRT).

[0227]

[0228]

[0229]

[0230] in represents the net electricity supply of the i-th user at the t-th moment; is the net load of the ith user at the tth moment; η i is the confidence level of the power balancing opportunity constraint in the i-th user; Represents a random variable The inverse function of the CDF is in η i The function value at .

[0231] Figure 3The execution process of the MEMG day-ahead scheduling of the SG-based trading energy sharing proposed in the present invention is demonstrated. Firstly, based on the collected basic data, a day-ahead scheduling model of the leader (MEMG operator) and multiple followers (users) considering multi-dimensional operation uncertainty is established, in which the uncertainty of the RDG and multi-energy load configured in the MEMG and the user is modeled through chance constraints, and a net electric load and thermal load quantile prediction method based on GBRT is developed to convert the chance constraints into solvable deterministic constraints. In addition, the MEMG operator model is established as a risk-averse form through stochastic optimization integrating the CVaR criterion to take into account the uncertainty introduced by the upstream wholesale power market. In the day-ahead scheduling, a distributed iterative algorithm is used to achieve the game equilibrium solution without infringing the privacy of the MEMG operator and the user, and a dichotomy is added in the iterative process to avoid the oscillation of the internal day-ahead market electricity price to ensure the convergence of the game. The core idea of ​​the dichotomy is to update the upper and lower limits of the pricing range in each iteration, so as to ensure that the pricing range contains the equilibrium state while gradually narrowing the pricing range to suppress the game oscillation. Table 1 shows the execution process of the distributed iterative algorithm that integrates the dichotomy method. Based on this algorithm, MEMG operators and users are only responsible for model optimization within their jurisdiction and only need to interact with transaction-related information, thereby effectively achieving privacy protection.

[0232] Table 1 SG-based transaction energy sharing MEMG day-ahead scheduling execution process

[0233]

[0234]

[0235] Real-time energy regulation model of MEMG for trading energy sharing: The present invention constructs a real-time energy regulation model of MEMG for trading energy sharing based on the rolling MPC method, including energy regulation models of MEMG and users in the upstream real-time market and the internal real-time market.

[0236] MEMG real-time energy control model: The goal of MEMG real-time energy control is to minimize the operating cost on the basis of ensuring that all operating constraints are met. st The objective function of the real-time energy regulation model for a rolling cycle is shown in formula (4-72), which includes the upstream real-time market participation cost, internal real-time market participation cost and benefit, natural gas procurement cost, and the decline cost of ESS and TSS.

[0237]

[0238]

[0239]

[0240]

[0241]

[0242]

[0243]

[0244]

[0245]

[0246]

[0247] Among them l st Indicates the start hour of the current scroll cycle; For MEMG st The objective function of the real-time energy control model for one hour; and Respectively represent MEMG in the first st Real-time electricity purchase costs, penalty costs and natural gas purchase costs in real-time energy regulation within 24 hours; and are ESS and TSS in MEMG in the first st The decay cost in real-time energy regulation over a period of hours; Indicates that the MEMG operator is in the first st The electricity purchase cost and electricity sales revenue in the internal real-time market during the real-time energy regulation of one hour is equal to the sum of the inverse of the electricity purchase cost and revenue of all users in the internal real-time market. It should be noted that this item is a parameter in the MEMG real-time energy regulation model. It is listed in the objective function to clearly illustrate the cost item included in the MEMG real-time energy regulation, which has no effect on the optimization result; Indicates that the i-th user is in the l-th st The electricity purchase cost and electricity sales revenue in the internal real-time market during the real-time energy regulation within 24 hours; is the real-time power consumption of MEMG in the upstream real-time market at the first hour, ΔE l The deviation between the real-time power consumption of MEMG and the bid power of the day before in the first hour; is the day-ahead bid electricity of MEMG in the lth hour (a known parameter in this model); L MPC is the scrolling MPC window size; The fine that MEMG needs to pay to the upstream real-time market at the first hour; To represent ΔE lAuxiliary variable of absolute value; P t CHP and They represent the output electric power and thermal power of CHP and GB in MEMG at the tth moment, respectively; and They represent the discharge and charge power of ESS in MEMG at the tth moment respectively; and They represent the heat release and heat charging power of TSS in MEMG at the tth moment respectively.

[0248] The MEMG real-time energy control model based on rolling MPC is constructed every hour based on the ultra-short-term prediction information of uncertain variables, so it is a deterministic optimization model every hour. It can also be seen from the objective function that the decision variable does not contain the scenario subscript "s". The power balance constraints that need to be met by MEMG real-time energy control are shown in the following formula (4-73).

[0249]

[0250] Where P t EB represents the power consumption of EB in MEMG at the tth moment; It represents the actual electric power obtained by the i-th user from the MEMG at the t-th time.

[0251] Other operating constraints that need to be satisfied by MEMG’s real-time energy control can be obtained by removing the scenario subscript “s” from all decision variables, which will not be elaborated here. st The real-time energy control model for each hour is an optimization problem that removes the constraints of the scenario subscript "s" from the objective function. By using the rolling solution mechanism of the rolling MPC to repeatedly construct and solve the corresponding optimization problem according to the updated information every hour, the actual operation plan of the MEMG within the entire optimization range can be gradually obtained.

[0252] User real-time energy regulation model: The goal of user real-time energy regulation is also to minimize the respective operating costs on the basis of ensuring that all operating constraints are met, including the internal real-time market participation costs and benefits and the decay cost of ESS. st The objective function of the real-time energy control model with a rolling cycle can be established as the following formula (4-74).

[0253]

[0254]

[0255]

[0256]

[0257]

[0258] in Indicates that the i-th user is in the l-th st The objective function of the real-time energy control model for one hour; is the ESS of the i-th user in the l-th st The decay cost in real-time energy regulation over a period of hours; represents the power deviation of the i-th user in the l-th hour; represents the real-time power consumption of the i-th user in the l-th hour; and They represent the day-ahead power purchase and sales transaction agreement of the i-th user in the l-th hour (regarded as parameters in this model); and They represent the discharging and charging powers of ESS in the i-th user at the t-th moment, respectively.

[0259] The positive or negative value of can indicate that the i-th user has a power shortage or power surplus in the l-th hour compared with the day-ahead transaction agreement, indicating that different prices are used to purchase or sell power in the internal real-time market. At this time, the user purchased additional electricity from MEMG, so In the opposite case

[0260] The constraints that the user's real-time energy control needs to meet are the ESS operation constraints shown in Equations (4-48) to (4-52) and the power balance constraints shown in (4-79).

[0261]

[0262] In summary, users st The real-time energy control model for each hour is based on the above (4-79) as the objective function and the optimization problem with the above constraints. The rolling solution mechanism of the rolling MPC is also used to repeatedly construct and solve the corresponding optimization problem according to the updated information every hour to gradually obtain the actual operation plan for all users in the entire optimization range.

[0263] In order to achieve the optimal energy management and internal energy sharing of MEMG that integrates multiple production and consumption users under a multi-dimensional uncertainty environment, the present invention proposes an energy sharing MEMG energy management strategy based on internal two-stage electricity market transactions. This strategy models the internal day-ahead market as an SG model to support electricity transactions between MEMG and users while balancing multilateral interests. At the same time, a distributed iterative algorithm that integrates the dichotomy method is used to achieve game equilibrium solution without infringing privacy. In addition, the strategy uses opportunity constraints and stochastic optimization methods with risk criteria in the day-ahead stage to respectively deal with the challenges caused by RDG and multi-energy loads and upstream wholesale market uncertainties. In the real-time stage, a real-time energy control model based on rolling MPC is established, and the actual operation plans of MEMG and all users are determined to support internal real-time market transactions to ensure real-time supply and demand balance.

[0264] The above are only embodiments of the present invention, and are not intended to limit the patent scope of the present invention. Any equivalent structural transformations made using the contents of the present invention's specification and drawings, or directly or indirectly applied in other related technical fields, are also included in the patent protection scope of the present invention.

Claims

1. A multi-energy microgrid energy control method, It is characterized in that include: Step S1: Construct data-driven opportunity constraints based on the quantile forecasting method, incorporate users in the internal day-ahead market transactions, and include the uncertainties of renewable distributed generation and multi-energy loads in the multi-energy microgrid; Step S2: Based on the internal day-ahead market of Stackelberg game, the strategic game between operators and users in the multi-energy microgrid is captured, and the distributed iterative algorithm of fusion dichotomy is used to eliminate the oscillation in the iteration process and promote the convergence of the game; Step S3: In the real-time control stage, the rolling model predictive control method is used to realize the real-time energy control of multi-energy microgrids and multiple prosumers to support internal real-time market transactions.

2. The multi-energy microgrid energy control method according to claim 1, It is characterized in that The strategic interaction between the multi-energy microgrid operator and the user during the game process. The Stackelberg game model has the following elements: (1) Participants: multi-energy microgrid operators and users, where the multi-energy microgrid operator is the leader and the users are the followers; (2) Strategy set: The leader’s strategy set is the internal day-ahead market price clearing scheme based on the followers’ trading protocol. Including the electricity price sold by the multi-energy microgrid operator to the i-th user in the l-th hour and electricity purchase price The strategy set of multiple followers is the power trading protocol they formulate based on the power price clearing plan of the leader. Includes the electricity sold by the i-th user to the multi-energy microgrid operator in the lth hour and purchased electricity (3) Utility function: The utility functions of the multi-energy microgrid operator and the user are the objective functions of their respective day-ahead scheduling models.

3. The multi-energy microgrid energy control method according to claim 2, It is characterized in that The objective function of the multi-energy microgrid operator model under a specific real-time electricity price scenario s is formulated as follows: Among them, F m,s represents the total operating cost of the multi-energy microgrid in the sth scenario; C DA represents the day-ahead bidding cost of the multi-energy microgrid in the upstream wholesale electricity market; and They represent the electricity purchase cost and penalty cost of the multi-energy microgrid in the upstream real-time market under the sth scenario respectively; represents the natural gas procurement cost of the multi-energy microgrid in the sth scenario; and They represent the decay costs of the electric energy storage system and the thermal energy storage system in the multi-energy microgrid under the sth scenario respectively; and They respectively represent the electricity purchasing cost and electricity selling revenue of the multi-energy microgrid in the internal day-ahead market.

4. The multi-energy microgrid energy control method according to claim 3, It is characterized in that The objective function of the multi-energy microgrid operator model must satisfy the pricing constraints shown in equations (4-17), (4-18) and (4-19) and the operating constraints described in (2)-(6) below; (1) Pricing constraints of multi-energy microgrid operators: The customized electricity price that multi-energy microgrid operators clear to each user and In this model, it is a decision variable, and the constraints it must satisfy are shown in the following equations (4-17), (4-18) and (4-19): in and They represent the lower and upper limits of the electricity price sold by the multi-energy microgrid to users in the first hour, which is formulated with reference to the day-ahead electricity price in the upstream competitive power market; L represents the total number of hours in the entire time range; μ av is the average price of electricity sold by the multi-energy microgrid to users; ε represents the price coefficient of electricity purchased by the multi-energy microgrid to users and ε<1; Ω H ={1,2,...,24}; (2) Cogeneration unit operation constraints: in P CHP and They represent the lower and upper limits of the output electric power of the cogeneration unit respectively; represents the output thermal power of the cogeneration unit at the tth moment in the sth scenario; b is the heat-to-electricity ratio of the cogeneration unit; represents the output power of the CHP unit at the tth moment in the sth scenario; (3) Electric boiler operation constraints: in H EB and They represent the lower and upper limits of the thermal power output of the electric boiler respectively; and They represent the output thermal power and consumed electrical power of the electric boiler at the tth moment in the sth scenario respectively; η EB is the electricity-to-heat efficiency of the electric boiler; (4) Gas boiler operation constraints: in H GB and They represent the lower and upper limits of the thermal power output of the gas boiler respectively; represents the output thermal power of the gas boiler at the tth moment in the sth scenario; (5) Operation constraints of electric energy storage systems: Where Q m,s,t represents the amount of electricity stored in the electric energy storage system in the multi-energy microgrid at the tth moment in the sth scenario; and They represent the charging and discharging efficiency of the electric energy storage system in the multi-energy microgrid respectively; P m,ESS and They represent the lower and upper limits of the charging and discharging power of the electric energy storage system in the multi-energy microgrid, respectively; is a binary variable used to avoid simultaneous charging and discharging of the electric energy storage system in the multi-energy microgrid at the tth moment in the sth scenario; Q m and They represent the lower and upper limits of the amount of electricity that can be stored in the electric energy storage system in the multi-energy microgrid respectively; and They represent the discharge and charging power of the electric energy storage system in the multi-energy microgrid at the tth moment in the sth scenario; Δt represents the duration of a moment; (6) Thermal energy storage system operation constraints: Among them, H m,s,t represents the amount of heat stored by the thermal energy storage system in the multi-energy microgrid at the tth moment in the sth scenario; and They are the charging and discharging efficiencies of the thermal energy storage system in the multi-energy microgrid, respectively; h m,TSS and They represent the lower and upper limits of the charging and discharging powers of the thermal energy storage system in the multi-energy microgrid, respectively; is a binary variable used to avoid the simultaneous charging and discharging of heat by the thermal energy storage system in the multi-energy microgrid at the tth moment in the sth scenario; H m and They represent the lower and upper limits of the amount of heat that can be stored in the thermal energy storage system in the multi-energy microgrid; and They represent the heat release and heat charging power of the thermal energy storage system in the multi-energy microgrid at the tth moment in the sth scenario respectively; (7) Power balancing opportunity constraints: in and They represent the power of photovoltaic power generation, wind turbine power generation, electrical load and thermal load in the multi-energy microgrid at the tth moment respectively; represents the transmission power between the multi-energy microgrid and the power grid at the tth moment in scenario s; and They represent the sales and purchase of electric power by the i-th user from the multi-energy microgrid operator at the tth moment in the internal day-ahead market; Ω PS Represents the set of all users; in view of the uncertainty introduced by random renewable distributed generation and fluctuating multi-energy loads in the operation of multi-energy microgrids, the power balance opportunity constraint is used to ensure the energy supply reliability of the multi-energy microgrid; the power balance constraint formula (4-33) and formula (4-34) are respectively expressed as follows under the opportunity constraint framework: in and They represent the net power supply and heat supply of the multi-energy microgrid at the tth moment in the sth scenario, and are calculated according to the following formulas (4-37) and (4-38) respectively; represents the net power load of the multi-energy microgrid at the tth moment, which is calculated according to formula (4-39); η m and β m They are the confidence levels of the opportunity constraints for electric and thermal power balance in multi-energy microgrids; Convert the chance constraints (4-35) and (4-36) into deterministic inequality constraints as shown in the following equations (4-40) and (4-41); in and Denote random variables and The inverse function of the cumulative distribution function is in η m and β m The function value at .

5. The multi-energy microgrid energy control method according to claim 4, It is characterized in that The user's goal is to determine the optimal electricity purchasing strategy in the internal market based on the electricity price cleared by the multi-energy microgrid operator, so as to minimize their respective operating costs. The user's operating costs include the decay cost of the electric energy storage system and the costs and benefits of participating in the internal market. The user model objective function is formulated as follows: Among them, F i represents the total operating cost of the i-th user; is the decay cost of the electric energy storage system for the i-th user; and They represent the cost and benefit of the i-th user in the internal day-ahead market respectively; the calculation method and corresponding constraints of each item in formula (4-47) are as follows: (1) Electric energy storage system: Some users will also configure an electric energy storage system. Its dynamic model and calculation method of decay cost are similar to those of the electric energy storage system in the multi-energy microgrid, as shown below: in is the decay cost coefficient of the electric energy storage system configured in the i-th user; and They represent the charging and discharging power of the energy storage system in the i-th user at the t-th moment; Q i,t is the amount of electricity stored in the energy storage system of the i-th user at the t-th moment; and They represent the charging and discharging efficiency of the electric energy storage system in the i-th user respectively; P i,ESS and They represent the lower and upper limits of the charging and discharging power of the energy storage system in the i-th user respectively; is a binary variable used to prevent the i-th user's electric energy storage system from charging and discharging simultaneously at time t; Q i and They represent the lower and upper limits of the amount of electricity that can be stored in the energy storage system of the i-th user; Ω TS ={1,2,...,96}; (2) Transaction costs and benefits of users in the internal day-ahead market: In day-ahead scheduling, users need to optimally determine the day-ahead transaction agreement based on the internal day-ahead market electricity price cleared by the multi-energy microgrid. The transaction costs and benefits of users in the internal day-ahead market are expressed as follows: (4-53) and (4-54), respectively, where and In the user model, it is treated as a parameter. and is the decision variable; (3) Power balance opportunity constraint: Each user must also ensure the balance between supply and demand of electric power during operation, as shown in the following equation (4-55); in and They respectively represent the power of photovoltaic power generation, wind turbine power generation and electrical load of the i-th user at the t-th moment.

6. The multi-energy microgrid energy control method according to claim 5, It is characterized in that The supply and demand balance constraint is established as an opportunity constraint and converted into a deterministic constraint as shown below using the quantile prediction method based on the gradient boosting regression tree algorithm: in represents the net electricity supply of the i-th user at the t-th moment; is the net load of the ith user at the tth moment; η i is the confidence level of the power balancing opportunity constraint in the i-th user; Represents a random variable The inverse function of the cumulative distribution function is in η i The function value at .

7. The multi-energy microgrid energy control method according to claim 6, It is characterized in that The goal of real-time energy control of multi-energy microgrids is to minimize the operating cost on the basis of ensuring that all operating constraints are met. st The objective function of the real-time energy regulation model for a rolling cycle is shown in the following formula (4-72), which includes the upstream real-time market participation cost, the internal real-time market participation cost and income, the natural gas procurement cost, and the decay cost of the electric energy storage system and the thermal energy storage system; Among them l st Indicates the start hour of the current rolling cycle; For multi-energy microgrids st The objective function of the real-time energy control model for one hour; and They represent the multi-energy microgrid in the first st Real-time electricity purchase costs, penalty costs and natural gas purchase costs in real-time energy regulation within 24 hours; and They are respectively the electric energy storage system and the thermal energy storage system in the multi-energy microgrid in the first st The decay cost in real-time energy regulation over a period of hours; Indicates that the multi-energy microgrid operator st The electricity purchase cost and electricity sales revenue in the internal real-time market for one hour is equal to the sum of the inverse of the electricity purchase cost and revenue of all users in the internal real-time market; Indicates that the i-th user is in the l-th st The electricity purchase cost and electricity sales revenue in the internal real-time market during the real-time energy regulation within 24 hours; is the real-time power consumption of the multi-energy microgrid in the upstream real-time market at the first hour; ΔE l The deviation between the real-time power consumption of the multi-energy microgrid and the bid power of the day before in the first hour; is the day-ahead bid electricity of the multi-energy microgrid in the first hour, which is a known parameter in the model; L MPC Control window size for rolling model forecasts; The fine that the multi-energy microgrid needs to pay to the upstream real-time market at the first hour; To represent ΔE l Auxiliary variable of absolute value; P t CHP and They represent the output electric power and thermal power of the cogeneration unit and gas boiler in the multi-energy microgrid at the tth moment, respectively; and They represent the discharge and charging power of the electric energy storage system in the multi-energy microgrid at the tth moment respectively; and They represent the heat release and charging power of the thermal energy storage system in the multi-energy microgrid at the tth moment; P t grid represents the transmission power between the multi-energy microgrid and the power grid at the tth moment; l RT represents the real-time electricity price of the upstream real-time market at the lth hour; p For the penalty price; r represents the deviation ratio allowed from the day-ahead bid electricity quantity; v gas is the price of natural gas; η CHP and η GB represents the conversion efficiency of natural gas into electricity and heat in the cogeneration unit and gas boiler, respectively; ρ m,ESS represents the decay cost coefficient of the electric energy storage system in the multi-energy microgrid; ρ m,TSS It represents the decay cost coefficient of thermal energy storage system in multi-energy microgrid.

8. The multi-energy microgrid energy control method according to claim 7, It is characterized in that The goal of user real-time energy regulation is also to minimize their respective operating costs on the basis of ensuring that all operating constraints are met, including the internal real-time market participation costs and benefits and the decay costs of the electric energy storage system. st The objective function of the real-time energy control model for a rolling cycle is established as follows: in Indicates that the i-th user is in the l-th st The objective function of the real-time energy control model for one hour; The energy storage system of the i-th user is st The decay cost in real-time energy regulation over a period of hours; represents the power deviation of the i-th user in the l-th hour; represents the real-time power consumption of the i-th user in the l-th hour; and They represent the day-ahead power purchase and sale transaction agreement of the i-th user in the l-th hour, which are regarded as parameters in this model; represents the actual electric power obtained by the i-th user from the multi-energy microgrid at the t-th time; and They respectively represent the electricity selling price and electricity purchasing price of the multi-energy microgrid operator to the ith user in the lth hour.

9. A computer device comprising a memory, a processor and a computer program stored in the memory and executable on the processor, It is characterized in that When the processor executes the computer program, the steps of the method according to any one of claims 1 to 8 are implemented.

10. A computer-readable storage medium having a computer program stored thereon, It is characterized in that When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 8 are implemented.