You are on page 1of 4

Comparing methods for calculating Z-factor

Gabor Takacs nal points for pseudoreduced tem- Thus the need arose early for some
Texas Tech University perature (Tr) and pseudoreduced pres- kind of mathematical description of
Lubbock, Tex. sure (Pr) in the ranges of 1.2 -:; T, -:; that chart. Furthermore, numerical
3.0 and 0.2 -:; p, -:; 15.0. methods are of utmost importance for
From an examination of computa- Petroleum engineering calculations computer application of any calcula-
tional methods, one can select the often require knowledge of Z-factors tion involving determination of Z-fac-
most accurate method for calculating for natural gases, but experimental tors.
a gas deviation factor (Z), the method data from pressure-volume-tempera-
that needs the least computer time, ture (p - V - T) measurements are sel- Methods investigated
and whether a minicomputer or larger dom available. In such cases, use of The most commonly used methods
machine is needed. the Standing-Katz Z-factor chart' or its to describe the original Z-factor chart
This examination covered thirteen tabulated form is generally accepted. are evaluated in this article which is
computational methods for describing This chart gives reasonably accurate an extension of a study published in a
the Standing-Katz natural gas devi- results for mixtures composed of pure previous article by the author."
ation factor chart that has been used hydrocarbon gases. Following is a review of the meth-
for more than 40 years. The use of this chart in complex ods investigated:
The accuracy of the methods has calculation schemes is often too time- Gray-Sirns.:' This method involves
been determined based on 180 origi- consuming or perhaps impossible. the storage of a matrix composed of Z

Table 1

Comparison of methods for computer calculation of Z-factors

1. Gray-Sims (1959) 5. Hankinson, et al. (1969) 10. Oranchuk-A. Kassem (1975)

6. Carlile-Gillett (1971)
2. Sarem (1969) 11. Gopal (1977)
7. Hall-Yarborough (1973)
3. Leung (1964) 12. Burnett (1979)
8. Brill (1974)

4. Papay (1968) 9. Oranchuk, el al. (1974) 13. Papp (1979)

2 3 4 5 6 7 8 9 10 11 12 13

Average error, % 0.145 -0.043 0.638 -4.889 2.261 -0.052 -0.158 -3.423 -0.017 -0.002 0.105 -3.882 0.120

Average absolute error,% 0.190 0.939 2.115 7 .• 69 2.799 0.208 0_ 512 3.966 0.361 0.304 1.338 4.601 0.539

Average running time,


0.718 1.08 a 0.656 0.362 1. 961 0.329 1.798 0.659 1. 588 1. 231 0.294 0.333 0.367
sec/Z value

T, Isotherm average absolute error, %


1.2 0.070 2.160 7.689 19.490 11.387 0.334 0.552 1. 627 0.417 0.335 1.177 20.639 1. 068
1.3 0.081 1.370 4.179 12.541 6.176 0.214 0.620 1. 042 0.402 0.417 1. 251 2.251 0.547
1.4 0.075 0.991 2.558 9.518 3.497 0.179 0.425 o . 372 0.361 0.308 0.745 2.070 0.790
1.5 0.048 0.787 1.704 8.564 2.193 0.115 0.602 0.857 0.169 0.143 1.008 1. 441 0.877
1.6 0.063 0.742 1.183 8.023 1.469 0.259 0.424 0.724 0.313 0.244 1.16J 1. 3 79 0.45J
1.7 0.437 0.6ld 0.655 7.067 1. 093 0.216 0.341 0.425 0.424 0.302 1. 497 1.204 0.350
1.6 0.435 0.561 0.479 5.702 0.802 0.182 0.381 0.447 0.293 0.254 1.588 1. 215 0.325
2.0 0.354 0.43. 0.472 3.107 o . 553 0.233 0.489 1.909 0.281 O. J83 2.210 2.J 56 0.310
2.4 0.324 0.654 0.532 1. 209 0.299 0.191 0.682 7.149 0.264 0.221 0.461 4.920 0.287
3.0 0.016 1.071 1. 500 4.171 0.524 0.153 0.607 25.J04 0.665 0.633 2.279 8.740 0.382

P, Isobar average absolute error


