You are on page 1of 5

Journal of Petroleum Science and Engineering 73 (2010) 156160

Contents lists available at ScienceDirect

Journal of Petroleum Science and Engineering


j o u r n a l h o m e p a g e : w w w. e l s ev i e r. c o m / l o c a t e / p e t r o l

Estimation of sour natural gas water content


Yazdan Shirvany a, Gholamreza Zahedi b,, Mohsen Bashiri a
a
b

Dept. of Electronic, Faculty of Engineering, Razi University, Kermanshah, Iran


Process Systems Engineering Centre (PROSPECT), Faculty of Chemical and Natural Resources Engineering, Universiti Teknologi Malaysia, UTM Skudai, 81310 Johor Bahru, Johor, Malaysia

a r t i c l e

i n f o

Article history:
Received 14 January 2008
Accepted 28 May 2010
Keywords:
water content
natural gas
articial neural networks

a b s t r a c t
In this paper a new method based an articial neural network (ANN) for prediction of natural gas mixture
water content (NGMWC) is presented. H2S mole fraction, temperature, and pressure have been input
variables of the network and NGMWC has been set as network output. Among the 136 data set 80 data have
been implemented to nd best ANN structure. 56 data have been used to check generalization capability of
the best trained ANN. Comparisons show average absolute error (AAE) equal to 1.437 between ANN
estimations and unseen experimental data. ANNs also have been compared with two commonly used
correlations in gas industry. Results show ANN superiority to correlations. Especially in higher hydrogen
sulde content in spite of ANN good predictions there was considerable deviation between experimental
data and common correlations. The proposed ANN model is able to estimate NGMWC as a function of
hydrogen sulde composition up to 89.6 mol%, temperatures between 50 and 350 F and pressure from 200
up to 3500 psia.
2010 Elsevier B.V. All rights reserved.

1. Introduction
Water is mixture with natural gas from the reservoir, through
production and processing, and is concerned in transmission. Natural
gas reservoirs always have water associated with them; gas in the
reservoir is saturated by water. When the gas is produced water is
produced too from the reservoir directly. Other water produced with
the gas is water of condensation formed because of the changes in
pressure and temperature during production. In the transmission of
natural gas further condensation of water is troublesome (Sharma and
Campbell, 1969). It can increase pressure drop in the line and
frequently causes corrosion problems. Natural gas freshly obtained
from gas elds cannot be transported before it has been dried. When
natural gas is liqueed, residual amounts of the water would freeze out
and block valves. Moist natural gas also has a lower caloric value.
Highly pure, dry protective gases (e.g. nitrogen, argon) are essential for
many production processes in the chemical and technical industries.
For example, the use of dry protective gas increases the corrosion
resistance of a welding. Therefore, water should be removed from the
natural gas before it is offered to be transmitted in the pipeline. For
these arguments, the water content of sour gas could be important for
engineering attention. In a study of the water content of natural gases
Lukacs (1963) measured the water content of pure methane at 160 F
and pressures up to 1500 psia. Gillespie et al. (1984) predicted the

Corresponding author. Tel.: +60 7 5535583; fax: +60 7 5581463.


E-mail address: grzahedi@fkkksa.utm.my (G. Zahedi).
0920-4105/$ see front matter 2010 Elsevier B.V. All rights reserved.
doi:10.1016/j.petrol.2010.05.018

water content of methane in the range of 122 F to 167 F and for


pressures from 200 to 2000 psia. Sharma and Campbell (1969)
proposed a method for calculating the water content of sour gases,
originally designed for hand calculations, but it was slightly complicated. Bukacek suggested a relatively simple correlation for the water
content of sweet gas, based on using an ideal contribution and a
deviation factor. McKetta et al., published a chart for estimating the
water content of sweet natural gas. This chart has been modied
slightly over the years and has been reproduced in many publications
(GPSA, 1998). Ning et al. (2000) proposed a correlation based on
McKetta et al.'s chart. This correlation reveals how difcult it can be to
correlate something that is as seemingly simple as the water content of
natural gas. Maddox et al. (1988) developed a method for estimating
the water content of sour natural gas. His method assumes that the
water content of sour gas is the sum of three terms of sweet gas
contribution (methane, CO2 and H2S).
Most of the traditional methods work in the limited range of
pressure and temperature and they have a good accuracy in this
limited range, which is near the ideal equilibrium condition. But in the
high pressure and temperature, gases have nonlinear behavior that
these methods cannot predict the gas behavior (Carroll, 2002). The
ANN as a good nonlinear function approximator can simulate the
nonlinear functions with high accuracy (Zahedi et al., 2005, 2006). In
this paper the water content of the sour natural gas mixtures with
ANN method has been predicted. The results show the ANN's
capability to predict the measured data. We compare our results
with the other numerical and analytical methods, e.g., Wichert and
Bukacek. These comparisons conrm the superiority of the ANN

