Carbon dioxide compressibility factor determination using a robust intelligent method

Carbon dioxide compressibility factor determination using a robust intelligent method

G Model ARTICLE IN PRESS SUPFLU 3278 1–10 J. of Supercritical Fluids xxx (2015) xxx–xxx Contents lists available at ScienceDirect The Journal of ...

2MB Sizes 0 Downloads 82 Views

G Model

ARTICLE IN PRESS

SUPFLU 3278 1–10

J. of Supercritical Fluids xxx (2015) xxx–xxx

Contents lists available at ScienceDirect

The Journal of Supercritical Fluids journal homepage: www.elsevier.com/locate/supflu

Carbon dioxide compressibility factor determination using a robust intelligent method

1

2

Q1

3

Erfan Mohagheghian a , Alireza Bahadori b,∗ , Lesley A. James a a

4

b

5

Faculty of Engineering and Applied Science, Memorial University of Newfoundland, St. John’s, NL, Canada Southern Cross University, School of Environment, Science and Engineering, Lismore, NSW, Australia

6

7 20

a r t i c l e

i n f o

a b s t r a c t

8 9 10 11 12 13

Article history: Received 26 December 2014 Received in revised form 22 March 2015 Accepted 23 March 2015 Available online xxx

14

19

Keywords: Carbon dioxide Compressibility factor Supercritical fluids Least square support vector machine

21

1. Introduction

15 16 17 18

Owing to the demanding applications and wide uses of supercritical carbon dioxide in oil, gas and chemical industries, fast and precise estimation of carbon dioxide compressibility factor is of a vital significance in order to be imported into the relevant industrial simulators. In this study, a data bank covering wide range of temperature and pressure was gathered from open literature. Afterwards, a rigorous novel approach, namely least square support vector machine (LSSVM) optimized with coupled simulated annealing (CSA) was proposed to develop a reliable and robust model for the prediction of compressibility factor of carbon dioxide. Reduced temperature and pressure are the inputs of the model. 80% of the dataset was used for training the model and the remaining 20% was used to evaluate its accuracy and reliability. Statistical and graphical error analyses have been conducted to investigate the performance of the model and the obtained results from the proposed model have been compared with those of six equations of state, REFPROP package and two correlations. It was demonstrated that the proposed CSA–LSSVM model is more efficient and reliable than all of the studied empirical correlations, equations of state and the software package, hence it can be utilized confidently for the prediction of carbon dioxide compressibility factor. © 2015 Published by Elsevier B.V.

Q2 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38

Supercritical carbon dioxide, as the most commonly used supercritical fluid, has been used in polymer processing as a solvent, anti-solvent or plasticizer which reduces the system viscosity and allows lower temperatures of the process. The low temperature sterilization technology by means of supercritical CO2 can be incorporated in removing hazardous contaminants in food and pharmaceutical industries. It can be utilized as a cleaning agent in micro-electronics, for continuous hydrogenation, as a solvent in oxidation processes and also can be combined with biocatalysts to enhance their activity and stability [1]. Moreover, it has been used for more than thirty years in enhanced oil recovery which can be combined with carbon sequestration in mature oil fields [2,3] and also has found some applications as a refrigerant [2] and a working fluid in gas turbines providing high efficiency [4]. The compressibility factor (Z-factor) of CO2 is vital in most chemical engineering calculations and design of processing units

∗ Corresponding author. Tel.: +61 0422789572; fax: +61 266269857. E-mail address: [email protected] (A. Bahadori).

due to its effect on mathematical models and also in oil and gas industry for CO2 compression, design of pipeline, material balance calculations and surface facilities design [5]. Compressibility factor as a thermodynamic property is obtained via experimental laboratory procedures. Experimental measurements are usually expensive, time consuming and cumbersome [6], and while there is lack of experimentally measured data, engineers would have to determine them through equations of state (EOS’s) or experimentally derived correlations [7]. The challenge with equations of state is that they are all implicit in terms of Z-factor. The compressibility factor has to be determined as the EOS root which yields the minimum free Gibbs energy. The mathematical approach to determine Z-factor is lengthy and requires proper root selection which adds to numerous engineering calculations [8]. An extremely large number of carbon dioxide Zfactors is required in the simulation of CO2 injection as an enhanced oil recovery method in oil reservoirs or for the purpose of CO2 sequestration and the large number of root selections adds to the simulations run time. Correlations are usually faster and much easier to use [6]; however, they sometimes involve multiple steps and complicated calculations and are limited to the data for which the correlation was formulated [9]. A small error in Z-factor will be propagated in the prediction of other properties such as gas

http://dx.doi.org/10.1016/j.supflu.2015.03.014 0896-8446/© 2015 Published by Elsevier B.V.

Please cite this article in press as: E. Mohagheghian, et al., Carbon dioxide compressibility factor determination using a robust intelligent method, J. Supercrit. Fluids (2015), http://dx.doi.org/10.1016/j.supflu.2015.03.014

39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61

G Model SUPFLU 3278 1–10

E. Mohagheghian et al. / J. of Supercritical Fluids xxx (2015) xxx–xxx

2 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96

97

ARTICLE IN PRESS

isothermal compressibility, gas formation volume factor for carbon storage calculations and thermal conductivity of supercritical carbon dioxide [10]. According to the above, the need is felt to find a fast and reliable method which can predict the compressibility factor of supercritical carbon dioxide quickly and accurately. Recently, support vector machine (SVM) as a supervised learning algorithm has been a tool for classification and regression analysis. It has found applications in PVT properties estimation, determination of porosity and permeability from log data, text categorization, protein classification in medical science, etc. In a modified version of support vector machine, namely least square support vector machine (LSSVM), the inequality constraint is replaced by an equality, which eliminates the necessity of solving a difficult quadratic programming problem. The LSSVM has shown high capability in solving nonlinear and complex problems and it has been applied for the prediction of several chemical properties of oil and gas [11–17]. To the best of the authors’ knowledge, this method has not yet been applied for the prediction of the Z-factor of CO2 . In this study, a collection of 178 data points for the compressibility factor of supercritical carbon dioxide as a function of temperature and pressure up to 1273.15 K and 50 MPa has been gathered from the literature [18]. Afterwards, least square support vector machine (LSSVM) has been applied to predict the Z-factor of CO2 and coupled simulated annealing (CSA) has been utilized as an optimization technique to determine the LSSVM hyper-parameters. Next, statistical and graphical error analyses have been conducted to measure the accuracy and reliability of the model, and finally, the results have been compared with six equations of state, namely Peng–Robinson EOS, Redlich–Kwong EOS, Soave–Redlich–Kwong EOS, Schmidt–Wenzel EOS, Patel–Teja EOS, and Lawal–Lake–Silberberg EOS, a software package named REFPROP developed by NIST as well as two correlations, namely Bahadori–Vuthaluru correlation and the Virial coefficients correlation. 2. Compressibility factor

