TOUGH4 User Manual
  • Quick Entry to Keywords for Data Input
  • 1️⃣INTRODUCTION
    • About TOUGH
    • TOUGH Development History
    • TOUGH4 Implementation
    • Scope and Methodology
  • 2️⃣WHAT IS NEW IN TOUGH4
  • 3️⃣CODE COMPILATION AND INSTALLATION
    • Setup for Compilation
    • Code Compilation
      • 1. Compilation of TOUGH4 using Visual Studio
      • 2. Compilation of TOUGH4 on Linux-like platform
    • Installation
    • Running the Executable for Simulations
  • 4️⃣GOVERNING EQUATIONS
    • Mass-Balance Equation
    • Accumulation Terms
    • Flux Terms
    • Sink and Source Terms
    • Virtual Node Well Treatment
    • Semi-Analytical Conductive Heat Exchange
    • Drift Model
    • Non-Darcy Flow
  • 5️⃣NUMERICAL METHOD
    • Space and Time Discretization
    • Interface Weighting Schemes
    • Initial and Boundary Conditions
      • Initial Conditions and Restarting
      • Neumann Boundary Conditions
      • Dirichlet Boundary Conditions
      • Atmospheric Boundary Conditions
      • Constant Temperature Boundary Conditions
    • Parallel computing schemes
    • Linear Solvers
    • Python Functions
      • Relative Permeability
      • Capillary Pressure
      • Initial Condition Calculation
      • Fetching Output Data
      • Fetching Thermophysical Property Data From NIST Webbook
      • Coupling With Third-Party Software
  • 6️⃣SOFTWARE ARCHITECTURE
    • Program Design
    • Data Structure
    • Linear Equation Setup
  • 7️⃣PROCESS MODELING
    • EOS1
    • EOS2
    • EOS3
    • EOS4
    • EOS6
    • EOS7
    • EOS9
    • ECO2
    • EWASG
    • TMVOC
    • Tracers/Decay Chain
    • Biodegradation Reaction
    • Wellbore Flow
    • Non-Darcy Flow
    • Enhanced Coal Bed Methane
  • 8️⃣PREPARATION OF MODEL INPUT
    • Input Formatting
    • Keywords and Input Data
      • TITLE
      • BIODG
      • CBMDA
      • CHEMP
      • COFT
      • CONNE
      • COUPL
      • DIFFU
      • ELEME
      • ENDCY
      • ENDFI
      • FLAC
      • FNIST
      • FOFT
      • FORCH
      • GASES
      • GENER
      • GOFT
      • HYSTE
      • INCON
      • INDOM
      • MESHM
      • MODDE
      • MOMOP
      • MULTI
      • OUTPU
      • PARAM
      • ROCKS
      • ROFT
      • RPCAP
      • SELEC
      • SOLVR
      • SPAVA
      • TIMBC
      • TIMES
      • TRACR
      • WELLB
    • Inputs for Initial Conditions
      • EOS1
      • EOS2
      • EOS3
      • EOS4
      • EOS6
      • EOS7
      • EOS9
      • ECO2
      • EWASG
      • TMVOC
    • Geometry Data
      • General Concepts
      • MESHMaker
      • Multiple-continuum processing
    • Inputs for MESHMaker
      • Generation of radially symmetric grids
        • RADII
        • EQUID
        • LOGAR
        • LAYER
      • Generation of rectilinear grids
      • MINC processing for fractured media
    • Adjustment of Computing Parameters at Run-time
  • 9️⃣OUTPUTS
  • 🔟VALIDATION AND APPLICATION EXAMPLES
    • EOS1
      • Problem 1 - Code Demonstration
      • Problem 2 - Heat Sweep in a Vertical Fracture (rvf)
      • Problem 3 - Five-spot Geothermal Production/Injection (rfp)
      • Problem 4 - Coupled Wellbore Flow (r1q)
      • Problem 5 - Five-Spot Geothermal Production/Injection under extremely high temperature
    • EOS2
      • Problem 1 -Five-spot Geothermal Production/Injection (rfp)
    • EOS3
      • Problem 1 - Code Demonstration (eos3p1)
      • Problem 2 - 1D TH Problem with Heating and Gas Source (by Guanlong Guo)
      • Problem 3 - Heat Pipe in Cylindrical Geometry (rhp)
      • Problem 4 - 3D Thermal Consolidation Test, Coupling with FLAC3D Simulator (by Guanlong Guo)
    • EOS4
      • Problem 1 - Code Demonstration (eos4p1)
      • Problem 2 - Heat Pipe in Cylindrical Geometry (rhp)
    • EOS6
      • Problem 1-Validation with EOS2
      • Problem 2-Noble Gas Transport
    • EOS7
      • Problem 1-Multiphase and Nonisothermal Processes in a System with Variable Salinity (rf1)
      • Problem 2-Thermal and Tracer Diffusion (EOS7R/rdif7)
      • Problem 3-Contamination of an Aquifer from VOC Vapors in the Vadose Zone (EOS7R/rdica)
      • Problem 4-Density, Viscosity, Solubility, and Enthalpy of Real Gas Mixtures (EOS7C/SAM7C1)
      • Problem 5-CO2 Injection into a Depleted Gas Reservoir (EOS7C2/SAM7C2)
      • Problem 6- CO2 Injection into a Saturated System (EOS7C/SAM7C3)
      • Problem 7-Density, Viscosity, and Enthalpy of Real Gas Mixtures (EOS7CA/SAM7CA1)
      • Problem 8-CO2 Injection into a Shallow Vadose Zone (EOS7CA/SAM7CA2)
      • Problem 9-Non-Isothermal Compressed Air Energy Storage in Reservoir (by Julien Mouli-Castillo)
    • EOS9
      • Page 1
    • ECO2
      • Problem 1-Demonstration of Initialization Options (ECO2N/rtab)
      • Problem 2-Radial Flow from a CO2 Injection Well (ECO2N/rcc3)
      • Problem 3-CO2 Discharge Along a Fault Zone (ECO2N/r1dv)
      • Problem 4-CO2 Injection into a 2-D Layered Brine Formation (ECO2N/rtp7)
      • Problem 5-Upflow of CO2 along a Deep Fault Zone (ECO2M/r1d)
      • Problem 6-Migration of a CO2 Plume in a Sloping Aquifer, Intersected by a Fault (ECO2M/rwaf)
      • Problem 7-GCS/GHE with a double-porosity reservoir (Case6_50kg_DP/ECO2NV2)
    • EWASG
      • Problem 1 - Brine Density Calculation (dnh)
      • Problem 2 - Production from a Geothermal Reservoir with Hypersaline Brine and CO2 (rhbc)
    • TMVOC
      • Problem 1-Initialization of Different Phase Conditions (r7c)
      • Problem 2-1-D Buckley-Leverett Flow (rblm)
      • Problem 3-Diffusion of components (rdif2)
      • Problem 4-Steam Displacement of a NAPL in a Laboratory Column (rtcem)
      • Problem 5-Steam Displacement of a Benzene-Toluene Mixture in a Laboratory Column (rbt)
      • Problem 6 -Air Displacement of a NAPL from a Laboratory Column (rad)
      • Problem 7-NAPL Spill in the Unsaturated Zone (r2dl)
    • T4.Well
      • Problem 1-Steady-state two-phase flow upward
      • Problem 2-Non-isothermal CO2 flow through a wellbore initially full of water
  • CONCLUSION REMARKS
  • REFERENCES
  • ACKNOWLEDGEMENT
  • Appendix
    • ☑️A: RELATIVE PERMEABILITY FUNCTIONS
      • IRP=1 Linear function
      • IRP=2 Power function
      • IRP=3 Corey's curves
      • IRP=4 Grant's curve
      • IRP=5 Perfectly mobile
      • IRP=6 Fatt and Klikoff function
      • IRP=7 van Genuchten-Mualem Model
      • IRP=8 Verma function
      • IRP=10 Modified Brooks-Corey Model
      • IRP=11 Modified van Genuchten Model
      • IRP=12 Regular hysteresis
      • IRP=13 Simple hysteresis
      • IRP=31 Three phase perfectly mobile
      • IRP=32 Modified Stone's first 3-phase method
      • IRP=33 Three-phase Parker's function
      • IRP=34 Alternative Stone 3-phase
      • IRP=35 Power-law function
      • IRP=36 Faust for two-phase Buckley-Leverett problem
      • IRP=37 Another alternative to Stone function
      • IRP=40 Table lookup
      • IRP=41 User-Defined relative permeability function
    • ☑️B: CAPILLARY PRESSURE FUNCTIONS
      • ICP=1 Linear function
      • ICP=2 Function of Pickens
      • ICP=3 TRUST capillary pressure
      • ICP=4 Milly’s function
      • ICP=6 Leverett’s function
      • ICP=7 van Genuchten function
      • ICP=8 No capillary pressure
      • ICP=10 Modified Brooks-Corey Model
      • ICP=11 Modified van Genuchten Model
      • ICP=12 Regular hysteresis
      • ICP=13 Simple hysteresis
      • ICP=31 Parker et al 3-phase function
      • ICP=32 Parker 3-phase function, alternative 1
      • ICP=33 Parker 3-phase function, alternative 2
      • ICP=34 Parker 3-phase function, alternative 3
      • ICP=40 Table lookup
      • ICP=41 User-Defined capillary pressure function
    • ☑️C: ADDITIONAL PROGRAM OPTIONS
    • ☑️D: DESCRIPTION OF FRACTURED FLOW
      • Multiple Continuum Approaches
      • Active Fracture Modle
