Next Article in Journal
Research on an Intelligent Sealed Neutral Point Protection Device for High-Altitude Transformers
Previous Article in Journal
An Explicit Representation Method for Operational Reliability Constraints in Multi-Energy Coupled Low-Carbon Distribution Network
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Distributionally Robust Dynamic Interaction for Microgrid Clusters with Shared Electric–Hydrogen Storage

School of Economics and Management, North China Electric Power University, Beijing 102206, China
*
Author to whom correspondence should be addressed.
Energies 2026, 19(4), 903; https://doi.org/10.3390/en19040903
Submission received: 29 December 2025 / Revised: 1 February 2026 / Accepted: 5 February 2026 / Published: 9 February 2026
(This article belongs to the Section A5: Hydrogen Energy)

Abstract

Shared energy storage provides a promising solution for the operation of microgrid clusters. This paper explores a hybrid electric–hydrogen shared energy storage model within microgrid clusters, aiming for clean energy generation and economical energy supply despite renewable energy’s unpredictability and complex stakeholder interactions. First, the proposed method features a shared energy storage operator that hosts electric storage and power-to-gas, enabling multi-microgrids energy sharing. To address market dynamics, a hybrid game theory approach using Nash bargaining and Stackelberg games is employed to manage interactions among the shared energy storage operator, microgrid operators, and internal end-users, while accounting for their differing interests. Second, to address uncertainty in renewable energy output, a distributionally robust optimization model is implemented with conditional value at risk, focusing on risk in extreme scenarios. The Adaptive Alternating Direction Method of Multipliers algorithm and Karush–Kuhn–Tucker conditions are used to solve the optimal decision scheme for each entity. Finally, a case study is used to verify the model’s effectiveness. Simulation results show that hybrid electric–hydrogen energy sharing improves resource utilization, leading to significant revenue increases for microgrids and higher profitability for shared energy storage operator. The game-theory-based approach ensures equitable revenue distribution and a 9.86% increase in coalition revenue. It provides a flexible approach to balance economic efficiency and system robustness by allowing decision-makers to adjust risk preference parameters and use historical sample data for informed decision-making.

1. Introduction

1.1. Motivation

Under the “dual carbon” context, the energy sector is gradually transitioning toward a clean and low-carbon structure. Integrated energy microgrids (MGs) can combine distributed power sources, energy storage systems, and flexible loads, providing capabilities for energy aggregation, usage, and management. It is a key pathway for achieving local consumption and efficient utilization of distributed renewable energy. As the distributed multi-energy market emerges and develops, a large number of MGs, each belonging to different stakeholders, are expected to appear on the demand side in the future. The trend of adjacent microgrids cooperating as microgrid clusters is likely to emerge, posing increased challenges to system safety and stability.
Energy storage systems are a crucial means of mitigating fluctuations and deviations in renewable energy output. As microgrid clusters scale up in the future, the demand for energy storage resources and related services is expected to increase significantly. Given the high investment costs of energy storage systems, the capacity for independent storage within microgrids is often limited, leading to suboptimal resource utilization. Therefore, the development of business models for energy storage that encourage its participation and utilization, while stabilizing the output fluctuations and discrepancies in renewable energy, is a critical research focus. The “sharing model” offers a novel solution to this problem by pooling idle resources to meet diverse regulatory needs. It not only facilitates the time–space multiplexing of storage resources, improving efficiency, but also reduces investment costs through economies of scale, yielding a win-win outcome for all parties involved. Most existing shared storage models rely on electrochemical energy storage. Nowadays, hydrogen energy has gained significant attention due to its clean, low-carbon profile, scalability for extended periods and long-distance transport capabilities. A power-to-Gas (P2G) system with electrolyzers (ELs), hydrogen storage tanks (HSTs), and fuel cells (FCs), has proven to be a viable route for optimizing electric–hydrogen coordination. However, the current business models for hybrid electric–hydrogen shared storage remain in their early stages.
The purpose of this paper is to explore the feasibility of introducing a hybrid electric–hydrogen shared energy storage model into microgrid clusters. It examines how to ensure clean energy generation and economical power supply amidst the unpredictability of renewable energy sources and the complex interactions among various stakeholders.

1.2. Literature Review

The traditional idea of energy storage allocation involves users individually installing and operating storage systems to meet their own needs. This approach has seen considerable research, such as the work by Mahmoud Ahrari et al. [1] which optimized independent energy storage to enhance grid security, using robust optimization to address uncertainty risks. However, due to cost and space limitations, this approach often leads to inefficient resource utilization, hindering widespread adoption of energy storage [2]. As a response, a shared energy storage model, inspired by the “sharing economy”, has emerged. It can improve storage efficiency through distributing costs, so it can serve multiple users, and promote broader adoption of energy storage [3].
Existing shared energy storage mechanisms encompass capacity leasing and energy trading. In capacity leasing mode, a shared energy storage operator (SESO) divides its storage system into several segments, allocating them to different MGs. For example, Lai et al. [4] proposed a two-stage price-based approach: in the first stage, SESO sets its investment capacity and the price for leasing based on minimizing total investment cost, while in the second stage, users strategically adjust their required storage capacity based on published prices. Zhang et al. [5] explored optimal bidding strategies for renewable energy virtual power plants (VPPs) participating in the energy market using shared energy storage. The VPPs lease storage capacity from the SESO by paying for capacity usage rights and battery aging costs, with the leasing price determined by exogenous day-ahead market prices. Despite its simplicity, this method restricts user flexibility as the available capacity is predetermined. In contrast, the energy trading mechanism enables flexible energy exchanges between MGs and the shared energy storage system [6]. In this mode, when MGs sell energy to SESO, it is considered charging, while purchasing energy from SESO is viewed as discharging. Steriotis, K. et al. [7] developed a pricing model for shared energy storage based on real-time electricity prices, allowing for greater operational efficiency without compromising user benefits or SESO profits. Bian et al. [8] introduced a third-party entity, an energy-sharing coordinator, to facilitate energy trading between shared energy storage systems and data center clusters.
Most existing shared energy storage modes focus primarily on electrical storage (ES), which, while straightforward, has limitations. Multi-energy microgrids incorporate a variety of energy loads, including electrical, cooling, and heating. Therefore, energy sharing in other forms is essential to improve efficiency. Cao et al. [2] introduced a hybrid storage system for both ES and thermal energy (TES), allowing for the sharing of these energies among microgrid clusters. Simulation results demonstrated that this model effectively increased the utilization rate of renewable energy generation. Liu et al. [9] examined the bilateral trading of electrical and thermal energy between microgrid clusters and shared storage systems, analyzing the potential of this business model from an environmental perspective.
In recent years, with the advancement of P2G technology, hybrid electric–hydrogen storage has emerged as a novel research area. It combines electricity and hydrogen for mixed storage and distribution, offering a balance between hydrogen’s long-term storage capabilities and electricity’s rapid response, providing considerable flexibility. Several scholars have conducted studies on this hybrid model, yielding promising results. Deng et al. [10] investigated capacity optimization for shared electric–hydrogen storage in scenarios involving hydrogen loads, using a bi-level optimization model. The case study findings indicated that this approach could reduce microgrid cluster operating costs while significantly decreasing the total capacity of batteries. Li et al. [11] developed residential, industrial, and commercial energy systems, exploring the trading mechanisms for shared electric–hydrogen storage between different systems and storage operators. They proposed a hierarchical optimization scheduling model based on Stackelberg game theory to derive optimal energy-sharing strategies and pricing mechanisms. Similarly, Qiu et al. [6] proposed a new shared storage service model incorporating P2G technology. Unlike the study by Li et al. [11], Qiu’s work focused on bilateral electricity trading and unidirectional hydrogen trading between microgrid clusters and SESO. Shi et al. [12] investigated a similar shared storage trading scheme but with only bilateral electricity trading between microgrid clusters and shared storage. These studies on shared electric–hydrogen storage offer valuable insights. However, prior research primarily addresses the feasibility of hybrid storage models without delving into the competitive dynamics among different stakeholders or the impact on energy supply and demand characteristics. This gap presents an opportunity for further research to enhance economic benefits and energy efficiency.
There are different types of decision-makers in the shared energy storage mode, including SESO, microgrid operators (MGOs), and microgrid users. Each has its own goal, focusing on either minimizing costs or maximizing profits, which can lead to conflicting interests. This conflict makes it crucial to design effective incentive mechanisms to coordinate these stakeholders. Yan and Chen [13] categorized shared energy storage pricing mechanisms into three types: marginal price-based, game theory-based, and heuristic-based. They suggested that the marginal price-based approach requires centralized data collection and has high computational complexity, making it suitable only for small-scale systems. The heuristic-based approach relies on expert judgment and is more applicable to specific cases. Given these considerations, game theory-based mechanisms, with their emphasis on privacy protection and versatility, are a preferable solution to harmonize these conflicting interests.
Many researchers have started using game theory to study the settlement issues of shared energy storage. Shuai et al. [14] utilized Stackelberg game to develop a win-win revenue-sharing strategy between MGs and SESO. A. Fleischhacker et al. [15] investigated shared energy storage in residential buildings, where a third-party service provider acts as the leader in Stackelberg game, aiming to maximize profits through price adjustments. Meanwhile, consumers play the role of followers, strategically adjusting their energy storage usage and electricity purchasing plans to minimize costs. Sun et al. [16] applied auction theory to shared energy storage, where SESO and users engage in combined double-sided auctions under an auctioneer’s organization. They proposed a pricing mechanism that equally divides social welfare between buyers and sellers. These studies are modeled based on non-cooperative game theory, which can lead to game equilibria deviating from social optima, potentially limiting the ability to maximize social welfare or ensure fair resource allocation. Conversely, cooperative games based on Nash bargaining theory offer advantages such as computational simplicity and the ability to achieve Pareto-optimal solutions [17]. Many studies have combined the Nash bargaining game with the Alternating Direction Method of Multipliers (ADMM) algorithm to allocate the benefits of shared energy storage. Such an approach allows participants to maintain privacy while preserving their decision-making independence. For example, Zhang et al. [18] applied generalized Nash bargaining to solve the joint planning problem of shared energy storage between prosumers. Similarly, Dai et al. [19] developed a Nash bargaining model to encourage users to engage in shared energy storage collaboration, demonstrating that this approach can optimize energy arbitrage and ensure fair benefit distribution. However, these studies often overlook the role of users in energy trading. Actually, users in multi-energy microgrids play a significant role in system optimization and operation. With a more finely segmented energy market, the interactions between internal sources and loads have become more pronounced. Users are increasingly participating in market transactions. Energy prices set by MGOs not only affect user load demand but energy loads also react to prices. Therefore, in addition to studying the profit distribution mechanism between SESO and MGOs, further consideration must be given to the impact of user participation in market trading on system optimization. In parallel with game-theoretic approaches, distributed consensus-based coordination has recently gained prominence in microgrid management [20]. These methods excel in achieving global convergence on technical state variables via local information exchange [21], offering high robustness against communication failures. However, standard consensus algorithms typically assume cooperative agents pursuing a unified global objective. In contrast, the shared energy storage ecosystem involves stakeholders (SESO, MGOs, Users) with distinct, often conflicting, financial interests. Therefore, while consensus methods are effective for technical coordination, the hybrid game framework is more advantageous for addressing the economic conflicts and ensuring incentive compatibility through equitable benefit allocation.
Given the significant presence of renewable energy sources within MGs, the inherent uncertainty in their output can impact the optimization strategies of participating stakeholders. Thus, it is crucial to investigate how uncertain variables affect the optimal operation of such systems. Common modeling approaches include stochastic optimization and robust optimization. The former relies on precise distribution information of uncertain variables, which is often challenging to obtain in real-world scenarios [22]. The latter focuses on worst-case scenarios, ignoring distribution details and leading to a conservative approach [23]. Recently, distributionally robust optimization (DRO) has emerged as a method that offers a balance between reliability and economic efficiency. Depending on how fuzzy sets are constructed, DRO can be categorized into four types: based on moment information, discrete scenarios, Kullback–Leibler (KL) divergence, and Wasserstein distance [24]. Among these, Wasserstein-based DRO creates fuzzy sets using the Euclidean norm between different probability distributions, making it more comprehensive in utilizing historical data and applicable in a wider range of scenarios compared to other DRO types [25]. Zhai et al. [26] proposed an energy management model driven by Wasserstein-based DRO to examine the impact of uncertain renewable energy sources on energy sharing among multi-energy microgrid clusters. Fan et al. [25] introduced a DRO approach that combines nonparametric kernel density estimation with Wasserstein distance. Although DRO methods have found wide application in energy systems, research on their use in shared energy storage business models is limited. Wang et al. [27] used KL divergence-based DRO to study capacity planning for mixed shared energy storage. Li et al. [28] provided a quantitative analysis of various benefits in a park-based hydrogen storage sharing model and introduced a Wasserstein-based DRO to analyze the scenario.
The above studies consider the uncertainty in probability distributions but do not address potential tail risks when developing scheduling plans, making it difficult for operators to understand the risk profile of the system. To intuitively grasp these tail risks, risk measurement tools from economics, particularly conditional value at risk (CVaR), can be utilized. CVaR offers advantages like convexity, subadditivity, and consistency, providing more accurate tail risk assessments [29]. Liu et al. [30] designed a piecewise affine function combining expected returns and corresponding CVaR to address uncertainties in electricity prices and wind power output. They applied a data-driven Wasserstein DRO model to maximize VPP profits, showing that the model incurs lower extra risk costs in balancing wind power shortages. Zeng et al. [31], while examining the scheduling optimization of AC/DC systems, considered CVaR for intra-day system adjustment costs and used KL divergence to construct a fuzzy set of probability distributions for uncertainty. However, no similar applications have been observed in the study of multi-microgrids shared energy storage systems.
A comparative analysis of this study against prior works is presented in Table 1. While existing literature has made strides in shared energy storage, three fundamental limitations remain: (1) Most studies focus exclusively on electrical storage, neglecting the cross-sectoral flexibility offered by hybrid electric–hydrogen systems. This overlooks the potential for long-duration storage and the economic synergy between P2G conversion and fuel cells. (2) Existing coordination frameworks typically employ either pure cooperative games (ignoring the market power hierarchy) or non-cooperative games (ignoring fairness in benefit distribution). They often treat end-users as passive loads, failing to capture the “efficiency-fairness” trade-off in a multi-layer market where users act as independent stakeholders. (3) Standard approaches often rely on stochastic optimization (requiring exact distributions) or static robust optimization (overly conservative). They seldom integrate decision-makers’ risk aversion with data-driven ambiguity sets to balance robustness and economic performance under severe uncertainty.
To address these issues, this paper introduces a model for a multi-microgrids shared electric–hydrogen hybrid storage system, incorporating one SESO and multiple microgrids. The SESO hosts both ES and P2G systems, facilitating energy sharing and storage within the alliances. Given the varying interests and dynamic characteristics of the energy market, a cooperative alliance model is proposed, incorporating Stackelberg game between MGOs and end-users. The pricing strategies derived from this model are based on the Karush–Kuhn–Tucker (KKT) conditions and the ADMM algorithm. Additionally, the uncertainty in renewable energy output is addressed through DRO, which integrates CVaR cost to account for risk in extreme scenarios under the worst-case probability distribution.
The key contributions of this paper are as follows. (1) By integrating a shared electric–hydrogen architecture, the SESO can host both ES and P2G systems, facilitating cross-vector energy sharing and alleviating balance pressures within the alliance. (2) A nested Nash–Stackelberg game framework is proposed to model the complex interactions. This mechanism simultaneously respects the vertical pricing authority of MGOs over users and ensures horizontal cooperative fairness between the SESO and MGOs. (3) A data-driven WDRO model incorporating CVaR is developed. This fills the gap in risk management by allowing operators to explicitly trade-off between operational cost and protection against worst-case renewable fluctuations.
The remainder of this paper is organized as follows: Section 2 outlines the MGs-SESO system structure, detailing the interaction strategies among various stakeholders. Section 3 provides modeling for different stakeholders and explains the methodology for solving the hybrid game equilibrium. Section 4 presents a case study analysis, and Section 5 concludes the paper.

