Download as pdf or txt
Download as pdf or txt
You are on page 1of 7

Increasing the Computational Speed of

Flash Calculations With Applications for


Compositional, Transient Simulations
Claus P. Rasmussen, SPE, Calsep A/S; Kristian Krejbjerg, SPE, Calsep Inc.; Michael L. Michelsen, IVC-SEP,
Technical U. of Denmark; and Kersti E. Bjurstrøm, Scandpower Petroleum Technology A/S

Summary simulation far exceeds that of a corresponding noncompositional,


Approaches are presented for reducing the computation time spent table-based simulation; furthermore, the computation time in-
on flash calculations in compositional, transient simulations. In a creases with an increased number of components.
conventional flash calculation, the majority of the simulation time Consider, as an example, a typical transient pipeline simulation.
is spent on stability analysis, even for systems far into the single- The total number of discretized sections depends on the total
phase region. A criterion has been implemented for deciding when length of the pipeline and the desired degree of detail in the simu-
it is justified to bypass the stability analysis. With the implemen- lation, but a typical number of sections is approximately 100. The
tation of the developed time-saving initiatives, it has been shown total number of timesteps depends on slug formation, liquid
for a number of compositional, transient pipeline simulations that holdup, and varying boundary conditions but is often in the order
a reduction of the computation time spent on flash calculations by of 50,000. That is, a compositional, transient pipeline simulation
approximately 85 to 90% can be achieved. comprising 100 sections and 50,000 timesteps requires 5 million
flash calculations.
Introduction Even with an optimized algorithm, the flash computation time
Modeling of oil production requires simulations of transient flow. typically constitutes 70 to 80% of the total computation time re-
Examples are miscible-gas displacement in petroleum reservoirs quired for a compositional, transient pipeline simulation. It is
and multiphase flow in pipelines, including slug formation and therefore highly desirable to be able to reduce the computation
startup scenarios. In a typical transient-flow simulation, the system time associated with flash calculations.
is discretized into a number of cells or sections. Phase amounts and To further investigate the computation time spent on flash cal-
phase properties are needed for each cell or section to solve the culations in a typical compositional, transient simulation, condi-
conservation equations in the model, and specifically for transient tions have been recorded in an arbitrarily selected section during
pipeline simulations to calculate such properties as heat loss to the an actual compositional, transient pipeline simulation. The condi-
surroundings, liquid holdup, and pressure drop. If the overall com- tions comprise changes in overall composition z, pressure p, and
position is constant during the simulation, the phase properties can temperature T during 1,757 timesteps.
be stored in precalculated tables listing the needed properties as a In the present work, a hydrocarbon fluid lumped to 6, 12, and
function of pressure and temperature (Bendiksen et al. 1991; Xu 18 components, respectively, is investigated. For each lumped
and Shea 2001). This is referred to in the following sections as a fluid, a set of noncritical and near-critical conditions have been
noncompositional, table-based simulation. investigated, giving a total of six different scenarios. To facilitate
When simulating miscible-gas displacement in reservoirs, the a verification of the outlined procedures, the variations in overall
assumption of a constant overall composition is not adequate be- composition, pressure, and temperature with time have been ap-
cause the injection gas will dissolve in the reservoir fluid and vice proximated using sixth-degree polynomials, as outlined in Eq. 1 in
versa. Similarly, in many typical multiphase pipelines, the fluid the noncritical scenario for the fluid lumped to six components. In
composition will vary because of velocity differences between addition, complete data describing all six cases are available in
phases, interfacial mass transfer, and merging networks. In these electronic form from the corresponding author (cpr@calsep.com).
situations, a compositional approach is useful. A compositional
model has the drawback that the computation time is much higher
6

