0

Using iTough2 with third-party forward modelling software

Hello,

 

To which extend is it possible to use iTough2 with a third party forward modelling software? Could it be possible with potentially some minimal modification of the source code to use iTough interacting with Input/ output of another software than Tough?

 

Kind regards,

Ludo

2 replies

null
    • Finsterle GeoConsulting
    • Stefan_Finsterle
    • 2 days ago
    • Reported - view

    Hi Ludo,

    The feature you propose - linking a third-party modeling software (TPMS) to iTOUGH2 - is not just a possibility, but has been an integral part of iTOUGH2 since 2010. Here is how it works:

    (1) Define adjustable input parameters of your TPMS through a template file using the well-known PEST/JUPITER protocol (Doherty, 2008; Banta et al., 2008).

    (2) Select observable output variables of interest through an instruction file using the PEST/JUPITER protocol.

    (3) Add the TPMS-related parameters and observations as well as the command(s) or script(s) used to execute the TPMS in the iTOUGH2 input file.  

    That’s it! Here is the iTOUGH2-PEST flow chart 

    There are a few conditions (they also apply to PEST and UCODE and other “universal: optimization frameworks):

    - The (adjustable) input to the TPMS must be provided on an ASCII file.

    - The TPMS output of interest must be provided on an ASCII file.

    - The TPMS must be run to completion without user intervention.

    In iTOUGH2, you can actually combine the TPMS with a TOUGH2 simulation. Here are a couple of examples how I have used this feature:

    (A) As the “TPMS” I call a unix script file that in turn calls a number of external pre-processing codes and scripts that generate the TOUGH2 MESH file. This may even include a template file of a Fortran source code; this source code is automatically updated by iTOUGH2, then recompiled and executed. Its output is then used by other codes, for example, AMESH or even TOUGH2 itself to run its internal MESHM mesh generator (whose parameter, such as fracture spacing, can also be adjusted through PEST), before it calls a suite of mesh-modification codes (such as those provided at https://www.finsterle-geoconsulting.com/download). This allows you to adapt the mesh (including its extent, well placement or radius, stratigraphy, material assignments, boundary element definitions, etc., etc. - note that many of these features are now directly integrated in iTOUGH2 without the need for PEST). The mesh topology can then be used as the subject of an inversion, sensitivity or uncertainty propagation analysis. After the mesh is re-generated according to the parameter changes provided by iTOUGH2, the actual simulation is run and the system state of interest is extracted from both the TPMS and TOUGH2 to update the parameter set (or perform "further analyses").

    (B) The “TPMS” can also be called after a TOUGH2 simulation to post-process the simulation results. For example, the TPMS could be an economic model that calculates remediation costs based on the required pumping rates, contaminant concentrations, etc. iTOUGH2 can then be used to minimize these costs or develop a Pareto front within a multi-objective optimization framework. 

    (C) Obviously, the following equation also holds: iTOUGH2-PEST(TPMS) for TPMS=TOUGH(i), i=2, 3, 4, +, MP, REACT, FLAC3D, ...). See, for example, TPMS=TOUGH-FLAC (Rinaldi et al., 2017).

    The official iTOUGH2 distribution includes iTOUGH2-PEST, the manual as well as the related sample problems. Simplified versions of these concepts are described in some of the references provided below. I presented iTOUGH2-PEST at the TOUGH Symposium 2012 (my presentation is attached in ppsx format).

    I hope this is useful.

    See you at the TOUGH Symposium 2026!

    Stefan

     

    References:

    Banta, E.R., M.C. Hill, E. Poeter, J.E. Doherty, and J. Babendreier, Building model analysis applications with the Joint Universal Parameter IdenTification and Evaluation of Reliability (JUPITER) API, Computers and Geosciences, 34, 310–319, 2008.

    Doherty, J., PEST: Model-Independent Parameter Estimation, Watermark Numerical Computing, Brisbane, Australia, 2008.

    Finsterle, S., iTOUGH2 Universal Optimization Using the PEST Protocol — User's Guide, Report LBNL-3698E, Lawrence Berkeley National Laboratory, Berkeley, Calif., July 2010.

    Finsterle, S., and Y. Zhang, Solving iTOUGH2 simulation and optimization problems using the PEST protocol, Environmental Modelling and Software, 26, 959–968, doi:10.1016/j.envsoft.2011.02.008, 2011.

    Rinaldi, A.P., J. Rutqvist, S. Finsterle, and H.-H. Liu, Inverse modeling of ground surface uplift and pressure with iTOUGH-PEST and TOUGH-FLAC: The case of CO2 Injection at In Salah, Algeria, Computers and Geosciences, 108, 98–109, doi:10.1016/j.cageo.2016.10.009, 2017.

    • Ludovic_Ricard
    • yesterday
    • Reported - view

    Evening Stefan,

    Thank you very much for the prompt reply and detailed explanation.

    I knew something was possible but failed to find any information (and obviously didn't look hard enough :-( ). 

    This is very helpful and will get me started a long way!

    See you soon Stefan!

     

    Best

    Ludo

Content aside

  • yesterdayLast active
  • 2Replies
  • 4Views
  • 2 Following