0.2 0.055 1.147 1. 689 0.235 0.181 0.129 1. 301 0.292 0.088 0.079 0.121 0.627 0.230
0.5 0.050 0.529 1.1&5 0.389 0.425 0.118 1. 553 0.591 0.151 0.165 0.190 1. 488 0.375
1.0 0.047 1.176 0.825 a. 562 0.782 0.065 0.567 1.175 0.299 0.265 0.514 2.842 0.268
1.5 0.015 0.880 0.577 1. J72 0.987 0.138 0.422 2.014 0.424 0.323 0.775 3.844 0.387
2.0 0.031 0.957 1. sos 2. GdS 0.564 0.160 0.583 3.136 0.483 0.369 1. 238 J. 66 9 0.89J
2.5 0.000 1.567 2. 07d 3.1159 1.199 0.149 0.577 3.635 0.28S 0.234 0.730 4.303 0.9J8
3.0 0.046 1. 206 1. 502 2.132 1. 836 0.200 0.575 3.445 0.337 0.317 1.656 6.680 0.703
3.5 O.ll64 0.738 O.BoO 2.021 2. J64 0.161 0.447 3.344 0.514 0.424 0.714 8.359 0.658
4.0 0.014 0.696 1.078 3. Old 2.903 0.134 0.437 3.547 0.701 0.574 0.899 9.603 0.650
4.5 0.049 0.622 1. 091 J. e76 1.179 0.115 0.331 3.757 0.665 0.528 0.725 0.532
5.0 0.039 0.861 1. 046 4. :01 3.598 0.127 0.325 3.983 0.569 0.477 0.684 e.465
5.5 0.255 1. 054 0.867 4. i76 2.078 0.098 0.310 4.249 0.434 0.372 3.590 0.490
6.0 0.495 loll 7 0.638 4. SOB 2.429 0.11 0 0.503 4.359 0.242 0.247 3.008 0.579
6.5 u.678 0.934 0.330 4.695 2.876 0.087 0.304 4.495 0.125 0.182 2.522 0.6J3
7. a 0.854 0.586 0.413 5.1d5 3.346 0.251 0.242 4.636 0.155 0.146 2.098 0.631
8.0 0.700 0.217 1. 50b 6.968 4.443 0.659 0.258 4.998 0.202 0.185 1. 602 0.616
10.0 0.035 0.756 2.275 20.450 6.395 0.708 0.109 6.100 0.247 0.159 1.301 0.319
15.0 0.000 1. ass 18.480 72.409 10.80 0 0.330 0.381 13.622 0.575 0.424 1. 710 0;·367

OGJ

TECHNOLOGY May 15, 1989, Oil & Gas Journal 43


