Skip to content

Commit 9ac89e5

Browse files
authored
Merge branch 'master' into osm-raw-islands
2 parents 94affe5 + 946609e commit 9ac89e5

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

43 files changed

+4209
-387
lines changed

.gitignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,4 +79,5 @@ dev/*
7979
# ai coding tools
8080
CLAUDE.md
8181
.claude/
82-
.github/copilot-instructions.md
82+
.github/copilot-instructions.md
83+
CLAUDE.local.md

.pre-commit-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,4 +60,4 @@ repos:
6060
- repo: https://github.com/fsfe/reuse-tool
6161
rev: v6.0.0
6262
hooks:
63-
- id: reuse
63+
- id: reuse-lint-file

Snakefile

Lines changed: 74 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,12 @@ rule all:
9494
run=config["run"]["name"],
9595
**config["scenario"],
9696
),
97+
# COP profiles plots
98+
expand(
99+
RESULTS + "graphs/cop_profiles_s_{clusters}_{planning_horizons}.html",
100+
run=config["run"]["name"],
101+
**config["scenario"],
102+
),
97103
lambda w: expand(
98104
(
99105
RESULTS
@@ -143,6 +149,74 @@ rule all:
143149
run=config["run"]["name"],
144150
**config["scenario"],
145151
),
152+
# Explicitly list heat source types for temperature maps
153+
lambda w: expand(
154+
(
155+
RESULTS
156+
+ "maps/base_s_{clusters}_{opts}_{sector_opts}_{planning_horizons}-heat_source_temperature_map_river_water.html"
157+
if config_provider("plotting", "enable_heat_source_maps")(w)
158+
and "river_water"
159+
in config_provider("sector", "heat_pump_sources", "urban central")(w)
160+
else []
161+
),
162+
**config["scenario"],
163+
run=config["run"]["name"],
164+
),
165+
lambda w: expand(
166+
(
167+
RESULTS
168+
+ "maps/base_s_{clusters}_{opts}_{sector_opts}_{planning_horizons}-heat_source_temperature_map_sea_water.html"
169+
if config_provider("plotting", "enable_heat_source_maps")(w)
170+
and "sea_water"
171+
in config_provider("sector", "heat_pump_sources", "urban central")(w)
172+
else []
173+
),
174+
**config["scenario"],
175+
run=config["run"]["name"],
176+
),
177+
lambda w: expand(
178+
(
179+
RESULTS
180+
+ "maps/base_s_{clusters}_{opts}_{sector_opts}_{planning_horizons}-heat_source_temperature_map_ambient_air.html"
181+
if config_provider("plotting", "enable_heat_source_maps")(w)
182+
and "air"
183+
in config_provider("sector", "heat_pump_sources", "urban central")(w)
184+
else []
185+
),
186+
**config["scenario"],
187+
run=config["run"]["name"],
188+
),
189+
# Only river_water has energy maps
190+
lambda w: expand(
191+
(
192+
RESULTS
193+
+ "maps/base_s_{clusters}_{opts}_{sector_opts}_{planning_horizons}-heat_source_energy_map_river_water.html"
194+
if config_provider("plotting", "enable_heat_source_maps")(w)
195+
and "river_water"
196+
in config_provider("sector", "heat_pump_sources", "urban central")(w)
197+
else []
198+
),
199+
**config["scenario"],
200+
run=config["run"]["name"],
201+
),
202+
expand(
203+
RESULTS
204+
+ "graphics/balance_timeseries/s_{clusters}_{opts}_{sector_opts}_{planning_horizons}",
205+
run=config["run"]["name"],
206+
**config["scenario"],
207+
),
208+
expand(
209+
RESULTS
210+
+ "graphics/heatmap_timeseries/s_{clusters}_{opts}_{sector_opts}_{planning_horizons}",
211+
run=config["run"]["name"],
212+
**config["scenario"],
213+
),
214+
expand(
215+
RESULTS
216+
+ "graphics/interactive_bus_balance/s_{clusters}_{opts}_{sector_opts}_{planning_horizons}",
217+
run=config["run"]["name"],
218+
**config["scenario"],
219+
),
146220
default_target: True
147221

148222

config/config.default.yaml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -533,7 +533,6 @@ sector:
533533
aquifer_volumetric_heat_capacity: 2600
534534
fraction_of_aquifer_area_available: 0.2
535535
effective_screen_length: 20
536-
dh_area_buffer: 1000
537536
capex_as_fraction_of_geothermal_heat_source: 0.75
538537
recovery_factor: 0.6
539538
marginal_cost_charger: 0.035
@@ -549,10 +548,15 @@ sector:
549548
geothermal:
550549
constant_temperature_celsius: 65
551550
ignore_missing_regions: false
551+
river_water:
552+
constant_temperature_celsius: false
552553
direct_utilisation_heat_sources:
553554
- geothermal
554555
temperature_limited_stores:
555556
- ptes
557+
dh_areas:
558+
buffer: 1000
559+
handle_missing_countries: fill
556560
heat_pump_sources:
557561
urban central:
558562
- air
@@ -735,6 +739,7 @@ sector:
735739
biomass_to_methanol: true
736740
biomass_to_methanol_cc: false
737741
ammonia: true
742+
min_part_load_electrolysis: 0
738743
min_part_load_fischer_tropsch: 0.5
739744
min_part_load_methanolisation: 0.3
740745
min_part_load_methanation: 0.3

config/plotting.default.yaml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44

55
# docs in https://pypsa-eur.readthedocs.io/en/latest/configuration.html#plotting
66
plotting:
7+
enable_heat_source_maps: false
78
map:
89
boundaries: [-11, 30, 34, 71]
910
geomap_colors:
@@ -53,6 +54,8 @@ plotting:
5354
- residential rural heat
5455
- services urban decentral heat
5556
- services rural heat
57+
interactive_bus_balance:
58+
bus_name_pattern: None
5659
heatmap_timeseries:
5760
marginal_price:
5861
- AC
@@ -458,6 +461,10 @@ plotting:
458461
urban central geothermal heat pump: '#4f2144'
459462
geothermal heat pump: '#4f2144'
460463
geothermal heat direct utilisation: '#ba91b1'
464+
river_water heat: '#4bb9f2'
465+
river_water heat pump: '#4bb9f2'
466+
sea_water heat: '#0b222e'
467+
sea_water heat pump: '#0b222e'
461468
ground heat pump: '#2fb537'
462469
residential rural ground heat pump: '#4f2144'
463470
residential rural air heat pump: '#48f74f'

config/test/config.myopic.yaml

Lines changed: 14 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -40,15 +40,17 @@ sector:
4040
supplemental_heating:
4141
enable: true
4242
booster_heat_pump: true
43-
heat_pump_sources:
44-
urban central:
45-
- air
46-
- geothermal
47-
urban decentral:
48-
- air
49-
rural:
50-
- air
51-
- ground
43+
heat_pump_sources:
44+
urban central:
45+
- air
46+
- geothermal
47+
- river_water
48+
- sea_water
49+
urban decentral:
50+
- air
51+
rural:
52+
- air
53+
- ground
5254
hydrogen_turbine: false
5355
regional_oil_demand: false
5456
regional_co2_sequestration_potential:
@@ -121,3 +123,6 @@ plotting:
121123
energy_max:
122124
energy_min:
123125
energy_threshold: 0.000001
126+
interactive_bus_balance:
127+
bus_name_pattern: "*central heat*"
128+
enable_heat_source_maps: true

config/test/config.overnight.yaml

Lines changed: 14 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -68,15 +68,17 @@ sector:
6868
booster_heat_pump: true
6969
ates:
7070
enable: true
71-
heat_pump_sources:
72-
urban central:
73-
- air
74-
- geothermal
75-
urban decentral:
76-
- air
77-
rural:
78-
- air
79-
- ground
71+
heat_pump_sources:
72+
urban central:
73+
- air
74+
- geothermal
75+
- river_water
76+
- sea_water
77+
urban decentral:
78+
- air
79+
rural:
80+
- air
81+
- ground
8082
hydrogen_turbine: false
8183
regional_oil_demand: false
8284
regional_co2_sequestration_potential:
@@ -92,7 +94,6 @@ sector:
9294
biomass_to_liquid: false
9395
electrobiofuels: false
9496

95-
9697
industry:
9798
HVC_environment_sequestration_fraction: 0.5
9899
waste_to_energy: true
@@ -119,3 +120,6 @@ plotting:
119120
energy_max:
120121
energy_min:
121122
energy_threshold: 0.000001
123+
interactive_bus_balance:
124+
bus_name_pattern: "*central heat*"
125+
enable_heat_source_maps: true

config/test/config.perfect.yaml

Lines changed: 13 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -51,16 +51,19 @@ sector:
5151
booster_heat_pump: true
5252
ates:
5353
enable: true
54-
heat_pump_sources:
55-
urban central:
56-
- air
57-
- geothermal
58-
urban decentral:
59-
- air
60-
rural:
61-
- air
62-
- ground
63-
hydrogen_turbine: false
54+
heat_pump_sources:
55+
urban central:
56+
- air
57+
- ptes
58+
- river_water
59+
- sea_water
60+
- geothermal
61+
urban decentral:
62+
- air
63+
rural:
64+
- air
65+
- ground
66+
hydrogen_turbine: false
6467
regional_oil_demand: false
6568
regional_co2_sequestration_potential:
6669
enable: false

doc/configtables/plotting.csv

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,14 @@
11
,Unit,Values,Description
2+
heat_sources,,,
3+
-- enable_heat_source_maps,--,bool,If true generate temporal aggregate maps for heat sources
24
map,,,
35
-- boundaries,°,"[x1,x2,y1,y2]",Boundaries of the map plots in degrees latitude (y) and longitude (x)
46
-- geomap_colors,,,
57
-- -- ocean,--,str,Color of the ocean in the geomap.
68
-- -- land,--,str,Color of the land in the geomap.
9+
interactive_bus_balance,,,
10+
-- bus_name_pattern,--,str,Regex pattern to match bus names for which interactive balance time series are plotted. E.g. 'DE*' for all buses starting with 'DE'.
11+
712
projection,,,
813
-- name,--,Valid Cartopy projection name,See https://scitools.org.uk/cartopy/docs/latest/reference/projections.html for list of available projections.
914
-- args,--,--,"Other entries under 'projection' are passed as keyword arguments to the projection constructor, e.g. ``central_longitude: 10.``."

doc/configtables/sector.csv

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -48,17 +48,21 @@ district_heating,--,,
4848
-- -- isentropic_compressor_efficiency,--,float,Isentropic efficiency of heat pump compressor assumed for approximation. Must be between 0 and 1.
4949
-- -- heat_loss,--,float,Heat pump heat loss assumed for approximation. Must be between 0 and 1.
5050
-- -- min_delta_t_lift,--,float,"Minimum feasible temperature lift for heat pumps, used to approximate technical limits in heat pump operation. This value accounts for practical constraints in heat pump design."
51-
-- limited_heat_sources,--,Dictionary with names of limited heat sources (not air) for which data by Fraunhofer ISI (`Manz et al. 2024 <https://www.sciencedirect.com/science/article/pii/S0960148124001769>) is used,
52-
-- -- geothermal,-,Name of the heat source. Must be the same as in ``heat_pump_sources``,
51+
-- -- min_delta_t_lift,--,float,"Minimum feasible temperature lift for heat pumps, used to approximate technical limits in heat pump operation. This value accounts for practical constraints in heat pump design."
52+
-- limited_heat_sources,--,,Dictionary with names of limited heat sources (not air). Must be `river_water` / `geothermal` or another heat source in `Manz et al. 2024 <https://www.sciencedirect.com/science/article/pii/S0960148124001769>`__)
53+
54+
-- -- river_water,-,Name of the heat source. Must be the same as in ``heat_pump_sources``,
5355
-- -- -- constant_temperature_celsius,°C,heat source temperature,
5456
-- -- -- ignore_missing_regions,--,Boolean,Ignore missing regions in the data and fill with zeros or raise an error
5557
-- direct_utilisation_heat_sources,--,List of heat sources for direct heat utilisation in district heating. Must be in the keys of `heat_utilisation_potentials` (e.g. ``geothermal``),
5658
-- temperature_limited_stores,,Dictionary with names for stores used as limited heat sources
5759
-- -- ptes,-,Name of the heat source. Must be the same as in ``heat_pump_sources``
60+
-- dh_area_buffer,m,float,The buffer by which dh_area shapes from Manz et al. are increased
5861
-- heat_pump_sources,--,,
59-
-- -- urban central,--,List of heat sources for heat pumps in urban central heating,
60-
-- -- urban decentral,--,List of heat sources for heat pumps in urban decentral heating,
61-
-- -- rural,--,List of heat sources for heat pumps in rural heating,
62+
-- -- urban central,--,"List of heat sources for heat pumps in urban central heating. Must be one of [air, river_water, sea_water, geothermal]",
63+
-- -- urban decentral,--,"List of heat sources for heat pumps in urban decentral heating. Must be one of [air]",
64+
-- -- rural,--,"List of heat sources for heat pumps in rural heating. Must be one of [air, ground]",
65+
6266
cluster_heat_buses,--,"{true, false}",Cluster residential and service heat buses in `prepare_sector_network.py <https://github.com/PyPSA/pypsa-eur-sec/blob/master/scripts/prepare_sector_network.py>`_ to one to save memory.
6367
bev_dsm_restriction _value,--,float,Adds a lower state of charge (SOC) limit for battery electric vehicles (BEV) to manage its own energy demand (DSM). Located in `build_transport_demand.py <https://github.com/PyPSA/pypsa-eur-sec/blob/master/scripts/build_transport_demand.py>`_. Set to 0 for no restriction on BEV DSM
6468
bev_dsm_restriction _time,--,float,Time at which SOC of BEV has to be dsm_restriction_value
@@ -166,6 +170,7 @@ methanol,--,--,Add methanol as carrrier and add enabled methnol technologies
166170
-- -- biomass_to_methanol,--,"{true, false}"," Add biomass to methanol"
167171
-- -- biomass_to_methanol_cc,--,"{true, false}"," Add biomass to methanol with carbon capture"
168172
ammonia,--,"{true, false, regional}","Add ammonia as a carrrier. It can be either true (copperplated NH3), false (no NH3 carrier) or ""regional"" (regionalised NH3 without network)"
173+
min_part_load_electrolysis,per unit of p_nom ,float,The minimum unit dispatch (``p_min_pu``) for electrolysis
169174
min_part_load_fischer _tropsch,per unit of p_nom ,float,The minimum unit dispatch (``p_min_pu``) for the Fischer-Tropsch process
170175
min_part_load _methanolisation,per unit of p_nom ,float,The minimum unit dispatch (``p_min_pu``) for the methanolisation process
171176
use_fischer_tropsch _waste_heat,--,"{true, false}",Add option for using waste heat of Fischer Tropsch in district heating networks
@@ -222,4 +227,4 @@ imports,,,
222227
-- limit,TWh,float,Maximum allowed renewable energy imports
223228
-- limit_sense,--,"{==, <=, >=}",Sense of the limit
224229
-- price,,"{H2, NH3, methanol, gas, oil}",
225-
-- -- {carrier},currency/MWh,float,Price for importing renewable energy of carrier
230+
-- -- {carrier},currency/MWh,float,Price for importing renewable energy of carrier

0 commit comments

Comments
 (0)