2. System Structure and Trading Strategies

2.1. System Structure

The energy cooperation framework of MGs-SESO is illustrated in Figure 1. It involves three primary stakeholders: MGOs, end-users, and the SESO. MG users have both electricity and heat load demands. Besides addressing fixed loads for basic needs, this study considers the transferability and reducibility of electrical loads, as well as the reducibility of heat loads, enabling integrated demand response for users.
MGOs supply electricity and heat to their users through wind turbines (WTs), photovoltaic systems (PV), combined heat and power units (CHP), electric boilers (EBs), and gas boilers (GBs). They can also acquire energy from external sources. Since gas units are minimally affected by hydrogen blending at ratios of 10–20%, natural gas can be mixed with hydrogen to create a cleaner energy source [32]. When the internal supply in the MG exceeds demand, MGOs can sell surplus electricity to SESO. Conversely, when there is an energy deficit, they can buy electricity and hydrogen from SESO to meet their needs. This mechanism allows indirect energy sharing between MGs.
The SESO includes components such as ES, EL, FC, and HST. It can store electricity in ES or produce hydrogen via electrolyzers by utilizing surplus power from MGs or purchasing electricity from the grid. The hydrogen generated can be stored in HST or sold directly to the hydrogen market. When energy shortages occur in MGs, SESO can release electricity from ES or convert the stored hydrogen in the tanks into electricity using FC to meet MGs’ power demand. Additionally, SESO can also sell hydrogen directly to MGs for use in hydrogen-blended units. The high flexibility and reliability of this electric–hydrogen shared storage system make it well-suited for providing continuous, stable energy to multiple microgrids simultaneously.

2.2. Hybrid Game-Based Trading Strategies

The interactions of various stakeholders within the system are intricate, necessitating the design of a fair and efficient trading mechanism to incentivize active participation in energy trading and sharing. The multi-agent hybrid game interaction strategy proposed in this paper is based on the following assumptions: (1) Each microgrid is operated by its own operator, responsible for internal market optimization and settlement, with no direct energy exchange between MGs. Their data and processes remain confidential. (2) SESO consolidates information from multiple MGs via an energy-sharing trading platform to facilitate energy pricing and exchange.
The specific trading strategy is outlined as follows:
(1)
Within each MG system, MGO, as the leader, sets energy purchase prices for users based on supply–demand dynamics and market information. MG users then optimize their load demand according to the energy pricing information provided by the MGO. The decision-making sequence between pricing and load optimization forms a Stackelberg game.
(2)
MGOs and SESO, acting as independent rational entities, engage in trading as equals, with their transactions achieved through repeated negotiations and consensus-building. After completing their internal interactions with users, MGOs can choose to participate in energy trading with SESO as buyers or sellers. SESO, by integrating feedback from MGOs, manages P2G and ES systems and sets pricing strategies. Their decisions are influenced by the trading prices and volumes of electricity and hydrogen, with pricing convergence achieved through multiple rounds of information exchange. This leads to optimal social welfare.
Based on the aforementioned trading strategy, this paper constructs a two-layer hybrid game model, as depicted in Figure 2. The outer layer represents cooperative game between MGOs and SESO, while the inner layer represents Stackelberg games between MGOs and users within individual decentralized and autonomous MGs.
The proposed hybrid framework is designed to address the distinct interaction characteristics within the system:
(1)
Vertical Interaction (Stackelberg Game): The MGO–User relationship is inherently hierarchical. MGOs act as leaders (price-makers), while users act as followers (price-takers). The Stackelberg formulation captures this market power asymmetry more accurately than cooperative models, as individual users typically lack the bargaining leverage to negotiate prices directly with operators.
(2)
Horizontal Interaction (Nash Bargaining): The SESO–MGOs relationship is collaborative, involving independent entities with equal status. Unlike non-cooperative formulations (e.g., Cournot or monopoly models) which often suffer from efficiency losses (e.g., double marginalization), the Nash bargaining framework guarantees a Pareto-optimal solution. Crucially, it provides a mechanism for fair surplus distribution, which is essential for incentivizing the long-term participation of independent microgrids.

2.3. Modeling Assumptions and Practical Implications

This section justifies the key assumptions made in the model and discusses the practical implications of relaxing these assumptions.
First, the blending ratio of hydrogen is assumed to be fixed at 20%. This assumption is grounded in current safety standards for natural gas infrastructure. Studies indicate that blending hydrogen up to 20% into existing natural gas pipelines and end-use equipment typically does not require significant retrofitting or compromise safety. Furthermore, treating the blending ratio as a variable would introduce bilinear terms (product of gas volume and blending ratio) into the constraints, rendering the model non-convex and significantly increasing computational complexity.
Second, the assumption that SESO operates as a neutral platform is made for simplicity and fairness in modeling. This assumption aligns with the regulatory trend of treating energy storage as a shared infrastructure or a regulated service to prevent market power abuse. In this framework, the SESO aims to maximize the collective surplus of the coalition and ensure fair distribution via Nash bargaining, rather than extracting monopoly rents from microgrids. Relaxing this assumption would introduce a competitive dimension to the model, potentially lowering energy costs for microgrids.
Third, the model assumes that microgrids are independent except for their interactions through the SESO. In practice, microgrids often belong to different stakeholders with strict data privacy requirements. They are unwilling to share detailed internal topology or load data directly with other microgrids. Relaxing this to allow direct Peer-to-Peer (P2P) trading between microgrids would require a more complex mesh network infrastructure and transparent information sharing protocols. While P2P trading might marginally improve local matching efficiency, it faces significant regulatory and privacy barriers compared to the mediator-based approach proposed here.
Fourth, to address the uncertainty in renewable energy output, we employ a linear affine recourse strategy for the second-stage decision variables in the WDRO model. In two-stage robust optimization, finding a fully adaptive recourse policy is generally NP-hard. The affine policy, which assumes that the adjustment of flexible resources (e.g., CHP, GB) is linearly proportional to the forecast error, serves as a standard approximation in power system optimization. It transforms an infinite-dimensional functional optimization problem into a tractable finite-dimensional conic programming problem, ensuring that the model can be solved within the time limits required for day-ahead markets. A non-affine strategy would allow for a more accurate representation of how resources can be adjusted in response to forecast errors but would also introduce additional complexity in solving the optimization problem.
Finally, the proposed model relies on the assumptions of full rationality, complete information transparency between the SESO and MGOs, and known user utility functions. While human decision-making in real-world scenarios is often characterized by “bounded rationality” and information asymmetry, these assumptions are justified within the context of automated smart grids. In practical engineering applications, the complex dispatch decisions are not made by humans manually but are executed by automated Energy Management Systems and smart controllers. These algorithmic agents operate strictly according to pre-defined optimization logic, thereby aligning practical operations closely with the assumption of rational behavior. Regarding the “known utility functions,” while exact user preferences are difficult to capture perfectly, they can be effectively approximated in practice using data-driven methods, such as inverse reinforcement learning or historical load analysis. Therefore, the proposed framework serves as a theoretical benchmark for the system’s maximum potential efficiency, providing a target for actual system design.

3. Mathematical Model and Solution Methodology

3.1. Deterministic Optimization Model

3.1.1. Model of the SESO

