Skip to content
This repository was archived by the owner on Mar 27, 2025. It is now read-only.
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 12 additions & 6 deletions workflow/scripts/modify_prenetwork.py
Original file line number Diff line number Diff line change
Expand Up @@ -370,14 +370,16 @@ def unravel_oilbus(n):
)

# add stores
EU_oil_store = n.stores.loc["EU oil Store"].copy()
n.add(
"Store",
"DE oil Store",
bus="DE oil",
carrier="oil",
e_nom_extendable=True,
e_cyclic=True,
capital_cost=0.02,
e_nom_extendable=EU_oil_store.e_nom_extendable,
e_cyclic=EU_oil_store.e_cyclic,
capital_cost=EU_oil_store.capital_cost,
overnight_cost=EU_oil_store.overnight_cost,
)

# unravel meoh
Expand Down Expand Up @@ -414,14 +416,16 @@ def unravel_oilbus(n):
)

# add stores
EU_meoh_store = n.stores.loc["EU methanol Store"].copy()
n.add(
"Store",
"DE methanol Store",
bus="DE methanol",
carrier="methanol",
e_nom_extendable=True,
e_cyclic=True,
capital_cost=0.02,
e_nom_extendable=EU_meoh_store.e_nom_extendable,
e_cyclic=EU_meoh_store.e_cyclic,
capital_cost=EU_meoh_store.capital_cost,
overnight_cost=EU_meoh_store.overnight_cost,
)


Expand Down Expand Up @@ -758,6 +762,7 @@ def force_retrofit(n, params):
h2_plants.efficiency -= params["efficiency_loss"]
h2_plants.efficiency2 = 1 # default value
h2_plants.capital_cost *= 1 + params["cost_factor"]
h2_plants.overnight_cost *= 1 + params["cost_factor"]
# add the new links
n.import_components_from_dataframe(h2_plants, "Link")
n.links.drop(gas_plants, inplace=True)
Expand All @@ -779,6 +784,7 @@ def force_retrofit(n, params):
h2_plants.efficiency -= params["efficiency_loss"]
h2_plants.efficiency3 = 1 # default value
h2_plants.capital_cost *= 1 + params["cost_factor"]
h2_plants.overnight_cost *= 1 + params["cost_factor"]
n.import_components_from_dataframe(h2_plants, "Link")
n.links.drop(gas_plants, inplace=True)

Expand Down