Powered by GitBook
On this page
  1. GOVERNING EQUATIONS

Flux Terms

Advective mass flux is a sum of phase fluxes,

 Fκ∣adv=∑βXβκFβ\left.\ \mathbf{F}^\kappa\right|_{adv}=\sum_{\beta}{X_\beta^\kappa\mathbf{F}_\beta} Fκ∣adv​=∑β​Xβκ​Fβ​ (4-4)

where individual phase fluxes are given by a multiphase version of Darcy's law:

Fβ=ρβuβ=−   k  krβρβμβ  (∇ Pβ−  ρβg)\mathbf{F}_\beta\quad=\quad\rho_\beta\mathbf{u}_\beta\quad=\quad-\;\ k\;\frac{k_{r\beta}\rho_\beta}{\mu_\beta}\;(\nabla\ P_\beta-\;\rho_\beta g)Fβ​=ρβ​uβ​=− kμβ​krβ​ρβ​​(∇ Pβ​−ρβ​g) (4-5)

where, uβu_\betauβ​ is the Darcy velocity (volume flux) of phase β\betaβ, k is absolute permeability, krβk_{r\beta}krβ​ is relative permeability to phase β\betaβ, μβ\mu_\betaμβ​ is the phase dynamic viscosity, and

Pβ= P+ PcβP_\beta=\ P+\ P_{c\beta}Pβ​= P+ Pcβ​

