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

Semi-Analytical Conductive Heat Exchange

TOUGH4 provides options for modeling linear or radial conductive heat exchange with geologic formations where no fluid exchange is considered, using semi-analytical methods. This is a much more efficient alternative to the approach that simply extends the computational grid into those formations and assigns small or vanishing permeability to them. Even to achieve modest accuracy, the number of grid blocks in the heat flow domain could easily become comparable to, or even larger than, the number of grid blocks in the fluid flow domain, leading to a very inefficient calculation. The semi-analytical methods require no grid blocks outside of the fluid flow domain, and permit better accuracy for short- and long-term heat exchange. Note that radial and linear semi-analytical heat exchange cannot be combined in the current version of TOUGH4.

Linear Heat Exchange between a Reservoir and Confining Beds

TOUGH4 uses the method of Vinsome and Westerveld (1980), which gives excellent accuracy for heat exchange between reservoir fluids and confining beds such as may arise in geothermal injection and production operations. This method is developed for calculating heat losses from the reservoir to caprock or base rock and predicting the temperature profile in a semi-infinite, homogeneous, conductive half-space confining bed. Observing that the process of heat conduction tends to dampen out temperature variations, Vinsome and Westerveld suggested that caprock or base rock temperatures would vary smoothly even for strong and rapid temperature changes at the boundary of the conduction zone. Arguing that heat conduction perpendicular to the conductive boundary is more important than parallel to it, they proposed to represent the temperature profile in a semi-infinite conductive layer by means of a simple trial function, as follows:

T(x,t)−Ti=(Tf−Ti+px+qx2)exp⁡(−x/d)T(x,t)-T_i=(T_f-T_i+px+qx^2 ) exp⁡(-x/d)T(x,t)−Ti​=(Tf​−Ti​+px+qx2)exp⁡(−x/d) (4-31)

where, x is the distance from the boundary, TiT_iTi​ is initial temperature in the cap- or base-rock (assumed uniform), TfT_fTf​is the time-varying temperature at the cap- or base-rock boundary, p and q are time-varying fit parameters, and d is the penetration depth for heat conduction, given by d=Θt∕2d=\sqrt{Θt}∕2d=Θt​∕2 (4-32)

where Θ=λ/ρCΘ=\lambda/\rho CΘ=λ/ρC is the thermal diffusivity, λ\lambda λthe thermal conductivity, ρ\rhoρ the density of the medium, and C the specific heat. In the context of a finite-difference simulation of nonisothermal flow, each grid block in the top and bottom layers of the computational grid will have an associated temperature profile in the adjacent impermeable rock as given by Eq. (4-31). The coefficients p and q will be different for each grid block; they are determined concurrently with the flow simulation from the physical constraints of (1) continuity of heat flux across the boundary, and (2) energy conservation for the reservoir/confining layer system.

Radial Heat Exchange between Fluids in a Wellbore and the Surrounding Formation

Radial, conductive heat exchange between fluids in a discretized wellbore and the formation is calculated using a semi-analytical, time-convolution method. Note that the time-dependent temperature evolution in the fully-discretized wellbore is calculated numerically. At each time step, radial heat transfer with the formation is calculated by superposition of analytical solutions of heat flow that are dependent on the temperature differences between subsequent time steps.

Carslaw and Jaeger (1959) provided an approximate solution for heat conduction between a cylinder and surrounding media where the temperature of the cylinder is maintained constant. If the initial temperature difference between the two domains is ∆T = Tw - Tf (where Tw and Tf are the temperatures in the well and the formation, respectively), the heat flux q from the wellbore to the formation can be calculated as the product of a heat transfer function and the temperature using Eq. (4-33) for small values of the dimensionless time td=αt/r02t_d=\alpha t/r_0^2td​=αt/r02​ , where α is the thermal diffusivity and r0r_0r0​ is the wellbore radius (m), and Eq. (4-34) for large values of tdt_dtd​:

q=f1(td)⋅ΔT=λΔT/r0[(πtd)−0.5+1/2−1/4(td/π)0.5+1/8td−…]q=f_1 (t_d)⋅ΔT=λΔT/r_0 [(πt_d )^{-0.5}+1/2-1/4(t_d/π )^{0.5}+1/8 t_d-…]q=f1​(td​)⋅ΔT=λΔT/r0​[(πtd​)−0.5+1/2−1/4(td​/π)0.5+1/8td​−…] (4-33)

q=f2(td)⋅ΔT=2λΔT/r0[1/(ln⁡(4td)−2γ)−γ/((ln⁡(4td)−2γ)2)−…]q=f_2 (t_d)⋅ΔT=2λΔT/r_0 [1/(ln⁡( 4t_d)-2γ)-γ/((ln⁡( 4t_d)-2γ)^2 )-…]q=f2​(td​)⋅ΔT=2λΔT/r0​[1/(ln⁡(4td​)−2γ)−γ/((ln⁡(4td​)−2γ)2)−…] (4-34)

where, λ is thermal conductivity (Wm−1K−1)(Wm^{-1}K^{-1})(Wm−1K−1), and γ is the Euler constant (0.57722). The heat transfer functions f1 and f2 express the amount of heat flux with time due a unit temperature difference. As shown in Zhang et al. (2011), the heat transfer functions f1 and f2 are approximately the same at the dimensionless time td=2.8t_d=2.8td​=2.8. Therefore, td=2.8t_d=2.8td​=2.8 is considered the critical dimensionless time to switch from f1 to f2.

During fluid injection and production, and as a result of the heat exchange processes, temperature changes continuously over time at any point within the wellbore and at the wellbore-formation interface. Based on superposition, the radial heat flux across each wellbore element to the surrounding formation is a time-convolution result of varying temperature. The discretized form at each time step can be expressed as

qtotal=∑i=1d−1f(td−ti)ΔT(ti)q_{total}=\displaystyle\sum_{i=1}^{d-1}f(t_d-t_i) \Delta T(t_i)qtotal​=i=1∑d−1​f(td​−ti​)ΔT(ti​) (4-35)

where, tdt_dtd​ represents the current time after d time steps, and tit_iti​ represents the time after i time steps; the function f is f1 if td−ti≤2.8t_d-t_i \le2.8td​−ti​≤2.8 , and f2 if td=ti>2.8t_d=t_i>2.8td​=ti​>2.8 . The temperature difference ΔT(ti)\Delta T(t_i)ΔT(ti​) is the temperature in the well at time step i, minus the formation temperature at the interface at the previous time step, i.e., ΔT(ti)=Tw(ti)−Tf(ti−1)\Delta T(t_i)=T_w(t_i)-T_f(t_i-1)ΔT(ti​)=Tw​(ti​)−Tf​(ti​−1).

PreviousVirtual Node Well TreatmentNextDrift Model
4️⃣