Anda di halaman 1dari 41

Terapan Reservoir Simulasi Course

SOLUSI SIMULASI
PERSAMAAN-3
Pekanbaru, 13 Mar 2017

REINC_APR2014
2-D multifase Arus

Dua Tahap Arus Sedikit CompressibleOil dan Air di Horizontal Homogen Sebuah

Reservoir dari UniformThickness.

• • • Hai k x k ro • P Hai • • • • k y k ro • P Hai • •


~
•• • ooS •
Hai
• •• • •• • MINYAK
•x • Hai • tq
Hai

• •x • •y • Hai
•y •

• • • w k x k rw • P w • • • • w k y k rw • P w • •q ~ •


••


• •
• • •• • wwS • AIR
• w • w
w
•x • •x • •y • •y • •t

persamaan ini adalah non-linear, terutama disebabkan oleh permeabilitas relatif

yang merupakan fungsi dari kejenuhan.

Numerik Solusi 3/3 2


FD Persamaan untuk Tahap Minyak

m m
kx • • Hai k ro • • P n•1
o, i • 1, j P• o, i, j
n•1
• kx • • Hai k ro • • P o,n •i,1j P• o, i • 1,n •j 1 •
• • • •• • • • •
• • • x • • • • •
• x • • Hai • saya • 2
1 ,j •
• x
• • Hai • saya •
2
1 ,j •
• x •
m m
k • • o kro • • Po,ni,•j1• 1 • Po,ni,• j1• • k y • • k • • Po,ni,•j 1 P• n • o,1 i, j • 1 • •

y
• • • • • o ro • •
• • • y • y • Hai • •
• y • • Hai • aku j • 1
2
• • y
• • • aku j • 1
2
• • y •

• n • 1 • • • ooS • n

• q~
Hai

• t• ••S oo aku j aku j

m: tingkat waktu di mana dievaluasi. non-linear koefisien

m = n: untuk skema eksplisit.

m = n + 1: untuk skema implisit.

Numerik Solusi 3/3 3


FD Persamaan untuk Tahap Minyak

m
• • •
Syarat jenis k x •• Hai k ro •

dievaluasi pada blok
• • Hai• x • saya2• 1, j

batas.

Mengalikan kedua sisi FD persamaan dengan curah waduk

volume ( h • x • y) memberikan:

khx • x • Hai • • •P • • •P • Po,n i••11, j •


• m • • Hai k ro
P •n • 1 o, i, j khx
y Hai k ro y m
n•1 n•1
saya • 1, j
o, i • 1, j • x • Hai saya • 1, j
o, i, j

••
2 2

• khy ••yx• Hai • Hai k ro


• •P m
n
o, i, j • 1
• Po,ni,•j 1 • •kh • x
y • y • Hai
• • Hai k ro • •Pm
n
o, i, j
• Po,n i,• 1j • 1 •
aku j • 1 aku j • 1
2 2
•1 •1

•• • S • n • 1 • • • ooS • n •
h • x • YQ ~
• h•x•y•
Hai oo
• t
aku j aku j

Numerik Solusi 3/3 4


FD Persamaan untuk Tahap Air

m m
• y• • k rw • • y • • w k rw •
kx h •
w
• •P n•1
w, i • 1, j P• w, i, j
n•1
• • khx •P n•1
w, i, j
n•1
P• w, i • 1, j •
• x • w • saya • • x •• • w ••
1, j saya • 1, j
2 2

m m
• • k• • x • • w k rw •
• kyh
x
• w rw
• •P n•1
w, i, j • 1 P• w, i, j
n•1
• • khy • • •P n•1
w, i, j
n•1
P• w, i, j • 1 •
• y • • w • aku j • 1
• y • • w • aku j • 1
2 2

• n • 1 • • • ww•Sn
•h•x•y
• q ~h
w
•x•y•
• t• ••S ww aku j aku j

Numerik Solusi 3/3 5


transmisibilitas

Aliran volumetrik tingkat di x-arah digambarkan oleh

Hukum Darcy sebagai:


k x k ro • P Hai
q Hai • • SEBUAH
x
• Hai
•x

Dalam bentuk beda hingga persamaan di atas menjadi

