Skip to content

Commit

Permalink
75127368_DCFSEC Cleaned.
Browse files Browse the repository at this point in the history
  • Loading branch information
Nigusse committed Oct 17, 2014
1 parent a72758e commit c71ba48
Show file tree
Hide file tree
Showing 7 changed files with 55 additions and 33 deletions.
11 changes: 9 additions & 2 deletions idd/Energy+.idd.in
Original file line number Diff line number Diff line change
Expand Up @@ -40167,14 +40167,21 @@ Coil:Cooling:DX:SingleSpeed,
\note wb = entering wet-bulb temperature seen by the DX cooling coil (C)
\note db = entering dry-bulb temperature seen by the DX cooling coil (C)
\note entering temperature can be outside air or pretreated air.
A16; \field Sensible Heat Ratio Function of Flow Fraction Curve Name
A16, \field Sensible Heat Ratio Function of Flow Fraction Curve Name
\type object-list
\object-list QuadraticCubicCurves
\note Table:OneIndependentVariable object can also be used
\note quadratic curve = a + b*ff + c*ff**2
\note cubic curve = a + b*ff + c*ff**2 + d*ff**3
\note ff = fraction of the full load flow

A17; \field Report ASHRAE Standard 127 Performance Ratings
\type choice
\key Yes
\key No
\default No
\note when this input field is specified as Yes then the program calculates the net cooling
\note capacity and total electric power input of DX cooling coils per ANSI/ASHRAE 127.

Coil:Cooling:DX:TwoSpeed,
\memo Direct expansion (DX) cooling coil and condensing unit (includes electric compressor
\memo and condenser fan), two-speed (or variable-speed). Requires two sets of performance
Expand Down
12 changes: 11 additions & 1 deletion src/EnergyPlus/DXCoils.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1403,6 +1403,16 @@ namespace DXCoils {
if ( DXCoil( DXCoilNum ).SHRFTemp( 1 ) > 0 && DXCoil( DXCoilNum ).SHRFFlow( 1 ) > 0 ) {
DXCoil( DXCoilNum ).UserSHRCurveExists = true;
}
// get User Input floag for ASHRAE Standard 127 Standard Ratings Reporting
if ( lAlphaBlanks( 17 ) ) {
DXCoil( DXCoilNum ).ASHRAE127StdRprt = false;
} else {
if ( Alphas( 17 ) == "YES" || Alphas( 17 ) == "Yes" ) {
DXCoil( DXCoilNum ).ASHRAE127StdRprt = true;
} else {
DXCoil( DXCoilNum ).ASHRAE127StdRprt = false;
}
}

} // end of the Doe2 DX coil loop

