5 Electrical grid constraints
5.1 Model
The electrification of the energy system will lead to the adoption of solar photovoltaics panel (PV), heat pumps (HP), electric vehicles (EV) and other electrical technologies. All this renewable technologies can significantly alter the energy and power load profiles of buildings where they are installed. While PV systems can result in a reverse power flow in distribution feeders, potentially causing voltage violations and overloading of distribution lines. On the other hand, the use of HP and EV can increase peak electricity demand. The continued addition of these technologies may require upgrading or even complete rebuilding of existing transformer stations and reinforcement of distribution lines, leading to substantial investments for distribution system operators (DSOs) and ultimately affecting consumers’ electricity bills (Gupta et al. 2021).
5.1.1 Integration of the constraints in REHO
The electrification of the energy system will involve greater use of the electricity grid and its infrastructure. In order to obtain consistent results for the energy demand of a district, it is relevant to take into account the constraints of the power grid in REHO. The addition of the constraints allows for a greater relevance of the power imported and exported by the district, as well as the capital and operational expenditure values. These constraints are modeled by the maximum capacity of the district transformer and the maximum capacity of the district distribution lines.
In REHO, the transformer enables power exchanges between the rest of the grid and the district. The grid constraints apply to the power that can be imported or exported by the district. These constraints do not limit the internal flows within the district. In a scenario tending towards the electrification of the energy system, exchanges between buildings could be higher than the power allowed by the lines. Indeed, the distribution lines of a district are not necessarily adapted to a strong electrification of the district. To allow an optimisation closer to reality, REHO limits the maximum power of the lines by setting a maximum line capacity constraint.
To integrate the maximum capacity of a district’s transformer into REHO, insert the code shown below. The transformer maximal capacity value have to replace the variable Limit_Transfo.
= {'TransformerCapacity': pd.DataFrame([Limit_Transfo], index=['Electricity'], columns=['TransformerCapacity'])} parameters
To integrate the line constraints in REHO, they must be added in the specific parameters as shown in the code below. The line capacity maximum value have to replace the variable Limit_Line.
= pd.MultiIndex.from_tuples([("Electricity", "Building1")])
line_b1 = pd.DataFrame([Limit_Line], columns=["LineCapacity"], index=line_b1)
line_capacity = {'LineCapacity': line_capacity} parameters
5.1.2 Example of the transformer constraint on a building
In this example, a single-building optimisation was carried out to show the impact of the constraint on the maximum transformer capacity or the constraint on the maximum capacity that can be transmitted by a line. In fact, for a single building, these two constraints act in the same way.
Figure 5.1 shows the grid’s unconstrained energy profile with a hourly moving average.

Figure 5.1: Energy profiles with a hourly moving average and without grid constraints
The positive part of these graphs represent everything related to energy consumption and electricity imports, while the negative part represents the energy produced by the solar panels, their curtailment and electricity exports.
Figure 5.2 shows the energy profile with a hourly moving average and with grid constraints set at 40 [kW].
![Energy profiles with a hourly moving average and with grid constraints at 40 [kW]](results/insertCaptionToincludeHTML.png)
Figure 5.2: Energy profiles with a hourly moving average and with grid constraints at 40 [kW]
When a constraint of 40 [kW] is set, the positive part of the graph does not change because the constraint is greater than the maximum value when the electricity is imported. However, this constraint is lower than the electricity exported by this building, which forces the system to use PV capping to avoid exceeding this limit. This energy could be stored, but at current prices it’s not cost-effective to install a battery. In addition, the quantity of PV panels is almost the same as in the unconstrained case.
Figure 5.3 shows the energy profile with a hourly moving average and with grid constraints set at 25 [kW]. This limit is lower than the electricity imported by the system, which will mean a difference in the system’s installed power compared with the other two cases.
![Energy profiles with a hourly moving average and with grid constraints at 25 [kW]](results/insertCaptionToincludeHTML.png)
Figure 5.3: Energy profiles with a hourly moving average and with grid constraints at 25 [kW]
When a 25 [kW] constraint is imposed on the grid, it is possible to notice that there are fewer installed PV panels than in 5.1. Additionally, air heat pumps are replaced by geothermal heat pumps as they have a better efficiency, which reduces the electricity consumed for heat production. On the other hand, this type of heat pump is more expensive.
The constraints of the grid are of great importance in the optimisation results, as they will have an impact on the units installed. A greater constraint on the grid will force the system to choose the most efficient units. Storage devices such as electric batteries can compensate for energy needs during peaks in consumption when the PV panels cannot produce enough. Increased grid constraints will greatly increase the cost of the installation. Furthermore, as export is limited, the system will be able to sell less electricity to the grid and therefore the prosumer will be able to make less profit.
5.2 Parameters
5.2.1 Constraints of the transfomer
To determine the maximum capacity of the transformer, the following approach was employed. Initially, the maximum value of the domestic electricity consumption for a district was identified. Subsequently, we assumed that the transformers were sized based on a capacity three times higher than this maximum value. As a result, the maximum allowable value, namely the Limit_Transfo variable, was set at three times the identified maximum value.