m
• kkx roAx • • Po,n i,• 1j P• n o, i • 1, j • •
•q • • • • •

• •
1
Hai saya •• jm
2

• • Hai • saya •• j •
1
• x •
2

The luas penampang di x-arah adalah:

•1 , j
• h • y A saya
2

Numerik Solusi 3/3 6


transmisibilitas

Fluks massa dapat ditulis sebagai:

q o, i •• j 1 • qo,1 i ••• jo
2 2

dan persamaan beda hingga menjadi

m
• k hy• • k ro o• •• •
•q • m
Hai saya1 • 2, j
• • • x •
• •• •P n•1
o, i, j P• o, i • n1, •
• • x• • • • saya • jo
2
1,
j

Istilah dalam braket persegi disebut inter-blok

transmisibilitas:
m
• k x h • y k• ro • Hai ••
T o,m i • 2,1 j • • • ••
• • •
• • x• Hai • • saya • 1, j
2

Numerik Solusi 3/3 7


FD Persamaan Minyak & Air

m
• n•1
T Hai saya • 1, j P o, i • 1, j P•o, i, j
2
n•1
•• m
T Haisaya • 1, j
2
•P n•1
o, i, j
n•1
P•o, i • 1, j •
•P •• To,mi, j•• P n •o,1 i, j • Po,n i,• j1• 1 •
m
• T o, i, j • 2 1 n
o, i, j • 1
• Po,ni,•j1 2
1

• q Haiˆ •
V
•1
p, i, j •••S • n • 1 • • • ooS • n •
oo
• t
aku j aku j

T
m

w, i •• 12j
•P n
w, i • 1, j
• Pw,n i,• j1 •
m
T w, i • 2,1 j •P n
w, i, j
• Pw,n •i •11, j

•P •• •P •
•1 •1
• Pw,n •i, 1j • 1
m
• • Pw,n i,• j1
m
T wi, j • 1 n•1
w, i, j • 1
T n
2
wi, j • 1 2
w, i, j

• q wˆ •
V p, i, j ••• S • n • 1 • • • wwij
•Sn
•1


ww
• t
aku j

PTRL3002 / 5004 Numerik Solusi 3/3 8


Penentuan transmisibilitas

Itu antar-blok laju aliran massa adalah produk dari transmisibilitas

dan perbedaan tekanan antara blok.

m
• kh • y k •• ••
•q • m
Hai saya1 • 2, j
• • • x

• •
ro o •
•• •P n•1
o, i, j
• Po,n i••11, j •
• • x• Hai • • saya •1
1, j
2

Dalam rangka untuk mengevaluasi antar-blok


antar transmissibility kita harus mendefinisikan

nilai untuk permeabilitas, permeabilitas relatif, kerapatan dan viskositas

di wajah blok. Karena parameter ini hanya didefinisikan pada sel

pusat
k bl blok, nilai-nilai
t th imerekal harus diestimasi
tb dari
ti nilai-nilai
TDF ini. th l

Numerik Solusi 3/3 9


Hulu Beratnya transmisibilitas

Transmisibilitas adalah saturasi tergantung karena mereka melibatkan

permeabilitas relatif. Kami telah menunjukkan bahwa stabilitas

mensyaratkan bahwa saturasi hal tergantung dievaluasi pada posisi

up-stream. Jadi,

m
T o, i • 1 , j • T o, i • 1, j jika P o, i • 1, j P•o, i, j
m m m

Numerik Solusi 3/3 10


Eksplisit & implisit transmisibilitas

m
T Hai •
n
T Hai Eksplisit. Transmisibilitas dapat dievaluasi langsung
dari tekanan dikenal dan
saturasi pada tingkat waktu n. Sistem yang
dihasilkan dari persamaan aljabar linier.

n•1
m
• TTHaiHai Implisit. Transmisibilitas adalah fungsi dari
tekanan yang tidak diketahui dan saturasi pada saat tingkat n +

1. Sistem yang dihasilkan dari persamaan aljabar adalah

non-linear dan lebih sulit untuk memecahkan dari yang

eksplisit.

Numerik Solusi 3/3 11


Cara Implisit adaptif

Formulasi eksplisit membutuhkan CPU kurang dari skema implisit. Tapi, untuk stabilitas • t harus
cukup kecil untuk metode eksplisit. implisit