Expand Down Expand Up @@ -6044,7 +6054,7 @@ namespace DXCoils {

// Call routine that computes AHRI certified rating for single-speed DX Coils
if ( ( DXCoil( DXCoilNum ).DXCoilType_Num == CoilDX_CoolingSingleSpeed && DXCoil( DXCoilNum ).CondenserType( 1 ) == AirCooled ) || DXCoil( DXCoilNum ).DXCoilType_Num == CoilDX_HeatingEmpirical ) {
CalcDXCoilStandardRating( DXCoil( DXCoilNum ).Name, DXCoil( DXCoilNum ).DXCoilType, DXCoil( DXCoilNum ).DXCoilType_Num, 1, DXCoil( DXCoilNum ).RatedTotCap( 1 ), DXCoil( DXCoilNum ).RatedCOP( 1 ), DXCoil( DXCoilNum ).CCapFFlow( 1 ), DXCoil( DXCoilNum ).CCapFTemp( 1 ), DXCoil( DXCoilNum ).EIRFFlow( 1 ), DXCoil( DXCoilNum ).EIRFTemp( 1 ), DXCoil( DXCoilNum ).PLFFPLR( 1 ), DXCoil( DXCoilNum ).RatedAirVolFlowRate( 1 ), DXCoil( DXCoilNum ).FanPowerPerEvapAirFlowRate( 1 ), DXCoil( DXCoilNum ).RegionNum, DXCoil( DXCoilNum ).MinOATCompressor, DXCoil( DXCoilNum ).OATempCompressorOn, DXCoil( DXCoilNum ).OATempCompressorOnOffBlank, DXCoil( DXCoilNum ).DefrostControl );
CalcDXCoilStandardRating( DXCoil( DXCoilNum ).Name, DXCoil( DXCoilNum ).DXCoilType, DXCoil( DXCoilNum ).DXCoilType_Num, 1, DXCoil( DXCoilNum ).RatedTotCap( 1 ), DXCoil( DXCoilNum ).RatedCOP( 1 ), DXCoil( DXCoilNum ).CCapFFlow( 1 ), DXCoil( DXCoilNum ).CCapFTemp( 1 ), DXCoil( DXCoilNum ).EIRFFlow( 1 ), DXCoil( DXCoilNum ).EIRFTemp( 1 ), DXCoil( DXCoilNum ).PLFFPLR( 1 ), DXCoil( DXCoilNum ).RatedAirVolFlowRate( 1 ), DXCoil( DXCoilNum ).FanPowerPerEvapAirFlowRate( 1 ), DXCoil( DXCoilNum ).RegionNum, DXCoil( DXCoilNum ).MinOATCompressor, DXCoil( DXCoilNum ).OATempCompressorOn, DXCoil( DXCoilNum ).OATempCompressorOnOffBlank, DXCoil( DXCoilNum ).DefrostControl, DXCoil( DXCoilNum ).ASHRAE127StdRprt );
}
// Call routine that computes AHRI certified rating for multi-speed DX cooling Coils
if ( DXCoil( DXCoilNum ).DXCoilType_Num == CoilDX_MultiSpeedCooling || DXCoil( DXCoilNum ).DXCoilType_Num == CoilDX_MultiSpeedHeating ) {
Expand Down
10 changes: 7 additions & 3 deletions src/EnergyPlus/DXCoils.hh
Original file line number Diff line number Diff line change
Expand Up @@ -417,6 +417,7 @@ namespace DXCoils {
// (function of actual supply air flow vs rated air flow)
int SHRFTempCurveType2; // type of curve for SHRFTemp (cubic,quadratic,bi-quadratic)
bool UserSHRCurveExists; // TRUE if user specified SHR modifier curve exists
bool ASHRAE127StdRprt; // TRUE if user wishes to report ASHRAE 127 standard ratings

// Default Constructor
DXCoilData() :
Expand Down Expand Up @@ -614,7 +615,8 @@ namespace DXCoils {
SHRFTemp2( 0 ),
SHRFFlow2( 0 ),
SHRFTempCurveType2( 0 ),
UserSHRCurveExists( false )
UserSHRCurveExists( false ),
ASHRAE127StdRprt( false )
{}

// Member Constructor
Expand Down Expand Up @@ -852,7 +854,8 @@ namespace DXCoils {
int const SHRFTemp2, // index of sensible heat ratio modifier curve
int const SHRFFlow2, // index of sensible heat ratio modifier curve
int const SHRFTempCurveType2, // type of curve for SHRFTemp (cubic,quadratic,bi-quadratic)
bool const UserSHRCurveExists // TRUE if user specified SHR modifier curve exists
bool const UserSHRCurveExists, // TRUE if user specified SHR modifier curve exists
bool const ASHRAE127StdRprt // TRUE if user wishes to report ASHRAE 127 standard ratings
) :
Name( Name ),
DXCoilType( DXCoilType ),
Expand Down Expand Up @@ -1087,7 +1090,8 @@ namespace DXCoils {
SHRFTemp2( SHRFTemp2 ),
SHRFFlow2( SHRFFlow2 ),
SHRFTempCurveType2( SHRFTempCurveType2 ),
UserSHRCurveExists( UserSHRCurveExists )
UserSHRCurveExists( UserSHRCurveExists ),
ASHRAE127StdRprt( ASHRAE127StdRprt )
{}

};
Expand Down
25 changes: 13 additions & 12 deletions src/EnergyPlus/OutputReportPredefined.cc
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,8 @@ namespace OutputReportPredefined {
int pdchDXCoolCoilIEERIP; // IEER value in IP unit at AHRI std. 340/360 conditions

// DX Cooling Coil subtable per ANSI/ASHRAE Std 127 for Tests A, B, C and D
int pdchDXCoolCoilTestClass; // Standard Rated Test Class Number
int pdstDXCoolCoil2;
//int pdchDXCoolCoilTestClass; // Standard Rated Test Class Number
int pdchDXCoolCoilNetCapSIA; // Standard Rated (Net) Cooling Capacity [W], Test A
int pdchDXCoolCoilElecPowerA; // Standard Rated Electric Power [W], Test A
int pdchDXCoolCoilNetCapSIB; // Standard Rated (Net) Cooling Capacity [W], Test B
Expand Down Expand Up @@ -895,17 +896,17 @@ namespace OutputReportPredefined {
pdchDXCoolCoilIEERIP = newPreDefColumn( pdstDXCoolCoil, "IEER [Btu/W-h]" );

// for DX Cooling Coil ASHRAE 127-12 Report
pdstDXCoolCoil = newPreDefSubTable( pdrEquip, "DX Cooling Coil ASHRAE 127-12 Standard Report" );
pdchDXCoolCoilType = newPreDefColumn( pdstDXCoolCoil, "DX Cooling Coil Type" );
pdchDXCoolCoilTestClass = newPreDefColumn( pdstDXCoolCoil, "Application Class" );
pdchDXCoolCoilNetCapSIA = newPreDefColumn( pdstDXCoolCoil, "Rated Net Cooling Capacity Test A [W]" );
pdchDXCoolCoilElecPowerA = newPreDefColumn( pdstDXCoolCoil, "Rated Electric Power Test A [W]" );
pdchDXCoolCoilNetCapSIB = newPreDefColumn( pdstDXCoolCoil, "Rated Net Cooling Capacity Test B [W]" );
pdchDXCoolCoilElecPowerB = newPreDefColumn( pdstDXCoolCoil, "Rated Electric Power Test B [W]" );
pdchDXCoolCoilNetCapSIC = newPreDefColumn( pdstDXCoolCoil, "Rated Net Cooling Capacity Test C [W]" );
pdchDXCoolCoilElecPowerC = newPreDefColumn( pdstDXCoolCoil, "Rated Electric Power Test C [W]" );
pdchDXCoolCoilNetCapSID = newPreDefColumn( pdstDXCoolCoil, "Rated Net Cooling Capacity Test D [W]" );
pdchDXCoolCoilElecPowerD = newPreDefColumn( pdstDXCoolCoil, "Rated Electric Power Test D [W]" );
pdstDXCoolCoil2 = newPreDefSubTable( pdrEquip, "DX Cooling Coil ASHRAE 127 Standard Ratings Report" );
pdchDXCoolCoilType = newPreDefColumn( pdstDXCoolCoil2, "DX Cooling Coil Type" );
//pdchDXCoolCoilTestClass = newPreDefColumn( pdstDXCoolCoil, "Application Class" );
pdchDXCoolCoilNetCapSIA = newPreDefColumn( pdstDXCoolCoil2, "Rated Net Cooling Capacity Test A [W]" );
pdchDXCoolCoilElecPowerA = newPreDefColumn( pdstDXCoolCoil2, "Rated Electric Power Test A [W]" );
pdchDXCoolCoilNetCapSIB = newPreDefColumn( pdstDXCoolCoil2, "Rated Net Cooling Capacity Test B [W]" );
pdchDXCoolCoilElecPowerB = newPreDefColumn( pdstDXCoolCoil2, "Rated Electric Power Test B [W]" );
pdchDXCoolCoilNetCapSIC = newPreDefColumn( pdstDXCoolCoil2, "Rated Net Cooling Capacity Test C [W]" );
pdchDXCoolCoilElecPowerC = newPreDefColumn( pdstDXCoolCoil2, "Rated Electric Power Test C [W]" );
pdchDXCoolCoilNetCapSID = newPreDefColumn( pdstDXCoolCoil2, "Rated Net Cooling Capacity Test D [W]" );
pdchDXCoolCoilElecPowerD = newPreDefColumn( pdstDXCoolCoil2, "Rated Electric Power Test D [W]" );

pdstDXHeatCoil = newPreDefSubTable( pdrEquip, "DX Heating Coils" );
pdchDXHeatCoilType = newPreDefColumn( pdstDXHeatCoil, "DX Heating Coil Type" );
Expand Down
3 changes: 2 additions & 1 deletion src/EnergyPlus/OutputReportPredefined.hh
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,8 @@ namespace OutputReportPredefined {
extern int pdchDXCoolCoilIEERIP; // IEER value in IP unit at AHRI std. 340/360 conditions

// DX Cooling Coil subtable per ANSI/ASHRAE Std 127 for Tests A, B, C and D
extern int pdchDXCoolCoilTestClass; // Standard Rated Test Class Number
extern int pdstDXCoolCoil2;
//extern int pdchDXCoolCoilTestClass; // Standard Rated Test Class Number
extern int pdchDXCoolCoilNetCapSIA; // Standard Rated (Net) Cooling Capacity [W], Test A
extern int pdchDXCoolCoilElecPowerA; // Standard Rated Electric Power [W], Test A
extern int pdchDXCoolCoilNetCapSIB; // Standard Rated (Net) Cooling Capacity [W], Test B
Expand Down
24 changes: 11 additions & 13 deletions src/EnergyPlus/StandardRatings.cc
Original file line number Diff line number Diff line change
Expand Up @@ -727,7 +727,8 @@ namespace StandardRatings {
Optional< Real64 const > MinOATCompressor, // Minimum OAT for heat pump compressor operation [C] //Autodesk:OPTIONAL Used without PRESENT check
Optional< Real64 const > OATempCompressorOn, // The outdoor temperature when the compressor is automatically turned //Autodesk:OPTIONAL Used without PRESENT check
Optional_bool_const OATempCompressorOnOffBlank, // Flag used to determine low temperature cut out factor //Autodesk:OPTIONAL Used without PRESENT check
Optional_int_const DefrostControl // defrost control; 1=timed, 2=on-demand //Autodesk:OPTIONAL Used without PRESENT check
Optional_int_const DefrostControl, // defrost control; 1=timed, 2=on-demand //Autodesk:OPTIONAL Used without PRESENT check
Optional_bool_const ASHRAE127StdRprt // true if user wishes to report ASHRAE 127 standard ratings
)
{

Expand Down Expand Up @@ -920,11 +921,10 @@ namespace StandardRatings {
// Writes the net rated cooling capacity, SEER, EER and IEER values to the EIO file and standard tabular output tables
ReportDXCoilRating( DXCoilType, DXCoilName, DXCoilType_Num, NetCoolingCapRated( 1 ), SEER * ConvFromSIToIP, EER, EER * ConvFromSIToIP, IEER * ConvFromSIToIP, NetHeatingCapRatedHighTemp, NetHeatingCapRatedLowTemp, HSPF * ConvFromSIToIP, RegionNum );

// temporarily commented until issues with table formt is resolved
//DXCoolingCoilDataCenterStandardRatings( DXCoilName, DXCoilType, CapFTempCurveIndex( 1 ), CapFFlowCurveIndex( 1 ), EIRFTempCurveIndex( 1 ), EIRFFlowCurveIndex( 1 ), PLFFPLRCurveIndex( 1 ), RatedTotalCapacity( 1 ), RatedCOP( 1 ), RatedAirVolFlowRate( 1 ), FanPowerPerEvapAirFlowRateFromInput( 1 ), NetTotCoolingCapRated, TotElectricPowerRated );
//
//ReportDXCoolCoilDataCenterApplication( DXCoilType, DXCoilName, DXCoilType_Num, NetTotCoolingCapRated, TotElectricPowerRated );

if ( ASHRAE127StdRprt ) {
DXCoolingCoilDataCenterStandardRatings( DXCoilName, DXCoilType, CapFTempCurveIndex( 1 ), CapFFlowCurveIndex( 1 ), EIRFTempCurveIndex( 1 ), EIRFFlowCurveIndex( 1 ), PLFFPLRCurveIndex( 1 ), RatedTotalCapacity( 1 ), RatedCOP( 1 ), RatedAirVolFlowRate( 1 ), FanPowerPerEvapAirFlowRateFromInput( 1 ), NetTotCoolingCapRated, TotElectricPowerRated );
ReportDXCoolCoilDataCenterApplication( DXCoilType, DXCoilName, DXCoilType_Num, NetTotCoolingCapRated, TotElectricPowerRated );
}
} else if ( SELECT_CASE_var == CoilDX_HeatingEmpirical ) { // Coil:Heating:DX:SingleSpeed

CheckCurveLimitsForStandardRatings( DXCoilName, DXCoilType, DXCoilType_Num, CapFTempCurveIndex( 1 ), CapFFlowCurveIndex( 1 ), EIRFTempCurveIndex( 1 ), EIRFFlowCurveIndex( 1 ), PLFFPLRCurveIndex( 1 ) );
Expand Down Expand Up @@ -2226,8 +2226,8 @@ namespace StandardRatings {
static std::string CompNameNew;

// Formats
static gio::Fmt const Format_101( "('! <DX Cooling Coil Standard Rating Information>, Component Type, Component Name, Class, ','Rated Net Cooling Capacity Test A {W}, ','Rated Total Electric Power Test A {W}, ','Rated Net Cooling Capacity Test B {W}, ','Rated Total Electric Power Test B {W}, ','Rated Net Cooling Capacity Test C {W}, ','Rated Total Electric Power Test C {W}, ','Rated Net Cooling Capacity Test D {W}, ','Rated Total Electric Power Test D {W} ')" );
static gio::Fmt const Format_102( "(' DX Cooling Coil Standard Rating Information, ',A,', ',A,', ',A,', ',A,', ',A,', ',A,', ',A,', ',A,', ',A)" );
static gio::Fmt const Format_101( "('! <DX Cooling Coil ASHRAE 127 Standard Rating Information>, Component Type, Component Name, Class, ','Rated Net Cooling Capacity Test A {W}, ','Rated Total Electric Power Test A {W}, ','Rated Net Cooling Capacity Test B {W}, ','Rated Total Electric Power Test B {W}, ','Rated Net Cooling Capacity Test C {W}, ','Rated Total Electric Power Test C {W}, ','Rated Net Cooling Capacity Test D {W}, ','Rated Total Electric Power Test D {W} ')" );
static gio::Fmt const Format_102( "(' DX Cooling Coil ASHRAE 127 Standard Rating Information, ',A,', ',A,', ',A,', ',A,', ',A,', ',A,', ',A,', ',A,', ',A,', ',A,', ',A)" );


{ auto const SELECT_CASE_var( CompTypeNum );
Expand All @@ -2241,12 +2241,10 @@ namespace StandardRatings {
for ( ClassNum = 1; ClassNum <= 4; ++ClassNum ) {
Num = ( ClassNum - 1 ) * 4;
ClassName = "Class " + RoundSigDigits(ClassNum);
//CompNameNew = CompName + RoundSigDigits( ClassNum );
CompNameNew = RoundSigDigits( ClassNum );
CompNameNew = CompName + "(" + ClassName + ")";
gio::write( OutputFileInits, Format_102 ) << CompType << CompName << ClassName << RoundSigDigits( NetCoolingCapRated( Num + 1 ), 1 ) << RoundSigDigits( TotElectricPowerRated( Num + 1 ), 1 ) << RoundSigDigits( NetCoolingCapRated( Num + 2 ), 1 ) << RoundSigDigits( TotElectricPowerRated( Num + 2 ), 1 ) << RoundSigDigits( NetCoolingCapRated( Num + 3 ), 1 ) << RoundSigDigits( TotElectricPowerRated( Num + 3 ), 1 ) << RoundSigDigits( NetCoolingCapRated( Num + 4 ), 1 ) << RoundSigDigits( TotElectricPowerRated( Num + 4 ), 1 );
PreDefTableEntry( pdchDXCoolCoilType, CompName, CompType );
PreDefTableEntry( pdchDXCoolCoilType, CompNameNew, CompType );
//PreDefTableEntry( pdchDXCoolCoilTestClass, CompNameNew, RoundSigDigits( ClassNum ) );
PreDefTableEntry( pdchDXCoolCoilTestClass, CompNameNew, ClassName );
PreDefTableEntry( pdchDXCoolCoilNetCapSIA, CompNameNew, RoundSigDigits( NetCoolingCapRated( Num + 1 ), 1 ) );
PreDefTableEntry( pdchDXCoolCoilElecPowerA, CompNameNew, RoundSigDigits( TotElectricPowerRated( Num + 1 ), 1 ) );
PreDefTableEntry( pdchDXCoolCoilNetCapSIB, CompNameNew, RoundSigDigits( NetCoolingCapRated( Num + 2 ), 1 ) );
Expand All @@ -2255,7 +2253,7 @@ namespace StandardRatings {
PreDefTableEntry( pdchDXCoolCoilElecPowerC, CompNameNew, RoundSigDigits( TotElectricPowerRated( Num + 3 ), 1 ) );
PreDefTableEntry( pdchDXCoolCoilNetCapSID, CompNameNew, RoundSigDigits( NetCoolingCapRated( Num + 4 ), 1 ) );
PreDefTableEntry( pdchDXCoolCoilElecPowerD, CompNameNew, RoundSigDigits( TotElectricPowerRated( Num + 4 ), 1 ) );
addFootNoteSubTable( pdstDXCoolCoil, "Standard Ratings for Room Unitary Air Conditioners DX Cooling Coils per ANSI/ASHRAE Standard 127-2012." );
addFootNoteSubTable( pdstDXCoolCoil2, "ANSI/ASHRAE Standard 127 includes supply fan heat effect and electric power." );
}

} else {
Expand Down
3 changes: 2 additions & 1 deletion src/EnergyPlus/StandardRatings.hh
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,8 @@ namespace StandardRatings {
Optional< Real64 const > MinOATCompressor = _, // Minimum OAT for heat pump compressor operation [C] //Autodesk:OPTIONAL Used without PRESENT check
Optional< Real64 const > OATempCompressorOn = _, // The outdoor temperature when the compressor is automatically turned //Autodesk:OPTIONAL Used without PRESENT check
Optional_bool_const OATempCompressorOnOffBlank = _, // Flag used to determine low temperature cut out factor //Autodesk:OPTIONAL Used without PRESENT check
Optional_int_const DefrostControl = _ // defrost control; 1=timed, 2=on-demand //Autodesk:OPTIONAL Used without PRESENT check
Optional_int_const DefrostControl = _, // defrost control; 1=timed, 2=on-demand //Autodesk:OPTIONAL Used without PRESENT check
Optional_bool_const ASHRAE127StdRprt = _ // true if user wishes to report ASHRAE 127 standard ratings
);

void
Expand Down

6 comments on commit c71ba48

@nrel-bot
Copy link

Choose a reason for hiding this comment

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

75127368_DCFSEC (Nigusse) - x86_64-Linux-Ubuntu-14.04-gcc-4.8: OK (954 of 964 tests passed)

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.

75127368_DCFSEC (Nigusse) - x86_64-Linux-Ubuntu-14.04-cppcheck-1.61: OK (0 of 0 tests passed)

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

75127368_DCFSEC (Nigusse) - x86_64-MacOS-10.9-clang: OK (954 of 964 tests passed)

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.

75127368_DCFSEC (Nigusse) - x86_64-MacOS-10.9-clang-Debug: OK (949 of 964 tests passed)

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.

75127368_DCFSEC (Nigusse) - i386-Windows-7-VisualStudio-12: OK (954 of 964 tests passed)

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.

75127368_DCFSEC (Nigusse) - Win64-Windows-7-VisualStudio-12: OK (954 of 964 tests passed)

Build Badge Test Badge

Please sign in to comment.