-
Notifications
You must be signed in to change notification settings - Fork 392
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
Simulate CoilSystem:Cooling:DX using AirloopHVAC:UnitarySystem code base #8729
Simulate CoilSystem:Cooling:DX using AirloopHVAC:UnitarySystem code base #8729
Conversation
ASHRAE9012016_SchoolSecondary_Denver error file diff on CI is confused. They are nearly the same. |
Summary of Diffs. All others not listed are Warmup Convergence diffs. I did not try to determine if Table diffs were a result of row changes.
|
…lSystem-To-UnitarySystem
…lSystem-To-UnitarySystem
OnOffAirFlowRatio); | ||
|
||
OutletHumRatHS = state.dataLoopNodes->Node(this->CoolCoilOutletNodeNum).HumRat; | ||
for (int speedNum = SpeedNum; speedNum <= this->m_NumOfSpeedCooling; ++speedNum) { |
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.
Issue found while converting HVACDXSystem.unit.cc tests. The VS coil was not looping through higher speeds to get to the humrat set point. Thanks goodness for unit tests. Documented in #8883.
@@ -565,7 +563,6 @@ void SimOAComponent(EnergyPlusData &state, | |||
OACoolingCoil = true; | |||
} else if (CompTypeNum == SimAirServingZones::CompType::DXSystem) { // CoilSystem:Cooling:DX old 'AirLoopHVAC:UnitaryCoolOnly' |
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.
@rraustad Do we have a regression test file that uses CoilSystem:Cooling:DX in an AirloopHVAC:OutdoorAirSystem?
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 have only found water coils in the OA system. I could create one using an existing example file. I also need a test file for the faults model as well.
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.
There is something strange happening. I added CoilSystem:Cooling:DX to OA System in FurnaceWithDXSystemRHControl. In this file there is a UnitarySystem in the air loop, and I added CoilSystem to the OA system. That's a good test of multiple objects in the same file.
Existing:
Branch,
Air Loop Main Branch, !- Name
, !- Pressure Drop Curve Name
AirLoopHVAC:OutdoorAirSystem, !- Component 1 Object Type
OA Sys 1, !- Component 1 Name
Outdoor Air Mixer Inlet Node, !- Component 1 Inlet Node Name
Mixed Air Node, !- Component 1 Outlet Node Name
AirLoopHVAC:UnitarySystem, !- Component 2 Object Type
GasHeat DXAC Furnace 1, !- Component 2 Name
Mixed Air Node, !- Component 2 Inlet Node Name
Air Loop Outlet Node; !- Component 2 Outlet Node Name
New CoilSystem added to OA system:
AirLoopHVAC:OutdoorAirSystem:EquipmentList,
OA Sys 1 Equipment, !- Name
CoilSystem:Cooling:DX, !- Component 1 Object Type
OA DX Cooling Coil, !- Component 1 Name
OutdoorAir:Mixer, !- Component 2 Object Type
OA Mixing Box 1; !- Component 2 Name
Sim is crashing on this->AirInNode = 0 here.
Real64 tempMassFlowRateMaxAvail = state.dataLoopNodes->Node(this->AirInNode).MassFlowRateMaxAvail;
The thing is I see it setting that node num during getInput. I wonder if this is like report vars that this needs to be set once all systems are gotten. Still looking at this one.
@rraustad I have run to similar problem for coilSystem water coil. I suspect that you may need to add the following code in getDXCoilSystemData() as well:
|
…lSystem-To-UnitarySystem
I looked at AtticRoof_RadiantBarriers for why it has big table diffs. This input file has a UnitarySystem and the rows are switched in the Annual and Peak Values - Electricity table. The values were the same as before. |
DXCoils::SimDXCoilMultiSpeed(state, CompName, SpeedRatio, CycRatio, this->m_CoolingCoilIndex); | ||
OutletTemp = state.dataDXCoils->DXCoilOutletTemp(this->m_CoolingCoilIndex); | ||
if (OutletTemp < DesOutTemp && SensibleLoad) break; // this isn't going to work IF dehumidIFying | ||
if (SpeedRatio == 1) { |
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 should be speedRatio not SpeedRatio
@@ -867,7 +865,8 @@ namespace OutdoorAirUnit { | |||
} else if (SELECT_CASE_var == "COILSYSTEM:COOLING:DX") { | |||
OutAirUnit(OAUnitNum).OAEquip(CompNum).ComponentType_Num = CompType::DXSystem; | |||
// set the data for 100% DOAS DX cooling coil | |||
CheckDXCoolingCoilInOASysExists(state, OutAirUnit(OAUnitNum).OAEquip(CompNum).ComponentName); | |||
// is a different function call needed here? similar to one in HVACDXSystem | |||
// CheckDXCoolingCoilInOASysExists(state, OutAirUnit(OAUnitNum).OAEquip(CompNum).ComponentName); |
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.
Need to follow-up on this.
@@ -14409,7 +14409,7 @@ void ComputeTableBodyUsingMovingAvg(EnergyPlusData &state, | |||
// if exterior is other side coefficients using ground preprocessor terms then | |||
// set it to ground instead of other side coefficients | |||
if (curExtBoundCond == OtherSideCoefNoCalcExt || curExtBoundCond == OtherSideCoefCalcExt) { | |||
if (has_prefixi(state.dataSurface->OSC(state.dataSurface->Surface(kSurf).OSCPtr).Name, "surfPropOthSdCoef")) { | |||
if (has_prefixi(AsString(state.dataSurface->OSC(state.dataSurface->Surface(kSurf).OSCPtr).Name), "surfPropOthSdCoef")) { |
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.
Try taking this back out...maybe a fluke?
@@ -3464,7 +3463,10 @@ void SimAirLoopComponents(EnergyPlusData &state, | |||
FirstHVACIteration, | |||
AirLoopNum, | |||
PrimaryAirSystems(AirLoopNum).Branch(BranchNum).Comp(CompNum).CompIndex, | |||
PrimaryAirSystems(AirLoopNum).Branch(BranchNum).Comp(CompNum).compPointer); | |||
PrimaryAirSystems(AirLoopNum).Branch(BranchNum).Comp(CompNum).compPointer, | |||
AirLoopNum, |
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.
Take out the extra AirLoopNum here.
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 walked through this with @rraustad line-by-line. What a massive effort. I see nothing red-flag. There are some yellow-flags that I have noted that we should consider as we clean this up, but this should be ready to go. I'll do a final check after all the recent merges to develop, but this will drop soon. 🎈
@Nigusse when this does merge, it will cause conflicts in your work. Let me know if you want some assistance proceeding with resolving them. Because of the major work in the unitary system, it may be better to pull your changes in manually. (Make sure to save your changes before trying the merge). CI results are looking great, but we want to spot check a couple things:
|
We are all good with UnitarySystem_SubcoolReheatDX Just a reorder! @rraustad if you get that supply fan thing working then we should be ready to merge! |
VariableSpeedCoils::getCoilTypeAndName(state, this->m_CoolingCoilIndex, coilType, coilName, errorsFound); | ||
if (!errorsFound) coilDataSet = true; | ||
} else if (this->m_CoolingCoilIndex == DataHVACGlobals::CoilDX_CoolingSingleSpeed) { | ||
// need to check for all other coil types |
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.
HVACDXSystem only did this for VS coils. Will open this up in a future pass.
if (!state.dataHVACDXSys->DXCoolingSystem(DXSystemNum).VSCoilFanInfoSet && AirLoopNum > 0) {
if (state.dataHVACDXSys->DXCoolingSystem(DXSystemNum).CoolingCoilType_Num == Coil_CoolingAirToAirVariableSpeed) {
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.
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.
Great!!
Alllright, I think that was the last thing. This should be ready. I built once again with latest develop and ran the unit test suite then ran the full regression suite. Everything looks good. Still similar to what CI reported last, but now some improvements. Now DesiccantDehumidiferWithAirToAirCoil is small table diffs instead of large, thanks to @rraustad last change. Nice. I'm going to merge this down now. This is a crucial step forward as we continue to refactor the coils and parent objects in a more manageable and robust direction. |
Thank goodness! Who wants to do the next one? |
Pull request overview
Fixes UnitarySystem used in OutdoorAirUnit does not size cooling coil air flow properly #8751
Fixes UnitarySystem does not correctly size Coil:Cooling:DX:TwoStageWithHumidityControlMode #8761
Fixes CoilSystem:Cooling:DX with Coil:Cooling:TwoSpeed does not control humidity #8849
Fixes AirloopHVAC:UnitarySystem does not control humidity with Coil:Cooling:DX:VariableSpeed when more than 1 speed is used #8883
DESCRIBE PURPOSE OF THIS PULL REQUEST: To execute CoilSystem:Cooling:DX within UnitarySystem to reduce maintenance requirements. Several issues, as shown above, were discovered during this transition.
NOTE: ENHANCEMENTS MUST FOLLOW A SUBMISSION PROCESS INCLUDING A FEATURE PROPOSAL AND DESIGN DOCUMENT PRIOR TO SUBMITTING CODE
Pull Request Author
Add to this list or remove from it as applicable. This is a simple templated set of guidelines.
Reviewer
This will not be exhaustively relevant to every PR.