You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
h_4 should be the enthalpy after the subcooler, but the code of "RefrigeratedCase.cc" uses the enthalpy BEFORE the subcooler, just after the gas cooler (Extract from "RefrigeratedCases.cc"):
The effect of the bug is that the application of a subcooler does not reduce the consumption of the compressor. A proof of this being a bug is that in the same code, the subcooler calculation ends with this:
This is "the enthalpy (J/kg) reduction of the Gas cooler". And the variable "DelHSubcoolerDis" is used in calculating the massflow of the refrigeration system:
So in the calculation of the massflow it was considered that "the enthalpy of the refrigerant entering the receiver INCLUDES the effect of the Subcooler". But then this effect is missing in the capacity calculation. So this results in a subcooler reducing the rated massflow BUT not reducing the electricity consumption.
This is my fixthat in my E+ modified version works (When subcooling is done both the bypass mass, the total massflow and the consumption are reduced). The total Enthalpy Change Actual is changed to use the same variable of the subcooler than the massflow part of the code. This way it is using the same enthalpy as what the documentation says (Which is the correct one):
Ticket added to EnergyPlus Defect Complexity (Github Project)
Pull request created (the pull request will have additional tasks related to reviewing changes that fix this defect)
The text was updated successfully, but these errors were encountered:
PMP-Rsch
changed the title
Refrigeration Compressor Energy Use subcooling not using correct enthalpy for capacity correction
Refrigeration Transcritical Compressor Energy Use subcooling not using correct enthalpy for capacity correction
Sep 20, 2024
Issue overview
The code for the calculation of the refrigeration compressor enregy use is supposed to use these equations:
https://bigladdersoftware.com/epx/docs/8-0/engineering-reference/page-099.html#compressor-energy-use-1
The coding for these equations however use an incorrect enthalpy for "h_4" ONLY FOR THE CAPACITY, the massflow uses the correct h_4.
h_4 should be the enthalpy after the subcooler, but the code of "RefrigeratedCase.cc" uses the enthalpy BEFORE the subcooler, just after the gas cooler (Extract from "RefrigeratedCases.cc"):
https://github.com/NREL/EnergyPlus/blob/80732bf0a8a545891d2b4a4fdc316bbccf658d28/src/EnergyPlus/RefrigeratedCase.cc#L13940C1-L13940C100
TotalEnthalpyChangeActualMT = this->HCompInHP - GasCooler(this->GasCoolerNum(1)).HGasCoolerOut;
And then it is applied in the aforementioned equation:
https://github.com/NREL/EnergyPlus/blob/80732bf0a8a545891d2b4a4fdc316bbccf658d28/src/EnergyPlus/RefrigeratedCase.cc#L14006
CapacityCorrectionMT = MassCorrectionMT * TotalEnthalpyChangeActualMT / CaseEnthalpyChangeRatedMT;
The effect of the bug is that the application of a subcooler does not reduce the consumption of the compressor. A proof of this being a bug is that in the same code, the subcooler calculation ends with this:
https://github.com/NREL/EnergyPlus/blob/80732bf0a8a545891d2b4a4fdc316bbccf658d28/src/EnergyPlus/RefrigeratedCase.cc#L13918
this->DelHSubcoolerSuc = SubcoolEffect * (HIdeal - this->HCompInHP);
this->HCompInHP += this->DelHSubcoolerSuc;
this->DelHSubcoolerDis = -this->DelHSubcoolerSuc;
This is "the enthalpy (J/kg) reduction of the Gas cooler". And the variable "DelHSubcoolerDis" is used in calculating the massflow of the refrigeration system:
https://github.com/NREL/EnergyPlus/blob/80732bf0a8a545891d2b4a4fdc316bbccf658d28/src/EnergyPlus/RefrigeratedCase.cc#L13880C1-L13880C135
if (std::abs((Hnew - (GasCooler(this->GasCoolerNum(1)).HGasCoolerOut + this->DelHSubcoolerDis)) / Hnew) < ErrorTol) break;
So in the calculation of the massflow it was considered that "the enthalpy of the refrigerant entering the receiver INCLUDES the effect of the Subcooler". But then this effect is missing in the capacity calculation. So this results in a subcooler reducing the rated massflow BUT not reducing the electricity consumption.
This is my fixthat in my E+ modified version works (When subcooling is done both the bypass mass, the total massflow and the consumption are reduced). The total Enthalpy Change Actual is changed to use the same variable of the subcooler than the massflow part of the code. This way it is using the same enthalpy as what the documentation says (Which is the correct one):
https://github.com/NREL/EnergyPlus/blob/80732bf0a8a545891d2b4a4fdc316bbccf658d28/src/EnergyPlus/RefrigeratedCase.cc#L13940C1-L13940C100
TotalEnthalpyChangeActualMT = this->HCompInHP - (GasCooler(this->GasCoolerNum(1)).HGasCoolerOut+this->DelHSubcoolerDis);
Details
Some additional details for this issue (if relevant):
Checklist
Add to this list or remove from it as applicable. This is a simple templated set of guidelines.
The text was updated successfully, but these errors were encountered: