Keywords

2.1 Introduction

Large-scale thermal power plants were the main source of energy in recent decades. Fossil fuels whose resources are ending are converted into other energies (mainly electricity) with very low efficiency at these plants. Transmission and distribution infrastructure over long distances are responsible for delivering this energy to consumers. However, such a structure of energy supply faces many problems. The problems caused by the fossil fuels consumption and greenhouse gases emissions have led to issues such as global warming and increasing international environmental concerns. Because of the scarcity of fossil fuels and the lack of access to the resources of this fuel in many countries in the world, it is not reasonable to use them at low-efficiency thermal power plants. On the other hand, problems such as the huge costs and losses of transmission and distribution systems, the difficulty of controlling and protecting these systems have made the current hierarchical systems not a suitable option for future energy supply. From another perspective, different energy systems were planned and managed independently [1]. But nowadays the development of technologies such as efficient multi-generation system leads to realizing the benefits of integrated energy infrastructure such as electricity, natural gas, and district heating networks, and thus a rapid movement toward multi-energy systems. In such systems, different energy carriers and systems interact together in a synergistic way. However, consideration of such a concept requires a suitable tool for integrated management of the system components. Energy hub is an appropriate framework for modeling and optimal scheduling of multi-energy systems [2]. Therefore, the scarcity of fossil fuels, environmental concerns, and problems of centralized energy supply systems have led to an incentive to use energy efficient systems and alternative energy systems [3].

Nowadays, with the advent of DER in particular RES, ESS, and multi-generation systems, centralized large-scale power plants are now shifting to local and distributed energy sources. RES are one of the most commonly used distributed energy sources that their popularity is increasing day by day. From another perspective, renewable energies are much more stable than fossil fuels and have endless reserves. Therefore, these energies have also a remarkable role in sustainable development. This means that they have a much less destructive effect on the environment and can, in addition to meeting the needs of the current generation, respond to the needs of future generations and not be a threat to them. However, the main problem of these resources is their fluctuating and unpredictable nature. The production of these resources heavily depends on the location and time of their operation, which reduces the reliability of the operation of renewable systems. One of the main solutions to this problem is the use of energy storage systems. ESS, in addition to mitigating the effects of the integration of RES, can be used to provide ancillary services to energy networks and to participate effectively in demand response programs and to create a balance between energy production and demand. An energy hub can interact with different energy carriers so the energy hub can simultaneously utilize different RES and ESS. Each of these elements has some effects on the performance of the hub. The main objective of this chapter is to review and discuss the effects and the role of RES and ESS on the optimal management of energy hubs. In this regard, the role of renewable resources as inputs in energy hubs and energy storages to improve the reliability and flexibility of the energy hub is studied by reviewing previous research in this area. Finally, a model of energy hub is presented and the role of RES and electrical and thermal storage systems is discussed using numerical results.

2.2 Impact of RES on the Performance of EHs

In the energy hub models different energy carriers can interact with each other, and thus the energy hub can provide these different carriers through common sources such as electricity and natural gas networks or from renewable sources. Therefore, the range of inputs varies from fossil fuel sources to new and renewable technologies [4]. In large-scale and centralized power plants, which are major energy suppliers in many parts of the world, mostly fossil fuels are converted to low-efficiency electricity (low energy conversion efficiency at thermal power plants), and this electricity is transmitted to consumers with high losses, resulting in a large part of the primary energy is wasted in this system. For example, in a conventional coal-fired power plant, 72% of the primary energy is wasted and only 28% of it reaches the final consumer [5].

DER can be defined as systems for producing or storing energy at or near the place of consumption. The development of these systems will reduce the waste of primary energy, reduce transmission losses and thus reduce operating costs. DER have the ability to use different technologies such as fuel cells, micro gas turbines, waste heat recovery equipment, renewable technologies such as small wind turbines and PV. These types of on-site energy generation resources can be one of the main sources of energy for an energy hub. A model for optimal scheduling of a DER including renewable resources and storage systems along with power distribution networks with the goal of minimizing energy costs has been presented in [6]. Renewable resources can play an essential role in DER and their share is increasing rapidly. The inefficiency of fossil-fuel-based energy systems has led to the integration of RES with these systems and the move towards 100% renewable energy systems [7]. The use of RES, such as biomass, solar, fuel cells and the use of waste heat in the different co-generation and poly-generation technologies have been studied in [8]. The role of different technologies to achieve a 100% renewable energy system in Europe in 2050 has been discussed in [9]. The results showed that by using existing technologies there is a possibility to achieve a 100% renewable scenario, due to the possibility of optimal integration of different energy carriers. This reveals the importance of multi-energy systems and energy hub models in optimal utilization of energy resources, especially in the future renewable energy systems.

