@@ -2761,6 +2761,18 @@ void InitOAController(EnergyPlusData &state, int const OAControllerNum, bool con
2761
2761
}
2762
2762
}
2763
2763
2764
+ // Fill People index lists if needed
2765
+ if (vent_mech.SystemOAMethod == DataSizing::SysOAMethod::ProportionalControlDesOcc) {
2766
+ for (int peopleNum = 1 ; peopleNum <= state.dataHeatBal ->TotPeople ; ++peopleNum) {
2767
+ for (auto &thisMechVentZone : vent_mech.VentMechZone ) {
2768
+ if (state.dataHeatBal ->People (peopleNum).ZonePtr == thisMechVentZone.zoneNum ) {
2769
+ thisMechVentZone.peopleIndexes .push_back (peopleNum);
2770
+ break ;
2771
+ }
2772
+ }
2773
+ }
2774
+ }
2775
+
2764
2776
// Check to see if any zones on an air loop are not accounted for by a mechanical ventilation object
2765
2777
for (int AirLoopZoneInfoZoneNum = 1 ; AirLoopZoneInfoZoneNum <= state.dataAirLoop ->AirLoopZoneInfo (AirLoopNum).NumZones ;
2766
2778
++AirLoopZoneInfoZoneNum) {
@@ -3608,19 +3620,18 @@ Real64 VentilationMechanicalProps::CalcMechVentController(EnergyPlusData &state,
3608
3620
// new local variables for DCV
3609
3621
// Zone OA flow rate based on each calculation method [m3/s]
3610
3622
std::array<Real64, static_cast <int >(DataSizing::OAFlowCalcMethod::Num)> ZoneOACalc{0.0 };
3611
- Real64 CO2PeopleGeneration = 0 ; // CO2 generation from people at design level
3612
- Real64 ZoneOABZ; // Zone breathing-zone OA flow rate [m3/s]
3613
- Real64 ZoneOA; // Zone OA flow rate [m3/s]
3614
- Real64 ZoneOAFrac; // Zone OA fraction (as a fraction of actual supply air flow rate)
3615
- Real64 SysOAuc; // System uncorrected OA flow rate
3616
- Real64 SysOA; // System supply OA volume flow rate [m3/s]
3617
- Real64 SysEv; // System ventilation efficiency
3618
- Real64 NodeTemp; // node temperature
3619
- Real64 NodeHumRat; // node humidity ratio
3620
- Real64 ZoneMaxCO2 = 0.0 ; // Breathing-zone CO2 concentartion
3621
- Real64 ZoneMinCO2 = 0.0 ; // Minimum CO2 concentration in zone
3622
- Real64 ZoneOAMin = 0.0 ; // Minimum Zone OA flow rate when the zone is unoccupied (i.e. ZoneOAPeople = 0)
3623
- Real64 ZoneOAMax = 0.0 ; // Maximum Zone OA flow rate (ZoneOAPeople + ZoneOACalc[static_cast<int>(DataSizing::OAFlowCalcMethod::PerArea)])
3623
+ Real64 ZoneOABZ; // Zone breathing-zone OA flow rate [m3/s]
3624
+ Real64 ZoneOA; // Zone OA flow rate [m3/s]
3625
+ Real64 ZoneOAFrac; // Zone OA fraction (as a fraction of actual supply air flow rate)
3626
+ Real64 SysOAuc; // System uncorrected OA flow rate
3627
+ Real64 SysOA; // System supply OA volume flow rate [m3/s]
3628
+ Real64 SysEv; // System ventilation efficiency
3629
+ Real64 NodeTemp; // node temperature
3630
+ Real64 NodeHumRat; // node humidity ratio
3631
+ Real64 ZoneMaxCO2 = 0.0 ; // Breathing-zone CO2 concentartion
3632
+ Real64 ZoneMinCO2 = 0.0 ; // Minimum CO2 concentration in zone
3633
+ Real64 ZoneOAMin = 0.0 ; // Minimum Zone OA flow rate when the zone is unoccupied (i.e. ZoneOAPeople = 0)
3634
+ Real64 ZoneOAMax = 0.0 ; // Maximum Zone OA flow rate (ZoneOAPeople + ZoneOACalc[static_cast<int>(DataSizing::OAFlowCalcMethod::PerArea)])
3624
3635
Real64 MechVentOAMassFlow = 0.0 ;
3625
3636
3626
3637
// Apply mechanical ventilation only when it is available/allowed
@@ -3882,8 +3893,8 @@ Real64 VentilationMechanicalProps::CalcMechVentController(EnergyPlusData &state,
3882
3893
// Calculate zone maximum target CO2 concentration in PPM
3883
3894
if (this ->SystemOAMethod == DataSizing::SysOAMethod::ProportionalControlDesOcc) {
3884
3895
// Accumulate CO2 generation from people at design occupancy and current activity level
3885
- for ( int PeopleNum = 1 ; PeopleNum <= state. dataHeatBal -> TotPeople ; ++PeopleNum) {
3886
- if (state. dataHeatBal -> People (PeopleNum). ZonePtr != ZoneNum) continue ;
3896
+ Real64 CO2PeopleGeneration = 0.0 ;
3897
+ for ( int const PeopleNum : thisMechVentZone. peopleIndexes ) {
3887
3898
CO2PeopleGeneration +=
3888
3899
state.dataHeatBal ->People (PeopleNum).NumberOfPeople *
3889
3900
state.dataHeatBal ->People (PeopleNum).CO2RateFactor *
0 commit comments