兺 a t . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (1)
than that of a noncompositional table-based approach. The phase
amounts and properties must be evaluated in each cell or section in ␾j = j i
i
i=0
each timestep. Furthermore, phase compositions are required to
calculate the interfacial mass transfer. Nevertheless, the increased
accuracy in the fluid description makes the compositional ap- In Eq. 1, ␾j is composition, pressure, or temperature; aji are poly-
proach attractive to represent multiphase pipelines and reservoirs nomial coefficients; and t is the index for the timestep. The poly-
with large compositional variations. nomial coefficients describing the change in pressure and tempera-
ture for all timesteps (1 ⱕ t ⱕ 1,757) in the six-component, non-
Flash Equilibrium Calculations in Compositional, critical scenario, are given in Table 1a.
Transient Simulations The polynomial coefficients describing the change in compo-
The physical properties of a fluid in a cell or section depend on sition for timesteps above 944 in the six-component, noncritical
whether the fluid is present as a single phase or splits into several scenario are given in Table 1b.
equilibrium phases. A flash calculation is therefore required in In the initial part of the simulation (t < 944), the overall com-
each timestep to determine the number of equilibrium phases and position is constant and equal to the following:
their amounts and compositions. Even with relatively few mixture N2+CO2 : 3.6583 mol%
components, the computation time of a compositional, transient C1–C3 : 94.7852 mol%
C4 : 1.1024 mol%
C5–C6 : 0.3688 mol%
Copyright © 2006 Society of Petroleum Engineers C7 : 0.0758 mol%
This paper (SPE 84181) was first presented at the 2003 SPE Annual Technical Conference C8–C14 : 0.0095 mol%
and Exhibition, Denver, 5–8 October, and revised for publication. Original manuscript re-
ceived for review 29 October 2003. Revised manuscript received 6 October 2005. Paper
The critical pressures, critical temperatures, and acentric factors
peer approved 8 October 2005. of each component in the six-component fluid can be seen in

32 February 2006 SPE Reservoir Evaluation & Engineering


yi
Ki = , . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (3)
xi

where yi and xi are the mole fractions of component i in the gas and
liquid phases, respectively. The Wilson K-factors are used to cal-
culate the first approximation to the phase split and the phase com-
positions x and y. Subsequent equilibrium factors are obtained from

␸li共p,T,x兲
Ki = . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (4)
␸vi 共p,T,y兲

The successive substitution procedure is accelerated by means of


the dominant eigenvalue method and followed by a switch to a
second-order Gibbs energy minimization (using analytic deriva-
tives) if the accelerated successive substitution does not converge
rapidly. If the phase-split calculation fails to yield two phases,
Table 2, whereas the applied interaction coefficients for each bi- stability analysis by tangent plane distance minimization is per-
nary component pair can be seen in Table 3. formed (Michelsen 1982). The stability analysis will either con-
The six scenarios have been analyzed with respect to compu- firm that the fluid at the specified conditions forms a single, stable
tation time, when one flash calculation is carried out in each phase, or it will provide a composition estimate for a phase split
timestep using a traditional approach, where each calculation dis- and enable the phase-split calculation to be carried out.
regards information from previous timesteps or adjacent cells.
The simulation times shown in Table 4 are for computation
time spent only on flash calculations (i.e., the simulation time used Speeding Up Flash Calculations
on property calculations, flow calculations, etc. has been left out). The approach described above is designed for standalone flash
The simulations have been performed on a computer with a Pen- calculations, where the emphasis is on safety (i.e., avoiding pro-
tium IV 2.4-GHz processor and 512 MB RAM. The applied pro- gram failure) and correctness (i.e., that the correct number of
gramming language is Fortran, and the program has been compiled phases and the correct phase compositions are found). Preserving
with Compaq Visual Fortran version 6.6. these features, it is possible to take advantage of the typical situ-
For six components, the tabulated flash frequency corresponds ation in flow simulations, in which repeated solutions to equilib-
to a computation time of approximately 10 minutes for a typical rium calculations with only small changes in the conditions occur.
transient-flow scenario comprising 5 million flash calculations,
which is quite high. Furthermore, the computation time increases
linearly (or slightly stronger) with the number of components. The Two-Phase Region
In all six scenarios, approximately half the computation time is If two equilibrium phases are present in a cell at a given timestep,
spent on solving the equilibrium equations and the other half on it is very likely that two phases will also be present at the same
verifying stability (i.e., that the proper conditions correspond to a position in the next timestep. This scenario is usually encountered
single, stable phase). To further reduce the computation time, a when simulating miscible-gas displacement in reservoirs, but it
more efficient approach for both types of calculations will there- also occurs in pipeline simulations. The solution strategy for in-
fore be needed. creasing the computational speed of flash calculations in the two-
phase region in such situations has been thoroughly investigated
Basic Flash Algorithms previously, and the approach in this work is very similar to that of
The computation times of Table 4 are based on the methodology Michelsen (1998). Michelsen, however, deals only with the Soave-
for flash calculations described by Michelsen (1993) and in more Redlich-Kwong (SRK) equation of state (Soave 1972) with clas-
detail by Michelsen and Mollerup (2004). Initial estimates for the sical mixing rules, whereas the procedures in the actual work are
K-factors are obtained from the Wilson approximation: generally applicable to any equation of state.

