Skip to content

Commit b65543b

Browse files
authored
Merge pull request #403 from cse-sim/flowmult
IZXFER izLinkedFlowMult re support of models using zone multiplier(s)
2 parents 5420cbd + f2bcc7c commit b65543b

File tree

5 files changed

+100
-88
lines changed

5 files changed

+100
-88
lines changed

doc/src/records/izxfer.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,22 @@ Name of DOAS where air is supplied from (**izVfMin** > 0), or exhausting to (**i
103103
required: "when izNVType = AIRNETDOAS",
104104
variability: "constant") %>
105105

106+
**izLinkedFlowMult=*float***
107+
108+
Specifies a multiplier applied to air flow to/from any associated DOAS. This supports use of a single modeled zone to represent multiple actual zones while preserving the total DOAS air flow and energy consumption.
109+
110+
For example, consider a DOAS-linked IZXFER with izVfMin = 100 and izLinkedFlowMult = 5. The zone specified by izZn1 receives 100 cfm while the DOAS specified by izDOAS is modeled as if the supply flow is 500 cfm. Thus the DOAS behavior (fan energy use etc.) approximates that of a DOAS serving 5 zones, but only one zone is simulated.
111+
112+
Note izLinkedFlowMult has no effect on the air flow to or from the zone specified by izZn1.
113+
114+
<%= member_table(
115+
units: "--",
116+
legal_range: "*x* $\\gt$ 0",
117+
default: "1",
118+
required: "No",
119+
variability: "constant") %>
120+
121+
106122
Give izHConst for a conductive transfer between zones. Give izNVType other than NONE and the following variables for a convective (air) transfer between the zones or between a zone and outdoors. Both may be given if desired. Not known to work properly as of July 2011
107123

108124
**izHConst=*float***

src/CNRECS.DEF

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3033,6 +3033,12 @@ RECORD IZXRAT "izXfer" *RAT // interzone heat transfers: conductive and/or vent.
30333033
*s AFLOW iz_vfMin // min vent flow rate, cfm (for fixed flow types)
30343034
// (*net* supply flow for _ANHERV)
30353035
*s AFLOW iz_vfMax // max vent flow rate, cfm (for fixed flow types)
3036+
*i FLOAT_GZ iz_linkedFlowMult // multiplier for flow to/from linked zone or DOAS or ...
3037+
// applied to flow seen by "other" zone or device (but not this zone)
3038+
// supports zone multiplier schemes
3039+
// initially implemented for DOAS only, 6-1-2023
3040+
3041+
30363042
*s FRAC iz_ASEF // apparent sensible effectiveness (for _ANHERV)
30373043
*s FRAC iz_LEF // latent effectiveness (for _ANHERV)
30383044
*s FRAC iz_SRE // HVI sensible recovery efficiency (for _ANHERV)

src/cgcomp.cpp

Lines changed: 33 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -1016,7 +1016,7 @@ RC DOAS::oa_CkfDOAS() // input checks
10161016

10171017

