Skip to content

Commit

Permalink
fix unit test
Browse files Browse the repository at this point in the history
  • Loading branch information
Yujie Xu committed Oct 25, 2024
1 parent 4e05f26 commit a39086f
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions tst/EnergyPlus/unit/HVACVariableRefrigerantFlow.unit.cc
Original file line number Diff line number Diff line change
Expand Up @@ -2591,9 +2591,9 @@ TEST_F(EnergyPlusFixture, VRF_FluidTCtrl_VRFOU_Compressor)

// Test
EXPECT_NEAR(1.0, CyclingRatio, 0.01);
EXPECT_NEAR(4654, OUEvapHeatExtract, 1); // low load calculation, min speed capacity should use the curve corresponding to the lowest speed
EXPECT_NEAR(3536, OUEvapHeatExtract, 1); // low load calculation, min speed capacity should use the curve corresponding to the lowest speed
EXPECT_NEAR(1500, CompSpdActual, 1);
EXPECT_NEAR(2080, Ncomp, 1);
EXPECT_NEAR(2082, Ncomp, 1);
EXPECT_EQ(state->dataLoopNodes->Node(state->dataHVACVarRefFlow->VRFTU(1).VRFTUInletNodeNum).MassFlowRate, 0.0);

// Inputs_condition for an even lower load, and a more strict Te lower bound
Expand Down Expand Up @@ -2625,14 +2625,14 @@ TEST_F(EnergyPlusFixture, VRF_FluidTCtrl_VRFOU_Compressor)
Ncomp,
CyclingRatio);

EXPECT_NEAR(0.20, CyclingRatio, 0.01);
EXPECT_NEAR(0.22, CyclingRatio, 0.01);
Real64 x = T_discharge;
Real64 y = -5; // in low load modification
Real64 CurveValueEvap = 3.19E-01 - 1.26E-03 * x - 2.15E-05 * x * x + 1.20E-02 * y + 1.05E-04 * y * y - 8.66E-05 * x * y;
Real64 CurveValuePower = 8.79E-02 - 1.72E-04 * x + 6.93E-05 * x * x - 3.38E-05 * y - 8.10E-06 * y * y - 1.04E-05 * x * y;
EXPECT_NEAR(CurveValueEvap * state->dataHVACVarRefFlow->VRF(1).RatedEvapCapacity, OUEvapHeatExtract, 1);
EXPECT_NEAR(1500, CompSpdActual, 1);
EXPECT_NEAR(CurveValuePower * state->dataHVACVarRefFlow->VRF(1).RatedCompPower, Ncomp, 1);
EXPECT_NEAR(CurveValuePower * state->dataHVACVarRefFlow->VRF(1).RatedCompPower * CyclingRatio, Ncomp, 1);
EXPECT_EQ(state->dataLoopNodes->Node(state->dataHVACVarRefFlow->VRFTU(1).VRFTUInletNodeNum).MassFlowRate, 0.0);
}

Expand Down Expand Up @@ -2676,7 +2676,7 @@ TEST_F(EnergyPlusFixture, VRF_FluidTCtrl_VRFOU_Compressor)
thisVRF.RatedEvapCapacity * CurveValue(*state, thisVRF.OUCoolingCAPFT(1), thisVRF.CondensingTemp, thisVRF.EvaporatingTemp);
Real64 CompEvaporatingPWRSpdMin =
thisVRF.RatedCompPower * CurveValue(*state, thisVRF.OUCoolingPWRFT(1), thisVRF.CondensingTemp, thisVRF.EvaporatingTemp);
EXPECT_NEAR(0.35, CyclingRatio, 0.01);
EXPECT_NEAR(0.33, CyclingRatio, 0.01);
EXPECT_NEAR(OUEvapHeatExtract, CompEvaporatingCAPSpdMin + Ncomp, 1e-4);
EXPECT_NEAR(1500, CompSpdActual, 1);
EXPECT_NEAR(Ncomp, CompEvaporatingPWRSpdMin, 1e-4);
Expand Down Expand Up @@ -13365,7 +13365,7 @@ TEST_F(EnergyPlusFixture, VRF_FluidTCtrl_ReportOutputVerificationTest)
EXPECT_NEAR(5645.5696, thisVRFTU.TotalCoolingRate, 0.0001);
EXPECT_NEAR(84.8359, thisFan->totalPower, 0.0001);
EXPECT_NEAR(thisDXCoolingCoil.TotalCoolingEnergyRate, (thisVRFTU.TotalCoolingRate + thisFan->totalPower), 0.0001);
EXPECT_NEAR(0.4124, state->dataHVACVarRefFlow->VRF(1).VRFCondCyclingRatio, 0.0001);
EXPECT_NEAR(0.4036, state->dataHVACVarRefFlow->VRF(1).VRFCondCyclingRatio, 0.0001);
EXPECT_NEAR(state->dataHVACVarRefFlow->VRF(1).OUFanPower,
state->dataHVACVarRefFlow->VRF(1).RatedOUFanPower * state->dataHVACVarRefFlow->VRF(1).VRFCondCyclingRatio,
0.0001);
Expand Down

4 comments on commit a39086f

@nrel-bot-2b
Copy link

Choose a reason for hiding this comment

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

fixVRFhighCOP (Unknown) - x86_64-Linux-Ubuntu-22.04-gcc-11.4: Tests Failed (0 of 0 tests passed, 0 test warnings)

Build Badge Test Badge

@nrel-bot-2b
Copy link

Choose a reason for hiding this comment

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

fixVRFhighCOP (Unknown) - x86_64-Linux-Ubuntu-22.04-gcc-11.4-IntegrationCoverage-RelWithDebInfo: Tests Failed (0 of 0 tests passed, 0 test warnings)

Build Badge Test Badge Coverage Badge

@nrel-bot
Copy link

Choose a reason for hiding this comment

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

fixVRFhighCOP (Unknown) - Win64-Windows-10-VisualStudio-16: OK (2894 of 2894 tests passed, 0 test warnings)

Build Badge Test Badge

@nrel-bot-2
Copy link

Choose a reason for hiding this comment

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

fixVRFhighCOP (Unknown) - x86_64-Linux-Ubuntu-22.04-gcc-11.4-UnitTestsCoverage-RelWithDebInfo: OK (2098 of 2098 tests passed, 0 test warnings)

Build Badge Test Badge Coverage Badge

Please sign in to comment.