冉 冊
It should be noted that cubic equations of state with nonclas-
pci Tci sical mixing rules [such as that of Huron and Vidal (1979)] or new
ln KWilson
i = ln + 5.373共1 + ␻i兲 1 − . . . . . . . . . . . . . . (2) equations of state [e.g., the Cubic-Plus-Association (CPA) equa-
p T
tion of state (Kontogeorgis et al. 1996)] are required for a satis-
In Eq. 2 pci, Tci, and ␻i are critical pressure, critical temperature, factory description of multiphase flow in pipelines. In such sce-
and acentric factor, respectively, for component i. Ki is the equi- narios, both hydrocarbons and polar components, such as water
librium factor, and liquid hydrate inhibitors, are present.

February 2006 SPE Reservoir Evaluation & Engineering 33


tangent plane distance are investigated. These are located as com-
positions w, satisfying

ln wi + ln ␸i共w兲 − ln zi = ln ␸i共z兲 = k, 兺 w = 1 . . . . . . . . . . . (7)


i
i

In Eq. 7, z represents the composition of the phase to be tested for


stability. The value of the tangent plane distance at the minimum
equals the constant k, and stability requires that this value is non-
negative at all minima. To ensure that a phase is stable, it is
therefore necessary to verify that k is non-negative at all minima.
Eq. 7 is seen to always have the noninformative “trivial solution,”
w⳱z; k⳱0.
The character of the solutions to the set of equations in Eq. 7
depends on the location in pT space of the phase z to be tested,
In the present approach, the results of the previous timestep, relative to the phase boundary. Fig. 1 shows a typical phase en-
t–1, are used as initial estimates as follows: velope for a reservoir oil mixture.
Calculate distribution fractions ␪i from The following cases exist:

冋 册
1. The phase is unstable [i.e., the mixture will form two phases
␤yi (Point A, Fig. 1)]. In this case, Eq. 7 will have one or two solutions
␪i = , . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (5)
␤yi + 共1 − ␤兲xi t−1 for which k is negative.
2. Exactly at the phase boundary (Point B). Here, one solution
and use these as initial estimates for the current timestep, t.
to Eq. 7 will be the trivial solution and the other a nontrivial
vi = zti␪i, li = zti共1 − ␪i兲 , . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (6) solution (representing the composition of the incipient phase) with
a value of k equal to zero.
where vi and li are the molar amounts of component i in the vapor 3. In the single-phase region, but “close to” the phase boundary
and the liquid phase. With these initial estimates, successive sub- (Point C). One solution to Eq. 7 will be the trivial solution and the
stitution is skipped, and the simulation proceeds directly to second- other a nontrivial solution with a positive value of k. Increasing the
order Gibbs energy minimization. Most likely, convergence will distance from the phase boundary increases the value of k. This region
take place after one or two iterations. If this is not the case, or if will, in the following, be referred to as the “shadow-phase region.”
any “problems” arise (e.g., iterations leading to negative compo- 4. “Far from” the phase boundary (Point D). Only the trivial
sition variables), the calculation procedure reverts to the safe tra- solution is obtained.
ditional procedure described previously. Such problems are typi- The essential purpose of stability analysis is to distinguish between
cally encountered when crossing the phase boundary between the Case 1 and the other cases. A failure to determine a negative
two-phase region and the single-phase region. tangent plane distance means that a mixture is taken to be a single
Alternatively, the approach of Michelsen (1980) could be used, phase even though it would form two phases. The objective is to
in which initial estimates are generated by linearly extrapolating reduce the amount of computation time spent on stability analysis
the converged phase compositions of the previous timestep to the to the smallest period possible while ensuring that the correct
current timestep by use of the Jacobian matrix. The approach has result is obtained.
been investigated, but it was found to provide no significant re- In the standard flash procedure, the solutions in the single-
ductions in computation time. phase region are determined through a full, two-sided stability
Table 5 shows computation times for the six scenarios de- analysis, with two different sets of initial estimates for the trial
scribed previously using the revised approach for the two-phase phase w, a gas-like composition and a liquid-like composition,
region. By comparing with Table 4, it can be seen that the total calculated by means of the Wilson K-factors, as shown in Eq. 8.
simulation time can be reduced by an average of approximately 45%.
Yi
The Single-Phase Region Yi = KWilson zi, wvap =
兺Y
i i
If the fluid in a given timestep forms a single, stable phase, it is j
j
most likely that it will remain as a single phase in the following
timestep. The traditional approach involving stability analysis can zi Xi
Xi = , i =
wliq . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (8)
determine whether the fluid at the current timestep still forms only
a single, stable phase or if two equilibrium phases have formed,
KWilson
i 兺Xj
j

