## 4 Case Study
### Results and Analysis
#### 4.2.1 Impact of Energy Storage Equipment and Electric Energy Substitution on RIES
Similar results can be obtained in the grid-connected mode, therefore, it will not be repeated again. It is noted that the interaction power with the grid plays a key role in energy storage configuration in the grid-connected mode, the conclusion obtained above may be different in the grid-connected mode, which has been analyzed in detail below. For further discussion, the electricity, gas and heat output of each device in scene 3 under both off-grid and grid-connected modes are shown in the Figure 4.  
As shown in Figures 3 and 4, the wind power was high but the electric load demand was low during 1-7 h in the evening. During this period, the space for the system to accept wind power could not be improved even though the MT was working with minimum power, causing lot of wind power to be abandoned in scenario 2. P2G and EB equipment were added in scenario 3. During the abandonment period, P2G and EB works were equivalent to increasing the electric load. At the same time, the surplus electric energy was converted into natural gas and heat energy respectively, and the remaining electric energy was stored by the battery for discharging when the electric demand was high. P2G only works when the wind power is high, and P2G turns off when the electric load demand is high in the day, while EB works all day because of the heat load demand, and its output force follows the change of heat load value. As the abandoned wind power was consumed by P2G and EB, the system abandonment rate reduced from 32% to 0. At the same time, the cost of purchasing natural gas from the external gas network reduced because part of the natural gas needed by the RIES was produced by the P2G, while EB heat production reduced the output of CHP and optimized the operation of the system. The cost was significantly reduced, and the storage system configuration capacity was also significantly reduced. \begin{table}
\begin{tabular}{c c c c c c c c} \hline \hline  & & \(C_{\text{inv}}\)/yuan & \(C_{\text{op}}\)/yuan & \multicolumn{2}{c}{**Total**} & \multicolumn{2}{c}{**Power**} & \multicolumn{1}{c}{**Gas**} \\  & & & & **Costs/yuan** & **Costs\({}^{1}\)/yuan** & **Costs\({}^{2}\)/yuan** & \(\beta\)/\%** \\ \hline \multirow{4}{*}{Off-grid} & Scen.\({}^{3}\)1 & 0 & 2902.48 & 2902.48 & 0 & 2062.15 & 4.02 \\  & Scen.2 & 193.53 & 4291.84 & 4485.38 & 0 & 2840.41 & 32.39 \\  & Scen.3 & 98.20 & 2356.04 & 2454.24 & 0 & 1976.16 & 0 \\  & Scen.1 & 0 & 2379.06 & 2379.06 & \(-\)524.6 & 2469.4 & 0 \\ Grid-connected & Scen.2 & 59.77 & 2625.06 & 2711 & \(-\)600.4 & 2830.08 & 5.2 \\  & Scen.3 & 41.29 & 2129.42 & 2170.71 & \(-\)516.6 & 2427.7 & 0 \\ \hline \hline \end{tabular}  
* Interaction costs with the grid; 2 Interaction costs with the gas network; 3 Scenario.  
\end{table} 
Table 5: The costs of the RIES in different scenarios. Figure 4: _Cont_. Comparing Figure 4a with Figure 4b, it can be seen that interaction power with the grid played a key role in the grid-connected mode. In the abandonment period, the system sells surplus wind power to the grid more since selling electricity is obviously more economic than opening P2G. Therefore, P2G does not work, and the output of EB has also decreased, which is different from the off-grid mode. There was no significant difference between the heat output and the gas output of equipment in the grid-connected mode compared with the off-grid mode. Due to the existence of interactive power with the power grid, the overall benefit of the system in the grid-connected mode was better than the off-grid mode, and the energy storage configuration capacity was also reduced.