10181018
return rc;
1019-
}
1019+
} // DOAS::oa_CkfDOAS
10201020
//-----------------------------------------------------------------------------
10211021
RC DOAS::oa_Setup(DOAS* iRat)
10221022
{
@@ -1035,18 +1035,15 @@ RC DOAS::oa_Setup(DOAS* iRat)
10351035
float exhFanVfDemand = 0.f;
10361036

10371037
IZXRAT* izx;
1038-
RLUP( IzxR, izx)
1038+
RLUPC( IzxR, izx, izx->iz_doas == ss)
10391039
{
1040-
if (izx->iz_IsDOAS() && izx->iz_doas == ss)
1040+
if (izx->iz_vfMin > 0.f)
10411041
{
1042-
if (izx->iz_vfMin > 0.f)
1043-
{
1044-
supFanVfDemand += izx->iz_vfMin;
1045-
}
1046-
else
1047-
{
1048-
exhFanVfDemand -= izx->iz_vfMin;
1049-
}
1042+
supFanVfDemand += izx->iz_vfMin * izx->iz_linkedFlowMult;
1043+
}
1044+
else
1045+
{
1046+
exhFanVfDemand -= izx->iz_vfMin * izx->iz_linkedFlowMult;
10501047
}
10511048
}
10521049

@@ -1071,14 +1068,10 @@ RC DOAS::oa_Setup(DOAS* iRat)
10711068

10721069
// Adjust IZXFER flows
10731070
IZXRAT* izx;
1074-
RLUP( IzxR, izx)
1075-
{
1076-
if (izx->iz_IsDOAS() && izx->iz_doas == ss)
1071+
RLUPC(IzxR, izx, izx->iz_doas == ss)
1072+
{ if (izx->iz_vfMin > 0.f)
10771073
{
1078-
if (izx->iz_vfMin > 0.f)
1079-
{
1080-
izx->iz_vfMin *= supFlowRatio;
1081-
}
1074+
izx->iz_vfMin *= supFlowRatio;
10821075
}
10831076
}
10841077
}
@@ -1099,14 +1092,10 @@ RC DOAS::oa_Setup(DOAS* iRat)
10991092

11001093
// Adjust IZXFER flows
11011094
IZXRAT* izx;
1102-
RLUP( IzxR, izx)
1103-
{
1104-
if (izx->iz_IsDOAS() && izx->iz_doas == ss)
1095+
RLUPC( IzxR, izx, izx->iz_doas == ss)
1096+
{ if (izx->iz_vfMin < 0.f)
11051097
{
1106-
if (izx->iz_vfMin < 0.f)
1107-
{
1108-
izx->iz_vfMin *= exhFlowRatio;
1109-
}
1098+
izx->iz_vfMin *= exhFlowRatio;
11101099
}
11111100
}
11121101
}
@@ -1159,29 +1148,27 @@ RC DOAS::oa_BegSubhr()
11591148
{
11601149
RC rc = RCOK;
11611150
// Get total air flow rates and calculate mixed exhaust air state
1162-
oa_supAF.af_amf = 0.;
1163-
oa_exhAF.af_amf = 0.;
1164-
float supVf = 0.f;
1165-
float exhVf = 0.f;
1151+
oa_supAF.af_Init();
1152+
oa_exhAF.af_Init();
1153+
float supVf = 0.f; // total supply flow provided by this DOAS, cfm
1154+
// float exhVf = 0.f; // total exhaust flow for this DOAS, cfm
1155+
// not used, activate if needed
11661156
IZXRAT* izx;
1167-
RLUP( IzxR, izx)
1157+
RLUPC(IzxR, izx, izx->iz_doas == ss)
11681158
{
1169-
if (izx->iz_IsDOAS() && izx->iz_doas == ss)
1159+
if (izx->iz_vfMin > 0.f)
11701160
{
1171-
if (izx->iz_vfMin > 0.f)
1172-
{
1173-
supVf += izx->iz_vfMin;
1174-
}
1175-
else
1176-
{
1177-
ZNR* zpx = ZrB.GetAt( izx->iz_zi1);
1178-
AIRSTATE zoneAir;
1179-
zpx->zn_GetAirStateLs( zoneAir);
1180-
float rhoX = zpx->zn_rho0ls;
1181-
exhVf -= izx->iz_vfMin;
1182-
AIRFLOW zoneExhAF(-izx->iz_vfMin * rhoX * 60.f, zoneAir);
1183-
oa_exhAF.af_Mix(zoneExhAF);
1184-
}
1161+
supVf += izx->iz_vfMin * izx->iz_linkedFlowMult;
1162+
}
1163+
else
1164+
{
1165+
ZNR* zpx = ZrB.GetAt( izx->iz_zi1);
1166+
AIRSTATE zoneAir;
1167+
zpx->zn_GetAirStateLs( zoneAir);
1168+
float rhoX = zpx->zn_rho0ls;
1169+
// exhVf -= izx->iz_vfMin * izx->iz_linkedFlowMult; activate if needed
1170+
AIRFLOW zoneExhAF(-izx->iz_vfMin * izx->iz_linkedFlowMult * rhoX * 60.f, zoneAir);
1171+
oa_exhAF.af_Mix(zoneExhAF);
11851172
}
11861173
}
11871174
oa_supAF.af_amf = supVf * Top.tp_rhoMoistOSh * 60.f;
@@ -1625,6 +1612,7 @@ x }
16251612
rc |= require(when, IZXRAT_DOAS);
16261613
}
16271614
break;
1615+
16281616
case C_IZNVTYCH_ANIZFLOW:
16291617
case C_IZNVTYCH_ANEXTFLOW:
16301618
rc |= disallowN("when izNVType is flow AIRNET",

src/cncult.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1459,6 +1459,7 @@ CULT( "izDOAS", DAT, IZXRAT_DOAS, 0, 0, VEOI, TYREF, &OAiB, 0.f,
14591459
CULT( "izHConst", DAT, IZXRAT_UA, 0, 0, VHRLY, TYFL, 0, 0.f, N, N),
14601460
CULT( "izNVType", DAT, IZXRAT_NVCNTRL,0, 0, VEOI, TYCH, 0, C_IZNVTYCH_NONE, N, N),
14611461
CULT( "izAFCat", DAT, IZXRAT_AFCATI, 0, 0, VEOI, TYCH, 0, 0, N, N),
1462+
CULT( "izLinkedFlowMult",DAT,IZXRAT_LINKEDFLOWMULT,0,0,VEOI, TYFL, 0, 1.f, N, N),
14621463
CULT( "izALo", DAT, IZXRAT_A1, 0, 0, VHRLY, TYFL, 0, 0.f, N, N),
14631464
CULT( "izAHi", DAT, IZXRAT_A2, 0, 0, VHRLY, TYFL, 0, 0.f, N, N),
14641465
CULT( "izL1", DAT, IZXRAT_L1, 0, 0, VEOI, TYFL, 0, 0.f, N, N),

test/ref/ASHPPKGROOM.REP

Lines changed: 44 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -529,16 +529,16 @@ Top
529529
repBotM 6 129 0 0 1 1 nz 0 0 0
530530
repTestPfx 6 130 0 0 1 4 0 0 0 0
531531
ck5aa5 6 285 4 0 0 1 nz 0 0 0
532-
material 5 0 16400 0 0 0 material 0 0 487 0
533-
construction 5 0 16400 0 0 0 construction 0 0 476 0
534-
foundation 5 0 16 0 0 0 foundation 0 0 464 0
535-
glazeType 5 0 16 0 0 0 glazeType 0 0 45d 0
536-
zone 5 0 16400 0 0 0 zone 0 0 338 0
537-
izXfer 5 0 16384 0 0 0 izXfer 0 0 2db 0
532+
material 5 0 16400 0 0 0 material 0 0 488 0
533+
construction 5 0 16400 0 0 0 construction 0 0 477 0
534+
foundation 5 0 16 0 0 0 foundation 0 0 465 0
535+
glazeType 5 0 16 0 0 0 glazeType 0 0 45e 0
536+
zone 5 0 16400 0 0 0 zone 0 0 339 0
537+
izXfer 5 0 16384 0 0 0 izXfer 0 0 2dc 0
538538
afmeter 5 0 16 0 0 0 AFMETER 0 0 23d 0
539539
loadmeter 5 0 16 0 0 0 LOADMETER 0 0 23a 0
540540
rsys 5 0 16400 0 0 0 RSYS 0 0 29f 0
541-
doas 5 0 16 0 0 0 doas 0 0 30b 0
541+
doas 5 0 16 0 0 0 doas 0 0 30c 0
542542
dhwdayuse 5 0 16 0 0 0 DHWDayUse 0 0 229 0
543543
dhwmeter 5 0 16 0 0 0 DHWMETER 0 0 240 0
544544
dhwsys 5 0 0 0 0 0 DHWSYS 0 0 1a7 0
@@ -547,15 +547,15 @@ Top
547547
battery 5 0 0 0 0 0 Battery 0 0 12b 0
548548
shadex 5 0 0 0 0 0 SHADEX 0 0 11c 0
549549
airHandler 5 0 16 0 0 0 airHandler 0 0 117 0
550-
meter 5 0 16400 0 0 0 meter 0 0 3a1 0
551-
gain 5 0 32 0 0 0 gain 0 0 39a 0
552-
reportCol 5 0 32 0 0 0 reportCol 0 0 38a 0
553-
exportCol 5 0 32 0 0 0 exportCol 0 0 380 0
554-
report 5 0 32 0 0 0 report 0 0 377 0
555-
export 5 0 32 0 0 0 export 0 0 361 0
556-
reportfile 5 0 0 0 0 0 reportFile 0 0 34c 0
557-
exportfile 5 0 0 0 0 0 exportFile 0 0 345 0
558-
importfile 5 0 16 0 0 0 importFile 0 0 33f 0
550+
meter 5 0 16400 0 0 0 meter 0 0 3a2 0
551+
gain 5 0 32 0 0 0 gain 0 0 39b 0
552+
reportCol 5 0 32 0 0 0 reportCol 0 0 38b 0
553+
exportCol 5 0 32 0 0 0 exportCol 0 0 381 0
554+
report 5 0 32 0 0 0 report 0 0 378 0
555+
export 5 0 32 0 0 0 export 0 0 362 0
556+
reportfile 5 0 0 0 0 0 reportFile 0 0 34d 0
557+
exportfile 5 0 0 0 0 0 exportFile 0 0 346 0
558+
importfile 5 0 16 0 0 0 importFile 0 0 340 0
559559
heatPlant 5 0 16 0 0 0 heatPlant 0 0 7a 0
560560
coolPlant 5 0 16 0 0 0 coolPlant 0 0 4b 0
561561
towerPlant 5 0 16 0 0 0 towerPlant 0 0 3d 0
@@ -927,6 +927,7 @@ izXfer Parent: Top
927927
izHConst 6 5 0 0 739 2 0 0 0 0
928928
izNVType 6 6 16384 0 1 16 nz 0 0 0
929929
izAFCat 6 7 0 0 1 16 0 0 0 0
930+
izLinkedFlowMult 6 21 0 0 1 2 0 1 0 0
930931
izALo 6 10 16384 0 739 2 0 0 0 0
931932
izAHi 6 11 0 0 739 2 0 0 0 0
932933
izL1 6 12 0 0 1 2 0 0 0 0
@@ -938,25 +939,25 @@ izXfer Parent: Top
938939
izExp 6 17 16384 0 1 2 0 0.5 0 0
939940
izVfMin 6 19 0 0 1763 2 0 0 0 0
940941
izVfMax 6 20 0 0 1763 2 0 0 0 0
941-
izASEF 6 21 0 0 1763 2 0 0 0 0
942-
izLEF 6 22 0 0 1763 2 0 0 0 0
943-
izSRE 6 23 0 0 1763 2 0 0 0 0
944-
izASRE 6 24 0 0 1763 2 0 0 0 0
945-
izRVFanHeatF 6 25 0 0 1763 2 0 0 0 0
946-
izVfExhRat 6 26 0 0 1763 2 0 1 0 0
947-
izEATR 6 27 0 0 1763 2 0 0 0 0
948-
izFanVfDs 6 29 0 0 1 2 0 0 0 0
949-
izFanPress 6 33 0 0 1 2 0 0.3 0 0
950-
izFanEff 6 34 0 0 1 2 0 0.08 0 0
951-
izFanShaftBhp 6 35 0 0 1 2 0 0 0 0
952-
izFanElecPwr 6 36 0 0 1 2 0 0 0 0
953-
izFanMtr 6 46 0 0 1 8192 meter 0 0 0 0
954-
izFanEndUse 6 47 0 0 1 16 nz 0 0 0
955-
izFanType 6 28 4 0 0 16 nz 0 0 0
956-
izFanVfMxF 6 32 4 0 0 2 0 1 0 0
957-
izFanMotPos 6 39 4 0 0 16 nz 0 0 0
958-
izFanCurvePy 6 40 128 0 1 2 0 0 nz 0
959-
izFanMotEff 6 38 4 0 0 2 0 1 0 0
942+
izASEF 6 22 0 0 1763 2 0 0 0 0
943+
izLEF 6 23 0 0 1763 2 0 0 0 0
944+
izSRE 6 24 0 0 1763 2 0 0 0 0
945+
izASRE 6 25 0 0 1763 2 0 0 0 0
946+
izRVFanHeatF 6 26 0 0 1763 2 0 0 0 0
947+
izVfExhRat 6 27 0 0 1763 2 0 1 0 0
948+
izEATR 6 28 0 0 1763 2 0 0 0 0
949+
izFanVfDs 6 30 0 0 1 2 0 0 0 0
950+
izFanPress 6 34 0 0 1 2 0 0.3 0 0
951+
izFanEff 6 35 0 0 1 2 0 0.08 0 0
952+
izFanShaftBhp 6 36 0 0 1 2 0 0 0 0
953+
izFanElecPwr 6 37 0 0 1 2 0 0 0 0
954+
izFanMtr 6 47 0 0 1 8192 meter 0 0 0 0
955+
izFanEndUse 6 48 0 0 1 16 nz 0 0 0
956+
izFanType 6 29 4 0 0 16 nz 0 0 0
957+
izFanVfMxF 6 33 4 0 0 2 0 1 0 0
958+
izFanMotPos 6 40 4 0 0 16 nz 0 0 0
959+
izFanCurvePy 6 41 128 0 1 2 0 0 nz 0
960+
izFanMotEff 6 39 4 0 0 2 0 1 0 0
960961
endIzxfer 13 0 0 0 0 0 0 0 0 0
961962

962963

@@ -1988,7 +1989,7 @@ inverse Parent: Top
19881989
ivX 6 6 8 0 1771 2 0 0 0 0
19891990
ivY 6 7 8 0 1771 2 0 0 0 0
19901991
endInverse 13 0 0 0 0 0 0 0 0 0
1991-
! CSE 0.916.0+auxfeff.ad2e5053.2 for Win32 console
1992+
! CSE 0.917.0 for Win32 console
19921993

19931994

19941995

@@ -3551,18 +3552,18 @@ Input for Run 001:
35513552

35523553

35533554

3554-
! CSE 0.916.0+auxfeff.ad2e5053.2 for Win32 console run(s) done: Wed 31-May-23 3:22:00 pm
3555+
! CSE 0.917.0 for Win32 console run(s) done: Thu 01-Jun-23 12:28:29 pm
35553556

35563557
! Executable: d:\cse\msvc\cse.exe
3557-
! 31-May-23 3:18 pm (VS 14.29 2749952 bytes) (HPWH 1.22.0)
3558+
! 01-Jun-23 12:16 pm (VS 14.29 2749952 bytes) (HPWH 1.22.0)
35583559
! Command line: -x! -t1 ashppkgroom
35593560
! Input file: D:\cse\test\ashppkgroom.cse
35603561
! Report file: D:\cse\test\ashppkgroom.rep
35613562

35623563
! Timing info --
35633564

3564-
! Input: Time = 0.10 Calls = 2 T/C = 0.0485
3565-
! AutoSizing: Time = 0.30 Calls = 1 T/C = 0.2960
3566-
! Simulation: Time = 6.61 Calls = 1 T/C = 6.6090
3567-
! Reports: Time = 0.00 Calls = 1 T/C = 0.0030
3568-
! Total: Time = 7.01 Calls = 1 T/C = 7.0120
3565+
! Input: Time = 0.10 Calls = 2 T/C = 0.0480
3566+
! AutoSizing: Time = 0.30 Calls = 1 T/C = 0.2990
3567+
! Simulation: Time = 6.64 Calls = 1 T/C = 6.6400
3568+
! Reports: Time = 0.00 Calls = 1 T/C = 0.0020
3569+
! Total: Time = 7.04 Calls = 1 T/C = 7.0420

0 commit comments

Comments
 (0)