Therefore, different energy carriers used in energy hubs can be supplied only through renewable sources, and the consumption of fossil fuels in the energy hub can be zero. For example, electricity and heat of an energy hub can be generated from solar and geothermal sources. In addition to generating electricity and heat, it is also possible to produce water in a fuel cell, as one of the most promising renewable technologies. Wind power can be used to supply electricity for various applications. In this regard, the possibility of using PV along with CHP in energy hub models for centralized cooling, heating, and electricity energy supply in a residential area has been investigated in [5]. The results of this study have shown that the use of PV in addition to supplying electricity demand in district level also provides the possibility of selling excess electricity to the grid. The biomass is another renewable energy that can be used in various forms in energy hubs and can provide different energy carriers such as electricity, heat, and transport fuels. A complete model of the various components of the biomass supply chain, including electricity, heating, and gas infrastructures for modeling various biomass technologies has been offered in [10]. A comprehensive overview of the biomass energy conversion models for generating electricity, heat, and fuel, along with a discussion of the challenges in this area, can be found in [11]. An assessment has been conducted in [12] to reduce the share of fossil fuels and increase the share of RES in the form of energy hub models for a village in Switzerland. The study focuses on the development of renewable technologies such as PV, biomass-based district heating, and small hydroelectric power plants to reduce costs and emissions. By developing this model, the authors in [13] provided a model for planning a hybrid renewable energy supply system for the village in the form of different structures of energy hubs. The results show that increasing the share of RES in the current energy supply system in the framework of energy hub models will lead to increased autonomy, peak shaving, and emission reductions.

Renewable fuels such as hydrogen and ethanol can be obtained from biomass. In this regard, a model for planning the conversion of biomass to hydrogen is presented in [14] to minimize the annual cost of energy. A framework for modeling of the fuel cell, electrolyzer, and hydrogen tanks as ESS in the content of smart grid and in the presence of RES can be found in [15]. Different aspects of the use of hydrogen as a clean fuel in future transportation systems are investigated in [16]. The results show that hydrogen is a promising option for using in future energy systems and emissions reduction. A review of various hydrogen production technologies from renewable sources and related issues can be found in [17]. The use of hydrogen infrastructures in the energy hub models has been investigated in [18]. In this study, the optimal planning of hydrogen infrastructures along with infrastructure such as electricity, gas, and district heating networks has been carried out in a network of interconnected energy hubs. The results indicated a higher degree of freedom in optimizing the system and improving the overall performance of the system with the presence of hydrogen infrastructure. The effects of the presence of the hydrogen distribution system in the form of a fueling station in the structure of an energy hub have been investigated in [19]. The results showed that the optimal interaction of hydrogen fuel supply system with commercial and residential energy hubs in a smart urban energy system leads to a reduction in the cost and emission of the whole system.

Despite the many benefits of using RES, so far little attention has been paid to these energy sources as inputs in energy hub models [20]. So that most of the energy hub models presented so far have used electricity and natural gas networks as their main inputs. The most commonly used renewable sources are the wind and solar power which can be found in 20% of the energy hub models [20]. However, the use of other renewable energies, especially biomass and clean fuels such as hydrogen is very limited. The energy hub models in the future should move towards modeling sustainable energy systems. Using fossil-fuel-based energy distribution networks with many problems in their structure cannot provide a comprehensive model of future sustainable energy systems. There is a great potential for studying the effects of renewable sources in the framework of energy hub models. Therefore, energy hub models require the use of RES and the integration of these resources to meet the demand for various renewable energy systems in the future.

2.3 Impact of ESS on the Performance of EHs

As discussed in the previous section, energy systems around the world need to move towards renewable energy systems to achieve sustainable energy systems. However, one of the main problems of RES is the intermittent nature and unpredictable power generation. Consequently, in renewable systems, production control is not easy to adapt to the pattern of consumption. One of the main solutions to this problem is the use of ESS, which facilitates the integration of RES. ESS stores the energy when it is not needed and provides energy when it is needed. Using ESS in energy systems will increase system efficiency, reduce operating system costs, reduce the size of production and transmission systems, reduce fossil fuel consumption, and reduce emissions [21]. However, in addition to facilitating the integration of RES, storage systems can have various applications in the energy systems which are discussed in the following sections.

2.3.1 The Ultimate Goal of Using ESS

ESS has various applications in energy systems due to its various types. Categories of energy storage systems and various technologies are presented in Fig. 2.1.

Fig. 2.1
figure 1

Classification of EES technologies

Determining the proper storage system for the energy system under planning requires a complete understanding of different energy storage technologies. Various indicators can influence the choice of ESS for an energy system. These include capacity, initial cost, efficiency, lifetime, storage capacity, maturity, charging time, response time, and storage loss. Comparison and investigation of various storage technologies from the viewpoint of the above indicators can be found in [22, 23]. After recognizing the characteristics of different ESS, it is essential to determine its ultimate goal and purpose of using ESS in the energy system. Different objectives for using ESS in energy systems can be categorized into three categories [22]:

  • Facilitating the integration of RES and improving system reliability [21].

  • Improving system resilience and providing ancillary services.

  • Increasing system flexibility and moving towards smart energy systems.

On the production side, ESS can be used to improve the pattern of RES production and align it with demand behavior. ESS can be used to provide ancillary services to the network and increase its stability. On the consumption side, ESS can be used as DER to meet the needs of subscribers and facilitate their participation in demand-side management (DSM) programs. ESS can be operated for increasing the benefit of the storage owner (merchant storage) [24].

2.3.1.1 Facilitating the Integration of RES and Improving System Reliability