but it is, as indicated earlier, relatively time consuming. An im-


portant focus of this work is, therefore, the development of a The procedure for carrying out the tangent plane distance minimi-
strategy that reduces the computation time spent on stability analy- zation is described in detail in Michelsen and Mollerup (2004).
sis in the single-phase region. Similar to the phase-split calculation, this procedure uses a
The stability analysis of the standard flash procedure is based combination of successive substitution and a second-order
on the tangent plane criterion of Gibbs (Michelsen 1982; Baker Gibbs energy minimization with a set of transformed variables.
et al. 1982). In the formulation of Michelsen (1982), minima of the With almost 20 years of use in the industry, this approach has

34 February 2006 SPE Reservoir Evaluation & Engineering


appeared extremely robust, and convergence problems have been
virtually absent.
emergent phase will be a gas phase, and it is therefore only nec-
In the two-phase region, one or both initial estimates converge
essary to search for a gas-like trial phase, hence the approach with
to a solution with a negative tangent plane distance. In the single-
the one-sided stability analysis. This approach allows the use of a
phase region close to the bubblepoint line (as Point C), the liquid-
second-order minimization approach right from the start. In most
like estimate will converge to the trivial solution, whereas the
cases, convergence is obtained in one or two iterations to a new
gas-like estimate will yield the nontrivial solution with a positive
minimum with either a positive value (still in the shadow-phase
k. Conversely, close to the dewpoint line, the trivial solution is
region) or a negative value (the simulation has moved into the
found from the gas-like estimate and the nontrivial from the liquid-
two-phase region, as for Point A). The final possibility is conver-
like. Finally, far from the phase boundary (Point D), both estimates
gence to the trivial solution. This happens when the conditions
result in the trivial solution. The limit at which a positive solution
have moved sufficiently far from the phase boundary in the direc-
to Eq. 7 can be found is shown as the dashed line in Fig. 1, and as
tion of Point D.
previously mentioned, the region between the phase boundary and
this line is denoted as the shadow-phase region.
The Single-Phase Region Outside the Shadow-Phase Region. If
a full stability analysis yields only the trivial solution, like Point D
The Single-Phase Region Inside the Shadow-Phase Re- in Fig. 1, it is evident that substantial changes in composition,
gion. Consider one section in a pipeline or one cell in a reservoir temperature, or pressure are required for a move into the two-phase
simulation. A full, two-sided stability analysis has, in a given region. It is possible to take advantage of that fact by saving the
timestep, shown that conditions correspond to a single phase like current composition, temperature, and pressure as references and
Point C in Fig. 1. This is indicated by the presence of a nontrivial completely bypass the stability analysis for the following timesteps
solution with a positive value of the tangent plane distance, k. The until substantial changes in composition, temperature, or pressure
resulting nontrivial solution denoted as the shadow phase (in this have taken place. When allowing stability analyses to be bypassed
example, originating from the gas-like estimate) is used as initial in the single-phase region, there is a risk that the detection of two
estimate for the w-composition for a tangent plane minimization in equilibrium phases may fail. To ensure the correct detection of
the subsequent timestep. The strategy for the shadow-phase region two-phase situations, it is necessary to be able to locate the phase
is, therefore, somewhat similar to the strategy used for the two- boundary based only on the current composition, temperature, and
phase region described previously. pressure and the history of the system in the previous timesteps.
However, significant differences exist between the two ap- Far from the critical point, the width of the shadow-phase region
proaches. In the two-phase region, the full stability analysis is is significant, and the allowed changes in composition, tempera-
completely bypassed, and calculations proceed directly to the ture, and pressure are determined accordingly to ensure that at least
phase-split calculation, where the converged phase amounts and one full stability analysis will be performed inside the shadow-
compositions from the previous timestep are used as initial esti- phase region. The calculation procedure will then revert to the
mates. In the shadow-phase region, the approach with a full two- shadow-phase approach (i.e., the shadow-phase region acts as a buffer
sided stability analysis is abandoned in favor of a one-sided sta- zone preventing the failure to detect the presence of two phases).
bility analysis. Because the converged shadow phase originates The width of the shadow-phase region, however, decreases
from the gas-like estimate, the phase boundary is approached from sharply in the vicinity of the critical point, and the changes allowed
the region of a single-phase liquid. On the phase boundary, the before reinitiating a full stability analysis must therefore be related
to the distance from the critical point. Close to the critical point,
only very small changes are allowed before a complete stability
analysis is performed again. For this purpose, a simple and easily
calculated measure of the distance from the critical point is required.
The matrix of composition derivatives of the fugacity coeffi-
cients provides this measure. Michelsen (1982) defines

