*3.1. Energy Balancing*

The first set presents the operation of the simple energy balancing algorithm. Figure 9 presents the performance indicators aggregated per month to give an overview of the whole year's operation. It is clearly visible that in winter months (November to February) the role of the production from photovoltaic is marginal and almost all of the produced energy is used for the self-consumption. In winter, the energy storage has no chance to charge as there is no surplus of energy. From March to October the activity of the energy storage is substantial, yet still, the storage is not able to completely rule out any purchase energy from the grid for June and July. Figure 9d represents the monthly aggregation of the energy bought and sold; in summer both can occur: sale and purchase can be present in the same month as one month can contain days when there is enough power from RES to cover the usage and sell, but the month can also contain days that might be too cloudy, making it necessary to buy energy.

**Figure 9.** Results for the energy balancing method, aggregated monthly: (**a**) grid energy balance, (**b**) energy usage and production (input data), (**c**) activity of the energy storage, (**d**) cost of purchased energy and profit for sold energy.

The more detailed view of each month gives a much better picture of the actual HESS performance. In Figures 10 and 11, the two different months are presented—January is the month with minimal energy storage activity, and July is the month when a surplus of produced energy allows the storage to cover the energy use in the evenings. On the 1 January, due to the initial settings of the simulation, the batteries are charged up to 50%, which causes the discharge of the battery immediately. In the other days in January, PV

generation does not exceed the load, so there is no ESS activity. In July, however, the situation is much more interesting—there are days where there is no need to buy energy from the grid (Figure 10d), which shows the real usefulness of the energy storage.

**Figure 10.** Results for the energy balancing method—data for the month of January, aggregated per day: (**a**) grid energy balance, (**b**) energy usage and production (input data), (**c**) activity of the energy storage, (**d**) cost of purchased energy and profit for sold energy.

**Figure 11.** Results for the energy balancing method—data for the month of July, aggregated per day: (**a**) grid energy balance, (**b**) energy usage and production (input data), (**c**) activity of the energy storage, (**d**) cost of purchased energy and profit for sold energy.

The following figures illustrate daily power profiles of the microgrid, including HESS. To fully illustrate behavior of control algorithms under different conditions, three days are chosen: 27 July with high PV generation (Figure 12), 4 October with medium PV generation

(Figure 13) and 6 February with almost no PV generation (Figure 14). The dynamics of the different types of batteries are clearly visible—the VRFB has more capacity, which cannot be fully used due to its lower power. Very visible is the non-optimal behavior of immediately discharging the storage at the beginning of the day in case the batteries have not discharged during previous day. Night time is related to lowest energy prices, so such behavior is not economically justifiable.

**Figure 12.** Results for the energy balancing method—data for 27 July: (**a**) grid power balance, (**b**) energy usage and production (input data), (**c**) batteries power, (**d**) batteries state of charge.

**Figure 13.** Results for the energy balancing method—data for 4 October: (**a**) grid power balance, (**b**) energy usage and production (input data), (**c**) batteries power, (**d**) batteries state of charge.

**Figure 14.** Results for the energy balancing method—data for 6 February: (**a**) grid power balance, (**b**) energy usage and production (input data), (**c**) batteries power, (**d**) batteries state of charge.

In October, the situation is similar to the summer time—there is still enough PV production that allows using both batteries to reduce the power exchange with the grid—first the VRFB is discharging, later the LFP takes over.

In winter (Figure 14), the energy storage is not active as there is little overproduction to be used.

Figure 15 summarizes the financial aspect of the HESS operation. Figure 15a depicts cost of energy purchased in each tariff zone, which clearly demonstrates that the high afternoon peak is not avoided, especially in winter months. In summer months, the PV production combined with the storage can substantially reduce the exchange with the grid. The overall costs and profits are presented in Figure 15b showing that the overall financial outcome is positive in June. Figure 15c gives the values of the surplus RES energy used directly or captured by the HESS. It is calculated as the costs that would have been if there was no energy production. In Figure 15d, the costs saved by the energy storage are presented, this includes the costs that are caused by the degradation of the storage—it is calculated from the difference of the total outcome with and without HESS. The overall cost balance has substantially decreased compared to the situation without the batteries at all, the value is PLN 266,028. This clearly shows that even the simple algorithm of battery management can lower the yearly costs of the operation of the facility.

**Figure 15.** Results for the energy balancing method—monthly economic indicators: (**a**) purchase cost classified by tariff zones (tariff prices), (**b**) costs, profits and financial balance, (**c**) costs of energy saved by PV generation, (**d**) costs of energy saved by HESS operation.