The operational objective of SESO is to maximize daily operating profits, as indicated in Equation (1), primarily considering three components: revenue from energy exchanges with microgrid clusters R S E S O t r a d i n g , income from energy market trading R S E S O m a r k e t , and costs associated with equipment operation and maintenance C S E S O o m [11].
max I S E S O = R S E S O t r a d i n g + R S E S O m a r k e t C S E S O o m = t = 1 T i = 1 N λ t e l e , b P i , t b λ t e l e , s P i , t s + λ t h y d , b V i , t b + λ h y d , t m a r k e t V m a r k e t , t λ g r i d , t s e l l P s e s o , t g r i d ( δ E L P E L , t + δ F C P F C , t + δ h s t V H S T , t c h + δ h s t V H S T , t d i s + δ e s P E S , t c h + δ e s P E S , t d i s ) Δ t
where λ t e l e , b and λ t e l e , s represent the electricity trading prices set by SESO at time t . P i , t b and P i , t s are electricity purchased and sold by M G O i , respectively. λ t h y d , b and V i , t b denote the hydrogen purchase price and quantity of M G O i . λ h y d , t m a r k e t and V m a r k e t , t refer to the hydrogen retail price in the hydrogen market and the amount of hydrogen SESO sells to the hydrogen market, respectively. Similarly, λ g r i d , t s e l l and P s e s o , t g r i d represent the grid selling price and the amount of electricity SESO purchases from the main grid. δ E L , δ F C , δ h s t and δ e s are the unit operational costs of EL, FC, HST, and ES. P E L , t is the power consumption of the EL at time t , while P F C , t denotes the output power of FC. V H S T , t c h and V H S T , t d i s are the quantities of hydrogen charged into and discharged from HST. P E S , t c h and P E S , t d i s are the ES charging and discharging amounts at time t .
The operational constraints to be met are as follows:
(1)
The EL converts electricity to hydrogen through water electrolysis, with the following operational requirements.
V E L , t = η E L P E L , t α H 2 P E L , min P E L , t P E L , max
where η E L represents the efficiency of hydrogen production in the electrolyzer. V E L , t denotes the amount of hydrogen generated by the electrolyzer at time t . α H 2 is the calorific value of hydrogen, taken as 3.55 kWh/m3. P E L , min and P E L , max are the minimum and maximum power consumption of EL.
(2)
FC converts the chemical energy in hydrogen and oxygen into electricity via redox reactions, subject to the following constraints.
P F C , t = η F C V F C , t α H 2 P F C , min P F C , t P F C , max
where η F C represents the efficiency of FC. V F C , t is the hydrogen consumption of FC at time t . P F C , min and P F C , max are the lower and upper bounds for the FC’s power output.
(3)
The HST must meet the following constraints.
S H S T , t = S H S T , t 1 + κ H S T , t η H S T c h V H S T , t c h 1 κ H S T , t V H S T , t d i s η H S T d i s S H S T , min S H S T , t S H S T , max S H S T , 1 = S H S T , 24 0 V H S T , t c h κ H S T , t V H S T , max c h 0 V H S T , t d i s 1 κ H S T , t V H S T , max d i s
where S H S T , t represents the HST state of charge at time t . κ H S T , t denotes the hydrogen charging/discharging status, acting as a binary indicator where 1 signifies charging. η H S T c h and η H S T d i s are the efficiencies for charging and discharging, respectively. S H S T , min and S H S T , max are the upper and lower bounds of the hydrogen storage capacity. V H S T , max c h and V H S T , max d i s are the upper limits for hydrogen charging and discharging at time t . The operational constraints for ES are analogous to those for HST, and therefore not detailed here.
(4)
Electricity and hydrogen power balance constraints in the system.
V F C , t + V H S T , t c h + V m a r k e t , t + i = 1 N V i , t b = V E L , t + V H S T , t d i s P E L , t + P E S , t c h = i = 1 N P i , t s + P s e s o , t g r i d P F C , t + P E S , t d i s = i = 1 N P i , t b
(5)
The energy transaction pricing between SESO and MGs should meet the following constraints.
λ g r i d , t b u y λ t e l e , s λ t e l e , b λ g r i d , t s e l l λ t , min h y d λ t h y d , b λ t , max h y d
where λ g r i d , t b u y is the feed-in tariff. λ t , min h y d and λ t , max h y d are the lower and upper bounds of hydrogen prices.
The SESO acts as the central coordinator of the shared energy storage system and determines the optimal scheduling of electricity–hydrogen conversion devices and storage resources over the scheduling horizon. The decision variables in this model mainly represent the charging and discharging of the energy storage, the operation of EL, FC and HST, as well as the electricity trading prices released to downstream participants. The objective function reflects the trade-off between maximizing operational revenue from electricity transactions and minimizing equipment operation and maintenance costs. Constraints (2)–(5) describe the physical conversion relationships between equipment, ensuring that the scheduling decisions strictly follow the thermodynamic and technical characteristics of the devices.

3.1.2. Model of the Microgrid Operator

The microgrid operator needs to optimize equipment output, develop energy trading strategies, and set user-facing energy pricing strategies. The goal is to maximize its revenue, as defined by Equation (7). It encompasses user energy sales revenue R M G O i , equipment maintenance costs C M G O i o m , energy trading costs with SESO C M G O i t r a d i n g , and interaction costs with upper energy networks C M G O i n e t w o r k [6].
max I M G O i = R M G O i C M G O i o m C M G O i t r a d i n g C M G O i n e t w o r k = t = 1 T λ i , t e l e , u s e r P i , t l o a d + λ i , t h e a t , u s e r H i , t l o a d δ W T P i , t W T + δ P V P i , t P V + δ C H P P i , t C H P + δ G B H i , t G B + δ E B H i , t E B λ t e l e , b P i , t b λ t e l e , s P i , t s + λ t h y d , b V i , t b λ g r i d , t s e l l P i , t g r i d + λ g a s , t G i , t n e t w o r k + λ h y d , t m a r k e t V i , t n e t w o r k Δ t
where λ i , t e l e , u s e r and λ i , t h e a t , u s e r represent the electricity and heat prices charged to users at time t . P i , t l o a d and H i , t l o a d are the corresponding electrical and thermal load power. δ W T / δ P V / δ C H P / δ G B / δ E B denote the operational cost coefficients for WT/PV/CHP/GB/EB. P i , t W T , P i , t P V and P i , t C H P are electricity outputs of WT, PV, and CHP at time t . H i , t G B and H i , t E B are heat outputs of GB and EB at time t . P i , t g r i d , G i , t n e t w o r k and V i , t n e t w o r k are purchased energy from upper energy networks. λ g a s , t is the gas purchase price
The following constraints need to be met.
(1)
The hydrogen-blended CHP generates electricity while producing high-temperature exhaust gases that can be recovered and converted into heat for user consumption [6].
α m i x = κ H 2 α H 2 + ( 1 κ H 2 ) α g a s P i , t C H P = η G T α m i x G i , t C H P + V i , t C H P H i , t C H P = 1 η G T η W H B η H E η G T P i , t C H P P i , min C H P P i , t C H P P i , max C H P
where κ H 2 is the hydrogen blending ratio in natural gas, which is set at 20% in this study. α g a s is the calorific value of natural gas, taken as 9.75 kWh/m3. η G T is electricity generation efficiency of the gas turbine. G i , t C H P and V i , t C H P denote the volumes of natural gas and hydrogen consumed by CHP at time t . η W H B and η H E represent the efficiencies of the waste heat recovery system and the heat exchanger. H i , t C H P indicates the heat output of the CHP system at time t . P i , min C H P and P i , max C H P are the lower and upper limits for the CHP output.
(2)
Similarly, the hydrogen-blended GB system has the following constraints.
H i , t G B = η G B α m i x G i , t G B + V i , t G B H i , min G B H i , t G B H i , max G B
where G i , t G B and V i , t G B represent the natural gas and hydrogen consumption by GB at time t . η G B denotes the thermal efficiency. H i , min G B and H i , max G B are the lower and upper output limits of GB.
(3)
EB operational constraints.
H i , t E B = η E B P i , t E B P i , min E B P i , t E B P i , max E B
where η E B represents the heat generation efficiency of EB. P i , t E B is the electricity consumption at time t . P i , min E B and P i , max E B are the minimum and maximum limits of electricity consumption by EB.
(4)
Due to the transmission capacity limitations, energy transactions of MG i with the upper grid and SESO must meet the following constraints.
0 P i , t g r i d P i , t , max g r i d 0 κ i , t P i , t b P i , t max 0 ( 1 κ i , t ) P i , t s P i , t max 0 V i , t b V i , t max
where P i , t , max g r i d represents the maximum amount of electricity that can be purchased from the upper grid. κ i , t is the binary indicator for power trading with SESO. P i , t max and V i , t max represent the upper limits for electricity and hydrogen transmission capacity.
(5)
The MG i system must maintain power balance.
P i , t g r i d + P i , t W T + P i , t P V + P i , t C H P + P i , t b = P i , t E B + P i , t l o a d + P i , t s H i , t C H P + H i , t G B + H i , t E B = H i , t l o a d V i , t b + V i , t n e t w o r k = V i , t C H P + V i , t G B G i , t n e t w o r k = G i , t C H P + G i , t G B
(6)
To prevent users from trading directly with grid, the energy sale price offered by operators must meet the following conditions [33].
λ i , t , min e l e , u s e r λ i , t e l e , u s e r λ i , t , max e l e , u s e r λ i , t , min h e a t , u s e r λ i , t h e a t , u s e r λ i , t , max h e a t , u s e r
where λ i , t , min e l e , u s e r / λ i , t , min h e a t , u s e r and λ i , t , max e l e , u s e r / λ i , t , max h e a t , u s e r are the upper and lower bounds for electricity/heat energy prices, respectively.
The MGO represents a profit-driven operator that manages local generation units and interacts with both the SESO and the upper energy network. The objective function captures the economic trade-off between energy purchasing costs, equipment operating costs, and revenues obtained from supplying electricity and heat to end-users. Constraints (8)–(12) ensure that the MGO’s operational decisions comply with equipment characteristics and network limitations. This model therefore reflects how the MGO optimizes multi-energy supply strategies in response to energy prices released by SESO while considering technical constraints and market interactions.

3.1.3. Model of the End-User

Based on the energy prices provided by M G O i , users implement demand response to maximize consumer surplus, defined as the utility function minus energy costs, as shown in Equation (14) [33].
max I U s e r i = t = 1 T v i e l e P i , t l o a d u i e l e 2 P i , t l o a d 2 + v i h e a t H i , t l o a d u i h e a t 2 H i , t l o a d 2 λ i , t e l e , u s e r P i , t l o a d λ i , t h e a t , u s e r H i , t l o a d Δ t
where v i e l e , v i h e a t , u i e l e and u i h e a t represent the preference coefficients for electrical and thermal energy consumption of U s e r i .
The user’s electrical load consists of fixed P i , t l o a d , 0 , transferable P i , t l o a d , t s l , and reducible loads P i , t l o a d , i l , expressed as follows:
P i , t l o a d = P i , t l o a d , 0 + P i , t l o a d , t s l P i , t l o a d , i l
When implementing demand response, the following constraints must be met.
P i , t , max l o a d , t s l P i , t l o a d , t s l P i , t , max l o a d , t s l t = 1 T P i , t l o a d , t s l = 0 0 P i , t l o a d , i l P i , t , max l o a d , i l
where P i , t , max l o a d , t s l and P i , t , max l o a d , i l represent the maximum transferable and reducible electric loads at time t .
Additionally, user thermal loads comprise both fixed thermal loads H i , t l o a d , 0 and reducible thermal loads H i , t l o a d , i l . To ensure user comfort and sufficient energy supply, the following constraints must also be met.
H i , t l o a d = H i , t l o a d , 0 H i , t l o a d , i l 0 H i , t l o a d , i l H i , t , max l o a d , i l
where H i , t , max l o a d , i l is the upper limit for heat load reduction for users in MG i at time t .
End-users participate in demand response by adjusting their electricity and heat consumption according to the energy prices announced by the MGO. The decision variables represent transferable and reducible loads, which describe the flexibility of user-side energy consumption. The objective function models user utility as the difference between energy satisfaction and energy expenditure, reflecting the trade-off between comfort and economic incentives. The constraints characterize the allowable range of load shifting and reduction, ensuring that the demand response remains within acceptable comfort limits.

3.2. Risk-Based Model Reconstruction

Microgrids contain a high proportion of renewable energy sources, the uncertainty of their output must be considered due to its significant impact on MGOs’ scheduling decisions. Therefore, this section introduces the flexibility resources adjustment cost and its CVaR value to adjust MG i optimization strategies. It proposes a Wasserstein-based distributionally robust optimization model (WDRO) incorporating CVaR to reduce system operation risk.