The most known application of ESS can be considered as solving the problem of integration of RES. The power generated by RES varies in different times and places. On the other hand, the pattern of production of these resources may vary with the pattern of consumption. For example, in a PV system used to provide power to residential houses, peak power production occurs during midday hours, while the peak demand of the residential consumers usually occurs in the early hours of the night. Therefore, ESS can be used to store additional power and use it at peak hours for the production and consumption balance. Using ESS in an isolated system leads to increased reliability and facilitates the use of RES in these systems. In the grid-connected mode, using ESS leads to tracking the pricing pattern in the energy market and reducing system operating costs. Various ESS applications in power systems with emphasis on RES integration have been discussed in [25] and it has been proved that RES in the presence of ESS become controllable and dispensable sources. Examining the appropriate ESSs for wind power integration, as well as issues related to size determination and control systems, can be found in [23]. A survey in Europe was conducted in [26] to achieve a 100% renewable energy system focusing on the effects of storage systems. In this study, data from Germany were used to study solar and wind resources. The results showed that only solar and wind resources could supply 50% of Germany’s electricity demand, and with the addition of ESS, this would increase by 80%.

Another important argument is the increasing of the system reliability in the presence of ESS. In power grid, the presence of spinning reserve can result in an appropriate response if an imbalance between production and demand is generated. Nevertheless, in off-grid systems, due to the limitations in the capacity of energy production and conversion systems, there is always no way to benefit from such a spinning reserve. In these types of systems, the ESS can be used to respond to imbalances in the system and stabilizing the system [27]. An imbalance in energy systems occurs for two reasons: the sudden drop in production or the sudden rise in demand. In systems that are separate from the network as well as in systems where the share of RES is high, this imbalance can have a huge impact on the reliability of the system. In these systems, the use of ESS is very important for responding to sudden changes in production or demand. Therefore, consideration of factors such as response times and ESS ramp rates for such purposes should be carefully checked.

In summary, the first goal of using ESS in energy systems is to improve the performance of RES and facilitate integration in order to increase the reliability of the system and create a balance between production and demand in renewable energy systems and so renewable energy hubs.

2.3.1.2 Improving System Resilience and Providing Ancillary Services

In power grid and more generally in energy systems, ESS can be used to increase system stability. In this case, ESS is used to reduce uncertainties, improve power quality, provide ancillary services to the network, and improve its conditions. Some of the applications of ESS for this purpose are frequency regulation, spinning reserve, voltage regulation, network inertia, volatility reduction, black starter energy supply, network synchronization, direct voltage supply in fault conditions, and equipment capacity optimization. In addition, the use of ESS for demand shifting in different periods of energy prices will lead to peak shaving and smoother demand curve. This will reduce the cost of production and transmission of electricity for the power grid, as well as improve its stability in peak hours. Further discussions in this area can be found in [28].

2.3.1.3 Increasing System Flexibility and Moving Towards Smart Energy Systems

The third objective for using ESS is to focus on their applications on demand side. Installing ESS on the consumer side, in addition to providing consumer energy, enables their active participation in DSM programs and benefits from the smart grid advantages. The effects of the final consumer storage systems in the content of the smart grid in the presence of RES and demand response (DR) programs have been investigated in [29]. The results show that the presence of ESS leads to better tracking of energy prices, increased productivity, and improved performance of other system equipment, especially distributed generation (DG) sources such as CHP. Thus, it can be said that ESS in the smart grid content can lead to a balance between production and energy consumption, smoothing the consumption curve, benefiting from the advantages of DG especially RES, and to improve the overall system performance and increasing its productivity.

One of the most promising smart technologies that have recently been considered as potential storage system is plug-in electric vehicle (PEV). These vehicles are mainly on the consumer side and have the ability for bi-directional power transfer with the network. The advanced technology used in the batteries of these vehicles has increased their charging and discharge rates. This has caused their potential applications in providing network-side services such as the spinning reserve, frequency regulation, and network stability. However, one vehicle alone cannot provide such a service, because participation in services such as frequency regulation requires high power capacity and fast dynamic response. So, as a rule, a large number of these vehicles are controlled centrally by the aggregators, so that, with the optimum control of the charge and discharge of these vehicles, in addition to lowering the costs of subscribers, they can provide ancillary services to the network [30]. In a study to optimize PEV charging program in the residential micro grid, three different technologies used in the battery of PEVs were investigated in presence of RES [31]. The results showed that optimal control of PEV leads to its successful operation for peak shaving purposes.

In general, we can say that the presence of ESS on the demand side can provide the possibility to benefit from the advantages of the smart grid. In some cases, such as PEV, with the coordinated control of the storages of these vehicles, in addition to meeting requests and reducing the cost of owners of these vehicles, they can be used as an energy storage system for the entire system and for realizing the concept of the smart grid.

2.3.2 Optimal Scheduling of ESS in EHs

When the main purpose of the ESS application was identified, then the optimal planning is important in the next step. At this stage, the goal is to determine the appropriate size for the storage system, which includes items such as power capacity and should be selected based on various parameters. Various parameters such as resource capacity, the pattern of consumption, climatic conditions, etc. affect the proper selection of ESS. Various parameters such as resource capacity, the pattern of consumption, climatic conditions, etc. affect the proper size selection of ESS. In the hub energy models, the type of connection and ESS installation location must also be carefully checked. In the energy hub, ESS can be installed at the place of production or purchase from the network and/or consumption side, so that the energy carrier can be stored on the input side, or after being transformed into a qualified energy carrier be stored at the demand. The choice of this installation location should be based on the desired indicators in the objective function and make the maximum controllability for ESS.

Storage systems can also be installed or controlled in a distributed or aggregated manner [32]. In distributed mode, each storage system is individually connected to the system and controlled, but in the aggregated scheme, a large group of storages is managed by a central control system. Therefore, the choice of an appropriate control strategy for ESS should also be considered. To design a charging and discharging controller for ESS, there are a lot of things to consider, including technical constraints, resource capacity or forecasting of production capacity in RES resources, energy pricing and market conditions, patterns of consumption, climatic conditions, and so on [33]. A model is presented in [34] to optimize the performance of a hybrid renewable energy system with a combination of a wind turbine, diesel and biomass generators in the presence of ESS. The presence of diesel generator with low inertia and variations in wind power production leads to voltage and frequency disturbances in this system. The results indicate that the use of ESS along with a suitable controller in the short term is essential for maintaining the system’s stability and power quality, and in the long term, it will improve system performance and smooth the demand curve. Given the little work that has been done on ESS control systems in the energy hub, and this fact the models presented so far have used a simple charging strategies, there is a good potential for designing and studying the effects of different control strategies on the optimal performance of the energy hubs.

2.3.3 ESS Performance in EHs

This section reviews the recent research done on the application of ESS in multi-energy systems and energy hubs. The authors in [35] examined the effects of the thermal storage size on the performance of a multi-energy system for generating electricity, heat, and cooling in the presence of RES. The results of this study showed that the use of thermal storage leads to optimization of equipment capacity (reducing the need for production of heat and reducing boiler capacity), reducing primary energy consumption and increasing system efficiency. Feasibility study of pit thermal storage, to capture the waste heat produced in a biomass poly-generation system, with district heating and cooling networks in residential buildings is done in [36]. The results indicate that pit storage is a suitable method for combination with a biomass power plant which increases the annual efficiency of the system. The effects of adding a pump storage system to the energy system of a touristic resort, a system for supplying electricity, heat, and water, have been investigated in [37]. The results indicate that adding new storage system will reduce the discharge power of the available battery, increase its lifetime, and reduce system’s costs. In another study, the effects of ESS and RES in a combined cooling, heating and power (CCHP) production system have been investigated in [38]. In this study, it has been shown that increasing the contribution of RES to electricity production reduces the need for heat generation by CCHP and directly affects the capacity of the thermal storage and reduces its capacity. The results indicate that RES and ESS have interactions on each other, even if they do not have a direct connection. Same authors have optimized the performance of a system for supplying electricity, heat, and cooling, taking into account different storage combinations in [21]. The results of the study of the effects of different storage systems have shown that the use of thermal storage along with CHP leads to a decrease in the dependence of the system on the main grid and an increase in power generated by CHP. Optimal design and operation of advance compressed air energy storage and air source heat pumps in CCHP systems is studied in [39]. Impact of battery energy storage system on operation of renewable energy based CCHP system is studied in [40]. The effect of thermal storage on a poly-generation system in the presence of a ground source heat pump has been investigated in [41]. In the designed system, electricity demand is purchased directly from the grid, the electricity produced by the CHP is consumed by the heat pump, and the excess heat generated by the heat pump is stored in the thermal storage. This combination allows the thermal storage to react to changes in the price of electricity and acts as an electrical storage for the system, while the initial cost of a thermal storage is much lower than an electrical storage. As a result, with this combination, the use of thermal storage leads to a demand shift to off-peak hours, reduces the capacity of the equipment, and reduces operating costs of the system.

Due to the various features and applications of ESS, an optimal combination of storage systems can be used to achieve the desired result or to meet different goals in a system. The idea of combining different storage systems with their application can be found in [22]. In this work, a diagram of possible combinations of different ESS is presented to minimize costs considering technical constraints. Considering the complementary features of various storage systems and considering the design and optimal management of hybrid storage systems have been done in [42].

In the energy hub models, as previously mentioned, ESS can be embedded in different places and have different effects. The impact of thermal energy market on operation of energy hub with heat and electrical storage is studied in [43]. The effects of various ESS such as electrical, gas, and heat storages from the perspective of operating costs on the performance of the energy hub are investigated in [44]. Also, the effect of different parameters such as the horizon of prediction and ESS size on the optimal performance of the energy hub has been studied in [45]. The results of this study showed that, in addition to the size of the ESS which affects system costs, an increase in simulation horizons could also reduce system costs, and even its impact can be more than increasing storage size. Therefore, in modeling, there should be a balance between increasing the computational time due to increased forecast horizons as well as the size of the storage system in order to achieve optimal performance and cost of the system.

