TReacLab: An object-oriented implementation of non-intrusive splitting methods to couple independent transport and geochemical software

Reactive transport modeling contributes to understand geophysical and geochemical processes in subsurface environments. Operator splitting methods have been proposed as non-intrusive coupling techniques that optimize the use of existing chemistry and transport codes. In this spirit, we propose a coupler relying on external geochemical and transport codes with appropriate operator segmentation that enables possible developments of additional splitting methods. We provide an object-oriented implementation in TReacLab developed in the MATLAB environment in a free open source frame with an accessible repository. TReacLab contains classical coupling methods, template interfaces and calling functions for two classical transport and reactive software (PHREEQC and COMSOL). It is tested on four classical benchmarks with homogeneous and heterogeneous reactions at equilibrium or kinetically-controlled. We show that full decoupling to the implementation level has a cost in terms of accuracy compared to more integrated and optimized codes. Use of non-intrusive implementations like TReacLab are still justified for coupling independent transport and chemical software at a minimal development effort but should be systematically and carefully assessed.

[1]  Christophe Tournassat,et al.  Simulation of Cement/Clay Interactions: Feedback on the Increasing Complexity of Modelling Strategies , 2014, Transport in Porous Media.

[2]  Paolo Trinchero,et al.  Interface COMSOL-PHREEQC (iCP), an efficient numerical framework for the solution of coupled multiphysics and geochemistry , 2014, Comput. Geosci..

[3]  Janet G. Hering,et al.  Principles and Applications of Aquatic Chemistry , 1993 .

[4]  David L. Parkhurst,et al.  PhreeqcRM: A reaction module for transport simulators based on the geochemical model PHREEQC , 2015 .

[5]  K. Van Breugel,et al.  Lattice Boltzmann based multicomponent reactive transport model coupled with geochemical solver for scale simulations , 2013 .

[6]  T. P. Clement,et al.  Modeling Multispecies Reactive Transport in Ground Water , 1998 .

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

[8]  Scott R. Charlton,et al.  Modules based on the geochemical model PHREEQC for use in scripting and programming languages , 2011, Comput. Geosci..

[9]  Michel Kern,et al.  A global method for coupling transport with chemistry in heterogeneous porous media , 2009, 0912.3867.

[10]  C. Steefel,et al.  Approaches to modeling of reactive transport in porous media , 1996 .

[11]  W. J. Alves,et al.  Analytical solutions of the one-dimensional convective-dispersive solute transport equation , 1982 .

[12]  G. Strang On the Construction and Comparison of Difference Schemes , 1968 .

[13]  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 .

[14]  Peter Knabner,et al.  A new numerical reduction scheme for fully coupled multicomponent transport‐reaction problems in porous media , 2005 .

[15]  Douglas G. MacFarland,et al.  Simulation with C , 1984, WSC '84.

[16]  Thomas Zimmermann,et al.  Object-oriented nonlinear finite element programming: a primer , 2000 .

[17]  István Faragó,et al.  Additive and iterative operator splitting methods and their numerical investigation , 2008, Comput. Math. Appl..

[18]  Kamy Sepehrnoori,et al.  Coupling IPhreeqc with UTCHEM to model reactive flow and transport , 2015, Comput. Geosci..

[19]  Richard E. Ewing,et al.  An Operator Splitting Method for Nonlinear Reactive Transport Equations and Its Implementation Based on DLL and COM , 2005 .

[20]  C. Ayora,et al.  On the behavior of approaches to simulate reactive transport. , 2001, Journal of contaminant hydrology.

[21]  Ming-Hsu Li,et al.  Groundwater Reactive Transport Models , 2018 .

[22]  J. Geiser Decomposition Methods for Differential Equations: Theory and Applications , 2009 .

[23]  G E Hammond,et al.  Evaluating the performance of parallel subsurface simulators: An illustrative example with PFLOTRAN , 2014, Water resources research.

[24]  R. Mosé,et al.  Operator-splitting procedures for reactive transport and comparison of mass balance errors. , 2004, Journal of contaminant hydrology.

[25]  Peter Knabner,et al.  A general reduction scheme for reactive transport in porous media , 2012, Computational Geosciences.

[26]  John C. Friedly,et al.  Solute transport with multiple equilibrium‐controlled or kinetically controlled chemical reactions , 1992 .

[27]  Peter Knabner,et al.  A parallel global-implicit 2-D solver for reactive transport problems in porous media based on a reduction scheme and its application to the MoMaS benchmark problem , 2010 .

[28]  Albert J. Valocchi,et al.  Accuracy of operator splitting for advection‐dispersion‐reaction problems , 1992 .

[29]  P. Havé,et al.  Reactive Transport in Porous Media , 2009 .

[30]  Peter Engesgaard,et al.  A geochemical transport model for redox-controlled movement of mineral fronts in groundwater flow systems: A case of nitrate removal by oxidation of pyrite , 1992 .

[31]  Patrick Goblet,et al.  Module-oriented modeling of reactive transport with HYTEC , 2003 .