106

Gas compressibility or deviation factor (Z-factor) is defined as the ratio of the actual volume to the ideal volume and is an indication of the gas deviation from ideal behaviour. Some thermodynamic properties such as density, isothermal compressibility and viscosity can be calculated by means of Z-factor. According to the law of corresponding states proposed initially by van der Waals, all gases behave the same at the same reduced pressure Pr and reduced temperature Tr [6]. In the mathematical form:

107

Z = f (T r , Pr )

108

where

109

Tr =

T Tc

(2)

110

P Pr = Pc

(3)

98 99 100 101 102 103 104 105

(1)

114

where Tc and Pc are the temperature and pressure at the critical point, respectively. The compressibility factor of a pure gas or gas mixture can be estimated by means of either equations of state or empirical correlations.

115

2.1. Equations of state

111 112 113

116 117

Several equations of state have been developed to calculate PVT properties of gas systems. The van der Waals type equations of state

which are normally used in petroleum industry can be expressed in the following general format: P=

RT

v−b



a

(4)

v2 + uv − w2

The above general equation can be rewritten in terms of compressibility factor as a cubic equation for calculation of volumetric behaviour:



Z 3 − (1 + B − U) Z 2 + A − BU − U − W



− AB − BW 2 − W

 2

 2

Z

=0

aP (RT )2

119

120

121 122 123

124

(5)

where dimensionless parameters A, B, U and W are functions of only pressure and temperature for a pure substance and are defined as follows: A=

118

125

126 127 128

(6)

129

B=

bP RT

(7)

130

U=

uP RT

(8)

131

(9)

132

W=

wP RT

where the parameters a and b are expressed by

133

a = ˝a

R2 Tc2 ˛ (T r , ω) Pc

(10)

134

b = ˝b

RTc Pc

(11)

135

where ˛ is the temperature dependency term, ω is the acentric factor, ˝a and ˝b are the generalized coefficients of the parameters in the original van der Waals equation which can be constant or functions of acentric factor and critical compressibility factor in the modified equations of state [19]. Six of widely used equations of states consisting of Redlich–Kwong (RK) [20], Soave–Redlich–Kwong (SRK) [21], Peng–Robinson (PR) [22], Schmidt–Wenzel (SW) [23], Patel–Teja (PT) [24] and Lawal–Lake–Silberberg (LLS) [25] equations of state are reviewed in Section A in the Supplementary information. In 1996, Span and Wanger derived an EOS specifically for CO2 by applying modern strategies for the optimization of the mathematical form of the EOS and for the simultaneous nonlinear fit to the experimental data. This EOS covers the wide temperature and pressure range of 216 K (triple point of CO2 ) to 1100 K and 0 to 800 MPa, respectively, is an empirical representation of the fundamental equation explicit in Helmholtz free energy as a function of density and temperature and is claimed to be accurate [26]. The drawback of this EOS for calculation of Z-factor making it improper for engineering purposes is first that it is implicit in density. As the result, to calculate density and then Z-factor, the function should be inverted and since there is no analytic form for that, an iterative method such as Newton’s method should be employed and an initial guess for density should be made for the pressure to converge in an iterative procedure. Apart from that, the derivative of the Helmholtz energy must be calculated and there are many coefficients and exponents in the equation (more than 180). These features make the computational procedures lengthy and unreasonable to be employed as an engineering tool. The fundamental equations and the equations for density calculation can be viewed in Section A in the Supplementary information as well.

Please cite this article in press as: E. Mohagheghian, et al., Carbon dioxide compressibility factor determination using a robust intelligent method, J. Supercrit. Fluids (2015), http://dx.doi.org/10.1016/j.supflu.2015.03.014

136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166

G Model

ARTICLE IN PRESS

SUPFLU 3278 1–10

E. Mohagheghian et al. / J. of Supercritical Fluids xxx (2015) xxx–xxx 167

168 169 170 171 172 173 174 175

2.2. Empirical correlations

3. Model development

177

3.1. Data gathering

178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199

200

201 202 203 204 205 206 207 208 209 210

211

212 213 214 215 216 217

Subjected to the following constraints:

Empirical correlations for compressibility factor are faster and easier to use and facilitate the computational procedure. Herein, we introduce two correlations which can be utilized for calculation of carbon dioxide compressibility factor, one of which is Bahadori–Vuthaluru correlation [27] and the other is the correlations for the second and third Virial coefficients [28,29]. These correlations are reviewed in Section B in the Supplementary information.

176

In order to develop the proposed model and perform the task mentioned, 178 data points from Perry’s chemical engineers’ handbook [18] consisting of temperatures up to 1273.15 K and pressures up to 50 MPa as the input and experimentally derived compressibility factors for carbon dioxide as the output of the model were gathered. This dataset was randomly divided into two subsets of training and testing in a way that data points are accumulated homogenously and different operating conditions are covered in each subset. The data distribution between the subsets is obtained by means of trial and error. A proper distribution should give optimal statistical error measures (explained later) for each subset as well as nearest mean and standard deviations of the subsets for the purpose of homogeneous accumulation. 80% of the dataset has been used for training purpose; i.e., for constructing the model, and the rest has been utilized to test the prediction capability of the model for unused data. Other distributions such as 50–50%, 60–40%, 70–30% and 90–10% respectively for training and testing, have also been examined during the trial and error procedure of the model development and the 80–20% configuration was known to yield the best results. It is worth to note that the model developed in this study is only valid for the mentioned range of temperature and pressure and any extrapolation should be avoided.

