You are on page 1of 8

Fluid Phase Equilibria 201 (2002) 287–294

Fallibility of analytic roots of cubic equations


of state in low temperature region
Yun Zhi a,∗ , Huen Lee b
a
Department of Chemical Engineering, Separation Engineering Research Center,
Nanjing University of Chemical Technology, Nanjing 210009, PR China
b
Department of Chemical Engineering, Korea Advanced Institute of Science and Technology,
373-1 Kusong-dong, Yusong-gu, Taejon 305-701, South Korea
Received 11 March 2000; accepted 24 January 2002

Abstract
It is showed by several examples that, in low temperature region, the analytical solutions of cubic equation of state
(EOS) lead to irrational results, while the iterative solutions of cubic EOS by using the Newton–Raphson method
produce valid results. Errors caused by the limitation of significant figures of the computer languages are revealed,
and a magnification of errors is defined which is a main factor bringing out the irrational results of the analytical
solution of cubic EOS.
© 2002 Elsevier Science B.V. All rights reserved.
Keywords: Cubic equation of state; Analytic roots; Fallibility; Low temperature

1. Introduction

Since van der Walls presented his famous equation of state (EOS) about 100 year ago, various EOS
have been developed. Among varieties of type of EOS, the number of cubic EOS may be the largest one.
As cubic EOS has a notable advantage over complex EOS in its mathematical simplicity, it has attracted
numerous researchers and played an important role in engineering calculations.
The complex EOS, such as the celebrated BWR EOS [1] etc., can not be solved analytically for
compressibility factors or specific volumes with temperature and pressure specified. The trial or iterative
methods are always needed to solve the complex EOS for getting their roots one by one, and after
these roots being obtained, to discriminate them is often needed too. On the other hand, for the cubic
EOS, analytical solutions can be easily got by using a relevant math formula, i.e. Cardan’s method to
solve EOS for their three roots simultaneously, as recommended by some textbooks on thermodynamics

Corresponding author.
E-mail address: zyun99@hotmail.com (Y. Zhi).

0378-3812/02/$ – see front matter © 2002 Elsevier Science B.V. All rights reserved.
PII: S 0 3 7 8 - 3 8 1 2 ( 0 2 ) 0 0 0 7 2 - 9
288 Y. Zhi, H. Lee / Fluid Phase Equilibria 201 (2002) 287–294

[2,3]. Generally speaking, with this merit, the cubic EOS make the programming and calculations of
thermodynamics concerned easier and simpler than the complex EOS do. In recent years, some non-cubic
EOS have been successfully developed, but no direct solution for them like a cubic EOS was considered
as a drawback [4].
However, for phase equilibria calculation involving infeasible conditions, Mathias et al. [5] developed
a heuristic and iterative procedure to calculate density roots using EOS, no matter cubic or non-cubic,
and the procedure is as efficient as analytical approaches. Furthermore, a detailed study made by Mathias
and Benson [6] showed that, for most cases of phase equilibria calculations, the computational load
of cubic equations are approximately equivalent to more complicated equations. In the case of a pure
component, the cubic equations are more computationally rapid than the more complicated equations, but
the difference becomes small for systems with many components. The larger the number of components,
the smaller the difference, as most of the CPU time is spent in calculating mixing-rule summations.
But, it seems that the valid of analytical roots of cubic EOS is beyond suspicion, and has not been
explored in literature yet. Even in the case of a pure component, there is a problem with analytic roots of
cubic EOS which was found in low temperature region by authors. The aim of this work is to demonstrate
several examples of the fallibility and discuss the reasons which cause the fallibility.

2. Calculations and results

Three well known cubic EOSs, PR [7], PT [8], and CCOR EOSs [9] are adopted as examples in this work.
In the literature [2,10,11], there are different expressions of the math formula needed for the analytic
solution of cubic equations, but the essences of which are in fact the same, i.e. Cardan’s method. In this
work, the formula recommended by Tester and Modell [2] is used. As in the temperature and pressure
ranges concerned in this work, the cubic EOS will certainly have three real roots, for lucidity, the cases
of less than three real roots are not taken into account.
Suppose a cubic EOS being arranged as a polynomial form
f (z) = z3 + c1 z2 + c2 z + c3 = 0 (1)

