TulipaEnergy / TulipaEnergyModel.jl

An energy system optimization model that is flexible, computationally efficient, and academically robust.
Apache License 2.0
22 stars 19 forks source link

Implement relationships for Multiple Inputs Multiple Outputs (MIMO) of an asset #596

Open datejada opened 5 months ago

datejada commented 5 months ago

Description

Two use cases need this feature to represent the assets' physics correctly:

  1. Cogeneration or combined heat and power (CHP): For each flow of electricity, an X amount of heat is produced.
  2. Hydro assets in cascade: if there are two hydro assets in cascade (one upstream, one downstream). The electricity flow from the upstream asset implies an X amount of water flow (turbined water) to the hydro reservoir downstream.

In both cases, the outputs of the asset are not independent.

Codewise, we need to think through how to make it straightforward for the user to include this data (and also, in the code, it should be clear when and how these constraints work).

Related Issues

No response

datejada commented 4 months ago

Use the proposal in SpineOpt as inspiration to include this feature in Tulipa:

https://github.com/spine-tools/SpineOpt.jl/discussions/873

clizbe commented 4 months ago

Wouldn't the second case be an output flow to an input flow (of water)? Ah wait do you mean the output flow of water is linked to the output of electricity?

datejada commented 4 months ago

Correct, the output of water depends on the electricity flow.

datejada commented 4 months ago

ESDL uses reference flow in their implementation. They developed it for the compatibility of OPERA with ESDL.

Image

clizbe commented 1 month ago

A comment from Kira about trying to implement in SpineOpt:

"Defining processes with multiple inputs is not very intuitive. For processes with multiple inputs & outputs, all need to be defined in terms of ratios compared to single main inputs & outputs. In the case of steel, I have used the parameter “fix_ratio_out_in_unit_flow” to define the electricity use per unit of steel output, and then used “fix_ratio_in_in_unit_flow” to define all other energy inputs in terms of the ratio of energy per unit of electricity use."

Are we doing this same method? If so, how to make it more intuitive?

datejada commented 1 month ago

A comment from Kira about trying to implement in SpineOpt:

"Defining processes with multiple inputs is not very intuitive. For processes with multiple inputs & outputs, all need to be defined in terms of ratios compared to single main inputs & outputs. In the case of steel, I have used the parameter “fix_ratio_out_in_unit_flow” to define the electricity use per unit of steel output, and then used “fix_ratio_in_in_unit_flow” to define all other energy inputs in terms of the ratio of energy per unit of electricity use."

Are we doing this same method? If so, how to make it more intuitive?

The names in SpineOpt are not intuitive for that type of application. The idea for Tulipa is the same: having a reference flow and then the other inputs and outputs as fractions. We can define the names with Kira so they make more sense to that type of user 😄

datejada commented 1 month ago

There is a summary of the proposals for SpineOpt here: https://github.com/spine-tools/SpineOpt.jl/discussions/873#discussioncomment-10339677

Please use it for further discussions regarding this issue.