Abstract

<p>The modern advances in computing and experimental capabilities in the research of water-rock-interactions require geoscientists to routinely combine laboratory data and models to produce knowledge in order to solve pressing societal challenges connected to subsurface utilization. Data science is hence a more and more pervasive instrument also for  geochemists, which in turn demands flexible and easy to learn software adaptable to their specific needs. <br>In this contribution we showcase geochemical and reactive transport modelling with our RedModRphree [1] extension package for the GNU R environment and programming language. The new version of the package leverages the R interface to the established PHREEQC geochemical simulator maintained by its original authors [2]. R has established itself as de facto standard language for statistics and machine learning. It enjoys increasing diffusion in many applied scientific fields such as bioinformatics, chemometrics and ecological modelling. The availability of excellent third party extensions such as the thermodynamic package CHNOSZ [3], which extends the functionalities of SUPCRT92, as well as its advanced graphical and numerical capabilities, make R an attractive platform for comprehensive geochemical data analysis, experiment evaluation and modelling. <br>The aim of RedModRphree is to provide the user with an easy-to-use, high-level interface to program algorithms involving geochemical models, which are then solved using the PHREEQC engine: parameter calibration, error and sensitivity analysis, visualization, up to CPU-intensive parallel coupled reactive transport models. Among the out-of-the-box features included in RedModRphree, we highlight the computation and visualization of Pourbaix (Eh-pH) diagrams and the implementation of 1D advective reactive transport supporting the use of surrogate models replacing expensive PHREEQC calculations [4]. RedModRphree is open source and can be installed from https://git.gfz-potsdam.de/delucia/RedModRphree.</p><p><img src="https://contentmanager.copernicus.org/fileStorageProxy.php?f=gnp.72552df75cff57113730161/sdaolpUECMynit/12UGE&app=m&a=0&c=afa6bef86f4c5523b81a86ccdd579fc9&ct=x&pn=gnp.elif&d=1" alt=""></p><p>[1] De Lucia, M. and Kühn, M.: Coupling R and PHREEQC: Efficient Programming of Geochemical Models, Energy Procedia, 40, 464–471, doi.org/10.1016/j.egypro.2013.08.053, 2013.</p><p>[2] Charlton, S.R. and Parkhurst, D.L.: Modules based on the geochemical model PHREEQC for use in scripting and programming languages, Computers & Geosciences 37, 10, 1653–1663, doi.org/10.1016/j.cageo.2011.02.005, 2011.</p><p>[3] Dick, J.M.: CHNOSZ: Thermodynamic Calculations and Diagrams for Geochemistry, Frontiers in Earth Science, 7, https://doi.org/10.3389/feart.2019.00180, 2019.</p><p>[4] Jatnieks, J., De Lucia, M., Dransch, D., and Sips, M.: Data-driven Surrogate Model Approach for Improving the Performance of Reactive Transport Simulations, Energy Procedia, 97, 447–453, doi.org/10.1016/j.egypro.2016.10.047, 2016.</p><p> </p>

Highlights

  • The GNU R language and programming environment has established itself as de facto standard language for statistics and machine learning, enjoying increasing diffusion in many applied scientific fields such as bioinformatics, chemometrics and ecological modelling

  • We introduce the open source RedModRphree extension package, which leverages the R interface to the established PHREEQC geochemical simulator

  • GNU R (R Core Team, 2021) is an open source software environment and programming language originally developed for statistical computing and graphics as new implementation of the closed source S language

Read more

Summary

Introduction

GNU R (R Core Team, 2021) is an open source software environment and programming language originally developed for statistical computing and graphics as new implementation of the closed source S language. At the moment of writing, over 17750 user-contributed extension packages have been submitted to the official repository called Comprehensive R Archive Network (CRAN) Indices of these packages, termed “Task Views” (Zeileis, 2005, 2021), are provided by domain experts to offer guidance in navigating such an ample landscape by organizing them under specific topics. An interface to the established geochemical simulator PHREEQC (Appelo et al, 2013; Parkhurst and Appelo, 2013) for the R language is available on CRAN as package phreeqc (Charlton and Parkhurst, 2011, note the lowercase writing adopted in this paper to distinguish it from PHREEQC itself) This interface only exposes the Application Programming Interface (API) of PHREEQC to R, and does not provide utility functions to quickly setup new models or in general to program algorithms involving geochemical calculations. Before diving into these applications, we provide a general overview of RedModRphree, its logic and its fundamentals illustrated with code examples

Package description
Basic usage demonstration
Parallel computations
Additional resources: demos and documentation
Pourbaix diagrams
Conclusions

Talk to us

Join us for a 30 min session where you can share your feedback and ask us any queries you have

Schedule a call

Disclaimer: All third-party content on this website/platform is and will remain the property of their respective owners and is provided on "as is" basis without any warranties, express or implied. Use of third-party content does not indicate any affiliation, sponsorship with or endorsement by them. Any references to third-party content is to identify the corresponding services and shall be considered fair use under The CopyrightLaw.