where z is compressibility factor, c1 , c2 and c3 the coefficients dependent on temperature and pressure.
According to the approach illustrated by Tester and Modell [2], let
q = 19 (3c2 − c12 ) (2)

r = 16 c1 c2 − 21 c3 − c
1 3
27 1
(3)

Then, three real roots are given by


   
√ arccos r/ −q 3
z1 = 2 −q cos  − c1 (4)
3 3
    
√ arccos r/ −q 3 c1
z2 = 2 −q cos + 120  −

(5)
3 3
Y. Zhi, H. Lee / Fluid Phase Equilibria 201 (2002) 287–294 289
    
√ arccos r/ −q 3 c1
z3 = 2 −q cos + 240  −

(6)
3 3

where z2 is the smallest root representing the compressibility factor of liquid phase, z3 is the largest root
representing the compressibility factor of vapor phase, z1 has no physical significance.
It is not the accuracy of the model we are concerned, but the validity of the compressibility factor
calculation. For the facility of discussion, only liquid compressibility factors and liquid volumes are
concerned in the following calculation.
Liquid molar volume is given by
RT
V = z2 (7)
P
where R is the gas constant, T the temperature, and P the saturated vapor pressure which, in this work, is
given by [12]
 q2 
P = exp q1 + + q3 ln T + q4 T q5 (8)
T
where q1 , q2 , q3 , q4 and q5 are constants depended on substances.
The liquids molar volumes of three pure substances (propylene, 1-butene and 1-pentene) are calculated
by the above procedure, and the results are listed in the Tables 1–3, denoted as Vf .

Table 1
Comparison among experimental and calculated liquid volumes for propylene
Number T (K) Tr P (MPa) Ve PT PR CCOR
Vn Vf Vn Vf Vn Vf

1 87.9 0.241 9.18E−10 55.07 57.94 −2197.4 53.91 1002.6 55.50 521.22
2 89.4 0.245 1.60E−09 55.18 58.02 1008.7 53.97 981.03 55.64 88.626
3 90.9 0.249 2.74E−09 55.29 58.09 −132.6 54.04 −159.66 55.78 27.537
4 92.4 0.253 4.59E−09 55.39 58.16 135.3 54.10 108.88 55.92 63.887
5 93.9 0.257 7.56E−09 55.50 58.24 109.19 54.17 83.30 56.06 59.85
6 95.4 0.262 1.22E−08 55.61 58.31 55.98 54.23 71.18 56.20 51.98
7 96.9 0.266 1.95E−08 55.72 58.39 62.74 54.30 54.68 56.34 56.71
8 98.4 0.270 3.06E−08 55.84 58.47 57.49 54.37 58.28 56.48 55.90
9 99.9 0.274 4.73E−08 55.95 58.54 60.66 54.44 52.62 56.62 56.43
10 101.4 0.278 7.21E−08 56.06 58.62 58.30 54.51 54.25 56.75 56.82
11 102.9 0.282 1.08E−07 56.17 58.70 59.35 54.58 54.43 56.89 56.89
12 127.9 0.351 2.08E−05 58.17 60.16 60.16 55.87 55.87 59.19 59.19
13 152.9 0.419 6.03E−04 60.39 61.90 61.90 57.42 57.42 61.53 61.53
14 177.9 0.488 6.09E−03 62.91 64.01 64.01 59.30 59.30 63.98 63.98
15 202.9 0.556 3.24E−02 65.79 66.62 66.62 61.63 61.63 66.67 66.67
16 227.9 0.625 1.14E−01 69.16 69.91 69.91 64.58 64.58 69.73 69.73
290 Y. Zhi, H. Lee / Fluid Phase Equilibria 201 (2002) 287–294

Table 2
Comparison among experimental and calculated liquid volumes for 1-butene
Number T (K) Tr P (MPa) Ve PT PR CCOR
Vn Vf Vn Vf Vn Vf

