Closed vancromy closed 4 years ago
Thanks for report it, it was a problem in logic in initial value for PT iteration, try with last commit, i think is fixed. The critical pressure value from ammonia and air was bad too, thanks for that too.
Thanks for the quick reply and fix.
Cloned the repo and confirmed its now working as intended. Is the new commit also automatically added to the pypi build or should I keep working off my cloned copy?
I've uploaded a new version to pypi, https://pypi.org/project/iapws/ with a new minor version release, try it from there. I remember you it can install using pip from any github repository without waiting a new release in pypi:
pip install git+https://github.com/jjgomera/iapws
If you are interesting in other compound properties, not only water, give a try to another library: https://github.com/jjgomera/pychemqt/tree/master/lib/mEoS
Best regards
Hello,
Thanks for this great repo allowing us to make use of the IAPWS standards. I was playing around with the ammonia.NH3 class and noticed some very unusual behaviour:
However when passing the correct density for that P and T, 3.4 kg/m3, the module is instantly returning the correct P without any issue:
It seems the MEoS is not able to converge to the right density but is having no problem working backwards to the pressure. Passing an initial rho0 did nothing:
Trying this with the thermo package:
I noticed that in the ammonia.py file, the critical pressure is defined in kPa and not MPa so I was wondering whether that might be one of the issues but could it be something with the root finder too?
OS version: macOS Catalina version 10.15.4 Python version: 3.7.6 Conda version: 4.8.3 IAPWS version: 1.4