[32]  William D. Burgos,et al.  A general paradigm to model reaction‐based biogeochemical processes in batch systems , 2003 .

[33]  Jesús Carrera,et al.  A formulation for decoupling components in reactive transport problems , 2004 .

[34]  Jesús Carrera,et al.  A mathematical formulation for reactive transport that eliminates mineral concentrations , 1998 .

[35]  Christopher E. Kees,et al.  Adaptive split-operator methods for modeling transport phenomena in porous medium systems , 2011 .

[36]  Scott R. Charlton,et al.  PHAST Version 2?A Program for Simulating Groundwater Flow, Solute Transport, and Multicomponent Geochemical Reactions , 2014 .

[37]  Chuan Lu,et al.  PFLOTRAN: Reactive Flow & Transport Code for Use on Laptops to Leadership-Class Supercomputers , 2012 .

[38]  C. Bethke Geochemical and Biogeochemical Reaction Modeling , 2007 .

[39]  Matthew J. Simpson,et al.  Theoretical analysis and physical interpretation of temporal truncation errors in operator split algorithms , 2008, Math. Comput. Simul..

[40]  Damian Rouson,et al.  Scientific Software Design: The Object-Oriented Way , 2011 .

[41]  L. Trotignon,et al.  Predicting the long term durability of concrete engineered barriers in a geological repository for radioactive waste , 2007 .

[42]  Chang Li,et al.  A COMSOL-GEMS interface for modeling coupled reactive-transport geochemical processes , 2016, Comput. Geosci..

[43]  Diederik Jacques,et al.  MULTICOMPONENT GEOCHEMICAL TRANSPORT MODELING USING HYDRUS‐1D AND HP11 , 2006 .

[44]  Jocelyne Erhel,et al.  A global approach to reactive transport: application to the MoMas benchmark , 2010 .

[45]  I. Faragó,et al.  Weighted sequential splittings and their analysis , 2005 .

[46]  Jérôme Carrayrou,et al.  Implementation of Richardson extrapolation in an efficient adaptive time stepping method: applications to reactive transport and unsaturated flow in porous media , 2007 .

[47]  Fidel Grandia,et al.  Feedback between reactive transport and convective flow during CO2 migration in a saline aquifer , 2013 .

[48]  Michel Kern,et al.  A global strategy for solving reactive transport equations , 2009, J. Comput. Phys..

[49]  Othman Nasir,et al.  A simulator for modeling of porosity and permeability changes in near field sedimentary host rocks for nuclear waste under climate change influences , 2014 .

[50]  Thomas Wagner,et al.  GEM-Selektor geochemical modeling package: revised algorithm and GEMS3K numerical kernel for coupled simulation codes , 2012, Computational Geosciences.

[51]  Sebastian Bauer,et al.  Modelling CO2-induced fluid–rock interactions in the Altensalzwedel gas reservoir. Part II: coupled reactive transport simulation , 2012, Environmental Earth Sciences.

[52]  Ionel Michael Navon,et al.  VARIATM—A FORTRAN program for objective analysis of pseudostress wind fields using large-scale conjugate-gradient minimization , 1991 .

[53]  C. Steefel,et al.  Reactive transport modeling: An essential tool and a new research approach for the Earth sciences , 2005 .

[54]  Massimo Rolle,et al.  Modeling multicomponent ionic transport in groundwater with IPhreeqc coupling: Electrostatic interactions and geochemical reactions in homogeneous and heterogeneous domains , 2016 .

[55]  Martin Berzins,et al.  A Method for the Spatial Discretization of Parabolic Equations in One Space Variable , 1990, SIAM J. Sci. Comput..

[56]  Cass T. Miller,et al.  Temporal discretisation errors in non-iterative split-operator approaches to solving chemical reaction/groundwater transport models , 1996 .

[57]  R. D. Poshusta Error Analysis , 2019, Numerical Methods.

[58]  Benoit Cochepin,et al.  Modeling of concrete carbonation in deep geological disposal of intermediate level waste , 2013 .

[59]  Andy H. Register A Guide to MATLAB Object-Oriented Programming , 2007 .

[60]  P. G. Thomsen,et al.  On the additive splitting procedures and their computer realization , 2008 .

[61]  V. S. Tripathi,et al.  A critical evaluation of recent developments in hydrogeochemical transport models of reactive multichemical components , 1989 .

[62]  Kamy Sepehrnoori,et al.  A mechanistic integrated geochemical and chemical-flooding tool for alkaline/surfactant/polymer floods , 2016 .

[63]  J. Verwer,et al.  Numerical solution of time-dependent advection-diffusion-reaction equations , 2003 .

[64]  K. Pruess,et al.  TOUGH2 User's Guide Version 2 , 1999 .

[65]  István Faragó,et al.  Error analysis of the numerical solution of split differential equations , 2008, Math. Comput. Model..

[66]  J. Bear Dynamics of Fluids in Porous Media , 1975 .

[67]  Jesús Carrera,et al.  CHEPROO: A Fortran 90 object-oriented module to solve chemical processes in Earth Science models , 2009, Comput. Geosci..