0% found this document useful (0 votes)
8 views41 pages

Random Fields

The document is a manual for generating random fields and geostatistical modeling, authored by Dr. Ir. Amro Elfeki from TU Delft. It details the multi-variate normal random number generator, covariance matrix construction, and the Cholesky factorization method for simulating hydraulic conductivity fields. Additionally, it provides input and output data specifications for the MVG computer program used in the simulations.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
8 views41 pages

Random Fields

The document is a manual for generating random fields and geostatistical modeling, authored by Dr. Ir. Amro Elfeki from TU Delft. It details the multi-variate normal random number generator, covariance matrix construction, and the Cholesky factorization method for simulating hydraulic conductivity fields. Additionally, it provides input and output data specifications for the MVG computer program used in the simulations.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 41

MVG, NNG, TBG, GEOMARKOV

Manual for
Generation of Random Fields
and
Geostatistical Modelling
by

Dr. Ir. Amro Elfeki


Section Hydrology and Ecology,
Dept. of Water Management, Environmental
and Sanitary Engineering,
TU Delft, P.O. Box 5048, 2600 GA Delft,
The Netherlands.
Tel. +31-15-2784733,
Fax. +31-15-2785915.
E-mail: [email protected]

Version 3 (May.,2004)

-20

-40

0 20 40 60 80 100 120 140 160 180 200

-3.3 -2.3 -1.3 -0.3 0.7 1.7 2.7

Y=Log (K)

1
(i) Multi-Variate Normal Random Number Generator

A p-dimensional random vector Z = {Z1,Z2,Z3,...Zp}T is defined to have a multi-variate normal


distribution if and only if the p-components of Z have a uni-variate normal distribution. The
distribution of Z is denoted Np(µ,C). The multi-variate normal density function Np(µ,C), p-
dimensional normal random variate, is given by Mood and Graybill [1963],

1 ⎡ 1 ⎤
exp ⎢ - ( Z- µ ) C -1 ( Z-µ )⎥
T
f (Z) = 1/ 2 p/ 2
|C| ( 2π ) ⎣ 2 ⎦

where, Np(µ,C) is a multi-variate normal distribution with mean µ, and covariance matrix C,
p is the number of parameters (nodes of the model),
Z = {Z1, Z2,..., Zp}T, p-dimensional random vector, (p×1),
µ = {µ1, µ2,…, µ p}T , p-dimensional mean values vector, (p×1),
T is superscript transpose operation of a matrix,
-1 superscript is inverse operation of a matrix,
C is a pxp covariance matrix,

⎡ σ 2z1 Cov( Z 1 , Z 2 ) . . . . . Cov( Z 1 , Z p ) ⎤


⎢ ⎥
⎢ Cov( Z 2 , Z 1 ) σ 2z2 . . . . . Cov( Z 2 , Z p )⎥
⎢ . . . . . . . . ⎥
⎢ ⎥
⎢ . . . . . . . . ⎥
C =⎢ ⎥
. . . . . . . .
⎢ ⎥
⎢ . . . . . . . . ⎥
⎢ . . . . . . . . ⎥
⎢ ⎥
⎢Cov ( Z p , Z 1 ) Cov( Z p , Z 2 ) . . . . . σ 2z p ⎥
⎣ ⎦

⎮C⎮ is the determinant of the covariance matrix C, and


σ2Zi is the variance of the random parameter Zi.

0 Y

, , ,
1 2 3
X Z
, j
Z , s ij
i
p ,

Figure 0. Domain desceratization in Multi-variate method.

Sometimes it is convenient to normalize covariance matrices by converting the individual


covariance in terms of the correlation coefficient ρ ij as,

2
Cov( Z i , Z j )
ρ ij =
σZ σZ i j

where, Cov(Zi, Zj) = Cij is the covariance between Zi and Zj.

Generating Random Fields with a Given Covariance Matrix of The System:

1) Build the covariance matrix C of the system. The elements of C are denoted by,
2)
C ij = Cov ( Z i , Z j )

and if i=j covariances become variances.


If the random field is assumed to be statistically homogeneous (stationary), i.e., the mean is
constant, the standard deviation is constant, and the covariance depends only on the distance
vector between the points in the domain, then one can write the elements of the covariance
matrix as,
cij = σ 2 Z ρ ( sij )

where, σ2Z is the variance of the process Z,


ρ(sij) is the auto-correlation function, and
sij is the distance vector between point i and point j.
Substitution of the covariance equation into the elements of covariance matrix and dividing the
matrix by σ2Z, one can get the so-called correlation matrix, which takes the general form,

⎡ 1. ρ12 . . . . . ρ1 p ⎤
⎢ρ 1. . . . . . ρ 2 p ⎥⎥
⎢ 21
⎢ . . 1 . . . . . ⎥
⎢ ⎥
1 . . . . . . . . ⎥
R = 2 (C ij ) = ⎢ .
σZ ⎢ . . . . . . . . ⎥
⎢ ⎥
⎢ . . . . . . . . ⎥
⎢ . . . . . . . . ⎥
⎢ ⎥
⎢⎣ ρ p1 . . . . . . 1. ⎥⎦

where, ρij = cij/σ2Z is the correlation coefficient between point i and point j.

Properties of the correlation matrix:


1. All diagonal elements of the correlation matrix R are equal to one, which means that
the correlation between the point and itself is perfect (complete correlation).
2. If ρij = 0, this means no correlation between i and j.
3. All off- diagonal elements are called correlation coefficients and they are less than
one.
4. The correlation matrix is symmetric, i.e., ρij = ρji.
5. According to the stationarity assumption, the value of ρ12 = ρ23 =...= ρp-1p, the value of
ρ13 = ρ24 =...= ρp-2p, and so on.

The correlation matrix can be calculated for a certain random field given its auto-
correlation function as follows.

3
For pairs of values Zi and Zj with i = 1,...p and j = 1,...p determine (xi - xj) and (yi - yj)
where, (xi,yi) are the coordinates of point Zi and point (xj,yj) are the corresponding coordinates for
point Zj. The distance sij between two points is,
2 2
sij = ( xi - x j ) + ( yi - y j )
Types of correlation functions:

1. ρ(sij) is isotropic: one gets circular contours, which means that, it depends on the
magnitude of sij only.
2. ρ(sij) is anisotropic: one can get elliptic contours, which means that, it depends not
only on the magnitude of sij but also on the orientation of the vector sij.

For a known auto-correlation function one can determine all relevant values of ρij.

3) Decomposition of the covariance matrix by the Cholesky factorization method,

C=LU

where, L is a unique lower triangular matrix, U is a unique upper triangular matrix, and U
is LT which means that U is the transpose of L.

Cholesky method is sometimes called "Square-Root" method which is used only for the
decomposition of symmetric matrices. For more details about Cholesky method see Westlake
[1968]. In brief, the elements of the lower triangular matrix are given by,

ci1
l i1 = ,1 ≤ i ≤ p
c11
l ii = [cii - ∑k=1 l ik2 ] , 1 ≤ i ≤ p
i -1 1/2

l ij =
1
[c ij - ∑kj=1
-1
l ik l jk ] , 1 < j < i ≤ p
l jj

l ij = 0 , i< j ≤ p

3) Generation of normally distributed p-dimensional sequence of independent random


numbers with zero mean and unit standard deviation N(0,1) which can be expressed as,

ε = {ε1 , ε 2 ,...ε i ,..., ε p }T

where, ε is vector of normally distributed random numbers, and


ε i is the i-th random number drawn from N(0,1).

4) Multiplication of the independent random vector ε by the triangular matrix U to get a


vector of correlated random numbers. This vector can be expressed by matrix multiplication
convention as,

4
X =U ε

where, X is a vector of multi-variate normal random Np(0,I),


0 is zero mean vector (p×1), and
I is the identity matrix (p×p).

The desired random field is then obtained by


Z = µ+ X
The random process Z is the one for which the samples Z1, Z2,..., Zp are jointly distributed
according to a multi-variate probability density function.

The computer code is called MVG

MVG:

DIGITAL COMPUTER PROGRAM FOR SIMULATION OF RANDOM FIELDS. THIS


PROGRAM IS BASED ON MULTI-VARIATE NORMAL RANDOM NUMBER
GENERATOR WITH SPECIFIED CORRELATION STRUCTURE FOR THE LOG-
HYDRAULIC CONDUCTIVITY FIELD.
0

-1

-2

-3

-4

-5

-6

-7
Ly

-8

-9

-10

-11

-12

-13

-14

-15
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15

