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

Simulate CoilSystem:Cooling:DX using AirloopHVAC:UnitarySystem code base #8729

Merged
merged 58 commits into from
Jul 16, 2021

Conversation

rraustad
Copy link
Contributor

@rraustad rraustad commented Apr 27, 2021

Pull request overview

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.

  • 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
  • If any defect files are updated to a more recent version, upload new versions here or on DevSupport
  • If IDD requires transition, transition source, rules, ExpandObjects, and IDFs must be updated, and add IDDChange label
  • If structural output changes, add to output rules file and add OutputChange label
  • If adding/removing any LaTeX docs or figures, update that document's CMakeLists file dependencies

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

@rraustad rraustad added the NewFeature Includes code to add a new feature to EnergyPlus label Apr 27, 2021
@mjwitte mjwitte added the Refactoring Includes code changes that don't change the functionality of the program, just perform refactoring label May 1, 2021
@rraustad
Copy link
Contributor Author

rraustad commented May 3, 2021

ASHRAE9012016_SchoolSecondary_Denver error file diff on CI is confused. They are nearly the same.
Compare-eplusout.zip

@rraustad
Copy link
Contributor Author

rraustad commented May 4, 2021

Impact of attempt to fix row order using Mac results.

image

@rraustad
Copy link
Contributor Author

rraustad commented May 5, 2021

Progress since yesterday. It's getting harder to find real diff's. I found one this morning with sizing a coil inside a UnitarySystem inside an OutdoorAirUnit.

image

@rraustad
Copy link
Contributor Author

rraustad commented May 5, 2021

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.
Summary-CoilSystemToUnitarySystem.txt

ASHRAE9012016_RestaurantFastFood_Denver
- Component Sizing Information, Coil:Cooling:DX:TwoSpeed, PSZ-AC_1:1_COOLC DXCOIL, Design Size High Speed Gross Rated Total Cooling Capacity [W], 25758.87372
+ Component Sizing Information, Coil:Cooling:DX:TwoSpeed, PSZ-AC_1:1_COOLC DXCOIL, Design Size High Speed Gross Rated Total Cooling Capacity [W], 24602.74334

ASHRAE9012016_RestaurantSitDown_Denver
- Component Sizing Information, Coil:Cooling:DX:TwoSpeed, PSZ-AC_2:2_COOLC DXCOIL, Design Size High Speed Gross Rated Total Cooling Capacity [W], 29150.58010
+ Component Sizing Information, Coil:Cooling:DX:TwoSpeed, PSZ-AC_2:2_COOLC DXCOIL, Design Size High Speed Gross Rated Total Cooling Capacity [W], 27842.22044

ASHRAE9012016_RetailStandalone_Denver - this new report seems correct but confuses me as to why now
  Component Sizing Information, Coil:Heating:Fuel, PSZ-AC:1_UNITARY_PACKAGE_HEATCOIL, Design Size Nominal Capacity [W], 41416.77458
  Component Sizing Information, Coil:Cooling:DX:TwoSpeed, PSZ-AC:1_UNITARY_PACKAGE_COOLCOIL, User-Specified High Speed Rated Air Flow Rate [m3/s], 1.74507
+ Component Sizing Information, Coil:Cooling:DX:TwoSpeed, PSZ-AC:1_UNITARY_PACKAGE_COOLCOIL, Design Size High Speed Gross Rated Total Cooling Capacity [W], 25957.12624
  Component Sizing Information, Coil:Cooling:DX:TwoSpeed, PSZ-AC:1_UNITARY_PACKAGE_COOLCOIL, User-Specified High Speed Gross Rated Total Cooling Capacity [W], 28887.06000
  Component Sizing Information, Coil:Cooling:DX:TwoSpeed, PSZ-AC:1_UNITARY_PACKAGE_COOLCOIL, User-Specified High Speed Rated Sensible Heat Ratio, 0.79866