3.2.1. Distributionally Robust Optimization Theory

(1)
Wasserstein ambiguity set
DRO method integrates historical data of uncertain variables to generate various sample distributions. It constructs fuzzy sets based on different distribution parameters, accounting for both parameter uncertainty and the uncertainty in their distribution.
Definition 1 
(Wasserstein Metric) [8]. For two distributions P 1 and   P 2  on   M Ξ , the Wasserstein distance is defined by
d W P 1 , P 2 = inf Π Ξ 2 ξ ^ 1 ξ ^ 2 Π d ξ 1 , d ξ 2
 where  Π is a joint distribution on M Ξ × M Ξ with marginals P 1 and  P 2 . Ξ is the support set.
During the MG operation, WT and PV power outputs are both highly uncertain. Assuming the total forecasting error ξ ˜ t of renewable energy output at time t is an unknown probability distribution, its empirical distribution P t ^ can be derived from a sample set of historical data as follows.
P t ^ = 1 M m = 1 M Θ ξ ^ m t
where ξ ^ m t , m M represents the sample value of ξ ˜ t . Θ ξ ^ m t is the Dirac measure for this sample.
Then, based on the empirical distribution, a fuzzy set representing the actual distribution can be derived using the Wasserstein metric.
t = P t M Ξ t | d W P t ^ , P t < γ M , β
where t represents the fuzzy set of the actual distribution of forecast errors at time t . γ M , β is the Wasserstein radius, which varies depending on the sample size and confidence level, with specific calculation methods provided in Ref. [34]. M Ξ t represents all possible probability distributions of forecast errors within the support set Ξ t . Here, the support set is modeled as a box set Ξ t = ξ ˜ t : H t ξ ˜ t h t [30].
(2)
Risk-based strategies with WDRO
When renewable energy forecasts are inaccurate, M G O i must re-dispatch flexible resources to mitigate the adverse effects, leading to adjustment costs. To address fluctuations in WT and PV output, this paper adopts the affine strategy to adjust the output of flexible resources such as CHP and GB, allowing them to share the burden of compensating for the forecast errors. This approach ensures real-time power system balance. The total error in WT and PV output forecasts is represented as follows [25].
P ˜ i , t W T = P i , t W T + ξ ˜ i , t W T P ˜ i , t P V = P i , t P V + ξ ˜ i , t P V ξ ˜ i , t = ξ ˜ i , t W T + ξ ˜ i , t P V
where ξ ˜ i , t is the total output deviation in MG i at time t . ξ ˜ i , t W T and ξ ˜ i , t P V are the output deviations in WT and PV, respectively. With the introduction of participation factor y i , t , the actual power of the flexible resources in MG i can be calculated as follows.
P ˜ i , t C H P = P i , t C H P + y i , t C H P ξ ˜ i , t P ˜ i , t E B = P i , t E B + y i , t E B ξ ˜ i , t H ˜ i , t G B = H i , t G B + y i , t G B ξ ˜ i , t P ˜ i , t g i r d = P i , t g i r d + y i , t g i r d ξ ˜ i , t 1 y i , t 1
where P ˜ i , t C H P , P ˜ i , t E B , H ˜ i , t G B and P ˜ i , t g i r d represent the actual power output for the corresponding units.
The objective of WDRO is to minimize the adjustment cost under the worst-case distribution within a given fuzzy set of probability distributions. However, methods based on expected mean values often fail to capture the risk associated with system decisions and the impact of extreme scenarios. To address this, the paper introduces a risk metric and uses it to adjust the WDRO strategy of MG i . Equation (7) is rewritten as follows.
O M G O i ( x i , y i , ξ ˜ i ) =   min x i , y i I M G O i + sup ( 1 ω i ) E F y i , ξ ˜ i + ω i C V a R F y i , ξ ˜ i
Where F y i , ξ ˜ i = C ˜ M G O i o m + t = 1 T λ g r i d , t s e l l P ˜ i , t g i r d is the adjustment cost for flexible resource deployment in M G i . x i , y i are the decision variables for the first and second stages, respectively. E denotes the expected value operator. sup is the upper bound function. represents the probability distribution of the total error in WT and PV forecasts. is the fuzzy set for uncertainty modeling. C V a R stands for the risk measure, with ω i 0 , 1 as the tail risk coefficient in MG i , indicating the degree to which the M G O i is risk-averse; a higher ω i value signifies a stronger preference for risk avoidance. In the WDRO context, the calculation is as follows [30].
C V a R β C V a R F y i , ξ ˜ i = E F y i , ξ ˜ i V a R β C V a R = inf E τ i + 1 1 β C V a R F y i , ξ ˜ i τ i +
where τ i represents value-at-risk V a R β C V a R . β C V a R 0 , 1 indicates the confidence level. A higher value suggests lower risk aversion. F y i , ξ ˜ i τ i + is defined as max F y i , ξ ˜ i τ i , 0 . Similarly, this formula assesses the tail risk under the worst-case scenario within a given fuzzy set of probability distributions.
In addition to the constraints in Equations (8)–(13), the actual values of the parameters must also meet the following conditions [24].
min P i , min C H P P ˜ i , t C H P P i , max C H P 1 ε i min H i , min G B H ˜ i , t G B H i , max G B 1 ε i min P i , min E B P ˜ i , t E B P i , max E B 1 ε i min 0 P ˜ i , t g r i d P i , t , max g r i d 1 ε i y i , t g i r d + y i , t C H P y i , t E B + 1 = 0 1 η G T η W H B η H E η G T y i , t C H P + y i , t G B + η E B y i , t E B = 0 κ H 2 η G T α m i x y i , t C H P + κ H 2 η G B α m i x y i , t G B = 0
where ε i is the risk coefficient for distributionally robust chance-constrained optimization.

3.2.2. Reformulation of the WDRO-CVaR Model

To better describe the problem, the M G O i ’s WDRO-CVaR model can be abstractly represented in the following compact form.
min x , y c T x + sup E max s = 1 , 2 ψ s δ T y ξ ˜ + ζ s τ s . t . h l x = 0 , l L g j x 0 , j J q y = 0 , q Q inf   a k y T ξ ˜ + b k x 0 , k K 1 ε
where ψ 1 = 1 ω + ω 1 β C V a R , ζ 1 = β C V a R 1 β C V a R ω ; ψ 2 = 1 ω , ζ 2 = ω . x = P W T , P P V , P C H P , H G B , P E B , P b , P s , V b , P g r i d , λ e l e , u s e r , λ h e a t , u s e r , y = y C H P , y G B , y E B , y g i r d , δ = δ W T , δ P V , δ C H P , δ G B , δ E B , λ g r i d . The constraints in the first two lines pertain to the first-stage decision variables x and correspond to Equations (8)–(13). The third line contains constraints for the second-stage decision variables y , aligning with the last three equality constraints in Equation (25). The fourth line comprises distributionally robust chance constraints involving both decision variables and random variables, corresponding to the first four constraints in Equation (25). L , J , Q , K indicates the number of respective constraints.
Given that the objective function involves a worst-case expectation and the constraints include distributionally robust chance constraints, these elements require conversion for solving. According to [30], under the premise of a support set Ξ = ξ ˜ : H ξ ˜ h , strong duality theory and auxiliary variables can be employed to transform the objective function into an equivalent form in Equation (27).
min x , y c T x + γ λ o + 1 M m = 1 M μ m o s . t . ζ s τ + ψ s δ T y ξ ^ m + ι m o T h H ξ ^ m μ m o , m M H T ι m o ψ s y T δ λ o , m M λ o 0 , ι m o 0 , m M
where λ o , ι m o , μ m o are the introduced auxiliary variables. represents the dual norm defined in the context of the Wasserstein distance.
As described in [35], the distributionally robust chance constraint inf a k y T ξ ˜ + b k x 0 , k K 1 ε is transformed as shown in Equation (29).
λ k c γ + 1 M m = 1 M μ m k c 0 ϕ k c μ m k c a k y T ξ ^ m + b k x + ε 1 ϕ k c + ε ι m k c T h H ξ ^ m ε μ m k c ε H T ι m k c a k y ε λ k c ι m k c 0 , m M , k K
where λ k c , μ m k c , ϕ k c , ι m k c are the introduced auxiliary variables.
The incorporation of CVaR into the WDRO framework introduces risk aversion into the decision-making process. Instead of optimizing the expected operational cost, the model minimizes the potential losses under the worst-case probability distribution within the Wasserstein ambiguity set. The auxiliary variables introduced in Equations (27)–(29) transform the original worst-case expectation problem into a tractable equivalent form. This reformulation enables the MGO to make conservative scheduling decisions that hedge against extreme unfavorable renewable generation outcomes. As a result, the system no longer operates based on average scenarios but instead prioritizes robustness and reliability, ensuring stable operation even when renewable forecasts deviate significantly from reality.

3.3. Model Solution

3.3.1. Stackelberg Game Equilibrium

Both the MGO and users are independent stakeholders within the MG. MGO, as energy suppliers, possess the capacity to set prices, reflecting the characteristics of Stackelberg game. As the leader, M G O i aims to maximize their benefits by optimizing power generation and energy pricing. The users, as followers, seek to improve their energy utilization satisfaction by optimizing their energy purchasing plans. Both parties adjust their strategies based on the other’s actions, as outlined in G i = N i ; λ M G O i , P M G O i , P U s e r i ; O M G O i , I U s e r i [33]. It encompasses three key elements: participants, strategies, and outcomes. The set of participants includes M G O i and its users, denoted as N i = M G O i , U s e r i . λ M G O i represents the energy pricing strategies set of M G O i , while P M G O i denotes its strategies for managing output plans, energy purchasing from upper networks, and energy interaction with SESO. P U s e r i is the energy usage strategies set of U s e r i . O M G O i is the M G O i ’s objective function (referencing Equation (23)), and I U s e r i is the U s e r i ’s objective function (referencing Equation (14)).
The game reaches a Stackelberg equilibrium when the followers optimize their response to the leader’s energy pricing strategy and the leader accepts this response. At this point, the equilibrium solution, λ M G O i , P M G O i , P U s e r i , must satisfy the following conditions:
O M G O i λ M G O i , P M G O i , P U s e r i O M G O i λ M G O i , P M G O i , P U s e r i I U s e r i λ M G O i , P M G O i , P U s e r i I U s e r i λ M G O i , P M G O i , P U s e r i
In a state of equilibrium, no participant can increase their payoff by changing their own pricing strategy or energy use plan. For proof of the existence and uniqueness of the equilibrium solution, refer to Ref. [36].
The Stackelberg problem described above is essentially a bi-level optimization problem. According to linear optimization theory, the KKT conditions can be used to convert the lower-level optimization model into constraints for the upper-level problem. This transformation allows the model to be solved as a single-level mixed-integer linear program. For a detailed derivation, see Appendix A.

3.3.2. Nash Bargaining Equivalence Transformation