Lx
Figure 1. Domain dimensions and descritization.

AQUIFER PARAMETERS:

KXBAX =ARITHMATIC MEAN VALUE OF THE HYDRAULIC CONDUCTIVITY


IN X-DIRECTION, i.e., E(KX).
KYBAX = ARITHMATIC MEAN VALUE OF THE HYDRAULIC
CONDUCTIVITY IN Y-DIRECTION, i.e., E(KY).
RATIO = ANISTROPY RATIO,KYBAR/KXBAR
SDKX = STANDARD DEVIATION OF THE HYDR. COND. IN X-X.
SDKY = STANDARD DEVIATION OF THE HYDR. COND. IN Y-Y.
KX =RANDOM HYDR.CONDUCTIVITY VALUE IN X-DIRECTION.
KY =RANDOM HYDR.CONDUCTIVITY VALUE IN Y-DIRECTION.
ZKX = NATURAL LOGARITHM OF KX, i.e. ln(KX).
ZKY = NATURAL LOGARITHM OF KY, i.e. ln(KY).
MUX = ARITHMATIC MEAN OF ZKX, i.e. E(ln(KX)).
MUY = ARITHMATIC MEAN OF ZKY, i.e. E(ln(KY)).
SDZKX = STANDARD DEVIATION OF THE LOG HYDR. COND. IN X-
SDZKY = STANDARD DEVIATION OF THE LOG HYDR. COND. IN Y-

5
SIMULATION PARAMETERS:

GRID SIZE DIMENSIONS:


DX = DISCRETIZATION IN X-DIRECTION.
DY = DISCRETIZATION IN Y-DIRECTION.

DOMAIN DIMENSIONS:
LX = LENGTH OF THE DOMAIN IN X-DIRECTION.
LY = LENGTH OF THE DOMAIN IN Y-DIRECTION.

NO. OF GRID POINTS:


II = NUMBER OF GRID POINTS IN X-DIRECTION.
JJ = NUMBER OF GRID POINTS IN Y-DIRECTION.
NP = (II*JJ) NUMBER OF GRID POINTS IN THE MESH.

CORRELATION PARAMETERS:
LAMDAX = CORRELATION LENGTH IN X-DIRECTION.
LAMDAY = CORRELATION LENGTH IN Y-DIRECTION.
RXY = CORRELATION COEFFICIENT BETWEEN KX AND KY.

MC = NO. OF MONTE-CARLO RUNS.


SEED = SEED OF THE RANDOM NUMBER GENERATOR.
MCLASS = NO. OF CLASSES FOR CALCULATION OF PDF.

Input data for MVG:


MVG.dat: This file contains
10 20 KXBAR, SDKX
05 10 KYBAR, SDKY
0.2 6 RXY (value between 0 and 1), MCLASS
15 15 LX, LY
2 2 100 LAMDAX, LAMDAY, MC
1 1 DX, DY
1999999 20 12 SEED, IB, KNORM
0 0 2 -2 X1, Y1, X2, Y2

Relevant output data for MVG:

KX.GRD and KY.GRD


Data in these files are the generated hydraulic conductivity. They are also written in a
SURFER software format, so, it can be displayed by SURFER. A sample data is given here:

DSAA
93 141
0.0000000000 276.0000000000
-14.0000000000 0.0000000000
0.0001000000 864.0000000000
0.9999999747E-04 0.9999999747E-04 0.9999999747E-04 0.9999999747E-04
0.9999999747E-04 0.9999999747E-04 0.9999999747E-04 0.9999999747E-04

6
0.9999999747E-04 0.9999999747E-04 0.9999999747E-04 0.9999999747E-04
0.9999999747E-04 0.9999999747E-04 0.9999999747E-04 0.9999999747E-04
0.9999999747E-04 0.9999999747E-04 0.9999999747E-04 0.9999999747E-04
0.9999999747E-04
0.9999999747E-04 0.9999999747E-04 0.9999999747E-04 0.9999999747E-04
0.9999999747E-04 0.9999999747E-04 0.9999999747E-04 0.9999999747E-04
0.9999999747E-04 0.9999999747E-04 0.9999999747E-04 0.9999999747E-04
0.9999999747E-04 0.9999999747E-04 0.9999999747E-04 0.9999999747E-04
0.9999999747E-04 0.9999999747E-04 0.9999999747E-04 0.9999999747E-04
…….

7
Figure 2. 3D graphical display of Kx.grd and Ky.grd by surfer.

8
Figure 3. 3D graphical display of lnKx.grd and lnKy.grd by wire-frame in surfer

0 0

-2 -2

4 4
-4 3.5 -4
3.5
3
3 2.5
2.5 2
-6
2 -6 1.5
1.5 1
0.5
1
-8 -8 0
0.5 -0.5
0 -1
-0.5 -1.5
-10 -10
-1 -2
-2.5
-1.5 -3
-12 -2 -12 -3.5
-2.5 -4

-14 -14

0 2 4 6 8 10 12 14 0 2 4 6 8 10 12 14

Figure 4. 2D graphical display of lnKx.grd and lnKy.grd by contour in surfer

9
KX.dat and KY.dat
Data in these files are the generated hydraulic conductivity. They can be displayed by surfer.
The following is Kx.dat.

X Y K(X,Y)
0 0 0.28699
0 -1 0.124
0 -2 0.35436
0 -3 0.52029
0 -4 0.43376
0 -5 2.82339
0 -6 3.2875
0 -7 0.41146
0 -8 2.22913
0 -9 25.93681
0 -10 43.908
0 -11 16.6936
0 -12 16.32112
0 -13 2.46761
0 -14 8.78845
0 -15 3.88168
1 0 0.55741
1 -1 0.32082
1 -2 0.39515
1 -3 0.99136
1 -4 1.48065
1 -5 0.25476
1 -6 0.17868
1 -7 0.97759
1 -8 2.54657
1 -9 0.86342
1 -10 11.6818
1 -11 16.45898
1 -12 6.8163
30.88329
17.31905 42.75402
24.54117 32.30068
0.28699
0.55741 4.55303
0.67606 2.87417 1.05422
0.30428 6.31553
0.91244 11.75237 11.47101
0
67.8035
1.21027 10.3489 8.09313
2.35346 10.20065
5.34666
1.42068 20.53919
5.12404 11.23448 30.41061
8.69777
0.1240.32082 0.51062

34.90381
7.09925 20.79013
8.29183 15.94668
0.35436 2.21103
0.39515 1.48523
2.14791 2.41725 3.39635
1.06186 3.95855
0.50234
0.81607
-2
0.52029 1.240530.47061.30414.98365
0.99136 3.17875 6.10433
4.86354 2.48164
1.57271 3.09853
1.05312 5.57951
3.91638 5.63443

1.48065
0.43376 0.30544
0.21063
0.21507 1.77417
0.42634 11.5938
10.50685 11.58156
2.50022 5.21557
2.15537 26.73628
12.63803 1.11147
-4
2.82339 30.56805
3.156326.2773 3.80179
4.44101 3.65272
2.07862 8.108631.373
5.24909
0.25476 0.46403
0.15782 0.40068
0.37859

3.28750.17868
0.48668
0.88586
0.69966 3.99769
1.09454 1.36955 7.00725
6.02858
4.74742 1.07008
1.14008
0.97956
0.65337
1.39489
-6
0.97759
0.41146 0.44252 3.84575
1.06082
0.49245 21.5799
4.03731 14.05327
4.90209
2.796490.9570.59477
0.38689 1.65188
0.28631

2.54657
2.22913 1.61891
0.23542 13.19885
1.45117 9.903938.90955.07495
4.05737
2.09579
0.85158 1.417250.59947.8432
1.29644
-8
25.93681
0.86342 7.24654
2.76874
1.04765
0.30282 5.02196 10.62526
5.07274 2.12508
1.30898
1.42507 6.85438
4.752921.5960.88886

43.908
11.6818 4.96095
2.49902 3.80318
1.44676 2.13703 4.79206
2.08731 0.55931
0.42914 1.36096
0.39869 4.81038
0.91391
0.39142
-10
16.6936
16.45898 32.34987
9.83698 8.52594 3.21752
2.85126
1.035880.56541.90731
1.38666
0.59714 1.91535
2.04016 2.76398
1.01115

16.32112
6.81635.211261.13182.34658
1.31321 4.757912.30331.250921.66084.851721.926 1.12984.40591
0.94896
0.44073
-12
2.46761 6.71247
4.51375 1.24446
0.64885 2.48386
1.63322
0.80853 0.99505 7.68545
3.60753 2.76972
0.88426
0.74543 2.70342
0.63288

