diff --git a/doc/src/docs/InputOutputReference/01d-InputOutputReference.md b/doc/src/docs/InputOutputReference/01d-InputOutputReference.md index 440cce83dd4..c248349d6e3 100644 --- a/doc/src/docs/InputOutputReference/01d-InputOutputReference.md +++ b/doc/src/docs/InputOutputReference/01d-InputOutputReference.md @@ -5589,22 +5589,22 @@ Following is an example IDF use of the object: ```idf Coil:Cooling:DX:TwoStageWithHumidityControlMode, - DOAS Cooling Coil, !- Name - HVACTemplate-Always 1, !- Availability Schedule Name - DOAS Supply Fan Outlet, !- Air Inlet Node Name - DOAS Cooling Coil Outlet, !- Air Outlet Node Name - , !- Crankcase Heater Capacity - , !- Maximum Outdoor Dry-Bulb Temperature for Crankcase Heater - 2, !- Number of Capacity Stages - 1, !- Number of Enhanced Dehumidification Modes + DOAS Cooling Coil, !- Name + HVACTemplate-Always 1, !- Availability Schedule Name + DOAS Supply Fan Outlet, !- Air Inlet Node Name + DOAS Cooling Coil Outlet, !- Air Outlet Node Name + , !- Crankcase Heater Capacity + , !- Maximum Outdoor Dry-Bulb Temperature for Crankcase Heater + 2, !- Number of Capacity Stages + 1, !- Number of Enhanced Dehumidification Modes CoilPerformance:DX:Cooling, !- Normal Mode Stage 1 Coil Performance Object Type - DOAS Standard Perf 1, !- Normal Mode Stage 1 Coil Performance Name + DOAS Standard Perf 1, !- Normal Mode Stage 1 Coil Performance Name CoilPerformance:DX:Cooling, !- Normal Mode Stage 1+2 Coil Performance Object Type - DOAS Standard Perf 1+2, !- Normal Mode Stage 1+2 Coil Performance Name + DOAS Standard Perf 1+2, !- Normal Mode Stage 1+2 Coil Performance Name CoilPerformance:DX:Cooling, !- Dehumidification Mode 1 Stage 1 Coil Performance Object Type - DOAS Dehumid Perf 1, !- Dehumidification Mode 1 Stage 1 Coil Performance Name + DOAS Dehumid Perf 1, !- Dehumidification Mode 1 Stage 1 Coil Performance Name CoilPerformance:DX:Cooling, !- Dehumidification Mode 1 Stage 1+2 Coil Performance Object Type - DOAS Dehumid Perf 1+2; !- Dehumidification Mode 1 Stage 1+2 Coil Performance Name + DOAS Dehumid Perf 1+2; !- Dehumidification Mode 1 Stage 1+2 Coil Performance Name ``` ### Coil:Cooling:DX:MultiSpeed @@ -5639,7 +5639,7 @@ This optional alpha field specifies the outdoor air node name used to define the #### Field: Condenser Type -#### The type of condenser used by the multispeed DX cooling coil. Valid choices for this input field areAirCooled orEvaporativelyCooled. The default for this field isAirCooled. +The type of condenser used by the multispeed DX cooling coil. Valid choices for this input field are AirCooled or EvaporativelyCooled. The default for this field is AirCooled. #### Field: Supply Water Storage Tank Name @@ -5767,7 +5767,7 @@ The fraction of energy input to the cooling coil that is available as recoverabl #### Field: Speed <x> Waste Heat Function of Temperature Curve Name -The name of a biquadratic performance curve (ref: Performance Curves) that parameterizes the variation of the waste heat recovery as a function of outdoor dry-bulb temperature and the entering coil dry-bulb temperature at Speed <x>. The output of this curve is multiplied by the rated waste heat fraction at specific temperature operating conditions (i.e., at temperatures different from the rating point). The curve is normalized to a value of 1.0 at the rating point. When the fuel type is electricity, this field can remain blank since it is ignored by the program in this instance. +The name of a biquadratic performance curve (ref: Performance Curves) that parameterizes the variation of the waste heat recovery as a function of outdoor dry-bulb temperature and the entering coil dry-bulb temperature at Speed <x>. The output of this curve is multiplied by the rated waste heat fraction at specific temperature operating conditions (i.e., at temperatures different from the rating point). The curve is normalized to a value of 1.0 at the rating point. When the fuel type is electricity, this field can remain blank since it is ignored by the program in this instance. When the fuel type is not electricity and the parent object AirLoopHVAC:UnitaryHeatPump:AirToAir:MultiSpeed does not require waste heat calculations, this field is ignored. If the field is blank, a warning will be issued and simulation continues. When the fuel type is not electricity and the parent object AirLoopHVAC:UnitaryHeatPump:AirToAir:MultiSpeed requires waste heat calculations, if this field is left blank, the program assumes a constant value of 1 to make simulation continue and a warning will be issued. #### Field: Speed <x> Evaporative Condenser Effectiveness @@ -7203,7 +7203,7 @@ The fraction of heat input to heating that is available as recoverable waste hea #### Field: Speed <x> Waste Heat Function of Temperature Curve Name -The name of a bi-quadratic performance curve (ref: Performance Curves) that parameterizes the variation of the waste heat recovery as a function of outdoor dry-bulb temperature and the entering coil dry-bulb temperature for Speed <x>. The output of this curve is multiplied by the rated recoverable waste heat at specific temperature operating conditions (i.e., at temperatures different from the rating point). The curve is normalized to a value of 1.0 at the rating point. When the fuel type is electricity, the field is either left blank or ignored by the program. +The name of a bi-quadratic performance curve (ref: Performance Curves) that parameterizes the variation of the waste heat recovery as a function of outdoor dry-bulb temperature and the entering coil dry-bulb temperature for Speed <x>. The output of this curve is multiplied by the rated recoverable waste heat at specific temperature operating conditions (i.e., at temperatures different from the rating point). The curve is normalized to a value of 1.0 at the rating point. When the fuel type is electricity, the field is either left blank or ignored by the program. When the fuel type is not electricity and the parent object AirLoopHVAC:UnitaryHeatPump:AirToAir:MultiSpeed does not require waste heat calculations, this field is ignored. If the field is blank, a warning will be issued and simulation continues. When the fuel type is not electricity and the parent object AirLoopHVAC:UnitaryHeatPump:AirToAir:MultiSpeed requires waste heat calculations, if this field is left blank, the program assumes a constant value of 1 to make simulation continue and a warning will be issued. #### Field: Zone Name for Evaporator Placement diff --git a/idd/Energy+.idd.in b/idd/Energy+.idd.in index 1a2346ace56..1f582641675 100644 --- a/idd/Energy+.idd.in +++ b/idd/Energy+.idd.in @@ -42015,11 +42015,11 @@ Coil:Cooling:DX:MultiSpeed, \note startup. Suggested value is 45; zero value means latent degradation \note model is disabled. N15, \field Speed 1 Rated Waste Heat Fraction of Power Input - \required-field \type real \units dimensionless \minimum> 0.0 \maximum 1.0 + \default 0.2 \note Recoverable waste heat at full load and rated conditions A18, \field Speed 1 Waste Heat Function of Temperature Curve Name \type object-list @@ -42171,11 +42171,11 @@ Coil:Cooling:DX:MultiSpeed, \note startup. Suggested value is 45; zero value means latent degradation \note model is disabled. N28, \field Speed 2 Rated Waste Heat Fraction of Power Input - \required-field \type real \units dimensionless \minimum> 0.0 \maximum 1.0 + \default 0.2 \note Recoverable waste heat at full load and rated conditions A24, \field Speed 2 Waste Heat Function of Temperature Curve Name \type object-list @@ -42323,6 +42323,7 @@ Coil:Cooling:DX:MultiSpeed, \units dimensionless \minimum> 0.0 \maximum 1.0 + \default 0.2 \note Recoverable waste heat at full load and rated conditions A30, \field Speed 3 Waste Heat Function of Temperature Curve Name \type object-list @@ -42470,6 +42471,7 @@ Coil:Cooling:DX:MultiSpeed, \units dimensionless \minimum> 0.0 \maximum 1.0 + \default 0.2 \note Recoverable waste heat at full load and rated conditions A36, \field Speed 4 Waste Heat Function of Temperature Curve Name \type object-list @@ -44570,11 +44572,11 @@ Coil:Heating:DX:MultiSpeed, \note cubic curve = a + b*PLR + c*PLR**2 + d*PLR**3 \note PLR = part load ratio (sensible heating load/steady state heating capacity) N14, \field Speed 1 Rated Waste Heat Fraction of Power Input - \required-field \type real \units dimensionless \minimum> 0.0 \maximum 1.0 + \default 0.2 \note recoverable waste heat at full load and rated conditions A15, \field Speed 1 Waste Heat Function of Temperature Curve Name \type object-list @@ -44669,11 +44671,11 @@ Coil:Heating:DX:MultiSpeed, \note cubic curve = a + b*PLR + c*PLR**2 + d*PLR**3 \note PLR = part load ratio (sensible heating load/steady state heating capacity) N19, \field Speed 2 Rated Waste Heat Fraction of Power Input - \required-field \type real \units dimensionless \minimum> 0.0 \maximum 1.0 + \default 0.2 \note recoverable waste heat at full load and rated conditions A21, \field Speed 2 Waste Heat Function of Temperature Curve Name \type object-list @@ -44764,6 +44766,7 @@ Coil:Heating:DX:MultiSpeed, \units dimensionless \minimum> 0.0 \maximum 1.0 + \default 0.2 \note recoverable waste heat at full load and rated conditions A27, \field Speed 3 Waste Heat Function of Temperature Curve Name \type object-list @@ -44854,6 +44857,7 @@ Coil:Heating:DX:MultiSpeed, \units dimensionless \minimum> 0.0 \maximum 1.0 + \default 0.2 \note recoverable waste heat at full load and rated conditions A33, \field Speed 4 Waste Heat Function of Temperature Curve Name \type object-list diff --git a/src/EnergyPlus/DXCoils.cc b/src/EnergyPlus/DXCoils.cc index 7a848fcb9a6..9e56d046445 100644 --- a/src/EnergyPlus/DXCoils.cc +++ b/src/EnergyPlus/DXCoils.cc @@ -4093,16 +4093,7 @@ namespace DXCoils { // Read waste heat modifier curve name DXCoil( DXCoilNum ).MSWasteHeat( I ) = GetCurveIndex( Alphas( 18 + ( I - 1 ) * 6 ) ); // convert curve name to number if ( DXCoil( DXCoilNum ).FuelType != FuelTypeElectricity ) { - if ( DXCoil( DXCoilNum ).MSWasteHeat( I ) == 0 ) { - if ( lAlphaBlanks( 18 + ( I - 1 ) * 6 ) ) { - ShowSevereError( RoutineName + CurrentModuleObject + "=\"" + DXCoil( DXCoilNum ).Name + "\", missing" ); - ShowContinueError( "...required " + cAlphaFields( 18 + ( I - 1 ) * 6 ) + " is blank." ); - } else { - ShowSevereError( RoutineName + CurrentModuleObject + "=\"" + DXCoil( DXCoilNum ).Name + "\", invalid" ); - ShowContinueError( "...not found " + cAlphaFields( 18 + ( I - 1 ) * 6 ) + "=\"" + Alphas( 18 + ( I - 1 ) * 6 ) + "\"." ); - } - ErrorsFound = true; - } else { + if ( DXCoil( DXCoilNum ).MSWasteHeat( I ) > 0 ) { // Verify Curve Object, only legal types are BiQuadratic { auto const SELECT_CASE_var( GetCurveType( DXCoil( DXCoilNum ).MSWasteHeat( I ) ) ); @@ -4608,16 +4599,7 @@ namespace DXCoils { // Read waste heat modifier curve name DXCoil( DXCoilNum ).MSWasteHeat( I ) = GetCurveIndex( Alphas( 15 + ( I - 1 ) * 6 ) ); // convert curve name to number if ( DXCoil( DXCoilNum ).FuelType != FuelTypeElectricity ) { - if ( DXCoil( DXCoilNum ).MSWasteHeat( I ) == 0 ) { - if ( lAlphaBlanks( 11 ) ) { - ShowSevereError( RoutineName + CurrentModuleObject + "=\"" + DXCoil( DXCoilNum ).Name + "\", missing" ); - ShowContinueError( "...required " + cAlphaFields( 15 + ( I - 1 ) * 6 ) + " is blank." ); - } else { - ShowSevereError( RoutineName + CurrentModuleObject + "=\"" + DXCoil( DXCoilNum ).Name + "\", invalid" ); - ShowContinueError( "...not found " + cAlphaFields( 15 + ( I - 1 ) * 6 ) + "=\"" + Alphas( 15 + ( I - 1 ) * 6 ) + "\"." ); - } - ErrorsFound = true; - } else { + if ( DXCoil( DXCoilNum ).MSWasteHeat( I ) > 0 ) { // Verify Curve Object, only legal types are BiQuadratic { auto const SELECT_CASE_var( GetCurveType( DXCoil( DXCoilNum ).MSWasteHeat( I ) ) ); @@ -5413,6 +5395,7 @@ namespace DXCoils { int DXCoilNumTemp; // Counter for crankcase heater report variable DO loop int AirInletNode; // Air inlet node number int SecZoneAirNodeNum; // secondary DX coil inlet node number ( secondary zone air node) + int SpeedNum; // Speed number for multispeed coils if ( MyOneTimeFlag ) { // initialize the environment and sizing flags @@ -5457,6 +5440,20 @@ namespace DXCoils { MyEnvrnFlag( DXCoilNum ) = false; } + if ( ( DXCoil( DXCoilNum ).DXCoilType_Num == CoilDX_MultiSpeedCooling || DXCoil( DXCoilNum ).DXCoilType_Num == CoilDX_MultiSpeedHeating ) && MyEnvrnFlag( DXCoilNum ) ) { + if ( DXCoil( DXCoilNum ).FuelType != FuelTypeElectricity ) { + if (DXCoil( DXCoilNum ).MSHPHeatRecActive ) { + for ( SpeedNum = 1; SpeedNum <= DXCoil( DXCoilNum ).NumOfSpeeds; ++SpeedNum ) { + if ( DXCoil( DXCoilNum ).MSWasteHeat( SpeedNum ) == 0 ) { + ShowWarningError( "GetDXCoils:" + DXCoil( DXCoilNum ).Name + ". The value of Waste Heat Function of Temperature Curve is assumed to be 1. Simulation continues. " ); + break; + } + } + } + } + MyEnvrnFlag( DXCoilNum ) = false; + } + // Find the companion upstream coil (DX cooling coil) that is used with DX heating coils (HP AC units only) if ( DXCoil( DXCoilNum ).FindCompanionUpStreamCoil ) { if ( DXCoil( DXCoilNum ).DXCoilType_Num == CoilDX_HeatingEmpirical || DXCoil( DXCoilNum ).DXCoilType_Num == CoilDX_MultiSpeedHeating ) { @@ -10738,11 +10735,20 @@ Label50: ; HeatReclaimDXCoil( DXCoilNum ).AvailCapacity = DXCoil( DXCoilNum ).TotalCoolingEnergyRate + DXCoil( DXCoilNum ).ElecCoolingPower; // Waste heat calculation - if ( DXCoil( DXCoilNum ).FuelType != FuelTypeElectricity ) { - WasteHeatLS = CurveValue( DXCoil( DXCoilNum ).MSWasteHeat( SpeedNumLS ), OutdoorDryBulb, InletAirDryBulbTemp ) * DXCoil( DXCoilNum ).MSWasteHeatFrac( SpeedNumLS ); - WasteHeatHS = CurveValue( DXCoil( DXCoilNum ).MSWasteHeat( SpeedNumHS ), OutdoorDryBulb, InletAirDryBulbTemp ) * DXCoil( DXCoilNum ).MSWasteHeatFrac( SpeedNumHS ); + if ( DXCoil( DXCoilNum ).MSHPHeatRecActive ) { + if ( DXCoil( DXCoilNum ).MSWasteHeat( SpeedNumLS ) == 0 ) { + WasteHeatLS = DXCoil( DXCoilNum ).MSWasteHeatFrac( SpeedNumLS ); + } else { + WasteHeatLS = CurveValue( DXCoil( DXCoilNum ).MSWasteHeat( SpeedNumLS ), OutdoorDryBulb, InletAirDryBulbTemp ) * DXCoil( DXCoilNum ).MSWasteHeatFrac( SpeedNumLS ); + } + if ( DXCoil( DXCoilNum ).MSWasteHeat( SpeedNumHS ) == 0 ) { + WasteHeatHS = DXCoil( DXCoilNum ).MSWasteHeatFrac( SpeedNumHS ); + } else { + WasteHeatHS = CurveValue( DXCoil( DXCoilNum ).MSWasteHeat( SpeedNumHS ), OutdoorDryBulb, InletAirDryBulbTemp ) * DXCoil( DXCoilNum ).MSWasteHeatFrac( SpeedNumHS ); + } MSHPWasteHeat = ( SpeedRatio * WasteHeatHS + ( 1.0 - SpeedRatio ) * WasteHeatLS ) * DXCoil( DXCoilNum ).ElecCoolingPower; } + // Energy use for other fuel types if ( DXCoil( DXCoilNum ).FuelType != FuelTypeElectricity ) { DXCoil( DXCoilNum ).FuelUsed = DXCoil( DXCoilNum ).ElecCoolingPower; @@ -10919,8 +10925,12 @@ Label50: ; EvapCondPumpElecPower = DXCoil( DXCoilNum ).MSEvapCondPumpElecNomPower( SpeedNumLS ) * DXCoil( DXCoilNum ).CoolingCoilRuntimeFraction; // Waste heat - if ( DXCoil( DXCoilNum ).FuelType != FuelTypeElectricity ) { - MSHPWasteHeat = CurveValue( DXCoil( DXCoilNum ).MSWasteHeat( SpeedNumLS ), OutdoorDryBulb, InletAirDryBulbTemp ) * DXCoil( DXCoilNum ).MSWasteHeatFrac( SpeedNumLS ) * DXCoil( DXCoilNum ).ElecCoolingPower; + if ( DXCoil( DXCoilNum ).MSHPHeatRecActive ) { + if ( DXCoil( DXCoilNum ).MSWasteHeat( SpeedNumLS ) == 0 ) { + MSHPWasteHeat = DXCoil( DXCoilNum ).MSWasteHeatFrac( SpeedNumLS ) * DXCoil( DXCoilNum ).ElecCoolingPower; + } else { + MSHPWasteHeat = CurveValue( DXCoil( DXCoilNum ).MSWasteHeat( SpeedNumLS ), OutdoorDryBulb, InletAirDryBulbTemp ) * DXCoil( DXCoilNum ).MSWasteHeatFrac( SpeedNumLS ) * DXCoil( DXCoilNum ).ElecCoolingPower; + } } // Energy use for other fuel types if ( DXCoil( DXCoilNum ).FuelType != FuelTypeElectricity ) { @@ -11377,12 +11387,21 @@ Label50: ; } // Waste heat calculation - if ( DXCoil( DXCoilNum ).FuelType != FuelTypeElectricity ) { - WasteHeatLS = CurveValue( DXCoil( DXCoilNum ).MSWasteHeat( SpeedNumLS ), OutdoorDryBulb, InletAirDryBulbTemp ) * DXCoil( DXCoilNum ).MSWasteHeatFrac( SpeedNumLS ); - WasteHeatHS = CurveValue( DXCoil( DXCoilNum ).MSWasteHeat( SpeedNumHS ), OutdoorDryBulb, InletAirDryBulbTemp ) * DXCoil( DXCoilNum ).MSWasteHeatFrac( SpeedNumHS ); + if ( DXCoil( DXCoilNum ).MSHPHeatRecActive ) { + if ( DXCoil( DXCoilNum ).MSWasteHeat( SpeedNumLS ) == 0 ) { + WasteHeatLS = DXCoil( DXCoilNum ).MSWasteHeatFrac( SpeedNumLS ); + } else { + WasteHeatLS = CurveValue( DXCoil( DXCoilNum ).MSWasteHeat( SpeedNumLS ), OutdoorDryBulb, InletAirDryBulbTemp ) * DXCoil( DXCoilNum ).MSWasteHeatFrac( SpeedNumLS ); + } + if ( DXCoil( DXCoilNum ).MSWasteHeat( SpeedNumHS ) == 0 ) { + WasteHeatHS = DXCoil( DXCoilNum ).MSWasteHeatFrac( SpeedNumHS ); + } else { + WasteHeatHS = CurveValue( DXCoil( DXCoilNum ).MSWasteHeat( SpeedNumHS ), OutdoorDryBulb, InletAirDryBulbTemp ) * DXCoil( DXCoilNum ).MSWasteHeatFrac( SpeedNumHS ); + } MSHPWasteHeat = ( SpeedRatio * WasteHeatHS + ( 1.0 - SpeedRatio ) * WasteHeatLS ) * DXCoil( DXCoilNum ).ElecHeatingPower; } if ( DXCoil( DXCoilNum ).FuelType != FuelTypeElectricity ) { + DXCoil( DXCoilNum ).FuelUsed = DXCoil( DXCoilNum ).ElecHeatingPower; DXCoil( DXCoilNum ).ElecHeatingPower = 0.0; } @@ -11568,10 +11587,15 @@ Label50: ; OutletAirEnthalpy = InletAirEnthalpy + DXCoil( DXCoilNum ).TotalHeatingEnergyRate / DXCoil( DXCoilNum ).InletAirMassFlowRate; OutletAirTemp = PsyTdbFnHW( OutletAirEnthalpy, OutletAirHumRat ); } - if ( DXCoil( DXCoilNum ).FuelType != FuelTypeElectricity ) { - MSHPWasteHeat = CurveValue( DXCoil( DXCoilNum ).MSWasteHeat( SpeedNumLS ), OutdoorDryBulb, InletAirDryBulbTemp ) * DXCoil( DXCoilNum ).MSWasteHeatFrac( SpeedNumLS ) * DXCoil( DXCoilNum ).ElecHeatingPower; + if ( DXCoil( DXCoilNum ).MSHPHeatRecActive ) { + if ( DXCoil( DXCoilNum ).MSWasteHeat( SpeedNumLS ) == 0 ) { + MSHPWasteHeat = DXCoil( DXCoilNum ).MSWasteHeatFrac( SpeedNumLS ) * DXCoil( DXCoilNum ).ElecHeatingPower; + } else { + MSHPWasteHeat = CurveValue( DXCoil( DXCoilNum ).MSWasteHeat( SpeedNumLS ), OutdoorDryBulb, InletAirDryBulbTemp ) * DXCoil( DXCoilNum ).MSWasteHeatFrac( SpeedNumLS ) * DXCoil( DXCoilNum ).ElecHeatingPower; + } } if ( DXCoil( DXCoilNum ).FuelType != FuelTypeElectricity ) { + DXCoil( DXCoilNum ).FuelUsed = DXCoil( DXCoilNum ).ElecHeatingPower; DXCoil( DXCoilNum ).ElecHeatingPower = 0.0; } @@ -15614,6 +15638,48 @@ Label50: ; return FanSpdResidualHeat; } + void + SetMSHPDXCoilHeatRecoveryFlag( int const DXCoilNum ) // + { + + // SUBROUTINE INFORMATION: + // AUTHOR L. Gu + // DATE WRITTEN Sep. 2015 + // MODIFIED na + // RE-ENGINEERED na + + // PURPOSE OF THIS SUBROUTINE: + // Set the heat recovery flag true when the parent object requests heat recovery. + + // METHODOLOGY EMPLOYED: + // + + // REFERENCES: + // na + + // Using/Aliasing + // na + + // Locals + // SUBROUTINE ARGUMENT DEFINITIONS: + + // SUBROUTINE PARAMETER DEFINITIONS: + // na + + // INTERFACE BLOCK SPECIFICATIONS: + // na + + // DERIVED TYPE DEFINITIONS: + // na + + // SUBROUTINE LOCAL VARIABLE DECLARATIONS: + + if ( DXCoil( DXCoilNum ).FuelType != FuelTypeElectricity ) { + DXCoil( DXCoilNum ).MSHPHeatRecActive = true; + } + + } + // Clears the global data in DXCoils. // Needed for unit tests, should not be normally called. void diff --git a/src/EnergyPlus/DXCoils.hh b/src/EnergyPlus/DXCoils.hh index ab16538509a..d37011ce522 100644 --- a/src/EnergyPlus/DXCoils.hh +++ b/src/EnergyPlus/DXCoils.hh @@ -401,6 +401,7 @@ namespace DXCoils { Array1D< Real64 > MSFanPowerPerEvapAirFlowRate; Real64 FuelUsed; // Energy used, in addition to electricity [W] Real64 FuelConsumed; // Energy consumed, in addition to electricity [J] + bool MSHPHeatRecActive; // True when entered Heat Rec Vol Flow Rate > 0 // End of multispeed DX coil input // VRF system variables used for sizing bool CoolingCoilPresent; // FALSE if coil not present @@ -645,6 +646,7 @@ namespace DXCoils { NumOfSpeeds( 0 ), PLRImpact( false ), LatentImpact( false ), + MSHPHeatRecActive( false ), CoolingCoilPresent( true ), HeatingCoilPresent( true ), ISHundredPercentDOASDXCoil( false ), @@ -920,6 +922,7 @@ namespace DXCoils { Array1< Real64 > const & MSFanPowerPerEvapAirFlowRate, Real64 const FuelUsed, // Energy used, in addition to electricity [W] Real64 const FuelConsumed, // Energy consumed, in addition to electricity [J] + bool const MSHPHeatRecActive, // True when entered Heat Rec Vol Flow Rate > 0 bool const CoolingCoilPresent, // FALSE if coil not present bool const HeatingCoilPresent, // FALSE if coil not present bool const ISHundredPercentDOASDXCoil, // FALSE if coil is regular dx coil @@ -1192,6 +1195,7 @@ namespace DXCoils { MSFanPowerPerEvapAirFlowRate( MSFanPowerPerEvapAirFlowRate ), FuelUsed( FuelUsed ), FuelConsumed( FuelConsumed ), + MSHPHeatRecActive( MSHPHeatRecActive ), CoolingCoilPresent( CoolingCoilPresent ), HeatingCoilPresent( HeatingCoilPresent ), ISHundredPercentDOASDXCoil( ISHundredPercentDOASDXCoil ), @@ -1717,6 +1721,9 @@ namespace DXCoils { // End of Methods for New VRF Model: Fluid Temperature Control // ***************************************************************************** + void + SetMSHPDXCoilHeatRecoveryFlag( int const DXCoilNum ); // must match coil names for the coil type + // Clears the global data in DXCoils. // Needed for unit tests, should not be normally called. void diff --git a/src/EnergyPlus/HVACMultiSpeedHeatPump.cc b/src/EnergyPlus/HVACMultiSpeedHeatPump.cc index 3cf36fa75f5..a4b0cfb2a1b 100644 --- a/src/EnergyPlus/HVACMultiSpeedHeatPump.cc +++ b/src/EnergyPlus/HVACMultiSpeedHeatPump.cc @@ -525,6 +525,7 @@ namespace HVACMultiSpeedHeatPump { using FluidProperties::GetSatDensityRefrig; using ZoneTempPredictorCorrector::NumStageCtrZone; using DataZoneControls::StageControlledZone; + using DXCoils::SetMSHPDXCoilHeatRecoveryFlag; // Locals // PARAMETERS @@ -1217,6 +1218,10 @@ namespace HVACMultiSpeedHeatPump { ErrorsFound = true; } TestCompSet( CurrentModuleObject, Alphas( 1 ), Alphas( 16 ), Alphas( 17 ), "MSHP Heat receovery Nodes" ); + SetMSHPDXCoilHeatRecoveryFlag( MSHeatPump( MSHPNum ).DXCoolCoilIndex ); + if ( MSHeatPump( MSHPNum ).DXHeatCoilIndex > 0 ) { + SetMSHPDXCoilHeatRecoveryFlag( MSHeatPump( MSHPNum ).DXHeatCoilIndex ); + } } else { MSHeatPump( MSHPNum ).HeatRecActive = false; MSHeatPump( MSHPNum ).DesignHeatRecMassFlowRate = 0.0; diff --git a/tst/EnergyPlus/unit/DXCoils.unit.cc b/tst/EnergyPlus/unit/DXCoils.unit.cc index 0ac56156fe5..90976420901 100644 --- a/tst/EnergyPlus/unit/DXCoils.unit.cc +++ b/tst/EnergyPlus/unit/DXCoils.unit.cc @@ -25,6 +25,7 @@ using namespace DataSizing; using namespace CurveManager; using namespace OutputReportPredefined; using namespace ScheduleManager; +using namespace DataEnvironment; namespace EnergyPlus { @@ -607,7 +608,7 @@ namespace EnergyPlus { } TEST_F( HVACFixture, TestSingleSpeedDefrostCOP ) { - // Test that the COP calculation is correct when the defrost is on. #4973 + // Test that the COP calculation is correct when the defrost is on. #4973 using CurveManager::Quadratic; using CurveManager::BiQuadratic; @@ -918,10 +919,19 @@ namespace EnergyPlus { TEST_F( HVACFixture, TestMultiSpeedWasteHeat ) { - // Test that the waste heat function #4536 + // Test the waste heat function #4536 + + using Psychrometrics::PsyTwbFnTdbWPb; + using Psychrometrics::PsyHFnTdbW; std::string const idf_objects = delimited_string( { "Version,8.3;", + " Schedule:Compact,", + " FanAndCoilAvailSched, !- Name", + " Fraction, !- Schedule Type Limits Name", + " Through: 12/31, !- Field 1", + " For: AllDays, !- Field 2", + " Until: 24:00, 1.0; !- Field 3", " OutdoorAir:Node,", " Outdoor Condenser Air Node, !- Name", " 1.0; !- Height Above Ground{ m }", @@ -1080,11 +1090,53 @@ namespace EnergyPlus { ASSERT_FALSE( process_idf( idf_objects ) ); + // Case 1 test GetDXCoils( ); EXPECT_EQ( FuelTypeElectricity, DXCoil( 1 ).FuelType ); EXPECT_EQ( 0, DXCoil( 1 ).MSWasteHeat( 2 ) ); - } + // Test calculations of the waste heat function #5162 + + // Case 2 test waste heat is zero when the parent has not heat recovery inputs + DXCoil( 1 ).FuelType = FuelTypeNaturalGas; + DXCoil( 1 ).MSHPHeatRecActive = false; + + OutDryBulbTemp = 35; + OutHumRat = 0.0128; + OutBaroPress = 101325; + OutWetBulbTemp = PsyTwbFnTdbWPb( OutDryBulbTemp, OutHumRat, OutBaroPress); + DXCoil( 1 ).MSRatedAirMassFlowRate( 1 ) = DXCoil( 1 ).MSRatedAirVolFlowRate( 1 ) * 1.2; + DXCoil( 1 ).MSRatedAirMassFlowRate( 2 ) = DXCoil( 1 ).MSRatedAirVolFlowRate( 2 ) * 1.2; + DXCoil( 1 ).InletAirMassFlowRate = DXCoil( 1 ).MSRatedAirMassFlowRate( 2 ); + MSHPMassFlowRateLow = DXCoil( 1 ).MSRatedAirMassFlowRate( 1 ); + MSHPMassFlowRateHigh = DXCoil( 1 ).MSRatedAirMassFlowRate( 2 ); + + DXCoil( 1 ).InletAirTemp = 25.0; + DXCoil( 1 ).InletAirHumRat = 0.005; + DXCoil( 1 ).InletAirEnthalpy = PsyHFnTdbW( 25.0, 0.005 ); + + DXCoil( 1 ).SchedPtr = 1; + Schedule( DXCoil( 1 ).SchedPtr ).CurrentValue = 1.0; // enable the VRF condenser + DXCoil( 1 ).MSRatedCBF( 1 ) = 0.1262; + DXCoil( 1 ).MSRatedCBF( 2 ) = 0.0408; + + CalcMultiSpeedDXCoilCooling( 1, 1, 1, 2, 1, 1 ); + + EXPECT_EQ( 0, MSHPWasteHeat ); + + // Case 3 heat recovery is true and no waste heat function cuvre + DXCoil( 1 ).MSWasteHeat( 1 ) = 0; + DXCoil( 1 ).MSWasteHeat( 2 ) = 0; + DXCoil( 1 ).MSHPHeatRecActive = true; + + CalcMultiSpeedDXCoilCooling( 1, 1, 1, 2, 1, 1 ); + + EXPECT_NEAR( 1303.4304, MSHPWasteHeat, 0.001 ); + + // clear + DXCoil.deallocate( ); + + } }