Skip to content
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

Hotfix #4265 following #3863 - Do not translate ControllerList if no external controllers for AirLoopHVACDedicatedOutdoorAirSystem #4266

Merged
merged 3 commits into from
Apr 1, 2021

Conversation

jmarrec
Copy link
Collaborator

@jmarrec jmarrec commented Mar 29, 2021

Pull request overview

Pull Request Author

Add to this list or remove from it as applicable. This is a simple templated set of guidelines.

  • Model API Changes / Additions
  • Any new or modified fields have been implemented in the EnergyPlus ForwardTranslator (and ReverseTranslator as appropriate)
  • Model API methods are tested (in src/model/test)
  • EnergyPlus ForwardTranslator Tests (in src/energyplus/Test)
  • If a new object or method, added a test in NREL/OpenStudio-resources: Add Link
  • If needed, added VersionTranslation rules for the objects (src/osversion/VersionTranslator.cpp)
  • Checked behavior in OpenStudioApplication, adjusted policies as needed (src/openstudio_lib/library/OpenStudioPolicy.xml)
  • Verified that C# bindings built fine on Windows, partial classes used as needed, etc.
  • All new and existing tests passes
  • If methods have been deprecated, update rest of code to use the new methods

Labels:

  • If change to an IDD file, add the label IDDChange
  • If breaking existing API, add the label APIChange
  • If deemed ready, add label Pull Request - Ready for CI so that CI builds your PR

Review Checklist

This will not be exhaustively relevant to every PR.

  • Perform a Code Review on GitHub
  • Code Style, strip trailing whitespace, etc.
  • All related changes have been implemented: model changes, model tests, FT changes, FT tests, VersionTranslation, OS App
  • Labeling is ok
  • If defect, verify by running develop branch and reproducing defect, then running PR and reproducing fix
  • If feature, test running new feature, try creative ways to break it
  • CI status: all green or justified

@jmarrec jmarrec added component - HVAC component - IDF Translation Pull Request - Ready for CI This pull request if finalized and is ready for continuous integration verification prior to merge. labels Mar 29, 2021
@jmarrec jmarrec self-assigned this Mar 29, 2021
@jmarrec jmarrec added this to the OpenStudio SDK 3.2.0 milestone Mar 29, 2021
@jmarrec jmarrec changed the title Hotfix #4264 following #3863 - Do not translate ControllerList if no external controllers for AirLoopHVACDedicatedOutdoorAirSystem Hotfix #4265 following #3863 - Do not translate ControllerList if no external controllers for AirLoopHVACDedicatedOutdoorAirSystem Mar 29, 2021
Comment on lines +103 to +107
// If it's not empty: then we have work to do.
// If it's empty, there's at least the controller Outdoor Air UNLESS it's on a AirLoopHVACDOAS in which case do nothing
if (!controllers.empty() || !modelObject.airLoopHVACDedicatedOutdoorAirSystem()) {

IdfObject _controllerList(IddObjectType::AirLoopHVAC_ControllerList);
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is the actual fix. The ControllerList is translated only if we have work to do. This is based on how I understand E+ expects it...

@jmarrec jmarrec force-pushed the Hotfx_4264_AirLoopHVACDOAS branch from 2217be4 to bab7db5 Compare March 29, 2021 14:49
@jmarrec
Copy link
Collaborator Author

jmarrec commented Mar 29, 2021

@eringold Could you try this branch with your specific application and let me know if that solves it please?

@eringold
Copy link
Contributor

@jmarrec of course, thanks for jumping on this!

Comment on lines -10221 to -10242
OS:AirLoopHVAC:ControllerList,
\memo List controllers in order of control sequence
\extensible:2
\min-fields 4
A1, \field Handle
\type handle
\required-field
A2, \field Name
\type alpha
\required-field
\reference ControllerLists
A3, \field Controller Object Type
\type choice
\required-field
\begin-extensible
\key Controller:WaterCoil
\key Controller:OutdoorAir
A4; \field Controller Name
\type object-list
\required-field
\object-list AirLoopControllers

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@kbenne I removed this, as it's actually unused.

@joseph-robertson
Copy link
Collaborator

@jmarrec So this was a case of the eplus idd permitted it but there is no example idf that demonstrates it?

@eringold
Copy link
Contributor

@joseph-robertson essentially yes. The only eplus example file with AirLoopHVAC:DOAS is 'SmallOffice_CentralDOAS.idf' which has water coils on the AirLoopHVAC:OAS, so that ControllerList was populated.

@jmarrec
Copy link
Collaborator Author

jmarrec commented Mar 29, 2021

@joseph-robertson Yeah it's a weird corner case. The only example in E+ is SmallOffice_CentralDOAS.idf. and it has this:

  AirLoopHVAC:DedicatedOutdoorAirSystem,
    AirLoopHVAC DOAS,        !- Name
    AirLoopDOAS OA system,   !- AirLoopHVAC:OutdoorAirSystem Name
   [...]

  AirLoopHVAC:OutdoorAirSystem,
    AirLoopDOAS OA system,   !- Name
    OA Sys 1 Controllers,    !- Controller List Name
    OA Sys 1 Equipment,      !- Outdoor Air Equipment List Name
    OA Sys 1 Avail List;     !- Availability Manager List Name

  AirLoopHVAC:ControllerList,
    OA Sys 1 Controllers,    !- Name
    Controller:WaterCoil,    !- Controller 1 Object Type
    OA CC Controller 1,      !- Controller 1 Name
    Controller:WaterCoil,    !- Controller 2 Object Type
    OA HC Controller 1;      !- Controller 2 Name

So it has a control list, but because it has coils... If you look at the E+ idd, there is a hint that you may need to omit it...

AirLoopHVAC:OutdoorAirSystem,
       \memo Outdoor air subsystem for an AirLoopHVAC. Includes an outdoor air mixing box and
       \memo optional outdoor air conditioning equipment such as heat recovery, preheat, and precool
       \memo coils. From the perspective of the primary air loop the outdoor air system is treated
       \memo as a single component.
       \min-fields 3
   A1, \field Name
       \required-field
       \type alpha
       \reference-class-name validBranchEquipmentTypes
       \reference validBranchEquipmentNames
   A2, \field Controller List Name
+       \note Enter the name of an AirLoopHVAC:ControllerList object or blank if this object is used in
+       \note AirLoopHVAC:DedicatedOutdoorAirSystem.
       \type object-list
       \object-list ControllerLists

If you ask me, E+ should just not complain if you provide a ControllerList but it references nothing... Except the ControllerList has \min-fields 3, so the InputParser complains...

@eringold
Copy link
Contributor

@jmarrec this works - a ControllerList is not created when no components that require it are on the OAS.

Now, since an OutdoorAirMixer is not listed in the AirLoopHVAC:OAS referenced by the AirLoopHVAC:DOAS, if you don't add any components to the DOAS's OAS, you will end up with an empty AirLoopHVAC:OutdoorAirSystem:EquipmentList, which will cause the sim to fail. But since the point of the DOAS is to contain HVAC components, I'm not sure OpenStudio needs to protect against that case. Just thought I'd mention.

@tijcolem tijcolem merged commit 48e607e into develop Apr 1, 2021
@tijcolem tijcolem deleted the Hotfx_4264_AirLoopHVACDOAS branch April 1, 2021 15:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component - HVAC component - IDF Translation Pull Request - Ready for CI This pull request if finalized and is ready for continuous integration verification prior to merge.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Empty AirLoopHVAC:ControllerList created for AirLoopHVAC:DedicatedOutdoorAirSystem at forward translation
5 participants