To study collaborative operations within MGs-SESO alliances, it is crucial to consider not only the gains for individual stakeholders but also the fairness and reasonableness of benefit distribution. As a key branch of cooperative game theory, Nash bargaining theory is suitable for describing cooperative interactions among multiple participants, with a focus on collective rationality and social optimization. According to the definition of the standard Nash bargaining problem, the cooperative operational model for the MGs-SESO alliance in this study is as follows.
max   ( I S E S O I S E S O , 0 ) i = 1 N ( O M G O i , 0 O M G O i ) s . t .   I S E S O I S E S O , 0 O M G O i , 0 O M G O i E q s .   ( 1 ) ( 17 ) , ( 25 ) , ( A 1 ) ( A 4 )
where I S E S O , 0 and O M G O i , 0 denote the negotiation breakdown points for SESO and M G O i , respectively. This study assumes the scenario where microgrids operate independently as the negotiation breakdown point, where SESO’s profit becomes zero. I S E S O I S E S O , 0 and O M G O i , 0 O M G O i represent the increase in benefits for each party after cooperative operation.
The equation includes the product of energy quantity and energy price, constituting a non-convex and nonlinear optimization problem, which requires transformation for solvability. It can be transformed into two subproblems: SP1 (Equation (31)), which addresses social benefit maximization, and SP2 (Equation (32)), which focuses on transaction payment negotiation [37].
max   ( R S E S O m a r k e t C S E S O o m ) + i = 1 N R M G O i C M G O i o m C M G O i n e t w o r k C M G O i r i s k s . t .   E q s . ( 1 ) ( 5 ) , ( 7 ) ( 17 ) , ( 25 ) , ( A 1 ) ( A 4 )
where C M G O i r i s k = sup ( 1 ω i ) E F y i , ξ ˜ i + ω i C V a R F y i , ξ ˜ i
max ln ( R S E S O t r a d i n g + R S E S O m a r k e t , C S E S O o m , I S E S O , 0 ) + i = 1 N ln O M G O i , 0 + R M G O i C M G O i o m , C M G O i t r a d i n g C M G O i n e t w o r k , C M G O i r i s k , s . t .   R S E S O t r a d i n g + R S E S O m a r k e t , C S E S O o m , I S E S O , 0 O M G O i , 0 R M G O i + C M G O i o m , + C M G O i t r a d i n g + C M G O i n e t w o r k , + C M G O i r i s k , E q . ( 6 )
where variables with the superscript “*” represent the optimal solution obtained from problem SP1.

3.3.3. Adaptive ADMM ALGORITHM

The adaptive ADMM algorithm demonstrates strong convergence for large-scale variable optimization problems while maintaining information privacy among participating entities. Hence, for the Nash bargaining model between MGs-SESO alliances, the adaptive ADMM algorithm can be used to sequentially solve SP1 and SP2.
Using SP1 as an example, the detailed solution steps are outlined below.
Given that Equation (31) contains coupling variables related to energy transactions among entities, auxiliary variables are introduced to decouple them for efficient problem-solving.
P i , t b = P ¯ i , t b P i , t s = P ¯ i , t s V i , t b = V ¯ i , t b
where P i , t b , P i , t s , V i , t b represent the expected electricity power and hydrogen volume that M G O i expects to trade with the SESO. P ¯ i , t b , P ¯ i , t s and V ¯ i , t b are the amount that the SESO expects to trade with M G O i .
Using the ADMM-based optimization framework, the distributed optimization model for stakeholders concerning SP1 is shown in Equations (34) and (35).
min   L S E S O 1 = C S E S O o m R S E S O m a r k e t + i = 1 N t = 1 T r i , t b , s e s o P ¯ i , t b P i , t b + i = 1 N s i b 2 t = 1 T P ¯ i , t b P i , t b 2 2 + i = 1 N t = 1 T r i , t s , s e s o P ¯ i , t s P i , t s + i = 1 N s i s 2 t = 1 T P ¯ i , t s P i , t s 2 2 + i = 1 N t = 1 T r i , t h , s e s o V ¯ i , t b V i , t b + i = 1 N s i h 2 t = 1 T V ¯ i , t b V i , t b 2 2 s . t .   E q s .   ( 1 ) ( 5 )
min   L M G O i 1 = C M G O i o m + C M G O i n e t w o r k + C M G O i r i s k R M G O i + t = 1 T r i , t b , m g P i , t b P ¯ i , t b + s i b 2 t = 1 T P i , t b P ¯ i , t b 2 2 + t = 1 T r i , t s , m g P i , t s P ¯ i , t s + s i s 2 t = 1 T P i , t s P ¯ i , t s 2 2 + t = 1 T r i , t h , m g V i , t b V ¯ i , t b + s i h 2 t = 1 T V i , t b V ¯ i , t b 2 2   s . t .   E q s . ( 7 ) ( 17 ) , ( 25 ) , ( A 1 ) ( A 4 )
where L S E S O 1 and L M G O i 1 represents the augmented Lagrangian function for SESO and M G O i under the problem SP1. r i , t b , s e s o / r i , t s , s e s o and r i , t b , m g / r i , t s , m g are the Lagrange multipliers for the electricity purchase/sales of SESO and M G O i , respectively. r i , t h , s e s o and r i , t h , m g are the Lagrange multiplier for the hydrogen purchase. s i b , s i s and s i h are the respective penalty factors.
The variable coupling in Equation (32) stems from energy trading prices among entities, and it is also addressed by introducing a shared variable for decoupling. Its distributed optimization model is similar to that of SP1, so it will not be discussed further. For details on variable update formulas and convergence conditions in SP1 and SP2, refer to ref. [28]. The specific solution process for the multi-agent hybrid game distributional robust optimization model in the MGs-SESO system is outlined in Figure 3.
Although the original Nash bargaining problem involves non-convex product terms, it is transformed into two equivalent convex subproblems (Social Welfare Maximization and Payment Negotiation) via logarithmic transformation and variable substitution. Furthermore, the inner Stackelberg game is linearized into an MILP model using KKT conditions. Since the resulting subproblems solved within the ADMM framework are convex (with fixed integer variables in the inner loop), the two-block ADMM algorithm is theoretically guaranteed to converge to a Pareto-optimal solution, provided the penalty factor is sufficiently large. Moreover, the Nash bargaining solution maximizes the product of individual benefit improvements over disagreement points. This property ensures Pareto optimality and proportional fairness, meaning that each participant receives a share of the cooperative surplus proportional to its contribution. Therefore, the revenue distribution is not arbitrarily assigned but derived from a well-defined cooperative game-theoretic principle.
The computational burden of the proposed framework mainly arises from solving the inner Stackelberg optimization problems for each MGO and the outer Nash bargaining problem via ADMM iterations. After reformulation using KKT conditions and McCormick linearization, each MGO’s problem becomes a convex optimization problem that can be solved independently. Therefore, the computational complexity grows approximately linearly with the number of microgrids, since these subproblems can be solved in parallel. The outer Nash bargaining layer is handled using ADMM, whose convergence for convex problems with linear coupling constraints is well established. The iterative updates only involve the exchange of trading quantities and multipliers between SESO and MGOs, which results in low communication overhead. As the system scale increases, the proposed framework remains computationally tractable due to its decomposable structure and parallel solvability, making it suitable for larger microgrid clusters.

4. Case Study

4.1. Parameter Setting

This section verifies the feasibility and effectiveness of the proposed energy trading framework and optimization model through case study simulations. A system comprising three microgrids and one SESO is selected for analysis. The predicted electricity and heat demand curves, as well as renewable energy output curves for each microgrid, are shown in Figure 4 [11]. The WT and PV output prediction error data are sourced from https://www.tennet.eu/ (accessed on 7 June 2025). The energy conversion equipment parameters for each microgrid and the SESO are detailed in Appendix B. The external natural gas price is 3 yuan/m3, while the retail price for hydrogen is 1.78 yuan/m3. The time-of-use (TOU) electricity prices are listed in Table 2 [12]. The minimum electricity price set by M G O i for users is 0.35 yuan/kWh, while the upper and lower limits for heat prices are 0.80 yuan/kWh and 0.15 yuan/kWh, respectively. Transferable electric loads and curtailable electric/heat loads within each microgrid account for 15% and 10% of the total loads, respectively. The users’ energy preference coefficients are set based on Ref. [33].
The simulation operates on a 24 h cycle with 1 h scheduling step. The tail risk weight coefficient is 50%, with a confidence level of 95%. The convergence threshold for the ADMM algorithm is set to 10−4.

4.2. Optimization Result Analysis

The hybrid game process of the MGs-SESO system was simulated using the solution method presented in Section 3.3. The primal and dual residuals decrease steadily and satisfy the convergence tolerance at the 109th iteration. The equilibrium operational strategy derived from the simulation yielded revenues of 1456.28 yuan for SESO, and 29,426.68 yuan, 21,501.58 yuan, and 18,547.54 yuan for the respective MGs. Additionally, consumer surplus within different microgrids reached 15,004.80 yuan, 13,357.56 yuan, and 11,474.92 yuan, respectively.

4.2.1. Analysis of SESO Operation Results

The energy trading outcomes between SESO and MGs are shown in Figure 5. A positive value indicates that SESO is selling electricity or hydrogen to the MGs, while a negative value denotes SESO purchasing electricity from the MGs or the main grid. Similarly, a positive energy trading price reflects the sale price for electricity to the MGs, whereas a negative price indicates the purchase price from the MGs. According to the data, SESO’s purchases from the main grid mainly occur between 00:00 and 09:00 and 23:00–24:00. This is primarily because the main grid’s electricity price is lower during these periods, and the MGs’ internal demand is also reduced, allowing renewable energy sources and internal equipment outputs to mostly meet their demand. Thus, only a small amount of electricity needs to be purchased from SESO. The purchased electricity is partially stored in the ES system, with the remainder used to produce hydrogen via the electrolyzer. A small portion of this hydrogen is sold to the energy market, while the majority is stored in the HST for later use. Figure 6 illustrates the storage status changes in ES and HST. During the 00:00–08:00 period, HST storage levels steadily increase. From 09:00 onward, some of the hydrogen from HST is converted to electricity via fuel cells for MGs, with the remaining portion directly sold to the MGs. This aligns with the trend in Figure 5 showing the hydrogen energy trading between SESO and the MGs. Notably, MG1 has the highest hydrogen purchase from SESO, totaling 520.35 m3. This is mainly due to MG1’s greater heat load demand compared to other MGs, leading to higher output from its hydrogen-mixed CHP units and consequently requiring more hydrogen.
Between 10:00 and 22:00, when wholesale electricity prices are generally high, SESO purchases surplus energy from MGs at rates lower than TOU prices. This typically occurs between 15:00 and 17:00 because MGs still have substantial PV output while demand is relatively low, allowing them to profit by selling excess energy. As shown in Figure 6, SESO stores this energy in its ES system for later use. During peak demand time, such as 12:00–14:00 and 18:00–22:00, the MGs often face energy shortages, and SESO releases stored energy for sale to them. An analysis of SESO’s pricing strategy reveals that it sets transaction prices within a range defined by TOU prices and feed-in tariffs. The pricing trends tend to align with fluctuations in shared energy transactions, offering a more favorable rate compared to the grid. This approach helps smooth out load fluctuations for MGs, promotes efficient energy use, and enhances the overall operational benefits for both parties.
Based on the SESO’s dispatch patterns observed above, we can identify that hydrogen storage becomes economically preferable under conditions of high renewable energy penetration and significant electricity price fluctuations. When surplus renewable electricity frequently occurs during low-price periods, converting electricity into hydrogen through P2G allows long-term energy storage without the capacity limitations of electrical storage. This stored hydrogen can then be converted back into electricity or used for heat supply during high-price or high-demand periods, reducing peak electricity purchasing costs. In addition, hydrogen blending in CHP and GB units increases the utilization value of stored hydrogen by directly contributing to electricity and heat production. Therefore, hydrogen storage is particularly advantageous when renewable curtailment risk is high, electricity price volatility is significant, and multi-energy coupling is present.

4.2.2. Analysis of Microgrids’ Operation Results