3.2. Least square support vector machine background Support Vector Machine (SVM) is one of the most rigorous approaches originated from machine learning which has recently been used in many fields [13,30,31]. This method as a supervised learning algorithm can be applied to interpret data, recognize patterns and perform regression analysis. Some advantages of SVM compared to conventional neural networks include the more probability to converge to the global optimum, no requirement to determine the network configuration in advance, less risk of over fitting and fewer number of adjustable parameters [11]. According to SVM theory, any function f(x) can be written as [32]: T

f (x) = w ϕ(x) + b

(12)

where wT and ϕ(x) are the transposed output layer vector and kernel function, respectively, and b is the bias. The model input (x) is an N × n matrix, where N and n represent the number of data points and the number of input parameters, respectively. Vapnik proposed the minimization of the following objective function in order to calculate w and b [32]:

  1 Objective function = wT + c  k − k∗ 2 N

218

3

i=1

(13)

⎧ y − wT ϕ (xk ) − b ≤ ε + k , ⎪ ⎨ k ⎪ ⎩

219

k = 1, 2, . . ., N

wT ϕ (xk ) + b − yk ≤ ε − k∗ ,

k = 1, 2, . . ., N

k , k∗

k = 1, 2, . . ., N

≥ 0,

(14)

where xk is the kth input and yk is the kth output data point. ε stands for the fixed precision of the function approximation, and  k and k∗ are slack variables. Slack variables are normally utilized to specify the allowed error bounds. c > 0 is the tuning parameter of the objective function which determines the amount of deviation from the preferred ε. A difficult quadratic programming problem has to be solved in order to find the parameters of SVM. Therefore, to decrease the complication of the SVM method, Suykens and Vandewalle [31,33] reformulated and modified it to LSSVM, which can be solved by means of linear programming and is faster than the conventional SVM while maintains its advantages [11]. The LSSVM method is expressed in the following format [32]: 1 T 1  2 ek w w+  2 2

220

221 222 223 224 225 226 227 228 229 230 231 232 233

N

Objective function =

(15)

234

k=1

Subjected to the following constraint: T

yk = w ϕ (xk ) + b + ek

235

(16)

where  is a tuning parameter and ek is the regression error for the training data points in LSSVM method. As can be seen, the inequality constraints of the SVM have been replaced by the equality constraint. The Lagrangian for this problem is defined as: L(w, b, e, a) =

 1 T 1  2   T ek − ak w ϕ (xk ) + b + ek − yk w w+  2 2 N

N

k=1

k=1

(17)

where ak represents Lagrangian multipliers. The derivatives of the above equation with respect to its four variables should be equated to zero to solve the problem. Doing so, the following set of equations will be obtained:

⎧ N  ⎪ ⎪ ⎪ w = ak ϕ (xk ) ⎪ ⎪ ⎪ ⎪ k=1 ⎪ ⎪ ⎨ N ak = 0 ⎪ ⎪ ⎪ k=1 ⎪ ⎪ ⎪ ak = ek , ⎪ ⎪ ⎪ ⎩ T

(18)

238 239 240

241

242 243 244 245 246

247

k = 1, 2, . . ., N

The above system consists of 2N + 2 equations and 2N + 2 unknown parameters (ak , ek , w, and b) whose solution provides the LSSVM parameters. As already mentioned,  is a tuning parameter of the LSSVM. Both the SVM and its modified version (LSSVM) are kernel-based functions, hence a parameter in the kernel function is regarded as the other tuning parameter. Radial basis function (RBF) kernel has been used in this study as [11,17,34–37]: K(x, xk ) = exp

237

k = 1, 2, . . ., N

yk = w ϕ (xk ) + b + ek ,



236



2 − xk − x

2

(19)

The other tuning parameter is  2 . So, there are two tuning parameters in the LSSVM with RBF kernel which are obtained through minimization of the error between the results predicted by LSSVM algorithm and the experimental data [32]. The mean

Please cite this article in press as: E. Mohagheghian, et al., Carbon dioxide compressibility factor determination using a robust intelligent method, J. Supercrit. Fluids (2015), http://dx.doi.org/10.1016/j.supflu.2015.03.014

248 249 250 251 252 253 254 255

256

257 258 259 260

G Model

ARTICLE IN PRESS

SUPFLU 3278 1–10

E. Mohagheghian et al. / J. of Supercritical Fluids xxx (2015) xxx–xxx

4

Fig. 1. A typical flowchart for the CSA–LSSVM algorithm used in this study.

261 262

square error (MSE) of the outputs resulted from the LSSVM model is calculated through the following formula:

 n

263

MSE =

Z i,exp − Zi,pred

i=1

n

2 (20)

274

where Z is the output compressibility factor, pred. and exp stand for the predicted and experimental values, respectively, and n represents the number of samples from the initial population. The LSSVM model developed by Suykens and Vandewalle [31] has been utilized in this study. The LSSVM tuning parameters can be optimized by means of coupled simulated annealing (CSA) whose detailed explanations can be found elsewhere [38]. In this study, CSA–LSSVM has been applied for the prediction of compressibility factor of carbon dioxide. A schematic flowchart of obtaining this model and its parameters has been shown in Fig. 1.

275

4. Error analysis

264 265 266 267 268 269 270 271 272 273

276 277 278 279 280 281

To evaluate the accuracy and validity of a model, several statistical parameters such as average percent relative error (Er %), average absolute percent relative error (Ea %), standard deviation (SD), root mean square error (RMSE) and coefficient of determination (R2 ) are normally used [39–43]. The equations for these parameters are reviewed in Section C in the Supplementary information.

In order to visualize the performance and validity of our model in comparison with the other methods, error distribution graphs and cumulative frequency plots versus absolute percent relative errors have been used in this study. In error distribution technique, percent relative errors are sketched around the zero error line versus experimental data to see whether or not the model follows an error trend. In the latter technique, the number of data points divided by the total number of them as the cumulative frequency is plotted against the absolute percent relative error for each data point,

Fig. 2. Average absolute percent relative error for all the investigated methods.

