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

Align PlantLowFlowRateToler with DataHVACGlobals::VerySmallMassFlow #10457

Merged
merged 7 commits into from
May 23, 2024

Conversation

lymereJ
Copy link
Collaborator

@lymereJ lymereJ commented Mar 29, 2024

Pull request overview

Align PlantLowFlowRateToler with DataHVACGlobals::VerySmallMassFlow so minimum pump flow rate can be correctly enforced during simulations.

Pull Request Author

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

  • Title of PR should be user-synopsis style (clearly understandable in a standalone changelog context)
  • Label the PR with at least one of: Defect, Refactoring, NewFeature, Performance, and/or DoNoPublish
  • Pull requests that impact EnergyPlus code must also include unit tests to cover enhancement or defect repair
  • Author should provide a "walkthrough" of relevant code changes using a GitHub code review comment process
  • If any diffs are expected, author must demonstrate they are justified using plots and descriptions
  • If changes fix a defect, the fix should be demonstrated in plots and descriptions

Reviewer

This will not be exhaustively relevant to every PR.

  • Perform a Code Review on GitHub
  • If branch is behind develop, merge develop and build locally to check for side effects of the merge
  • 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
  • Check that performance is not impacted (CI Linux results include performance check)
  • Run Unit Test(s) locally
  • Check any new function arguments for performance impacts
  • Verify IDF naming conventions and styles, memos and notes and defaults
  • If new idf included, locally check the err file and other outputs

@lymereJ lymereJ added the Defect Includes code to repair a defect in EnergyPlus label Mar 29, 2024
@lymereJ lymereJ changed the title Align PlantLowFlowRateToler with SmallWaterVolFlow Align PlantLowFlowRateToler with DataBranchAirLoopPlant::MassFlowTolerance Apr 1, 2024
@lymereJ lymereJ changed the title Align PlantLowFlowRateToler with DataBranchAirLoopPlant::MassFlowTolerance Reduce PlantLowFlowRateToler Apr 1, 2024
constexpr Real64 PlantFlowFlowRateToler(0.01); // Tolerance for mass flow rate convergence (in kg/s)
constexpr Real64 PlantLowFlowRateToler(0.000001); // Tolerance for low flow rate used for determining when plant pumps can be shut down
constexpr Real64 PlantFlowFlowRateToler(0.01); // Tolerance for mass flow rate convergence (in kg/s)
constexpr Real64 PlantLowFlowRateToler(1.0E-30); // Tolerance for low mass flow rate used for determining when plant pumps can be shut down
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Absolute tolerances are defined below (perhaps these should be relative to the plant loop flows?):

Real64 constexpr SmallHumRatDiff(1.0E-7);
Real64 constexpr SmallTempDiff(1.0E-5);
Real64 constexpr SmallMassFlow(0.001);
Real64 constexpr VerySmallMassFlow(1.0E-30);
Real64 constexpr SmallLoad(1.0);
Real64 constexpr TempControlTol(0.1); // temperature control tolerance for packaged equip. [deg C]
Real64 constexpr SmallAirVolFlow(0.001);
Real64 constexpr SmallWaterVolFlow(1.0E-9);

To avoid further failures, probably the best (and the most consistent with what's already use) is DataHVACGlobals::VerySmallMassFlow. It is currently only used for airloops but its name doesn't exclude other fluids.

@lymereJ
Copy link
Collaborator Author

lymereJ commented Apr 1, 2024

Once converted to 24.1 the defect files complete successfully without running into this issue. It is possible that other incremental changes on the component sides are preventing very low flow requests.

@lymereJ lymereJ changed the title Reduce PlantLowFlowRateToler Align PlantLowFlowRateToler with DataHVACGlobals::VerySmallMassFlow Apr 2, 2024
@lymereJ lymereJ marked this pull request as ready for review April 2, 2024 16:11
@Myoldmopar Myoldmopar self-assigned this Apr 24, 2024
@dareumnam
Copy link
Collaborator

I merged the develop and resolved conflicts. CI is all happy here. This PR looks fully clean and ready to go. @Myoldmopar

@Myoldmopar
Copy link
Member

Thanks @dareumnam ! Merging this in now.

@Myoldmopar Myoldmopar merged commit f05c974 into develop May 23, 2024
15 checks passed
@Myoldmopar Myoldmopar deleted the plant_low_flow_tol_update branch May 23, 2024 14:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Defect Includes code to repair a defect in EnergyPlus
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Plant low flow rate tolerance prevents minimum pump flow rate to be enforced
9 participants