To further analyze the shared energy storage operation in cooperative systems, Figure 7 displays the day-ahead electricity and heat scheduling results for MGs. Positive values indicate energy production or purchase, while negative values signify energy consumption. Generally, the MGs are powered primarily by renewable energy units and CHP units, with energy imbalances addressed through transactions with the SESO or the upstream grid. For example, in MG1, during the 0:00–10:00 and 23:00–24:00 periods, market electricity prices are lower than the CHP operational costs, leading the MGO1 to source energy from the upstream grid for economic efficiency, with CHP covering any shortfalls. During the 18:00–22:00 period, when the system’s power demand is high and market prices are elevated, SESO supplied additional energy through discharge transactions. Between 11:00 and 17:00, renewable energy is plentiful, allowing MG1 to sell excess energy to SESO for extra revenue.
Regarding heat demand, the system primarily uses CHPs and EBs to meet the load. Due to the cogeneration characteristic of CHP units, waste heat recovery boilers could cover a significant proportion of the heat demand. From the perspective of electricity balance, EBs are primarily used during periods of low market prices (0:00–7:00) or when renewable energy is abundant (12:00–16:00). This occurred because these periods have high electricity production, and after comparing electricity-to-heat prices and the costs of CHPs and GBs, the system opts to prioritize EBs for heat generation. During the heat demand peak from 9:00 to 14:00, any shortfall is supplemented by GBs.
In real-time operations, inaccuracies in renewable energy output forecasts can lead to fluctuations in power generation, which in turn disrupts the supply–demand balance in the system. Figure 8 illustrates the real-time rescheduling adjustment coefficients for various devices in MGs. As described in Section 3.2, these coefficients indicate the extent to which each device helps mitigate renewable energy output fluctuations in real time. For instance, at 8:00 in MG1, y 1 C H P = 0.75 , y 1 g i r d = 0.42 , y 1 E B = 0.17 . This implies that when renewable energy output varies ξ ˜ 1 , system balance can be achieved by modifying CHP generation y 1 C H P ξ ˜ 1 , upper grid electricity purchases y 1 g i r d ξ ˜ 1 , and EB electricity consumption y 1 E B ξ ˜ 1 . Examining MG1’s adjustment strategy in the second stage reveals that between 1:00 and 7:00 and 23:00–24:00, the affine coefficient for purchased electricity from grid y 1 g i r d is −1, suggesting that solely adjusting electricity purchases can completely offset the fluctuations. Between 8:00 and 22:00, the affine coefficient for electricity purchases decreases, while the CHP unit starts contributing to system balance. This shift is because, during nighttime, MG1 relies heavily on electricity purchases from the upper grid to maintain balance. As system load increases, the proportion of CHP units put into operation increases, and its role in stabilizing fluctuations grows. Due to the electro-thermal coupling impact of the CHP and EB units, their real-time adjustments also indirectly influence the thermal balance. Further analysis reveals that the rescheduling periods for the GB unit, which supports the thermal system, align with those of the CHP and EB units. The distribution of adjustment coefficients in Figure 8 offers a clearer visualization of how each device mitigates system output fluctuations, catering to various potential scenarios to ensure economic and robust system operation.

4.2.3. Analysis of Equilibrium Outcomes in MGO–User Stackelberg Game Transactions

Figure 9 and Figure 10 illustrate the equilibrium outcomes of the Stackelberg game between MGOs and their internal users. The results suggest that the game-based interaction leads to significantly lower energy sale prices for users compared to TOU prices or fixed heat prices. This indicates that the leader–follower interaction helps optimize energy prices in a stable manner. Analysis reveals that MGOs’ energy sale prices tend to align with the fluctuations in corresponding user demand. This is largely because during peak load times, users are more sensitive to price changes and can adjust their load demand based on MGOs’ pricing signals. Simultaneously, MGOs can strategically manage equipment output and reduce electricity purchases from the main grid. This ongoing interaction results in more rational pricing.
In Figure 9, the price stimulus encourages users to smooth their electric load curves to minimize energy costs. For example, MG1’s initial load curve shows peaks between 12:00 and 14:00 and 18:00–20:00, corresponding to higher electricity prices. After demand-response measures such as load shifting and reduction, these peaks are significantly reduced. The optimized MG1 electric load peak-to-valley difference dropped from 2184.62 kW to 1341.33 kW, an improvement of 38.60%. Furthermore, Figure 10 shows a slight reduction in heat loads among microgrid users, primarily in time periods with high initial demand. For MG1 users, the largest heat load reduction occurs from 7:00 to 15:00, likely to maintain user comfort. With these adjustments, MG1’s consumer surplus increased from 4294.25 yuan to 15,004.80 yuan. Meanwhile, energy costs dropped from 53,429.79 yuan to 45,423.59 yuan, while the utility function value rose from 57,724.04 yuan to 60,428.39 yuan. These outcomes demonstrate the effectiveness of the game-based interaction method in enhancing energy use efficiency and cost-effectiveness.

4.3. Result Comparison and Discussion

4.3.1. Scenario Comparison

To validate the effectiveness of the proposed approach, four scenarios are set up for comparative analysis, as shown in Table 3. The specific settings for each scenario are as follows.
Scenario 1: This scenario does not consider the Stackelberg game between MGOs and internal users. The MGO uses a fixed energy price for transactions with internal users, and the uncertainty in renewable energy generation is also ignored. Optimization of the energy cooperation and sharing strategy between MGOs and the SESO is carried out using the deterministic objective in the first stage.
Scenario 2: Building on Scenario 1, this scenario includes the Stackelberg game between the MGOs and internal users, but it still disregards the uncertainty in renewable energy output.
Scenario 3: This scenario, based on Scenario 2, incorporates the uncertainty stemming from renewable energy generation, which is the proposed approach in this paper.
Scenario 4: This scenario operates without SESO integration, with each MG running independently.
The optimization results for various scenarios are presented in Table 4. Analyzing the outcomes from Scenarios 1 and 2, we can see that incorporating the Stackelberg game led to a 9.86% increase in the coalition’s revenue. And users’ consumer surplus increased from −6493.30 yuan, 4084.87 yuan, and 1695.94 yuan to 15,022.96 yuan, 13,330.50 yuan, and 11,476.64 yuan, respectively. Figure 11 illustrates the distribution of users’ energy costs and satisfaction across the two scenarios. In Scenario 1, the MGOs did not engage in strategic interactions with internal users, and they chose to align their pricing strategy with the upper energy networks’ prices. It leads to higher energy costs for users due to a lack of information exchange about users’ behavior and energy prices. Compared to Scenario 1, users’ energy costs in Scenario 2 were reduced by 27.84%, 26.62%, and 26.88%, with minimal change in users’ satisfaction, indicating that information exchange between the MGOs and users fosters more optimal energy pricing and cost savings without compromising user satisfaction. This exchange of information also makes energy flow within the microgrids more flexible. For instance, in Figure 12, which shows energy transactions between MG3 and the SESO, Scenario 2 demonstrates that MG3 increased electricity sales to SESO during 11:00, 14:00–16:00, while reducing purchases during 12:00–13:00. This change is attributed to improved peak load management in response to MGO’s pricing strategy, which contributes to enhanced energy support and economic benefits for the microgrids.
Secondly, Scenario 3 further explores the impact of internal renewable energy uncertainty on the optimization results. Compared to the deterministic outcomes, the uncertainty in Scenario 3 reduced coalition revenue by 1429.20 yuan. Figure 12 shows a noticeable decline in energy transactions between MG3 and SESO, with MG3 reducing electricity purchases by 109.70 kWh and sales by 176.26 kWh during the critical 11:00–16:00 period. To ensure system stability, MGOs rely more on internal flexible resources, reducing energy sharing with SESO. Consequently, revenue decreases by 611.64 yuan, 4038.17 yuan, 3264.80 yuan, and 3178.39 yuan for various stakeholders.
Lastly, the comparison between Scenarios 3 and 4 reveals that the involvement of SESO increased microgrids’ revenues by 2210.65 yuan, 1873.19 yuan, and 1153.34 yuan, respectively. In Scenario 4, microgrids operate independently, relying solely on the superior energy network, which limits energy sharing and reduces efficiency. Compared to Scenario 4, Scenario 3 witnesses lower electricity purchases from the upper grid by 6205.53 kWh, 2361.74 kWh, and 6089.57 kWh for each of the MGs. This resulted in total energy interaction cost savings with the upper-level energy networks of 1918.45 yuan, 1560.84 yuan, and 1448.62 yuan, respectively. Additionally, the coalition formed with SESO resulted in an overall benefit increase of 6447.23 yuan. Using the Nash bargaining method to redistribute cooperative gains yields similar benefits for all participants, demonstrating the fairness of the Nash approach in handling surplus distribution in cooperative scenarios.
To quantitatively evaluate the fairness achieved by the Nash bargaining mechanism, Jain’s fairness index is adopted. Considering that the participating microgrids have different capacities and baseline load profiles, comparing absolute profit would be biased by their inherent scale differences. Therefore, we calculate the index based on the profit improvement ratio g M G O i of each microgrid relative to its non-cooperative benchmark, ensuring scale invariance, defined as:
J = i = 1 N g M G O i 2 N i = 1 N g M G O i 2
The index ranges from 0 to 1, with values closer to 1 indicating a more equitable distribution of benefits. The calculated Jain’s index for the proposed method is 0.9789, demonstrating that the Nash bargaining mechanism ensures a highly fair distribution of cooperative gains, preventing any single stakeholder from monopolizing the benefits while accounting for their individual contributions.

4.3.2. Impact Analysis of Decision-Makers’ Risk Attitude

To investigate the influence of decision-makers’ risk attitudes on the alliance profitability, this section examines Scenario 3 by adjusting the tail risk coefficient ω i and the confidence level β C V a R . The results are presented in Figure 13.
The tail risk coefficient is a subjective parameter that reflects the decision-maker’s risk tolerance. A lower value ω i indicates a risk-neutral or risk-seeking attitude, aiming for maximum expected returns but with diminished capacity to mitigate losses due to the uncertainty in renewable energy output. Conversely, a higher value suggests a more conservative approach with stronger risk aversion. As seen in Figure 13, as the tail risk coefficient increases, the decision-maker becomes increasingly cautious about tail risks, leading to higher system reserve levels, thereby reducing potential losses from uncertainty. This, however, results in increased operating costs and reduced profitability.
The confidence level represents the degree of certainty that losses will not exceed a specified value V a R β C V a R . For example, a 90% confidence level indicates a 90% probability that maximum losses during economic dispatch will not exceed a set value, reflecting the decision-maker’s level of risk acceptance. It can be seen that as the confidence level increases from 70% to 95%, alliance profitability declines. The main reason is that as decision-makers become more risk-averse to the uncertainties in renewable energy output, the system involves greater reliance on flexible resources to stabilize operations. This leads to reduced energy exchange between alliances, resulting in higher operational costs and lower returns. Therefore, in practical decision-making, it is essential to balance system robustness with appropriate risk values and confidence levels to ensure a realistic operational strategy.

4.3.3. Impact Analysis of Historical Sample Data

The performance and reliability of the WDRO-CVaR model are closely related to the fuzzy set size, which is determined by the radius of the Wasserstein ball as defined in Equation (20). The radius is influenced by two parameters: the number of historical sample data and the confidence level. Figure 14 illustrates coalition payoffs under different sample sizes M and confidence levels β . The experiments indicate that when the number of historical samples decreases, the distribution of unknown uncertainties becomes broader, leading to a larger Wasserstein ball radius. This expansion of the fuzzy set results in a more conservative WDRO-CVaR model, reducing coalition payoffs. Conversely, as the number of samples increases, outliers with low probabilities are excluded, shrinking the fuzzy set, and the optimization results tend to be more deterministic, leading to higher coalition payoffs.
The confidence level β represents the probability that the true distribution is within the Wasserstein fuzzy set. As shown in the figure, higher confidence levels lead to a larger Wasserstein ball radius, expanding the fuzzy set and requiring more robust system solutions, which generally result in reduced coalition payoffs. Conversely, lower confidence levels create a smaller fuzzy set, yielding higher coalition payoffs. Therefore, decision-makers can balance the economic performance and reliability of the system by selecting an appropriate fuzzy set size based on their requirements.

5. Conclusions