is the fluid pressure in phase β\betaβ, which is the sum of the pressure P of a reference phase (usually taken to be the gas phase) and the capillary pressure Pcβ(≤0)P_{c\beta}(\le0)Pcβ​(≤0). g is the vector of gravitational acceleration. Vapor pressure lowering due to capillary and phase adsorption effects can be considered, and is modeled by Kelvin’s equation (Edlefsen and Anderson, 1943),

Pv(T,Sl)= fVPL(T,Sl)⋅ Psat(T)P_v\left(T,S_l\right)=\ f_{VPL}\left(T,S_l\right)\cdot\ P_{sat}\left(T\right)Pv​(T,Sl​)= fVPL​(T,Sl​)⋅ Psat​(T) (4-6)

where

fVPL= exp[Mw  Pcl(Sl)ρlR(T+273.15)]f_{VPL}=\ ex p{\left[\frac{M_w\; P_{cl}\left(S_l\right)}{\rho_lR\left(T+273.15\right)}\right]}fVPL​= exp[ρl​R(T+273.15)Mw​Pcl​(Sl​)​] (4-7)

is the vapor pressure lowering factor. PvP_vPv​is the vapor pressure, PsatP_{sat}Psat​is the saturated vapor pressure of bulk aqueous phase, PclP_{cl}Pcl​is the capillary pressure (i.e., the difference between aqueous and gas phase pressures), MwM_wMw​ is the molecular weight of water, and R is the universal gas constant.

Absolute permeability of the gas phase increases at low pressures according to the relation given by Klinkenberg (1941)

k= k∞(1  +  bP)k=\ k_\infty\left(1\;+\;\frac{b}{P}\right)k= k∞​(1+Pb​) (4-8)

where k∞k_∞k∞​is the permeability at “infinite” pressure, and b is the Klinkenberg parameter.

In addition to Darcy flow, mass transport can also occur by diffusion. Diffusive flux is modeled as follows:

fβκ=−φτ0τβρβdβκ∇ Xβκ\mathbf{f}_\beta^\kappa=-\varphi\tau_0\tau_\beta\rho_\beta d_\beta^\kappa\nabla\ X_\beta^\kappafβκ​=−φτ0​τβ​ρβ​dβκ​∇ Xβκ​ (4-9)

where dβκd_\beta^\kappadβκ​ is the molecular diffusion coefficient for component k in phase β\betaβ, and τ0τβ\tau_0 \tau_\betaτ0​τβ​ is the tortuosity, which includes a porous medium dependent factor τ0\tau_0τ0​ and a coefficient that depends on phase saturation SβS_\betaSβ​ , τβ=τβ(Sβ)\tau_\beta=\tau_\beta(S_\beta)τβ​=τβ​(Sβ​). For general two-phase conditions, the total diffusive flux is then given by

fκ=−Σlκ∇ Xlκ  −  Σgκ∇ Xgκ−  Σoκ∇ Xoκf^\kappa \quad=\quad-\Sigma_l^\kappa\nabla\ X_l^\kappa\;-\;\Sigma_g^\kappa\nabla\ X_g^\kappa-\;\Sigma_o^\kappa\nabla\ X_o^\kappafκ=−Σlκ​∇ Xlκ​−Σgκ​∇ Xgκ​−Σoκ​∇ Xoκ​ (4-10)

where Σβκ=φτ0τβρβdβκ\Sigma_\beta^\kappa=\varphi\tau_0\tau_\beta\rho_\beta d_\beta^\kappaΣβκ​=φτ0​τβ​ρβ​dβκ​ is an effective diffusion coefficient in phase β\betaβ. We have used this pragmatic approach because it is not possible to formulate a model for multiphase diffusion that would be accurate under all circumstances. The basic Fick law works well for diffusion of tracer solutes that are present at low concentrations in a single-phase aqueous solution at rest with respect to the porous medium [1]^{[1]}[1].

Several models are available to describe the dependence of tortuosity on porous medium properties and phase saturation. For the relative permeability model, tortuosity will be taken as τ0τβ(Sβ)=τ0krβ(Sβ)\tau_0 \tau_\beta(S_\beta)=\tau_0k_{r\beta}(S_\beta)τ0​τβ​(Sβ​)=τ0​krβ​(Sβ​)with the user-specified porous medium dependent factor τ0\tau_0τ0​. The Millington and Quirk (1961) model, which has frequently been used for soils (Jury et al., 1983; Falta et al., 1989), yields non-zero tortuosity coefficients as long as phase saturation is non-zero [2]^{[2]}[2].

τ0τβ=φ13  Sβ103\tau_0\tau_\beta=\varphi^\frac{1}{3}\;{S_\beta}^\frac{10}{3}τ0​τβ​=φ31​Sβ​310​ (4-11) For the constant diffusivity formulation, τ0τβ=Sβ\tau_0 \tau_\beta=S_\betaτ0​τβ​=Sβ​ will be used. This alternative corresponds to the formulation for gas diffusion in the original version of TOUGH2. In the absence of phase partitioning and adsorptive effects, it amounts to effective diffusivity being approximately equal to dβκd_\beta^\kappadβκ​, independent of saturation. This can be seen by noting that the accumulation term in the phase β\betaβcontribution to the mass balance equation for component k is given by φ SβρβXβκ\varphi\ S_\beta\rho_\beta X_\beta^\kappaφ Sβ​ρβ​Xβκ​, approximately canceling out the φ Sβρβ\varphi\ S_\beta\rho_\betaφ Sβ​ρβ​ coefficient in the diffusive flux.

