Академический Документы
Профессиональный Документы
Культура Документы
Stable Timesteps
K.H. Coats, SPE, Coats Engineering, Inc.
The first sum is over all block neighbors; the second sum is over f 11ij = Tij 关共0 + g兲 ww
⬘ | ⌬⌽w | − wow
⬘ | ⌬⌽o|
all wells completed in the block. Well terms are assumed to be
treated fully implicitly and are dropped from consideration. − w共p + g兲 共Pcwoi ⬘ 兲兴 Ⲑ t, . . . . . . . . . . . . . . . . . . . (4a)
⬘ + Pcwoj
The IMPES formulation1,2 treats the interblock flow rates im- f 12ij = −Tij 关w⬘og | ⌬⌽o | + w⬘g | ⌬⌽g |
plicitly in pressure, but explicitly in saturations and compositions.
This explicit treatment gives rise to a conditional stability for − 共0 + g兲 ⬘wg | ⌬⌽w |
IMPES, + wg 共Pcgoi ⬘ 兲兴 Ⲑ t, . . . . . . . . . . . . . . . . . . . . . . . . . (4b)
⬘ + Pcgoj
Fi⌬t f 21ij = −Tij 关gww
⬘ | ⌬⌽w | gow
⬘ | ⌬⌽o|
⬍ 1, . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (2)
Vpi − gw 共Pcgoi ⬘ 兲兴 Ⲑ t, . . . . . . . . . . . . . . . . . . . . . . . . . (4c)
⬘ + Pcgoj
where ⌬t⳱maximum stable timestep and Fi⳱some function of f 22ij = Tij 关−gog
⬘ | ⌬⌽o | + 共w + o兲 ⬘g | ⌬⌽g |
rates and reservoir and fluid properties. This paper derives the
function Fi for compositional and black oil models, accounting for − gwg
⬘ | ⌬⌽w |
viscous, gravity, and capillary pressure forces in cocurrent and + g 共o + w兲 共Pcgoi ⬘ 兲兴 Ⲑ t, . . . . . . . . . . . . . . . . . . . (4d)
⬘ + Pcgoj
countercurrent three-phase flow. The grid may be unstructured, or
structured (e.g., Cartesian) with or without nonneighbor connec- det共Fi兲 = f 11i f 22i − f 12i f 21i. . . . . . . . . . . . . . . . . . . . . . . . . . . (4e)
tions. The flow may be 1D, 2D, or 3D. Tensor considerations are The flow potential definitions are
neglected. Condition 2 gives a different stable step value for each
block. In an IMPES model, the time step used is the minimum of ⌬⌽w = ⌬p − ␥w⌬Z − ⌬Pcwo . . . . . . . . . . . . . . . . . . . . . . . . . . . . (5a)
all blocks’ stable step values. In an AIM (adaptive implicit) model,3
each block’s stable step size can be used to determine if the block ⌬⌽o = ⌬p − ␥o⌬Z . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (5b)
needs implicit treatment. The effects on stable step size of (a) inter- ⌬⌽g = ⌬p − ␥g⌬Z + ⌬Pcgo, . . . . . . . . . . . . . . . . . . . . . . . . . . . . (5c)
phase mass transfer and (b) the pressure and composition dependence
of fluid properties are assumed small and neglected. where ⌬X is Xj−Xi, X being any of p, Z, Pcwo, and Pcgo. For each
Two functions Fi are derived for use in Condition 2. The first neighbor j, the four frsij (rs⳱11,12,21,22) values are stored in the
relates to effects of explicit treatment of the saturation-dependent four frs arrays at the gas-phase upstream block position, if g is not
terms (relative permeability and capillary pressure) in the inter- zero. If g is 0, they are stored at the water phase upstream block
block flow rates. The second relates to the explicit treatment of position. The frs satisfy f11i>0, f22i>0, and det(Fi)>0, which pro-
compositions in the interblock flow rates. vide a check on coding errors.
Derivations of the function Fi are lengthy and, at various The Fi given by Eq. 3 accounts for viscous, gravity, and cap-
points, tedious. This tends to obscure the simplicity and low cpu illary forces, and for all possible cocurrent and countercurrent
flows of three phases between two blocks. The above equations
collapse to simple forms for each of the three two-phase cases. For
example, for 1D two-phase gas/oil flow, w⳱wg ⬘ ⳱ow⬘ ⳱ww ⬘ ⳱0,
Copyright © 2003 Society of Petroleum Engineers which give f11⳱f12⳱f21⳱0 and
This paper (SPE 84924) was revised for publication from paper SPE 69225, first presented
at the 2001 SPE Reservoir Simulation Symposium, Houston, 11–14 February. Original F = f 22 = T 关0g⬘ | ⌬⌽g | − g⬘og | ⌬⌽o|
manuscript received for review 23 March 2001. Revised manuscript received 20 February
2003. Manuscript peer approved 10 March 2003. + go 共Pcgoi ⬘ 兲兴 Ⲑ 共og兲. . . . . . . . . . . . . . . . . . . . . . . . . . (6)
⬘ + Pcgoj
The derivative ⌿⬘ is positive for low to moderate Sg and negative ␦qgi = qgi共Sgi,n,Sgi−1,n兲 − qgi共Sgi,n
⬘ ,Sgi+1,n
⬘ 兲. . . . . . . . . . . . . . . . . . . (19)
for larger Sg. Condition 11 presents a dilemma because it gives
Using the first Taylor series terms gives
unconditional stability and conditional stability for positive and
negative ⌿⬘, respectively. For this counter-current flow, Eq. 3 ␦qgi = qgi,i
⬘ i,n + qgi,i+1
⬘ i+1,n, . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (20)
gives Fi=f22i and Condition 2 is
where q⬘gi,i⳱the partial derivative of qgi with respect to Sgi and
⌬t q⬘gi,i+1⳱the partial derivative of qgi with respect to Sgi+1. The term
T 共␥ − ␥g兲⌬Z共␥2o␥g⬘ − ␥2g␥og
⬘ 兲 Ⲑ ␥t2 ⬍ 1. . . . . . . . . . . . . . . . . (13) ␦qgi-l in Eq. 18 is expressed in similar fashion, with care to use
Vpi z o
locally constant derivatives (i.e., q⬘gi−l,i-l⳱q⬘gi,i and q⬘gi−l,i⳱q⬘gi,i+1),
Numerous 1D vertical countercurrent flow simulations were
performed, initializing the column with uniform saturation distri- ␦qgi−1 = qgi,i
⬘ i−1,n + qgi,i+1
⬘ i,n. . . . . . . . . . . . . . . . . . . . . . . . . . . . (21)
butions or with the upper half containing the heavier phase and the Substituting Eqs. 20 and 21 into Eq. 18 gives the error equation
lower half containing the lighter phase. In all cases, use of ⌬t from
Condition 13, using ⳱ in place of <, gave nonoscillatory stability. Vpi
In most cases, instability occurred for ⌬t values 10 to 20% larger. 共 − i,n兲 = aii+1,n − bii,n + cii−1,n, . . . . . . . . . . . . . . . . (22)
⌬t i,n+1
In all cases, results exhibited significant instability using ⌬t from
Condition 11 with the conservative choice of |⌿⬘| replacing −⌿⬘. where
Conditions 12 and 13 give the data-dependent ratio ai = −qgi,i+1
⬘ . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (23a)
⌬t共this work) +Max共k兲共|2og⬘ 2gog
⬘ |兲 bi = qgi,i
⬘ − qgi,i+1
⬘ . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (23b)
= ⬍ 1, . . . . . . . . (14)
⌬t(previous work) Max共k兲共2og⬘ − 2g⬘og兲 ci = qgi,i
⬘ . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (23c)
where Max(k) denotes maximum over all gridblocks at the current Eq. 23 shows that ai+ci⳱bi. Also, q⬘gi,iⱖ0 and q⬘gi+1ⱕ0 for all cases
timestep. Numerous similar simulations with three-phase flow gave of cocurrent and countercurrent flow, so that each of ai,bi,ciⱖ0.
stability using Eq. 3 and instability with ⌬t values 20% larger. The Appendix describes application of stability analysis to Eq.
22 with the variable coefficients Vpi, ai, bi, ci assumed to be con-
Derivation of F for Effects of Explicit Treatment stants independent of i and n. The resulting stability condition is
of Saturations
Methods of stability analysis generally apply to linear difference ⌬t
共a + bi + ci兲 ⱕ 2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (24)
equations with constant coefficients. For the case of variable Vpi i
Note that the term q⬘gi,i and q⬘gi,i+1 is always positive. The last two ⭸ ⭸
共Sgg兲 = − 共qgg兲. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (34c)
(non-Pc) terms in Eq. 27 can be expressed equivalently as ⭸t ⭸x
Ti+1 Ⲑ 2 If qo, these equations give
关og⬘|⌬⌽g|− ⬘gog
⬘ |⌬⌽o |兴. . . . . . . . . . . . . . . . . . . . . . . . . (28)
t ⭸y qggyI ⭸yI
+ = 0, . . . . . . . . . . . . . . . . . . . . . . . . . . (35a)
These results (Eqs. 26 through 28) for 1D gas/oil flow are equivalent ⭸t SooxI + SggyI ⭸x
to Condition 2 with Fi⳱f22i in Eq. 3. For multidimensional flow and if qg⳱0,
there are more contributions to Fi, each of the same form as f22i.
⭸xI q0oxI ⭸xI
The Three-Phase Flow Case. For the case of 1D three-phase + = 0. . . . . . . . . . . . . . . . . . . . . . . . . . . (35b)
⭸t SooxI + SggyI ⭸x
incompressible flow, the Darcy expressions for phase rates from
gridblock i to block i+1 are Eq. 35 is obtained from Eqs. 34 using yI⳱KIxI and neglecting the
dependence of the K-values on pressure and composition. Eq. 35
qwi = Ti+1 Ⲑ 2w共⌬p − ␥w⌬Z − ⌬Pcwo兲 . . . . . . . . . . . . . . . . . . . . (29a) is easily expressed in difference form, with explicit dating of the
qoi = Ti+1 Ⲑ 2o共⌬p − ␥o⌬Z兲 . . . . . . . . . . . . . . . . . . . . . . . . . . . . (29b) spatial derivatives and upstream weighting. Application of the von
Neumann stability analysis, as in the Appendix, gives stability
qgi = Ti+1 Ⲑ 2g共⌬p − ␥g⌬Z − ⌬Pcgo兲 . . . . . . . . . . . . . . . . . . . . . (29c) conditions
Eliminating ⌬p from these equations gives the phase rates as qggyI ⌬t
⬍ 共qo = 0兲 . . . . . . . . . . . . . . . . . . . . . . . . . . (36)
qwi = w关q + 共o + g兲 awo + gago兴 Ⲑ t . . . . . . . . . . . . . . . . . . (30a) SooxI + SggyI Vpi
The Two-Phase Case. We consider the difference equation 2i+1, n − 2i, n = a211i+1, n − b211i, n + c211i−1, n
i, n+1 − i, n = ␣i+1, n − bi, n + ci−1, n , . . . . . . . . . . . . . . . . . . (A-1) + a222i+1, n − b222i, n + c222i−1, n . . . . . . . . . . . (A-10b)
Comparing the coefficients in Eqs. 33 with those in Eq. A-10
similar to Eq. 22, where all coefficients a,b,c are ⱖ0. The von
shows that the latter satisfy
Neumann stability analysis method replaces i,n by the Fourier
type term ars + crs = brs rs = 11, 12, 21, 22. . . . . . . . . . . . . . . . . . (A-11)
n ˆii
i, n = e . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (A-2) Substituting 1i,n⳱n1eı̂j1 and 2i,n⳱n2eı̂i2 in these equations
gives
The ratio i,n+1/i,n is so that the stability condition is ||<1.
Substituting i,n from Eq. A-2 into Eq. A-1 and using the identity n+1 = En, . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (A-12)
eı̂⳱cos+ı̂sin gives where n⳱the error vector (1i,n,2i,n)T and the elements rs of
the amplification matrix E are
= 1 − b + 共a + c兲cos + î共a − c兲sin . . . . . . . . . . . . . . . . . (A-3)
11 = 1 − d11 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (A-13a)
and
12 = −d12 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (A-13b)
||2 = 关1 − b + 共a + c兲cos兴2 + 关共a − c兲sin兴2. . . . . . . . . . . . (A-4)
21 = −d21 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (A-13c)
We seek the maximum value of ||2 over the range of eigen-
values, or equivalently, the range of cos values, −1<cos<1. The 22 = 1 − d22, . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (A-13d)
maximum value of ||2 occurs at a  value which satisfies d||2/
d⳱0. Taking this derivative from Eq. A-4, setting it to zero, and and, for rs⳱11,12,21,22,
solving for  gives two roots. Using the first root, sin⳱0, in Eq.
A-3, we find that stability (||<1) requires the two conditions (for drs = −共ars + crs兲cosx + brs − î共ars − crs兲sinx , . . . . . . (A-14)
cos⳱−1 and +1, respectively) The spectral radius E of E is the eigenvalue of E of maximum
absolute value. We impose the stability requirement E<1. The
a + b + c ⬍ 2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (A-5a) value of E obviously depends upon the eigenvalues 1, 2, which
a + c ⬍ b. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (A-5b) assume all values corresponding to the ranges −1<cos1<1 and
−1<cos2<1. In the two-phase case above, the most restrictive
Adding these two conditions gives a+c<1. The second root leads to stability condition ||<1 resulted for the eigenvalue cos⳱−1,
nothing of consequence. For N>1, all difference forms of type Eq. sin⳱0. Assuming that is also true for this three-phase case gives
A-1 in this paper satisfy a+c⳱b so that the Condition A-5b is the eigenvalues cos1⳱cos2⳱−1, sin1⳱sin2⳱0. Using these
always satisfied. Therefore, the stability condition for Eq. A-1 is eigenvalues in Eq. A-14 gives real drs values and Eqs. A-13 give
A-5a or, using a+c⳱b, the (real) rs elements of the amplification matrix E. The two
eigenvalues of the E matrix are then easily calculated as the roots
a + c = b ⬍ 1. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (A-6) of E ‘s quadratic characteristic equation. The stability condition
that E<1 is obtained as
Discussion of the result b<2 for the case N⳱1 is dropped for
brevity. d11 + d22 + 公共d11 + d22兲2 − 4det共D兲 ⬍ 4, . . . . . . . . . (A-15)
Many authors point out that the stability condition for two or
three dimensions is simply the sum of two or three terms, each of where det(D)⳱d11d22 – d12d21. The drs satisfy
which is identical in form to that derived for the 1D case. For
example, consider Eq. A-1 written for three dimensions drs = 2brs rs = 11, 12, 21, 22 . . . . . . . . . . . . . . . . . . . . . (A-16a)
ijk, n+1 − ijk, n = axi+1, jkn − bxijkn + cxi−1, jkn d11 ⬎ 0 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (A-16b)