-
Notifications
You must be signed in to change notification settings - Fork 6
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
Refactoring of ThermalGrid.handleInfeed
to fix thermal storage recharge correctly when empty
#931
Conversation
…neState-of-ThermalHouse' into df/tmpHPmergeall
…ageResults-have-multiple-entries' into df/tmpHPmergeall # Conflicts: # CHANGELOG.md
…ion-of-Hp-when-not-under-control-of-an-EM' into df/tmpHPmergeall # Conflicts: # CHANGELOG.md
…ermalGird-energyDemand' into df/tmpHPmergeall
…ge correctly when empty
# Conflicts: # CHANGELOG.md # src/main/scala/edu/ie3/simona/model/thermal/ThermalGrid.scala
# Conflicts: # CHANGELOG.md
# Conflicts: # CHANGELOG.md
# Conflicts: # CHANGELOG.md
# Conflicts: # CHANGELOG.md
# Conflicts: # CHANGELOG.md
# Conflicts: # CHANGELOG.md
# Conflicts: # CHANGELOG.md # src/main/scala/edu/ie3/simona/model/thermal/ThermalGrid.scala
# Conflicts: # CHANGELOG.md
# Conflicts: # CHANGELOG.md
# Conflicts: # CHANGELOG.md
# Conflicts: # CHANGELOG.md
…refactor-handleInfeed
This reverts commit a669b5b.
…ctor-handleInfeed
…ctor-handleInfeed
# Conflicts: # CHANGELOG.md
# Conflicts: # src/test/scala/edu/ie3/simona/agent/em/EmAgentIT.scala
Signed-off-by: Sebastian Peter <sebastian.peter@tu-dortmund.de>
Signed-off-by: Sebastian Peter <sebastian.peter@tu-dortmund.de>
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.
I simplified the infeed cases, please have a look. Besides that, I have some last requests before merging this...
(zeroKW, lastStateStorageQDot * (-1)) | ||
else if ( | ||
lastStateStorageQDot == zeroKW && (demandWrapper.houseDemand.hasRequiredDemand || demandWrapper.heatStorageDemand.hasRequiredDemand) | ||
) | ||
( | ||
zeroKW, | ||
thermalGrid.storage.map(_.getChargingPower: squants.Power).get, | ||
) |
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.
Thanks for adding this large amount of commentary to the code! I have only two more places with "additional documentation demand" ;)
About storages: I guess one could argue about the required demand for empty storage (what if it's filled with a mWh of energy - there'd be no required demand). But, I'd suggest to just document the way this is currently implemented. Maybe it makes sense to enhance the documentation of ThermalDemandWrapper.heatStorageDemand
in that regard?
Furthermore, ScalaDoc for ThermalStorageState
would be great. Questions about the sign/direction of its qDot would be solved then.
…nto df/#930-refactor-handleInfeed
…ecking for conditions within HpModel.calculateHeat
…eInfeed # Conflicts: # CHANGELOG.md
Signed-off-by: Sebastian Peter <sebastian.peter@tu-dortmund.de>
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.
Thanks, that's very much good enough now :)
resolves #930
merge #1052 and #1046 and #1128 first