Skip to content

Commit

Permalink
Merge pull request #5471 from NREL/113107773-Improve-waste-heat-funct…
Browse files Browse the repository at this point in the history
…ion-handling-of-AirloopHVACUnitarySystem-#5222

Setup heat recovery flag for multispeed DX coils in AirloopHVAC:UnitarySystem
  • Loading branch information
mjwitte committed Mar 2, 2016
2 parents 31c4af4 + ff153fb commit 0ce5023
Show file tree
Hide file tree
Showing 3 changed files with 899 additions and 5 deletions.
4 changes: 2 additions & 2 deletions src/EnergyPlus/HVACMultiSpeedHeatPump.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1265,12 +1265,12 @@ namespace HVACMultiSpeedHeatPump {
if ( MSHeatPump( MSHPNum ).DesignHeatRecFlowRate > 0.0 ) {
MSHeatPump( MSHPNum ).HeatRecActive = true;
MSHeatPump( MSHPNum ).DesignHeatRecMassFlowRate = RhoH2O( InitConvTemp ) * MSHeatPump( MSHPNum ).DesignHeatRecFlowRate;
MSHeatPump( MSHPNum ).HeatRecInletNodeNum = GetOnlySingleNode( Alphas( 16 ), ErrorsFound, "MSHP Heat receovery", Alphas( 1 ), NodeType_Water, NodeConnectionType_Inlet, 3, ObjectIsNotParent );
MSHeatPump( MSHPNum ).HeatRecInletNodeNum = GetOnlySingleNode( Alphas( 16 ), ErrorsFound, CurrentModuleObject, Alphas( 1 ), NodeType_Water, NodeConnectionType_Inlet, 3, ObjectIsNotParent );
if ( MSHeatPump( MSHPNum ).HeatRecInletNodeNum == 0 ) {
ShowSevereError( CurrentModuleObject + ", \"" + MSHeatPump( MSHPNum ).Name + "\", Missing " + cAlphaFields( 16 ) + '.' );
ErrorsFound = true;
}
MSHeatPump( MSHPNum ).HeatRecOutletNodeNum = GetOnlySingleNode( Alphas( 17 ), ErrorsFound, "MSHP Heat receovery", Alphas( 1 ), NodeType_Water, NodeConnectionType_Outlet, 3, ObjectIsNotParent );
MSHeatPump( MSHPNum ).HeatRecOutletNodeNum = GetOnlySingleNode( Alphas( 17 ), ErrorsFound, CurrentModuleObject, Alphas( 1 ), NodeType_Water, NodeConnectionType_Outlet, 3, ObjectIsNotParent );
if ( MSHeatPump( MSHPNum ).HeatRecOutletNodeNum == 0 ) {
ShowSevereError( CurrentModuleObject + ", \"" + MSHeatPump( MSHPNum ).Name + "\", Missing " + cAlphaFields( 17 ) + '.' );
ErrorsFound = true;
Expand Down
13 changes: 10 additions & 3 deletions src/EnergyPlus/HVACUnitarySystem.cc
Original file line number Diff line number Diff line change
Expand Up @@ -2745,6 +2745,7 @@ namespace HVACUnitarySystem {
using UserDefinedComponents::GetUserDefinedCoilAirInletNode;
using UserDefinedComponents::GetUserDefinedCoilAirOutletNode;
using PackagedThermalStorageCoil::GetTESCoilCoolingCapacity;
using DXCoils::SetMSHPDXCoilHeatRecoveryFlag;

// Locals
// SUBROUTINE ARGUMENT DEFINITIONS:
Expand Down Expand Up @@ -5819,11 +5820,17 @@ namespace HVACUnitarySystem {
UnitarySystem( UnitarySysNum ).HeatRecActive = true;
errFlag = false;
if ( ! lAlphaBlanks( iHRWaterInletNodeAlphaNum ) && ! lAlphaBlanks( iHRWaterOutletNodeAlphaNum ) ) {
UnitarySystem( UnitarySysNum ).HeatRecoveryInletNodeNum = GetOnlySingleNode( Alphas( iHRWaterInletNodeAlphaNum ), errFlag, "Unitary System Heat receovery", Alphas( iNameAlphaNum ), NodeType_Water, NodeConnectionType_Inlet, 3, ObjectIsParent );
UnitarySystem( UnitarySysNum ).HeatRecoveryOutletNodeNum = GetOnlySingleNode( Alphas( iHRWaterOutletNodeAlphaNum ), errFlag, "Unitary System Heat receovery", Alphas( iNameAlphaNum ), NodeType_Water, NodeConnectionType_Inlet, 3, ObjectIsParent );
UnitarySystem( UnitarySysNum ).HeatRecoveryInletNodeNum = GetOnlySingleNode( Alphas( iHRWaterInletNodeAlphaNum ), errFlag, CurrentModuleObject, Alphas( iNameAlphaNum ), NodeType_Water, NodeConnectionType_Inlet, 3, ObjectIsNotParent );
UnitarySystem( UnitarySysNum ).HeatRecoveryOutletNodeNum = GetOnlySingleNode( Alphas( iHRWaterOutletNodeAlphaNum ), errFlag, CurrentModuleObject, Alphas( iNameAlphaNum ), NodeType_Water, NodeConnectionType_Outlet, 3, ObjectIsNotParent );

TestCompSet( CurrentModuleObject, Alphas( iNameAlphaNum ), Alphas( iHRWaterInletNodeAlphaNum ), Alphas( iHRWaterOutletNodeAlphaNum ), "Unitary System Heat receovery Nodes" );
TestCompSet( CurrentModuleObject, Alphas( iNameAlphaNum ), Alphas( iHRWaterInletNodeAlphaNum ), Alphas( iHRWaterOutletNodeAlphaNum ), "Unitary System Heat Recovery Nodes" );

if ( UnitarySystem( UnitarySysNum ).CoolingCoilType_Num == CoilDX_MultiSpeedCooling ) {
SetMSHPDXCoilHeatRecoveryFlag( UnitarySystem( UnitarySysNum ).CoolingCoilIndex );
}
if ( UnitarySystem( UnitarySysNum ).HeatingCoilType_Num == CoilDX_MultiSpeedHeating ) {
SetMSHPDXCoilHeatRecoveryFlag( UnitarySystem( UnitarySysNum ).HeatingCoilIndex );
}
if ( errFlag ) {
ShowContinueError( "Occurs in " + CurrentModuleObject + " = " + UnitarySystem( UnitarySysNum ).Name );
ErrorsFound = true;
Expand Down
Loading

8 comments on commit 0ce5023

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

develop (mjwitte) - x86_64-Linux-Ubuntu-14.04-cppcheck-1.61: OK (0 of 0 tests passed, 0 test warnings)

Build Badge

@nrel-bot-3
Copy link

Choose a reason for hiding this comment

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

develop (mjwitte) - x86_64-MacOS-10.9-clang: OK (1568 of 1568 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.

develop (mjwitte) - x86_64-Linux-Ubuntu-14.04-gcc-4.8: OK (1587 of 1587 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.

develop (mjwitte) - x86_64-Linux-Ubuntu-14.04-custom_check: OK (0 of 0 tests passed, 0 test warnings)

Build 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.

develop (mjwitte) - x86_64-Linux-Ubuntu-14.04-gcc-4.8-UnitTestsCoverage-Debug: OK (1013 of 1013 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.

develop (mjwitte) - i386-Windows-7-VisualStudio-12: OK (1570 of 1571 tests passed, 0 test warnings)

Build Badge Test 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.

develop (mjwitte) - Win64-Windows-7-VisualStudio-12: OK (1571 of 1571 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.

develop (mjwitte) - x86_64-Linux-Ubuntu-14.04-gcc-4.8-IntegrationCoverage-Debug: OK (1571 of 1571 tests passed, 0 test warnings)

Build Badge Test Badge Coverage Badge

Please sign in to comment.