The studied MEMG architecture, as shown in
Figure 1, integrates multiple generation, conversion, and storage technologies. The energy sources consist of wind turbines (WTs), photovoltaic (PV) systems, and a gas turbine (GT). For energy conversion, the system incorporates an electrolyzer (EL) to produce hydrogen and a methanation unit to synthesize natural gas (CH
4). Energy storage is provided by batteries (EES), a hydrogen storage tank (H
2), and a carbon dioxide storage tank (CO
2). The model operates under the assumption that network losses are negligible.
2.1. Objective Function
To address the impact of uncertainty on capacity planning, the objective of this model is to minimize the total annual comprehensive cost, denoted as
. This cost function is formulated as a weighted sum of economic and low-carbon objectives:
where
and
are the weighting factors for the economic and low-carbon objectives, respectively. In this study, equal weighting is adopted, with both set to 1/2. The economic cost
encompasses the entire lifecycle cost of the microgrid, comprising three components:
Here,
: Annualized investment cost.
: Annual operation and maintenance (O&M) cost.
: Annual operating cost (encompassing energy and carbon-related expenses).
The calculation for each cost component is detailed below.
2.1.1. Annual Equipment Investment Cost ()
This cost component represents the annualized capital expenditure for all installed equipment, calculated as
In the formula, represents the unit investment cost of different equipment units; WT, PV, GT, CCS, EL, CH4, and EES stand for wind turbines, photovoltaic systems, gas generators, carbon capture facilities, electrolyzers, methanation equipment, and batteries, respectively; denotes the rated installed capacity of the equipment; is the capital recovery coefficient for device .
The
calculation is shown in (4):
where
is the discount rate, and
is the operational lifetime of device
.
2.1.2. Annual Operating Cost and Maintenance Cost (Com)
This cost accounts for fixed annual maintenance expenses, assumed proportional to the installed capacity:
Here, and are the O&M cost coefficients, expressed as ratios to the investment cost for device .
2.1.3. Annual Operating Cost ()
This component aggregates variable costs incurred during daily operations over representative days. It includes expenses related to energy transactions, demand response compensation, and environmental compliance:
where
: Cost of electricity purchased from the main grid.
: Demand response compensation cost.
: Cost of natural gas procurement.
: Penalty cost for wind and photovoltaic power curtailment.
: Tiered carbon trading cost.
The calculation methodology for each term in is provided in the subsequent subsections.
Cost of Electricity Purchased by the Superiors
The cost of electricity imported from the main grid is given by
In the formula, is the set of four typical days, including spring, summer, autumn, and winter; refers to the number of days that a typical day d occupies in a year; and is the time price of a typical day d.
Demand Response Compensation Cost
The compensation cost for demand response participants is calculated as
In the formula, represents the unit compensation coefficient of the transferable load participating in DR.
Gas Cost
Gas cost is shown in (9):
In the formula, is the unit price of natural gas purchased in the t period of a typical day d.
Cost of Wind and Light Abandonment
Cost of wind and light abandonment is shown in (10):
In the formula, and are the wind curtailment power and light curtailment power in the t time period of a typical day d and they represent the penalty cost per unit of wind curtailment power and light curtailment power.
Carbon Trading Costs
Carbon trading costs are shown in (11):
In the formula, is the step carbon trading cost at time t of a typical day d.
2.2. Model Constraints
2.2.1. Constraints
The installed capacity of each device is bounded by its upper and lower limits:
where the superscripts
min and
max denote the minimum and maximum allowable installed capacities, respectively.
2.2.2. Power Balance Constraints
The electrical power balance within the microgrid must be maintained at all times:
In the formula, is the power load of users in the t period of a typical day d.
2.2.3. Wind Power Output Constraints
Wind power output constraint is shown in (14) and (15):
In the formula, and are the power of a typical day d and wind and light equipment t.
2.2.4. Gas-Generating Constraints
In addition, gas-generating units and carbon capture equipment need to meet the following constraints, which are shown in (16)–(19):
In the formula, is the gas consumption of , the gas generator in the t period; the output is the power of the gas generator in the t period and is the rated total power of the gas generator; a and b are the slope and intercept of the gas cost curve, respectively; is the power of the gas generator set in and , the t period of the typical day d, and are the maximum climbing and descending capacity limits of the gas generator.
2.2.5. Carbon Capture Equipment Constraints
Carbon capture equipment is shown in (20)–(24).
The carbon capture system operates coupled with the gas turbine. Gas turbines generate carbon dioxide emissions during operation. The CCS equipment captures a portion of these emissions, where the captured amount depends on its operating power . The captured CO2 is compressed and stored in a carbon storage tank, ready to be utilized by the P2G process or sequestered. Equations (20)–(24) describe the mathematical model of this process, including capture efficiency, equipment operating power, and its ramping constraints.
In this paper, the amount of CO
2 captured by CCS varies with the load and the output of the gas generator. Therefore, the amount of carbon capture in CCS involves the output of the gas generator, which is usually modeled:
In the formula, is the carbon emission of the gas generator, and and are the output of the gas generator and the carbon emission coefficient related to its output.
Because of the loss of equipment, efficiency cannot reach 100%. The relationship between the amount of CO
2 captured and the total amount of discharge is given by the formula shown in (21):
In addition, gas-generating units and carbon capture equipment need to meet the following constraints as shown in (22)–(24):
In the formula, is the ideal power consumption of the carbon; is the power consumption of the carbon capture equipment in the t period of a typical day d CCS; and and are the maximum climbing and descending capacity limits of the carbon capture equipment.
This research focuses on the steady-state operation economics and carbon benefits of the CCS-P2G system but does not consider its dynamic start-up/shutdown costs. This simplification is common in preliminary research and strategic-level configuration analysis, helping to reduce model complexity.
2.2.6. Electrolytic Cell Constraints
The power and climbing power of the electrolytic cell are limited by the equipment, and the following inequality constraints are shown in (25)–(27):
In the formula, is the power of the electrolytic cell equipment in the t period of a typical day, and and are the maximum limits of the climbing and descending capacities of the electrolytic cell.
2.2.7. Methanation Equipment Constraints
Power-to-gas technology converts surplus electrical energy into easily storable natural gas, serving as a key solution for cross-seasonal energy storage and carbon recycling. The P2G process modeled in this paper consists of two consecutive stages:
The electrolyzer consumes electrical power PEL(t) to split water, producing hydrogen H2 and oxygen.
The methanation unit utilizes the hydrogen produced in the previous step and the carbon dioxide captured by the CCS to perform a catalytic reaction, synthesizing methane .
The produced methane can be directly fed into the gas turbine for power generation or injected into the natural gas grid. Equations (28)–(33) describe the energy and mass balance relationships of the aforementioned two stages and the operational constraints of the equipment.
The electrical power generated by the methanation equipment in P2G devices is related to the unit power consumption coefficient. The total power of P2G devices can be divided into two main parts: the first stage involves electrolyzing water in the electrolyzer to produce hydrogen and oxygen. In the second stage, CO
2 reacts with H
2 under the action of a catalyst to synthesize CH
4 and water. Therefore, the following formula can be used for calculation as shown in (28)–(33):
In the formula, is the power consumption of P2G equipment; is the gas reaction equilibrium coefficient; is the amount of CO2 required for synthesis of CH4; is the power of the t period in a typical day for electrolytic cell equipment; is the power consumption coefficient of the CH4 unit; and and are the maximum limits of climbing and descending capacities of the electrolytic cell.
2.2.8. Generic Energy Storage Constraints
Hydrogen storage (H2) and carbon storage (CO2) systems share similar operational characteristics. Therefore, this paper employs a unified generic energy storage model to describe their operational constraints, as defined by the following equations.
State-of-Charge (SoC) Update Constraint:
This equation governs the energy state evolution of the storage device. Here, represents the storage level at time of typical day , corresponding to for H2 storage and for CO2 storage. and are the charging and discharging efficiencies, respectively. and denote the charging and discharging powers during the time interval .
Power Boundary Constraints:
These inequalities ensure that the charging and discharging powers do not exceed the device’s maximum ratings. The binary variable prevents simultaneous charging and discharging.
State-of-Charge Boundary Constraint:
This constraint maintains the energy state of the storage device within its permissible minimum and maximum limits for safe and stable operation.
For clarity, the correspondence between the parameters of the hydrogen/carbon storage devices and the generic model variables is summarized in
Table 1.
A core innovation of the microgrid model proposed in this paper is the synergistic coupling of CCS and P2G technologies. This integration establishes an internal ‘carbon cycle’: CO2 emitted by the gas turbine is captured by the CCS, and the captured CO2 is subsequently utilized as a feedstock in the P2G process. There, it combines with H2—produced via water electrolysis powered by renewable energy—to synthesize carbon-neutral methane (CH4). This pathway not only reduces the system’s net carbon emissions but also enhances the accommodation capacity of renewable energy, achieving synergistic optimization of energy and environmental objectives.
2.2.9. Battery Constraints
The constraints for the battery energy storage system (BESS) are consistent with the generic energy storage model and are described by the following equations:
In the formula, and are the charging and discharging coefficients of the battery; and are the charging and discharging powers of the battery in the t period; and are the charging and discharging powers of the battery in the t period of the typical day d; is the binary variable of the charging and discharging state of the battery in the t period of the typical day d; and are the maximum charging and discharging powers of the battery; T is the scheduling cycle.
2.2.10. Power Purchase Constraints
Power purchase constraint is shown in (42).
Because the output of distributed energy has strong randomness and volatility, this paper only considers purchasing electricity from the superior power grid.
In the formula, is the maximum value of power purchase from the superior in the t period of a typical day d and does not exceed the maximum output of wind and solar equipment.
2.2.11. Wind and Light Power Constraints
Wind and light power constraints are shown in (43) and (44):
In the formula,
is the maximum light loss rate.
In the formula, is the maximum wind curtailment rate.
2.2.12. H2 Balance Constraints
The H
2 balance constraints are shown in (45):
2.2.13. CO2 Balance Constraints
The CO
2 Balance constraints are shown in (46):
2.2.14. Ladder-Type Carbon Trading Constraints
By trading carbon emission allowances, the government or relevant departments allocate certain carbon emission quotas to power generation companies that have emissions, either for a fee or free of charge, to achieve carbon reduction targets. Production is positively correlated with carbon quotas; for companies of the same capacity, those with stronger emission reduction capabilities generate surplus quotas, while others face deficits, as can be found in [
24,
25]. Moreover, the gradual tightening of national
carbon quotas has increased the trading price of carbon quotas. To boost profits, companies are forced to reduce their carbon emissions. If they exceed their allocated quotas, they must purchase the shortfall from other companies or institutions. Free carbon emission allowances can be expressed as follows:
is the carbon quota for the system; is the emission quota for the unit power generation of gas generators purchased by the superior; is the generation of thermal power purchased by the superior; is the output power of gas generators in the t period; is the power purchased by the superior grid.
The actual carbon emissions in the
microgrid are shown in (48):
is the cruel carbon emission;
is the carbon emission intensity per unit of electricity
generated by gas generators; carbon emission
is the CO
2 density intensity per unit of electricity generated by thermal power purchased by superiors; the above data are referenced in the literature [
11].
To further increase carbon emission costs and incentivize emission reduction, a tiered carbon trading model is adopted in this paper. This model imposes an increasing carbon price based on the interval in which the difference between the actual carbon emissions and the free quota, , falls. The calculation mechanism is described step-by-step as follows:
Define Intervals and Prices:
Let the base carbon price be (CNY/ton), the price growth rate be , and the length of a single interval be (tons). The carbon emission range is divided into multiple tiers. The -th tier () is defined as , and its corresponding carbon price increases geometrically: .
Calculate Tiered Cost:
The total tiered carbon trading cost
is the sum of the costs across all applicable tiers. For a given emission difference
, assuming it falls within the
-th tier (i.e.,
), the cost is calculated as
The first term in this formula computes the cumulative cost of the first fully loaded intervals, and the second term computes the cost for the partially filled -th interval.
For easier implementation within the optimization model, this piecewise linear cost function can be equivalently formulated using the following compact mathematical programming form, which captures the structure more clearly than the original Equation (50):
Subject:
where
is a sufficiently large constant, representing the maximum number of tiers considered.
is an auxiliary decision variable, representing the portion of the emission difference
that falls into the
-th price tier.
is the carbon price for the
-th tier.
2.2.15. Incentive Demand Response Constraints
The incentive-based demand response (DR) model adopted in this paper simplifies the adjustment of power consumption strategies. It focuses on the load acquisition facilitated by national policy subsidies during load shifting, without considering changes in consumption patterns due to electricity price adjustments, aiming to improve the microgrid’s economy. Furthermore, loads are categorized in a simplified manner [
26,
27].
The total electrical load is divided into two parts: inelastic load and shiftable load. The shiftable load can be transferred across time dimensions and possesses DR capability. This is expressed as
In the formula, represents the value of the load t period, represents the forced load of the electric load t period, and represents the transferable load of the load t period.
The inelastic load must be consumed and typically refers to essential energy uses in daily life, such as lighting and refrigeration. This fixed load is not considered to participate in DR.
The shiftable load
can be transferred to different time periods during operation if necessary. Generally, consumption is reduced during peak load periods and increased during low load periods to improve resource utilization. The constraints are as follows:
In the formula, and represent the amount of transferable load DR and the amount participating in DR; is , a binary variable indicating the access status of DR at time t, and represents the incoming and outgoing power of transferable load ; in Equation (57) indicates that the total power change of the transferable load participating in DR within a scheduling cycle does not affect the original load and represents the upper and lower limit values of the amount participating in DR at each time period.
Incentive Demand Response Mechanism
To enhance the economic performance of the microgrid, this paper adopts a shiftable load management strategy within the framework of incentive-based demand response. This mechanism does not rely on electricity price variations. Instead, the microgrid operator enters into agreements with users and provides fixed compensation to participants for shifting part of their electricity consumption from peak periods to off-peak periods.
The electrical load is simplified into two parts: rigid load and shiftable load. The rigid load must be satisfied instantly, while the shiftable load (e.g., electric vehicle charging, specific industrial processes) can be shifted across time dimensions. It is assumed that the shiftable load constitutes a proportion of the total load, and its total energy consumption remains unchanged within the dispatch cycle.
Demand Response Parameter Setting
In this case study, it is assumed that 20% of the microgrid’s load is shiftable. The unit compensation coefficient cDR is set to 0.5 CNY/kWh. The maximum power for load shifting in or out at any time is set to 15% of the forecasted total load for that period. These parameters are intended to simulate a moderately active demand response program.
2.2.16. Dynamic Operational Constraints for Dispatchable Units
To enhance the practical relevance of the model, we have further introduced refined constraints and cost models that account for equipment start-up/shut-down dynamics and CCS load-dependent characteristics. The specific methodologies are as follows:
Countermeasure for Dynamic Response Times: Introduce Unit Commitment and Ramp-Rate Constraints
Introducing Binary State Variables and Minimum Up/Downtime Constraints:
For dispatchable devices (GT, CCS, EL), introduce binary variables representing the on/off status (1 = on, 0 = off) at time t of typical day d.
Minimum Uptime Constraint:
Once started, a unit must remain for a minimum duration
.
Minimum Downtime Constraint:
Once shut down, a unit must remain off for a minimum duration
.
Incorporate Start-up Costs:
Modify the annual operating cost by adding a start-up cost term:
where
is the start-up cost per event.
Refine Ramp-Rate Constraints Linked to State:
Enhance the existing ramp constraints to account for start-up and shut-down transitions.
Maximum Ramp-Up Constraint:
Maximum Ramp-Down Constraint:
Here, and are the normal maximum ramp rates (kW/h), while and represent the maximum allowable power change during start-up or shut-down, respectively, preventing unrealistic power jumps.
Countermeasure for CCS Efficiency Variability: Establish a Load-Dependent Energy Consumption Model
Develop a Piecewise Linear Approximation of a Nonlinear Efficiency Function:
CCS power consumption is a function of GT power and the capture rate . First, obtain this function from technical data or simulation. To maintain linearity, perform piecewise linearization. Select reference points (e.g., GT at 25%, 50%, 75%, 100% load) and calculate the corresponding CCS energy consumption for a fixed or varying .
Introduce Auxiliary Variables for Piecewise Linearization: Use binary variables
and continuous variables
to indicate the active segment i.