diff --git a/doc/release_notes.rst b/doc/release_notes.rst index 709e20a57..ddaf257e7 100644 --- a/doc/release_notes.rst +++ b/doc/release_notes.rst @@ -18,8 +18,10 @@ E.g. if a new rule becomes available describe how to use it `snakemake -j1 run_t **Minor Changes and bug-fixing** -* Minor bug-fixing for GADM_ID format naming. `PR #980 `__ +* Keep data on the original voltage value when rebasing voltages to the standard values and adjust the transmission capacity accordingly. `PR #898 `__ + +* Minor bug-fixing for GADM_ID format naming. `PR #980 `__ PyPSA-Earth 0.3.0 ================= diff --git a/scripts/base_network.py b/scripts/base_network.py index 27d9b21b0..f7fe0f623 100644 --- a/scripts/base_network.py +++ b/scripts/base_network.py @@ -451,6 +451,8 @@ def _rebase_voltage_to_config(base_network_config, voltages_config, component): config : dictionary (by snakemake) component : dataframe """ + component["v_nom_original"] = component["v_nom"] + v_min = ( base_network_config["min_voltage_rebase_voltage"] / 1000 ) # min. filtered value in dataset @@ -494,9 +496,16 @@ def base_network( lines_dc = lines[lines.tag_frequency.astype(float) == 0].copy() lines_ac = _set_electrical_parameters_lines(lines_config, voltages_config, lines_ac) + lines_ac.num_parallel = lines_ac.num_parallel * ( + lines_ac.v_nom_original / lines_ac.v_nom + ) + lines_dc = _set_electrical_parameters_dc_lines( lines_config, voltages_config, lines_dc ) + lines_dc.num_parallel = lines_dc.num_parallel * ( + lines_dc.v_nom_original / lines_dc.v_nom + ) transformers = _set_electrical_parameters_transformers( transformers_config, transformers @@ -518,7 +527,7 @@ def base_network( lines_dc = _set_electrical_parameters_links(links_config, lines_dc) # parse line information into p_nom required for converters lines_dc["p_nom"] = lines_dc.apply( - lambda x: x["v_nom"] * n.line_types.i_nom[x["type"]], + lambda x: x["v_nom_original"] * n.line_types.i_nom[x["type"]], axis=1, result_type="reduce", )