1 87.8 0.209 3.56E−13 70.09 75.79 1628.5 70.37 1671.6 69.63 −8310460
2 91.3 0.218 1.87E−12 70.35 75.96 1550.2 70.50 1601.8 69.95 −2053680
3 94.8 0.226 8.58E−12 70.62 76.15 −370983 70.63 1536.6 70.27 6370.11
4 98.3 0.234 3.51E−11 70.89 76.34 1411.1 70.77 1475.6 70.59 5940.21
5 101.8 0.243 1.29E−10 71.16 76.53 1349.1 70.90 1418.4 70.91 5548.8
6 105.3 0.251 4.32E−10 71.44 76.72 1291.4 71.04 1364.8 71.22 5191.4
7 108.8 0.259 1.33E−09 71.71 76.92 1237.7 71.19 −5679.9 71.54 −2129.9
8 112.3 0.268 3.79E−09 72.00 77.12 −36.61 71.33 1266.9 71.86 202.2
9 115.8 0.276 1.01E−08 72.28 77.33 78.65 71.48 71.69 72.17 −91.96
10 119.3 0.284 2.51E−08 72.57 77.55 77.75 71.63 51.00 72.49 92.06
11 122.8 0.293 5.92E−08 72.86 77.76 75.89 71.78 50.81 72.80 71.29
12 126.3 0.301 1.32E−07 73.16 77.98 78.12 71.94 76.89 73.12 72.85
13 161.3 0.384 4.98E−05 76.34 80.49 80.49 72.10 71.94 73.43 73.07
14 196.3 0.468 1.80E−03 80.00 83.63 83.63 74.20 74.20 77.11 77.11
15 231.3 0.551 1.90E−02 84.31 87.66 87.66 76.86 76.86 80.94 80.94
16 266.3 0.635 9.86E−02 89.52 93.01 93.01 80.28 80.28 85.15 85.15

Table 3
Comparison among experimental and calculated liquid volumes for 1-pentene
Number T (K) Tr P (MPa) Ve PT PR CCOR

Vn Vf Vn Vf Vn Vf
1 107.93 0.232 4.48E−12 86.64 91.05 1961.51 89.11 1946.1 86.44 8026.3
2 111.43 0.240 1.67E−11 86.94 91.23 1881.09 89.28 1866.4 86.86 7468.2
3 114.93 0.247 5.70E−11 87.25 91.42 1805.88 89.46 1791.8 87.27 6961.1
4 118.43 0.255 1.79E−10 87.56 91.61 1735.39 89.64 −20549 87.69 6499.1
5 121.93 0.262 5.24E−10 87.87 91.80 1669.2 89.83 1656.3 88.10 −1771.1
6 125.43 0.270 1.43E−09 88.19 92.00 1607.0 90.02 1594.5 88.51 161.2
7 128.93 0.277 3.68E−09 88.51 92.20 99.54 90.21 87.57 88.92 46.3
8 132.43 0.285 8.92E−09 88.83 92.40 122.2 90.41 22.16 89.33 81.1
9 135.93 0.292 2.06E−08 89.16 92.61 84.82 90.61 82.88 89.75 85.69
10 139.43 0.300 4.52E−08 89.49 92.82 91.59 90.82 91.30 90.16 90.18
11 142.93 0.308 9.50E−08 89.83 93.04 92.45 91.03 92.39 90.57 90.38
12 146.43 0.315 1.92E−07 90.17 93.26 93.18 91.24 91.27 90.98 90.92
13 149.93 0.323 3.73E−07 90.51 93.49 93.45 91.46 91.41 91.40 91.40
14 184.93 0.398 5.93E−05 94.18 96.04 96.04 93.92 93.92 95.59 95.59
15 219.93 0.473 1.48E−03 98.36 99.20 99.20 96.97 96.97 100.0 100.0
16 254.93 0.548 1.32E−02 103.21 103.20 103.20 100.83 100.83 104.84 104.84
Y. Zhi, H. Lee / Fluid Phase Equilibria 201 (2002) 287–294 291

For the purpose of comparisons, the Newton–Raphson method [11], i.e.


f (zk )
zk+1 = zk − (9)
f  (zk )
is used iteratively for solving Eq. (1) too. The results denoted as Vn are also listed in the tables.
The following equation [11] is adopted to produce liquid molar volumes for representing experimental
data which are also listed in the tables for the comparisons.
(1+(1−(T /S2 )))S3
S1
Ve = (10)
S4
where S1 , S2 , S3 and S4 are constants depended on substances.
From the Tables 1–3, it is easy to notice that in the low temperature region, i.e. in the region of about
Tr < 0.3, the analytical solutions of three cubic EOS give unreasonable results. It should be pointed out
that all calculations carried out in this work are based on double-precision arithmetic. If single-precision
arithmetic is used, the results given by the analytical solutions will be worse.
The tables also show that the results produced by Newton–Raphson iterative method are reasonable
in comparison with experimental data, which means it is arithmetic, not cubic EOS themselves that are
responsible for the errors.

