rl-institut / multi-vector-simulator

Multi-vector Simulation Tool assessing and optimizing Local Energy Systems (LES) for the E-LAND project
GNU General Public License v2.0
21 stars 10 forks source link

[Bug] Degree of Autonomy KPI doesn't cope well with two energy providers #862

Open TheOneAndra opened 3 years ago

TheOneAndra commented 3 years ago

In this system, two energy providers are used: Transmission system operator (energy vector: electricity) and Biogas (energy vector: electricity). This somehow causes an issue with the KPI degree of autonomy which is wrong.

Here is the folder to with the highlighted errors (in scalars) and the input: Error_DOA.zip

Checklist to make sure that the bug report ist complete:

TheOneAndra commented 3 years ago

@smartie2076 Kindly suggested that this error might be solvable by adapting this and that part of the code

smartie2076 commented 3 years ago

Reasoning: Basically, we did not expect that two energy providers of the same energy carrier type would be used, and the values are overwritten. They should be added in line https://github.com/rl-institut/multi-vector-simulator/blob/dev/src/multi_vector_simulator/E3_indicator_calculation.py#L839

Bachibouzouk commented 3 years ago

This would also be solved if we adopt the list of assets paradigm (like EPA) instead of dict of assets because you can add twice the same value in a list, but you can't have twice the same key in a dict. (reference to #689)