*3.2. Primary Energy Factors*

Primary energy (PE) is a concept used to compare different kinds of energy sources, but the scale used in the calculations is relevant [4,36]. In this research, the primary energy factors published by the Spanish Government in 2016 [37] are used to determine the building performance required for legalization. Corresponding values are summarized in Table 1 for both utilities considered, namely, the national electrical grid and the natural gas supply facility. The PE factor depends on the energy carrier and relates the primary energy consumed to provide one kWh to the end-user, in this case the final energy consumed by the residential users. PE factors are also divided into renewable and non-renewable. As can be observed in Table 1, renewable factors are smaller that non-renewable ones, but they are values above zero. This means that a certain amount of energy is required to serve the renewable source, i.e., maintenance tasks.

**Table 1.** Primary energy factors and CO2 conversion factor established by the Spanish Government for the electrical and natural gas utilities.


Not only the PE, but also the CO2 emissions will be compared to determine the benefits of the cogeneration technologies. The PE reductions are measured from the initial situation, and they can be evaluated using the equation:

$$\text{PE} = \left( \mathbf{Q}\_{\text{D}} \cdot \mathbf{f}\_{\text{g}}^{\text{PE}} + \mathbf{W}\_{\text{D}} \cdot \mathbf{f}\_{\text{e}}^{\text{PE}} \right), \tag{5}$$

where f PE stands for the primary energy factor (subscripts g and e represent gas and electricity, respectively), QD is the total thermal energy demanded and WD stands for the total electrical energy. The PE consumption with the use of a CHP system will depend on the technology. A general case is shown in Equation (6):

$$\text{PE}\_{\text{CHP}} = \left( \left( \text{Q}\_{\text{fuel}} + \text{Q}\_{\text{backup}} \right) \cdot \text{f}\_{\text{g}}^{\text{PE}} + \text{W}\_{\text{Imp}} \cdot \text{f}\_{\text{e}}^{\text{PE}} \right) - \text{W}\_{\text{Exp}} \cdot \text{f}\_{\text{e}}^{\text{PE}} \,\tag{6}$$

where exported energy (WExp) is considered as a primary energy decrement due to its decreasing effect in primary energy consumption. When hydrogen or any other fuel obtained from renewable energy sources is used, the gas terms (Qfuel and Qbackup) in Equation (6) can be neglected. Carbon emissions can be calculated using the same equations, just replacing the primary energy factors with the CO2 emission factor (fCO2 ).

$$\text{CO}\_2 = \left(\text{Q}\_\text{D} \cdot \text{f}\_\text{g}^{\text{CO}\_2} + \text{W}\_\text{D} \cdot \text{f}\_\text{g}^{\text{CO}\_2}\right) \text{ and} \tag{7}$$

$$\rm{CO}\_{2}^{\rm{CHP}} = \left( \left( \rm{Q}\_{\rm{fuel}} + \rm{Q}\_{\rm{backup}} \right) \cdot \rm{f}\_{\rm{g}}^{\rm{CO}\_{2}} + \rm{W}\_{\rm{Imp}} \cdot \rm{f}\_{\rm{e}}^{\rm{CO}\_{2}} \right) - \rm{W}\_{\rm{Exp}} \cdot \rm{f}\_{\rm{e}}^{\rm{CO}\_{2}}.\tag{8}$$