As discussed, the energy storage system is one of the main systems in the energy hub, but unfortunately, so far, little research has been done on the effects of this system and its optimal control in the framework of energy hub models. Optimal planning and placement, as well as designing an appropriate control strategy, are potential fields for studying ESS in energy hubs that require more research and studies. Energy hub models provide the ability to use different ESSs and even different combinations of them, which could be the subject of future research in this area.

2.4 Case Studies

In this section, the performance of RES and ESS in the optimal energy hub management problem is studied by modeling an energy hub and evaluating numerical results. For this purpose, a complete model of the energy hub is used which has different inputs, converters, storages, and outputs to meet different demands. A schematic representation of the studied energy hub can be seen in Fig. 2.2. In this model of the energy hub, the wind turbine is used as a source of renewable energy production. This energy hub is powered by electricity and natural gas networks. Transformer, converters, CHP, and boiler have been used to convert various energy carriers. Electrical and thermal storages are also used as energy storage systems. On demand side, given the usual demands for energy systems, electricity, heat, and natural gas demands are considered for this energy hub model.

Fig. 2.2
figure 2

Schematic representation of the proposed energy hub

2.4.1 Energy Hub Modeling

In the energy hub, various objective functions can be considered. The proposed objective function is formulated based on the cost of purchasing energy (electricity and natural gas), electricity sales to the grid, the cost of charging and discharging electrical and thermal storages, emission costs and reliability indicators. The objective function is formulated in a deterministic environment of wind speed, demand, and hourly price of the electricity market. This objective function is optimized to minimize operational costs in a one-day time horizon subject to different constraints. The objective function of the optimal management problem of the proposed energy hub can be considered as follows:

$$ {\displaystyle \begin{array}{l}\operatorname{minimize}\\ {}\mathrm{TC}=\sum \limits_{t=1}^{24}\left[{\pi_e}^N(t){P_e}^N(t)\right]+\left[{\pi_e}^W{P_e}^W(t)\right]\\[3pt] {}+\left[{\pi_g}^N{P_g}^N(t)\right]+\left[{\pi_e}^S\left({P_e}^{\mathrm{ch}}(t)+{P_e}^{\mathrm{dis}}(t)\right)\right]\\[3pt] {}+\left[{\pi_h}^S\left({P_h}^{\mathrm{ch}}(t)+{P_h}^{\mathrm{dis}}(t)\right)\right]+\left[{\pi_e}^{\mathrm{ENS}}{P_e}^{\mathrm{ENS}}(t)\right]+\left[{\pi_h}^{\mathrm{ENS}}{P_h}^{\mathrm{ENS}}(t)\right]\\[3pt] {}+\left[\sum \limits_{t=1}^{24}\sum \limits_{\mathrm{em}=1}^3{\pi}_{\mathrm{em}}\left({{\mathrm{EF}}_{\mathrm{em}}}^N{P_e}^N(t)+{{\mathrm{EF}}_{\mathrm{em}}}^{\mathrm{NCHP}}{P_g}^{\mathrm{NCHP}}(t)+{{\mathrm{EF}}_{\mathrm{em}}}^{\mathrm{NB}}{P_g}^{\mathrm{NB}}(t)\right)\right]\end{array}} $$
(2.1)

Subject to