Please cite this article in press as: E. Mohagheghian, et al., Carbon dioxide compressibility factor determination using a robust intelligent method, J. Supercrit. Fluids (2015), http://dx.doi.org/10.1016/j.supflu.2015.03.014

282 283 284 285 286 287 288 289 290

G Model

ARTICLE IN PRESS

SUPFLU 3278 1–10

E. Mohagheghian et al. / J. of Supercritical Fluids xxx (2015) xxx–xxx

5

Table 1 Statistical parameters for all the investigated methods.

Method

Er%

Ea%

SD

RMSE

R2

Virial Coefficients correlation

-1.52

1.53

0.0351

0.1354

0.9118

Redlich-Kwong EOS Bahadori-Vuthaluru correlation Lawal-Lake-Silberberg EOS Soave-Redlich-Kwong EOS Schmidt-Wenzel EOS Patel-Teja EOS Peng-Robinson EOS REFPROP package CSA-LSSVM, testing set CSA-LSSVM, training set

1.45 -0.07 1.39 -1.05 -1.01 -0.51 -0.15 -0.19 -0.04 -0.01

1.51 1.3 1.49 1.05 1.08 0.65 0.44 0.41 0.19 0.16

0.0216 0.0258 0.0224 0.0186 0.0175 0.0118 0.0081 0.0112 0.0034 0.0049

0.087 0.073 0.0672 0.0465 0.0437 0.0176 0.0074 0.0115 0.003 0.003

0.9433 0.9524 0.9562 0.9697 0.9715 0.9886 0.9952 0.9853 0.9983 0.9991

292

predicted by different models, on one plot to facilitate the comparison through observation [41–43].

293

5. Results and discussion

291

294 295 296 297

LSSVM model includes two tuning parameters named  2 and  which in this study have been optimized by means of CSA while searching for their global optima and are calculated to be 0.27169 and 4907.95, respectively.

In order to evaluate the accuracy and validity of the proposed model compared to the other methods, the aforementioned statistical parameters have been applied. Table 1 shows the statistical parameters consisting of average percent relative error (Er %), average absolute percent relative error (Ea %), standard deviation (SD), root mean square error (RMSE) and coefficient of determination (R2 ) for the six previously mentioned EOS’s, REFPROP package and two empirical correlations as well as the training and testing parts of this study. The reason to choose these equations of state is they

Fig. 3. Error distribution graphs for REFPROP package, PR and PT EOS’s and the CSA–LSSVM proposed model.

Please cite this article in press as: E. Mohagheghian, et al., Carbon dioxide compressibility factor determination using a robust intelligent method, J. Supercrit. Fluids (2015), http://dx.doi.org/10.1016/j.supflu.2015.03.014

298 299 300 301 302 303 304 305 306

G Model SUPFLU 3278 1–10 6 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348

ARTICLE IN PRESS E. Mohagheghian et al. / J. of Supercritical Fluids xxx (2015) xxx–xxx

are of the most commonly used ones in the oil and gas industry and have been nested in many petroleum and chemical engineering software packages and reservoir simulators. The results demonstrate that the proposed model has better accuracy and higher prediction capability for the compressibility factor of carbon dioxide in both training and testing parts. As can be concluded from Table 1, the proposed model in this study shows the best performance with respect to all calculated statistical parameters as it has the least amounts for average percent relative error, average absolute percent relative error, standard deviation and root mean square error as well as the closest value of R2 to 1 in both training and testing parts. Generally speaking, the equations of state (EOS’s) show better prediction capability for carbon dioxide compressibility factor and provide more accurate results compared to the correlations; however, all the methods give acceptable predictions with the maximum Ea of 1.51%. The results from REFPROP package has the second lowest Ea % after the proposed model, while its Er %, SD and RMSE are not better than PR EOS and its R2 is not better than neither of PR and PT EOS’s. The proposed model is easier to use and the most accurate one plus it does not incur the mentioned restrictions resulting from equations of state and correlations. By comparison of average absolute percent relative error and average relative error, it is found that Soave–Redlich–Kwong EOS, Schmidt–Wenzel EOS, the Virial coefficients correlation overestimate the Z-factor CO2 , whereas Redlich–Kwong EOS, Lawal–Lake–Silberberg EOS underestimate it. In the following, in order to provide a better visual comparison among all the methods and the proposed model in this study, average absolute percent relative error for each of the investigated equations of state, the software package and correlations as well as the training and testing part of this study are plotted in Fig. 2. Following the results from Table 1 and Fig. 2, the proposed model considerably outperforms all the other investigated methods. As shown, among the investigated methods, Peng–Robinson EOS, REFPROP package and Patel–Teja EOS have the lowest average absolute percent relative errors in the mentioned order, hence the error distribution graphs for the three of them in addition to the training and testing part of this model have been plotted and shown in Fig. 3. From the error distribution graphs of Fig. 3, in which percent relative errors for the predicted results by the aforementioned models versus the corresponding absolute temperature have been plotted, it is clear that the proposed model has the least scattering

Fig. 4. Cumulative frequency vs. absolute percent relative error for all the investigated methods.

and dispersion around the zero error line, which means that its prediction is the closest to the experimental values. In addition, as can be seen, all of the models have better capability for prediction of CO2 Z-factor at higher temperatures. Afterwards, in order to carry on the objectives of this study, the cumulative frequency versus the absolute percent relative error for all the investigated methods and the proposed model have been depicted in Fig. 4. As shown in Fig. 4, the proposed CSA–LSSVM model predicts around 70% of the data points with absolute relative error smaller than 0.1% and more than 90% of the data points with absolute relative error smaller than 0.5%. Even the second most accurate method, REFPROP package, only predicts 40% of the data points with absolute relative error smaller than 0.1%, which is an additional proof of the better accuracy and performance of the proposed model. A real gas deviates from ideality at high pressures following an observed experimental trend depending on its temperature. As a matter of fact, at lower temperatures the compressibility factor of the gas initially decreases and after reaching a minimum increases with increasing pressure, while at higher temperatures the minimum is not observed and the compressibility factor increases monotonically with increasing pressure. This trend has to be and is observed for the predicted results of the proposed model as an evidence of its accuracy and reliability. Therefore, the prediction of the model in the form of trend lines at three distinct reduced

