Professional Documents
Culture Documents
Simulation
K.H. Coats, SPE, K.H. Coats and Co. Inc., and L.K. Thomas, SPE, and R.G. Pierson, SPE, Phillips Petroleum Co.
Summary IMPES and fully implicit formulations are coded for both the
This paper describes a three-dimensional (3D), three-phase reser- black oil and compositional cases. The linear solvers include direct
voir simulation model for black oil and compositional applications. D4,7 nested factorization,8, 9 and red/black ILU/Orthomin.10 Well
Both implicit pressure, explicit saturation/concentration (IMPES) rate terms including wellbore crossflow are implicit in both for-
and fully implicit formulations are included. The relaxed volume mulations. The wellbore constraint equations11, 12 are fully implicit
balance concept effectively conserves mass and volume and re- to achieve exact target rates, even in the IMPES case.
duces Newton iterations in both formulations. A new implicit well Platform or gathering center logic allows assignment of target
rate calculation method improves IMPES stability. It approximates rates and constraints to groups of wells. Gas can be reinjected,
wellbore crossflow effects with high efficiency and relative sim- taking into account available produced and outside gas, gas sales,
plicity in both IMPES and fully implicit formulations. Multiphase and fuel loss. Produced gas from one platform can be transferred
flow in the tubing and near-well non-Darcy gas flow effects are for injection on another platform.
treated implicitly. The model handles the case of multiple reservoirs, e.g., stacked
Initial saturations are calculated as a function of water/oil and reservoirs, with no transmissibility communication between any
gas/oil capillary pressures, which are optionally dependent upon the pair of reservoirs and no well completed in more than one reservoir.
Leverett J function. A normalization of the relative permeability This capability can reduce central processing unit (CPU) time by
and capillary pressure curves is used to calculate these terms as a a factor of two or more, because the different reservoirs do not
function of rock type and gridblock residual saturations. require the same number of Newton or linear solver iterations.
Example problems are presented, including several of the SPE Tracer fractions for any number of traced components can be
comparative solution problems and field simulations. calculated. This feature is useful in equity situations as well as
tracking injected gas streams. Traced components can be any of the
Introduction fluid components including water. These calculations increase run
times very little and are optional.
This paper describes a numerical model for simulating 3D, three- Following model description, several example problems are
phase flow in heterogeneous, single-porosity reservoirs. The model presented. They include five SPE Comparative Solution Project
incorporates black oil and fully compositional capabilities formu- problems, a non-Darcy gas flow problem, a crossflow problem, and
lated in both IMPES and fully implicit modes. The formulations two field studies.
include a relaxed volume concept and a new method for implicit
treatment of well rates with wellbore crossflow. The usual viscous, Mathematical Description of the Model
gravity, and capillary forces are represented by Darcy’s law mod-
The model consists of N 5 2Nc 1 4 equations for each active
ified for relative permeability. The flow is isothermal although, as
gridblock and N w well constraint equations for active wells that are
an option, a spatially variable, time-invariant temperature distri-
not on pressure constraint. The N equations include mass balances
bution may be specified in the compositional case.
for Nc hydrocarbon components and water.
Complex reservoir geometries, including pinchouts and non-
neighbor connections across faults, can be simulated with Cartesian V
xyz or corner point geometry grids. Mapping or linear indexing is d# @f~ro So xi 1 rg Sg yi !#
Dt
used to require storage and arithmetic only for active gridblocks.
The black oil option includes the rs stb/scf term as well as the
normal Rs solution gas term. It therefore applies to gas condensate
and black oil problems. Interfacial tension, modifying gas/oil
F
5 D Tro xi
kro
m0
~Dp 2 DPcgo 2 go DZ! G
capillary pressure, is also entered vs. pressure in the black oil
pressure/volume/temperature (PVT) table. The compositional case
uses the Peng Robinson (PR)1 or Soave Redlich Kwong (SRK)2
F
1 D Trg yi
krg
mg G
~Dp 2 gg DZ! 2 qi ,
equation of state (EOS). Shift factors3 are included to account for i 5 1, 2, . . . , Nc . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (1a)
volume translation.4 The compositional case optionally uses tabular
K values vs. p, rather than EOS fugacity-based K values. The table V
d# ~fbw Sw !
is generated internally by an expansion of the original reservoir Dt
F G
fluid. This option applies near-rigorously to cases of natural de-
pletion with or without water injection and/or influx. It is signif- krw
5 D Tbw ~Dp 2 DPcgo 2 DPcwo 2 gw DZ! 2 qw . . . . . (1b)
icantly more efficient than the use of the EOS in the IMPES case. mw
The effect of pore collapse and compaction is incorporated in the
model applying the logic presented by Sulak et al.,5 which has been In addition to these Nc 1 1 equations, there are Nc 1 3 constraint
expanded to include a water weakening effect.6 Hysteresis of rock equations for each gridblock: Nc phase equilibrium constraints, and
compressibility is included in the calculation to account for the the summations to 1.0 of yi, xi, and Sw,So,Sg.
irreversible effect of pore collapse. 3D compaction tables relate It is well known that a black oil PVT table including formation
rock compressibility to porosity, water saturation, and stress. Each volume factors, Rs and rs vs. pressure can be converted to compo-
gridblock is then assigned to one of these tables. If no tables are sitional mode. The converted table gives the saturated oil and gas
entered, then porosity is fb [1 1 cr (p 2 pb)], where fb is entered phase molar densities [moles/reservoir barrel (RB)] and composi-
for each gridblock. tions (mole fractions x1 and y1) as single-valued functions of
pressure. Thus, Eqs. 1 and the constraints apply unchanged to the
black oil case. Only the implicit and IMPES formulations require
Copyright 1998 Society of Petroleum Engineers
description with appropriate comment regarding compositional
This paper (SPE 50990) was revised for publication from paper SPE 29111, first EOS PVT vs. the simpler black oil PVT.
presented at the 1995 SPE Symposium on Reservoir Simulation, 12–15 February.
Original manuscript received for review 15 February 1995. Revised manuscript The model formulation is an alteration of one previously de-
received 20 May 1998. Paper peer approved 3 June 1998. scribed.13 That paper’s linearization renders the model equations
OF G
N
ations. In all problems to date, we have found this concept an
a improvement with results showing near-exact volume balance in
da 5 dP# m . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (3)
m51
P# m addition to exact mass balance. Iterations and CPU time are
somewhat significantly less, and the answers are the same as
compared with the conventional 1.0 volume balance approach.
For a three-phase block, the constraints are a set of Nc 1 3 equations In the IMPES case, the pressure transmissibilities TN c11 are not
in the N variables. Gaussian elimination on them gives an elimi- necessarily constant over the timestep. If more than one Newton
nation matrix E relating the Nc 1 3 eliminated variables to the iteration is performed, they are recalculated to account for possible
Nc 1 1 retained or primary variables P of Eq. 2, changes in flow direction. The IMPES pressure equation is obtained
dPe 5 E dP. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (4) in a straightforward manner,22 applying the obvious extension of
the original black oil IMPES reduction. The ith equation of the Nc 1
The Nc 1 3 variables dPe are eliminated from the linearized form 1 scalar equations comprising Eq. 2 is multiplied by a factor vi, with
of Eq. 1 by means of this matrix E. E is ostensibly an Nc 1 3 x Nc 1 vN c11 5 1, and the resulting Nc 1 1 equations (rows) are added. The
1 matrix. Actually it is an NcxNc 1 1 matrix because of the values of vi are determined so that this addition reduces the
simplicity of the three constraints left-hand side to a single term cdp. Let A be the NcxNc matrix
obtained by deleting row Nc 1 1 and column Nc 6 1 from C. Let
dxN c 5 2dx1 2 dx2 2 . . . 2 dxN c21 . . . . . . . . . . . . . . . . . . . (5a) the Nc-row vector B be the first Nc entries of the last row of C. Then
the IMPES reduction vector v (first Nc entries) is obtained from their
dyN c 5 2dy1 2 dy2 2 . . . 2 dyN c21 . . . . . . . . . . . . . . . . . . . (5b) transposes as
where a is discussed below. The Nc eliminated variables in Pe are The reduction process gives three scalar transmissibilities t that are
y1, y2, . . . ,yN c21 , x1. E is formed at the beginning of each Newton simply the dot or scalar products v z TN c11 . A fourth dot product vzR
iteration for each three-phase block and stored. The eliminated gives the scalar residual r and the IMPES pressure equation
variables are then calculated from Eqs. 4 and 5 after P is available
from the linear solver’s solution of Eq. 2. cdp 5 D~tDdp! 1 r. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (7)
For a three-phase block, the resulting set of Nc 1 1 primary
variables is x2, x3, . . . , xN c21 , So, Sg, p. The primary variables are Because vN c11 5 1, the dot products require only Nc multiplies. This
x1, x2, . . . , xN c21 , So, p for a water/oil block and y1, y2, . . . , yN c21 , reduction process gives a left-hand pressure coefficient c, which
Sg, p for a gas/water block. reflects effects of changes in phase saturations, densities, and
The units of each term in Eq. 2 are moles/d (STB/D for the last, compositions.
water equation). For an all-water block, C is a diagonal matrix. For Additional IMPES reduction is required to eliminate the non-
i 5 1, Nc, cii 5 1/Dt, cN c11,N c11 5 fb w / r V/Dt. If hydrocarbons pressure coefficients in the implicit bottomhole pressure con-
invade the block, then the values of Pi, i 5 1,Nc are directly the straints. The latter constraint includes an Nc 1 1 row vector term
number of moles of component i in the block. Thus, the mass, for each perforated block. The first Nc (nonpressure) elements of
composition, density, and saturation of the hydrocarbon phase(s) this term are eliminated employing as pivots the diagonal elements
can be computed, and the block is switched to the appropriate of the C matrix of Eq. 2. This results in a constraint equation
hydrocarbon/water case. containing only pressure coefficient terms. However, the number of
A significant difference from the above formulation is a relaxed such terms is significantly larger than the number of perforated
volume concept mentioned by several authors in connection with blocks.
IMPES. IMPES is an implicit pressure, explicit saturation method For the compositional case, the Nc phase equilibrium constraints
independently conceived by Stone and Garder17 and Sheldon et are equality of liquid and vapor fugacities for each component. For
al.18 Their method is widely used in black oil simulation, generally the black oil case, the E matrix has only one nonzero column.
incorporating the saturation constraint Sw 1 So 1 Sg 5 1. However,
dY1 ~ p!
early papers by Wattenbarger19, 20 and Abel et al.21 described dy1 5 dp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (8)
IMPES in the compositional and black oil cases with exact mass dp
balance and a relaxed volume balance. Young and Stephenson14
and others15, 16 more explicitly described the exact mass balances dX1 ~ p!
dx1 5 dp, . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (9)
attained by relaxing the volume balance. dp
S D
water/oil and gas/water blocks, Newton-Raphson psat calculations
are performed, and phase appearance is signaled by the sign of p 2 Q2
q* 5 q1 5 q11 1 q12 5 q11 , . . . . . . . . . . . . . . . . . . (16)
psat. In the event of flash failure, the model calculates psat to confirm Q1
the hydrocarbon single-phase state. In the event of psat failure, the
mixture is flashed at a lower pressure, and the resulting two phases where q12 and Q2 are the summations of q1k and Qk over all outflow
are iteratively flashed back up toward block pressure p. The flash layers. All terms on the right side of Eq. 16 are single-valued
and/or psat calculations may fail either because of proximity to functions of pw. Eq. 16 is solved for pw applying Newton-Raphson
critical point or passing out the right-side of the pressure/compo- iteration and qikl are calculated from Eqs. 12 and 14. The implicit
sition phase envelope. The model avoids excessive flash, psat molar rates required in the model are then
iterations, and calculations by applying stored historical data and
O
avoiding repeated attempts when composition has not changed N
qik
sufficiently. The model senses when composition has moved to the qik 5 qlik 1 dqik 5 qlik 1 d P# m . . . . . . . . . . . . . . . . . . (17)
right of the phase envelope and avoids the futile flash and psat m51
P# m
calculations there. Typically, a flash calculation requires only one
to three Newton-Raphson iterations. Viscosities are obtained from The fi, fw values are iteratively lagged. All other terms in the qik
the Lohrenz et al. correlation.24 Interfacial tension is obtained from expressions are differentiated with respect to pw and all reservoir
the McLeod-Sugden correlation.25 gridblock variables yi, xi, Sw, So, Sg, and p.
In the black oil case, a simple check of overall mole fraction z1 The outflow curve gives pw as either pw 5 BHP or as a function
against the converted table X1(p) value detects phase appearance or of qo, gas/oil ratio, and water cut given by a tubinghead pressure
disappearance. In both black oil and compositional cases, a block’s table. If the calculated pw from Eq. 16 is above the outflow curve,
phase configuration may change over the Newton iterations. the well is on target rate, and a well constraint equation applies. If
not, Eq. 16 and the outflow curve must be solved simultaneously
Description of Well Calculations for a pw, which is an intersection of the inflow (Eq. 16) and outflow
curves. In this case, there is no constraint equation if outflow pw 5
Well calculations include the splitting or allocation of total well rate BHP but there is in the tubinghead pressure table case.28
among the completed layers, the well constraint equation preserv- The constraint equation for the above black oil example is
ing target rate over the iteration, and special effects such as
O
non-Darcy flow. k2
Holmes26 described a splitting method that accounts for wellbore dqlk 5 0 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (18)
crossflow in implicit formulations. He assumed a fully mixed k5k 1
wellbore and used three wellbore variables, two phase volume
variables, in addition to wellbore pressure. Modine et al.27 de- In black oil cases, the constraint equation exactly preserves target
scribed an implicit splitting method that uses multinode wellbore rate. The compositional case is more difficult. With q* 5 STB/D
mass balances to eliminate the fully mixed assumption in crossflow. oil specified, the constraint equation holding constant total
The splitting method used here is one developed by Phillips moles/D,
Petroleum in the 1970’s. It represents crossflow assuming a fully
O
k2
mixed wellbore and uses the single wellbore pressure variable. It
is simple and more efficient than the method of Modine et al. dqk 5 0, . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (19)
k5k 1
Wellbore pressure is
pw ~Z! 5 pw 1 gwb ~Z 2 Z*!, . . . . . . . . . . . . . . . . . . . . . . . . . (10) preserves surface oil rate only if the bottomhole inflow is an oil or
gas phase of unchanging composition. The model uses a method29
where wellbore gradient gwb is approximated at the beginning of the applying surface separation system overall K values. It gives a
timestep and held fixed over the Newton iterations. We consider a modified form of Eq. 18, which significantly reduces departure of
production well completed in multiple layers of index k. Defining the new rate from target value. This contributes to fewer Newton
Pk as pk 2 gwb(Zk 2 Z*), the total RB/D Qk and molar qik rates iterations, or better rates for the same number of iterations, in the
(moles/D) are the following: compositional case.
It is well known that high velocity gas flow can affect gas
For inflow layers (Pk . pw) injectivity in injection wells and producing rates and gas/oil ratio
Qk 5 Jk ltk ~Pk 2 pw ! . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (11) in production wells. Katz and Cornell30 modified the Darcy flow
equation to account for this effect by introducing the b factor in the
qik 5 Jk ~lo ro xi 1 lg rg yi !k ~Pk 2 pw ! . . . . . . . . . . . . . . . . . . . (12) Forscheimer equation. The model uses a radially integrated form of
that equation to relate pw and gas rate.28
qwk 5 Jk lwk bwk ~Pk 2 pw !; . . . . . . . . . . . . . . . . . . . . . . . . . . (13)
for outflow layers (Pk , pw), Qk is the same as Eq. 11 and pk 2 pwk 5 F 1
lg Jrg
qg 1
41.125~10216 ! Mb 2
rg rw h2 G
qg . . . . . . . . . (20)
k
qik 5 Jk fi ltk ~Pk 2 pw ! . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (14)
The term h2 is missing in Ref. 28, which describes in detail the
qwk 5 Jk fw ltk ~Pk 2 pw !, . . . . . . . . . . . . . . . . . . . . . . . . . . . (15) modifications for non-Darcy flow in the layer gas rate calculation.
The b factor is presented graphically as a function of perme-
where fi 5 qi1/Q1, fw 5 qw1/Q1, and the 1 denotes summation over ability and porosity by Katz et al.31 The correlation of Firoozabadi32
all inflow layers. That is, qi1 is the summation of all inflow-layer is used here,
qik molar rates, Q1 is the summation of all inflow-layer Qk RB/D
rates. This definition and use of fi, fw represents the fully mixed 2.6~1010 !
b5f , . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (21)
wellbore assumption; the outflow stream is the same for all outflow ~krg k!1.2
layers and has the composition of the combined inflow streams. The
interphase mass transfer and compressibility effects within the where f may be entered as data for each perforated layer.
Fluids in Place
Average
Water Oil Gas Pressure,
Region MSTB MSTB MMscf psia Case, Time
Field Examples
Two field examples are presented to demonstrate the usefulness of
the model. The first example is a history match of the Ekofisk
reservoir, which includes both gas and water injection. The second
example is a history match of gas cycling in the Chatom reservoir.
Ekofisk
The Ekofisk field, which is located in the Norwegian sector of the
North Sea, was placed on production in July 1971. Produced gas in
excess of sales has been reinjected in the Crest of the field since
1975. Water injection was started in 1987 after a successful wa-
terflood pilot was performed.41 The waterflood was subsequently
Fig. 1—SPE1 oil rate and gas/oil ratio vs. time.
expanded,42 and currently water injection rates average 750,000
B/D.
The reservoir rock effect alone (f 5 1) gives the following A history match of the field from 1971 to 1994 was run.
changes in SPE1 results at 3,650 days: cumulative gas production Reservoir and production (injection) data from Phillips reservoir
is reduced from 338 to 304 Bscf, and gas/oil ratio is reduced from simulation model43 were used as input. A 13,728-block 44 x 26 x
19,697 to 17,558 scf/STB. 12 grid with all cells active was used. The Phillips model extended
beta PVT data were replaced by a three-component description of
SPE Comparative Solutions Ekofisk.28
Several SPE Comparative Solution examples were run during the Field gas/oil ratio vs. time for this run is shown in Fig. 3 along
development of the model to test the accuracy of the results and the with the results from the Phillips model. Essentially identical results
efficiency of the formulation. Three black oil problems, SPE1, were obtained. The simulation was run with the IMPES formulation
Comparison of Solutions to a 3D Black-Oil Reservoir Simulation and took 264 timesteps, 294 iterations, and 456 seconds of CPU
Problem,36 SPE2, A Three-Phase Coning Study,37 and SPE9, An time applying nested factorization.
Expanded 3D Problem with a Geostatistical Distribution of Per-
meability,38 were run as well as two compositional cases, SPE3, Chatom
Gas Cycling of Retrograde Condensate Reservoirs,39 and SPE5, The Smackover Reservoir of the Chatom Field, which is located in
Evaluation of Miscible Flood Simulators.40 The number of time- Washington County, Alabama, is a retrograde gas condensate
steps, Newton iterations, and the CPU time required for each run reservoir that contains approximately 17% H2S. Liquid content of
are presented in Table 2. the gas at the dewpoint pressure of 3,073 psig and reservoir
The SPE1, SPE3, and SPE5 problems have square xy grids and temperature of 293°F is 400 bbl/MMscf. Production from the field
are symmetrical about the diagonal x 5 y. All runs reported here was started in 1974, and gas injection of residue gas was initiated
used the full grids. These problems give identical results when run in 1976.
with the half-symmetrical element, except that CPU times are A history match of this gas cycling project from 1974 to 1994
reduced by a factor of about two. was conducted starting with data from a previous study.44 A
* CPU time SPE2 was 0.9 sec, with 1.3 sec, for data input, initialization, and error checking. All CPU times reported in this table include similar overhead.
Nomenclature
bw 5 water formation volume factor, STB/br
cr 5 rock compressibility, 1/psi
D 5 non-Darcy flow coefficient, d/Mcf
Fig. 3—Ekofisk field gas/oil ratio match. f 5 multiplier on reservoir b factor that accounts for high
velocity flow through the near wellbore region
G 5 gas gravity, air 5 1
4,056-block 26 x 26 x 6 grid with 2,214 active cells was used. The h 5 layer thickness, ft
SRK EOS with six components was used to match experimental Jk 5 layer k productivity index, br-cp/d-psi
phase behavior data, which consisted of expansion and depletion k 5 absolute permeability, md
experiments and swelling data. The composition of initial reservoir kr 5 relative permeability, fraction
gas and injected gas are given in Table 1 of Ref. 44. krgcw 5 relative permeability to gas at connate water
Results from this study are presented in Fig. 4, which is a krwSw1 5 relative permeability to water at Sw 5 1
comparison of calculated and actual condensate rates vs. time. This M 5 gas molecular weight
simulation took 469 timesteps, 485 iterations, and 202 CPU seconds N 5 total number of variables, 2Nc 1 4
using nested factorization. Nc 5 number of hydrocarbon components
Nw 5 number of active wells on target rates
Discussion p 5 gas phase pressure, psia
pb 5 base or reference pressure
Several runs were made on SPE9 to investigate the level of time psat 5 saturation pressure, psia
truncation error. Base runs applying 1- and 10-day timesteps gave pw 5 bottomhole wellbore pressure
essentially identical results. Next, a run with 16 timesteps and 52 P 5 Nc 1 1 2 vector of primary variables
iterations was made. Time truncation error in this run was apparent P# 5 N 2 vector of total variables
although not appreciably large. The last run was made with smaller Pc 5 capillary pressure, psi
maximum timestep control and took 33 timesteps and 55 Newton Pe 5 Nc vector of eliminated variables
iterations (Table 2). The amount of time truncation error in this run qg 5 gas production rate, Mcf/D
is minimal. qi 5 production rate of component i, moles/D
qw 5 production rate of water, moles/D
Conclusions q* 5 well target rate
1. This paper describes a general three-phase, 3D numerical Q 5 production rate, total RB/D
simulation model. Black oil and fully compositional capabilities are rs 5 oil in gas phase, STB/scf
included with IMPES and fully implicit formulations. rw 5 wellbore radius, ft
Appendix
Keith Coats is President of K.H. Coats and Co. Inc. in Florida.
Relative Permeability Previously, he was Assistant Professor of chemical engineering
Relative permeability and capillary pressure curves are normalized at the U. of Michigan, Associate Professor of petroleum engi-
by means of residual saturations, which can be entered on a neering at the U. of Texas, a research associate at Esso Pro-
gridblock basis, and normalized saturation equations for the wetting duction Research, and Chairman of Intercomp. Coats holds MS
and nonwetting phases. The normalized saturations range from zero and PhD degrees in chemical engineering and an MS degree
to one for mobile phase saturations. Drainage Pcwo and krw are in mathematics from the U. of Michigan. Kent Thomas is Man-
normalized by means of S *w, where ager of Engineering Sciences in the Research and Services Div.
of Phillips Petroleum Co. in Bartlesville, Oklahoma. He holds a BS
degree from the U. of Oklahoma and MS and PhD degrees from
Sw 2 Swc the U. of Michigan, all in chemical engineering. Thomas served
S*w 5 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (A-1) as the Program Chairman for the 1997 SPE Symposium on
1 2 Swc
Reservoir Simulation and is currently a member of the 1999
Program Committee. He was the recipient of the 1993 Reservoir
Imbibition Pcwo and krow are normalized by means of S# w. Engineering Award and has served as a Distinguished Lecturer.
Thomas was elected a SPE Distinguished Member in 1995. Ray
Sw 2 Swc Pierson is a senior research computing specialist at Phillips
S# w 5 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (A-2) Petroleum Co. in Bartlesville. He holds a BS degree in mathe-
1 2 Swc 2 Sorw matics from Southwestern Oklahoma State U.