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

Refrigeration Transcritical Compressor Energy Use subcooling not using correct enthalpy for capacity correction #10754

Open
1 of 3 tasks
PMP-Rsch opened this issue Sep 20, 2024 · 0 comments

Comments

@PMP-Rsch
Copy link

PMP-Rsch commented 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
image5544
The coding for these equations however use an incorrect enthalpy for "h_4" ONLY FOR THE CAPACITY, the massflow uses the correct h_4.

image5543

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.

  • Defect file added (list location of defect file here)
  • 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)
@PMP-Rsch 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
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant