forked from Project-OMOTES/rtc-tools-heat-network
-
Notifications
You must be signed in to change notification settings - Fork 3
Integrated heat storage and e-conversion asset #396
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
FJanssen-TNO
wants to merge
17
commits into
main
Choose a base branch
from
heat_storage_e_input
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
17 commits
Select commit
Hold shift + click to select a range
afb6a90
start on creating an integrated heat storage asset that can be charge…
FJanssen-TNO 885ed3b
Merge remote-tracking branch 'origin/main' into heat_storage_e_input
tolga-akan 15b6b01
this commit is problematic. there is error to be resolved
tolga-akan 6261a1f
Merge branch 'main' into heat_storage_e_input
tolga-akan 3472997
Still we cannot test the functionally of e-buffer
tolga-akan e1655ec
olde input files are removed
tolga-akan 12ab5d7
Merge branch 'main' into heat_storage_e_input
tolga-akan 0b299bd
esdl is committed and main is merged
tolga-akan 609d494
Merge branch 'main' into heat_storage_e_input
tolga-akan 5a77f6e
Merge branch 'main' into heat_storage_e_input
tolga-akan 244f51b
not complete. heat buffer elec still requires some work
tolga-akan b580d99
completed
tolga-akan a41bb7f
changelog is added
tolga-akan 93f6622
not complete
tolga-akan 8fc3dc8
not complete
tolga-akan b1462e5
PR review completed
tolga-akan 2fe3a64
esdl is added
tolga-akan File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
53 changes: 53 additions & 0 deletions
53
src/mesido/pycml/component_library/milp/multicommodity/heat_buffer_elec.py
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,53 @@ | ||
| from mesido.pycml import Variable | ||
| from mesido.pycml.component_library.milp.electricity.electricity_base import ElectricityPort | ||
| from mesido.pycml.component_library.milp.heat.heat_buffer import _HeatBufferComponent | ||
| from mesido.pycml.pycml_mixin import add_variables_documentation_automatically | ||
|
|
||
| from numpy import nan | ||
|
|
||
|
|
||
| @add_variables_documentation_automatically | ||
| class HeatBufferElec(_HeatBufferComponent): | ||
| """ | ||
| The HeatBufferElec component represents a heat buffer that can be charged exclusively | ||
| using electricity. This asset cannot be charged by water flow through the inlet/outlet pipes | ||
|
|
||
| Variables created: | ||
| {add_variable_names_for_documentation_here} | ||
|
|
||
| Parameters: | ||
| name : The name of the asset. \n | ||
| modifiers : Dictionary with asset information. | ||
| """ | ||
|
|
||
| def __init__(self, name, **modifiers): | ||
| super().__init__( | ||
| name, | ||
| **modifiers, | ||
| ) | ||
|
|
||
| self.component_subtype = "heat_buffer_elec" | ||
| self.elec_power_nominal = nan | ||
| self.charging_efficiency = nan | ||
|
|
||
| # # Assumption: heat in/out is nonnegative | ||
| self.add_variable(ElectricityPort, "ElectricityIn") | ||
| self.add_variable(Variable, "Power_elec", min=0.0, nominal=self.elec_power_nominal) | ||
| self.add_variable(Variable, "Heat_elec_charging", min=0.0, nominal=self.elec_power_nominal) | ||
| # | ||
| self.add_equation(((self.ElectricityIn.Power - self.Power_elec) / self.elec_power_nominal)) | ||
| # | ||
| self.add_equation( | ||
| ( | ||
| (self.Power_elec * self.charging_efficiency - self.Heat_elec_charging) | ||
| / self.elec_power_nominal | ||
| ) | ||
| ) | ||
|
|
||
| # Heat flow balance of the buffer | ||
| self.add_equation( | ||
| (self.Heat_flow + self.Heat_elec_charging - self.Heat_buffer) / self.Heat_nominal | ||
| ) | ||
|
|
||
| # Buffer can only discharge into heat network. It cannot be charged by heat network | ||
| self.Heat_flow.max = 0.0 |
46 changes: 46 additions & 0 deletions
46
tests/models/simple_buffer/input/timeseries_import_ebuffer.csv
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,46 @@ | ||
| DateTime,demand,elec | ||
| 19-5-2013 22:00,150000,5.00E-05 | ||
| 19-5-2013 23:00,150000,5.00E-05 | ||
| 20-5-2013 00:00,150000,5.00E-05 | ||
| 20-5-2013 01:00,150000,5.00E-05 | ||
| 20-5-2013 02:00,150000,5.00E-05 | ||
| 20-5-2013 03:00,150000,5.00E-05 | ||
| 20-5-2013 04:00,150000,5.00E-05 | ||
| 20-5-2013 05:00,150000,5.00E-05 | ||
| 20-5-2013 06:00,150000,5.00E-05 | ||
| 20-5-2013 07:00,150000,5.00E-05 | ||
| 20-5-2013 08:00,150000,5.00E-05 | ||
| 20-5-2013 09:00,150000,5.00E-05 | ||
| 20-5-2013 10:00,150000,5.00E-05 | ||
| 20-5-2013 11:00,150000,5.00E-05 | ||
| 20-5-2013 12:00,150000,5.00E-05 | ||
| 20-5-2013 13:00,150000,5.00E-05 | ||
| 20-5-2013 14:00,100000,5.00E-05 | ||
| 20-5-2013 15:00,100000,5.00E-05 | ||
| 20-5-2013 16:00,100000,5.00E-05 | ||
| 20-5-2013 17:00,100000,5.00E-05 | ||
| 20-5-2013 18:00,100000,0.00015 | ||
| 20-5-2013 19:00,100000,0.00015 | ||
| 20-5-2013 20:00,100000,0.00015 | ||
| 20-5-2013 21:00,100000,0.00015 | ||
| 20-5-2013 22:00,100000,0.00015 | ||
| 20-5-2013 23:00,100000,0.00015 | ||
| 21-5-2013 00:00,100000,0.00015 | ||
| 21-5-2013 01:00,100000,0.00015 | ||
| 21-5-2013 02:00,100000,0.00015 | ||
| 21-5-2013 03:00,70000,0.00015 | ||
| 21-5-2013 04:00,70000,0.00015 | ||
| 21-5-2013 05:00,70000,0.00015 | ||
| 21-5-2013 06:00,70000,0.00015 | ||
| 21-5-2013 07:00,70000,0.00015 | ||
| 21-5-2013 08:00,70000,0.00015 | ||
| 21-5-2013 09:00,70000,0.00015 | ||
| 21-5-2013 10:00,70000,0.00015 | ||
| 21-5-2013 11:00,70000,0.00015 | ||
| 21-5-2013 12:00,70000,0.00015 | ||
| 21-5-2013 13:00,70000,0.00015 | ||
| 21-5-2013 14:00,70000,0.00015 | ||
| 21-5-2013 15:00,70000,0.00015 | ||
| 21-5-2013 16:00,70000,0.00015 | ||
| 21-5-2013 17:00,70000,0.00015 | ||
| 21-5-2013 18:00,70000,0.00015 |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this max_supply is the maximum heatflow