Skip to content

Commit 2a966e9

Browse files
committed
Space IV-ZoneCoolTowerShower
1 parent 8d8fec6 commit 2a966e9

File tree

4 files changed

+41
-18
lines changed

4 files changed

+41
-18
lines changed

doc/input-output-reference/src/overview/group-airflow.tex

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1965,9 +1965,9 @@ \subsubsection{Inputs}\label{inputs-8-002}
19651965

19661966
This field is the name of the schedule that denotes whether the cooltower can run during a given time period. A schedule value greater than 0 (usually 1 is used) indicates that the cooltower is available and can be on during the time period. A value less than or equal to 0 (usually 0 is used) denotes that the cooltower is not available and must be off for the time period. If this field is blank, the schedule has values of 1 for all time periods.
19671967

1968-
\paragraph{Field: Zone Name}\label{field-zone-name-6}
1968+
\paragraph{Field: Zone or Space Name}\label{field-zone-name-6}
19691969

1970-
This field is the name of the zone (ref: Zone) and attaches a particular cooltower statement to a thermal zone in the building.
1970+
This field is the name of the zone (ref: Zone) or space the cooltower is attached to.
19711971

19721972
\paragraph{Field: Water Supply Storage Tank Name}\label{field-water-supply-storage-tank-name}
19731973

idd/Energy+.idd.in

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24795,18 +24795,19 @@ ZoneCoolTower:Shower,
2479524795
\memo A cooltower (sometimes referred to as a wind tower or a shower cooling tower)
2479624796
\memo models passive downdraught evaporative cooling (PDEC) that is designed to capture the
2479724797
\memo wind at the top of a tower and cool the outdoor air using water evaporation before
24798-
\memo delivering it to a space.
24798+
\memo delivering it to a zone (or space).
2479924799
A1, \field Name
2480024800
\required-field
2480124801
A2, \field Availability Schedule Name
2480224802
\note Availability schedule name for this system. Schedule value > 0 means the system is available.
2480324803
\note If this field is blank, the system is always available.
2480424804
\type object-list
2480524805
\object-list ScheduleNames
24806-
A3, \field Zone Name
24806+
A3, \field Zone or Space Name
2480724807
\required-field
2480824808
\type object-list
2480924809
\object-list ZoneNames
24810+
\object-list SpaceNames
2481024811
A4, \field Water Supply Storage Tank Name
2481124812
\note In case of stand alone tank or underground water, leave this input blank
2481224813
\type object-list

src/EnergyPlus/CoolTower.cc

Lines changed: 34 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -198,9 +198,10 @@ namespace CoolTower {
198198
}
199199
}
200200

