bugfix: account for kerosene emissions in methanol-to-kerosene link (#1317)

* bugfix: account for kerosene emissions in methanol-to-kerosene link

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
This commit is contained in:
Fabian Neumann 2024-09-23 11:52:54 +02:00 committed by GitHub
parent 6387c46c2e
commit e2be4d730e
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -931,25 +931,10 @@ def add_methanol_to_power(n, costs, types=None):
def add_methanol_to_kerosene(n, costs):
nodes = pop_layout.index
nhours = n.snapshot_weightings.generators.sum()
demand_factor = options["aviation_demand_factor"]
tech = "methanol-to-kerosene"
logger.info(f"Adding {tech}.")
all_aviation = ["total international aviation", "total domestic aviation"]
p_nom_max = (
demand_factor
* pop_weighted_energy_totals.loc[nodes, all_aviation].sum(axis=1)
* 1e6
/ nhours
* costs.at[tech, "methanol-input"]
)
capital_cost = costs.at[tech, "fixed"] / costs.at[tech, "methanol-input"]
n.madd(
@ -961,12 +946,12 @@ def add_methanol_to_kerosene(n, costs):
bus0=spatial.methanol.nodes,
bus1=spatial.oil.kerosene,
bus2=spatial.h2.nodes,
bus3="co2 atmosphere",
efficiency=costs.at[tech, "methanol-input"],
efficiency2=-costs.at[tech, "hydrogen-input"]
/ costs.at[tech, "methanol-input"],
efficiency3=costs.at["oil", "CO2 intensity"] / costs.at[tech, "methanol-input"],
p_nom_extendable=True,
p_min_pu=1,
p_nom_max=p_nom_max.values,
)