11.43681
8.78845 36.83797
32.3879 31.53325
4.49048
1.66288
1.34587
0.17252
0.92027 5.32333
0.67849 1.68710.91028
0.66496
1.15642
-14
21.196324.2612.43532
3.88168 1.14081 2.8762421.886
3.38088
0.20769 16.70758
11.20657
2.08603 1.289721.74687.86256
1.13734

0 2 4 6 8 10 12 14

AUTKX.GRD and AUTKY.GRD


Data in these files is the calculated auto-correlation of log-hydraulic conductivity from the
generated realization in Figure 4. They are also written in a SURFER software format, so, it

10
can be displayed by SURFER. A sample data is given here in Figure 5. The auto-correlation is
calculated by,

∑ [Z (i + s , j + s ][Z (i, j) - Z ]
m( sx ) n( s y )
1
Cov( s x , s y ) = ∑
m( s x )n( s y ) i =1 j=1
x y )-Z

Cov( s x , s y )
ρ ZZ ( s x , s y ) = 2
σ Z

Figure 5. 3D graphical display of autkx.grd and autky.grd ( (auto-correlation surfer of single


realization displayed above) by wire-frame in surfer.

RHOTH.GRD
Data in this file is the model auto-correlation of log-hydraulic conductivity. They are also
written in a SURFER software format, so, it can be displayed by SURFER. A sample data is
given here in Figure 6. Exponential auto-correlation is given in the program.

11
Figure 6. 3D graphical display of RHOTH.grd model auto-correlation surfer by wire-frame in
surfer.

E{AUTO}X.grd and E{AUTO}Y.grd


Data in this file is the ensemble auto-correlation of log-hydraulic conductivity. They are also
written in a SURFER software format, so, it can be displayed by SURFER. Figure 6 shows
this display.

Figure 6. 3D graphical display of E{AUTO}X.grd and E{AUTO}Y.grd of ensemble average


auto-correlation surface of lnKx and lnKy respectively by wire-frame in surfer.

12
0 0

-2 -2

15
23
-4 14 -4

13 21
12 19
-6 -6
11
17
10
9 15
-8 -8
8
13
7
6 11
-10 -10
5 9
4
7
-12 3 -12
2 5

-14 -14

0 2 4 6 8 10 12 14 0 2 4 6 8 10 12 14

Figure 7. 2D graphical display of E{KX}.grd and E{KY).grd of the ensemble average Kx


and Ky respectively by contour in surfer.

E{AUTO}X.grd and E{AUTO}Y.grd


Data in this file is the ensemble standard deviations of Kx and Ky respectively. They are also
written in a SURFER software format, so, it can be displayed by SURFER. Figure 8 shows
this display.
0 0

-2 -2

-4 -4

-6 -6

-8 -8

-10 -10

-12 -12

-14 -14

0 2 4 6 8 10 12 14 0 2 4 6 8 10 12 14

Figure 8. 2D graphical display of sigKX.grd and sigKY.grd the ensemble average sigkx over
the realizations and also for Ky by contour in surfer.

PROBXY.grd and NORMXY.grd


These files contain data about the experimental joint pdf of lnKx and lnKy form the generated
realization (PROBXY.grd) and the theoretical jpdf (NORMXY.grd). The results are displayed
in Figure 9.

13
8

Ln(Ky)
0

-2

-4

-6

-6 -4 -2 0 2 4 6 8

Ln(Kx)
Figure 9. 2D graphical display of the experimental jpdf and theoretical jpdf of Kx and Ky
(correlation coefficient =0.2).

KxKy.dat
This file contains scatter plot of Kx and Ky and lnkx and lnky

Kx Ky lnKx lnKy
0.28699 0.01812 -1.24832 -4.01051
0.124 0.40156 -2.08749 -0.91239
0.35436 0.83821 -1.03745 -0.17649
0.52029 4.72366 -0.65337 1.55258
0.43376 1.98411 -0.83526 0.68517
2.8233 0.97743 1.03794 -0.02283
3.2875 2.54384 1.19013 0.93368
0.41146 1.33061 -0.88803 0.28564
2.22913 4.1738 0.80161 1.42883
25.93681 11.34292 3.25566 2.42859
43.908 9.15263 3.7821 2.21404
16.6936 35.59773 2.81503 3.57228
16.32112 22.68975 2.79246 3.12191
2.46761 4.42012 0.90325 1.48617
8.78845 6.03772 2.17344 1.79803
3.88168 1.98559 1.35627 0.68592

14
50 4

40 2

30 0

lnKy
Ky

20 -2

10 -4

0 -6

0 20 40 60 80 -4 -2 0 2 4 6
Kx lnKx

Figure 10. Scatter plot of Kx and Ky (left) and lnKx ans lnKy (right) of the generated
realization. The data file is KXKY.dat.

Kx1Kx2.dat

KX1(0,0), KX1(2,-2), lnKX1(0,0), lnKX1(2,-2), KY1(0,0), KY1(2,-2), lnKY1(0,0)


lnKY1(2,-2)

0.287 2.211 -1.248 0.793 0.037 2.594 -3.29 0.953


25.691 3.158 3.246 1.15 117.1 1.569 4.764 0.45
17.669 6.33 2.872 1.845 2.967 0.424 1.087 -0.858
2.663 2.034 0.979 0.71 2.526 7.705 0.927 2.042
4.042 2.388 1.397 0.87 27.07 80.89 3.298 4.393
2.389 13.703 0.871 2.618 0.253 0.889 -1.38 -0.118
23.575 15.16 3.16 2.719 0.059 0.283 -2.83 -1.261
2.074 1.625 0.729 0.486 39.229 2.466 3.669 0.903
6 4

2
lnky(2,-2)

lnkx(2,-2)

-2

-4 -2

-4 -2 0 2 4 6 -8 -4 0 4 8
lnky(0,0) lnKx(0,0)

Figure 10. Scatter plot of lnKy at two locations (0,0) and (2,-2) (left) and lnKx at two
locations (0,0) and (2,-2) (right) of the generated realization.

15
Autkxx.dat, Autkxy.dat, Autkyx.dat, Autkyy.dat

Theses files contain the calculation of the autocorrelation function, auto-covariance function
and the theoretical auto-correlation function (exponential decay) versus lag for lnKx and lnKy
in x and y-directions respectively for the generated realization. The files have the following
format.

Lag exp_auto exp_covar theo_auto


0 1 1.72392 1
1 0.57239 0.98675 0.60653
2 0.30987 0.5342 0.36788
3 0.0746 0.12861 0.22313
4 -0.15067 -0.25974 0.13534
5 -0.23983 -0.41345 0.08208
6 -0.24733 -0.42637 0.04979

1.2
1.2
Realization Auto-correlation
Experimental Auto-coorlation of Ln(Kx) in Y-direction Realization Auto-correlation
Experimatal Auto-correlation of Ln(Ky) in Y-direction Experimental Auto-coorlation of Ln(Kx) in X-direction
Theoretical Auto-correlation Experimatal Auto-correlation of Ln(Ky) in X-direction
0.8 Theoretical Auto-correlation
0.8

0.4
auto-corrlation

0.4
auto-corrlation

0
0

-0.4
-0.4

-0.8
-0.8
0 4 8 12 16
Lag in Y 0 4 8 12 16
La g in X

Figure 11. Auto-correlation of lnKx and lnKy in y-direction (left) and auto-correlation of
lnKx and lnKy in X-direction (right) of the generated realization.

E{Auto}x.dat, E{Auto}y.dat
Theses files contain the calculation of the ensemble autocorrelation function versus lag for
lnKx and lnKy with its 95% confidence intervals in X-direction. And similarly for lnKx and
lnKy in y-directions. The files have the following format.

Lag autokxx autokxx+2sd autokxx-2sd autokyx autokyx-2sd autokyx-2sd


0 1 1.0003 0.9997 1 1 1
1 0.5664 0.649 0.4838 0.5535 0.6253 0.4817
2 0.3127 0.4152 0.2102 0.2954 0.3965 0.1943
3 0.1601 0.2636 0.0565 0.1464 0.2625 0.0303
4 0.0674 0.1866 -0.0519 0.0576 0.1658 -0.0505
5 0.0102 0.1448 -0.1244 0.0122 0.1292 -0.1048
6 -0.0304 0.1067 -0.1676 -0.0265 0.1011 -0.154
7 -0.048 0.0946 -0.1906 -0.0546 0.0876 -0.1967

16
1.2
1.2
Ensemble Auto-correlation
Ensemble Auto-correlation Ensemble Auto-coorlation of Ln(Kx) in X-direction
Ensemble Auto-coorlation of Ln(Ky) in X-direction e{auto}-2*sd of Ln(Kx) in X-direction
e{auto}-2*sd of Ln(Ky) in X-direction e{auto}+2*sd of Ln(Kx) in X-direction
e{auto}+2*sd of Ln(Ky) in X-direction Theoretical Auto-correlation
Theoretical Auto-correlation 0.8
0.8

auto-corrlation
auto-corrlation

0.4
0.4

0
0

-0.4
-0.4
0 4 8 12 16
0 4 8 12 16 Lag in X
Lag in Y

Figure 12. Ensemble auto-correlation of lnKx in Y-direction (left) and in X-direction (right)
respectively.
1.2
1.2
Ensemble Auto-correlation
Ensemble Auto-correlation Ensemble Auto-coorlation of Ln(Ky) in X-direction
Ensemble Auto-coorlation of Ln(Ky) in Y-direction e{auto}-2*sd of Ln(Ky) in X-direction
e{auto}-2*sd of Ln(Ky) in Y-direction e{auto}+2*sd of Ln(Ky) in X-direction
e{auto}+2*sd of Ln(Ky) in Y-direction Theoretical Auto-correlation
Theoretical Auto-correlation 0.8
0.8
auto-corrlation
auto-corrlation

0.4
0.4

0
0

-0.4
-0.4
0 4 8 12 16
0 4 Lag8in X 12 16 Lag in X

Figure 13. Ensemble auto-correlation of lnKy in Y-direction (left) and in X-direction (right)
respectively.

normalx.dat, normaly.dat
These files contain the normal density function with the given mean and variance.
Lnkx pdf
-6.98133 0
-5.66835 0
-4.35537 0.0001
-3.04239 0.00338
-1.72941 0.04112
-0.41642 0.18429
0.89656 0.30384
2.20954 0.18429
3.52252 0.04112

17
4.8355 0.00338
6.14848 0.0001
7.46146 0
8.77444 0

probx.dat and proby.dat


These files contain the calculated pdf from the generated realization for lnKx and LnKy
respectivley.

Lnkx experimental pdf number of data points in this class


-1.56215 0.05972 16
-0.51147 0.19035 51
0.53922 0.29859 80
1.5899 0.22394 60
2.64059 0.1269 34
3.69127 0.05225 14

0.4 0.4

pdf of Ky pdf of Kx
Theoretical pdf Theoretical pdf
Experimental pdf Experimental pdf

0.3 0.3

0.2 0.2

0.1 0.1

0 0

-8 -4 0 4 8 12 -8 -4 0 4 8 12

Figure 14. Experimental and theoretical pdf of lnKy (left) and lnKx (right) respectively.

Log-nx.dat, log-ny.dat
These files contain the lognormal density function with the given mean and variance.

Kx pdf
0.00093 0
0.00345 0.00033
0.01284 0.00794
0.04772 0.07073
0.17739 0.23181
0.6594 0.27948
2.45115 0.12396
9.11149 0.02023
33.86954 0.00121
125.90113 3E-005
0 0
0 0

18
0 0

probkx.dat and probky.dat


These files contain the calculated pdf from the generated realization for Kx and Ky
respectively.

Kx experimental pdf number of data in this class


5.76396 0.07619 220
17.04387 0.00727 21
28.32379 0.00346 10
39.60371 0.00139 4
50.88362 0 0
62.16354 0.00035 1
0.5 0.3

pdf of Ky pdf of Kx
Theoretical pdf Theoretical pdf
Experimental pdf Experimental pdf

0.4

0.2

0.3

0.2

0.1

0.1

0 0

0.001 0.01 0.1 1 10 100 0.001 0.01 0.1 1 10 100 1000

Figure 15. Experimental and theoretical pdf of Ky (left) and Kx (right) respectively.

STAT.RES
This file displays the input data given to the program.
------------------
ARITHMATIC MEAN OF KX, (m/day) = 10.00000
STANDARD DIVIATION OF KX,(m/day) = 20.00000
ARITHMATIC MEAN OF KY, (m/day) = 5.00000
STANDARD DIVIATION OF KY,(m/day) = 10.00000
ANISOTROPY RATIO = 0.50000

LOGARITHMIC TRANSFORMATION
--------------------------
ARITHMATIC MEAN OF ln(KX) = 1.49787
STANDARD DIVIATION OF ln(KX) = 1.26864
ARITHMATIC MEAN OF ln(KY) = 0.80472
STANDARD DIVIATION OF ln(KY) = 1.26864
CORR. COEFF. BET. ln(KX) & ln(KY) = 0.36521

19
SIMULATION PARAMETERS
---------------------
LENGTH OF AQUIFER (m) = 15.00000
DEPTH OF AQUIFER (m) = 15.00000
DISCRETIZATION IN X-DIRECTION (m) = 1.00000
DISCRETIZATION IN Y-DIRECTION (m) = 1.00000
CORRELATION LENGTH IN X-DIRECTION= 2.00000
CORRELATION LENGTH IN Y-DIRECTION = 2.00000
CORR. COEFF. BETWEEN KX AND KY = 0.20000
NO. OF MONTE-CARLO SIMULATIONS = 100

RANDOM NUMBER GENERATOR PARAMETERS


----------------------------------
SEED OF RANDOM NUMBER GENERATOR = 1999999
LENGTH OF COMPUTER WORD IN BITS = 20

20
(ii) Nearest Neighbour Method

Whittle Model: the value of the parameter at a given node is replaced by weighted average of
previous random values at the given node and few surrounding ones.

A generalized form proposed by Whittle [1954],

Z i = ∑Wij Z j + ε i
i≠ j

where, Zi is random variable satisfying the nearest neighbour relation,


εi is uncorrelated normal random number with
E( ε i ) = 0, and Var( ε i ) = σ i2 , i=1,2,...p, and
Wij are weighting coefficients.

N=2 N=3
i,j-1 ,
N=4 ,
i-1,j ,i,j ,i+1,j
,
i,j+1
Figure 00. Numbering system in the NNG and number of neighbours .

In case of the anisotropic first-order auto-regressive scheme

Z ij = α x ( Z i-1j + Z i+1j ) + α y ( Z ij -1 + Z ij+1 ) + ε ij

where, α x is an auto-regressive parameter expressing the degree of dependence of Zij on its two
neighbouring values in the horizontal direction, Zi-1j and Zi+1j, ( α x <1), and α y is an auto-
regressive parameter expressing the degree of dependence of Zij on its two neighbouring values
in the vertical direction, Zij-1 and Zij+1, ( α y < 1).

The scheme should be applied with modifications at the boundaries of the domain of interest
where necessary, because the blocks do not extend across the boundaries i.e. the equation will be
truncated near the boundary.

The model can be recanted in matrix notation as,


Z=WZ+ε
where, matrix W is called the p×p connectivity matrix, or the p×p spatial lag operator of
scaled weights, wkl.

The elements of the connectivity matrix wkl are defined as,


*
wkl
wkl =
N
where, k = 1,2,...p, l = 1,2,...p, and k ≠ l,
w*kl = αx if the blocks k and l are contiguous in the x-direction,
w*kl = αy if the blocks k and l are contiguous in the y-direction, and

21
w*kl = 0 otherwise, i.e., if k = l, or if blocks k and l are not contiguous, and
N is the total number of blocks surrounding block k, i.e.,

N=4 if block k is located inside the domain that is being modelled,


N=3 if block k is located on the boundary of the domain, and
N=2 if block k is located at a corner of the domain.

The scaling of N is required to ensure stationarity in the generated sequence of Zij values near the
domain boundaries because the model is truncated near the boundaries.

Z sequence ~ N(µZ, σz)

ε ~ N(µε, σε).

In order to simulate the predetermined standard deviation σz, one should start from a
random sequence ε with a standard deviation of one. This vector can be pre-multiplied by an
appropriate factor to yield the desired value of σz. This factor is denoted by η, so becomes,

Z = W Z + ηε

The Eq. can be solved for Z sequence as follows

Z = ( I - W ) ηε
-1

To determine the simulation parameter η, one can follow the procedure of Smith and Freeze
[1979] or the procedure of [Baker, 1984] as given in brief here. The auto-correlation matrix of
the process Z can be written as
E (ZZ T )
R=
σ z2
With some algebraic manipulations, one gets
1
R= V η 2.σ ε2
σ 2
Z

where, V = (I - W)-1.((I - W)-1)T = ((I - W).(I - W)T)-1

Let σε be equal to one, then


1 2
R= Vη
σ
2
Z
All the diagonal elements of R are equal to unity by definition, hence, by taking the trace (the
sum of the elements on the main diagonal of the square matrix) and solving the resultant scalar
equation for η gives,

η= σZ
Vm
where, Vm = tr V/p, and the symbol "tr" is the trace of the matrix, which is given by, tr V = Σ vii
, i = 1,..., p

22
The final nearest neighbour generator is obtained.

Z = ( I - W)
-1 σZ ε
Vm

where, the Z sequences have a mean of zero. By adding the constant µZ to each element of Z the
system of equations for the nearest neighbour model can be written as

Z = µ Z + ( I - W)
-1 σZ ε
Vm
The analysis of the covariance function describing the generated random field with
first-order dependence is approximately an exponential decay function Smith and Freeze
[1979]. By adjusting the number of neighbors (higher-order nearest neighbour models), the
weighting coefficients and the variance of the initial random independent parameters, it is
possible to approximately fit any given real covariance function as observed on the data.

The advantage of this technique is that at the beginning of any simulation the matrix (I -
W) must be inverted only once. For each realization of the process Z, the inverted matrix (I - W)-
1
is simply multiplied by the generated random vector ηε. The drawback of this method is
computing the inverse matrix.
There is a relation between the correlation length and the autoregressive parameters which is
given by,

α
λ=a
1− α
π
a= in case of 2 D
4

Input data for NNG:


NNG.dat: This file contains
10 20 KXBAR, SDKX
05 10 KYBAR, SDKY
0.0 6 RXY (value between 0 and 1), MCLASS
20 20 LX, LY
0.98 0.98 100 0<ALPHAX<1, <0ALPHAY<1, MC
1 1 DX, DY
1999999 20 20 SEED, IB, KNORM

Output data for NNG:


The output files are identical to the ones by MVG.

23
(iii) Turning Bands Method (TBM)

The turning bands method generates realizations of stationary, correlated, and


multidimensional Gaussian random field from a normal distribution with zero mean and a
specified covariance structure. The TBM was first proposed by Matheron [1973] and applied by
the Ecole des Mines de Paris [e.g. Journel, 1974; and Delhomme, 1979]. Its basic concept is to
transform a multidimensional simulation into the sum of a series of equivalent uni-dimensional
simulations [Mantoglou and Wilson, 1982].

Figure. Turning bands method.

The basic idea of the algorithm in brief is, generating two- and three-dimensional fields by
subsequent projection and combining values found from a series of one-dimensional simulations
along several lines radiating outward from an arbitrary origin in space. This procedure yields
discrete values or realizations of the random field.

TBM is a repetition of a two-step procedure:

- First, a realization of a random process with a prescribed auto-covariance function and


zero mean is generated on one line. The Cholesky decomposition method can be used
(but with much smaller correlation matrix dimensions) or by auto-regression methods,
like nearest neighbour.
- Second, orthogonal projection of the generated line process to each point in the simulated
two- or three-dimensional random field. The two steps are repeated for a given number
of lines and then a final value is assigned to each grid point in the field by taking a
weighted average over the total number of lines.

There are two main approaches for generating the one-dimensional line process in TBM:

- Space Domain Approach: proposed by Matheron and applied by Journal and Huijbregts
[1978] and Delhomme [1979]. This approach can handle only particular forms of auto-
correlation functions.
- Spectral (frequency) Domain Approach, STBM: implemented by Mantoglou and Wilson
[1982]. It is a more general approach that can handle a wide variety of two-dimensional

24
processes, multi-variate (cross-correlated) processes, as well as spatial averaged
(integrated) processes.

(a) Theoretical Background of TBM:

Let Zi(u), i = 1,..., L a set of N independent realizations of a one-dimensional, second


order stationarity stochastic process on a line u with an auto-correlation function ρ1(uo), where uo
is the spatial lag on the line. Then the values given by the relation,

L
1
Z s(x, y,z) =
L
∑ Z (u)
i =1
i

is a realization of a two- or three-dimensional process. The subscript s represents the term "
simulated" or " synthetic". The field generated by Eq.(2.106) has zero mean as well. The relation
between the auto-correlation function on the line process ρ1(uo) and the auto-correlation function
in the three-dimensional random field ρ(uo) is given by [for the derivation, refer to Mantoglou
and Wilson, 1982; and Mantoglou, 1987],
d
ρ 1 ( uo ) = [u o ρ ( u o )]
du o

and for two-dimensional field the relationship becomes,


ρ 1 ( u o ) du o π
s
∫0 = ρ ( s)
( s 2 - u o2 ) 2
where, s is the spatial lag in two-dimensional field.

It can be observed from Eq.(2.108) that, it is not easy to obtain ρ1(uo) directly as a function of
ρ(s). Sironvalle [1980] wrote [referenced by Baker, 1984] " This integral equation is too difficult
to solve, so we discard this (the TBM) method." Therefore, Mantoglou and Wilson [1982] used a
spectral method to generate uni-dimensional process along the lines for different types of auto-
correlation functions. In the following section this method will be given more attention.

(b) Spectral Turning Bands Method (STBM):

Generation of 2-D random fields by TBM needs the solution of the integral equation given by
Eq.(2.108). This integral equation cannot be directly expressed as a function of ρ(s). Particular
solutions can be found for certain two-dimensional auto-correlation functions [Mantoglou and
Wilson, 1982]. To circumvent this difficulty, an expression for the spectral density function of
the one-dimensional processes as a function of the radial spectral density function of the two-
dimensional process is used. This expression is given in Fourier space by,
2
σ Z S( ω )
S 1( ω ) =
2
This means, that the spectral density function of the uni-dimensional process S1(ω) along the
turning bands lines is given by one half of the radial spectral density function S(ω) of the two-
dimensional process multiplied by the variance of the two-dimensional process.

Steps used in implementing the STBM generator in simulating a two-dimensional random field
are given below:

25
(1) Generation of One-dimensional Uni-variate Process on The Turning Bands Line:

In the literature, there are two main techniques used for generation of the line process. The first,
is called the "Fast Fourier Transform" (FFT) algorithm, which can be used to construct a
complex process X(u) = Z(u) + i Y(u) given by Tompson, et al. [1989],

X(u) = ∫ allω eiω u dW( ω ) ≈ ∑all ω eiω u dW( ω j )


j

where, in the approximate form, X is the sum of a complex series of sinusoidal functions of
varying wavelength, each magnified by complex random amplitude with zero mean dW(ωj), ωj =
j.∆ω.

The second is the "Standard Fourier Integration" method. The real part of the complex
process X(u) is given by
Re X(u) = Z(u) = ∫ | dW( ω ) | cos(ω u + φ ω )
allω
can be used to develop a straightforward discrete approximation using positive frequencies,
M

Z i (u ) = ∑ | dW (ω j ) | cos(ω j u + φ j )
j =1

where, φj represents independent random angles which is uniformly distributed between 0 and
2π, M is the number of harmonics used in the calculations, ωj = (j - .5) ∆ω, j = 1,2,...M, and ∆ω is
the discretized frequency which is given by ωmax/M, and ωmax is the maximum frequency used in
the calculations.

The magnitude ⎮dW(ωj)⎮ is taken to be deterministic from the spectrum as,

| dW (ω j ) |= [4 S 1 (ω j ).∆ω ]
1/2

where, S1(ωj) is the spectral density function of the real process Z(u) on the line.

S1(ω) is assumed to be insignificant outside the region [-ωmax,+ωmax]. Substitution of this equation
into the previous equation gives the generator of the uni-dimensional process on line i as,

Z i (u ) = 2 ∑ [S 1 (ω j ).∆ω ] cos(ω j u + φ j )
M
1/2

j =1

This is the classical method proposed by Rice [1954]. The form of above equation is slightly
modified by Shinozuka and Jan [1972] to give,

Z i (u ) = 2 ∑ [S 1 (ω j ).∆ω ] cos(ω ′ j u + φ j )
M
1/2

j =1

where, ώj = ωj + δω
The frequency δω is a small random frequency added here in order to avoid periodicities. δω is
uniformly distributed between -∆ώ/2 and ∆ώ/2, where, ∆ώ is a small frequency, ∆ώ<<∆ω. ∆ώ is
taken equal to ∆ω/20 according to Shinozuka and Jan [1972].

26
This approach involves a discrete summation over frequency increments ∆ω up to a
maximum cutoff frequency of ωmax = M ∆ω. The method involves a larger computational effort
than FFT, but it is more flexible in the choice of the parameters, M, ∆ω, ∆u, ωmax and umax
[Tompson, et al., 1989].

(2) Distribution of The Turning Bands Lines and The Number of Lines:

Theory of TBM is based on an infinite number of lines. The lines are assumed to be
randomly oriented, as taken from a uniform distribution on a unit circle in 2-D space or sphere in
3-D space. It has been shown by Mantoglou and Wilson [1982] that by spacing the lines evenly
on the unit circle or sphere, with prescribed directions, the simulated correlation function
converges much faster to the theoretical function. Mantoglou and Wilson show that a number of
8 -16 lines is generally a satisfactory choice in isotropic auto-correlation function. In anisotropic
case, however, a larger number of lines might be required.

(3) Spectral Discretization:

A realization of the line process Zi(un) at point n on line i is constructed from a discrete
integration of a series of random components over all the frequency domain. The frequency
discretization ∆ω must be kept small enough to ensure a sufficient degree of accuracy, while the
number of harmonics M must be kept large enough to account for the contributions of the
spectral tail at ωmax = M ∆ω. Mantoglou and Wilson [1982] considered the case where M is
varying between 50 and 100 and ωmax is 40 times the correlation length of isotropic auto-
correlation function in both cases. They found that while the accuracy for M = 50 is poor at large
distances, the accuracy shown for M = 100 improves rapidly.

(4) Physical Discretization:

The physical increment ∆u used along the line should be chosen less than the domain
discretization ∆x, ∆y as a pragmatic rule of thumb in order to avoid some numerical problems
[Mantoglou and Wilson, 1982].

(5) Length of The Turning Bands Lines:

The minimum length of the line is determined by the orientation of the line and the size
of the simulation domain.

(6) Generation of The Simulated Field:

The construction of a simulated field Zs(x,y,z) will include the selection of a finite number
of lines L and their orientation, the discrete simulation of one-dimensional process Zi(u) on each
line, the subsequent projection of these values onto all simulation points x in the domain, and the
division of each sum at each point by L1/2 to yield Zs(x,y,z).

Input data for TBG:


TBG.dat: This file contains
2 4 KXBAR, SDKX
1 2 KYBAR, SDKY
0.0 6 RXY (value between 0 and 1), MCLASS
50 25 LX, LY

27
1.0 1.0 70 LAMBDAX, LAMBDAY, MC
0.25 0.25 DX, DY
80 3 0.1 0 No. of lines, Coefficient, disceretization on the line
process, switch to choose for random lines (1) or evenly spaced lines (0).
0.25 100 Dk (spectral discretization) , Max. Harmonics
1999999 20 12 SEED, IB, KNORM

Output data for TBG:


The output files are identical to the ones by MVG.

28
(iv) Coupled Markov Chain (CMC)

INTRODUCTION

At present a variety of techniques are available to characterize reservoir heterogeneity. Some


selected ones can be found in the literature of hydrogeology (see e.g. Neuman, 1984) and
reservoir engineering (see e.g. Haldorsen, and Damsleth, 1990 and Deutsch and Journel,
1992). Most of these techniques rely on the use of variogram or auto-covariance function to
describe the spatial structure of reservoir heterogeneity. An alternative to describe the spatial
structure is by the use of Markov chains. Markov chains are applied in geology to model
discrete variables such as lithologies or facies. The Markov chain model does not use
variograms or autocovariance functions to quantify the spatial structures as most of the
available models do. Instead, it uses conditional probabilities. Conditional probabilities have
the advantage that they are interpreted geologically much easier than variogram or auto-
covariance functions. This is the reason for their popularity in the geological community
(Davis, 1973).

This paper proposes an extension of the coupled Markov chain model, developed by
Elfeki, (1996) to characterize heterogeneity of natural formations, to conditioning on any number
of well data. The coupled Markov chain model is also an extension of the one-dimensional
Markov chain model used by Krumbein (1967) to synthesize a stratigraphic sequence. The
methodology is based on a Markov chain that is conditioned on the future states. The
conditioning is performed in an explicit way that makes it efficient in terms of computer time
and storage. In the next sections, the basic concepts of the classical one-dimensional Markov
chain and the coupled Markov chains theories are presented followed by the concept of
conditioning of Markov chain on the future states. Some applications on a hypothetical case
study and on real outcrop data are presented.

ONE-DIMENSIONAL MARKOV CHAINS

A Markov chain is a probabilistic model that exhibits a special type of dependence: given the
present the future does not dependent on the past. In formulas, let Z0, Z1, Z2,…, Zm be a sequence
of random variables taking values in the state space {S1, S2,…, Sn}. The sequence is a Markov
chain or Markov process if,

Pr( Z i = S k | Z i -1 = S l , Z i - 2 = S n , Z i -3 = S r ,..., Z 0 = S p ) =
(1)
Pr( Z i = S k | Z i -1 = S l ) =: plk ,

where the symbol '|' is the symbol for conditional probability.

Sl Sk Sq
0 1 2 i-1 i i+1 N

29
Figure 1. Numbering series of events for a one-dimensional Markov chain.

Transition Matrix and stationary probabilities

In one-dimensional problems a Markov chain is described by a single transition probability


matrix. Transition probabilities correspond to relative frequencies of transitions from certain state
to another state. These transition probabilities can be arranged in a square matrix form,

⎡ p11 p12 . . p1n ⎤


⎢p . . . . ⎥⎥
⎢ 21
p=⎢ . . plk . . ⎥
⎢ ⎥
⎢ . . . . . ⎥
⎢⎣ p n1 . . . p nn ⎥⎦

where plk denotes the probability of transition from state Sl to state Sk, and n is the number of
states in the system. Thus the probability of a transition from S1 to S1, S2, ..., Sn is given by p1l, l =
1,2,…, n in the first row and so on. The matrix p has to fulfil specific properties: (1) its elements
are non-negative, plk ≥ 0; (2) the elements of each row sum up to one or,

∑p
k =1
lk =1 (2)

The transition probabilities considered in the previous section are called single step transitions.
One considers also N-step transitions, which means that transitions from a state to another take
place in N steps. The N-step transition probabilities can be obtained by multiplying the single-
step transition probability matrix by itself N times. Under some mild conditions on the transition
matrix (aperiodicity and irreducibility), the successive multiplication leads to identical rows (w1,
w2…, wn). So the wk (k=1, 2,…, n) are given by

(N)
lim plk = wk (3)
N →∞

and are called stationary probabilities. The wk are no longer dependent on the initial state Sl. The
stationary probabilities may also be found by solving the equations,


l =1
wl plk = wk , k = 1 , ..., n (4)

subject to the conditions wk ≥ 0 and ∑k wk=1.

30
One-dimensional Markov Chain Conditioned on Future States

Consider a one-dimensional series of events that are Markovian (see Figure 1). The probability
of cell i to be in state Sk, given that the previous cell i-1 is in state Sl and cell N is in state Sq can
be expressed mathematically as

Pr ( Z i = S k | Z i −1 = S l , Z N = S q )

This probability can be written in terms of joint probabilities as,

Pr( Z i −1 = S l , Z i = S k , Z N = S q )
Pr ( Z i = S k | Z i −1 = S l , Z N = S q ) = (5)
Pr ( Z i −1 = S l , Z N = S q )

One can factorize the numerator of Eq. 5 leading to

Pr ( Z i = S k | Z i −1 = S l , Z N = S q ) =
Pr ( Z N = S q | Z i −1 = S l , Z i = S k ) Pr ( Z i −1 = S l , Z i = S k ) (6)
Pr ( Z i −1 = S l , Z N = S q )

By applying the Markovian property on the conditional probability in the numerator of Eq. 6,
one obtains

Pr ( Z i = S k | Z i −1 = S l , Z N = S q ) =
Pr ( Z N = S q | Z i = S k ). Pr ( Z i −1 = S l , Z i = S k ) (7)
Pr ( Z i −1 = S l , Z N = S q )

The joint distributions in the numerator and the denominator can be expressed in terms of
conditional probabilities and marginal probabilities as

Pr ( Z i = S k | Z i −1 = S l , Z N = S q ) =
Pr ( Z N = S q | Z i = S k ). Pr ( Z i = S k | Z i −1 = S l ). Pr ( Z i −1 = S l ) (8)
Pr ( Z N = S q | Z i −1 = S l ). Pr( Z i −1 = S l )

The conditional probabilities in Eq. 8 can be expressed in terms of the matrix p as

31
( N −i )
p kq plk
Pr ( Z i = S k | Z i −1 = S l , Z N = S q ) = (9)
plq( N −i +1)

where, pkq(N-i) is the (N-i)-step transition probability, plk(N-i+1) is the (N-i+1)-step transition
probability. Eq. 9 can be rearranged in the form

plk p kq( N −i )
plk q = (10)
plq( N −i +1)

where plk|q is our target, the probability of cell i to be in state Sk, given that the previous cell i-1
is in state Sl and the future cell N is in state Sq.

In Eq. 10 when cell N is far from cell i the terms plq(N-i+1) and pkq(N-i) will cancel because they
will almost be equal to the stationary probability wq. However, when we get closer to cell N,
its state will start to play a role and the simulation results will be influenced by the state at that
cell.

COUPLED MARKOV CHAIN THEORY

The coupled chain describes the joint behaviour of a pair of independent systems, each evolving
according to the laws of a classical Markov chain (Billingsley, 1995). Consider two Markov
chains (Xi), (Yi) both defined on the state space {S1, S2,..., Sn} and having the positive transition
probability defined as,

Pr( X i+1 = S k , Y i+1 = S f | X i = S l , Y i = S m) = plm ,kf (11)

The coupled transition probability plm,kf on the state space {S1, S2,..., Sn}×{S1, S2,..., Sn}is given
by,

plm ,kf = plk . p mf (12)

These transition probabilities form a stochastic matrix.

32
1,1 Nx,1
i,j-1
i-1,j i,j Nx,j

1,Ny Nx,Ny

Unconditional Coupled Markov Chain on the Right Boundary.

1,1 Nx,1
i,j-1
i-1,j i,j Nx,j

1,Ny Nx,Ny

Conditional Coupled Markov Chain on the Right Boundary.

Figure 2. Numbering system in two-dimensional domain for the coupled Markov chain.
Unconditional Markov chain (top) and conditional Markov chain on the states of the future
(bottom). Dark grey cells are known boundary cells, light grey cells are known cells inside the
domain (previously generated, the past), white cells are unknown cells. The future state used
to determine the state of cell (i,j) is cell (Nx, j).

Coupled Markov Chain on a Lattice

Two coupled one-dimensional Markov chains (Xi) and (Yi) can be used to construct a two
dimensional spatial stochastic process on a lattice (Zi,j). Consider a two dimensional domain of
cells as shown in Figure 2. Each cell has a row number j and a column number i. Consider also a
given number of geological materials say n. The geological materials are coded as numbers. The
word "state", in this text, describes a certain geological unit, lithology, or bedding type. The (Xi)
chain will describe the structure of the geological unit in the horizontal direction. We will write

plkh = Pr ( X i +1 = S k | X i = S l ) (13)

Similarly, the (Yi) chain will describe the structure in the vertical direction and we will write,

v
p mk = Pr (Y j +1 = S k | Yi = S m) (14)

The stochastic process (Zij) will be obtained by coupling the (Xi) and (Yi) chain, but
forcing these chains to move to equal states. Hence,

Pr ( Z i , j = S k | Z i −1, j = S l , Z i , j −1 = S m) =
(15)
C Pr( X i = S k X i −1 = S l ) Pr(Y j = S k Y j −1 = S m )

where C is a normalizing constant which arises by not permitting transitions in the (Xi) and (Yi)
chain to different states. Hence

−1
⎛ n ⎞
C = ⎜⎜ ∑ plfh . pvmf ⎟⎟ . (16)
⎝ f =1 ⎠

combining Eq. 15 and Eq. 16 the required probability is therefore

33
h v
plk . p mk
plm ,k := Pr( Z i , j = S k | Z i −1, j = S l , Z i , j −1 = S m ) = . k = 1,...n (17)
∑p
f
h
lf . pvmf

1 1 1 1

1 2 1 2
1 1 1 2 1 2 1 1

1 1 1 1

1 2 1 2
2 1 2 2 2 2 2 1

2 2 2 2

1 2 1 2
1 1 1 2 1 2 1 1

2 2 2 2

1 2 1 2
2 1 2 2 2 2 2 1

Allowed Transitions Excluded Transitions

Figure 3. Transition scheme in the two-state model.

As an example, suppose we have two chains that are operating on two different states coded as 1
and 2. The possible states at cell (i, j) given that the state of the previous cell (i-1, j) was 1, and
top cell (i, j-1) was in state 1 as well, are displayed in Figure 3 top row. It is possible that one
obtains the same state 1 or 2 from both chains as in the first two possibilities in Figure 3 top row,
or one could get different states from the chains as in the last two possibilities in the top row.
Here for example one has

h v
p11 . p 21
p12,1 = Pr( Z i , j = 1 | Z i −1, j = 1, Z i , j −1 = 2) = h v h v
. (18)
p11 . p 21 + p12 . p 22

Conditioning the Coupled Markov Chain on Two Wells

Since it is already not evident how to define a notion for “future” in two dimensions, it is not
straightforward to extend the conditioning of one-dimensional Markov chains on future states to
the coupled chain. We shall therefore mainly consider a very simple and computationally cheap
approximative way by performing conditioning of the horizontal chain first, and coupling the
conditioned horizontal chain with the vertical chain afterwards. The expression of the conditional
probability in the coupled chain, according to this way, given the cell on the right hand side
boundary is given by

Pr ( Z i , j = S k | Z i −1, j = S l , Z i , j −1 = S m , Z N x , j = S q ) =
(19)
C ' Pr( Z i , j = S k | Z i −1, j = S l , Z N x , j = S q ) . Pr ( Z i , j = S k | Z i , j −1 = S m)

Here C’ is a normalising constant as in Eq. 16.

34
By inserting the expression derived in Eq. 10 into Eq. 19 and proceeding as in the
previous section we obtain

h h ( N x −i )
plk . p kq
Pr ( Z i , j = S k | Z i −1, j = S l , Z i , j −1 = S m , Z N x , j = S q ) = C '
h ( N x −i +1)
. pvmk (20)
p kq

Computing C’ as in the previous section and cancelling the numerators we finally find

plm ,k q := Pr( Z i , j = S k | Z i −1, j = S l , Z i , j −1 = S m , Z N x , j = S q ) =


h h ( N x −i )
plk . p kq . pvmk (21)
, k = 1,...n.
∑p f
h
lf .p h ( N x −i )
fq .p v
mf

INFERENCE OF STATISTICAL PARAMETERS FROM

A GEOLOGICAL SYSTEM

This section is similar to the description given by Elfeki, (1996) for estimation of model
parameters from field observations. For the sake of completeness, parameter estimation is
explained once again in the present context. A Markov chain is completely described when the
state space, transition probabilities and initial probabilities are given. The initial probabilities will
be chosen equal to the stationary probabilities. We will not need to estimate an initial distribution
as we well do simulations conditioned on well log and surface data. For a geological system
represented by a Markov chain, one has to perform the following steps. Firstly, the set of
possible states of the system {S1, S2,…, Sn} must be defined. Secondly, the probability, plk, of
going from a state Sl to state Sk in one interval must be estimated. Finally, the stationary
probabilities wk are determined either by estimation from the data or by calculation from the
transition probabilities. In practical applications, transition and stationary probabilities of a
geological system can be estimated from well logs, bore holes, surface and subsurface mapping
or from geological image synthesized by information derived from geologically similar sites or
analogous outcrops. The estimation procedure is given below.

Estimation of Transition Probabilities

v
v T lk
plk = (22)
n


q =1
T lq
v

The vertical transition probability matrix can be estimated from well logs. The tally matrix of
vertical transitions is obtained by superimposing a vertical line with equidistant points along the
well with a chosen sampling interval. The transition frequencies between the states are calculated
by counting how many times a given state say Sl is followed by itself or the other states say Sk in
the system and then divided by the total number of transitions,

where Tlkv is the number of observed transitions from Sl to Sk in the vertical direction.

35
Similarly, the horizontal transition probability matrix can be estimated from geological
maps. Maps that shows formation extensions in the horizontal plane may be obtained from
geological survey. On the map plan, a transect is defined where the subsurface profile is
required. On the transect, a similar procedure is performed as in the case of vertical
transitions. A horizontal line with equidistant points at a proper sampling interval for the
horizontal direction is superimposed over the map. The transitions between different states are
counted and the horizontal transition probability matrix is computed using Eq. 25 with
superscript h instead of v.

Estimation of the Sampling Intervals

Estimation of the proper sampling intervals is a trial and error procedure. There is no specific
rule. Perhaps the proper sampling interval in the vertical direction would be less than or equal to
the minimum thickness of the geologic unit found in the well log in order to be reasonably
reproduced in the simulation. Similarly, the proper sampling interval in the horizontal direction
would be less than or equal to the minimum length of a geological unit found in the planar
geological map.

THE ALGORITHM

A procedure for Monte-Carlo sampling to implement this methodology is presented. Refer to


Figure 2 during the description of the algorithm. The procedure for conditional simulation on
two neighbouring wells is as follows:

Step 1: The two dimensional domain is discretized using proper sampling intervals.

Step 2: Well data is inserted in their locations at the well on the left side of the domain at
(1, j), j = 2,..., Ny, the well at the right side of the domain at (Nx ,j), j = 2,..., Ny, and the top surface
information at location (i,1), i = 1,..., Nx.

Step 3: Generate the rest of the cells inside the domain that is numbered (i, j), i = 2,..., Nx-
1 and j = 2,..., Ny row-wise using the conditional distribution Pr (Zi,j = Sk | Zi-1,j = Sl, Zi,j-1 = Sm,
ZNx,j = Sq), given that the states at (i-1, j), (i, j-1) and (Nx, j) are known. The four-index
conditional probability plm,k|q is calculated by Eq. 21. From state Sl at the horizontal neighbouring
cell (i-1, j), Sm at the vertical neighbouring cell (i, j-1) and the state Sq at the cell on the right hand
side boundary (Nx, j) one can determine the succeeding state Sk at cell (i, j). We simulate a state
for Sk according to the distribution given by (plm,r|q: r=1,…n).

Step 4: The procedure stops after having visited all the cells in the domain between the
two given wells at i=1 and i= Nx.

Step 5: The same procedure is followed for the next two wells and so on until the domain
is filled with the states.

36
Input data file for GEOMARKOV:

Georeal: This file contains


3, 9991, 1 No. of states, Seed, no. of realizations to be generated (max. 99)
100., 30. LX, LY
10., 0.5 DX, DY

0.70 0.15 0.15 3x3 Horizontal transition probability matrix


0.15 0.70 0.15
0.15 0.15 0.70

0.34 0.33 0.33 3x3 Vertical transition probability matrix


0.34 0.33 0.33
0.34 0.33 0.33

Outcrop data files for GEOMARKOV:

Geosec01.grd up to Geosec99.grd: These files contain realizations of the geological sections.


The values of that file is just integer numbers representing the states of the geological system.
One of them is presented in the figure below (Using Surfer image option).
3

-10
Depth (m)

-20 2

-30
0 10 20 30 40 50 60 70 80 90 100
Longitudinal direction (m)

1
Figure .Geological realization generated by the GEOMARKOV.exe using the data presented in
the table.

Gmodel.res
This file contains the input data for the model and some statistics of one generated realization
(This file can be opened by “notpad”).

***********************************
* Input Data for Geological Model *
***********************************
Length of The Given Section (m)= 100.0000

37
Depth of The Given Section (m)= 30.00000
Sampling interval in X-axis (m)= 10.00000
Sampling interval in Y-axis (m)= 0.5000000
No. of States = 3
Seed = 9991
-------------------------------------
****************** ************************
*Input Statistics* *Calculated Statistics *
****************** ************************
Horizontal Transition Probability Matrix
0.700 0.150 0.150 0.708 0.162 0.130
0.150 0.700 0.150 0.108 0.716 0.176
0.150 0.150 0.700 0.145 0.131 0.724
Vertical Transition Probability Matrix
0.340 0.330 0.330 0.370 0.280 0.350
0.340 0.330 0.330 0.227 0.369 0.404
0.340 0.330 0.330 0.315 0.340 0.345
Marginal Probabilities of The States
State......Marginal Prob.............Marginal Prob.
from Transitions from Model
1 0.30236 0.29955
2 0.33386 0.33681
3 0.36378 0.36364

Geo.res
This file contains the input transition probabilities and their cumulative distributions (This file
can be opened by “notpad”).

***********************************
* Input Data for Geological Model *
***********************************
Length of The Given Section (m)= 100.0000
Depth of The Given Section (m)= 30.00000
Sampling interval in X-axis (m)= 10.00000
Sampling interval in Y-axis (m)= 0.5000000
No. of States = 3
Seed = 9991
-------------------------------------
***********************************
* Input Statistics for The Model *
***********************************
Horizontal Transition Probability Matrix
0.70000 0.15000 0.15000
0.15000 0.70000 0.15000
0.15000 0.15000 0.70000
HL. Cumulative Transition Prob. Matrix
0.70000 0.85000 1.00000
0.15000 0.85000 1.00000
0.15000 0.30000 1.00000

38
Vertical Transition Probability Matrix
0.34000 0.33000 0.33000
0.34000 0.33000 0.33000
0.34000 0.33000 0.33000
VL. Cumulative Transition Prob. Matrix
0.34000 0.67000 1.00000
0.34000 0.67000 1.00000
0.34000 0.67000 1.00000

Statist.dat
This file contains the computed transition probabilities and marginal probabilities form the first
generated realization and its cumulative distribution (This file can be opened by “surfer”)..

****************************************
*Calculated Statistics from The Single Realization*
****************************************
Horizontal Transition Probability Matrix
0.69469 0.17257 0.13274
0.19588 0.63918 0.16495
0.17895 0.13158 0.68947
HL. Cumulative Transition Prob. Matrix
0.69469 0.86726 1
0.19588 0.83505 1
0.17895 0.31053 1
Vertical Transition Probability Matrix
0.35628 0.35628 0.28745
0.39109 0.27228 0.33663
0.36967 0.28436 0.34597
VL. Cumulative Transition Prob. Matrix
0.35628 0.71255 1
0.39109 0.66337 1
0.36967 0.65403 1
Marginal Probabilities of The States
State......Marginal Probability
1 0.37407
2 0.30849
3 0.31744

P123.res
This file contains the coupled chain probabilities of both vertical and horizontal chains (This file
can be opened by “notpad”).

0.23800 0.04950 0.04950


0.05100 0.23100 0.04950
0.05100 0.04950 0.23100
0.23800 0.04950 0.04950
0.05100 0.23100 0.04950
0.05100 0.04950 0.23100
0.23800 0.04950 0.04950
0.05100 0.23100 0.04950

39
0.05100 0.04950 0.23100
0.70623 0.85312 1.00000
0.15385 0.85068 1.00000
0.15385 0.30317 1.00000
0.70623 0.85312 1.00000
0.15385 0.85068 1.00000
0.15385 0.30317 1.00000
0.70623 0.85312 1.00000
0.15385 0.85068 1.00000
0.15385 0.30317 1.00000

PIIT.DAT
This file contains some statistics about the average thickness of the generated layers and its
standard deviations.

State 1-pvii < thickness>/Lx sd_thickness/< thickness>


1 0.66 0.01283 3.75248
2 0.67 0.01135 3.61262
3 0.67 0.01268 3.48106

PIIW.DAT
This file contains some statistics about the average widths of the generated layers and its
standard deviations.

State 1-phii < width>/Lx sd_width/< width>


1 0.3 2.67021 1.05698
2 0.3 2.49398 1.08053
3 0.3 2.59756 1.11002

HCURVE.DAT

VCURVE.DAT

40
0

-20

-40

0 20 40 60 80 100 120 140 160 180 200

0 0

-20 -20

-40 -40

0 20 40 60 80 100 120 140 160 180 200 0 20 40 60 80 100 120 140 160 180 200

0 0

-20 -20
4

-40 -40

0 20 40 60 80 100 120 140 160 180 200 0 20 40 60 80 100 120 140 160 180 200

0 0 3

-20 -20

-40 -40
2
0 20 40 60 80 100 120 140 160 180 200 0 20 40 60 80 100 120 140 160 180 200

0 0

1
-20 -20

-40 -40

0 20 40 60 80 100 120 140 160 180 200 0 20 40 60 80 100 120 140 160 180 200

0 0

-20 -20

-40 -40

0 20 40 60 80 100 120 140 160 180 200 0 20 40 60 80 100 120 140 160 180 200

Figure 4. Hypothetical example (with four different lithologies) showing how the method
works when conditioning on more than two wells is performed. Top left is the "real" reservoir
and all the next rows show the well locations and lithologies observed at each well (on the left
of the figure). The corresponding stochastic simulations (single realisations) conditioned on
these wells are shown on the right hand side of the

41

You might also like