Metode memungkinkan lebih besar • t yang membutuhkan langkah waktu yang lebih sedikit untuk lengkap

simulasi tapi kemudian CPU yang lebih tinggi diperlukan.

Formulasi menggunakan transmissibility eksplisit untuk beberapa blok dan


transmissibility implisit bagi orang lain disebut Metode implisit adaptif . Ini
mengambil keuntungan dari kesederhanaan metode eksplisit dan kekokohan
metode implisit untuk meminimalkan beban kerja komputasi secara keseluruhan.

Numerik Solusi 3/3 12


Solusi Aljabar Persamaan

Persamaan FD diperoleh untuk 2-D, masalah 2-fase yang ditulis untuk setiap

2N
blok jaringan. Untuk N blok, kita memiliki persamaan aljabar, yang dapat

dirumuskan sebagai:

• SEBUAH •• x • • • b •

Koefisien matrixA adalah matriks 2Nx2N dengan 10 non-nol diagonal. Struktur

ini untuk pemesanan alami. Skema pemesanan lainnya menghasilkan struktur

yang berbeda.

Untuk 2-D aliran 1-fase, [A] adalah nxn memiliki 5 elemen diagonal non-nol.

Numerik Solusi 3/3 13


Solusi dengan transmisibilitas Eksplisit

Sistem ini [A] persamaan linear, yaitu, unsur-unsur matriks koefisien


berisi dikenal. Vektor kolom {x} mengandung

semua diketahui:

• Dalam vektor ini, dua independen


P o, 1,1 •
n•1

• n•1 •
S w, 1,1 • diketahui adalah tekanan minyak dan air

• . • kejenuhan.
• •
•x • • • . •
• • n•1 n•1
P w, 1,1 P• o, 1,1 P c, •1,1 P
P
n•1
.
• •
n•1
• P o, M, N •
n•1 n•1
• n•1 • S o, 1,1 • 11 • S w, 1,1
• S w, M, N •

Numerik Solusi 3/3 14


Solusi dengan transmisibilitas Eksplisit

Solusinya diperoleh dengan membalik matriks koefisien [A]. Tiga metode


dapat digunakan:

1. eliminasi Gauss (efisien untuk masalah kecil). bentuk modifikasi


2. dari Gaussian penghapusan (menggunakan keuntungan dari

sparsity dari matriks). metode iteratif (efisien untuk masalah

3. besar).

Linear Solver: memecahkan sistem linear persamaan aljabar, yang


merupakan bagian utama dari simulator waduk.

Numerik Solusi 3/3 15


Solusi dengan transmisibilitas Implisit

Koefisien matriks [A] menjadi non-linear sejak transmisibilitas


bergantung pada tekanan dan saturasi:

• Hai
• • Hai •P •
• Hai • • Hai •P •
k ro • k ro • S w •

sistem non-linear dari persamaan harus diselesaikan secara berulang.


Metode iteratif didasarkan pada Metode Newton

menemukan nol dari fungsi satu atau lebih variabel.

Numerik Solusi 3/3 16


Metode Newton

Persamaan Non-Linear dengan Variabel Tunggal

Objek dari metode ini adalah untuk menemukan nol dari fungsi sebagai:

f•x ••0

Estimasi awal dibuat untuk solusi dan estimasi

ditingkatkan lebih iterasi berturut-turut. Mulanya kita memiliki

f • x Hai • • 0

f • x Hai • • Hai • • 0

• Hai adalah kesalahan dalam estimasi awal x Hai.

Numerik Solusi 3/3 17


Metode Newton

Memperluas fungsi dalam serangkaian Taylor tentang • Hai memberikan

1
f • x Hai • • Hai • • f • x • • f • • x o • • Hai • f • • x Hai • • Hai •
2

2
...
Jika perkiraan x Hai dekat dengan solusi, kesalahan • Hai harus menjadi

kecil dan kita bisa mengabaikan hal tatanan yang lebih tinggi. Di dalam kasus,

f • x Hai • • Hai • f • x Hai • f• • x Hai • • • 0


• • Hai
Mengatur kembali persamaan ini memberikan

f • x Hai
• Hai • •
f• • x Hai •

Numerik Solusi 3/3 18


