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

Coil refactor feb2020 rich #36

Merged
merged 2 commits into from
Feb 25, 2020
Merged
Show file tree
Hide file tree
Changes from all 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
1 change: 1 addition & 0 deletions src/EnergyPlus/Coils/CoilCoolingDX.cc
Original file line number Diff line number Diff line change
Expand Up @@ -413,6 +413,7 @@ void CoilCoolingDX::getDataAfterSizing(Real64 &_normalModeRatedEvapAirFlowRate,
}

void CoilCoolingDX::size() {
this->performance.parentName = this->name;
this->performance.size();
}

Expand Down
1 change: 1 addition & 0 deletions src/EnergyPlus/Coils/CoilCoolingDXCurveFitOperatingMode.cc
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,7 @@ void CoilCoolingDXCurveFitOperatingMode::size()
this->ratedCondAirFlowRate = TempSize;

for (auto &curSpeed : this->speeds) {
curSpeed.parentName = this->parentName;
curSpeed.parentModeRatedGrossTotalCap = this->ratedGrossTotalCap;
curSpeed.parentModeRatedEvapAirFlowRate = this->ratedEvapAirFlowRate;
curSpeed.parentModeRatedCondAirFlowRate = this->ratedCondAirFlowRate;
Expand Down
1 change: 1 addition & 0 deletions src/EnergyPlus/Coils/CoilCoolingDXCurveFitOperatingMode.hh
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@ struct CoilCoolingDXCurveFitOperatingModeInputSpecification
struct CoilCoolingDXCurveFitOperatingMode
{
std::string object_name = "Coil:Cooling:DX:CurveFit:OperatingMode";
std::string parentName;

void instantiateFromInputSpec(CoilCoolingDXCurveFitOperatingModeInputSpecification input_data);
void size();
Expand Down
1 change: 1 addition & 0 deletions src/EnergyPlus/Coils/CoilCoolingDXCurveFitPerformance.cc
Original file line number Diff line number Diff line change
Expand Up @@ -180,6 +180,7 @@ void CoilCoolingDXCurveFitPerformance::simulate(const DataLoopNode::NodeData &in
void CoilCoolingDXCurveFitPerformance::size()
{
if (!DataGlobals::SysSizingCalc && this->mySizeFlag) {
this->normalMode.parentName = this->parentName;
this->normalMode.size();
if (this->hasAlternateMode) {
this->alternateMode.size();
Expand Down
2 changes: 2 additions & 0 deletions src/EnergyPlus/Coils/CoilCoolingDXCurveFitPerformance.hh
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ class OutputFiles;
struct CoilCoolingDXCurveFitPerformanceInputSpecification
{
std::string name;
std::string parentName;
Real64 crankcase_heater_capacity;
Real64 minimum_outdoor_dry_bulb_temperature_for_compressor_operation;
Real64 maximum_outdoor_dry_bulb_temperature_for_crankcase_heater_operation;
Expand All @@ -77,6 +78,7 @@ struct CoilCoolingDXCurveFitPerformanceInputSpecification
struct CoilCoolingDXCurveFitPerformance
{
std::string object_name = "Coil:Cooling:DX:CurveFit:Performance";
std::string parentName;
void instantiateFromInputSpec(const CoilCoolingDXCurveFitPerformanceInputSpecification &input_data);
void simulate(const DataLoopNode::NodeData &inletNode,
DataLoopNode::NodeData &outletNode,
Expand Down
4 changes: 2 additions & 2 deletions src/EnergyPlus/Coils/CoilCoolingDXCurveFitSpeed.cc
Original file line number Diff line number Diff line change
Expand Up @@ -332,8 +332,8 @@ void CoilCoolingDXCurveFitSpeed::size()
Psychrometrics::PsyRhoAirFnPbTdbW(DataEnvironment::StdBaroPress, RatedInletAirTemp, RatedInletAirHumRat, RoutineName);

bool PrintFlag = true;
std::string CompType = this->object_name;
std::string CompName = this->name;
std::string CompType = DataHVACGlobals::cAllCoilTypes(DataHVACGlobals::CoilDX_Cooling);
std::string CompName = this->parentName;

int SizingMethod = DataHVACGlobals::CoolingAirflowSizing;
std::string SizingString = "Rated Air Flow Rate [m3/s]";
Expand Down
1 change: 1 addition & 0 deletions src/EnergyPlus/Coils/CoilCoolingDXCurveFitSpeed.hh
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,7 @@ struct CoilCoolingDXCurveFitSpeedInputSpecification
struct CoilCoolingDXCurveFitSpeed
{
std::string const object_name = "Coil:Cooling:DX:CurveFit:Speed";
std::string parentName;

CoilCoolingDXCurveFitSpeed() = default;
explicit CoilCoolingDXCurveFitSpeed(const std::string& name);
Expand Down
2 changes: 1 addition & 1 deletion src/EnergyPlus/ReportCoilSelection.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1898,7 +1898,7 @@ bool ReportCoilSelection::isCompTypeCoil(std::string const &compType // string c
{
// if compType name is one of the coil objects, then return true
bool found(false);
for (int loop = 1; loop < DataHVACGlobals::NumAllCoilTypes; ++loop) {
for (int loop = 1; loop <= DataHVACGlobals::NumAllCoilTypes; ++loop) {
if (UtilityRoutines::SameString(compType, DataHVACGlobals::cAllCoilTypes(loop))) {
found = true;
break;
Expand Down