To facilitate regional consumption of renewable energy power, considering the diverse regulation needs of heterogeneous microgrids, this paper proposes a novel hybrid electricity–hydrogen energy storage sharing and trading framework. In this framework, the SESO is equipped with ES and P2G system, allowing it to act as an independent entity engaging in electricity and hydrogen energy trading among microgrids. First, recognizing the complex interactions among the SESO, multiple microgrids, and internal users, a hybrid game theory framework combining Nash bargaining and Stackelberg game is constructed to model stakeholder behavior. Second, to mitigate the adverse effects of renewable energy output uncertainty, a distributionally robust optimization model with CVaR consideration is developed. Lastly, the proposed model is validated using an adaptive ADMM algorithm and KKT theory to ensure effectiveness. Based on simulation results, the main findings are as follows:
(1)
Compared to individual microgrids operating independently, enabling energy sharing via SESO results in improved resource utilization, enhancing SESO profitability and altering the cost structure of individual microgrids. This approach leads to revenue increases of 2210.65 yuan, 1873.19 yuan, and 1153.34 yuan for each of the microgrids, respectively.
(2)
The proposed hybrid game-based interaction mechanism ensures sustainable sharing. The Nash bargaining approach delineates interactions between SESO and microgrids, providing a nearly even increase in revenue for all participants and ensuring fair distribution of benefits. Simultaneously, the Stackelberg game describes the trading behavior between microgrid operators and internal users, increasing system operational flexibility. This approach results in a 9.86% increase in coalition revenue while safeguarding user utility.
(3)
By incorporating a Wasserstein distance-based probabilistic fuzzy set and quantifying tail risk in extreme scenarios using CVaR, the model addresses both probabilistic distribution uncertainty and worst-case tail risk. This methodology effectively reduces operational risks and improves system robustness. Its data-driven nature allows decision-makers to adjust risk preference and sample size parameters to make informed decisions.
Despite the demonstrated theoretical benefits, the real-world deployment of the proposed framework faces several practical challenges that merit attention: First, the iterative ADMM algorithm requires high-bandwidth, low-latency infrastructure to ensure convergence within day-ahead scheduling windows. Second, current markets lack mature frameworks for P2P hydrogen trading and shared storage, necessitating policy reforms to define asset ownership and clearing mechanisms. Third, retrofitting microgrids with hydrogen technologies involves significant capital investment and requires stringent safety standards for leakage prevention.
Future research should extend beyond renewable energy output uncertainty to consider the uncertainty in internal microgrid user loads, thereby adding complexity to the system’s internal structure. This would explore ways to ensure stable system operations amid multiple uncertainties. Additionally, this study addresses the case of multiple microgrids with a single SESO, but given current high storage costs, a single SESO scenario demands significant investment, hindering scalability. Future work will focus on a solution involving multiple SESOs, with each investing in separate shared storage facilities, collectively serving a group of microgrids.

Author Contributions

Conceptualization, J.L.; Methodology, Z.W.; Resources, Z.W.; Data curation, J.L. and Z.W.; Writing—original draft, J.L.; Writing—review & editing, J.L. All authors have read and agreed to the published version of the manuscript.

Funding

This research was funded by Optimization Pathways and Countermeasures for China’s Energy-Economy-Environment System under Heterogeneous Consumption-Investment Behaviors, grant number 24YJA630104.

Data Availability Statement

The original contributions presented in this study are included in the article. Further inquiries can be directed to the corresponding author.

Conflicts of Interest

The authors declare that they have no known competing financial interests or personal relationships that could have appeared to influence the work reported in this paper.

Nomenclature

Sets and Indices
t Index   of   time   periods ,   t 1 , 2 , , 24
i Index of microgrids
m / M Index of historical data samples/total number of historical samples
ele/hyd/heat/loadIndex of electrical energy/thermal energy/hydrogen/load
Decision variable
R / C Revenue/Cost
λ t b / λ t s Energy Price at time t for purchase/sale
P t   H t   V t   G t Electrical power/Thermal power/Hydrogen volume/Natural gas volume at time t
V H S T , t c h / V H S T , t d i s Quantities of hydrogen charged into and discharged from HST.
P E S , t c h / P E S , t d i s ES charging and discharging amounts at time t
S H S T , t HST state of charge at time t
κ H S T , t / κ i , t Binary indicator, means hydrogen charging and discharging status/MGO power trading status with SESO
v i e l e / v i h e a t / u i e l e / u i h e a t Preference coefficients for electrical and thermal energy consumption
P i , t l o a d , 0 / P i , t l o a d , t s l / P i , t l o a d , i l Fixed/transferable/reducible loads
Parameters
η Energy Efficiency Factor of Equipment
α H 2 / α g a s Calorific value of hydrogen/natural gas
δ Unit operating and maintenance cost of energy equipment
WDRO-CVaR model
Ξ Support set
ξ ˜ t / ξ ^ m t , m M Forecasting error/sample value of renewable energy output at time t
Θ ξ ^ m t Dirac measure
t / t ^ Actual distribution/empirical distribution
Π Joint distribution
y i , t Participation factor
t Fuzzy set of the actual distribution of forecast errors at time t .
γ M , β Wasserstein radius
ω i 0 , 1 Tail   risk   coefficient   in MG i
λ k c , μ m k c , ϕ k c , ι m k c Introduced auxiliary variables used in WDRO-CVaR model

Appendix A. KKT Transformation of Stackelberg Model

First, convert the user’s objective function into the augmented Lagrangian function as shown in Equation (A1), where u i , t 1 , u i , t 2 , u i , t 3 , u i , t 4 , u i , t 5 , u i , t 6 represents the dual variable for inequality constraints, and u i 7 represents the dual variable for equality constraints. The KKT equilibrium conditions are given in Equation (A2), with the complementary slackness condition shown in Equation (A3). x y means that at most one of the variables between x and y can be strictly greater than zero.
L = t = 1 T v i e l e P i , t l o a d + u i e l e 2 P i , t l o a d 2 v i h e a t H i , t l o a d + u i h e a t 2 H i , t l o a d 2 + λ i , t e l e , u s e r P i , t l o a d + λ i , t h e a t , u s e r H i , t l o a d + u i , t 1 P i , t , max l o a d , t s l P i , t l o a d , t s l + u i , t 2 P i , t l o a d , t s l P i , t , max l o a d , t s l + u i , t 3 P i , t l o a d , i l + u i , t 4 P i , t l o a d , i l P i , t , max l o a d , i l + u i , t 5 H i , t l o a d , i l + u i , t 6 H i , t l o a d , i l H i , t , max l o a d , i l + u i 7 t = 1 T P i , t l o a d , t s l Δ t
𝜕 L 𝜕 P i , t l o a d , t s l = 0 , 𝜕 L 𝜕 P i , t l o a d , i l = 0 , 𝜕 L 𝜕 H i , t l o a d , i l = 0
0 P i , t l o a d , t s l + P i , t , max l o a d , t s l u i , t 1 0 0 P i , t , max l o a d , t s l P i , t l o a d , t s l u i , t 2 0 0 P i , t l o a d , i l u i , t 3 0 0 P i , t , max l o a d , i l P i , t l o a d , i l u i , t 4 0 0 H i , t l o a d , i l u i , t 5 0 0 H i , t , max l o a d , i l H i , t l o a d , i l u i , t 6 0
Nonlinear constraints in Equation (A3) can be linearized using the Big-M method. For instance, the transformation of 0 P i , t l o a d , t s l + P i , t , max l o a d , t s l u i , t 1 0 can be conducted as follows.
0 P i , t l o a d , t s l + P i , t , max l o a d , t s l M Z i , t 1 0 u i , t 1 M 1 Z i , t 1
where M is a sufficiently large integer, and Z i , t 1 is a binary variable. Similarly, the same transformations are applied to other constraints.
By applying the KKT conditions, the follower’s model can be equivalently transformed, enabling the internal Stackelberg game to be converted into a single-level model. The objective function is given in Equation (23), and in addition to the constraints from Equation (8)–(13) and Equation (25), the constraints from Equation (15)–(17) and Equation (A2)–(A4) must also be considered. Since the transformed objective function is nonlinear, this study employs McCormick Envelopes to relax the original bilinear non-convex problem, achieving an equivalent transformation. This allows for solving the problem using MATLAB R2023b + YALMIP in conjunction with the GUROBI solver (version 11.0.3), sourced from Gurobi Optimization, LLC, Houston, TX, USA.

Appendix B. Related Parameters

Table A1. Related parameters in MGs.
Table A1. Related parameters in MGs.
ParameterValue (kW)ParameterValueParameterValue
(yuan/kWh)
MG1MG2MG3
P i , min C H P / P i , max C H P 0/30000/20000/3000 η G T 0.40 δ C H P 0.59
H i , min G B / H i , max G B 0/30000/10000/2500 η W H B 0.83 δ G B 0.20
P i , min E B / P i , max E B 0/30000/10000/1500 η H E 0.90 δ E B 0.20
P i , t , max g r i d 600 η G B 0.53 δ W T 0.10
P i , t max (kW)600 η E B 0.90 δ P V 0.10
Table A2. Related parameters in SESO.
Table A2. Related parameters in SESO.
ParameterValueParameterValueParameterValue
P E L , min / P E L , max (kW)0/1000 η E L 0.60 δ E L (yuan/m3)0.45
P F C , min / P F C , max (kW)0/600 η F C 0.60 δ F C (yuan/kWh)0.10
S H S T , min / S H S T , max (m3)80/720 η H S T c h / η H S T d i s 0.95/0.95 δ h s t (yuan/m3)0.05
S E S , min / S E S , max (kWh)100/2000 η E S c h / η E S d i s 0.97/0.97 δ e s (yuan/kWh)0.02
V H S T , max c h / V H S T , max d i s (m3/h)150/150 P E S , max c h / P E S , max d i s (kW)300/300