$$ {\displaystyle \begin{array}{l}{P}_{\mathrm{ed}}(t)=\left[{A}^N{\eta}_T{P_e}^N(t)\right]+\left[{A}^{\mathrm{CHP}}{\eta}_{\mathrm{echp}}{P_g}^{\mathrm{NCHP}}(t)\right]\\[5pt] {}+\left[{A}^W{\eta}_C{P_e}^W(t)\right]+\left[{P_e}^{\mathrm{dis}}(t)-{P_e}^{\mathrm{ch}}(t)\right]\\[5pt] {}+\left[{P_e}^{\mathrm{shdo}}(t)-{P_e}^{\mathrm{shup}}(t)\right]+\left[{P_e}^{\mathrm{ENS}}(t)\right]\end{array}} $$
(2.2)
$$ {\displaystyle \begin{array}{l}{P}_{\mathrm{hd}}(t)=\left[{A}^{\mathrm{CHP}}{\eta}_{\mathrm{hchp}}{P_g}^{\mathrm{NCHP}}(t)\right]+\left[{\eta}_B{P_g}^{\mathrm{NB}}(t)\right]\\[4pt] {}+\left[{P_h}^{\mathrm{dis}}(t)-{P_h}^{\mathrm{ch}}(t)\right]+\left[{P_h}^{\mathrm{ENS}}(t)\right]\end{array}} $$
(2.3)
$$ {P}_{\mathrm{gd}}(t)=\left[{P_g}^N(t)\right]-\left[{P_g}^{\mathrm{NCHP}}(t)\right]-\left[{P_g}^{\mathrm{NB}}(t)\right] $$
(2.4)
$$ -{P_e}^{N\max}\le {P_e}^N(t)\le {P_e}^{N\max } $$
(2.5)
$$ 0\le {P_g}^N(t)\le {P_g}^{N\max } $$
(2.6)
$$ {\eta}_T{P_e}^N(t)\le {P}^T $$
(2.7)
$$ {\eta}_{\mathrm{echp}}{P_g}^{\mathrm{NCHP}}(t)\le {P}^{\mathrm{CHP}} $$
(2.8)
$$ {\eta}_B{P_g}^{\mathrm{NB}}(t)\le {P}^B $$
(2.9)
$$ {P_e}^S(t)={P_e}^S\left(t-1\right)+{\eta_e}^{\mathrm{ch}}{P_e}^{\mathrm{ch}}(t)-\frac{{P_e}^{\mathrm{dis}}(t)}{{\eta_e}^{\mathrm{dis}}}-{P_e}^{\mathrm{loss}}(t) $$
(2.10)
$$ {P_e}^{\mathrm{loss}}(t)={\alpha_e}^{\mathrm{loss}}{P_e}^S(t) $$
(2.11)
$$ {\alpha_e}^{\mathrm{min}}{P_e}^{\mathrm{SC}}\le {P_e}^S(t)\le {\alpha_e}^{\mathrm{max}}{P_e}^{\mathrm{SC}} $$
(2.12)
$$ {\alpha_e}^{\mathrm{min}}{P_e}^{\mathrm{SC}}{I_e}^{\mathrm{ch}}(t)\le {P_e}^{\mathrm{ch}}(t)\le {\alpha_e}^{\mathrm{max}}{P_e}^{\mathrm{SC}}{I_e}^{\mathrm{ch}}(t) $$
(2.13)
$$ {\alpha_e}^{\mathrm{min}}{P_e}^{\mathrm{SC}}{I_e}^{\mathrm{dis}}(t)\le {P_e}^{\mathrm{dis}}(t)\le {\alpha_e}^{\mathrm{max}}{P_e}^{\mathrm{SC}}{I_e}^{\mathrm{dis}}(t) $$
(2.14)
$$ 0\le {I_e}^{\mathrm{ch}}(t)+{I_e}^{\mathrm{dis}}(t)\le 1 $$
(2.15)
$$ {P_h}^S(t)={P_h}^S\left(t-1\right)+{\eta_h}^{\mathrm{ch}}{P_h}^{\mathrm{ch}}(t)-\frac{{P_h}^{\mathrm{dis}}(t)}{{\eta_h}^{\mathrm{dis}}}-{P_h}^{\mathrm{loss}}(t) $$
(2.16)
$$ {P_h}^{\mathrm{loss}}(t)={\alpha_h}^{\mathrm{loss}}{P_h}^S(t) $$
(2.17)
$$ {\alpha_h}^{\mathrm{min}}{P_h}^{\mathrm{SC}}\le {P_h}^S(t)\le {\alpha_h}^{\mathrm{max}}{P_h}^{\mathrm{SC}} $$
(2.18)
$$ {\alpha_h}^{\mathrm{min}}{P_h}^{\mathrm{SC}}\frac{1}{{\eta_h}^{\mathrm{ch}}}{I_h}^{\mathrm{ch}}(t)\le {P_h}^{\mathrm{ch}}(t)\le {\alpha_h}^{\mathrm{max}}{P_h}^{\mathrm{SC}}\frac{1}{{\eta_h}^{\mathrm{ch}}}{I_h}^{\mathrm{ch}}(t) $$
(2.19)
$$ {\alpha_h}^{\mathrm{min}}{P_h}^{\mathrm{SC}}{\eta_h}^{\mathrm{dis}}{I_h}^{\mathrm{dis}}(t)\le {P_h}^{\mathrm{dis}}(t)\le {\alpha_h}^{\mathrm{max}}{P_h}^{\mathrm{SC}}{\eta_h}^{\mathrm{dis}}{I_h}^{\mathrm{dis}} $$
(2.20)
$$ 0\le {I_h}^{\mathrm{ch}}(t)+{I_h}^{\mathrm{dis}}(t)\le 1 $$
(2.21)

In this objective function, the first term is related to the value of power exchange with the electricity network. The second term is the cost of providing electric power from the wind turbine. The third term also refers to the cost of purchasing natural gas from the network. Fourth and fifth terms are included in order to take into account the operating costs of charging and discharging storages. Fifth and sixth terms are related to the electrical and thermal energies not supplied cost. And finally, the last term is related to environmental costs of different greenhouse gas emissions. In the above relations, Eqs. (2.2)–(2.4) are related to power equilibrium, so that at each step of the simulation demand is equal to the total energy generation.

Equations (2.5) and (2.6) are defined to take into account the technical and contractual limitations of gas and electricity networks and assume a maximum amount of the power exchanged with these networks. Hub components are installed with limited production capacity and for considering this maximum capacity for the transformer, CHP and boiler, Eqs. (2.7)–(2.9) are defined respectively. Equations (2.10)–(2.15) are related to the operational constraints of electrical storage. Equation (2.10) refers to the state of charge of storage. The content of the storage at any time is a function of the storage content in the previous step, as well as the amount of charge, the amount of discharge, and the amount of storage loss in that time step. According to (2.11), the amount of electrical storage losses is defined as a certain percentage of its charge content. The allowed amount of storage content in each step is specified by (2.12). Binary variables I e ch(t) and I e dis(t) are defined in such a way that storage charging and discharging do not occur simultaneously. So at any time step, only one of the binary variables can have a value of 1. This constraint is applied through (2.15). Thermal storage constraints are defined in the same way in (2.16)–(2.21).

