Skip to content

Commit 0c5a8e3

Browse files
committed
CSE 0.832
UEF-based instantaneous DHW model
1 parent ea1990d commit 0c5a8e3

File tree

6 files changed

+267
-34
lines changed

6 files changed

+267
-34
lines changed

src/CNCULT.CPP

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1772,6 +1772,12 @@ CULT( "whASHPSrcT", DAT, DHWHEATER_ASHPTSRC,0, 0, VSUBHRLY,TYFL, 0,
17721772
CULT( "whASHPResUse",DAT, DHWHEATER_ASHPRESUSE,0, 0, VEOI, TYFL, 0, 7.22f, N, N),
17731773
CULT( "whVol", DAT, DHWHEATER_VOL, 0, 0, VEOI, TYFL, 0, 0.f, N, N),
17741774
CULT( "whEF", DAT, DHWHEATER_EF, 0, 0, VEOI, TYFL, 0, 0.82f, N, N),
1775+
1776+
CULT( "whUEF", DAT, DHWHEATER_UEF, 0, 0, VEOI, TYFL, 0, 0.f, N, N),
1777+
CULT( "whRatedInput",DAT, DHWHEATER_RATEDINPUT,0, 0, VEOI, TYFL, 0, 0.f, N, N),
1778+
CULT( "whRatedFlow", DAT, DHWHEATER_RATEDFLOW, 0, 0, VEOI, TYFL, 0, 0.f, N, N),
1779+
CULT( "whAnnualFuel",DAT, DHWHEATER_ANNUALFUEL,0, 0, VEOI, TYFL, 0, 0.f, N, N),
1780+
CULT( "whAnnualElec",DAT, DHWHEATER_ANNUALELEC,0, 0, VEOI, TYFL, 0, 0.f, N, N),
17751781
CULT( "whResHtPwr", DAT, DHWHEATER_RESHTPWR,0, 0, VEOI, TYFL, 0, 4500.f, N, N),
17761782
CULT( "whResHtPwr2", DAT, DHWHEATER_RESHTPWR2,0, 0, VEOI, TYFL, 0, 0.f, N, N),
17771783
CULT( "whLDEF", DAT, DHWHEATER_LDEF, 0, 0, VEOI, TYFL, 0, 1.0f, N, N),

src/CNDTYPES.DEF

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -355,8 +355,9 @@ DUCTSEGP -- "class DUCTSEG*" 4 none
355355
*choicb WHTYPECH {
356356
STRGSML "SmallStorage"
357357
STRGLRG "LargeStorage"
358-
INSTSML "SmallInstantaneous"
359-
INSTLRG "LargeInstantaneous"
358+
INSTSML "SmallInstantaneous"
359+
INSTLRG "LargeInstantaneous"
360+
INSTUEF "InstantaneousUEF"
360361
}
361362
*choicb WHASHPTYCH { // comments from Ecotope, see hphw.hh
362363
RESTANKNOUA "ResTankNoUA" // a simple resistance tank, but with no tank losses

src/CNGLOB.H

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -615,12 +615,14 @@ const float FHuge = float(1.E38); // Handy large (not strictly largest) value us
615615
// search initializations, etc. Single defn for portability and code clarity.
616616

617617
// Other constants
618-
const float SrcMultElect = 3.f; // Source multiplier for electrical energy (California CEC value)
619618
const float BtuperWh = 3.413f; // Btu per Wh
620619
const float BtuperkWh = 3413.f; // Btu per kWh
621-
const float BtuSrcperWh = 10.239f; /* Btu (source energy) per Wh. Includes California electric
622-
to source conversion factor of 3 (3 * 3.413 = 10.239);
623-
used to convert electrical consumption to source energy */
620+
#if 0 // obsolete
621+
x const float SrcMultElect = 3.f; // Source multiplier for electrical energy (California CEC value)
622+
x const float BtuSrcperWh = 10.239f; /* Btu (source energy) per Wh. Includes California electric
623+
x to source conversion factor of 3 (3 * 3.413 = 10.239);
624+
x used to convert electrical consumption to source energy */
625+
#endif
624626

625627
// re solar gain distribution (must be known for rccn.h)
626628
enum { socOPEN, socCLSD, socCOUNT }; // internal shade modes (open, closed)

src/CNRECS.DEF

Lines changed: 28 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -3359,7 +3359,8 @@ RECORD DHWHEATER "DHWHeater" *RAT // input / runtime DHW heater
33593359
*declare "int wh_IsStorage() const { return wh_type==C_WHTYPECH_STRGSML || wh_type==C_WHTYPECH_STRGLRG; }"
33603360
*declare "int wh_UsesDerivedLDEF() const;"
33613361
*declare "int wh_IsHPWHModel() const { return wh_heatSrc==C_WHHEATSRCCH_ASHPX || wh_heatSrc==C_WHHEATSRCCH_ELRESX; }"
3362-
*declare "int wh_IsSubhrModel() const { return wh_IsHPWHModel(); }"
3362+
*declare "int wh_IsInstUEFModel() const { return wh_type==C_WHTYPECH_INSTUEF; }"
3363+
*declare "int wh_IsSubhrModel() const { return wh_IsHPWHModel() || wh_IsInstUEFModel(); }"
33633364
*declare "float wh_CalcLDEF( float arl, int options=0);"
33643365
*declare "RC wh_DoHour( float HARL, int wsMult);"
33653366
*declare "RC wh_DoEndPreRun();"
@@ -3374,7 +3375,8 @@ RECORD DHWHEATER "DHWHeater" *RAT // input / runtime DHW heater
33743375
// _ASHPX: air source heat pump (Ecotope HPWH)
33753376
// _ELRESX: electric resistance (Ecotope HPWH)
33763377
*i WHTYPECH wh_type; // heater type
3377-
// C_WHTYPECH_STRGSML, _STRGLRG, _INSTSML, _INSTLRG
3378+
// C_WHTYPECH_STRGSML, _STRGLRG, _INSTSML, _INSTLRG,
3379+
// _INSTUEF
33783380
*i ANAME wh_desc; // probe-able description text
33793381
*i WHASHPTYCH wh_ashpTy; // air source heat pump type, required iff ASHPX, else ignored
33803382
// C_WHASHPTYCH_xxx, etc
@@ -3397,26 +3399,41 @@ RECORD DHWHEATER "DHWHeater" *RAT // input / runtime DHW heater
33973399
*i FLOAT_GZ wh_ashpResUse; // resistance heat parameter for
33983400
// Ecotope HPWH model iff C_WHASHPTYCH_GENERIC
33993401
// default = 7.22, units / meaning unknown
3400-
3402+
34013403
*i FLOAT_GEZ wh_vol; // storage tank vol, gal
34023404
// applicable to STRGxx types
34033405
// used only for HPWH ResistanceX, 5-2016
34043406
// default=50 if STRGxx else 0
34053407
*i FLOAT_GZ wh_EF; // rated energy factor
34063408
*i FLOAT_GZ wh_LDEF; // load-dependent energy factor
3407-
*i FLOAT_GZ wh_eff; // efficiency
3409+
*i FLOAT_GZ wh_UEF; // rated uniform energy factor
3410+
// documentation only re C_WHTYPECH_INSTUEF
3411+
*i FLOAT_GZ wh_ratedFlow; // max rated flow per UEF test, gpm
3412+
*i FLOAT_GZ wh_annualFuel; // annual fuel use per UEF method, therms/yr
3413+
*i FLOAT_GZ wh_annualElec; // annual electricity use per UEF method, kWh/yr
3414+
*declare "RC wh_InstUEFInit();"
3415+
*declare "RC wh_InstUEFDoSubhr( double* draw, double scale, double xLoss);"
3416+
3417+
*r FLOAT wh_cycLossFuel; // derived startup fuel use (=cyclic loss) for INSTUEF, Btu/cycle
3418+
*r FLOAT wh_cycLossElec; // derived startup electricity use (=cyclic loss) for INSTUEF, Btu/cycle
3419+
*r FLOAT wh_maxFlowX; // derived max flow for INSTUEF, gal/tick-F
3420+
*r FLOAT wh_maxInpX; // input at max flow, Btu/tick
3421+
3422+
*i FLOAT_GZ wh_eff; // efficiency (aka recovery efficiency)
34083423
*i FLOAT_GZ wh_HPAF; // heat pump adjustment factor
34093424
// used for small storage ASHP only
34103425
*i FLOAT_GEZ wh_SBL; // standby loss, Btuh
34113426
*h FLOAT_GEZ wh_pilotPwr; // pilot light power, Btuh
3412-
// included in
3427+
// included in wh_inFuel
34133428
*h FLOAT_GEZ wh_parElec; // parasitic electric use, W
34143429
*h FLOAT wh_tHWOut; // average hot water temp, F (at water heater)
34153430
// HPWH: as delivered by model (subhr average of tick calls)
34163431
// other: DHWSYS.ws_tUse
34173432
*h FLOAT wh_mixDownF; // factor for draw adjustment re HPWH setpoint > DHWSYS::ws_tUse
34183433
// Some HPWHs (e.g. Sanden) have fixed (high) setpoints
3419-
// We reduce draws to balance load at ws_tUse.
3434+
// draws are reduced to balance load at ws_tUse.
3435+
*s INt wh_drawTicks; // duration of current draw, for HPWH and INSTUEF, ticks
3436+
// allows detection of startup event
34203437

34213438
*i TI wh_elecMtri // meter for system electricity use (default = parent ws_elecMtri)
34223439
*i TI wh_fuelMtri // meter for system fuel use (default = parent ws_electMtri)
@@ -3431,8 +3448,11 @@ RECORD DHWHEATER "DHWHeater" *RAT // input / runtime DHW heater
34313448
// (includes wh_HPWHxBU)
34323449
*h *e FLOAT wh_inFuel; // fuel (including wh_pilotPwr)
34333450

3434-
3435-
*i FLOAT_GZ wh_input; // rated input, Btuh (future use?)
3451+
*i FLOAT_GZ wh_ratedInput;// rated primary input, Btuh (doc only)
3452+
*r FLOAT wh_operElec; // electrical power during operation at rating conditions, Btuh
3453+
// never input, derived for INSTUEF
3454+
*r FLOAT wh_stbyElec; // electrical power during standby, Btuh
3455+
// never input, derive for INSTUEF
34363456

34373457
*i FLOAT_GZ wh_resHtPwr; // upper element resistance heating power, W
34383458
// used for some models only

0 commit comments

Comments
 (0)