Fig. 5. CO2 Z-factor at three distinct reduced temperatures vs. reduced pressure for the CSA–LSSVM model and experimental (Exp) data.

Please cite this article in press as: E. Mohagheghian, et al., Carbon dioxide compressibility factor determination using a robust intelligent method, J. Supercrit. Fluids (2015), http://dx.doi.org/10.1016/j.supflu.2015.03.014

349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373

G Model

ARTICLE IN PRESS

SUPFLU 3278 1–10

E. Mohagheghian et al. / J. of Supercritical Fluids xxx (2015) xxx–xxx

7

Table 2 Predicted CO2 Z-factor for the testing set of data points of the CSA–LSSVM model.

374 375 376 377 378 379 380 381 382

P (MPa)

T (K)

Pr

Tr

Z-Exp.

Z-Pred.

Relative Error (%)

0.1 0.5 0.5 0.5 0.5

673.15 373.15 423.15 573.15 823.15

0.0135 0.0676 0.0676 0.0676 0.0676

2.2124 1.2264 1.3907 1.8838 2.7055

1.003 1.0056 1.1067 1.0015 1.0019

1.0026 1.0075 1.1067 1.0016 1.0016

0.036 -0.197 -0.003 -0.013 0.025

0.5 1 1 1 4 4 4 4

973.15 523.15 573.15 973.15 473.15 623.15 673.15 1173.15

0.0676 0.1353 0.1353 0.1353 0.5412 0.5412 0.5412 0.5412

3.1985 1.7194 1.8838 3.1985 1.5551 2.0481 2.2124 3.8558

1.0083 0.9416 0.9983 0.9508 1.0093 1.0458 0.9253 0.9938

1.0082 0.9408 0.9973 0.9618 1.0097 1.0517 0.9214 0.9948

0.008 0.077 0.09 -1.161 -0.043 -0.564 0.419 -0.105

4 6 6 6 6 6 6 8

1273.15 573.15 623.15 723.15 773.15 823.15 1173.15 1273.15

0.5412 0.8119 0.8119 0.8119 0.8119 0.8119 0.8119 1.08254

4.1845 1.8838 2.0481 2.3768 2.5411 2.7055 3.8558 4.1845

1.0171 1.0079 0.9896 1.0002 0.9195 0.7264 0.9984 1.0128

1.0172 1.0109 0.9918 0.9998 0.9189 0.7172 0.9968 1.0127

-0.013 -0.301 -0.229 0.037 0.063 1.264 0.152 0.007

10 10 10 20 20 30 30 30

673.15 873.15 1273.15 573.15 1373.15 823.15 1073.15 1273.15

1.3531 1.3531 1.3531 2.7063 2.7063 4.0595 4.0595 4.0595

2.2124 2.8698 4.1845 1.8838 4.5132 2.7055 3.5271 4.1845

1.0017 0.9822 0.9883 0.9621 1.0218 1.1318 0.8995 1.0166

1.002 0.9849 0.988 0.962 1.0218 1.1341 0.9026 1.0172

-0.031 -0.283 0.025 0.001 -0.005 -0.206 -0.348 -0.061

40 40 40 40 40 50 50

573.15 623.15 673.15 823.15 1173.15 823.15 873.15

5.4127 5.4127 5.4127 5.412 5.4127 6.765 6.7659

1.8838 2.0481 2.2124 2.7055 3.8558 2.7055 2.8698

0.9982 0.9773 1.0266 1.0709 0.9658 1.0107 1.0062

0.9976 0.9796 1.0258 1.0718 0.9631 1.0136 1.006

0.051 -0.236 0.075 -0.087 0.273 -0.295 0.014

temperatures vs. reduced pressure have been drawn with the experimental data points on the same plot and shown in Fig. 5. The prediction results for the testing set of the data points used in this study as well as experimental results and percent relative errors vs. temperature and pressure have been reported in Table 2. As can be seen from this table, there is an excellent agreement between the results of the CSA–LSSVM model and the experimental values which shows the high capability of this model for prediction of carbon dioxide compressibility factor.

6. Conclusion LSSVM has been used in this work to predict the Z-factor of carbon dioxide in the temperature and pressure range which mostly includes the supercritical CO2 . The tuning parameters of LSSVM have been optimized by means of coupled simulated annealing (CSA). A dataset consisting of 178 data points for the Z-factor of CO2 was collected from open literature. Statistical analysis provided an average absolute percent relative error of 0.19% and R2 of 0.9983

Please cite this article in press as: E. Mohagheghian, et al., Carbon dioxide compressibility factor determination using a robust intelligent method, J. Supercrit. Fluids (2015), http://dx.doi.org/10.1016/j.supflu.2015.03.014

383

384 385 386 387 388 389 390

G Model

ARTICLE IN PRESS

SUPFLU 3278 1–10

E. Mohagheghian et al. / J. of Supercritical Fluids xxx (2015) xxx–xxx

8

400

for the previously unused testing dataset. The comparison with six equations of state, a software package and two empirical correlations showed the better capability of this model for predicting the Z-factor of CO2 and proved it to be more accurate. The validity of the model was also shown as it follows the expected physical trend for compressibility factor as a function of reduced pressure and temperature. The model has the potential to be imported and implemented in chemical engineering and reservoir engineering software and offers increased accuracy and less computational time for the prediction of CO2 compressibility factor.

401

Appendix A.

Q3 402

A.1. Section A

Q4 403 404

A.1.1. Redlich–Kwong (RK) EOS [20] u = b, w = 0

(21)

 = 0.329032 − 0.076799ω + 0.0211947ω

405

˝a = 0.42747,

(22)

and ˝b is the smallest positive root of the following equation:

445

406

1 ˛= √ Tr

(23)

˝b3 + (2 − 3)˝b2 + 32 ˝b − 3 = 0

446

391 392 393 394 395 396 397 398 399

˝b = 0.08664

411

where

412

m=

 2 Tr

(24)

0.48 + 1.574ω − 0.176ω2

 (25)

1.18

414

(26)

415

˝a = 0.457235,