Bij = ␦ij + 公ninj 冉 冊


⭸ ln ␸i
⭸nj p,T
. . . . . . . . . . . . . . . . . . . . . . . . . . (9)

For an ideal solution, all eigenvalues of B are equal to 1. At the


limit of intrinsic stability (the spinodal) and at the mixture critical
point, the smallest eigenvalue of B equals 0 (Michelsen 1982). In
addition, the spinodal and the phase boundary have a common
tangent at the mixture critical point. The smallest eigenvalue of
B⳱b has therefore been chosen as the measure of distance.
The phase boundary in the critical region of the mixture of Fig.
1 is shown in Fig. 2, together with the spinodal and other lines of
constant b. In the “dangerous” region in the vicinity of the critical
point, where the shadow-phase region is very narrow, it is noted
Fig. 1—Phase diagram for a typical oil. that the value of b provides an excellent measure of the distance to

February 2006 SPE Reservoir Evaluation & Engineering 35


certain favorable conditions, the set of equations that must be
solved in equilibrium calculations can be reduced from the number
of components, C, to a smaller number (typically three to six).
The first such approach was that of Michelsen (1986), who
Fig. 2—Contour plot of parameter b.
demonstrated that in cases in which all binary interaction coeffi-
cients in a cubic equation-of-state model are zero, the equilibrium
the phase boundary. When the full stability analysis only results in equations are reduced to three. Later methods, such as those of
trivial solutions, the minimum eigenvalue, b, is calculated and Hendriks (1988), Firoozabadi and Pan (2002), and Pan and
stored together with the composition, temperature, and pressure. Firoozabadi (2003), approximate the matrix of binary interaction
As mentioned above, in the following timesteps, all calculations coefficients with a matrix of less than full rank, (typically of rank
are bypassed unless the changes in these variables exceed a speci- 1 to 3) or make other assumptions about the interdependence of the
fied tolerance chosen to be proportional to b. interaction coefficients. The advantage claimed by proponents of
Along the phase boundary, in the vicinity of the critical point, the reduction methods is that the smaller size should result in both
b is to a first approximation proportional to the square of the quicker and more-stable solution procedures.
distance from the critical point, and the relative change in b from With the potential exception of the rare case in which all in-
the phase boundary to the outer perimeter of the shadow-phase teraction coefficients can be assumed to be zero, the authors will
region is approximately 1/8 (Michelsen 1984). Based on this and a question that such a speed advantage exists. The set of equations
large number of simulation experiments, the purely empirical corre- to be solved in the reduction methods appears much more complex
lations in Eq. 10 have been determined for bypassing stability analysis than that of the traditional approach; in particular, the evaluation of
in the single-phase region outside the shadow-phase region. the Jacobian matrix or its equivalent seems very cumbersome (Pan
bold and Firoozabadi 2003). With the same number of independent vari-
|zi − zi,old| ⱖ ables, the reduction methods can therefore be expected to be substan-
10
tially less computationally efficient than the traditional approach.
bold p Proponents of the reduction methods claim that in the tradi-
|p − pold| ⱖ tional formulation, the computation time increases with the third
10
power of the component number, C (Firoozabadi and Pan 2002),
|T − Told| ⱖ 10bold . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (10) making it infeasible to use when many components (e.g., 15 to 20)
In Eq. 10, zi, T, and p denote the composition, temperature, and are required for the fluid description. From the present examples,
pressure, respectively, at the current timestep, whereas zi,old, Told, it is obvious that the third-power variation does not hold. Accord-
pold, and bold denote the composition, temperature, pressure, and ingly, there is no potential speed advantage of reduction methods
value of b at the timestep where the previous full stability analysis for mixtures with many components because the observed devel-
was performed. opment in computation time with the number of components is
Table 6 shows the gains from using the revised approaches to close to linear. A fair comparison of the reduction method and the
flash calculations in both the single- and two-phase regions for the traditional flash is therefore dependent on an optimum implemen-
examples used previously in Tables 4 and 5. tation of the traditional flash, and the authors have never encoun-
As can be seen from Table 6, the six-component near-critical tered the problems described in Firoozabadi and Pan (2002) and
scenario appears to give deviating results as compared to the other Pan and Firoozabadi (2003).
near-critical cases. The reason is the lumping of the fluid. When Finally, the reduction methods are limited to cubic equations of
lumping down to six components, some fluid-description accuracy state with additional restrictions on the interaction coefficients
is lost, resulting in the fluid behavior of this particular near-critical and, except in rare cases, cannot reproduce the original equation of
scenario being considerably different from the remaining near- state exactly. In contrast, the methodology presented here is com-
critical scenarios. pletely general and does not imply any restrictions on the equation
Furthermore, it is seen from Table 6 that the total computation of state used.
time is decreased dramatically by applying the criteria of Eq. 10
for determining when to bypass two-sided stability analysis in the Extension to More Than Two Phases
single-phase region outside the shadow-phase region. For six com- An extension of the presented methodology to mixtures forming
ponents, the tabulated flash frequency corresponds to a computa- more than two phases is in several ways straightforward but does
tion time of approximately 1 minute for a typical transient-flow introduce new complexities. A typical extension would be to in-
scenario comprising 5 million flash calculations. clude an aqueous phase that, in addition to water, might contain
In the above simulations, it was furthermore observed that, alcohols, glycols, and dissolved hydrocarbons. In case all phases
although more than 98% of all stability investigations were being were present in the previous timestep, direct application of a sec-
bypassed by this approach, no misidentifications occurred. ond-order approach with initial estimates from the previous step is
the obvious choice, and the same applies when only two of the
Alternative Ways of Reducing the three phases were present.
Computation Time The added complexity relates to the stability analysis, where it
A potential alternative approach is to use the “reduction methods” is now necessary to investigate a variety of different possibilities.
approach. These methods take advantage of the fact that under When a hydrocarbon phase is missing, it is expected that the