Metode Newton

• Hai adalah mudah dievaluasi (analitis atau numerik) jika bentuk fungsi ini
f th f ti perkiraan
known.Abetter ik untuk xab ti x 1,tf
tt karena itu
Oleh

x 1 • x Hai • • Hai

Prosedur :

1. Membuat awal memperkirakan dari solusi dan menetapkan iterasi

kontra k = 0

2. Set • k • • f • xk• / f • • xk•

3. Set xk•1 • xk• •k

4. Jika • k • • • toleransi konvergensi yang membuat f • x k • 1 • • 0 •


prosedur diakhiri. Jika tidak set k = k + 1 dan kembali ke 2.

Numerik Solusi 3/3 19


Metode Newton

Persamaan Non-Linear dengan Multiple Variabel

Untuk fungsi beberapa variabel metode Newton mudah


umum dengan cara berikut:

• x 1, k • • • 1, k • • f • x1 • • f• • x1 •
• • • • • • •

x 2, k


• 2, k •
f• • x 2 • • f• • • x 2 •• •
• •
• xk• • • . • •• k • •• . • • f • x •• •• . • J • f • x •• •• . •
• • • • • • • •
• . • • . • • . • • . •
• x N, k • • • N, k • • f • x N ••• • f • • x N •• •
• • • • • •

J [f (x)] adalah matriks Jacobian.

Numerik Solusi 3/3 20


Metode Newton

Prosedur :

1. Buatlah perkiraan awal x0 vektor dan set iterasi

kontra k = 0.

2. Set ε k • • • J • f • x ••• • 1 f •k x •

3. Set
xk•1 • xk• •k

4. If
•k • • • the convergence tolerance which makes f • x k•1
•• 0 •

the
prosedur
procedure
diakhiri
is terminated.
Jika tidak set
Otherwise
k = k + 1set
dan=k+1
kembali
and ke
return
2 to 2.

Numerik Solusi 3/3 21


Newton Method

Example: Consider the following non-linear problem:

3 x 2 • 2 x • 8 xy • 4 y 2 • 1 • 0
2
x 2 • 2 xy • 2 y • 2 y 2 • 1 • 0

The zeros of this system are x=y= 1. For purpose of illustration let us make the initial

estimates x o= y o= 0 and see how Newton’s method improves the estimate.

Numerical Solutions 3/3 22


Newton Method

Following our vector notation we have

• x•
x• • •
•y•

• f • x • • • 3 x • 2 x • 8 xy • 4 y • 1 • • 0 •
2 2

f • x • • •1 • • • •
• f 2• x ••• • x 2 • 2 xy • 2 y • 2 y • 1 • • • 0 ••
2


• •6 x • 2 • 8 y •• 8 x • 8 y
• f1
• •f 1

•y•
J •f •x •• • • • f•
•x
• f 2••• • •
•• •x
2

•y
•2 x •• 2 y • • • 2 x• • 2 • 4 y •••

Numerical Solutions 3/3 23


Newton Method

Begin the iterative process

•0 •
xo•

•0 •

• 3 x 2 • 2 x • 8 xy • 4 y 2 • 1 • •• 1 •
f • xo• • • •• • •
• x 2 • 2 xy • 2 y • 2 y 2 • 1 • • 1 •

• •6 x • 2 • 8 y • ••8x•8y • • •2 0 •
J •f •x o •• • • •
• •2 x • 2 y • • • 2 x • 2 • 4 y • • • •• 0 • 2 ••

•1 •• 1 •
•2 0 • • 0.5 0 • • • 1 • • 0.5 •
εo• • J • f • x ••
o

f • xo• • • • • • • • • • •• • • • •
1 • 0 • 2 • • 1 • • 0 • 0.5 • • 1 • • 0.5 •

Numerical Solutions 3/3 24


Newton Method

A better estimate of the solution is therefore

• 0 • • 0.5 • • 0.5 •
x1• x0• ε0• • • • •

• 0 •• • 0 .55 ••• • 0 55•••

• 3 x 2 • 2 x • 8 xy • 4 y 2 • 1 • • • 0.25 •
f • x1• • • • • • •
• x 2 • 2 xy • 2 y • 2 y 2 • 1 • 0.25 •