TOUGH4 can model the pressure and temperature dependence of gas phase diffusion coefficients by the following equation (Vargaftik, 1975; Walker et al., 1981).

dgκ(P,T)= dgκ(P0,T0)  P0P  [T+273.15273.15]θd_g^\kappa(P,T)=\ d_g^\kappa(P_0,T_0)\;\frac{P_0}{P}\;\left[\frac{T+273.15}{273.15}\right]^\thetadgκ​(P,T)= dgκ​(P0​,T0​)PP0​​[273.15T+273.15​]θ (4-12)

At standard conditions of P0P_0P0​ = 1 atm = 1.01325 bar and T0T_0T0​ = 0˚C, the diffusion coefficient for vapor-air mixtures has a value of 2.13×10−5m2/s2.13 \times10 ^{-5}m^2/s2.13×10−5m2/s; parameter θ\thetaθfor the temperature dependence is 1.80. Presently there are no provisions for inputting different values for the parameter θ\thetaθ of temperature dependence for different gas phase components. Diffusion coefficients for the non-gaseous phases are taken as constants, with no provisions for temperature dependence of these parameters.

Heat flux includes conductive, convective, and radiative components:

Fh=−λ∇ T  +  ∑βhβFβ+fσσ0∇ T4\mathbf{F}^h=-\lambda\nabla\ T\;+\;\sum_{\beta}{h_\beta\mathbf{F}_\beta}+f_\sigma\sigma_0\nabla\ T^4Fh=−λ∇ T+∑β​hβ​Fβ​+fσ​σ0​∇ T4 (4-13)

where λ\lambdaλ is the effective thermal conductivity, and hβh_\betahβ​ is the specific enthalpy in phase β\betaβ, fσf_\sigmafσ​is the radiant emittance factor, and σ0\sigma_0σ0​ is the Stefan-Boltzmann constant.


[1] Many subtleties and complications can arise when multiple components diffuse in a multiphase flow system. Effective diffusivities in general may depend on all concentration variables, leading to nonlinear behavior especially when some components are present in significant (non-tracer) concentrations. Additional nonlinear effects arise from the dependence of tortuosity on phase saturations, and from coupling between advective and diffusive transport. For gases, the Fickian model has serious limitations even at low concentrations, which prompted the development of the “dusty gas” model that entails a strong coupling between advective and diffusive transport (Mason and Malinauskas, 1983; Webb, 1998) and accounts for molecular streaming effects (Knudsen diffusion) that become very important when the mean free path of gas molecules is comparable to pore sizes. Further complications arise for components that are both soluble and volatile, in which case diffusion in aqueous and gaseous phases may be strongly coupled via phase partitioning effects. An extreme case is the well-known enhancement of vapor diffusion in partially saturated media, which is attributed to pore-level phase change effects (Cass et al., 1984; Webb and Ho, 1998a, b). These alternative models are not implemented in TOUGH4.

[2] It stands to reason that diffusive flux should vanish when a phase becomes discontinuous at low saturations, suggesting that saturation-dependent tortuosity should be related to relative permeability, i.e., τβ(Sβ)≈krβ(Sβ)\tau_\beta(S_\beta) \approx k_{r\beta}(S_\beta)τβ​(Sβ​)≈krβ​(Sβ​). However, for components that partition between liquid and gas phases, a more complex behavior may be expected. For example, consider the case of a volatile and water-soluble compound diffusing under conditions of low gas saturation where the gas phase is discontinuous. In this case we have krg(Sg)=0k_{rg}(S_g)=0krg​(Sg​)=0 (because Sg<SgrS_g \lt S_{gr}Sg​<Sgr​), and krl(Sl=1−Sg)<1k_{rl}(S_l=1-S_g) \lt 1krl​(Sl​=1−Sg​)<1, so that a model equating saturation-dependent tortuosity to relative permeability would predict weaker diffusion than in single-phase liquid conditions. For compounds with “significant” volatility this would be unrealistic, as diffusion through isolated gas pockets would tend to enhance overall diffusion relative to single-phase liquid conditions.

PreviousAccumulation TermsNextSink and Source Terms

Last updated 10 months ago

4️⃣