2.4.2 Simulation Results

Five cases are considered to evaluate the effects and roles of RES and ESS in the energy hub operation. The case study results are compared and analyzed based on operational cost, emission, and reliability. These five cases are categorized in Table 2.1. In case 1, the energy hub also has CHP and boiler in addition to the possibility of purchasing energy from electricity and gas networks. This case is considered as the base case of the model. In case 2, the electrical storage (ES) is added to the base case. Case 3 uses a heat storage (HS) instead of an electrical storage to balance production and demand. However, the case 4 energy hub uses an on-site wind turbine (WT) for clean electric power generation. Finally, a combination of electrical and thermal storages alongside wind turbine and CHP is evaluated in case 5. The demand of energy hub for electricity, heat, and natural gas can be seen in Fig. 2.3. Also, hourly electricity prices and hourly wind speed are shown in Figs. 2.4 and 2.5, respectively.

Table 2.1 Defined cases for the energy hub optimal operation
Fig. 2.3
figure 3

The hourly electricity, heat, and natural gas demand

Fig. 2.4
figure 4

The hourly electricity price

Fig. 2.5
figure 5

The hourly wind speed

The values of the input parameters and other assumptions for the optimal energy hub management problem can be found in Table 2.2.

Table 2.2 Energy hub input data and parameters

The proposed optimal management problem for energy hub is an MILP model that has been solved in the GAMS software using the CPLEX solving algorithm. Due to the linearity of the objective function and the convexity of the solution space, the solutions obtained from the problem are the optimal global solutions. These results are discussed for different cases in the following sections.

2.4.2.1 Case 1

In this case, CHP is the main supplier of electrical and thermal demand, and electricity and boiler networks are considered as a backup system for CHP. If demand is not fully met by CHP, the remainder of the demand will be supplied from the grid. In the case of heat demand, the boiler is also responsible for the thermal power deficit. The numerical results of this case can be seen in Table 2.3.

Table 2.3 Optimal operational plan for energy hub in the first case

As shown in the table above, CHP is responsible for supplying electrical and thermal energy with maximum capacity during the day. This is due to lower gas price than electricity and the possibility of supplying heat demand simultaneously. In cases where the demand increases and the CHP is unable to meet this demand, the fraction of this power is purchased from the main network, which leads to an increase in operating costs of the system. The existence of CHP in the system allows for the sale of excess electricity to the network. In the table above, the negative values for power exchanged with the network are sales of this power to the network. So, in the early hours of the day, the energy hub can earn money by selling excess electricity to the network. However, it is observed that part of the electrical demand does not come at peak times, which reduces the reliability of the energy hub. The schematic representation of the above concepts can be seen in Fig. 2.6. This figure shows how to supply the energy demand by the energy hub.

Fig. 2.6
figure 6

Supply of electricity demand by the energy hub in case 1

In the case of heat demand, 252 kW of heat demand is produced by CHP and the rest of the demand is provided by burning gas in the boiler. In this case, the current structure of energy hub in the heat demand peak hours (hours 10 and 19) is not able to provide all the demand and part of this heat demand is not provided. In this case, the energy hub faces an energy not supplied penalty and increases operating costs. The total operational cost of the energy hub, in this case, is 190,734.8 Euro cents.

2.4.2.2 Case 2

In this case, an electrical storage is added to the system so that during the excess electricity production period, some of this additional power is stored and used at times required to meet the demand. The numerical results of this case are summarized in Table 2.4. In this case, the electrical storage is charged at times when the energy price is low and it provides part of the electrical demand at peak hours. How to exchange electrical energy in the energy hub in the presence of an electrical storage can be seen in Fig. 2.7.

Table 2.4 Optimal operational plan for energy hub in case 2
Fig. 2.7
figure 7

Supply of electricity demand by the energy hub in case 2

The existence of the electrical storage leads to a reduction in the electrical energy sold to the network from 519.3 kWh in the base case to 417.7 kWh in this case. The reason for this can be attributed to spending some of that energy on charging electrical storage at low-cost energy hours. So that even the charging of the storage at 4:00 am leads to the purchase of energy from the network. However, the purchase of energy occurs in the hours when energy price is low. The addition of the electrical storage device results in a significant reduction in the amount of electrical energy not supplied, and only a small amount of electrical energy is not provided at 7:00 pm. The most discharge amount occurs at an hour when the price of electrical energy is at its highest (6:00 pm). This causes the electrical storage to have the greatest impact in reducing the operating costs of the energy hub. In the thermal behavior of the energy hub, there is no change and its operational plan is similar to the base case for thermal demand. The set of these factors will reduce the total operating cost of the energy hub by 189,930.7 cents. Therefore, it can be said that addition of an electrical storage in addition to reducing operating costs leads to increase of reliability of the system in the field of supply of electrical demand.

2.4.2.3 Case 3

In this case, in order to compare the effectiveness of the heat storage in the optimal performance of the energy hub, a thermal storage is added to the base state. Figure 2.8 shows how to supply the heat demand by the energy hub in this case.

Fig. 2.8
figure 8

Supply of electricity demand by the energy hub in case 3