ASHRAE9012016_RetailStripmall_Denver - same as above
  Component Sizing Information, Coil:Cooling:DX:TwoSpeed, PSZ-AC_1:1_UNITARY_PACKAGE_COOLCOIL, User-Specified High Speed Rated Air Flow Rate [m3/s], 1.75855
+ Component Sizing Information, Coil:Cooling:DX:TwoSpeed, PSZ-AC_1:1_UNITARY_PACKAGE_COOLCOIL, Design Size High Speed Gross Rated Total Cooling Capacity [W], 24297.89259
  Component Sizing Information, Coil:Cooling:DX:TwoSpeed, PSZ-AC_1:1_UNITARY_PACKAGE_COOLCOIL, User-Specified High Speed Gross Rated Total Cooling Capacity [W], 29110.29000
  Component Sizing Information, Coil:Cooling:DX:TwoSpeed, PSZ-AC_1:1_UNITARY_PACKAGE_COOLCOIL, User-Specified High Speed Rated Sensible Heat Ratio, 0.79866

ASHRAE9012016_SchoolPrimary_Denver - same as above with 1st one removed. Still confusing as to why. The 1st one is greater than 10% different so it should have reported.
  Component Sizing Information, Coil:Cooling:DX:TwoSpeed, PSZ-AC_2:5_UNITARY_PACKAGE_COOLCOIL, User-Specified High Speed Rated Air Flow Rate [m3/s], 0.88609
- Component Sizing Information, Coil:Cooling:DX:TwoSpeed, PSZ-AC_2:5_UNITARY_PACKAGE_COOLCOIL, Design Size High Speed Gross Rated Total Cooling Capacity [W], 17255.86627
  Component Sizing Information, Coil:Cooling:DX:TwoSpeed, PSZ-AC_2:5_UNITARY_PACKAGE_COOLCOIL, User-Specified High Speed Gross Rated Total Cooling Capacity [W], 15055.82000
  Component Sizing Information, Coil:Cooling:DX:TwoSpeed, PSZ-AC_2:5_UNITARY_PACKAGE_COOLCOIL, User-Specified High Speed Rated Sensible Heat Ratio, 0.78918
  Component Sizing Information, Coil:Cooling:DX:TwoSpeed, PSZ-AC_2:5_UNITARY_PACKAGE_COOLCOIL, Design Size Low Speed Rated Air Flow Rate [m3/s], 0.29533
@@ -2050,7 +2049,7 @@
  Component Sizing Information, Fan:ConstantVolume, PSZ-AC_2:7_UNITARY_PACKAGE_FAN, Design Size Maximum Flow Rate [m3/s], 1.48809
  Component Sizing Information, Coil:Heating:Fuel, PSZ-AC_2:7_UNITARY_PACKAGE_HEATCOIL, Design Size Nominal Capacity [W], 83555.97596
  Component Sizing Information, Coil:Cooling:DX:TwoSpeed, PSZ-AC_2:7_UNITARY_PACKAGE_COOLCOIL, User-Specified High Speed Rated Air Flow Rate [m3/s], 1.48809
- Component Sizing Information, Coil:Cooling:DX:TwoSpeed, PSZ-AC_2:7_UNITARY_PACKAGE_COOLCOIL, Design Size High Speed Gross Rated Total Cooling Capacity [W], 33935.71212
+ Component Sizing Information, Coil:Cooling:DX:TwoSpeed, PSZ-AC_2:7_UNITARY_PACKAGE_COOLCOIL, Design Size High Speed Gross Rated Total Cooling Capacity [W], 30701.57114

ASHRAE9012016_SchoolSecondary_Denver - same as above with this new warning which occurred twice
+   ** Warning ** Enthalpy out of range (PsyTsatFnHPb)
+   **   ~~~   **  Routine=CalcMultiSpeedDXCoil:newdewpointconditions,
+   **   ~~~   **  Environment=DENVER-AURORA-BUCKLEY.AFB_CO_USA ANN CLG .4% CONDNS DB=>MWB, at Simulation time=07/21 22:00 - 22:10
+   **   ~~~   **  Enthalpy=-90928.11610 Pressure= 82237.00
+   **   ~~~   **  Initial Resultant Temperature= -59.98