(27)

˝b = 0.077796

417

The temperature dependency function is similar to Eq. (24). The authors correlated m as

418

m = 0.3796 + 1.485ω − 0.1644ω2 + 0.1667ω3

416

for supercritical compounds, ˛ has been correlated as (39)

A.1.5. Patel–Teja (PT) EOS [24] u = b + c, w2 = bc

(40)

420

(29)

421

˝a = [1 − (1 − q)]3

(30)

422

where q is the smallest positive root of the following equation:

423

(6ω + 1)q3 + 3q2 + 3q − 1 = 0

424

then

425

1 = 3(1 + qω)

426

and

427

˝b = q

(31)

429 430

m ≡ m1 = m0 + 0.01429 (5Tr − 3m0 − 1) 2

431

m ≡ m2 = m0 + 0.71 (T r − 0.779)

432

where

433 434

(41)

442

(42)

443

(43)

444

(44)

m0 = 0.465 + 1.347ω − 0.528ω m0 = 0.5361 + 0.9593ω

447

m = 0.452413 + 1.30982ω − 0.295937ω

(45)

2

(46)

A.1.6. Lawal–Lake–Silberberg (LLS) EOS [40] u = b, w2 = ˇb2



for

2

2

for

for

for

ω ≤ 0.4

ω ≥ 0.55

ω ≤ 0.3671

ω > 0.3671

(34) (35)

(36) (37)

448

449 450

451

452



1 + ˝w − 3 Zc ˝w Zc

(47)

453

(48)

454

where Zc is the critical compressibility factor and ˝w has been correlated with acentric factor as follows: 0.361 ˝w = 1 + 0.0274ω

455 456

(49)

457

(50)

458

˝a = 1 + ˝w − 1 Zc

(51)

459

˝b = ˝w Zc

(52)

460



3

Zc2 ˝w − 1





2Z + + 2˝w (1 − 3Zc ) ˝w c 2Z ˝w c

 3

The temperature dependency function is similar to Eq. (24). The authors correlated m as (53)

[26] A.1.7. A( , T )Span–Wanger EOS = ϕ(ı, ) = ϕ0 (ı, ) + ϕr (ı, ) RT

(33)

The temperature dependency function is similar to Eq. (24). The authors correlated m as

428

2

m = 0.14443 + 1.06624ω + 0.02576ω2 − 0.18074ω3 (32)

440

441

The temperature dependency function is similar to Eq. (24). The authors correlated m as

(28)

A.1.4. Schmidt–Wenzel (SW) EOS [23] u = (1 + 3ω)b, w2 = 3ωb2

438

439

˝a = 32 + 3(1 − 2)˝b + ˝b2 + (1 − 3)

ˇ= 419

436

437

˛ = 1 − (0.4774 + 1.328ω)ln (T r )

=

A.1.3. Peng–Robinson (PR) EOS [22] u = 2b, w = b

413

(38)

and then ˝a can be calculated by

˛= 1+m 1−



m1 + 2(ω − 0.4)m2

˝c = 1 − 3

410



0.15

435

RTc c = ˝c Pc

409

408

m=

0.55 − ω 

where

A.1.2. Soave–Redlich–Kwong (SRK) EOS [21] √ Soave [21] replaced the term 1/ Tr in RK EOS by a more general term as follows:

407

and for intermediate values of 0.4 < ω < 0.55

ı=

462

463

464 465

Tc = c ,

T

466

where A is the Helmholtz free energy and ϕ is its dimensionless form divided into the ideal-gas part (ϕ0 ) and the residual part (ϕr ) c is the critical density and all other terms take their normal or already mentioned meanings. ϕ0 (ı, ) = ln(ı) + a01 + a02 + a03 ln( ) +

461

8  i=4





a0i ln 1 − exp − i0

467 468 469 470



(54)

Please cite this article in press as: E. Mohagheghian, et al., Carbon dioxide compressibility factor determination using a robust intelligent method, J. Supercrit. Fluids (2015), http://dx.doi.org/10.1016/j.supflu.2015.03.014

471

472

G Model

ARTICLE IN PRESS

SUPFLU 3278 1–10

E. Mohagheghian et al. / J. of Supercritical Fluids xxx (2015) xxx–xxx 473

 7

ϕr (ı, ) = 39 

474

+



B1 = 0.139 −



34

ni ıdi ti +

i=1



ni ıdi ti exp −ıci

i=8

ni ıdi ti exp −˛i ı − εi

2

− ˇi ( − i )2



+



bi

ni ı exp −Ci (ı − 1) − Di ( − 1)

i=40

475

=

2



(1 − ) + Ai



2 1/(2ˇi ) 2

ı−1

2

 (55)

+ Bi

2 ai

ı−1

(56)

479 480

= A−1 (A ( , T ))

477 478

(57)

483

There is no analytic form for this and an iterative method like Newton’s method should be employed. Since the temperature and pressure are known, the following equation can be written:

484

P = RT 1 + ı

481 482

485 486 487 488





∂A ∂ı

C0 = 0.01407 +

 

So, an initial guess should be made for density and then pressure should be found knowing the temperature and density. The iteration continues until the calculated and known P become sufficiently close.

494

ln(Z) = ˛ +

495

where

492

ˇ  + 2 + 2 Tr Tr Tr

(59)

496

˛ = A1 +

B1 C1 D1 + 2 + 3 Pr Pr Pr

(60)

497

ˇ = A2 +

B2 C2 D2 + 2 + 3 Pr Pr Pr

(61)

498

B3 C3 D3  = A3 + + 2 + 3 Pr Pr Pr

(62)

499

B4 C4 D4 = A4 + + 2 + 3 Pr Pr Pr

(63)

500 501

502 503 504

505

where

506

Bˆ = B0 + ωB1

507

B0 = 0.083 −

Tr1.6

Tr10.5

510

(70)

511

A.3.1. Average percent relative error

513

1 Er = Ei n

(71)

514

i=1

where Ei (percent relative error) shows the relative difference between a represented/predicted value and its corresponding experimental value:



Ei =

Zi,exp − Zi,pred Zi,exp



× 100

i = 1, 2, 3, . . ., n

