From a012344ca70c263d5d5cf7a17f3e5e1c48b67548 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonas=20H=C3=B6rsch?= Date: Fri, 26 Oct 2018 10:29:44 +0200 Subject: [PATCH] prepare_network: Pass Nyears to set_line_volume_limit Sets the transmission capital costs in the optimum line_volume case properly for multi-year optimizations. --- scripts/prepare_network.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/prepare_network.py b/scripts/prepare_network.py index 129ca04f..585a8a73 100644 --- a/scripts/prepare_network.py +++ b/scripts/prepare_network.py @@ -41,7 +41,7 @@ def set_line_s_max_pu(n): n.links.loc[dc_b, 'p_max_pu'] = s_max_pu n.links.loc[dc_b, 'p_min_pu'] = - s_max_pu -def set_line_volume_limit(n, lv): +def set_line_volume_limit(n, lv, Nyears=1.): links_dc_b = n.links.carrier == 'DC' if np.isinf(lv): @@ -123,6 +123,6 @@ if __name__ == "__main__": # if 'Ep' in opts: # add_emission_prices(n) - set_line_volume_limit(n, float(snakemake.wildcards.lv)) + set_line_volume_limit(n, float(snakemake.wildcards.lv), Nyears) n.export_to_netcdf(snakemake.output[0])