values taken from the Standing-Katz Table 2
chart at some fixed values of pseudo-
reduced parameters p, and T,. An Three different programs for calculating Z-factor
interpolation scheme is then used to
compute deviation factors from the
stored values.
1121REM SUBROUTINE TO CALCULATE DEVIATION FACTORS
To minimize computer memory re- 20 REM using the method of BURNETT (1979)
30 REM
quirements, data points were taken 40 Z0"".3379·I>LOG(LOG<TRED) 1+1.0!yt
from the original chart by taking into 50 P0=21. 46*Z0-ll. 9"Z0-.Z0-5. 9
60 U=PRED/P0
account its varying curvature. Thus, a 70 N= (1. 1+. 26*TRED+ (1.04--1. 42*TREDI *U) "EXP (U) fTRED
80 1=1+ (Z0-1 1*(SIN (1.570796.327 •.•.0) ) .....
N
20 x 20 matrix of Z values was 90 RETURN

constructed that adequately represents


the whole chart.
10 REM SUBROUTINE TO CALCULATE GAS DEVIATION FACTORS
This method requires the storage in 20 REM using th~ Illethod of GOPAL (1977>
30 DIM A(48)
memory of one 20 x 20-type matrix 40 DATA 1.6643,-2.2114,-0.3647,1.4385.0.5222,-0.8511,-0. 0364. 1.049
50 DATA a. 1391.-0.2988,0.0007,0.
along with two vectors of 20 elements 9969,0.11J295. -0. 0825,0.
60 OAT A -1.357,1.4942,4.6315,-4.7009,0.1717,-0.3232,0.5869,0.1229
121009,0. 9967

each. Therefore, the use of most types 70 DATA 0.0984,-0.2053,0.062190.858,0.0211,-0.0527,0.0127 ,0. 9549
80 DATA -0.3278,O. 47~2,1. 8223,-1. 9036,-0. 2521,0. 3871,1.6087,-1.6635
of programmable calculators is heavi- 90 DArA -0.0284 ,0. 062~,0. 4714. -0. 0011 ,0.0041,0.0039,0.0607,0.7927
100 FOR 19=1 TO 48
ly restricted, as their storage capacity 110 READ A(I9)

is relatively small. 12121NEXT 19


130 IF PRED(=5. -4 THEN 16Q1
The ranges of applicability of this Z- 140 Z""PRED*{ . 711 +3. 66*TRED)·" (-1. 4667) -1.637/ (. 319*TRED· +, 522) +2. 071
150 RETURN
factor calculation method are the fol- 160 IF PRED<= 1.2 THEN 210

lowing, according to the authors: 170 IF PRED >2.8


180 IF PRED >1.4
THEN 230
THEN 250
190IFTRED> 1.19HtEN250
200 IF TRED <
1 . 08 THEN 2~0
1.05 -s:;T, -s:; 3.0 210 19=1
220 GOTO 260
230 19:3

0.0 -s:;p,-S:;15.0 240


250
GOTO 260
19=2
260 IF TRED<:::: 1.2 THEN 310
270 IF TRED<=I. -4 THEN 330
Sarern." The author made a least- 280 IF TRED <=2 THEN 350
290 K9:.;.q
squares fit of the Z = f(p" T,) relation- 300 GOTD 360
ship using Legendre polynomials of 310
320
K9=1
GOTO 360
up to five degree. His equation can be 330 K9=2
340 GOTD 360
written as: 350 K9== 3
·360 ,J9"'16*19+4*.<9··19
370 Z""PRED*·(A (J9) *TRED·,·A (J9+1) ) +A (J9+2) *TRED+A (J9+3)
3813 RETURN

Z
10 REM SUBROUT1NE TO CALCULATE GAS DEVIATION FACTORS
m=O n=O 20 REM usi ng the method of LEUNG (1964)
30 DIM 8(16)
40 FOR 19:::1 TO 16
In this formula, constants Amn are 50 READ 8(19)

given in matrix A of the type 6 x 6, 60


70
NEXT 19
DATA 1.877,-4.936,8.987,-5.215,-.6562,3.692,-6.477,3. rJJ77,. 1015, -. 5242
and Pm (x ), Pn (y) are Legendre poly- 80
90
DATA .8359,
Z=0
-. 3192,-. Ql0422, .121205,-.0288, .1210742

nomials of p, and T" respectively. 11210 FOR J9=1 TO -4


110 FOR 19::1 TO 4
As a result of Sarem's work, only 36 120 Z:Z+8 (J9+4·" ( 19-1) ) *PREDA (19-1) __
TREDA (1-J9)

coefficients (the elements of matrix A) 130


140
NEXT I9:NEXT
RETURN
J9

need to be stored for calculating Z-


factors.
OGJ
This made the use of smaller-capac-
ity minicomputers possible.
The limits of the correlation are 1.1-S:;T,-S:; 2.6 sure ranges of p, < 5.0 and p, 5.0. :?
given as: There are eight coefficients given in
0.5 -s:;p, -s:;11.0 each range, thus data storage is limit-
1.05 -s:;T, -s:; 2.95 ed to 16 values.
Papay." Widely used in Hungary, As the BWR equation of state is
0.1 -s:;p, -s:;14.9 this author's formula for the calcula- implicit regarding deviation factors,
tion of Z-factors is given as: numerical methods such as Newton-
Leung.? The Standing-Katz Z-factor Raphson's iteration scheme have to be
chart is approximated by using the used to solve for Z values.
method of least-squares fitting and the 3.52 p, 0.274 p,2 Accuracy is sufficient in the ranges:
following mixed power polynomial: Z=l 10°.9813T, + 10°.8157T,
1.1 -S:;T,-S:;3.0
4 4
Z L L This equation lends itself easily for p, -s:;15.0
i=l j=l hand calcu lations. When pro-
grammed to computers, memory re- Carlile-Gillett." Isotherms of the Z-
Only the values of matrix B (16 in quirements are minimal. factor chart can be described by poly-
number) need to be stored in comput- Hankinson- Thomas-Phillips." The nomials of the pseudoreduced pres-
er memory, thus the use of smaller authors used the Benedict-Webb-Ru- sure.
capacity programmable calculators is bin (BWR) equation of state to de- According to Carlile-Gillett, these
also possible. scribe deviation factor values. They polynomials for the different pseudo-
The suggested ranges of applicabil- obtained different coefficients of the reduced temperatures are of different
ity are: BWR equation for the reduced pres- degree, but not higher than eight.

44 Oil & Gas Journal, May 15, 1989 TECHNOLOGY


Thus, their basic equation takes the chart in different ranges of pseudore-
form: duced pressure and pseudoreduced
The author ... temperature. Because 12 such ranges
Gabor Takacs is
an associate profes- are set, a total of 48 constants has to
sor of petroleum be stored in computer memory.
for T, = constant, where n -:::;;8. engineering at the Recommended application ranges
Technical Univer-
The coefficients a, were determined sity of Miskolc, are:
for 17 different isotherms. Additional- Hungary, and is
ly, as for higher pseudoreduced pres- currently working at 1.05 -:::;;r, -:::;;
3.0
sures the original isotherms have a Texas Tech Uni-
versity, Lubbock, as
linear portion, 17 linear equations 0.2 -:::;;Pr-:::;;15.0
a visiting profes-
had to be given in order to reproduce sor. He has auth-
the whole chart. All these resulted in Takacs ored more than 40 Burnett.!" Deviation factor values
having to store in computer memory a technical papers on of AGA are approximated by the fol-
production technology, and special-
total of more than 100 coefficients. izes in artificial lift problems. Takacs is lowing formula:
Memory requirements are further vice-president of Petroleum Engineer-
increased by the rather lengthy pro- ing Consultants Co., a firm active in Z = 1 + (Z' - 1) (sin 90 pIp,')
gramming caused by having two dif- industrial research and development
projects. He has an MS and PhD in
ferent equations for each isotherm. petroleum engineering and is a mem- where: Z', p,', and N are functions of
The use of this method on minicom- ber of SPE. T, and Pro
puters is, therefore, at least impracti- This non iterative calculation can be
calor even impossible. used in the somewhat limited ranges
This method can be used in the of:
ranges: Z values using the Newton-Raphson
iteration method. The logic of the 1.3 -:::;;Tr s 3.0
1.2 -:::;;r, -:::;;
3.0 numerical model implies that memory
storage is not a limiting factor. 0.2 -:::;;p, -:::;;4.0
0.0-:::;;Pr-:::;;15.0 The method is valid in the ranges:
Papp.'! The deviation factor chart is
Hall-Yarborough.? The relatively 1.05 -:::;;r, s 3.0 described by the equation:
lesser-known Starling-Carnahan equa-
tion of state was used to develop the 0.2 -:::;;p, -:::;;
30.0 Z = 1 + R1Pr + R2P/ - W R3P/(p/
numerical model of these authors. + RsPr + R6)
Coefficients in the equation were de- Dranchuk-A. Kassem.'? The aim of
termined by fitting the equation to these authors was to develop a meth- Where parameters Rj and Ware
data from the Standing-Katz chart. od that adequately calculates Z-fac- functions of pseudoreduced tempera-
The resulting transcendent, nonlinear tors for pseudo-reduced temperatures ture only.
equation can be solved for Z-factors lower than T, = 1.0. Their approach In applications where temperature
by the Newton-Raphson iteration was similar to that of Hall-Yarbor- is constant, these values need to be
scheme. ough's, in so far as the Starling-Carna- calculated only once, and in such
On programming the method to han equation of state. Coefficients cases calculation speed is increased.
computers, storage requirements are were determined by surface fitting the Papp gives the following applica-
small, making it suitable for minicom- Z-factor chart to 1,500 Z values. tion ranges for his correlation:
puter applications. The Newton- Using again the Newton-Raphson
Raphson model provides easy conver- iteration procedure, this method can 1.2 -:::;;r. s 3.0
gence in the ranges of applicability. also be programmed, due to the mod-
Owing to its sound theoretical ba- erate memory storage needed, into 0.0-:::;;Pr-:::;;15.0
sis, this calculation method can be minicomputers.
applied in a wider pseudoreduced Ranges of application are:
Comparison of methods
pressure range than the original chart. To conduct this study, computer
The authors demonstrated (usi ng ex- 1.0 -:::;;r, -:::;;
3.0 programs, in Basic, were developed
perimental data) that it gives results of for an IBM PC/XT personal computer.
high accuracy even above p, = 24.0. 0.2 -:::;;p, -:::;;
30.0 From the original Standing-Katz
Thus, the limits of this correlation are: chart, 180 Z-factor values were taken
and r, -:::;;
in the ranges of 1 .2 -:::;; 3.0 and 0.2
r. -:::;;
1.2 -:::;; 3.0 -:::;;p, -:::;;15.0.
0.7 -:::;;r, -:::;;
1.0 for p, < 1.0 For the same T, - p, pairs, Z values
0.1 -:::;;p, -:::;;24.0 were determined by using the meth-
Gopal.':' This author presented a non- ods investigated. Deviation of the cal-
Brill.lO The computer program for iterative method for deviation factor culated values from the original ones
Z-factor calculations originally pub- calculations. Such methods, in gener- were defined as:
lished in Reference 10 involves a sim- al, require less computation time than
ple equation and can be easily adopt- methods involving iterations for solv-
ed to minicomputers. ing some kinds of equation of state. d = Zehart - Zealc 1 00%
Dranchuk, et al.!' This calculation Gopal's final equations have the Zehart
method is a result of fitting the Bene- form:
dict-Webb-Rubin (BWR) equation of Detailed results of accuracies ob-
state to the Z = f(p"Tr) surface. Accu- Z = Pr (A T, + B) + C T, + D tained are not reproduced here, but
racy of fitting was assured by using Table 1 contains condensed results for
1,500 points of the original chart. The Coefficients A to D were evaluated each of the methods studied.
nonlinear BWR equation is solved for by curve-fitting the Standing-Katz In this table,' average errors and

TECHNOLOGY May 15, 1989,Oil & GasJournal45


average absolute errors are given for
the different calculation models. Run-
ning times, as shown, include certain
output operations and serve only to
compare the capabilities of the meth-
ods. To present a more-rigorous pic-
ture of the methods, average errors for
each isotherm and isobar are also
listed. These last parameters allow
one to select those ranges of pseudo-
reduced temperature and pressure,
where calculation errors are below
some specified value.
Using the result of Table 1, one can
select just that Z-factor calculation
which provides the required accuracy
in the parameter ranges at hand or
requires minimum computer running
time.
Because relative running times,
shown in Table 1, spread over a wide
range of about one to six, choosing
the right model can substantially
speed up complex programs that in- Daniel's automated crude oil tanker loading system was set up outside the company's Houston
volve caculating several deviation fac- headquarters before being shipped in January to the Middle East for installation (Fig. 1).
tors in one run.
Basic programs for the Leung, Go-
pal, and Burnett models (which all
exhibit low running times) are given in
Tanker-loading flow-metering
Table 2.

Acknowledgments
system leaves for Saudi Arabia
The support received from Texas
Tech University and the Soros Foun- Daniel Industries Inc. of Houston has In redundant configuration, the
dation, ew York, during the author's shipped to the Middle East an auto- MM3000's provide automatic control
stay at Texas Tech is sincerely ac- mated crude-oil, tanker-loading sys- for three independent crude-oil-me-
knowledged. tem (Fig. 1) with capacity to load tering stations which measure crude
390,000 bbl/hr. oil as it is passed to offshore loading
References The custom-designed, multimillion- faci Iities.
1. Standing, M.B., and Katz, D.L., "Density of
natural gases," Trans. AIME, Vol. 146, 1942, dollar system will measure and con- Using data from system sensors and
pp. 140-49. trol the flow of crude oil loaded into flow computers, they perform station
2. Takacs G., "Comparisons made for computer
Z-factor calculations," OGL Dee. 20, 1976, tankers at the Yanbu (Saudi Arabia) totaling, meter proving, and operator-
pp. 64-66. terminal for the new IPSA-2 pipeline control functions.
3. Gray, E.H., and Sims, H.L., Z-factor determina-
tion in a digital computer," OGL July 20, 1959,
from Iraq to the Red Sea. That 602- Six Daniel Model 2522 (8088-
pp. 80-81. mile pipeline is set for completion based, 128 RAM) microcomputers
4. Sarem, A.M., "Z-factor equation developed for later this year. perform flow-measurement calcula-
use in digital computers," OGL Sept. 18, 1961,
p. 118. In February of last year, the pipeline tions and handle individual line-pro-
5. Dranchuk, P.M., and Quon, D., "A general contractor, Mitsubishi Corp., selected cessing tasks based on input from
solution of the equations describing steady state
turbulent compressible flow in circular con- Daniel to build the system. Design, each metering station's six turbine
duits," )CPT, Summer 1965, pp. 60-65. construction, and flow testing were flow meters and various temperature
6. Papay, J., "A terrnelestechnologiai pararneterek
valtozasa a gaztelepek muvelese soran." OGIL
conducted at Daniel's Houston facili- and pressure sensors.
MOsz. Tud. kozl.. Budapest, 1968, pp. 267-73. ty. The project has been completed Operator interface is provided by a
7. Hankinson, R.W., Thomas, L.K., and Phillips, ahead of schedule. pair of Daniel model-600 IBM Pc/AT-
K.A., "Predict natural gas properties," Hydro-
carbon Processing, April 1969, pp. 106-108. Cash register. Daniel's Yanbu sys- compatible (80286-based) color-
8. Carlile, R.E., and Gillett, B.E., "Digital solu- tem weighs over 275 tons and will graphics computers with proprietary
tions of an integral," OGL July 19, 1971, pp.
68-72. occupy more than 7,000 sq ft when data-collection and communications
9. Yarborough, L., and Hall, K.R., "How to solve installed. It will perform as a "cash programs.
equation of state for Z-factors," OGL Feb. 18,
1974, pp. 86-88.
register" for the IPSA-2 pipeline. Three berths. The system consists of
10. "Two-phase Flow in Pipes," Intercomp Course, In addition to the mechanical flow- three separate loading berths and,
The Hague, 1974. control equipment, it uses a micro- with its automated control system,
11. Dranchuk, P.M., Purvis, R.A., and Robinson,
D.B., "Computer calculations of natural gas processor-based instrumentation sys- can load three super-tankers simulta-
compressibility factors using the Standing and tem to ensure accurate measurement neously. The system's electronic and
Katz correlation," lnst. of Petroleum Technical
Series, o. IP 74-008, 1974. of the crude oil being delivered. mechanical measuring components
12. Dranchuk, P.M., and Abou-Kassem, J.H., "Cal- Two Daniel MM3000 system-con- were specifically selected from field-
culations of Z-factors for natural gases using
equations of state," )CPT, July-September 1975,
trol-unit microcomputers, three me- proven products manufactured by
pp. 34-36. tering-station-control cabinets, and Daniel.
13. Gopal, V.N., "Gas Z-factor equations devel- two color-graphics terminals form the After delivery, Daniel will provide
oped for computer," OGL Aug. 8, 1977.
14. Burnett, R.R., "Calculator gives compressibility operations and monitoring center for the expertise required to ensure suc-
factors," OGL June 11, 1979, pp. 70-74. the tanker-loading system's instru- cessful commissioning, training for
15. Papp, I., "Uj m6dszer Ioldgazok elteresi tenve-
zojenek szamirasara," koola] es Foldgaz, No- mentation and flow-control equip- operating personnel, and future field
vember, 1979, pp. 345-47. ment. service.

46 Oil & Gas Journal, May 15,1989 TECHNOLOGY