3. Discussion

3.1. The limitation of signification figure

For any algorithmic language used in computers, the numbers of significant figure are finite. In this
work, the C language is used. Based on double-precision arithmetic, all variables used in the program
made by the C language have 16 significance digits. It is easy to understand that when more than 16
significance digits is needed by a operation during a calculation, the calculated result will certainly more
or less be in error.
As examples, the following discussion will be focused on the calculation of liquid volume of 1-pentene
by PT EOS at the condition of T = 121.93 K, P = 5.24 × 10−10 MPa which is produced by Eq. (8).
For PT EOS, c3 in Eq. (1) is given by
c3 = B 3 C + BC − AB (11)
where
Pa
A= (12)
R2T 2
Pb
B= (13)
RT
Pc
C= (14)
RT
where a, b and c are the constants of PT EOS which depend on substances.
292 Y. Zhi, H. Lee / Fluid Phase Equilibria 201 (2002) 287–294

At the condition given above,


B 3 C = 3.24620 × 10−42 (15)
BC = 1.60586 × 10−21 (16)
AB = 8.11908 × 10−21 (17)
Obviously, accurate algebraic operation among B3 C, BC and AB needs more than 16 significant figure.
However, due to the limitations of computers and their language, the contribution made by B3 C to c3 in
Eq. (11) is in fact nothing.
Then, let Eq. (3) be checked. Under the same condition defined above, three terms of it have the
following values, respectively
c
1 3
27 1
= −3.70370 × 10−2 (18)
1
cc
6 1 2
= −2.87523 × 10−10 (19)
1
c
2 3
= −3.97925 × 10−20 (20)
Once again, because of the limitation of significant figure, the contribution of c3 /2 to r in Eq. (3) is
ignored.

3.2. The magnification of error

Let
r
s= (21)
−q 3
and the error of s is s. So the Eq. (5), which representing liquid compressibility factor can be expressed
as

√ arccos(s) ◦ c1
z2 = 2 −q cos + 120 − (22)
3 3
The magnification of error is defined as
z/z2
M= (23)
s/s
where z is the error of z2 . When s tend to zero, M can be expressed as
√ 
dz s 2 −q arccos(s) ◦ 1 s
M= = sin + 120 √ (24)
ds z2 3 3 1 − s 2 z2

It is easy to see that when the value of s equals 1, the term 1/ 1 − s 2 will turn to infinity, and at the same
time, the other parts of the right side of the above Eq. (24) still remain finite, so the error magnification
M will become infinity too.
Unfortunately, in low temperature region, the values of s do tend to 1. For example, in the calculation
of liquid volume of 1-pentene by PT EOS at the condition of temperature and pressure given above, there
Y. Zhi, H. Lee / Fluid Phase Equilibria 201 (2002) 287–294 293

Table 4
The values of variables in Eqs. (3), (11) and (24) at different temperatures
107.93 K 121.93 K 135.93 K 149.93 K 254.93 K

Eq. (11) B3 C 2.84 × 10−50 3.25 × 10−42 4.99 × 10−36 3.64 × 10−31 6.81 × 10−14
BC 1.50 × 10−25 1.61 × 10−21 1.99 × 10−18 5.38 × 10−16 2.33 × 10−7
AB 8.86 × 10−24 8.12 × 10−20 8.75 × 10−17 2.08 × 10−14 4.31 × 10−6
Eq. (3) (1/6)c1 c2 −3.27 × 10−12 −2.88 × 10−10 −8.74 × 10−9 −1.25 × 10−7 −1.17 × 10−3
(1/2)c3 −4.36 × 10−24 −3.98 × 10−20 −4.27 × 10−17 −1.01 × 10−14 −2.04 × 10−6
(1/27)c13 −3.70 × 10−2 −3.70 × 10−2 −3.70 × 10−2 −3.70 × 10−2 −3.70 × 10−2
Eq. (24) s √ 1 1 1−8.0 × 10−16 1−1.6 × 10−13 1−1.1 × 10−4
1/ 1 − s 2 ∝ ∝ 7.8 × 106 5.5 × 105 6.6 × 101