• •6 x • 2 • 8 y • ••8x•8y • •1 0 •
J •f •x 1 •• • • • •
• •2 x • 2 y • • • •2 x • 2 • 4 y • • •0 • 1••

•1 0 • • • 0.25 • • 0.25 •
••xf 1••• f • x1• • •
1
ε1• • J •• • • • •
• 0 • 1 •• 0.25 • • 0.25 •

Numerical Solutions 3/3 25


Newton Method

Abetter estimate of the solution now becomes

• 0.5 • • 0.25 • • 0.75 •


x2• x1• ε1• • • • •
• 0.5 •• • 0• 25 • • • 0.75 •••

If the procedure is repeated 15 times, the result is

• 0.99995 •
x 15 • •
• 0.99995 • •

The iteration process may be continued to achieve any


desired accuracy.

Numerical Solutions 3/3 26


Derivation of Jacobian Matrix

Residuals for 2-D 2-Phase problem:

••• • n • 1 • • •• oSo • n ••
h•x•y
R o ,i , j • S
oo
• t
i,j i,j

T
m •P n•1
• •Pon,i •, j1 •• T
m
•P n•1 • Pon,i••11, j •• OIL
o ,i • 2 , j
1
o ,i • 1, j o ,i • 2 , j1 o ,i , j

•P • Pon,i •, j1 •• To ,im, j•• P n •o1,i , j • Pon,i •, j1• 1 • • q~ h•x•y


m
T 1 n
o ,i , j • 1 1 o ,i , j
o ,i , j • 2 2

•1

••• • n • 1 • • •• w•Swn ••
h•x•y
R w,i , j • S
ww
• t
i,j i,j

T
m

w ,i • 21, j
•P n
w,i • 1, j
• •Pw,in •, j1 •• T
m

w ,i • 21, j
•P n
w,i , j
• Pw,in ••11, j •• WATER

•P •• •P • • q~
•1 •1
• Pw,in •, j1 • Pw,in •, 1j • 1 h•x•y
m m
T 1 n•1
w,i , j • 1
T 1 w,i , j
n•1
w,i , j
w ,i , j • 2 w ,i , j • 2

Numerical Solutions 3/3 27


Derivation of Jacobian Matrix

To form the Jacobian matrix we must differentiate the residual


equations with respect to pressure and saturations. The derivative
w.r.t. P for the oil phase is:

n•1 n•1
• R on ,i• ,1j h•x•y• • • • •••o • • •
• ••• o So • n•1
• • • •• S • o
n•1
• •

• Pon,i ,•j 1
i,j
• t • • Po • i , j
i,j
• • • Po •i,j •
• •
• T o ,i • 1 , j • T o ,i • 1 , j
m m

• 2

n •• 1
•P n•1
o ,i • 1, jj
• Pon,i •, j1 •• T
o
m
,i • 1
, jj
• 2

n •• 11
•P n•1
o ,i , j
• Pon,i• •11,, j •• m
Too ,i • 1 , ,j j
• P o ,i , j •P
o
2
P o ,i , j 22

m
• Toi,j• • To i , j •
m


1
2
•P n
• 1

o ,i , j • 1

• Pon,i •, j1 ••
1
T
m

o ,i , j • 1 • 1
1
2
• P• n
•1
o ,i , j
Pn•1
• o ,i , j • 1
•• m1
To•,i , j • 1

• Pon,i ,•j • Pon,i •, j


1
2 2

Numerical Solutions 3/3 28


Derivation of Jacobian Matrix

From the definition of transmissibility:

k xh • y •• k ro• o •
T o• •
• x • • o •

Its derivation w.r.t. pressure:

• To kx h • y • • • k ro k ro • • •• •
o
• k ro • o
o o
• • •
• Po • x •• • o
• Po • o • Po • Po •

Assuming that the viscosity is constant:

•To k xh • y • • k ro • • o ••
• •• • k ro •
• o • x ••
o
• Po • Po • Po •

Numerical Solutions 3/3 29


Derivation of Jacobian Matrix

Using the chain rule we have:

• k ro dk ro • S w

• Po dS w • Po

Evaluated from relative


permeability data

1 • •o
Oil density is given by: • o• sc
• R s • g ,sc •
Bo