Y. Shirvany et al. / Journal of Petroleum Science and Engineering 73 (2010) 156160

157

whereas inputs to the neurons are given as,


ni = input signal to the ANN;

Ni

nj = wij oi + j ;

i=1
Nj

nk = wjk oj + k :

method. The outline of this paper is as follows: In Section 2 the ANN


concept is described. Section 3 provides results of the application of
ANN for sour gas water content estimation.
2. Articial neural networks
ANN is constructed as a massive connection model of a simply
designed computing unit, called neuron. Fig. 1 illustrates a simple
model of n-inputs single-output neuron. All the input signals are
summed up as z and the amplitude of the output signal is determined
by the nonlinear activation function f(z). In this study, the modied
sigmoid function f(z) given as follows is implemented for modeling
studies (Haykin, 1999):
f z =

kz

1e
:
1 + ekz

Here, Ni and Nj represent the numbers of the units belonging to


input and hidden layers, while wij denotes the synaptic weight
parameter which connects the neurons i and j. Threshold parameter
(bias) with respect to the neuron j is represented by j. In this research
the sigmoid function only in the hidden layer to realize smooth and
moderate responses of the ANN and the linear function for the output
layer. This architecture of ANN is a good function approximator
(Haykin, 1999). The overall response of the present network is given
as,
Nj

ok = wjk f
j=1

Ni

wij ni + j

i=1

Ni

nj = wij oi + j ;

ok = f nk ;

Nj

nk = wjk oj + k ;

10

 
oj = f nj :

11

j=1

ANN training is an optimization process in which an error function


is minimized by adjusting the ANN parameters (weights and biases).
When an input training pattern is introduced to the ANN, it calculates
an output. Output is compared with the real output (experimental
data) provided by the user. This difference is used by optimization
technique to train the network. The error function to be minimized in
our study is mean square error (MSE), Eq, and is given as below
(Haykin, 1999):
q

 
oj = f nj ;

+ k :

where:

i=1

In the limit of k = , as the slope approaches innity, f(z) behaves


like a threshold function. Here the sigmoid function with moderate
slope has been selected so that the network can output a continuous
range of values from 1 to 1, which brings the differentiability of the
network (Haykin, 1999). Multilayer perceptron (MLP) type network
with three layers, which has been used for various applications
(Zahedi et al., 2006; Haykin, 1999). Fig. 2 depicts the architecture of
the perceptron neural network. For clear notation, the indices i, j and k
for the units corresponding to input, hidden and output layers,
respectively have been used (see Fig. 2). Note also that ni and oi are
used to represent the input and output to the ith neuron, respectively.
Inputoutput properties of the neurons in each layer can be simply
expressed in mathematical term as (Haykin, 1999):
oi = f ni ;

j=1

Fig. 1. Basic model of multi-inputs one-output neuron.

E =

2
1 n 
yj oj
n j=1

where yj is the target data and oj is the output of the neural networks.
In our method the target data is the experimental data. In this

Fig. 2. Multilayer perceptron consisting input, hidden, and output layers.

158

Y. Shirvany et al. / Journal of Petroleum Science and Engineering 73 (2010) 156160


Table 2
Comparison of the ANN prediction results of the sour natural gas mixture water content
with the Wichert and BM methods.

Fig. 3. Performance of ANN based on number of hidden neurons.

research the network has been studied via the fast convergence
gradient-descend back-propagation method with momentum term
for the nonnegative energy function (Zahedi et al., 2009). According to
the gradient-descend algorithm with momentum the changes of the
weights and bias, wt, t through the minimization of the energy
function with respect to the weights wt, and bias, t, are as:
t

w =

Eq
t1
+ w ;
wt

10

Eq
t1
+ :
t

11

where , and t are the learning rate, momentum parameter and


