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

Variable speed coils can have higher flow rate than Packaged Terminal unit and fan #5723

Merged
merged 17 commits into from
Aug 18, 2017

Conversation

nealkruis
Copy link
Member

@nealkruis nealkruis commented Jun 10, 2016

Pull request overview

Add exceptions for mass imbalances. Correct problems as found in CI, such as:

Work Checklist

  • Title of PR should be user-synopsis style (clearly understandable in a standalone changelog context)
    • At least one of the following appropriate labels must be added to this PR to be consumed into the changelog:
      • Defect: This pull request repairs a github defect issue. The github issue should be referenced in the PR description

Review Checklist

  • Code style (parentheses padding, variable names)
  • Functional code review (it has to work!)
  • If defect, results of running current develop vs this branch should exhibit the fix
  • CI status: all green or justified
  • Performance: CI Linux results include performance check -- verify this
  • C++ checks:
    • Argument types
    • If any virtual classes, ensure virtual destructor included, other things
  • IDD changes:
    • Verify naming conventions and styles, memos and notes and defaults
    • Open windows IDF Editor with modified IDD to check for errors
    • If transition, add rules to spreadsheet
    • If transition, add transition source
    • If transition, update idfs
  • If new idf included, locally check the err file and other outputs
  • Documentation changes in place
  • ExpandObjects changes??
  • If output changes, including tabular output structure, add to output rules file for interfaces

@nealkruis
Copy link
Member Author

@rraustad @mjwitte @EnergyArchmage Here is the PR for the mass balance checks and the corresponding fixes. So far I've only taken care of the PTHP issue discussed in #5632, but I anticipate others may fall out after iterating with the CI.

I changed the assertions to fatal errors and added the tolerance as @mjwitte suggested. This should clear out some (hopefully most?) of the failed integration tests. I'll keep you posted if I discover anything new.

PTUnit( PTUnitNum ).MSCoolingSpeedRatio( Iter ) = VarSpeedCoil( PTUnit( PTUnitNum ).DXCoolCoilIndexNum ).MSRatedAirVolFlowRate( Iter ) / VarSpeedCoil( PTUnit( PTUnitNum ).DXCoolCoilIndexNum ).MSRatedAirVolFlowRate( PTUnit( PTUnitNum ).NumOfSpeedCooling );
PTUnit( PTUnitNum ).CoolVolumeFlowRate( Iter ) = PTUnit( PTUnitNum ).MaxCoolAirVolFlow * PTUnit( PTUnitNum ).MSCoolingSpeedRatio( Iter );
Copy link
Member Author

Choose a reason for hiding this comment

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

@rraustad this is the change I ended up making. I believe this is in line with the changes you had in mind, but you might want to look them over to be sure.

Copy link
Contributor

Choose a reason for hiding this comment

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

This is what I was thinking, but it does scare me a bit. Off design flow rates only work up to a point.