36 February 2006 SPE Reservoir Evaluation & Engineering


criteria for bypassing stability analysis can be used unchanged, and ␾ ⳱ composition, pressure, or temperature
when an aqueous phase is missing, stability analysis is expected to ␸ ⳱ fugacity coefficient
be fairly straightforward because the composition of the trial phase ␪ ⳱ fraction of components ending up in the gas phase
is dominated by water. In particular, the stability analysis is ex- ␻ ⳱ acentric factor
tremely simple if the aqueous phase is assumed to contain only
pure water (a reasonable assumption when alcohols, glycols, and Acknowledgments
salts are not present) because the stability analysis only requires
that the fugacity of water dissolved in the hydrocarbon phases is The authors wish to thank Allan K. Rydahl, Scandpower Petro-
checked against that of pure water. leum Technology Inc., for helpful contributions.

References
Conclusions
Baker, L.E., Pierce, A.C., and Luks, K.D.: “Gibbs Energy Analysis of
Approaches for reducing the flash calculation computation time in Phase Equilibria,” SPEJ (October 1982) 22, No. 5, 731.
compositional, transient simulations on hydrocarbon systems have Bendiksen, K.H., Malnes, D., Moe, R., and Nuland, S.: “The Dynamic
been presented and discussed. The methodology is based on the Two-Fluid Model OLGA: Theory and Application,” SPEPE (May
assumption that in the majority of simulations, only small changes 1991) 6, No. 2, 171; Trans., AIME, 291.
in pressure, temperature, or composition will take place from one
Firoozabadi, A. and Pan, H.: “Fast and Robust Algorithm for Composi-
timestep to the next in a given section or cell of a pipeline or
tional Modeling: Part I—Stability Analysis Testing,” SPEJ (March
reservoir. In the two-phase region, results from the previous
2002) 7, No. 1, 78.
timestep are used as estimates of the solution in the current
Hendricks, E.M.: “Reduction Theorem for Phase Equilibrium Problems,”
timestep. In the single-phase region, a criterion has been estab-
Ind. Eng. Chem. Res. (1988) 27, 1728.
lished for evaluating whether a stability analysis is needed or can
Huron, M.J. and Vidal, J.: “New Mixing Rules in Simple Equations of
be bypassed. To prevent an erroneous single-phase prediction in
State Representing Vapor-Liquid Equilibria of Strongly Non-Ideal
the two-phase region resulting from bypassed stability analyses, a
Mixtures,” Fluid Phase Equilibria (1979) 3, 255.
buffer zone denoted as the shadow-phase region is used in the
vicinity of the phase boundary away from the critical point. An- Kontogeorgis, G.M., Voutsas, E.C., Yakoumis, I.V., and Tassios, D.P.:
other measure is used to predict the distance to the phase boundary “An Equation of State for Associating Fluids,” I&EC Research (1996)
in the near-critical region. These measures provide a safe proce- 35, 4310.
dure for bypassing stability analysis along the whole phase bound- Michelsen, M.L.: “Calculation of Phase Envelopes and Critical Points for
ary. For the test scenarios considered, these approaches reduce Multicomponent Mixtures,” Fluid Phase Equilibria (1980) 4, 1–10.
simulation time spent on flash calculations in a compositional, Michelsen, M.L.: “The Isothermal Flash Problem. Part I: Stability,” Fluid
transient-flow simulation by between approximately 85 and 90%. Phase Equilibria (1982) 9, 1–19.
For a six-component fluid, effectively 5 million flash calculations Michelsen, M.L.: “Calculation of Critical Points and Phase Boundaries in
can be carried out in approximately 1 minute when simulations are the Critical Region,” Fluid Phase Equilibria (1984) 16, 57.
performed on a computer with a Pentium IV 2.4 GHz processor Michelsen, M.L.: “Simplified Flash Calculations for Cubic Equations of
and 512 MB RAM. State,” Ind. Eng. Chem. Process Des. Dev. (1986) 25, 184.
Michelsen, M.L.: “Phase Equilibrium Calculations. What is Easy, and
Nomenclature What is Difficult?,” Comp. Chem. Eng. (1993) 17, 561.
Michelsen, M.L.: “Speeding up the Two-Phase TP-Flash, With Applica-
a ⳱ coefficients in sixth-degree polynomial tions for Calculation of Miscible Displacement,” Fluid Phase Equilib-
B ⳱ matrix of composition derivatives of fugacity ria (1998) 143, 1–12.
coefficients Michelsen, M.L. and Mollerup, J.M.: Thermodynamic Models: Fundamen-
Bij ⳱ composition derivative of the fugacity coefficient of tals & Computational Aspects, first edition, Tie-Line Publications,
component i with respect to component j Holte, Denmark (2004).
b ⳱ smallest eigenvalue in B Pan, H. and Firoozabadi, A.: “Fast and Robust Algorithm for Composi-
C ⳱ component number tional Modeling: Part II—Two-Phase Flash Computations,” SPEJ (De-
i ⳱ component or time index cember 2003) 8, No. 4, 380.
j ⳱ component or coefficient index Soave, G.: “Equilibrium Constants from a Modified Redlich-Kwong Equa-
k ⳱ defined in Eq. 7 tion of State,” Chem. Eng. Sci. (1972) 27, 1197.
K ⳱ equilibrium factor Xu, Z.G. and Shea, R.H.: “Important Tips for Setting up Simulation Mod-
els for Multiphase Flow in Pipelines,” Multiphase ’01 Proc., Cannes,
l ⳱ molar amount of component in liquid phase
France (2001) 315–328.
n ⳱ mole number
p ⳱ pressure, atm
pc ⳱ critical pressure, atm
t ⳱ time, seconds SI Metric Conversion Factors
T ⳱ temperature, K atm × 1.013250* E+05 ⳱ Pa
Tc ⳱ critical temperature, K °F (°F + 459.67)/1.8 ⳱K
v ⳱ molar amount of component in gas phase *Conversion factor is exact.
w ⳱ mole fraction in trial phase
w ⳱ vector of trial-phase mole fractions
x ⳱ mole fraction in liquid phase Claus P. Rasmussen works for Calsep A/S in the area of mod-
x ⳱ vector of liquid mole fractions eling of PVT and phase behavior of petroleum systems. e-mail:
X ⳱ mole fraction in liquid-like composition estimate cpr@calsep.com. His work areas currently include develop-
ment of the PVT simulation program PVTsim and development
y ⳱ mole fraction in gas phase of the flash engine for the compositional version of the tran-
y ⳱ vector of gas mole fractions sient-flow simulator OLGA. Rasmussen holds an MS degree in
Y ⳱ mole fraction in gas-like composition estimate chemical engineering from the Technical U. of Denmark. Kris-
z ⳱ mole fraction in feed tian Krejbjerg has been president of Calsep Inc. in Houston
since 2001. e-mail: kk@calsep.com. He previously worked for 2
z ⳱ vector of feed mole fractions years at Calsep A/S in Denmark developing the PVT simulation
␤ ⳱ gas-phase fraction program PVTsim. His work areas currently include development
␦ij ⳱ Kronecker delta, ␦ij⳱0 for i⫽ j and ␦ij⳱1 for i⳱j of a compositional hydrate-kinetics model. Krejbjerg holds an