(72)

1    Ea = Ei n

515 516 517

518

519

n

(73)

520

i=1

A.3.3. Root  mean square error

 n  1  2 RMSE =  Zi,exp − Zi,pred

521

(74)

Standard deviation A.3.4. 

 2 n   1  Zi,exp − Zi,pred  SD = n−1

i=1

Zi,exp

523

(75)

A.3.5. Coefficient of determination n  

R2 = 1 −

522

i=1

Zi,exp − Zi,pred

i=1

n  

Zi,pred − Z

524

525

2

2

(76)

References

(64)

(65) 0.422

0.00242

(69)

526

i=1

where parameters A1 to D4 for pressures less than 4 MPa as well as pressures between 4 to 50 MPa can be found elsewhere [27]. A.2.2. Correlations for the second and third Virial coefficients [28,29]

P 2 Pr r + Cˆ Z = 1 + Bˆ Tr Z Tr Z



509

512

A.2. Section B

493

491

Tr2.7

(68)

A.3.2. Average absolute percent relative error:

(58)

A.2.1. Bahadori–Vuthaluru correlation [27] Bahadori and Vuthaluru [27] presented the following relations for calculation of carbon dioxide compressibility factor for pressures up to 50 MPa and temperatures up to 1000 ◦ C.

490

0.05539

508

A.3. Section C

n

489

0.02432 0.00313 − Tr Tr10.5

(67)

n

The coefficients and exponents of the above equations are tabulated in [26]. Since the Helmholtz EOS is a function of density, it should be inverted:

476

Tr4.2

C1 = −0.02676 +

 

0.172

Cˆ = C0 + ωC1

i=35

42 

9

(66)

ˇ [1] Zˇ . Knez, E. Markoˇciˇc, M. Leitgeb, M. Primoˇziˇc, M.K. Hrnˇciˇc, M. Skerget, Industrial applications of supercritical fluids: a review, Energy 77 (2014) 235–243. [2] K. Srinivasan, Identification of optimum inter-stage pressure for two-stage transcritical carbon dioxide refrigeration cycles, J. Supercritical Fluids 58 (2011) 26–30. [3] A. Hemmati-Sarapardeh, S. Ayatollahi, A. Zolghadr, M.-H. Ghazanfari, M. Masihi, Experimental determination of equilibrium interfacial tension for nitrogencrude oil during the gas injection process: the role of temperature, pressure, and composition, J. Chemical & Engineering Data 59 (2014) 3461–3469. [4] V. Dostal, M.J. Driscoll, P. Hejzlar, N.E. Todreas, A supercritical CO2 gas turbine power cycle for next-generation nuclear reactors, in: 10th International Conference on Nuclear Engineering, American Society of Mechanical Engineers, 2002, pp. 567–574. [5] A.M. Elsharkawy, Efficient methods for calculations of compressibility, density and viscosity of natural gases, Fluid Phase Equilibria 218 (2004) 1–13. [6] T. Ahmed, Reservoir Engineering Handbook, Gulf Professional Publishing, 2006. Q5 [7] T.H. Ahmed, Hydrocarbon Phase Behavior, Gulf Pub Co., 1989. [8] E. Heidaryan, J. Moghadasi, M. Rahimi, New correlations to predict natural gas viscosity and compressibility factor, J. Petroleum Science and Engineering 73 (2010) 67–72. [9] E.M.E.-M. Shokir, M.N. El-Awad, A.A. Al-Quraishi, O.A. Al-Mahdy, Compressibility factor model of sweet, sour, and condensate gases using genetic programming, Chemical Engineering Research and Design 90 (2012) 785–792.

Please cite this article in press as: E. Mohagheghian, et al., Carbon dioxide compressibility factor determination using a robust intelligent method, J. Supercrit. Fluids (2015), http://dx.doi.org/10.1016/j.supflu.2015.03.014

527

528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550

G Model SUPFLU 3278 1–10 10

ARTICLE IN PRESS E. Mohagheghian et al. / J. of Supercritical Fluids xxx (2015) xxx–xxx

[10] M. Mahmoud, Development of a new correlation of gas compressibility factor (Z-factor) for high pressure gas reservoirs, J. Energy Resources Technology 136 553 (2014) 012903. 554 [11] A. Hemmati-Sarapardeh, R. Alipour-Yeganeh-Marand, A. Naseri, A. Safiabadi, F. 555 Gharagheizi, P. Ilani-Kashkouli, A.H. Mohammadi, Asphaltene precipitation due 556 to natural depletion of reservoir: determination using a SARA fraction based 557 intelligent model, Fluid Phase Equilibria 354 (2013) 177–184. 558 [12] A. Hemmati-Sarapardeh, B. Mahmoudi, S.A. Ramazani, A.H. Mohammadi, 559 Q6 Experimental measurement and modeling of saturated reservoir oil viscosity, 560 Korean J. Chemical Engineering (2014) 1–12. 561 [13] A. Hemmati-Sarapardeh, A. Shokrollahi, A. Tatar, F. Gharagheizi, A.H. Moham562 madi, A. Naseri, Reservoir oil viscosity determination using a rigorous approach, 563 Fuel 116 (2014) 39–48. 564 [14] A. Kamari, A. Hemmati-Sarapardeh, S.-M. Mirabbasi, M. Nikookar, A.H. Moham565 madi, Prediction of sour gas compressibility factor using an intelligent 566 approach, Fuel Processing Technology 116 (2013) 209–216. 567 [15] A. Shokrollahi, M. Arabloo, F. Gharagheizi, A.H. Mohammadi, Intelligent model 568 for prediction of CO2 —reservoir oil minimum miscibility pressure, Fuel 112 569 (2013) 375–384. 570 [16] M. Hosseinzadeh, A. Hemmati-Sarapardeh, Toward a predictive model for esti571 mating viscosity of ternary mixtures containing ionic liquids, J. Molecular 572 Liquids 200 (2014) 340–348. 573 [17] A. Fayazi, M. Arabloo, A. Shokrollahi, M.H. Zargari, M.H. Ghazanfari, State574 of-the-art least square support vector machine application for accurate 575 determination of natural gas viscosity, Industrial & Engineering Chemistry 576 Research 53 (2013) 945–958. 577 [18] D.W. Green, R.H. Perry, Perry’s Chemical Engineers’ Handbook, eighth ed., 578 McGraw-Hill, New York, NY, 2008. 579 [19] A. Danesh, PVT and Phase Behaviour of Petroleum Reservoir Fluids, Elsevier, 580 1998. 581 [20] O. Redlich, J. Kwong, On the thermodynamics of solutions. V. An equation of 582 state. Fugacities of gaseous solutions, Chemical Reviews 44 (1949) 233–244. 583 [21] G. Soave, Equilibrium constants from a modified Redlich–Kwong equation of 584 state, Chemical Engineering Science 27 (1972) 1197–1203. 585 [22] D.-Y. Peng, D.B. Robinson, A new two-constant equation of state, Industrial & 586 Engineering Chemistry Fundamentals 15 (1976) 59–64. 587 [23] G. Schmidt, H. Wenzel, A modified van der Waals type equation of state, Chem588 ical Engineering Science 35 (1980) 1503–1512. 589 [24] N.C. Patel, A.S. Teja, A new cubic equation of state for fluids and fluid mixtures, 590 Chemical Engineering Science 37 (1982) 463–473. 591 [25] A.S. Lawal, E.T. Van der Laan, R.K.M. Thambynayagam, Four-Parameter 592 Modification of the Lawal-Lake-Silberberg Equation of State for Calculat593 ing Gas-Condensate Phase Equilibria, in, Society of Petroleum Engineers. 594 Q7 DOI:10.2118/14269-MS. 595 [26] R. Span, W. Wagner, A new equation of state for carbon dioxide covering the 596 fluid region from the triple-point temperature to 1100 K at pressures up to 597 800 MPa, J. Physical and Chemical Reference Data 25 (1996) 1509–1596. 598 [27] A. Bahadori, H. Vuthaluru, Rapid estimation of carbon dioxide compressibility 599 factor using simple predictive tool, in: SPE Asia Pacific Oil and Gas Conference and Exhibition, Society of Petroleum Engineers, 2010. 551 552

