Modules based on the geochemical model PHREEQC for use in scripting and programming languages

The geochemical model PHREEQC is capable of simulating a wide range of equilibrium reactions between water and minerals, ion exchangers, surface complexes, solid solutions, and gases. It also has a general kinetic formulation that allows modeling of nonequilibrium mineral dissolution and precipitation, microbial reactions, decomposition of organic compounds, and other kinetic reactions. To facilitate use of these reaction capabilities in scripting languages and other models, PHREEQC has been implemented in modules that easily interface with other software. A Microsoft COM (component object model) has been implemented, which allows PHREEQC to be used by any software that can interface with a COM server-for example, Excel^(R), Visual Basic^(R), Python, or MATLAB^(R). PHREEQC has been converted to a C++ class, which can be included in programs written in C++. The class also has been compiled in libraries for Linux and Windows that allow PHREEQC to be called from C++, C, and Fortran. A limited set of methods implements the full reaction capabilities of PHREEQC for each module. Input methods use strings or files to define reaction calculations in exactly the same formats used by PHREEQC. Output methods provide a table of user-selected model results, such as concentrations, activities, saturation indices, and densities. The PHREEQC module can add geochemical reaction capabilities to surface-water, groundwater, and watershed transport models. It is possible to store and manipulate solution compositions and reaction information for many cells within the module. In addition, the object-oriented nature of the PHREEQC modules simplifies implementation of parallel processing for reactive-transport models. The PHREEQC COM module may be used in scripting languages to fit parameters; to plot PHREEQC results for field, laboratory, or theoretical investigations; or to develop new models that include simple or complex geochemical calculations.

[1]  Philippe Martinet,et al.  Modeling expected solute concentration in randomly heterogeneous flow systems with multicomponent reactions. , 2004, Environmental science & technology.

[2]  John H. Weare,et al.  The prediction of mineral solubilities in natural waters: the NaKMgCaClSO4H2O system from zero to high concentration at 25° C , 1980 .

[3]  N. Møller,et al.  The prediction of mineral solubilities in natural waters: The Na-K-Mg-Ca-H-Cl-SO4-OH-HCO3-CO3-CO2-H2O system to high ionic strengths at 25°C , 1984 .

[4]  Kenneth S. Pitzer,et al.  Thermodynamics of electrolytes. I. Theoretical basis and general equations , 1973 .

[5]  TACK: a program coupling chemical kinetics with a two-dimensional transport model in geochemical systems , 2003 .

[6]  D. A. Barry,et al.  Reactive transport in unsaturated soil: Comprehensive modelling of the dynamic spatial and temporal mass balance of water and chemical components , 2008 .

[7]  David G. Kinniburgh,et al.  PhreePlot: Creating graphical output with PHREEQC , 2011 .

[8]  Jill S. Baron,et al.  Application of a coupled ecosystem-chemical equilibrium model, DayCent-Chem, to stream and soil chemistry in a Rocky Mountain watershed , 2007 .

[9]  David L. Parkhurst,et al.  A computer program incorporating Pitzer's equations for calculation of geochemical reactions in brines , 1988 .

[10]  D. A. Barry,et al.  Three-dimensional model for multi-component reactive transport with variable density groundwater flow , 2006, Environ. Model. Softw..

[11]  Henning Prommer,et al.  PHT3D – A three-dimensional biogeochemical transport model for modelling natural and enhanced remediation.In Johnston, C. D., editor,Proceedings of the , 1999 .

[12]  D. L. Parkhurst,et al.  User's guide to PHREEQC (Version 2)-a computer program for speciation, batch-reaction, one-dimensional transport, and inverse geochemical calculations , 1999 .

[13]  D. A. Barry,et al.  Implementation of variably saturated flow into PHREEQC for the simulation of biogeochemical reactions in the vadose zone , 2010, Environ. Model. Softw..

[14]  James W. Ball,et al.  User's manual for WATEQ4F, with revised thermodynamic data base and text cases for calculating speciation of major, trace, and redox elements in natural waters , 1991 .

[15]  Reinhold Jahn,et al.  New Tool RhizoMath for Modeling Coupled Transport and Speciation in the Rhizosphere , 2008 .

[16]  D. A. Barry,et al.  2 , , 1993 .