February 2006 SPE Reservoir Evaluation & Engineering 37


MS degree in chemical engineering from the Technical U. of this field. Kersti E. Bjurstrøm is a senior consultant at Scand-
Denmark. Michael L. Michelsen is a professor in the Dept. of power Petroleum Technology A/S, Kjeller, Norway. e-mail:
Chemical Engineering at the Technical U. of Denmark, where keb@scandpowerpt.com. She is a project leader and software
he has been employed since 1968. e-mail: mlm@kt.dtu.dk. He developer who has developed different models for tracking
has spent 1 year at the U. of California, Berkeley, working on the concentration of components of multiphase flow in OLGA
process control of chemical reactors. His research interests in- (a transient multiphase-flow simulator). Bjurstrøm also has de-
clude mathematical modeling of chemical systems. For the veloped a general network model in OLGA, and she previously
last 25 years, his main research interest has been the develop- developed software for the reservoir technology department
ment of algorithms for the calculation of phase equilibria (in at Scandpower Petroleum Technology A/S. She holds an MS
particular two-phase and multiphase flash and phase enve- degree in mathematical sciences from the Norwegian U. of
lopes), and he is the author or coauthor of numerous articles in Science and Technology.

38 February 2006 SPE Reservoir Evaluation & Engineering

You might also like