number of iteration, respectively. The values of the learning rate and
momentum parameter are adaptively varied from 0 to 1 (Zahedi et al.,
2009; Yam and Chow, 2000).
3. Results and discussions
In this part of our study, the objective is to nd the optimal
performance ANN model for prediction of the water content. The MLP
architecture has been developed. The task was to nd the optimum
number of nodes in the hidden layer, which provides good estimates
of the output. The criterion for selection was MSE between network
output and training data. The results are illustrated in Fig. 3. In this
work, as illustrated in Fig. 3, the optimum number of hidden nodes
was found to be 302. In selecting data for modeling, and to ensure that
they represent normal operating ranges, off data were deleted from
the data list. The variables of the model and the operating ranges are
summarized in Table 1.
Data sets were collected from various components in this
simulation. For an ANN simulation of gas mixture water content,
data sets obtained by Ning et al. (2000), Lukacs (1963), and GPSA
Engineering Data Book (GPSA, 1998). These data sets are in wide range
of operating condition and suitable for achieving studies on the
behavior of natural gases.
Major components used in these references are: methane, propane,
hydrogen sulde, carbon dioxide and water. In this paper the analysis

H2S mol%

T (F)

P (psia)

Experimental

7.96
8.00
9.06
10.00
15.71
16.00
17.00
17.46
18.10
19.00
21.00
27.50
27.50
29.00
43.80
47.30
75.56
81.25
89.52

200.0
130.0
200.0
100.0
120.0
159.8
160.0
120.0
120.0
160.0
160.0
160.0
160.0
160.0
120
200
120
200
120

200
1500
200
1100
200
1395
1010
200
200
611
358
1392
1367
925
200
200
200
200
200

2835.0
111.0
2820.0
81.0
414.8
226.0
292.0
526.5
378.8
442.0
712.0
247.0
247.0
328.0
568.4
3087.0
559.1
2916.0
619.9

AAD%
Wichert
W.C (calc)
2506.0
116.0
2500.0
75.0
380.1
231.0
294.0
379.2
378.6
418.0
707.0
264.0
268.0
330.0
388.0
2462.0

BM

ANN

Div%

W.C (calc)

Div%

W.C (calc)

Div%

11.60
4.50
11.34
7.41
8.36
2.21
0.68
32.59
0.05
5.43
0.07
6.88
8.50
0.61
31.74

2866.0
113.0
2855.0
83.0
430.5
260.0
322.0
433.7
434.2
467.0
723.0
297.0
300.0
375.0
446.0

1.09
1.80
1.24
2.47
3.66
15.04
10.27
17.62
14.62
5.66
1.54
20.24
21.45
0.61
21.53

2890.0
113.0
2877.9
81.3
420.3
231.9
298.6
529.4
384.9
447.0
709.3
253.3
257.2
334.6
570.1

1.94
1.80
2.05
0.37
1.33
2.61
2.26
0.55
1.66
1.13
0.38
2.55
4.13
2.01
0.30
0.55

data are based on sour gas. 136 data sets were obtained. Among 136 data
sets 80 points were used for training the ANN and the remaining 56 data
sets were used for accuracy checks of the simulation. The input variables
of model and their operating ranges are as; hydrogen sulde
composition up to 89.6 mol% and is applicable for temperatures
between 50 and 350 F and pressure from 200 up to 3500 psia and

Table 1
ANN model variables and their ranges.
Variable

Range

H2S (mol%)
T (F)
P (psia)
Water content (lb/MMSCF)

7.9689.52
50350
2003500
40.63500

Fig. 4. Articial neural network prediction of gas mixtures water content, (lb/MMSCF).

Y. Shirvany et al. / Journal of Petroleum Science and Engineering 73 (2010) 156160

159

Fig. 5. Wichert prediction of gas mixtures water content, (lb/MMSCF).

nally the water content as output of ANN is in the range of 40.6 up to


3500 lb/MMSCF.
At low temperatures the water content is a function of temperature and pressure and is accurately predicted using the mathematical
methods. Wichert correlation is valid only for H2S up to 55 mol% in
sour gas mixtures. This only covers 68% of data of valid experimental
data. In this simulation of gas mixture water content we compared the
results of ANN by Wichert and BukacekMaddox (B.M). At this
comparison of B.M and Wichert could not predict sour natural gas
water content in a wide range of data (Wichert and Wichert, 1993;
Carroll (2002)). Table 2 provides generalization of proposed ANN
model (comparison of trained ANN with 56 unseen data) and also
comparison of ANN results with Wichert and BM correlations.
For measuring the accuracy of the method two types of
measurement errors have been dened:
1. Divergence: The error of each measurement is dened as:
Div% =



ValueApproximate
100
Value

