3.1. Objective Function
In this paper, the two objectives are evaluated from economic and environmental perspectives. In an integrated energy community, including electrical, gas, cold, and heat energy, the impact of carbon emissions should be considered in particular. Therefore, the annual total operating cost and annual carbon emissions are selected as the optimal allocation objectives of the integrated energy community.
3.1.1. Total Annual Operating Costs
The minimum annual total operating cost is selected as the economic objective function to determine the configuration capacity of various pieces of energy equipment. The annual total operating cost includes the primary investment cost and the operation and maintenance costs of the power storage system, heat storage system, clean energy power station, solid oxide fuel cell system, heat pump, electric refrigerator, and absorption refrigerator. The cost of purchasing and selling electricity from the power grid and the cost of purchasing natural gas from the fuel cell are shown in (11).
In the formula,
Ctotal is the total annual operating cost of the integrated energy community, including the investment cost of the power storage system,
CBES; the investment cost of the heat storage system,
CHS; the investment cost of the photovoltaic system,
CPV; the investment cost of the wind power system,
CWT; the investment cost of the solid oxide fuel cell system,
CSOFC; the investment cost of the heat pump,
CHP; the investment cost of the electric refrigerator,
CEC; the investment cost of the absorption chillers,
CAC; the cost of purchasing electricity from the grid,
Cbuy; the revenue from electricity sales to the grid,
Csell; and the fuel cost of purchasing natural gas,
CNG. The specific calculation formulas of the costs are as follows [
20].
The investment cost of the power storage system:
In the formula, r is the discount rate, is the life cycle of the power storage system, is the primary investment cost of the unit power storage system, is the annual operation and maintenance costs of the unit power storage system, and EBES is the configuration capacity of the power storage system.
- 2.
The investment cost of the heat storage system;
In the formula, r is the discount rate, is the life cycle of the heat storage system. is the unit investment cost of the heat storage system, is the annual operation and maintenance costs of the unit heat storage system, and EHS is the configuration capacity of the heat storage system.
- 3.
The investment cost of the photovoltaic system;
In the formula, is the life cycle of photovoltaic systems, is the primary investment cost of the unit photovoltaic system. is the annual operation and maintenance costs of the unit photovoltaic system, and PPV is the configuration capacity of the photovoltaic system.
- 4.
The investment cost of the wind power system;
In the formula, is the life cycle of the wind power system, is the primary investment cost of the unit wind power system, is the annual operation and maintenance costs of the unit wind power system, and PWT is the configuration capacity of the wind power system.
- 5.
The SOFC system’s investment costs;
In the formula, is the life cycle of the solid oxide fuel cell system, is the unit investment cost of the solid oxide fuel cell system, is the annual operation and maintenance costs of the unit solid oxide fuel cell system, and PSOFC is the configuration capacity of the solid oxide fuel cell system.
- 6.
The investment cost of the heat pump:
In the formula, is the life cycle of the heat pump, is the unit investment cost of the heat pump, is the unit annual operation and maintenance costs of the heat pump, and PHP is the configuration capacity of the heat pump.
- 7.
The investment cost of the electric refrigerator:
In the formula, is the life cycle of the electric refrigerator, is the first investment cost of the unit electric refrigerator, is the annual operation and maintenance costs of the unit electric refrigerator, and PEC is the configuration capacity of the electric refrigerator.
- 8.
The investment cost of the absorption chillers:
In the formula, is the life cycle of an absorption refrigerator, is the first investment cost of the unit absorption refrigerator, is the annual operation and maintenance cost of the unit absorption chiller, and PAC is the configuration capacity of the absorption refrigerator.
- 9.
The cost of purchasing electricity from the grid:
In the formula, λre(t) is the power grid electricity purchase price over period t, Pbuy(t) is the community’s electricity purchases from the grid over a period t, and is the duration of the unit scheduling period.
- 10.
Revenue from electricity sales to the grid:
In the formula, λfit(t) is the on-grid price over a period t, and Psell(t) is the amount of electricity sold by the community to the grid over a period t.
- 11.
The cost of purchasing natural gas:
In the formula, λNG(t) is the natural gas purchase unit price over a period t, and QNG(t) is the purchase amount of natural gas over a period t.
3.1.2. Total Annual Carbon Emissions
The annual total carbon emissions are the objective function evaluated from the perspective of the environment. Clean energy generates almost no carbon emissions in the process of generating electricity. At the same time, in order to simplify the problem, the carbon emissions generated during the operation and maintenance of the energy equipment are not considered. Therefore, the calculation of the annual carbon emissions is mainly composed of two parts: the emissions of electricity purchased from the main power grid and the emissions generated by natural gas consumption, as shown in (23).
In the formula, is the unit carbon emission coefficient of the power grid, and is the unit carbon emission coefficient of natural gas.
3.2. Constraint Condition
According to the energy management strategy of the integrated energy community given in
Section 2.1, the constraints of the integrated energy community’s energy optimization configuration model include equipment state constraints, cold and heat energy balance constraints, the building’s power state constraints, the community’s power state constraints [
21], the community’s purchase and sale power constraints [
22], the power storage system’s state continuity constraints [
23], and the heat storage system’s state constraints.
The equipment state constraint indicates that the available installation capacity of the planned energy production equipment is constrained by the planning upper limit, and the input of the heat pump, the electric refrigerator, and the absorption refrigerator must be lower than the corresponding installation capacity. At the same time, the energy conversion efficiency constraints of each piece of energy conversion equipment are also stipulated. Constraints (24) and (25) indicate that the clean energy scale that each building can plan to configure is limited. Constraint (26) indicates that the SOFC scale planned for each building is limited. Constraints (27) to (29) indicate that the operating power of the energy equipment must not exceed its configuration capacity. Constraint (30) represents the energy balance model of the electric heat pump. Constraint (31) represents the energy balance model of the electric refrigerator. Constraint (32) represents the energy balance model of the absorption refrigerator. Constraint (33) indicates that the operating power of the SOFC must not exceed its configuration capacity and must not be less than 30% of its configuration capacity to avoid the low-load operating conditions of the SOFC [
24]. Constraints (34) and (35) represent the energy balance model of the SOFC. Constraints (36) and (37) indicate that in order to avoid drastic changes in the output of the SOFC, the difference in the output power of the SOFC at adjacent times is limited to 50% of the configuration capacity [
24].
In the formula,
is the upper limit of the configuration capacity of the photovoltaic system in building
n,
is the upper limit of the wind power system configuration capacity in building
n,
is the upper limit of the SOFC system configuration capacity in building
n;
is the electric power consumed by the heat pump of building
n at time
t,
is the electric power consumed by the electric refrigerator of building
n at time
t,
is the thermal power absorbed by the absorption chiller of building
n at time
t;
is the thermal power generated by the heat pump of building
n at time
t,
is the heating efficiency of the heat pump in building
n;
is the cold power generated by the electric refrigerator of building
n at time
t,
is refrigeration efficiency of the electric refrigerator in building
n;
is the cold power generated by the absorption chiller of building
n at time
t, and
is the refrigeration efficiency of an absorption chiller for building
n.
In the formula, is the electrical power output by the SOFC of building n at time t, is the amount of natural gas consumed by building n at time t, is the electrical efficiency of the SOFC for building n, is the heat-to-electric output ratio of the SOFC for building n, and is the thermal power output of the SOFC of building n at time t.
- 2.
The cold and hot energy balance constraints:
The cold and hot energy balance constraint indicates that the cold and hot power in each building in the community should be balanced under the community integrated energy management strategy proposed in this paper. Constraint (38) indicates the thermal power energy balance of building n. Constraint (39) indicates the cold power energy balance of building n. Constraint (40) indicates that the thermal power output by the SOFC consists of two parts.
In the formula, is the thermal load power demand of building n at time t, is the cooling load power demand of building n at time t, is the thermal power obtained by building n from the heat storage system at time t, is the part of the thermal power output by the SOFC of building n at time t, and is the part of the thermal power that is not utilized in the SOFC output of building n at time t.
- 3.
The state constraints of the buildings’ electric power:
The electric power state constraint of the buildings indicates the calculation method and state limit of the excess electric power and electric power shortage of each building in the community under the community integrated energy management strategy proposed in this paper. Constraints (41) and (42) represent the calculation method of the electric power excess and shortage of building
n in a period
t, respectively. Constraint (43) indicates that the two states of electric power excess and power shortage cannot appear at the same time. Constraint (44) indicates that the sum of the variables
and
is nonnegative.
In the formula, is the remaining amount of electrical power in building n at time t, is the shortage of electrical power in building n at time t, is the configuration capacity of the photovoltaic system in building n, is the wind power configuration capacity of building n, and and are the amounts of power generated by the unit photovoltaic and unit wind power systems of building n at time t, respectively. is the electrical load power demand of building n at time t. represents the 0–1 variable of the residual state of electrical power in building n in time period t. Taking 1 means that there is an electrical power surplus in building n; otherwise, a value of 0 is obtained. represents the 0–1 variable of the state of an electrical power shortage in building n during the period t. When 1 is taken, it indicates that there is insufficient electrical power in building n; otherwise, 0 is taken.
- 4.
The community’s electrical power state constraints:
The community’s electrical power state constraint represents the calculation method and state limitation of an overall electrical power surplus and electrical power shortage in the community under the community integrated energy management strategy proposed in this paper. Constraints (45) and (46) represent the calculation method of an electrical power surplus and shortage in the community’s building group in a period
t, respectively. Constraint (47) indicates that the two states of electrical power surplus and power shortage cannot appear at the same time. Constraint (48) indicates that the sum of the variables
and
is nonnegative.
In the formula, N is the total number of buildings in the community, is the remaining amount of electrical power in the community’s buildings at time t, is the shortage of electrical power in the community’s buildings at time t, and represents the 0–1 variable of the residual state of electrical power in the community during a period t. When 1 is taken, it indicates that there is residual electrical power in the community’s buildings; otherwise, 0 is taken. represents the 0–1 variable of the state of an electrical power shortage in the community during the period t. When 1 is taken, it indicates that there is insufficient electrical power in building n; otherwise, 0 is taken.
- 5.
The electricity purchase and sale’s constraints in the community:
The community’s power purchase and sale constraint represents the calculation method of the community’s and external power grid’s power purchases and sales under the community integrated energy management strategy proposed in this paper and its limited binary variable state constraint. Constraints (49) and (50) represent the calculation methods of power sales and power purchases over a period
t, respectively. Constraints (51) and (52) represent the state constraints of the maximum state of charge and the minimum state of charge of the power storage system, respectively.
In the formula,
represents the 0–1 variable of whether the community’s power storage system reaches the maximum state of charge during a period
t. When 1 is taken, it means that the power storage system reaches the maximum state of charge; otherwise, a value of 0 is obtained.
represents the 0–1 variable of whether the community’s power storage system reaches the minimum state of charge during the period
t. When 1 is taken, it means that the power storage system reaches the minimum state of charge; otherwise, a value of 0 is obtained.
is the charging amount of the storage system over a period
t, and
is the discharge amount of the storage system over a period
t. The calculation methods are as follows in (53) and (54).
In the formula, SOC(t) is the state of charge of the community’s power storage system at time t, SOCmax is the maximum state of charge of the power storage system, SOCmin is the minimum state of charge of the power storage system, μcha is the charging efficiency of the power storage system, and μdis is the discharge efficiency of the power storage system.
- 6.
The continuity constraint of the state of charge of the storage system:
The continuity constraint on the state of charge of the power storage system represents the calculation method and state constraint of the state of charge of the power storage system under the community integrated energy management strategy proposed in this paper.
In the formula, Constraint (55) represents the calculation formula for the state of charge. Constraint (56) represents the energy conservation of the initial and final states of the community’s power storage system. Constraint (57) indicates that the state of charge at any time is between the maximum state and the minimum state of charge.
- 7.
The state constraints of the heat storage system:
The continuity constraint on the state of charge of the heat storage system represents the calculation method and state constraint of the state of charge of the heat storage system under the community integrated energy management strategy proposed in this paper. Constraint (58) represents the heat storage state calculation formula for the heat storage system. Constraint (59) represents that the two states of stored heat energy and released heat energy cannot appear at the same time. Constraint (60) represents the energy conservation of the initial and final states of the community’s heat storage system. Constraint (61) represents that the heat storage state at any time is between the maximum and the minimum heat storage states.
In the formula, is the heat storage state of the community’s heat storage system at time t, is the maximum heat storage state of the heat storage system, is the minimum heat storage state of the heat storage system, is the heat storage efficiency of the heat storage system, and is the heat release efficiency of the heat storage system. represents the 0–1 variable of whether the community’s heat storage system is in the state of stored heat energy over a period t. When 1 is taken, it means that the heat storage system is in a state of stored heat energy; otherwise, a value of 0 is obtained. represents the 0–1 variable of whether the community’s heat storage system is in a state of releasing heat energy over a period t. When 1 is taken, the heat storage system is in a state of releasing heat energy; otherwise, 0 is taken.