TOUGH2 Example: Initial State and Production Analyses in a

403 Poyntz Avenue, Suite B
Manhattan, KS 66502
USA
+1.785.770.8511
www.thunderheadeng.com
TOUGH2 Example:
Initial State and Production Analyses in
a Layered Model
PetraSim 5
Table of Contents
Acknowledgements............................................................................................................................ v
1. Initial State and Production Analysis in a Layered Model with a Surface Contour ...........................2
Create a New Model ................................................................................................................................. 2
Edit Materials ............................................................................................................................................ 2
Define Top Contour................................................................................................................................... 3
Create Mesh .............................................................................................................................................. 6
Edit Global Properties ............................................................................................................................... 7
Assign Materials to Layers ........................................................................................................................ 7
Initial Conditions ....................................................................................................................................... 8
Surface Boundary Conditions.................................................................................................................... 9
Define Source ............................................................................................................................................ 9
Define Outflow Aquifer ........................................................................................................................... 10
Select Cells for Time History Output ....................................................................................................... 11
Edit Solution Controls ............................................................................................................................. 11
Edit Output Controls ............................................................................................................................... 12
Save and Run........................................................................................................................................... 12
View 3D Results....................................................................................................................................... 12
Production Analysis................................................................................................................................. 14
Read Initial Conditions ............................................................................................................................ 14
Define Injection and Production Wells ................................................................................................... 14
Edit Solution Controls ............................................................................................................................. 16
Save and Run........................................................................................................................................... 16
View 3D Results....................................................................................................................................... 16
View Well Time History Plots .................................................................................................................. 18
References....................................................................................................................................... 19
iii
Disclaimer
Thunderhead Engineering makes no warranty, expressed or implied, to users of PetraSim, and accepts
no responsibility for its use. Users of PetraSim assume sole responsibility under Federal law for
determining the appropriateness of its use in any particular application; for any conclusions drawn from
the results of its use; and for any actions taken or not taken as a result of analyses performed using
these tools.
Users are warned that PetraSim is intended for use only by those competent in the field of multi-phase,
multi-component fluid flow in porous and fractured media. PetraSim is intended only to supplement the
informed judgment of the qualified user. The software package is a computer model that may or may
not have predictive capability when applied to a specific set of factual circumstances. Lack of accurate
predictions by the model could lead to erroneous conclusions. All results should be evaluated by an
informed user.
Throughout this document, the mention of computer hardware or commercial software does not
constitute endorsement by Thunderhead Engineering, nor does it indicate that the products are
necessarily those best suited for the intended purpose.
iv
Acknowledgements
We thank Karsten Pruess, Tianfu Xu, George Moridis, Michael Kowalsky, Curt Oldenburg, and Stefan
Finsterle in the Earth Sciences Division of Lawrence Berkeley National Laboratory for their gracious
responses to our many questions. We also thank Ron Falta at Clemson University and Alfredo Battistelli
at Aquater S.p.A., Italy, for their help with T2VOC and TMVOC. Without TOUGH2, T2VOC, TOUGHREACT,
and TOUGH-Fx/HYDRATE, PetraSim would not exist.
In preparing this manual, we have liberally used descriptions from the user manuals for the TOUGH
family of codes. Links to download the TOUGH manuals are given at http://www.petrasim.com. More
information about the TOUGH family of codes can be found at: http://www-esd.lbl.gov/TOUGH2/.
Printed copies of the user manuals may be obtained from Karsten Pruess at <[email protected]>.
The original development of PetraSim was funded by a Small Business Innovative Research grant from
the U.S. Department of Energy. Additional funding was provided by a private consortium for the
TOUGHREACT version and by the U.S. Department of Energy NETL for the TOUGH-Fx/HYDRATE version.
We most sincerely thank our users for their feedback and support.
v
1. Initial State and Production Analyses in a Layered
Model with a Surface Contour
This example demonstrates a basic reservoir analysis, including an initial state calculation and then a
production analysis. The example also demonstrates the use of contours to define the model surface, so
that the surface represents a varying topography. Surface boundary conditions are also specified.
Create a New Model
This example will use EOS1, the equation of state module that models multi-phase water and tracer.
The dimensions of the model will be 2000x1000x1700 meters. This information can be entered using
the New dialog.
To create the model:
1.
2.
3.
4.
5.
6.
7.
8.
9.
10.
On the File menu, click New
In the Simulator Mode list, select TOUGH2
In the Equation of State (EOS) list, select EOS1
In the X Min box, type -1000
In the X Max box, type 1000
In the Y Min box, type 0
In the Y Max box, type 1000
In the Z Min box, type -1500
In the Z Max box, type 200
Click OK to close the dialog and create the model
Edit Materials
It is often easiest to define all the materials first. This simulation will use three materials. To specify
properties for the first material:
1.
2.
3.
4.
5.
6.
On the Properties menu, click Edit Materials...
In the Name box, type POMED
In the Density box, type 2650.0
In the Porosity box, type 0.01
In all three Permeability boxes (X, Y, and Z), type 6e-15
In the Wet Heat Conductivity box, type 2.1
For this simulation we will use the default linear functions for relative permeability and not include any
capillary pressure. These are found by selecting Additional Material Data... .
We will now create a new cap rock material, based on POMED.
1. In the Material Data dialog, click New
2. In the Name box, type CAPRK
2
3. By default, the new material data will be based on the POMED data
4. Click OK to create the new material
5. For the CAPRK material, change the values in the three Permeability boxes (X, Y, and Z) to 6e-16.
Finally, we will create one material to be used to represent an aquifer boundary condition.
1.
2.
3.
4.
In the Material Data dialog, click New
In the Name box, type AQUIF
By default, the new material data will be based on the POMED data
Click OK to create the new material
a. For the AQUIF material, in the Wet Heat Conductivity box, type 0.0. This material will
not conduct heat.
Click OK to save changes and exit the Edit Materials dialog.
Define Top Contour
Before creating the mesh we define the top contours of the model. This is done using an XYZ file listed
below.
-1000.
-100.
-300.
-1000.
200.
0.
-400.
-1000.
400.
200.
-200.
-600.
1000.
1000.
1000.
1000.
800.
200.
1000.
600.
200.
0.
1000.
600.
200.
0.
0.
1000.
0.
200.
200.
200.
100.
100.
100.
100.
0.
0.
0.
0.
0.
0.
Figure 1: XYZ Contour File
The contour defined by this file is shown in Figure 2.
3
Figure 2: The top contour is defined by the XYZ file
We can use this contour in two different ways, as shown in Figure 2. We can have the mesh follow the
top contours, Figure 3.b. If we do this, the cells have different sizes in the Z direction. Alternately, we
can define a uniform mesh and use the contour to delete elements above the contour from the mesh.
The first approach has more flexibility to follow geologic layers, but does not strictly conform to the
TOUGH2 requirements for a Voronoi mesh. The second meets the Voronoi requirements, but will
require more elements to follow any geologic layers. We will present results for both approaches.
a. Mesh follows contour
b. Mesh is uniform and cells about contour are
removed from analysis
Figure 3: Two different approaches of using the contour to define the mesh
In the first model, we will use three layers to define the geometry. The surface layer will follow the
contour file and have a base at -200 m. We will then define a cap rock layer from -200 m to -300 m and
the reservoir layer will extend from -300 m to -1500 m. The approximate cell dimensions will be 100 m
in the Z direction.
4
To define the Surface layer geometry:
1.
2.
3.
4.
5.
6.
On the Model menu, click Edit Layers. The Default layer will be selected.
In the Name box, type Surface
In the Material list, select POMED
In the Top list, select From File and then open the top.xyz file
In the Base list select Constant and in the box, type -200
We will subdivide the Surface layer with four cells in the Z direction. However, the top cells will
be used to define boundary conditions, so we want them to be thin. In the Dz options, select
Custom.
7. The Dz table allows us to specify non-uniform grid spacing. This is apportioned by fraction, since
the layer does not have a constant thickness. In the first row of the table, type 0.9 for the
Fraction and 3 for the Cells.
8. In the second row of the table, type 0.1 for the Fraction and 1 for the Cells (Figure 4)
Figure 4: Defining the Surface layer
To define the Cap Rock layer geometry:
1.
2.
3.
4.
5.
6.
7.
8.
In the Edit Layers dialog, click New… (Figure 5).
In the Name box, type Cap Rock
Click OK to create the new layer
Click on the Color box to change the color to a gray
In the Material list, select CAPRK
In the Base list select Constant and in the box, type -300
In the Dz options, select Regular
In the Cells box, type 1
5
Figure 5: Creating the Cap
Rock layer
To define the Reservoir layer:
1.
2.
3.
4.
5.
6.
7.
8.
In the Edit Layers dialog, click New…
In the Name box, type Reservoir
Click OK to create the new layer
Click on the Color box to change the color to a blue
In the Material list, select POMED
In the Base list select Constant and in the box, type -1500
In the Dz options, select Regular
In the Cells box, type 1
The number of mesh divisions in the Z direction is defined for each layer. We can also change the color
of the layers. To do this:
1.
2.
3.
4.
5.
6.
7.
8.
9.
In the Edit Layers dialog, click on the Surface layer in the display list..
In the Cells box, type 4
In the Edit Layers dialog, click on the Cap Rock layer in the display list.
Click on the Color box to change the color to a gray.
In the Cells box, type 1
In the Edit Layers dialog, click on the Reservoir layer in the display list.
Click on the Color box to change the color to a blue.
In the Cells box, type 12
Click OK to close the Edit Layers dialog
Create Mesh
In this model, we also want to specify boundary conditions on the right side (+X), so we want a thin layer
of cells. To do this, we will use custom divisions.
1. On the Model menu, click Create Mesh
2. In the Divisions options, select Custom.
3. Define three rows in the X direction and one row in the Y direction, as shown below. The total
length in the X direction is 2000 m and 1000 m in the Y.
6
Table 1 : Cell divisions
Dir (X, Y)
X
X
X
Y
Cells
19
1
1
10
Cell Size
100.0
90.0
10.0
100.0
4. Click OK to create the mesh
Your model should now look as shown below.
Figure 6: After creating the mesh
Edit Global Properties
Global properties apply to the entire model. In this example, the only item to change is the analysis
name. To set the simulation name:
1. On the Properties menu, click Global Properties
2. In the Name box, type Initial State Analysis
3. Click OK
Assign Materials to Layers
When specifying materials for each cell, PetraSim uses a tiered system that allows cells to inherit values
from the containing region, regions from the containing layer, and layers from the global defaults. In this
example, we will assign materials by layer.
To assign the materials:
7
1.
2.
3.
4.
5.
6.
7.
On the Model menu, click Edit Layers. The Surface layer will be selected.
In the Material list, select POMED
Click on the Cap Rock layer in the list and save the changes to the Surface layer.
In the Material list, select CAPRK
Click on the Reservoir layer in the list and save the changes to the Cap Rock layer.
In the Material list, select POMED
In the Cells box, type 4 (Figure 4)
Initial Conditions
When specifying parameters such as initial conditions, PetraSim uses a tiered system that allows cells to
inherit values from the containing region, regions from the containing layer, and layers from the global
defaults. Once we set the default initial conditions, these values will be used by all cells except those
where we have explicitly set values.
In this example, we will use linear pressure and temperature gradients. At the surface (200 m), the
pressure will be 1E5 Pa (1 bar) and the temperature will be 10 C. At the bottom of the reservoir (-1500
m), the pressure will be the approximate hydraulic head 15E6 Pa and a temperature of 200 C. These
initial conditions have been chosen to approximate our initial solution. As will be illustrated, the default
initial conditions can be over-ridden for individual cells.
To set the global initial conditions:
1.
2.
3.
4.
5.
6.
7.
On the Properties menu, click Initial Conditions...
In the EOS1 list, select Single-Phase (P, T)
In the Pressure options list, select Function.
In the A box, type 1.853E6 and in the D box, type -8765
In the Temperature options list, select Function.
In the A box, type 32.353 and in the D box, type -0.1117
Click OK to save changes and exit the dialog
Figure 7: Initial condition specification
8
Surface Boundary Conditions
We now want to define surface boundary conditions for the model. These will be a pressure of 1E5 Pa (1
bar) and a temperature of 10 C. To set the surface conditions:
1. Zoom in to view the top layer in the model.
2. Select the Select Mesh Layer tool and then click on the top cell layer in the model. This will
select all cells in the top mesh layer (Figure 8).
3. Right-click on the selected cells and click Edit Cells… .
4. For the Type, click Fixed State.
5. Click on the Initial Conditions tab and select Specify Initial Conditions by Cell.
6. In the Pressure box type 1.0E5.
7. In the Temperature box type 10.
8. Click OK.
Figure 8: Select top cell layer
Define Source
We will assume that there is a heat source at the bottom of the reservoir. This will be applied 50 cells in
the bottom mesh layer within the range -650≤X≤-250 and 50≤Y≤950 (Figure 9). We will define a total
flow of 25 kg/s. We could just specify 0.5 kg/s for each cell, but will demonstrate using flux. The total
projected XY area of these cells is 50x10000 m2, for a flux of 0.00005 kg/s-m2.
1. Using the Select Mesh Layer tool, select the bottom mesh layer and right-click to Show Only
Selected Cells.
2. Click Top View on the toolbar.
3. Use the Select Objects tool to select the indicated cells.
4. Right-click the selected cells, and click Edit Cells …
1. Click the Sources/Sinks tab and under Injection, select the Water/Steam check box
2. In the option list select Constant Flux.
3. In the Rate box, type 0.00005
9
4. In the Enthalpy box, type 1.085E6
5. Click Show All Cells and then click OK.
Figure 9: Select these 50 cells in the bottom cell layer
Define Outflow Aquifer
We will define a fixed pressure aquifer on the side of the reservoir. Since we are defining a mass up flow
from the bottom of the reservoir, by setting a fixed pressure on selected cells, this will become the
location of out flow. We will also define the aquifer cells to have the material we previously defined as
AQUIF.
1. Using the Select Mesh Column tool, select all the cells in the thin layer on the right of the model
and right-click to Show Only Selected Cells.
2. Click Side View on the toolbar.
3. Use the Select Objects tool to select the indicated cells within the range 50≤Y≤950 and -450≤Z≤350 (Figure 10).
4. Right-click the selected cells, and click Edit Cells …
6. Under Material, select AQUIF.
7. Under Type, select Fixed State.
8. Click the Initial Conditions tab and select Specify Initial Conditions by Cell
9. In the Pressure box, type 3.5E6. This corresponds to the hydrostatic pressure at 400 m depth.
10. In the Temperature box, type 100
11. Click Show All Cells and then click OK.
10
Figure 10: The aquifer cells
Select Cells for Time History Output
To select cells for time history output, in the Find box on the toolbar, type 50 and then ENTER.
1.
2.
3.
4.
5.
On the Edit menu, click Properties.
In the Cell Name box, type Source
Click the Print Options tab
Click to select both time dependent output check boxes
Click OK to save changes and close the dialog
Repeat for an aquifer cell. In the Find box on the toolbar, type 2414 and then ENTER.
1.
2.
3.
4.
5.
On the Edit menu, click Properties.
In the Cell Name box, type Outflow
Click the Print Options tab
Click to select both time dependent output check boxes
Click OK to save changes and close the dialog
The Source and Outflow cells now appear in the tree at the left under the Named/Print Cells heading.
Any cell that has been selected for time dependent output or explicitly named will appear in this list.
Edit Solution Controls
Parameters relating to the solver and time stepping can be found in the Solution Controls dialog.
Because we use a material with zero conductivity, experience has shown that the solution will converge
more reliably if the stabilized bi-conjugate gradient solver is used.
To specify the simulation end time and solver:
11
1.
2.
3.
4.
5.
6.
On the Analysis menu, click Solution Controls
In the End Time list, click User Defined and type20 000 years
In the Max Num Time Steps box, type 500
Click the Solver tab
Click to select the Stabilized Bi-Conjugate Gradient option
Click OK
Edit Output Controls
By default, the simulation will print output every 100 time steps. For this simulation, we will specify
output every 20 time steps.
To specify the output frequency:
1. On the Analysis menu, click Output Controls
2. In the Print and Plot Every # Steps box, type 20
3. Click OK
Save and Run
The input is complete and you can run the simulation. The simulator will generate numerous output
files (e.g. FOFT, mesh.csv, etc.). Since these files have the same name for every simulation, it is usually a
good idea to create a folder specifically for a particular model.
To save your model:
1.
2.
3.
4.
On the File menu, click Save
Create a folder named Initial
Save the model with the name initial
Click Save
To run the simulation:
1. On the Analysis menu, click Run TOUGH2
You should see a graph showing the increase in time step size as the simulation converges. If there are
any problems, you can view the log. Output that has been identified as errors will appear in red.
The Simulation Complete dialog will notify you when the end time has been reached. Click OK to dismiss
the notification and click Close to exit the Running TOUGH2 dialog.
View 3D Results
To open the 3D Results dialog:
1. On the Results menu, click 3D Results
By default, the display will show isosurfaces corresponding to pressure for the first output step.
12
To show temperature isosurfaces for the last time step:
1. In the Scalar list, click T
2. In the Time(s) list, click the last entry (t = 6.31139E11)
To show scalar data on a slice plane:
1.
2.
3.
4.
5.
6.
7.
8.
9.
Click Slice Planes...
In the Axis list, click Y
In the Coord box, type 500
Click the Scalar checkbox
To add a display of flow vectors, on the second slice plane in the Axis list, click Y
In the Coord box, type 1
Click to remove the Scalar checkbox and then click to select the Vector checkbox
Click Close
In the Vector list, click FLOF
The resulting visualization is shown below. There is fluid down flow from the surface and up flow from
the bottom source.
Figure 11: Temperature contours and flow vectors
When finished, you can close the 3D Results dialog.
13
Production Analysis
We will now use the initial state results to perform a simplified production analysis. If PetraSim is not
already running, restart PetraSim and on the File menu, click Open... and select the initial.sim file. This
file has all the model data for the first segment analysis. We will now save this file to a different name
for the second segment of the analysis. It is recommended that you create a new directory in which to
save this analysis.
To save your model:
1.
2.
3.
4.
On the File menu, click Save As
Create a folder named Production
Save the model with the name production
Click Save
Read Initial Conditions
To load the initial state solution results as initial conditions for the production analysis:
1. On the File menu, click Load Initial Conditions…
2. Go to the Initial folder and select the SAVE file.
3. Click Open. This reads the saved data from the previous run and stores it as an initial condition
for each cell in the current analysis.
To verify that the initial conditions have been correctly loaded, you can select Temperature in the Cell
Color option. This will plot the values on the cells. Any cell that is gray, is not in a state where that
option is valid. For example, some cells will be in two-phase conditions, where the state variables are
pressure and saturation of gas.
Define Injection and Production Wells
In the production run, we will define two production wells and one injection well. The user can select
specific cells and define sources and sinks in those cells. In this example, we will use wells. To define the
injection well:
1. On the Model menu, click Add Well…
2. In the Name box, type Inj
3. In the X, Y, and Z coordinate table, type:
X
250
250
Y
750
750
4. Click OK.
To define the first production well:
1. On the Model menu, click Add Well…
2. In the Name box, type Prod1
14
Z
200
-1300
3. In the X, Y, and Z coordinate table, type:
X
-250
-250
Y
350
350
Z
200
-1300
Y
250
250
Z
200
-1300
4. Click OK.
To define the second production well:
1. On the Model menu, click Add Well…
2. In the Name box, type Prod2
3. In the X, Y, and Z coordinate table, type:
X
550
550
4. Click OK.
This has defined the well geometry. Now we will define the production zones for each well and the flow
rates.
1.
2.
3.
4.
5.
6.
7.
8.
9.
In the tree at the left under the Wells heading, double-click on Inj
Click the Geometry tab
In the Top Completion Depth box, type -1200
Click the Flow tab
Under Injection, click Water/Steam and select Constant.
In the Rate box, type 30
In the Enthalpy box, type 4.19E5
Click the Print Options tab and click to Print Time Dependent Flow and Generation Data.
Click OK.
For the production well:
1.
2.
3.
4.
5.
6.
7.
8.
In the tree at the left under the Wells heading, double-click on Prod1
Click the Geometry tab
In the Top Completion Depth box, type -1200
Click the Flow tab
Under Production, click Mass Out and select Constant.
In the Rate box, type 20
Click the Print Options tab and click to Print Time Dependent Flow and Generation Data.
Click OK.
Repeat the production data for the second production well (Prod2). The wells should look as displayed
below (only third layer of cells is displayed).
15
Figure 12: After defining the wells
Edit Solution Controls
The production analysis will be a new analysis, starting from time 0, but with initial conditions
corresponding to the end of the initial state analysis.
1. On the Analysis menu, click Solution Controls
2. In the End Time list, click User Defined and type40 years
Click OK
Save and Run
The input is complete and you can run the simulation. To run the simulation:
1. On the Analysis menu, click Run TOUGH2
You should see a graph showing the increase in time step size as the simulation converges. If there are
any problems, you can view the log. Output that has been identified as errors will appear in red.
The Simulation Complete dialog will notify you when the end time has been reached. Click OK to dismiss
the notification and click Close to exit the Running TOUGH2 dialog.
View 3D Results
To open the 3D Results dialog:
1. On the Results menu, click 3D Results
By default, the display will show isosurfaces corresponding to pressure for the first output step.
To show temperature isosurfaces and fluid flow vectors for the last time step:
16
1.
2.
3.
4.
In the Time(s) list, click the last entry (t = 1.262E9)
In the Scalar list, click T
In the Vectors list, click FLOF
Click Show Isosurfaces to turn off the checkbox of global isosurface display
To show scalar and vector data on a slice plane:
1.
2.
3.
4.
5.
6.
7.
8.
9.
10.
11.
Click Slice Planes...
In the Axis list, click Y
In the Coord box, type 750
Click the Scalar and Vectors checkboxes.
In the second slice plane Axis list, click Z
In the Coord box, type -1250
Click the Scalar and Vectors checkboxes.
In the third slice plane Axis list, click X
In the Coord box, type 1000
Click the Scalar and Vectors checkboxes.
Click Close
The resulting visualization is shown below. The cooling around the injection well and flow to the
production wells can be seen.
Figure 13: Temperature contours and flow vectors
When finished, you can close the 3D Results dialog.
17
View Well Time History Plots
To view time history plots of the well flow rates:
1. On the PetraSim Results menu, click Well Plots
2. In the Variable list, click Flow Rate
3. In the Well Name list, click Inj
The resulting plot is shown below.
Figure 1.14: Flow rate history of injection well
When finished, you can close the Cell History dialog.
18
References
1. Pruess, Karsten, Oldenburg, Curt and Moridis, George. TOUGH2 User's Guide, Version 2.0. Berkeley,
CA, USA : Earth Sciences Division, Lawrence Berkeley National Laboratory, November 1999. LBNL-43134.
2. Falta, Ronald, et al., et al. T2VOC User's Guide. Berkeley, CA, USA : Earth Sciences Division, Lawrence
Berkeley National Laboratory, March 1995. LBNL-36400.
19