AirflowNetwork_MultiAirLoops - new warning but similar to what was there before
+   ** Warning ** The mass flow rate difference is found between System Node = 'ZONE EQUIPMENT INLET NODE' and AFN Link = 'MAIN LINK 1'.
+   **   ~~~   ** The system node max mass flow rate = 0.753 kg/s. The AFN node mass flow rate = 1.364 kg.s.
    ** Warning ** The mass flow rate difference is found between System Node = 'ZONE 1 INLET NODE ATINLET' and AFN Link = 'ZONE1SUPPLY2LINK'.
    **   ~~~   ** The system node max mass flow rate = 0.753 kg/s. The AFN node mass flow rate = 0.764 kg.s.
    ** Warning ** Please adjust the rate of Maximum Air Flow Rate field in the terminal objects or duct pressure resistance.

AirflowNetwork_MultiZone_SmallOffice_VAV - sizing difference
- Component Sizing Information, Coil:Cooling:DX:TwoSpeed, ACDXCOIL 1, Design Size High Speed Rated Air Flow Rate [m3/s], 1.06000
- Component Sizing Information, Coil:Cooling:DX:TwoSpeed, ACDXCOIL 1, Design Size High Speed Gross Rated Total Cooling Capacity [W], 17546.76378
+ Component Sizing Information, Coil:Cooling:DX:TwoSpeed, ACDXCOIL 1, Design Size High Speed Rated Air Flow Rate [m3/s], 1.00461
+ Component Sizing Information, Coil:Cooling:DX:TwoSpeed, ACDXCOIL 1, Design Size High Speed Gross Rated Total Cooling Capacity [W], 16629.89824

CmplxGlz_SmOff_IntExtShading - big diffs in Coil System Part Load Ratio

DOASDXCOIL_wADPBFMethod - sizing differences in all 4 performance modes, this is the 1st mode
- Component Sizing Information, Coil:Cooling:DX:TwoStageWithHumidityControlMode, DOAS COOLING COIL:DOAS STANDARD PERF 1, Design Size Gross Rated Total Cooling Capacity [W], 8428.75217
- Component Sizing Information, Coil:Cooling:DX:TwoStageWithHumidityControlMode, DOAS COOLING COIL:DOAS STANDARD PERF 1, Design Size Gross Rated Sensible Heat Ratio, 0.62575
+ Component Sizing Information, Coil:Cooling:DX:TwoStageWithHumidityControlMode, DOAS COOLING COIL:DOAS STANDARD PERF 1, Design Size Gross Rated Total Cooling Capacity [W], 12189.71939
+ Component Sizing Information, Coil:Cooling:DX:TwoStageWithHumidityControlMode, DOAS COOLING COIL:DOAS STANDARD PERF 1, Design Size Gross Rated Sensible Heat Ratio, 0.58872

DOASDXCOIL_wADPBFMethod_NoReturnPath - same as above

DisplacementVent_VAV - table diffs with DX Coil Capacity Increase Ratio from Too Low Flow/Capacity Ratio - new issue #8750

EMSThermochromicWindow - same as above

HVACTemplate-5ZonePTAC-DOAS - same sizing issue as DOASDXCOIL_wADPBFMethod

HVACTemplate-5ZonePackagedVAV - same sizing issue as DOASDXCOIL_wADPBFMethod

HybridVentilationControlGlobalSimple - not sure I caught this in previous files, warmup convergence diffs, point to control differences?
-Environment:WarmupDays,  6
+Environment:WarmupDays, 13