[28] H. Orbey, J. Vera, Correlation for the third virial coefficient using Tc, Pc and ␻ as parameters, AIChE J. 29 (1983) 107–113. [29] J. O’connell, J. Prausnitz, Empirical correlation of second virial coefficients for vapor–liquid equilibrium calculations, Industrial & Engineering Chemistry Process Design and Development 6 (1967) 245–250. [30] A. Eslamimanesh, F. Gharagheizi, M. Illbeigi, A.H. Mohammadi, A. Fazlali, D. Richon, Phase equilibrium modeling of clathrate hydrates of methane, carbon dioxide, nitrogen, and hydrogen+ water soluble organic promoters using support vector machine algorithm, Fluid Phase Equilibria 316 (2012) 34–45. [31] J.A. Suykens, J. Vandewalle, Least squares support vector machine classifiers, Neural Processing Letters 9 (1999) 293–300. [32] V. Vapnik, S.E. Golowich, A. Smola, Support vector method for function approximation, regression estimation, and signal processing, Advances in Neural Information Processing Systems (1997) 281–287. [33] K. Pelckmans, J.A. Suykens, T. Van Gestel, J. De Brabanter, L. Lukas, B. Hamers, B. De Moor, J. Vandewalle, LS-SVMlab: a Matlab/c Toolbox for Least Squares Support Vector Machines, Tutorial, KULeuven-ESAT, Leuven, Belgium, 2002. [34] A. Kamari, F. Gharagheizi, A. Bahadori, A.H. Mohammadi, Rigorous modeling for prediction of barium sulfate (barite) deposition in oilfield brines, Fluid Phase Equilibria 366 (2014) 117–126. [35] A. Kamari, A. Khaksar-Manshad, F. Gharagheizi, A.H. Mohammadi, S. Ashoori, Robust model for the determination of wax deposition in oil systems, Industrial & Engineering Chemistry Research 52 (2013) 15664–15672. [36] A. Kamari, A. Safiri, A.H. Mohammadi, A compositional model for estimating asphaltene precipitation conditions in live reservoir oil systems, J. Dispersion Science and Technology 36 (3) (2015) 301–309, http://dx.doi.org/10.1080/01932691.2014.896220. [37] S. Esfahani, S. Baselizadeh, A. Hemmati-Sarapardeh, On determination of natural gas density: least square support vector machine modeling approach, J. Natural Gas Science and Engineering 22 (2015) 348–358. [38] J.A. Suykens, J. Vandewalle, B. De Moor, Intelligence and cooperative search by coupled local minimizers, International J. Bifurcation and Chaos 11 (2001) 2133–2144. [39] M. Arabloo, M.-A. Amooie, A. Hemmati-Sarapardeh, M.-H. Ghazanfari, A.H. Mohammadi, Application of constrained multi-variable search methods for prediction of PVT properties of crude oil systems, Fluid Phase Equilibria 363 (2014) 121–130. [40] A. Hemmati-Sarapardeh, M. Khishvand, A. Naseri, A.H. Mohammadi, Toward reservoir oil viscosity correlation, Chemical Engineering Science 90 (2013) 53–68. [41] A. Tatar, A. Shokrollahi, M. Mesbah, S. Rashid, M. Arabloo, A. Bahadori, Implementing radial basis function networks for modeling CO2 -reservoir oil minimum miscibility pressure, J. Natural Gas Science and Engineering 15 (2013) 82–92. [42] A. Bahadori, H.B. Vuthaluru, M.O. Tadé, S. Mokhatab, Predicting waterhydrocarbon systems mutual solubility, Chemical Engineering & Technology 31 (2008) 1743–1747. [43] A. Bahadori, H.B. Vuthaluru, A novel correlation for estimation of hydrate forming condition of natural gases, J. Natural Gas Chemistry 18 (2009) 453–457.

Please cite this article in press as: E. Mohagheghian, et al., Carbon dioxide compressibility factor determination using a robust intelligent method, J. Supercrit. Fluids (2015), http://dx.doi.org/10.1016/j.supflu.2015.03.014

600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649