-
Notifications
You must be signed in to change notification settings - Fork 361
Description
Version Checks (indicate both or one)
-
I have confirmed this bug exists on the lastest release of PyPSA-Eur.
-
I have confirmed this bug exists on the current
masterbranch of PyPSA-Eur.
Issue Description
This is really a pypsa issue which interacts with the pypsa-eur default settings.
As outlined in PyPSA/PyPSA#1495 the current implementation of AC line losses in pypsa-eur start with zero losses as long as p < s_nom/2*n_tangents. In Pypsa-Eur default is n_tangents=2, and hence flows smaller than 0.25 of s_nom would be lossless.
Now what creates an issue, is that for extendable lines s_nom gets replaced with s_nom_max. If using e.g. v1.5 as line limit, i.e. s_nom_max = 1.5*s_nom this implies that flows smaller than 0.375 are lossless.
However, with the default setting of pypsa-eur, the line limit is vopt and in this case s_nom_max is determined as s_nom + 20000. As a consequence flows smaller than 0.25*s_nom + 5000 are lossless, which is often larger than s_nom. This implies that most lines (and most flows) are completely lossless and that the model has an incentive to expand lines to 0.25*s_nom + 5000 .
Here are two plots, of relative line flows and relative line expansion
The spike occurs at 0.25*s_nom_max. It can be seen that most flows are lossless, and that the optimal solution favors lines with a specific capacity.
Reproducible Example
snakemake all on current masterExpected Behavior
This is the behavior when using a secant based approximation of line losses PyPSA/PyPSA#1495
Caveat: The tendency of the optimal solution to lie at the breakpoints of the linear approximation of the line losses still persists, even when using the improved line formulation. This can be seen by rescaling the line flows with sqrt(r_pu_eff) when using the secant formulation of losses.
However the dependency on s_nom_max is no longer there, and the approximation error of the secant formulation is smallest at exactly these breakpoints.
The objective values increases by about 1% when losses are fully considered