# Energy Trading Strategy for Heat and Electricity-Coupled Microgrid Based on Cooperative Game
## 6 Distribution Solution
### Algorithm Implementation
It is easy to see that the power of an MT reaches its maximum in

Figure 6: Energy Consumption of Users. (**a**) User1. (**b**) User2. (**c**) User3. time slots 1-10 and time slots 21-24. The main reason is that the thermal load demand in these two periods exceeds the maximum value of the MT's heat supply. Additionally, to ensure the thermal energy supply to users, the standby boilers will be put into operation during these two periods. Compared with the original heat supply strategy, the optimized output power of the standby boiler is lower in these two periods. In time slots 11-20, as the demand for heat load during the day decreases, the standby boiler is no longer put into operation. The MT runs in the heat lead mode to supply heat energy for users. Under heat load DR, the optimized MT output power is lower than the original value. In addition, it can be seen that the electric energy supply of the MT varies with the thermal energy supply of the MT in all periods. To balance the electric energy in the MG, the MGO should trade with the utility grid. The optimized electricity net energy is shown in Figure 8. Compared with the original net profile, the optimized net profile is flatter. The electricity buying demands in time slots 10-12 and 18-21 are effectively suppressed. The redundant electric energy in time slots 1-5 and 13-15 has been well utilized. Therefore, the trading cost of the MGO is reduced. Figure 9 shows the decline in the MGO's natural gas purchases from gas companies. Obviously, as thermal supply based on thermal DR decreases, the optimized gas purchasing volume decreases, thus reducing the gas consumption cost of the MGO. Figure 8: Electricity trading between MGO and grid. Figure 7: Energy Supply of MT and Boiler. ### Analysis of Economic Benefit

#### 7.5.1 Compare with the Original Strategy

To further analyze the impact of the proposed model on economic benefits, the results of the comparison are shown in Table 2. The profit of the MGO is much higher when using the proposed strategy, which has a 5.15% profit increase compared with the original strategy. In addition, the profits of users 1-3 also increase 1.73%, 1.76%, and 1.78%, respectively. #### 7.5.2 Compare with the Strategy Based on Stackelberg Game

As discussed in Section I, the study of [20] mainly focuses on the optimization strategy based on the Stackelberg game. In the Stackelberg game, users determine energy consumption according to the prices specified by the MGO, while in the Nash cooperation game, the users decide their thermal and electric demand by bargaining with the MGO. To illustrate the advantage of the proposed strategy, the increased benefits of comparison are shown in Figure 3.0 Obviously, the MGO can gain more profits in the Stackelberg game, while users can get more benefits through the Nash bargaining game. However, as the essence of the Nash bargaining game is to maximize social welfare, all the participants in the MG can make more increased social benefits. Besides, the increased benefits are fairly distributed to the MGO and users. Therefore, the users are more willing to participate in the proposed energy trading strategy. \begin{table}
\begin{tabular}{c c c c} \hline \hline \multirow{2}{*}{**Participants**} & \multicolumn{2}{c}{**Original Benefits**} & \multicolumn{2}{c}{**Optimized Benefits**} & \multirow{2}{*}{**Increased Percentage**} \\  & **(RMB)** & & **(RMB)** & \\ \hline MGO & 2437.0 & 2561.5 & 5.15\% \\ User1 & 7244.1 & 7369.7 & 1.73\% \\ User2 & 7117.7 & 7243.2 & 1.76\% \\ User3 & 7028.1 & 7153.6 & 1.78\% \\ \hline \hline \end{tabular}
\end{table} 
Table 2: Comparison of Economic utilities. Figure 9: Natural gas consumption. ## 8 Conclusions

In the present paper, an energy trading framework was proposed for CHP-MG with hybrid DR users, consisting of both electric and thermal demand.