Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move static VRF variables to namespace #8339

Closed
wants to merge 5 commits into from
Closed
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 3 additions & 9 deletions src/EnergyPlus/HVACVariableRefrigerantFlow.cc
Original file line number Diff line number Diff line change
Expand Up @@ -220,6 +220,9 @@ namespace HVACVariableRefrigerantFlow {
Array1D<Real64> MinDeltaT; // minimum zone temperature difference from setpoint
Array1D<Real64> SumCoolingLoads; // sum of cooling loads
Array1D<Real64> SumHeatingLoads; // sum of heating loads
Real64 CurrentEndTime; // end time of current time step
Real64 CurrentEndTimeLast; // end time of last time step
Real64 TimeStepSysLast; // system time step on last time step
Comment on lines +223 to +225
Copy link
Contributor Author

Choose a reason for hiding this comment

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

The three variables are not initialized.

The static variables in the original code were not initialized as well, so I am not sure if this is ok.

Copy link
Collaborator

Choose a reason for hiding this comment

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

It's fine without initial values unless it's complaining about them being used before being initialized. That would need to be corrected.


// Object Data
Array1D<VRFCondenserEquipment> VRF; // AirConditioner:VariableRefrigerantFlow object
Expand Down Expand Up @@ -515,9 +518,6 @@ namespace HVACVariableRefrigerantFlow {
Real64 HREIRFTConst; // stead-state EIR fraction
Real64 HRInitialEIRFrac; // Fractional cooling degradation at the start of heat recovery from cooling mode
Real64 HREIRTC; // Time constant used to recover from initial degradation in cooling heat recovery
static Real64 CurrentEndTime; // end time of current time step
static Real64 CurrentEndTimeLast; // end time of last time step
static Real64 TimeStepSysLast; // system time step on last time step
Real64 SUMultiplier; // multiplier for simulating mode changes
Real64 CondPower; // condenser power [W]
Real64 CondCapacity; // condenser heat rejection [W]
Expand Down Expand Up @@ -5111,9 +5111,6 @@ namespace HVACVariableRefrigerantFlow {
int TUListIndex; // pointer to TU list for this VRF system
int IndexToTUInTUList; // index to TU in TerminalUnilList
Real64 RhoAir; // air density at InNode
static Real64 CurrentEndTime; // end time of current time step
static Real64 CurrentEndTimeLast; // end time of last time step
static Real64 TimeStepSysLast; // system time step on last time step
Real64 TempOutput; // Sensible output of TU
Real64 LoadToCoolingSP; // thermostat load to cooling setpoint (W)
Real64 LoadToHeatingSP; // thermostat load to heating setpoint (W)
Expand Down Expand Up @@ -10219,9 +10216,6 @@ namespace HVACVariableRefrigerantFlow {
Real64 HRCapTC; // Time constant used to recover from initial degradation in cooling heat recovery
Real64 HRInitialEIRFrac; // Fractional cooling degradation at the start of heat recovery from cooling mode
Real64 HREIRTC; // Time constant used to recover from initial degradation in cooling heat recovery
static Real64 CurrentEndTime; // end time of current time step
static Real64 CurrentEndTimeLast; // end time of last time step
static Real64 TimeStepSysLast; // system time step on last time step
Real64 SUMultiplier; // multiplier for simulating mode changes
Real64 CondPower; // condenser power [W]
Real64 CondCapacity; // condenser heat rejection [W]
Expand Down