Merge branch 'master' into industry-pathway
This commit is contained in:
commit
4d4badc519
@ -314,7 +314,7 @@ pypsa_eur:
|
||||
|
||||
# docs in https://pypsa-eur.readthedocs.io/en/latest/configuration.html#energy
|
||||
energy:
|
||||
energy_totals_year: 2011
|
||||
energy_totals_year: 2013
|
||||
base_emissions_year: 1990
|
||||
eurostat_report_year: 2016
|
||||
emissions: CO2
|
||||
@ -501,6 +501,7 @@ sector:
|
||||
SMR_cc: true
|
||||
regional_methanol_demand: false
|
||||
regional_oil_demand: false
|
||||
regional_coal_demand: false
|
||||
regional_co2_sequestration_potential:
|
||||
enable: false
|
||||
attribute: 'conservative estimate Mt'
|
||||
|
25
data/switzerland-new_format-all_years.csv
Normal file
25
data/switzerland-new_format-all_years.csv
Normal file
@ -0,0 +1,25 @@
|
||||
country,item,2010,2011,2012,2013,2014,2015
|
||||
CH,total residential,268.2,223.4,243.4,261.3,214.2,229.1
|
||||
CH,total residential space,192.2,149.0,168.1,185.5,139.7,154.4
|
||||
CH,total residential water,32.2,31.6,31.9,32.2,31.7,31.9
|
||||
CH,total residential cooking,9.3,9.3,9.3,9.4,9.5,9.6
|
||||
CH,electricity residential,67.9,63.7,65.7,67.6,63.0,64.4
|
||||
CH,electricity residential space,15.9,12.8,14.3,15.8,12.3,13.5
|
||||
CH,electricity residential water,8.8,8.5,8.5,8.6,8.5,8.6
|
||||
CH,electricity residential cooking,4.9,4.9,4.9,4.9,5.0,5.0
|
||||
CH,total services,145.9,127.4,136.7,144.0,124.5,132.5
|
||||
CH,total services space,80.0,62.2,70.8,77.4,58.3,64.3
|
||||
CH,total services water,10.1,10.0,10.1,10.1,10.0,10.0
|
||||
CH,total services cooking,2.5,2.4,2.3,2.3,2.4,2.3
|
||||
CH,electricity services,60.5,59.2,60.3,61.4,60.3,62.6
|
||||
CH,electricity services space,4.0,3.2,3.8,4.2,3.3,3.6
|
||||
CH,electricity services water,0.7,0.7,0.7,0.7,0.7,0.7
|
||||
CH,electricity services cooking,2.5,2.4,2.3,2.3,2.4,2.3
|
||||
CH,total rail,11.5,11.1,11.2,11.4,11.1,11.4
|
||||
CH,total road,199.4,200.4,200.4,201.2,202.0,203.1
|
||||
CH,electricity road,0.,0.,0.,0.,0.,0.
|
||||
CH,electricity rail,11.5,11.1,11.2,11.4,11.1,11.4
|
||||
CH,total domestic aviation,3.3,3.2,3.4,3.4,3.5,3.5
|
||||
CH,total international aviation,58.0,62.0,63.5,64.2,64.5,66.8
|
||||
CH,total domestic navigation,1.6,1.6,1.6,1.6,1.6,1.6
|
||||
CH,total international navigation,0.,0.,0.,0.,0.,0.
|
|
@ -10,6 +10,18 @@ Release Notes
|
||||
Upcoming Release
|
||||
================
|
||||
|
||||
* Bugfix: Correct units of subtracted chlorine and methanol demand in
|
||||
:mod:`build_industry_sector_ratios`.
|
||||
|
||||
* Include all countries in ammonia production resource. This is so that the full
|
||||
EU28 ammonia demand can be correctly subtracted in the rule
|
||||
:mod:`build_industry_sector_ratios`.
|
||||
|
||||
* Regions are assigned to all buses with unique coordinates in the network with
|
||||
a preference given to substations. Previously, only substations had assigned
|
||||
regions, but this could lead to issues when a high spatial resolution was
|
||||
applied.
|
||||
|
||||
* The default configuration ``config/config.default.yaml`` is now automatically
|
||||
used as a base configuration file and no longer copied to
|
||||
``config/config.yaml`` on first use. The file ``config/config.yaml`` should be
|
||||
@ -17,6 +29,10 @@ Upcoming Release
|
||||
|
||||
* Merged two OPSD time series data versions into such that the option ``load:
|
||||
power_statistics:`` becomes superfluous and was hence removed.
|
||||
* Bugfix: The industry coal emissions for industry were not properly tracked.
|
||||
|
||||
* Allow industrial coal demand to be regional so its emissions can be included
|
||||
in regional emission limits.
|
||||
|
||||
* Add new default to overdimension heating in individual buildings. This allows
|
||||
them to cover heat demand peaks e.g. 10% higher than those in the data. The
|
||||
@ -113,6 +129,8 @@ Upcoming Release
|
||||
workflows with foresight "myopic" and still needs to be added foresight option
|
||||
"perfect".
|
||||
|
||||
* Switched the energy totals year from 2011 to 2013 to comply with the assumed default weather year.
|
||||
|
||||
|
||||
PyPSA-Eur 0.9.0 (5th January 2024)
|
||||
==================================
|
||||
|
@ -248,7 +248,7 @@ rule build_energy_totals:
|
||||
input:
|
||||
nuts3_shapes=RESOURCES + "nuts3_shapes.geojson",
|
||||
co2="data/bundle-sector/eea/UNFCCC_v23.csv",
|
||||
swiss="data/bundle-sector/switzerland-sfoe/switzerland-new_format.csv",
|
||||
swiss="data/switzerland-new_format-all_years.csv",
|
||||
idees="data/bundle-sector/jrc-idees-2015",
|
||||
district_heat_share="data/district_heat_share.csv",
|
||||
eurostat=input_eurostat,
|
||||
@ -392,8 +392,6 @@ rule build_salt_cavern_potentials:
|
||||
|
||||
|
||||
rule build_ammonia_production:
|
||||
params:
|
||||
countries=config["countries"],
|
||||
input:
|
||||
usgs="data/bundle-sector/myb1-2017-nitro.xls",
|
||||
output:
|
||||
|
@ -559,6 +559,7 @@ def _set_countries_and_substations(n, config, country_shapes, offshore_shapes):
|
||||
for b, df in product(("bus0", "bus1"), (n.lines, n.links)):
|
||||
has_connections_b |= ~df.groupby(b).under_construction.min()
|
||||
|
||||
buses["onshore_bus"] = onshore_b
|
||||
buses["substation_lv"] = (
|
||||
lv_b & onshore_b & (~buses["under_construction"]) & has_connections_b
|
||||
)
|
||||
|
@ -25,13 +25,14 @@ if __name__ == "__main__":
|
||||
header=0,
|
||||
index_col=0,
|
||||
skipfooter=19,
|
||||
na_values=["--"],
|
||||
)
|
||||
|
||||
ammonia.index = cc.convert(ammonia.index, to="iso2")
|
||||
|
||||
years = [str(i) for i in range(2013, 2018)]
|
||||
countries = ammonia.index.intersection(snakemake.params.countries)
|
||||
ammonia = ammonia.loc[countries, years].astype(float)
|
||||
|
||||
ammonia = ammonia[years]
|
||||
|
||||
# convert from ktonN to ktonNH3
|
||||
ammonia *= 17 / 14
|
||||
|
@ -135,7 +135,13 @@ if __name__ == "__main__":
|
||||
c_b = n.buses.country == country
|
||||
|
||||
onshore_shape = country_shapes[country]
|
||||
onshore_locs = n.buses.loc[c_b & n.buses.substation_lv, ["x", "y"]]
|
||||
onshore_locs = (
|
||||
n.buses.loc[c_b & n.buses.onshore_bus]
|
||||
.sort_values(
|
||||
by="substation_lv", ascending=False
|
||||
) # preference for substations
|
||||
.drop_duplicates(subset=["x", "y"], keep="first")[["x", "y"]]
|
||||
)
|
||||
onshore_regions.append(
|
||||
gpd.GeoDataFrame(
|
||||
{
|
||||
|
@ -408,15 +408,15 @@ def chemicals_industry():
|
||||
df.loc["methane", sector] -= ammonia_total * params["MWh_CH4_per_tNH3_SMR"]
|
||||
df.loc["elec", sector] -= ammonia_total * params["MWh_elec_per_tNH3_SMR"]
|
||||
|
||||
# subtract chlorine demand
|
||||
# subtract chlorine demand (in MtCl/a)
|
||||
chlorine_total = params["chlorine_production_today"]
|
||||
df.loc["hydrogen", sector] -= chlorine_total * params["MWh_H2_per_tCl"]
|
||||
df.loc["elec", sector] -= chlorine_total * params["MWh_elec_per_tCl"]
|
||||
df.loc["hydrogen", sector] -= chlorine_total * params["MWh_H2_per_tCl"] * 1e3
|
||||
df.loc["elec", sector] -= chlorine_total * params["MWh_elec_per_tCl"] * 1e3
|
||||
|
||||
# subtract methanol demand
|
||||
# subtract methanol demand (in MtMeOH/a)
|
||||
methanol_total = params["methanol_production_today"]
|
||||
df.loc["methane", sector] -= methanol_total * params["MWh_CH4_per_tMeOH"]
|
||||
df.loc["elec", sector] -= methanol_total * params["MWh_elec_per_tMeOH"]
|
||||
df.loc["methane", sector] -= methanol_total * params["MWh_CH4_per_tMeOH"] * 1e3
|
||||
df.loc["elec", sector] -= methanol_total * params["MWh_elec_per_tMeOH"] * 1e3
|
||||
|
||||
# MWh/t material
|
||||
df.loc[sources, sector] = df.loc[sources, sector] / s_out
|
||||
|
@ -172,6 +172,13 @@ def define_spatial(nodes, options):
|
||||
spatial.coal.nodes = ["EU coal"]
|
||||
spatial.coal.locations = ["EU"]
|
||||
|
||||
if options["regional_coal_demand"]:
|
||||
spatial.coal.demand_locations = nodes
|
||||
spatial.coal.industry = nodes + " coal for industry"
|
||||
else:
|
||||
spatial.coal.demand_locations = ["EU"]
|
||||
spatial.coal.industry = ["EU coal for industry"]
|
||||
|
||||
# lignite
|
||||
spatial.lignite = SimpleNamespace()
|
||||
spatial.lignite.nodes = ["EU lignite"]
|
||||
@ -3048,19 +3055,40 @@ def add_industry(n, costs):
|
||||
|
||||
mwh_coal_per_mwh_coke = 1.366 # from eurostat energy balance
|
||||
p_set = (
|
||||
industrial_demand["coal"].sum()
|
||||
+ mwh_coal_per_mwh_coke * industrial_demand["coke"].sum()
|
||||
industrial_demand["coal"]
|
||||
+ mwh_coal_per_mwh_coke * industrial_demand["coke"]
|
||||
) / nhours
|
||||
|
||||
if not options["regional_coal_demand"]:
|
||||
p_set = p_set.sum()
|
||||
|
||||
n.madd(
|
||||
"Bus",
|
||||
spatial.coal.industry,
|
||||
location=spatial.coal.demand_locations,
|
||||
carrier="coal for industry",
|
||||
unit="MWh_LHV",
|
||||
)
|
||||
|
||||
n.madd(
|
||||
"Load",
|
||||
spatial.coal.nodes,
|
||||
suffix=" for industry",
|
||||
bus=spatial.coal.nodes,
|
||||
spatial.coal.industry,
|
||||
bus=spatial.coal.industry,
|
||||
carrier="coal for industry",
|
||||
p_set=p_set,
|
||||
)
|
||||
|
||||
n.madd(
|
||||
"Link",
|
||||
spatial.coal.industry,
|
||||
bus0=spatial.coal.nodes,
|
||||
bus1=spatial.coal.industry,
|
||||
bus2="co2 atmosphere",
|
||||
carrier="coal for industry",
|
||||
p_nom_extendable=True,
|
||||
efficiency2=costs.at["coal", "CO2 intensity"],
|
||||
)
|
||||
|
||||
|
||||
def add_waste_heat(n):
|
||||
# TODO options?
|
||||
|
@ -611,6 +611,7 @@ if __name__ == "__main__":
|
||||
"symbol",
|
||||
"tags",
|
||||
"under_construction",
|
||||
"onshore_bus",
|
||||
"substation_lv",
|
||||
"substation_off",
|
||||
"geometry",
|
||||
|
Loading…
Reference in New Issue
Block a user