12

where value is the experimental value used to construct the


model and Approximate is the output of the neural networks at the
same conditions. Regardless of the model, this error can have either a
positive or negative values. However the better result is convergence
of Div to zero.

2. Absolute Average Divergence (AAD) is dened as:


N

AAD% =

1 p j ValueiApproximatei j
100

Np i = 1
Valuei

13

Fig. 7. Prediction of gas mixture water content,(lb/MMSCF).

A scatter plot of measured water content against the ANN model


predictions is show in Fig. 4. The prediction, which match measured
unseen values, should fall on the diagonal line (line with intercept 0
and slope equal to 1). Almost all data lay on this line, which can
conrms the accuracy of the ANN model.
The data points are very close to the diagonal lines and this
conrms again the ANN can learn very well the relationships between
input and output data and generalized successfully. Good performance of ANN is obvious when it is compared to other models and
simulators. To check the performance of the ANN model, its
estimation and comparison with an existing simulator are available.
Figs. 5 and 6 provide the same comparison carried out in Fig. 4 with
Wichert and BM correlations respectively.
Fig. 7 compares methods at the range of 1000 to 3500 lb/MMSCF of
Water Content. Error of Wichert calculations at this area is more than
BM and ANN calculations.
4. Conclusions
In this paper ANN model is developed for prediction of natural sour
gas mixtures water content. The model is trained based on measured
(experimental) data for three various inputs, (H2S, pressure and
temperature). The difference between ANN model prediction and
validation data was very small which conrmed the ability of ANN to
accurately predict unseen data.
The ANN model was also compared with two numerical and
analytical models, Wichert and BukacekMaddox. The results showed
that the ANN model accuracy outperform the traditional simulators.

Where Np is the number of data.


References

Fig. 6. BukacekMaddox prediction of gas mixture water content, (lb/MMSCF).

Carroll, John J., 2002. The water content of acid gas and sour gas from 100 F to 220 F
and pressures to 10, 000 psia 81st Annual GPA Convention March 1113, 2002
Dallas, Texas, USA.
Gillespie, P.C., Owens, J.L., Wilson, G.M., 1984. Sour Water Equilibria Extended to High
Temperature and with Inerts Present AIChE Winter National Meeting, Paper 34-b,
Atlanta, GA, pp. 1114. Mar.
GPSA Engineering Data Book. Gas Processors Suppliers Association, Tulsa, OK.
Haykin, S., 1999. Neural Networks: A Comprehensive Foundation, 2nd. Prentice-Hall,
New York.
Lukacs, J.,1963. Water Content of Hydrocarbon Hydrogen Sulphide Gases, MSc Thesis,
Dept. Chem. Eng., University of Alberta, Edmonton, ABLukacs, J., Robinson, D.B.,
1962. Water Content of Sour Hydrocarbon Systems. Soc. Petrol. Eng. J. 3, 293297.
Maddox, R.N., Lilly, L.L., Moshfeghian, M., Elizondo, E., 1988. Estimating Water Content
of Sour Natural Gas Mixtures, Laurance Reid Gas Conditioning Conference, Norman,
OK. USA. Mar.
Ning, Y., Zhang, H., Zhou, G., 2000. Mathematical simulation and program for water
content chart of natural gas. Chem. Eng. Oil Gas 29, 7577.

160

Y. Shirvany et al. / Journal of Petroleum Science and Engineering 73 (2010) 156160

Sharma, S., Campbell, J.M., 1969. Predict natural-gas water content with total gas usage.
Oil & Gas J. 136137 Aug. 4.
Wichert, G.C., Wichert, E., 1993. Chart estimates water content of sour natural gas. Oil &
Gas J. 6164.
Yam, J., Chow, T., 2000. A weight initialization method for improving training speed in
feed-forward neural network. Neurocomputing 30 (219), 232.

Zahedi, G., Jahnmiri, A., Rahimpor, M.R., 2005. A neural network approach for prediction of
the CuOZnOAl2O3 catalyst deactivation. Int. J. Chem. Reactor Eng. 3 Article A8.
Zahedi, G., Fgaier, H., Jahanmiri, A., Al-Enezi, G., 2006. Identication and evaluation of
hydrotreater plant. Pet. Sci. and Tech. 24, 14471456.
Zahedi, G., Karami, Z., Lohi, A., 2009. A neural network approach for identication and
modeling of delayed cocking plant. Int. J. Chem. Reactor Eng. 7 article A16.

You might also like