pytzer
pytzer is a Python 3.6+ implementation of the Pitzer model for chemical activities in aqueous solutions (Pitzer, 1991).
Installation
If using conda, first create and activate a new environment with Python 3.6 and numpy 1.15. Then:
pip install pytzer
Other versions are probably fine, but untested. We are using Python 3.6 rather than 3.7 to enable planned integration with MATLAB.
See the quick-start guide for more detailed instructions and examples.
Development status
pytzer is in beta. Tests of the accuracy of its coefficients and equations are underway, so results may change. API may change and functions may be added or removed. Use at your own peril!
Modules
Module | Purpose |
.io |
Import and export data |
.cflibs |
Define combinations of model coefficients to use |
.model |
Implement the Pitzer model |
.coeffs |
Define functions to evaluate model coefficients |
.tables |
Store tables of coefficient values |
.jfuncs |
Define unsymmetrical mixing functions |
.props |
Define universal ionic properties |
.constants |
Define physical constants |
.meta |
Define package metadata |
Acknowledgements
pytzer is maintained by Dr Matthew P. Humphreys at the Centre for Ocean and Atmospheric Sciences, School of Environmental Sciences, University of East Anglia, Norwich, UK.
Its ongoing development is funded by the Natural Environment Research Council (NERC, UK) through NSFGEO-NERC: A Thermodynamic Chemical Speciation Model for the Oceans, Seas, and Estuaries (NE/P012361/1).
License
The entirety of pytzer is licensed under the GNU General Public License version 3 (GPLv3).
References
Pitzer, K. S. (1991). “Ion Interaction Approach: Theory and Data Correlation,” in Activity Coefficients in Electrolyte Solutions, 2nd Edition, ed. K. S. Pitzer (CRC Press, Florida, USA), 75–153.