201-
state.dataCoolTower->CoolTowerSys(CoolTowerNum).ZoneName = state.dataIPShortCut->cAlphaArgs(3); // Name of zone where cooltower is serving
202201
state.dataCoolTower->CoolTowerSys(CoolTowerNum).ZonePtr = Util::FindItemInList(state.dataIPShortCut->cAlphaArgs(3), Zone);
203-
if (state.dataCoolTower->CoolTowerSys(CoolTowerNum).ZonePtr == 0) {
202+
state.dataCoolTower->CoolTowerSys(CoolTowerNum).spacePtr =
203+
Util::FindItemInList(state.dataIPShortCut->cAlphaArgs(3), state.dataHeatBal->space);
204+
if ((state.dataCoolTower->CoolTowerSys(CoolTowerNum).ZonePtr == 0) && (state.dataCoolTower->CoolTowerSys(CoolTowerNum).spacePtr == 0)) {
204205
if (lAlphaBlanks(3)) {
205206
ShowSevereError(state,
206207
format("{}=\"{}\" invalid {} is required but input is blank.",
@@ -216,6 +217,9 @@ namespace CoolTower {
216217
state.dataIPShortCut->cAlphaArgs(3)));
217218
}
218219
ErrorsFound = true;
220+
} else if (state.dataCoolTower->CoolTowerSys(CoolTowerNum).ZonePtr == 0) {
221+
state.dataCoolTower->CoolTowerSys(CoolTowerNum).ZonePtr =
222+
state.dataHeatBal->space(state.dataCoolTower->CoolTowerSys(CoolTowerNum).spacePtr).zoneNum;
219223
}
220224

221225
state.dataCoolTower->CoolTowerSys(CoolTowerNum).CoolTWaterSupplyName = state.dataIPShortCut->cAlphaArgs(4); // Name of water storage tank
@@ -627,7 +631,12 @@ namespace CoolTower {
627631
thisZoneHB.MCPTC = 0.0;
628632
thisZoneHB.MCPC = 0.0;
629633
thisZoneHB.CTMFL = 0.0;
630-
634+
if ((state.dataHeatBal->doSpaceHeatBalance) && (state.dataCoolTower->CoolTowerSys(CoolTowerNum).spacePtr > 0)) {
635+
auto &thisSpaceHB = state.dataZoneTempPredictorCorrector->zoneHeatBalance(state.dataCoolTower->CoolTowerSys(CoolTowerNum).spacePtr);
636+
thisSpaceHB.MCPTC = 0.0;
637+
thisSpaceHB.MCPC = 0.0;
638+
thisSpaceHB.CTMFL = 0.0;
639+
}
631640
if (ScheduleManager::GetCurrentScheduleValue(state, state.dataCoolTower->CoolTowerSys(CoolTowerNum).SchedPtr) > 0.0) {
632641
// check component operation
633642
if (state.dataEnvrn->WindSpeed < MinWindSpeed || state.dataEnvrn->WindSpeed > MaxWindSpeed) continue;
@@ -707,22 +716,35 @@ namespace CoolTower {
707716
AirDensity = Psychrometrics::PsyRhoAirFnPbTdbW(state, state.dataEnvrn->OutBaroPress, OutletTemp, OutletHumRat); // Outlet air density
708717
CVF_ZoneNum = state.dataCoolTower->CoolTowerSys(CoolTowerNum).ActualAirVolFlowRate *
709718
ScheduleManager::GetCurrentScheduleValue(state, state.dataCoolTower->CoolTowerSys(CoolTowerNum).SchedPtr);
710-
thisZoneHB.MCPC = CVF_ZoneNum * AirDensity * AirSpecHeat;
711-
thisZoneHB.MCPTC = thisZoneHB.MCPC * OutletTemp;
712-
thisZoneHB.CTMFL = thisZoneHB.MCPC / AirSpecHeat;
719+
Real64 thisMCPC = CVF_ZoneNum * AirDensity * AirSpecHeat;
720+
Real64 thisMCPTC = thisMCPC * OutletTemp;
721+
Real64 thisCTMFL = thisMCPC / AirSpecHeat;
722+
Real64 thisZT = thisZoneHB.ZT;
723+
Real64 thisAirHumRat = thisZoneHB.airHumRat;
724+
thisZoneHB.MCPC = thisMCPC;
725+
thisZoneHB.MCPTC = thisMCPTC;
726+
thisZoneHB.CTMFL = thisCTMFL;
727+
if ((state.dataHeatBal->doSpaceHeatBalance) && (state.dataCoolTower->CoolTowerSys(CoolTowerNum).spacePtr > 0)) {
728+
auto &thisSpaceHB =
729+
state.dataZoneTempPredictorCorrector->zoneHeatBalance(state.dataCoolTower->CoolTowerSys(CoolTowerNum).spacePtr);
730+
thisSpaceHB.MCPC = thisMCPC;
731+
thisSpaceHB.MCPTC = thisMCPTC;
732+
thisSpaceHB.CTMFL = thisCTMFL;
733+
thisZT = thisSpaceHB.ZT;
734+
thisAirHumRat = thisSpaceHB.airHumRat;
735+
}
713736

714-
state.dataCoolTower->CoolTowerSys(CoolTowerNum).SenHeatPower = thisZoneHB.MCPC * std::abs(thisZoneHB.ZT - OutletTemp);
715-
state.dataCoolTower->CoolTowerSys(CoolTowerNum).LatHeatPower = CVF_ZoneNum * std::abs(thisZoneHB.airHumRat - OutletHumRat);
737+
state.dataCoolTower->CoolTowerSys(CoolTowerNum).SenHeatPower = thisMCPC * std::abs(thisZT - OutletTemp);
738+
state.dataCoolTower->CoolTowerSys(CoolTowerNum).LatHeatPower = CVF_ZoneNum * std::abs(thisAirHumRat - OutletHumRat);
716739
state.dataCoolTower->CoolTowerSys(CoolTowerNum).OutletTemp = OutletTemp;
717740
state.dataCoolTower->CoolTowerSys(CoolTowerNum).OutletHumRat = OutletHumRat;
718741
state.dataCoolTower->CoolTowerSys(CoolTowerNum).AirVolFlowRate = CVF_ZoneNum;
719-
state.dataCoolTower->CoolTowerSys(CoolTowerNum).AirMassFlowRate = thisZoneHB.CTMFL;
720-
state.dataCoolTower->CoolTowerSys(CoolTowerNum).AirVolFlowRateStd = thisZoneHB.CTMFL / state.dataEnvrn->StdRhoAir;
742+
state.dataCoolTower->CoolTowerSys(CoolTowerNum).AirMassFlowRate = thisCTMFL;
743+
state.dataCoolTower->CoolTowerSys(CoolTowerNum).AirVolFlowRateStd = thisCTMFL / state.dataEnvrn->StdRhoAir;
721744
state.dataCoolTower->CoolTowerSys(CoolTowerNum).InletDBTemp = Zone(ZoneNum).OutDryBulbTemp;
722745
state.dataCoolTower->CoolTowerSys(CoolTowerNum).InletWBTemp = Zone(ZoneNum).OutWetBulbTemp;
723746
state.dataCoolTower->CoolTowerSys(CoolTowerNum).InletHumRat = state.dataEnvrn->OutHumRat;
724-
state.dataCoolTower->CoolTowerSys(CoolTowerNum).CoolTWaterConsumpRate =
725-
(std::abs(InletHumRat - OutletHumRat) * thisZoneHB.CTMFL) / RhoWater;
747+
state.dataCoolTower->CoolTowerSys(CoolTowerNum).CoolTWaterConsumpRate = (std::abs(InletHumRat - OutletHumRat) * thisCTMFL) / RhoWater;
726748
state.dataCoolTower->CoolTowerSys(CoolTowerNum).CoolTWaterStarvMakeupRate = 0.0; // initialize -- calc in update
727749
state.dataCoolTower->CoolTowerSys(CoolTowerNum).PumpElecPower =
728750
state.dataCoolTower->CoolTowerSys(CoolTowerNum).RatedPumpPower * PumpPartLoadRat;

src/EnergyPlus/CoolTower.hh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -85,9 +85,9 @@ namespace CoolTower {
8585
std::string Name; // The component name
8686
std::string CompType; // Type of component
8787
std::string Schedule; // Available schedule
88-
std::string ZoneName; // Name of zone the component is serving
8988
int SchedPtr = 0; // Index to schedule
90-
int ZonePtr = 0; // Point to this zone
89+
int ZonePtr = 0; // Index to zone
90+
int spacePtr = 0; // Index to space (if applicable)
9191
int PumpSchedPtr = 0; // Index to schedule for water pump
9292
FlowCtrl FlowCtrlType = FlowCtrl::Invalid; // Type of cooltower operation
9393
WaterSupplyMode CoolTWaterSupplyMode = WaterSupplyMode::FromMains; // Type of water source

0 commit comments

Comments
 (0)