IndEvapCoolerRTUoffice - lots of new warnings
+   ** Warning ** CalcDoe2DXCoil: Coil:Cooling:DX:SingleSpeed "ACDXCOIL ZN1" - Full load outlet air dry-bulb temperature < 2C. This indicates the possibility of coil frost/freeze. Outlet temperature = -0.12 C.
+   **   ~~~   **  ...Occurrence info = PHOENIX ANN HTG 99.6% CONDNS DB, 12/21 06:00 - 06:05
+   **   ~~~   ** ... Possible reasons for low outlet air dry-bulb temperatures are: This DX coil
+   **   ~~~   **    1) may have a low inlet air dry-bulb temperature. Inlet air temperature = 19.985 C.
+   **   ~~~   **    2) may have a low air flow rate per watt of cooling capacity. Check inputs.
+   **   ~~~   **    3) is used as part of a HX assisted cooling coil which uses a high sensible effectiveness. Check inputs.

OutdoorAirUnit - fixed this morning. And didn't break anything else?
- Component Sizing Information, Coil:Cooling:DX:SingleSpeed, ACDXCOIL 1, Design Size Rated Air Flow Rate [m3/s], 0.42000
- Component Sizing Information, Coil:Cooling:DX:SingleSpeed, ACDXCOIL 1, Design Size Gross Rated Total Cooling Capacity [W], 9186.05557
+ Component Sizing Information, Coil:Cooling:DX:SingleSpeed, ACDXCOIL 1, Design Size Rated Air Flow Rate [m3/s], 1.26703
+ Component Sizing Information, Coil:Cooling:DX:SingleSpeed, ACDXCOIL 1, Design Size Gross Rated Total Cooling Capacity [W], 27711.88366

OutdoorAirUnitwithAirloopHVAC - same as above, must not have noticed this wasn't working correctly when example file was created

PythonPluginThermochromicWindow - same sizing issue as DOASDXCOIL_wADPBFMethod

ReliefIndEvapCoolerRTUoffice - new warnings
+   ** Warning ** CalcDoe2DXCoil: Coil:Cooling:DX:SingleSpeed "ACDXCOIL ZN5" - Full load outlet air dry-bulb temperature < 2C. This indicates the possibility of coil frost/freeze. Outlet temperature = 1.63 C.
+   **   ~~~   **  ...Occurrence info = PHOENIX ANN HTG 99.6% CONDNS DB, 12/21 06:00 - 06:05
+   **   ~~~   ** ... Possible reasons for low outlet air dry-bulb temperatures are: This DX coil
+   **   ~~~   **    1) may have a low inlet air dry-bulb temperature. Inlet air temperature = 20.347 C.
+   **   ~~~   **    2) may have a low air flow rate per watt of cooling capacity. Check inputs.
+   **   ~~~   **    3) is used as part of a HX assisted cooling coil which uses a high sensible effectiveness. Check inputs.

SmOffPSZ - odd results
DX COOLING COIL SYSTEM 1:Coil System Part Load Ratio  DX COOLING COIL SYSTEM 2:Coil System Part Load Ratio
1.32E+40	999
1.32E+40	999
1.32E+40	999

SmOffPSZ_OnOffStagedControl - similar to CmplxGlz_SmOff_IntExtShading but the diffs are 1, yuck this is staged control Tstat
Coil System Part Load Ratio

SpectralAngularOpticalProperties_TableData - warmup convergence diffs
-Environment:WarmupDays,  6
+Environment:WarmupDays, 13

TermRHDXSystem - same as above

ThermochromicWindow - same as CmplxGlz_SmOff_IntExtShading, DX Coil Capacity Increase Ratio from Too Low Flow/Capacity Ratio

TranspiredCollectors - lots of new warnings
+   ** Warning ** CalcDoe2DXCoil: Coil:Cooling:DX:SingleSpeed "ACDXCOIL ZN1" - Air-cooled condenser inlet dry-bulb temperature below 0 C. Outdoor dry-bulb temperature = -20.00
+   **   ~~~   **  ... Occurrence info = DENVER_STAPLETON ANN HTG 99.6% CONDNS DB, 12/21 00:00 - 00:15
+   **   ~~~   ** ... Operation at low ambient temperatures may require special performance curves.