is s = 1, which leads 1/ 1 − s 2 = ∞. Here s may not be exactly equal to 1, it could be in the region
of (1 − 1 × 10−16 ) < s < (1 + 1 × 10−16 ). But the computers can only output s = 1, for that the exact
expression of it may beyond the ability of the computer’s language.
In the Table 4, the values of variables in Eqs. (3), (11) and (24) for which PT EOS and 1-pentene
are concerned at different temperatures are listed. The comparisons among the values show that, as
temperature arises, the errors caused by the limitation of significant figures will become smaller, and at
same time, the error magnifications also reduce obviously.
From the Table 4, it can be noticed that even in low temperature region, the errors caused by the
limitation of√significant figures are so small that they can be ignored in the most cases, but the values of
the term 1/ 1 − s 2 are large√ enough to lead the errors being magnified tremendously. However, Eq. (9)
has nothing to do with 1/ 1 − s 2 , which is the reason why the Newton–Raphson method can give
corrective calculation results.
Finally, it should be pointed out that if Eq. (1) is transformed into a polynomial in molar volume V
instead compressibility factor z, the results of calculation are almost the same as that given above.

4. Conclusions

Due to the limitation of significant figures of the computer languages, and especially the effect of the
magnification of errors in low temperature region, the analytical solutions of cubic EOS lead to irrational
results. In contrast, the iterative solutions of cubic EOS by using the Newton–Raphson method produce
valid results. It is safer to use the iterative method than the analytical method for solving cubic EOS.
Generally speaking, at least in the region of Tr < 0.3, it is suggested to adopt the iterative method instead
of the analytical method.

List of symbols
a parameter in PT EOS
A variable in Eq. (11)
b parameter in PT EOS
B variable in Eq. (11)
c parameter in PT EOS
294 Y. Zhi, H. Lee / Fluid Phase Equilibria 201 (2002) 287–294

c1 , c2 , c3 coefficients of Eq. (1)


C variable in Eq. (11)
CCOR cubic chain-of-rotator EOS
f polynomial form of cubic EOS
M magnification of error
P saturated vapor pressure
PR Peng–Robinson EOS
PT Patel–Teja EOS
q variable in Eq. (2)
q1 , q2 , q3 , q4 , q5 constants in Eq. (8)
r variable in Eq. (3)
R gas constant
s variable in Eq. (21)
S1 , S2 , S3 , S4 variables in Eq. (10)
T temperature
V liquid molar volume
z compressibility factor

Superscripts
k kth iteration

degree

Subscripts
e experimental
f analytical solution
n Newton–Raphson method
r reduced property

References

[1] M. Benedict, G.B. Webb, L.G. Rubin, J. Chem. Phys. 8 (1940) 334–345.
[2] J.W. Tester, M. Modell, Thermodynamics and its Applications, 3rd Edition, Prentice-Hall, New Jersey, 1996, p. 925.
[3] J.M. Prausnitz, R.N. Lichtenthaler, E.G.D. Azevedo, Molecular Thermodynamics of Fluid-Phase Equilibria, Prentice-Hall,
New Jersey, 1999, p. 50.
[4] G. Soave, Fluid Phase Equilib. 56 (1990) 39–57.
[5] P.M. Mathias, J.F. Boston, S. Watanasiri, AIChE J. 30 (1984) 182–186.
[6] P.M. Mathias, M.S. Benson, AIChE J. 32 (1986) 2087–2090.
[7] D.-Y. Peng, D.B. Robinson, Ind. Eng. Chem. Fundam. 10 (1976) 59–64.
[8] N.C. Petal, A.S. Teja, Chem. Eng. Sci. 37 (1982) 464–473.
[9] H. Kim, H-M. Lin, K.C. Cao, Ind. Eng. Chem. Fundam. 25 (1986) 75–84.
[10] R.H. Perry, D.W. Green, J.O. Maloney, Perry’s Chemical Engineers’ Handbook, 6th Edition, McGraw-Hill, New York,
1984, pp. 2–15.
[11] D. Zwillinger et al. Standard Mathematical Tables and Formulae, CRC Press, Boca Raton, 1996, p. 82.
[12] T.E. Daubert, Danner, Physical and Thermodynamic Properties of Pure Chemicals, Hemisphere, New York, 1989.

You might also like