Feb 28, 2007 - September 2009 SPE Journal. 431. Compositional Space Parameterization: Theory and Application for Immiscible. Displacements.
Compositional Space Parameterization: Theory and Application for Immiscible Displacements D.V. Voskov, SPE, and H.A. Tchelepi, SPE, Stanford University
Summary Thermodynamic equilibrium calculations in compositional flow simulators are used to find the partitioning of components among fluid phases, and they can be a time consuming kernel in a compositional flow simulation. We describe a tie-line-based compositional space parameterization (CSP) approach for dealing with immiscible gas-injection processes with large numbers of components. The multicomponent multiphase equilibrium problem is recast in terms of this parameterized compositional space, in which the solution path can be represented in a concise manner. This tie-line-based parameterization approach is used to speed up the phase behavior calculations of standard compositional simulation. Two schemes are employed. In the first method, the parameterization of the phase behavior is computed in a preprocessing step, and the results are stored in a table. During the course of a simulation, the flash calculation procedure is replaced by the solution of a multidimensional optimization problem in terms of the parameterized space. For processes where significant changes in pressure and temperature take place, this optimization procedure is combined with linear interpolation in tie-line space. In the second method, compositional space adaptive tabulation (CSAT) is used to accelerate the equation of state (EOS) computations associated with standard compositional reservoir simulation. The CSAT strategy takes advantage of the fact that, in gas injection processes, the solution path involves a limited number of tie-lines. The adaptively collected tie-lines are used to avoid redundant phase-stability checks in the course of a flow simulation. Specifically, we check if a given composition belongs to one of the tie-lines (or its extension) already in the table. If not, a new tie-line is computed and added to the table. The CSAT technique was implemented in a general-purpose research simulator (GPRS), which is designed for compositional flow simulation on unstructured grids. Using a variety of challenging models, we show that, for immiscible compositional processes, CSAT leads to significant speed up (at least a several-fold improvement) of the EOS calculations compared with standard techniques. Introduction Gas injection processes for enhanced oil recovery are described using compositional models that account for the transfer of components between multiple fluid phases. Compositional reservoir simulators usually employ an EOS model to describe the phase behavior (Coats 1980; Nghiem et al. 1981; Chien et al. 1985; Aziz and Wong 1988). For each computational cell (gridblock) in the reservoir model, given the temperature, pressure, and overall composition of each component in the mixture, EOS computations are used to determine the phase state (liquid, vapor, or both), and, if two or more phases are present, EOS computations are used to determine the phase amounts and compositions. The computational cost of compositional flow simulation increases dramatically with the number of gridblocks in the reservoir model and the number of components used to represent the fluid system. Significant progress has been made over the last two
Copyright © 2009 Society of Petroleum Engineers This paper (SPE 106029) was accepted for presentation at the SPE Reservoir Simulation Symposium, Houston, 26–28 February 2007, and revised for publication. Original manuscript received for review 13 December 2006. Revised manuscript received for review 18 August 2008. Paper peer approved 21 August 2008.
September 2009 SPE Journal
decades in improving the robustness and efficiency of standard EOS-based phase behavior computations. For example, the flash computations associated with miscible gas displacements can be solved more efficiently by using a full Newton iteration scheme (Michelsen 1998). A reduced variable method (Firoozabadi and Pan 2002) has proved quite effective in solving phase equilibrium problems with large numbers of components. Physically based heuristics aimed at reducing the number of routine phase-stability checks during a simulation have also been proposed (Rasmussen et al. 2006). Another way of dealing with the computational cost of compositional flow simulation is the use of lumping procedures to represent the thermodynamic behavior using a small number of pseudocomponents. Specifically, there have been several attempts to describe gas injection recovery processes using pseudoternary representations (Helfferich 1981; Barenblatt et al. 1990; Tang and Zick 1993). Many investigators suggested that such ternary representations may be applicable for general compositional flow problems. During the last two decades, Orr and coworkers, including Monroe et al. (1990), Orr et al. (1993), and Johns et al. (1993), studied gas-injection processes for oil recovery. They presented a unified method of characteristics (MOC) theory of multicontact miscible gas-injection processes for mixtures with large numbers of components (Orr 2007). While that theory is limited to dispersion-free 1D displacements, it provides deep insight into the behavior of these complex recovery processes that can be used for more general settings. Orr and coworkers showed that the geometry and structure of the tie-lines dictate the solution route in compositional space. We now know that displacements involving more than three components display significantly different flow behaviors from those associated with pseudoternary models. On the basis of the ideas of Orr and his group (Orr 2007), an alternative approach to compositional simulation was developed (Entov 2000; Entov and Voskov 2000; Voskov and Entov 2001; Voskov et al. 2001) where a tie-line-based parameterization is used to represent the behaviors associated with gas-injection processes. A similar approach was also suggested for systems with constant partitioning coefficients (Bedrikovetsky and Chumak 1992). The paper is organized as follows: We begin with a brief description of the standard EOS-based simulation approach. Then, we present a CSP framework for modeling multicomponent immiscible displacements, and we discuss the near invariance of the solutions in tie-line space. We then describe a CSAT strategy for the acceleration of EOS calculations in standard compositional reservoir simulation. The robustness and computational efficiency of the tie-line-based parameterization approach are demonstrated using several challenging gas-injection simulation problems. The summary and conclusions are given in the last section. Conventional Compositional Simulation Approach For a mixture of nc hydrocarbon components and two hydrocarbon phases, the mathematical statement expressing the state of thermodynamic equilibrium can be written as fi ,V ( p, T , yi ) − fi ,L ( p, T , xi ) = 0, i ∈[1… nc ] . . . . . . . . . . . . . . (1) zi − (1 − L ) yi − Lxi = 0, i ∈[1… nc ] . . . . . . . . . . . . . . . . . . . . (2) 431
nc
∑( x
i
C1
− yi ) = 0 , . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (3)
Critical tie-line
i =1
where p, T, and zi denote pressure, temperature, and overall mole fraction of component i, respectively; xi and yi represent oil and gas mole fractions; L is the mole fraction of the liquid phase; fi,V(p, T, yi) and fi,L(p, T, xi) represent the fugacities of component i in the vapor and liquid phases, respectively. We assume that p, T, and zi are known and that the fi,j are governed by a nonlinear function, and we need to find xi, yi, and L. The following procedure is used to describe the phase behavior at equilibrium: • Phase stability test: For the current p, T, and zi, find the phase state (liquid, vapor, or two-phase) of this composition. This test is needed for any cell whose status in the previous iteration was single-phase. • Flash calculation: When the phase stability test indicates that the phase-state of the gridblock changed from one to two phases, we need to solve Eqs. 1 through 3 to obtain the xi, yi, and L. The phase-stability test in modern reservoir simulators is usually performed using the scheme described by Michelsen (1982). For flash calculations, a combination of successive substitution iteration (SSI) and Newton’s method is usually used (Michelsen and Mollerup 2004). Compositional Space Parameterization (CSP) We present a tie-line-based parameterization of the compositional space for use in reservoir flow simulation. We describe the method and demonstrate its robustness and computational efficiency using comparisons with the standard EOS-based approach. Consider a system of nc components. The overall mole fraction of the i-th component, zi, in the mixture is defined by Eq. 2. Using one of the components, say the first one, we can write z −y L = 1 1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (4) x1 − y1 We use the structure and properties of the tie-lines to parameterize the compositional space. This is possible because, along a tie-line or its extension, the overall concentration and fractional flow of a component can be written as a linear function of one component concentration and the tie-line parameters (Entov 2000; Voskov and Entov 2001). To show this, we substitute Eq. 4 into Eq. 2, which leads to zi = Ai z1 + Bi , i = 2… nc − 1, . . . . . . . . . . . . . . . . . . . . . . . . (5) where Ai =
xi − yi x − yi , Bi = yi − y1 i . . . . . . . . . . . . . . . . . . . . . (6) x1 − y1 x1 − y1
The parameters Ai and Bi are constants for a given tie-line in the two-phase region or its extension (Fig. 1), and they change only when we change tie-lines. We replace the composition vector z ,{zi , i = 1… nc − 1} with a new set of independent variables, namely, z1 and = { i , i = 1… nc − 2} . The vector is constant for a particular tie-line. The quantities x1, y1, Ai, and Bi are easily written in terms of . For example, under certain assumptions the thermodynamic behavior of these quantities in -space can be described using polynomial approximations (Voskov et al. 2001; Voskov 2002). In practice, the compositional space can be represented reasonably well using a finite number of tie-lines. Notice that the definition in Eq. 6 means that, for cases when x1 is close to y1, we may have problems. This occurs when we are close to the plane z1 ≡ 0 or when we are close to the critical region. In the first case, we switch to another primary component, and that can be done easily based on the {zi} distribution. In the second case, standard EOS methods are used to resolve the phase behavior. 432
Extension of tie-lines
Tie-lines
N2
C12
Fig. 1—Ternary diagram for {N2, C1, C12} at p = 2,650 psi, T = 480°F.
Solution Invariance Parameterization of the tie-line space using the new tie-line-based variable set allows us to split the overall problem of compositional reservoir flow simulation into thermodynamic and hydrodynamic parts (Entov 2000; Voskov and Entov 2001). Consider the system of conservation laws for 1D incompressible two-phase flow in porous media
∂zi ∂F + U i = 0, i = 1,…, nc − 1, . . . . . . . . . . . . . . . . . . . . (7) ∂t ∂x
where Fi is the overall fractional flow of component i defined as Fi = xi F (s) + yi (1 − F (s)), and F(s) is the fractional flow of the liquid phase, U is the total velocity, and is the porosity. Using the tie-line-based parameterization in terms of z1 and , the system of Eq. 7 can be written as
∂z1 ∂F + U 1 = 0, . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (8) ∂t ∂x
∂Ai z1 + Bi ∂A F + Bi = 0 . . . . . . . . . . . . . . . . . . . . . . . (9) +U i 1 ∂t ∂x Here, i = 2,…, nc − 1. To simplify the description, we take U / = 1. A splitting procedure is used to solve Eqs. 8 and 9. First, the (auxiliary) thermodynamic problem is formulated in terms of Ai and Bi, which takes the following form m
∂Ai ( ) ∂Bi ( ) = 0, i = 2,…, nc − 1 , . . . . . . . . . . . . . . . . (10) + ∂t ∂y where y is an auxiliary dimensional variable different from x. Notice that Ai and Bi are only functions of . Thus, the solution of Eq. 10 depends only on the thermodynamic behavior of the system and is independent of the hydrodynamic properties (e.g., relative permeability, viscosity). Thus, the solution of Eq. 10 can be represented as a path in tie-line () space. The second part deals with the hydrodynamic problem (i.e., the flow equations), which can be expressed using two equations only, ∂z1 ∂F1 = 0 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (11) + ∂t ∂x and ∂Aj z1 + B j ∂t
+
∂Aj F1 + B j ∂x
= 0 . . . . . . . . . . . . . . . . . . . . . . . . . (12)
September 2009 SPE Journal
0.18
C4
0.16 0.14 −γ1
0.14 0.1 0.08 0.06 0.04 0.02 0
CO2
2d 40×40 solution 2d 80×80 solution 1d solution 0
0.1
0.2
C10 0.3
0.4
0.5
0.6
0.7
γ1
C4
Fig. 2—Projection of solutions into ⌫-space for 1D flow and 2D 5-spot displacements of oil made up of {CO2, C1, C4, C10} by gas. All solutions are obtained using the Eclipse simulator.
for any fixed j. In these equations, the variation of in -space is assumed to be a known function of a scalar parameter that varies monotonically along the path [e.g., the overall mole fraction of the first (principal) component]. It can be shown that projection of stable waves and shocks, which form the solution of Eqs. 8 and 9 for incompressible 1D problems in compositional space, correspond to stable waves and shocks that represent the solution of the thermodynamic problem in tie-line () space (Entov 2000). Moreover, the solution path in -space is independent of the hydrodynamic properties of the initial problem and depends only on the thermodynamic conditions (e.g., initial/injection compositions). Invariance of the solution path in -space with respect to variation in the hydrodynamic variables was shown to be valid for compressible flows as well (Voskov et al. 2001). Fig. 2 shows the projection of the solution, which is computed in standard compositional space, into -space. In the figure, the solutions of three gas-injection problems into oil made up of {CO2, C1, C4, C10} are shown. The solutions are obtained for different space dimensions. The figure indicates that these solutions share (nearly) the same path in -space. It is difficult to say if solution invariance in -space is a universal characteristic of all compositional problems. For a wide range of near-miscible gas-injection problems with varying operating conditions, dimensionality, heterogeneity, and grid size, our computational experience indicates that the solutions are indeed nearly invariant in -space. In the next sections, we show how this characteristic (i.e., the near invariance of the solution in tie-line space) can be used quite effectively to represent the phase behavior calculations associated with numerical simulations of gas-injection displacements.We also show that CSP in terms of tie-lines, both as a preprocessing step or with adaptive calculation, can be used to speed up the phase behavior calculations associated with standard multicomponent compositional simulators. We show that the adaptive tie-line-based methodology is particularly effective for the numerical simulation of immiscible multicomponent gas-injection processes. CSP-Based Phase Behavior We propose a parameterization algorithm to replace standard phase behavior computations in the course of a compositional flow simulation, including phase-stability tests and flash calculations. Given the overall composition, pressure, and temperature, this procedure returns the liquid and vapor mole fractions and the phase compositions. The approach makes use of the parameterized compositional space, in which x1, y1, Ai, and Bi (in Eqs. 4 through 6) must be expressed as a function of {p, T, }. To simplify the description, we take the temperature T to be constant. For each pressure in the interval of interest, we construct the September 2009 SPE Journal
C1
CO2 C10
C1 Fig. 3—Tetrahedral diagrams for a four-component {CO2, C1, C4, C10} system at p = 1,470 and 1,760 psi (T = 160°F). A randomly generated composition {0.31, 0.30, 0.21, 0.18} is shown along with the tie-line that intersects it.
phase diagram and parameterize it using a finite number of tie-lines (Voskov et al. 2001; Voskov 2002). The results are stored in a tie-line table. For any given {p, zi}, we solve the following problem ⎛ nc ⎞ 2 min ⎜ ∑( Ai ( ) z1 + Bi ( ) − zi ) ⎟ . . . . . . . . . . . . . . . . . . . . . . (13) ⎝ i =1 ⎠ for phase diagrams j and j+1, where pj and p j+1 are the endpoints of the interval under consideration. For both solutions j, the respective xij and yij are obtained from Eqs. 4 through 6. Then, using linear interpolation for pressure p ∈[ p j , p j +1 ], we find the xi and yi. Fig. 3 shows the phase diagram of a four-component system and the tie-line that intersects the composition under study. The top and bottom diagrams are for p = 1,470 and 1,760 psi, respectively. The absolute errors in xi and yi obtained using the tie-line table look-up approach with pressure interpolation compared with standard EOS calculations are: x = 0.066% and y = 0.032%. Additional comparisons for several randomly chosen compositions and pressures are presented in Table 1 for the system {CO2, C1, C4, C10} and in Table 2 for the system {N2, C1, C3, C6, C10}. For each composition, flash calculations are performed for randomly chosen pressures in the interval [1,100–2,400] psi for the first table and [1,400–2,700] psi for the second table. The maximum differences for the liquid and vapor fractions are shown in the tables. To obtain this level of accuracy, several thousand tie-lines were collected for each pressure. 433
TABLE 1—FLASH COMPUTATIONS OF A FOUR-COMPONENT SYSTEM xmax (%)
Composition (%)
TABLE 2—FLASH COMPUTATIONS OF A FIVE-COMPONENT SYSTEM ymax (%)
xmax (%)
Composition (%)
ymax (%)
{27, 22, 9, 42)
0.17
0.06
{16, 32, 20, 8, 25)
0.13
0.16
{28, 30, 19, 23}
0.23
0.08
{24, 33, 20, 14, 9}
0.24
0.21
{37, 42, 10, 11}
0.26
0.11
{10, 36, 16, 29, 8}
0.59
0.19
{39, 8, 7, 46}
0.1
0.03
{21, 11, 25, 25, 18}
0.08
0.12
{34, 52, 10, 4}
0.36
0.45
{13, 24, 22, 18, 22}
0.12
0.31 0.15
{38, 36, 18, 9}
0.27
0.26
{30, 16, 13, 16, 25}
0.14
{22, 37, 21, 20}
0.28
0.09
{24, 29, 16, 26, 5}
0.11
0.16
{46, 26, 19, 9}
0.23
0.11
{27, 12, 19, 3, 40}
0.15
0.27
To demonstrate the CSP-based table look-up approach, several gas-injection problems in 1D were solved using a standard finitevolume method with a variety of injection and initial compositions. Here, we assume that the overall compressibility is low and that the effect of the pressure differences on the compositional behavior is small. First, we consider a problem where a gas composed of {CO2 (80%), C1 (20%)} is injected into a homogeneous reservoir containing oil made up of {CO2 (5%), C1 (20%), C4 (30%), C10 (45%)} at a constant pressure p = 1,620 psi. For flash calculations, two tie-line-based table look-up schemes were implemented. The first method takes the closest tie-line from the table in order to minimize the norm of Eq. 13 (labeled ‘Table’ in Fig. 4). In the second method, Delaunay triangulation of the tie-line parameterization of the compositional space is performed, and the nonlinear problem Eq. 13 is solved; the solution using this second method is shown in Fig. 4 as “Interp.” Simple Corey relative permeability curves and constant viscosities were used in the calculations. In Fig. 4, the two CSP-based solutions are compared with standard compositional simulation results (line) obtained using the Eclipse simulator (Eclipse 2005). The small differences are caused by ignoring the compressibility effects in the CSP-based simulations. Fig. 5 shows the results for a five-component gas-injection problem in 1D, where a gas composed of {N2 (85%), C1 (10%), C3 (3%), C6 (1%), C10 (1%)} is injected into a homogeneous medium to displace oil made up of {N2 (1%), C1 (20%), C3 (20%),
C6 (20%), C10 (39%)} at constant pressure p = 1,840 psi. The figure shows the solutions obtained from the two CSP-based methods and standard simulation (line). Compositional Space Tabulation Tie-line parameterization of the compositional space can be performed as a preprocessing step. Then, the CSP approach described in the previous section can be used to replace standard EOS computations during a flow simulation. In that case, however, a large number of tie-lines may be needed and we have to contend with a high dimensional optimization problem (Eq. 13). We present results for several challenging problems using this compositional space tabulation (CST) approach. More importantly, we propose a modification of the CST strategy, namely CSAT where the tielines involved in the construction of the numerical solution are computed and stored in the course of a flow simulation. In gas-injection processes, the multicomponent solution path in compositional space usually involves a limited region of the compositional space and a small number of tie-lines. More specifically, the solution route can be split into two types: (1) tie-line paths, which connect points along a fixed tie-line (or its extension), and (2) non tie-line paths, where points on different tie-lines are connected (Orr 2007). In practice, it is often the case that a singlephase gas mixture is injected to displace the resident hydrocarbon liquid. If the initial and injected compositions remain fixed during
0.8
Eclipse Table Interp.
0.4
0.6 CO2
C1
0.3 0.2
0.4 0.2
0.1
0
0 0
20
40
60
80
0
100
20
40
80
100
60
80
100
x
x 0.3
60
0.5
0.25
0.4
0.2 C10
C4
0.3
0.15
0.2
0.1
0.1
0.05 0 0
0 20
40
60
x
80
100
0
20
40
x
Fig. 4—Solutions of gas injection into oil made up of {CO2, C1, C4, C10} using various strategies. 434
September 2009 SPE Journal
0.5
0.8
0.4 0.6 C1
N2
0.3 0.4 0.2
0
20
40
0.1
x
60
80
0
100
0.25
0.25
0.2
0.2 C6
C3
0
0.2
Eclipse Table Interp.
0.15
0.1
0.05
0.05 0 0
20
40
60
80
20
40
x
60
80
100
60
80
100
0.15
0.1
0
0
100
0
20
40
x
x
Fig. 5—Gas injection into oil made up of {N2, C1, C3, C6, C10} in a 1D homogeneous medium. The CSP-based table look-up methods and the results from standard compositional simulation are shown.
the displacement process and the pressure changes are small, the solution route involves these two tie-lines only (Fig. 6). Our objective is to improve the robustness and computational efficiency of numerical (finite-volume) simulation of gas-injection processes; as a result, we use these tie-line-based parameterization strategies to speed up the EOS computations of compositional reservoir simulators. Compositional Space Tabulation (CST). For the particular displacement problem of interest, we specify a set of compositions and a pressure range. The composition set is chosen using information about the likely key tie-lines. The tie-lines associated with the
initial and injection compositions are obvious candidates. A table is constructed, where, for each composition in the specified set, the tie-lines corresponding to each pressure value in the interval of interest are computed and stored. During a flow simulation, whenever we need to perform a phase stability test or run flash computations, we check if the composition lies close to one of the stored tie-lines. To check the composition, we use a modification of Eqs. 2 through 4. L=
z j − yj
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . (14)
x j − yj
nc
∑ ( x L + y (1 − L) − z ) i
C4
i
i
2
< ε . . . . . . . . . . . . . . . . . . . . . . . . (15)
i =1
If one of the stored tie-lines satisfies these criteria for the composition of interest, the table is used to look up the flash results. Otherwise, a standard EOS-based phase behavior procedure is employed. We refer to this scheme, where we use a precomputed table of tie-lines, as CST; any composition that does not intersect one of the tie-lines in the table is handled using a standard EOS module.
C1
C10
CO2 Fig. 6—Solution of gas-injection problem for composition {CO2, C1, C4, C10} in compositional space. The initial, injection, and intermediate tie-lines are also shown. September 2009 SPE Journal
Compositional Space Adaptive Tabulation (CSAT). For compositions that lie on one of the tie-lines in the table, the CST method replaces all phase behavior calculations. In compositional simulation practice, however, the phase stability test is the most time consuming part of the EOS calculations. The number of iterations to perform the phase stability tests is usually very large (Table 3), and each iteration takes a significant number of arithmetic operations. To speed up the phase stability test, we propose a CSAT strategy. Each time a phase-state stability test is required during a compositional simulation, we check the set of stored tie-lines. If the composition does not lie on any of the stored tie-lines, new tie-lines are computed for the pressure range of interest. The CSAT method was implemented in the GPRS simulator (Cao 2002). In addition to the phase stability test, the CSAT method can be used to replace standard flash calculations. In that case, a more sophisticated algorithm for tie-line checking (Eqs. 14 and 15) is needed because the number of tie-lines can be quite large. Such a strategy is presented by Voskov and Tchelepi (2008). 435
TABLE 3—COMPARISON BETWEEN STANDARD, CST, AND CSAT COMPOSITIONAL SIMULATION METHODS FOR EIGHT STUDY CASES Test Case
Type of EOS Calc.
Stab. It. (10 )
Case 1
Original
3012
–
–
29
CST
5
222
2