ZoneCoupledKivaRefBldgMediumOfficeNoClg - sizing issue
- Component Sizing Information, Coil:Cooling:DX:TwoSpeed, VAV_1_COOLC DXCOIL, Design Size High Speed Rated Air Flow Rate [m3/s], 2.13856
- Component Sizing Information, Coil:Cooling:DX:TwoSpeed, VAV_1_COOLC DXCOIL, Design Size High Speed Gross Rated Total Cooling Capacity [W], 53105.51758
+ Component Sizing Information, Coil:Cooling:DX:TwoSpeed, VAV_1_COOLC DXCOIL, Design Size High Speed Rated Air Flow Rate [m3/s], 1.11728
+ Component Sizing Information, Coil:Cooling:DX:TwoSpeed, VAV_1_COOLC DXCOIL, Design Size High Speed Gross Rated Total Cooling Capacity [W], 27744.78393

_DOASDXCOIL_wUserSHRMethod - same as above

_FanCoilHybridVentAFN - warmup convergence diffs
-Environment:WarmupDays,  6
+Environment:WarmupDays, 10

@rraustad rraustad changed the title Coil system to unitary system Simulate CoilSystem:Cooling:DX using AirloopHVAC:UnitarySystem code base Jul 13, 2021
OnOffAirFlowRatio);

OutletHumRatHS = state.dataLoopNodes->Node(this->CoolCoilOutletNodeNum).HumRat;
for (int speedNum = SpeedNum; speedNum <= this->m_NumOfSpeedCooling; ++speedNum) {
Copy link
Contributor Author

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'
Copy link
Contributor

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?

Copy link
Contributor Author

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.

Copy link
Contributor Author

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.

image

@Nigusse
Copy link
Contributor

Nigusse commented Jul 14, 2021

@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:

                int sysNum = getUnitarySystemIndex(state, thisObjectName);
                UnitarySys thisSys;
                if (sysNum == -1) {
                    ++state.dataUnitarySystems->numUnitarySystems;
                    auto const &thisObjName = instance.key();
                    state.dataInputProcessing->inputProcessor->markObjectAsUsed(cCurrentModuleObject, thisObjName);
                } else {
                    thisSys = state.dataUnitarySystems->unitarySys[sysNum];
                }

@rraustad
Copy link
Contributor Author

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) {
Copy link
Member

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);
Copy link
Member

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")) {
Copy link
Member

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,
Copy link
Member

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.

Copy link
Member

@Myoldmopar Myoldmopar left a 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. 🎈

@Myoldmopar
Copy link
Member

@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:

  • @rraustad will look at DesiccantDehumidifierWithAirToAirCoil tabular output -- it seems the supply fan is not being reported in a certain table row
  • @Myoldmopar will look at UnitarySystem_SubcoolReheatDX to see if the numerics are changing or if the rows are reordered.

@Myoldmopar
Copy link
Member

We are all good with UnitarySystem_SubcoolReheatDX

Develop:
image

This branch:
image

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
Copy link
Contributor Author

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) {

Copy link
Contributor Author

Choose a reason for hiding this comment

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

DesiccantDehumidifierWithAirToAirCoil tabular output now reports the fan associated with the DXSystem.

image

There are some files not reporting this information and now I know why. E.g., UnitarySystem_DXCoilSystemAuto which uses a UnitarySystem to mimic the CoilSystem file DXCoilSystemAuto.

image

Copy link
Member

Choose a reason for hiding this comment

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

Great!!

@Myoldmopar
Copy link
Member

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.

@Myoldmopar Myoldmopar merged commit b450ba4 into NREL:develop Jul 16, 2021
@Myoldmopar Myoldmopar deleted the CoilSystem-To-UnitarySystem branch July 16, 2021 22:04
@rraustad
Copy link
Contributor Author

Thank goodness! Who wants to do the next one?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
NewFeature Includes code to add a new feature to EnergyPlus Refactoring Includes code changes that don't change the functionality of the program, just perform refactoring
Projects
None yet
10 participants