By adding a thermal storage, some thermal energy is stored in the non-peak hours of thermal demand in this storage and it is used in peak hours. Charging the heat storage in the first hour leads to an increase in gas purchases from the grid and an increase in boiler production compared to the base case. The same thing can be seen at 6:00 pm. An increase in the state of charge of the heat storage at 6:00 pm will result in the heat demand deficit being compensated at 7:00 pm (peak hour), and this demand will be fully met at this hour. This will increase the reliability of the system. In terms of cost, the total operating cost of the energy hub, in this case, is 189,059.6 cents, which is lower than both previous cases. If we consider that the value of each kilowatt-hour of electrical and thermal energy for the consumer be same, it can be said that the thermal storage system creates a greater reduction in the amount of unmet energy and creates better conditions for reliability than electrical storage. The electrical operation plan of the energy hub, in this case, is similar to the two previous cases and has not changed. The performance of various components of the energy hub in each time step can be seen in Table 2.5 separately.

Table 2.5 Optimal operational plan for energy hub in case 3

2.4.2.4 Case 4

In this case, the energy hub uses wind turbine as a renewable energy source, in addition to CHP, this technology will also be used to generate electrical power. The effects of adding a wind turbine to the optimal operational program of energy hub can be seen in Table 2.6.

Table 2.6 Optimal operational plan for energy hub in case 4

By adding a wind turbine to the energy hub, local power supplies can be provided from RES and energy hub will be able to sell more energy to the grid. How to supply electricity demand and exchange energy with the network in the presence of a wind turbine is shown in Fig. 2.9. As can be seen, unlike previous cases that energy sales were only made in the early hours of the day, this scenario would allow the sale of energy during the day and even in the afternoon, when the price of electricity in the market is higher than the early hours of the day. As a result, energy sales are higher and also at higher prices, which results in higher energy hub revenues. The amount of energy sales in this scenario reaches 864.1 kWh, which is significantly higher than previous ones. On the other hand, the amount of electricity purchased in this scenario is 2979.1 kWh, which is less than half that for the base case. The combination of these factors leads to a reduction in the operating costs of the energy hub to a value of 165,831.83 cents. On the other hand, with the addition of a wind turbine, it is possible to provide all the electricity demand, and the reliability of the energy hub is remarkably improved. There is no change in the optimal energy hub plan for the supply of thermal demand. In total, it can be said that the addition of the wind turbine results in better performance of energy hub than the previous cases. Therefore, in the next case, the effect of adding storage systems in the presence of wind turbine is investigated.

Fig. 2.9
figure 9

Supply of electricity demand by the energy hub in case 4

2.4.2.5 Case 5

A combination of the wind turbine, thermal and electrical storages is added to the base case to study the effect of this structure on the optimal performance of the energy hub. The numerical results of this case can be found in Table 2.7. Energy hub primarily uses CHP and wind turbine to provide electrical demand. In times of capacity shortage, this amount is purchased from the power grid. The electrical storage is responsible for the coordination of production with the pattern of consumption, and especially the price pattern of the electricity market. At hour that the lowest electricity prices and the lowest electricity demand occur (4:00 am), this storage is charged and at hour, which has the highest rates for electricity price (6:00 pm), it is discharged and in addition to compensating the electricity generation deficit, provides the possibility of electricity sales to the network in this hour. This leads to more revenue and lower operating costs. With this operational plan, all electrical demand will be provided at the lowest operating cost. Such an operation is also used to provide heat demand and much of this demand is provided with a minimum operating cost. Therefore, operating costs of the energy hub are expected to decrease in this scenario. The amount, in this case, is 163,870.2 cents, which is the least amount among all examined cases. So, case 5 has the best performance in terms of operational costs and reliability.

Table 2.7 Optimal operational plan for energy hub in case 5

2.5 Conclusion

In this chapter, the effects and the role of RES and ESS have been evaluated on the performance of the energy hub. Increasing demand for energy, along with limited fossil fuel storage and growing concern about the environmental problems caused by fossil fuel consumption, increases the need to use RES such as the wind and solar and increases their penetration in the energy systems. The main inputs of the energy hubs models are electrical and gas networks that are mainly based on the use of fossil fuel energies. So, future energy hub models should move towards using RES to generate energy and supply different demands of the energy hub. Increasing the share of these resources, especially in the form of DES, and the unpredictable nature of the production of these resources can lead to imbalances in supply and demand of energy and reduce the stability of the system. Utilization of ESS for energy hubs can reduce the effects of the integration of renewable sources and increase the reliability of the system. ESS can be used to provide ancillary services to the network and improve the quality of power and reduce system stability problems, as well as intelligent demand-side performance and the goals of demand-side management programs. In this chapter, in order to numerically investigate the effects of RES and ESS, energy hub has been modeled in the presence of wind turbine and electrical and thermal storages and numerical results have been discussed. The results indicate that adding RES will reduce the dependence of the energy hub on the fossil fuel networks and increase the sales of renewable energy to these networks, thereby reducing the operating costs of the energy hub. The use of ESS will increase the reliability of the system by reducing the amount of energy not supplied, as well as increasing the flexibility of the energy hub in dealing with different pricing plans for energy.