Skip to content

Fix VRF crankcase heater calculations for multiple compressors#11486

Merged
mitchute merged 9 commits intodevelopfrom
11020-VRF-crankcase-heater-issue
Apr 14, 2026
Merged

Fix VRF crankcase heater calculations for multiple compressors#11486
mitchute merged 9 commits intodevelopfrom
11020-VRF-crankcase-heater-issue

Conversation

@rraustad
Copy link
Copy Markdown
Collaborator

@rraustad rraustad commented Mar 27, 2026

Pull request overview

Description of the purpose of this PR

VRF Crankcase heater operation not as expected. Reported by help desk as issue 11020 and recently this unmet hours post.

https://unmethours.com/question/103176/vrf-crankcase-heater-operation/

Used example file VariableRefrigerantFlow_5Zone as defect file with Chicago weather.

Pull Request Author

  • Title of PR should be user-synopsis style (clearly understandable in a standalone changelog context)
  • Label the PR with at least one of: Defect, Refactoring, NewFeature, Performance, and/or DoNoPublish
  • Pull requests that impact EnergyPlus code must also include unit tests to cover enhancement or defect repair
  • Author should provide a "walkthrough" of relevant code changes using a GitHub code review comment process
  • If any diffs are expected, author must demonstrate they are justified using plots and descriptions
  • If changes fix a defect, the fix should be demonstrated in plots and descriptions
  • If any defect files are updated to a more recent version, upload new versions here or on DevSupport
  • If IDD requires transition, transition source, rules, ExpandObjects, and IDFs must be updated, and add IDDChange label
  • If structural output changes, add to output rules file and add OutputChange label
  • If adding/removing any LaTeX docs or figures, update that document's CMakeLists file dependencies
  • If adding/removing any output files (e.g., eplustbl.*)
    • Update ..\scripts\Epl-run.bat
    • Update ..\scripts\RunEPlus.bat
    • Update ..\src\EPLaunch\ MainModule.bas, epl-ui.frm, and epl.vbp (VersionComments)
    • Update ...github\workflows\energyplus.py

Reviewer

  • Perform a Code Review on GitHub
  • If branch is behind develop, merge develop and build locally to check for side effects of the merge
  • If defect, verify by running develop branch and reproducing defect, then running PR and reproducing fix
  • If feature, test running new feature, try creative ways to break it
  • CI status: all green or justified
  • Check that performance is not impacted (CI Linux results include performance check)
  • Run Unit Test(s) locally
  • Check any new function arguments for performance impacts
  • Verify IDF naming conventions and styles, memos and notes and defaults
  • If new idf included, locally check the err file and other outputs

@rraustad rraustad self-assigned this Mar 27, 2026
@rraustad rraustad added the Defect Includes code to repair a defect in EnergyPlus label Mar 27, 2026
// calculate crankcase heater power
if (vrf.MaxOATCCHeater > OutdoorDryBulb) {
// calculate crankcase heater power
vrf.CrankCaseHeaterPower = vrf.CCHeaterPower * (1.0 - VRFRTF);
Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

These calculations start by adding in a baseline crankcase heater power. Then added in other values based on number of compressors. I could not follow what was intended so just came up with a different approach. Feel free to simplify code if a better method is conceived.

@rraustad
Copy link
Copy Markdown
Collaborator Author

rraustad commented Mar 27, 2026

VariableRefrigerantFlow_5Zone.idf:

AirConditioner:VariableRefrigerantFlow,
  15,                      !- Crankcase Heater Power per Compressor {W}
  3,                       !- Number of Compressors {dimensionless}
  0.33,                    !- Ratio of Compressor Size to Total Compressor Capacity {W/W}

Showing before changes in develop branch and then what looks like the correct answer from this branch.

image

This branch:

image

CondInletTemp = OutdoorDryBulb; // node inlet temp from above
OutdoorWetBulb = CondInletTemp; // for watercooled
CondWaterMassFlow = vrf.WaterCondenserDesignMassFlow;
OATForCCHeater = state.dataEnvrn->OutDryBulbTemp;
Copy link
Copy Markdown
Collaborator Author

@rraustad rraustad Mar 27, 2026

Choose a reason for hiding this comment

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

While creating the unit test I realized that for water-cooled VRF the condenser water inlet node was controlling the crankcase heater. So I added a variable specific to the VRF condenser type to control the crankcase heater.

" 15, !- Crankcase Heater Power per Compressor {W}",
" 3, !- Number of Compressors {dimensionless}",
" 0.33, !- Ratio of Compressor Size to Total Compressor Capacity {W/W}",
" 0.13, !- Ratio of Compressor Size to Total Compressor Capacity {W/W}",
Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

This input for Ratio of compressor size to total does have an effect on crankcase heater power. For this reason I had to use a more detailed calculation as my attempt at simplification did not take this input into account.

@github-actions
Copy link
Copy Markdown

⚠️ Regressions detected on ubuntu-24.04 for commit 2c5d542

Regression Summary
  • ESO Small Diffs: 703
  • Table Small Diffs: 391
  • MTR Small Diffs: 523
  • Table String Diffs: 186
  • EIO: 396
  • JSON Small Diffs: 2
  • ZSZ Small Diffs: 72
  • Table Big Diffs: 36
  • ERR: 14
  • MTR Big Diffs: 2
  • EDD: 4
  • ESO Big Diffs: 10
  • SSZ Small Diffs: 13
  • JSON Big Diffs: 2

@mitchute
Copy link
Copy Markdown
Collaborator

Thanks @rraustad. Merging.

@mitchute mitchute merged commit aeb685a into develop Apr 14, 2026
11 checks passed
@mitchute mitchute deleted the 11020-VRF-crankcase-heater-issue branch April 14, 2026 23:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Defect Includes code to repair a defect in EnergyPlus

Projects

None yet

Development

Successfully merging this pull request may close these issues.

VRF Crankcase heater operation is inconsistent with temperature limits

3 participants