@nealkruis nealkruis added Defect Includes code to repair a defect in EnergyPlus PriorityLow This defect or feature has been declared low priority labels Jun 10, 2016
@nealkruis nealkruis added this to the EnergyPlus 8.6.0 milestone Jun 10, 2016
@@ -515,6 +518,8 @@ namespace HVACManager {

ManageEMS( emsCallFromEndSystemTimestepBeforeHVACReporting, anyEMSRan ); // EMS calling point

CheckMassBalances();
Copy link
Contributor

Choose a reason for hiding this comment

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

So this is staying?

Copy link
Member Author

Choose a reason for hiding this comment

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

It shouldn't add any significant time to the simulation, and we should always be checking for mass conservation problems. There bay be a better time to check these. Ideas?

@rraustad
Copy link
Contributor

I've tried several times and can't pull this branch:

fatal: Unable to create
'C:/Users/Richard/Documents/GitHub/EnergyPlusTeam/.git/refs/remotes/origin/121319197Replace-a-field-name-of-"Controlled-Zone-Name"-in-two-objects-#5664.lock': Invalid argument
Unexpected end of command stream

git did not exit cleanly (exit code 1) (4484 ms @ 6/10/2016 8:17:43 PM)

@lgu1234
Copy link
Contributor

lgu1234 commented Jun 11, 2016

@rraustad I got the same problem when I switched branch. The branch with the problem was created by me. It may contain not-allowed characters. If possible, you may close the branch. I don't know how to close it. I can create it late.

@rraustad
Copy link
Contributor

Deleted that branch, now it's OK


if (abs(Node( Fan( FanNum ).OutletNodeNum ).MassFlowRate - Fan( FanNum ).OutletAirMassFlowRate) > SmallMassFlow) {
ShowFatalError(Fan(FanNum).FanType + ", Name: " + Fan(FanNum).FanName + ": Fan outlet mass flow rate (" + RoundSigDigits(Fan( FanNum ).OutletAirMassFlowRate, 4) + ") does not match outlet node mass flow rate (" + RoundSigDigits(Node( Fan( FanNum ).OutletNodeNum ).MassFlowRate, 4) + ").");
}
Copy link
Contributor

Choose a reason for hiding this comment

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

I see no need for these. Either outlet = inlet or it doesn't.

@rraustad
Copy link
Contributor

These changes are fundamentally what I expected. The parent design flow can be different than the child rated flow. And if so, the child coil rides the capacity and EIR as a function of flow fraction curve. This is how it's supposed to work, but what worries me is the capacity/flow relationship. I guess we allow that for other coil types so let's see what happens here.

@rraustad
Copy link
Contributor

So where's the CI, on vacation? I'm pushin up a change and we can argue what the end result should look like.

PTUnit( PTUnitNum ).MaxCoolAirMassFlow = RhoAir * PTUnit( PTUnitNum ).MaxCoolAirVolFlow;
PTUnit( PTUnitNum ).MaxHeatAirMassFlow = RhoAir * PTUnit( PTUnitNum ).MaxHeatAirVolFlow;

if ( PTUnit( PTUnitNum ).useVSCoilModel && PTUnit( PTUnitNum ).NumOfSpeedCooling == 0 ) {
Copy link
Contributor

Choose a reason for hiding this comment

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

So what is "PTUnit( PTUnitNum ).NumOfSpeedCooling == 0" supposed to mean here?

Copy link
Contributor

@rraustad rraustad Jun 11, 2016

Choose a reason for hiding this comment

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

It must be NumOfSpeedCooling > 0 for multispeed, and = 0 for VS? Or that the speed variables have not be calculated yet?

Copy link
Member Author

Choose a reason for hiding this comment

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

Good question. This was already here when I found it. @EnergyArchmage?

Copy link
Contributor

Choose a reason for hiding this comment

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

yes, it is NumOfSpeedCooling > 0 for multispeed, and = 0 for VS. I think these have been moving to use the bool over time, moving away from == 0 for VS, but it still lingers.

@rraustad
Copy link
Contributor

I've looked at this back and forth and don't see any issue with Neal's logic. Can't wait to see some results.

@mjwitte
Copy link
Contributor

mjwitte commented Jun 11, 2016

@rraustad Regarding CI, it's been messed up since sometime late Thursday. @Myoldmopar is working on it.

@nealkruis
Copy link
Member Author

nealkruis commented Jun 13, 2016

@rraustad @mjwitte

Results are coming back. There are 8 testfiles with mass balance problems (with links to the problem parent objects):

@mjwitte
Copy link
Contributor

mjwitte commented Sep 6, 2016

@nealkruis @rraustad What is the status on this PR? Is it ready for final review and merge? Since the mass balance checks were moved out of here, the overview at the top needs to be revised.

@rraustad
Copy link
Contributor

rraustad commented Sep 6, 2016

Not sure what to do with this one. I believe the change made to the VS DX coil altered the model where the Field: Nominal Speed Level is no longer used as intended (see Jul 18 comment above).

@nealkruis
Copy link
Member Author

@rraustad The Nominal Speed Level is still used to determine the actual capacities and air flow rates of the various speeds from the catalogue data (see the VS coil docs). This happens in VariableSpeedCoils.cc when the input is processed. In my understanding, the nominal rating values shouldn't be used elsewhere in the simulation (e.g., PackagedTerminalHeatPump.cc, or HVACUnitarySystem.cc).

@mjwitte I think the same change needs to happen in any parent object that uses variable speed coils (both heating and cooling). I don't have time immediately to look into this, but perhaps someone else can?

@nrel-bot-3
Copy link

@nealkruis @lgentile it has been 14 days since this pull request was last updated.

4 similar comments
@nrel-bot-3
Copy link

@nealkruis @lgentile it has been 14 days since this pull request was last updated.

@nrel-bot-3
Copy link

@nealkruis @lgentile it has been 14 days since this pull request was last updated.

@nrel-bot-3
Copy link

@nealkruis @lgentile it has been 14 days since this pull request was last updated.

@nrel-bot-3
Copy link

@nealkruis @lgentile it has been 14 days since this pull request was last updated.

@nrel-bot
Copy link

@nealkruis @lgentile it has been 42 days since this pull request was last updated.

@nrel-bot-3
Copy link

@nealkruis @lgentile it has been 15 days since this pull request was last updated.

@nrel-bot-3
Copy link

@nealkruis @lgentile it has been 14 days since this pull request was last updated.

4 similar comments
@nrel-bot-3
Copy link

@nealkruis @lgentile it has been 14 days since this pull request was last updated.

@nrel-bot-3
Copy link

@nealkruis @lgentile it has been 14 days since this pull request was last updated.

@nrel-bot-3
Copy link

@nealkruis @lgentile it has been 14 days since this pull request was last updated.

@nrel-bot
Copy link

@nealkruis @lgentile it has been 14 days since this pull request was last updated.

@rraustad
Copy link
Contributor

Now running into this same thing with UnitarySystem. The VS coil "Rated" volume flow rate, if autosized, is the same as MSRatedAirVolFlowRate(MaxSpeed). If it's not autosized, then these are different. Then in the parent object the ratio of Rated to MSRated is used. This change uses the ratio as MSRated(x) to MSRated(max) and fixes the problem. Still very wary but this change looks good at this point.

@rraustad rraustad changed the title Variable speed coils can have higher flow rate than system and fan Variable speed coils can have higher flow rate than Packaged Terminal unit and fan Aug 18, 2017
@rraustad rraustad merged commit 0959901 into develop Aug 18, 2017
@rraustad
Copy link
Contributor

This change is consistent with what I saw with UnitarySystem. I am also keeping a close eye on VS coil performance and sizing.

@rraustad rraustad deleted the conservation-tests branch August 18, 2017 19:22
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.

9 participants