•• o
d•1• • g ,sc dR s
• • • ••
• Po
o ,sc •o
dP o B • B o dP o
• •

This equation requires derivatives of PVT data with respect to pressure.

PTRL3002/5004 Numerical Solutions 3/3 30


Remarks for Jacobian Matrix

1. Calculation of each element in the Jacobian matrix requires many

computations. The size of the matrix is MxM (number of grid blocks

times the number of unknowns).

2. The Jacobian matrix must be evaluated and inverted for every

Newtonian iteration at every time step.

3. Direct or iterative methods can be used for the explicit formation,

depending on the problem and the convergence criterion.

4. For iterative methods, two iteration loops are required to solve a

single time-step: The inner iteration is the inversion of the matrix. The

outer iteration is the Newtonian iteration to successively reduce the

error in the estimate for the solution.

Numerical Solutions 3/3 31


Remarks for Jacobian Matrix

5. Newton iteration requires a good initial estimate of the solution at the

next time step ( n+ 1) and smooth derivatives to ensure convergence.

6. The accuracy of the initial estimate is controlled by the size of the

time step ( • t); the smaller • t the more accurate the estimate. This is

the criterion for setting the minimum time step-size. The maximum

time step size is determined by truncation error considerations.

7. Since the element of the Jacobian matrix require derivatives of fluid

and rock data, it is essential l that the input of B o, B g, R s, o, • g, k ro, k rw,

k rg, P cow, and P cgo be smooth.

Numerical Solutions 3/3 32


Ill-Conditioned Equation Systems

1.0 x • 2.0 y • 1.0 • 0.0

0.5 x • 4.0 y • 1.0 • 0.0

Numerical Solutions 3/3 33


Ill-Conditioned Equation Systems

Systems of equations which have the


characteristics of near parallel lines are
termed ill-conditioned and pose severe
convergence problems for iterative
schemes.

Increasing ill-conditioning makes difficult it


to ffobtain a sufficiently ff
accurate estimate for the solution at the next
the next
time time
level. level
This is the main reason for
non-convergence in reservoir simulation.

Numerical Solutions 3/3 34


Ill-Conditioned Equation Systems

Diagonally-dominant systems display good


convergence properties with Newton’s
method.

Amatrix is said to be diagonally dominant if


the value of the diagonal element is greater
than the sum of the off-diagonal elements

a ii • • ai,jj•
1, j • i

Numerical Solutions 3/3 35


Ill-Conditioned Equation Systems

This concludes that the greater the number of coefficients the more difficult it is to
maintain diagonal dominance.

It was previously shown that the Jacobian matrix depends on the number of
dimensions, the number of phases and the order of the difference equations.

1-D single-phase problem is therefore expected to give a diagonallydominant system


while methods result in more 3-D three-phase problems using higher-order
off-diagonal elements in the Jacobian matrix.

Numerical Solutions 3/3 36


Three-Phase Black Oil Model

PDEs
DISCRITIZATION
( 3 EQNS )

SET OF NON
NON-LINEAR
LINEARIZATION
NEWTON’S METHOD ( ALGEBRAIC EQNS
)
(3XM)

JACOBIAN MATRIX
( 3M X 3M )

Numerical Solutions 3/3 37


Three-Phase Black Oil Model

Flow chart for black oil simulator

Numerical Solutions 3/3 38


Three-Phase Black Oil Model

Flow chart for linear


solver

Numerical Solutions 3/3 39


Three-Phase Black Oil Model

Typical CPU time for black


oil simulator

Numerical Solutions 3/3 40


Three-Phase Black Oil Model

Guidelines for reducing simulator run times

1. Minimize the number of time-steps and time-step cuts. This can be done by setting a
max. • t which does not cause frequent time step cuts. This is determined by trial &
error.
2. Minimize the number of grid blocks. Avoid excessive detail in the reservoir model.

3. Reduce the number of Newton iterations. This can be done by loosening the
tolerance for convergence. Loosen tolerances on the linear solver.
4.
5. Make sure that all rock and fluid property input data monotonic are smooth ill
functions of pressure or saturation. This smooth derivatives. produce

PTRL3002/5004 Numerical Solutions 3/3 41

Anda mungkin juga menyukai