View Issue Details

IDProjectCategoryView StatusLast Update
0003503OpenFOAMBugpublic2020-06-05 11:04
ReporterSamMallinson Assigned Tohenry  
PrioritynormalSeverityminorReproducibilityalways
Status closedResolutionno change required 
PlatformLinuxOSUbuntu and DebianOS Version18.04 and sid
Summary0003503: reactingParcelFoam with thermophysicalProperties.energy:sensibleEnthalpy crashes in v7, but runs ok in v6
DescriptionWhen updating an OpenFOAM case from version 6 to version 7, the run crashed due to issues with the thermophysical properties.

We noticed the comment for the commit https://github.com/OpenFOAM/OpenFOAM-dev/commit/f9971f80d72a5318cdc81120a925ab9817b3ec62 mentions:

"Changed liquid thermo from sensibleEnthalpy to sensibleInternalEnergy in
tutorials. It is generally more convergent and stable to solve for internal
energy if the fluid is incompressible or weakly compressible."

So, we changed the case to use sensibleInternalEnergy (with requisite modifications to system/fvSolution and fvSchemes) and it ran without issue.

We were also able to get the case run in version 7 by modifying OpenFOAM-7/src/thermophysicalModels/specie/equationOfState/icoPolynomial/icoPolynomialI.H, line 98, from "return p/this->rho(p, T);" to "return 0;" (that is, modifying the code to match that in version 6, https://github.com/OpenFOAM/OpenFOAM-6/blob/47517f2ebb1bdbacb8e3ce4b15110cd252953f87/src/thermophysicalModels/specie/equationOfState/icoPolynomial/icoPolynomialI.H#L98), and then recompiling; but that approach is unpalatable.

I would have expected the case in version 7 to run with sensibleEnthalpy, as it did in version 6. Have the underlying thermodynamic equations changed? Is there a reference?
Steps To ReproduceFor version 6:
- download sergeyevShaw_of6.tar, un-tar it, call foam-bash-6 (. ~/pathTo/OpenFoam-6/etc/bashrc) then ./Allrun

For version 7, which does not work
- using the same case as above, ie sergeyevShaw_of6.tar, call foam-bash-7 (. ~/pathTo/OpenFoam-7/etc/bashrc) then ./Allrun

For version 7, which does work
- download sergeyevShaw_of7_sIE.tar, un-tar it, call foam-bash-7 (. ~/pathTo/OpenFoam-7/etc/bashrc) then ./Allrun
Additional InformationCase based on the paper by Sergeyev and Shaw, http://dx.doi.org/10.1088/0957-0233/17/10/N01: droplets of 34 um diameter and velocity 7 m/s are fired horizontally and their trajectory measured.

It would make a nice tutorial example for reactingParcelFoam.
TagsNo tags attached.

Activities

SamMallinson

2020-06-03 22:35

reporter  

sergeyevShaw_of6.tar (61,440 bytes)
sergeyevShaw_of7_sIE.tar (61,440 bytes)

henry

2020-06-03 23:39

manager   ~0011372

> I would have expected the case in version 7 to run with sensibleEnthalpy, as it did in version 6. Have the underlying thermodynamic equations changed? Is there a reference?

The enthalpy contribution from the equation of state is p/rho so version 7 is correct and returning 0 instead as in version 6 is an error.

henry

2020-06-03 23:41

manager   ~0011373

"Changed liquid thermo from sensibleEnthalpy to sensibleInternalEnergy in
tutorials. It is generally more convergent and stable to solve for internal
energy if the fluid is incompressible or weakly compressible."

This is good advice, you should use sensibleInternalEnergy with icoPolynomial and other incompressible equations of state.

Issue History

Date Modified Username Field Change
2020-06-03 22:35 SamMallinson New Issue
2020-06-03 22:35 SamMallinson File Added: sergeyevShaw_of6.tar
2020-06-03 22:35 SamMallinson File Added: sergeyevShaw_of7_sIE.tar
2020-06-03 23:39 henry Note Added: 0011372
2020-06-03 23:41 henry Note Added: 0011373
2020-06-05 11:04 henry Assigned To => henry
2020-06-05 11:04 henry Status new => closed
2020-06-05 11:04 henry Resolution open => no change required