References

  1. Ahrari, M.; Shirini, K.; Gharehveran, S.S.; Ahsaee, M.G.; Haidari, S.; Anvari, P. A security-constrained robust optimization for energy management of active distribution networks with presence of energy storage and demand flexibility. J. Energy Storage 2024, 84, 111024. [Google Scholar] [CrossRef]
  2. Cao, W.; Xiao, J.-W.; Cui, S.-C.; Liu, X.-K. An efficient and economical storage and energy sharing model for multiple multi-energy microgrids. Energy 2022, 244, 123124. [Google Scholar] [CrossRef]
  3. Sun, B.; Jing, R.; Zeng, Y.; Wei, W.; Jin, X.; Huang, B. Three-side coordinated dispatching method for intelligent distribution network considering dynamic capacity division of shared energy storage system. J. Energy Storage 2024, 81, 110406. [Google Scholar] [CrossRef]
  4. Lai, S.; Qiu, J.; Tao, Y. Individualized Pricing of Energy Storage Sharing Based on Discount Sensitivity. IEEE Trans. Ind. Inform. 2022, 18, 4642–4653. [Google Scholar] [CrossRef]
  5. Zhang, T.; Qiu, W.; Zhang, Z.; Lin, Z.; Ding, Y.; Wang, Y.; Wang, L.; Yang, L. Optimal bidding strategy and profit allocation method for shared energy storage-assisted VPP in joint energy and regulation markets. Appl. Energy 2023, 329, 120158. [Google Scholar] [CrossRef]
  6. Qiu, R.; Zhang, H.; Wang, G.; Liang, Y.; Yan, J. Green hydrogen-based energy storage service via power-to-gas technologies integrated with multi-energy microgrid. Appl. Energy 2023, 350, 121716. [Google Scholar] [CrossRef]
  7. Steriotis, K.; Tsaousoglou, G.; Efthymiopoulos, N.; Makris, P.; Varvarigos, E. Real-time pricing in environments with shared energy storage systems. Energy Effic. 2019, 12, 1085–1104. [Google Scholar] [CrossRef]
  8. Bian, Y.; Xie, L.; Ye, J.; Ma, L. A new shared energy storage business model for data center clusters considering energy storage degradation. Renew. Energy 2024, 225, 120283. [Google Scholar] [CrossRef]
  9. Liu, L.; Yao, X.; Qi, X.; Han, Y. Low-carbon economy configuration strategy of electro-thermal hybrid shared energy storage in multiple multi-energy microgrids considering power to gas and carbon capture system. J. Clean. Prod. 2023, 428, 139366. [Google Scholar] [CrossRef]
  10. Deng, H.; Wang, J.; Shao, Y.; Zhou, Y.; Cao, Y.; Zhang, X.; Li, W. Optimization of configurations and scheduling of shared hybrid electric-hydrogen energy storages supporting to multi-microgrid system. J. Energy Storage 2023, 74, 109420. [Google Scholar] [CrossRef]
  11. Li, Q.; Xiao, X.; Pu, Y.; Luo, S.; Liu, H.; Chen, W. Hierarchical optimal scheduling method for regional integrated energy systems considering electricity-hydrogen shared energy. Appl. Energy 2023, 349, 121670. [Google Scholar] [CrossRef]
  12. Shi, M.; Huang, Y.; Lin, H. Research on power to hydrogen optimization and profit distribution of microgrid cluster considering shared hydrogen storage. Energy 2023, 264, 126113. [Google Scholar] [CrossRef]
  13. Yan, D.; Chen, Y. Review on Business Model and Pricing Mechanism for Shared Energy Storage. Autom. Electr. Power Syst. 2022, 46, 178–191. [Google Scholar] [CrossRef]
  14. Shuai, X.; Ma, Z.; Wang, X.; Guo, H.; Zhang, H. Optimal Operation of Shared Energy Storage and Integrated Energy Microgrid Based on Leader-follower Game Theory. Power Syst. Technol. 2023, 47, 679–690. [Google Scholar] [CrossRef]
  15. Fleischhacker, A.; Auer, H.; Lettner, G.; Botterud, A. Sharing Solar PV and Energy Storage in Apartment Buildings: Resource Allocation and Pricing. IEEE Trans. Smart Grid 2019, 10, 3963–3973. [Google Scholar] [CrossRef]
  16. Sun, C.; Zheng, T.; Chen, L.; Xie, Y.; Gao, B.; Mei, S. Energy Storage Sharing Mechanism Based on Combinatorial Double Auction. Power Syst. Technol. 2020, 44, 1732–1739. [Google Scholar] [CrossRef]
  17. Fan, S.; Ai, Q.; Piao, L. Bargaining-based cooperative energy trading for distribution company and demand response. Appl. Energy 2018, 226, 469–482. [Google Scholar] [CrossRef]
  18. Zhang, T.; Chen, C.; Ma, L.; Chen, T.; Wei, Y.; Lin, Z.; Srinivasan, D. Multi-Step Clustering and Generalized Nash Bargaining-Based Planning Strategy of Community-Shared Energy Storage for Large-Scale Prosumers. IEEE Trans. Sustain. Energy 2024, 15, 1013–1027. [Google Scholar] [CrossRef]
  19. Dai, R.; Charkhgard, H.; Chen, Y.; Kuang, Y. Balancing Benefit Distribution for Energy Storage Sharing based on Nash Bargaining Solution. In Proceedings of the 2019 IEEE Power & Energy Society General Meeting (PESGM), 4–8 August 2019; IEEE: Piscataway, NJ, USA, 2019; pp. 1–5. [Google Scholar]
  20. Doostinia, M.; Beheshti, M.T.H.; Alavi, S.A.; Guerrero, J.M. Distributed event-triggered average consensus control strategy with fractional-order local controllers for DC microgrids. Electr. Power Syst. Res. 2022, 207, 107791. [Google Scholar] [CrossRef]
  21. Doostinia, M.; Beheshti, M.T.H.; Alavi, S.A.; Guerrero, J.M. Distributed control strategy for DC microgrids based on average consensus and fractional-order local controllers. IET Smart Grid 2021, 4, 549–560. [Google Scholar] [CrossRef]
  22. Vijayalakshmi, K.; Vijayakumar, K.; Nandhakumar, K. Prediction of virtual energy storage capacity of the air-conditioner using a stochastic gradient descent based artificial neural network. Electr. Power Syst. Res. 2022, 208, 107879. [Google Scholar] [CrossRef]
  23. Nasab, M.A.; Zand, M.; Padmanaban, S.; Bhaskar, M.S.; Guerrero, J.M. An efficient, robust optimization model for the unit commitment considering renewable uncertainty and pumped-storage hydropower. Comput. Electr. Eng. 2022, 100, 107846. [Google Scholar] [CrossRef]
  24. Zhou, K.; Fei, Z.; Hu, R. Hybrid robust decentralized optimization of emission-aware multi-energy microgrids considering multiple uncertainties. Energy 2023, 265, 126405. [Google Scholar] [CrossRef]
  25. Fan, W.; Ju, L.; Tan, Z.; Li, X.; Zhang, A.; Li, X.; Wang, Y. Two-stage distributionally robust optimization model of integrated energy system group considering energy sharing and carbon transfer. Appl. Energy 2023, 331, 120426. [Google Scholar] [CrossRef]
  26. Zhai, J.; Wang, S.; Guo, L.; Jiang, Y.; Kang, Z.; Jones, C.N. Data-driven distributionally robust joint chance-constrained energy management for multi-energy microgrid. Appl. Energy 2022, 326, 119939. [Google Scholar] [CrossRef]
  27. Wang, Q.; Zhang, X.; Yi, C.; Li, Z.; Xu, D. A Novel Shared Energy Storage Planning Method Considering the Correlation of Renewable Uncertainties on the Supply Side. IEEE Trans. Sustain. Energy 2022, 13, 2051–2063. [Google Scholar] [CrossRef]
  28. Li, Y.; Hu, W.; Zhang, F.; Li, Y. Collaborative operational model for shared hydrogen energy storage and park cluster: A multiple values assessment. J. Energy Storage 2024, 82, 110507. [Google Scholar] [CrossRef]
  29. Fan, W.; Tan, Z.; Li, F.; Zhang, A.; Ju, L.; Wang, Y.; De, G. A two-stage optimal scheduling model of integrated energy system based on CVaR theory implementing integrated demand response. Energy 2023, 263, 125783. [Google Scholar] [CrossRef]
  30. Liu, H.; Qiu, J.; Zhao, J. A data-driven scheduling model of virtual power plant using Wasserstein distributionally robust optimization. Int. J. Electr. Power Energy Syst. 2022, 137, 107801. [Google Scholar] [CrossRef]
  31. Zilong, Z.; Peiqiang, L.; Yong, L.; Junjie, Z.; Yijia, C. Low-carbon Distributionally Two-stage Robust Optimization Considering Conditional Value-at-Risk for Hybrid AC/DC Grids. High Volt. Eng. 2024, 50, 157–168. [Google Scholar] [CrossRef]
  32. Wang, K.; Liang, Y.; Jia, R.; Wang, X. Two-stage Optimal Scheduling of Nash Negotiation-based Integrated Energy Multi-microgrids With Hydrogen-doped Gas Under Uncertain Environment. Power Syst. Technol. 2023, 47, 3141–3159. [Google Scholar] [CrossRef]
  33. Wang, H.; Zhang, C.; Li, K.; Liu, S.; Li, S.; Wang, Y. Distributed coordinative transaction of a community integrated energy system based on a tri-level game model. Appl. Energy 2021, 295, 116972. [Google Scholar] [CrossRef]
  34. Wang, Y.; Song, M.; Jia, M.; Li, B.; Fei, H.; Zhang, Y.; Wang, X. Multi-objective distributionally robust optimization for hydrogen-involved total renewable energy CCHP planning under source-load uncertainties. Appl. Energy 2023, 342, 121212. [Google Scholar] [CrossRef]
  35. Ordoudis, C.; Nguyen, V.A.; Kuhn, D.; Pinson, P. Energy and reserve dispatch with distributionally robust joint chance constraints. Oper. Res. Lett. 2021, 49, 291–299. [Google Scholar] [CrossRef]
  36. Zhang, M.; Yang, J.; Yu, P.; Tinajero, G.D.A.; Guan, Y.; Yan, Q.; Zhang, X.; Guo, H. Dual-Stackelberg game-based trading in community integrated energy system considering uncertain demand response and carbon trading. Sustain. Cities Soc. 2024, 101, 105088. [Google Scholar] [CrossRef]
  37. Cai, P.; Mi, Y.; Xing, H.; Li, D.; Li, H.; Wang, P. Hierarchical coordinated energy management strategy for electricity-hydrogen integrated charging stations based on IGDT and hybrid game. Electr. Power Syst. Res. 2023, 223, 109527. [Google Scholar] [CrossRef]
Figure 1. MGs-SESO system structure.
Figure 1. MGs-SESO system structure.
Energies 19 00903 g001
Figure 2. System hybrid game framework.
Figure 2. System hybrid game framework.
Energies 19 00903 g002
Figure 3. Solution flowchart of the proposed algorithm.
Figure 3. Solution flowchart of the proposed algorithm.
Energies 19 00903 g003
Figure 4. Energy demand and forecasted output of MGs.
Figure 4. Energy demand and forecasted output of MGs.
Energies 19 00903 g004
Figure 5. Optimization results of MGs-SESO energy trading volume and price.
Figure 5. Optimization results of MGs-SESO energy trading volume and price.
Energies 19 00903 g005
Figure 6. State of charge for HST and ES.
Figure 6. State of charge for HST and ES.
Energies 19 00903 g006
Figure 7. Energy balance results in MGs.
Figure 7. Energy balance results in MGs.
Energies 19 00903 g007
Figure 8. Real-time rescheduling adjustment results in MGs.
Figure 8. Real-time rescheduling adjustment results in MGs.
Energies 19 00903 g008
Figure 9. Electricity load pricing and IDR results.
Figure 9. Electricity load pricing and IDR results.
Energies 19 00903 g009
Figure 10. Heating load pricing and IDR results.
Figure 10. Heating load pricing and IDR results.
Energies 19 00903 g010
Figure 11. Consumer surplus in Scenarios 1 and 2.
Figure 11. Consumer surplus in Scenarios 1 and 2.
Energies 19 00903 g011
Figure 12. Shared electricity in different scenarios.
Figure 12. Shared electricity in different scenarios.
Energies 19 00903 g012
Figure 13. The impact of decision-makers’ risk attitudes on alliance gains.
Figure 13. The impact of decision-makers’ risk attitudes on alliance gains.
Energies 19 00903 g013
Figure 14. The impact of historical sample data on alliance gains.
Figure 14. The impact of historical sample data on alliance gains.
Energies 19 00903 g014
Table 1. Comparative analysis of literature review.
Table 1. Comparative analysis of literature review.
Ref. No.Shared Energy Storage TechnologyTrading StrategyUncertainty
SESO–MGOMGO–User
[2]ES + TESNash bargaining game××
[6]P2GNash bargaining game××
[9]ES + TESBi-level optimization model××
[10]Battery + P2GBi-layer optimization model××
[11]ES + HSTStackelberg game××
[14]ESStackelberg gameStackelberg game×
[18]ESNash bargaining game××
[27]ES ×DRO
[28]P2GNash bargaining game×DRO
This paperES + P2GNash bargaining gameStackelberg gameDRO + CVaR
Table 2. Tou price.
Table 2. Tou price.
TimePrice (yuan/kWh)
1:00–7:00; 23:00–24:000.4
8:00–11:00; 15:00–18:000.75
12:00–14:00; 19:00–22:001.5
Table 3. Scenario settings.
Table 3. Scenario settings.
ScenarioStackelberg GameUncertaintySESO
1××
2×
3
4×
Table 4. Optimization results in different scenarios.
Table 4. Optimization results in different scenarios.
ScenarioSESO (yuan)MG1 (yuan)MG2 (yuan)MG3 (yuan)Alliance Benefits (yuan)
11776.3829,502.2521,642.8618,897.6465,644.45
22067.9233,464.8524,766.3821,725.9372,115.05
31456.2829,426.6821,501.5818,547.5470,685.85
4/27,216.0219,628.3917,394.20/
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Liang, J.; Wu, Z. Distributionally Robust Dynamic Interaction for Microgrid Clusters with Shared Electric–Hydrogen Storage. Energies 2026, 19, 903. https://doi.org/10.3390/en19040903

AMA Style

Liang J, Wu Z. Distributionally Robust Dynamic Interaction for Microgrid Clusters with Shared Electric–Hydrogen Storage. Energies. 2026; 19(4):903. https://doi.org/10.3390/en19040903

Chicago/Turabian Style

Liang, Jian, and Zhongqun Wu. 2026. "Distributionally Robust Dynamic Interaction for Microgrid Clusters with Shared Electric–Hydrogen Storage" Energies 19, no. 4: 903. https://doi.org/10.3390/en19040903

APA Style

Liang, J., & Wu, Z. (2026). Distributionally Robust Dynamic Interaction for Microgrid Clusters with Shared Electric–Hydrogen Storage. Energies, 19(4), 903. https://doi.org/10.3390/en19040903

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop