Advertisement

A Numerical Algorithm to Solve the Two-Phase Flow in Porous Media Including Foam Displacement

Conference paper
Part of the Lecture Notes in Computer Science book series (LNCS, volume 12143)

Abstract

This work is dedicated to simulating the Enhanced Oil Recovery (EOR) process of foam injection in a fully saturated reservoir. The presence of foam in the gas-water mixture acts in controlling the mobility of the gas phase, contributing to reduce the effects of fingering and gravity override. A fractional flow formulation based on global pressure is used, resulting in a system of Partial Differential Equations (PDEs) that describe two coupled problems of distinct kinds: elliptic and hyperbolic. The numerical methodology is based on splitting the system of equations into two sub-systems that group equations of the same kind and on applying a hybrid finite element method to solve the elliptic problem and a high-order finite volume method to solve the hyperbolic equations. Numerical results show good efficiency of the algorithm, as well as the remarkable ability of the foam to increase reservoir sweep efficiency by reducing gravity override and fingering effects.

Keywords

EOR Hybrid mixed methods Finite volume methods Foam injection Mobility reduction 

1 Introduction

The enhanced oil recovery by injection of gas is a technique that is used since the 1930’s [14]. The sweep efficiency of gas, however, can be affected by gravity (by the gravity override phenomenon, that occurs when the injected gas accumulates in the upper layers of the reservoir) and by the development of preferential paths (viscous fingering), due to gas lower density and viscosity. These obstacles can be surpassed by the creation of foam, that can be defined as the agglomeration of gas bubbles separated by thin liquid films (lamellae), since foam apparent viscosity is much higher than the viscosity of gas [11, 12, 23]. The usage of foam in oil recovery is mainly motivated by the reduction of the gas phase mobility [15].

Population balance models can be used to simulate foam creation, destruction and flow through porous media. In this approach, it is common to define the foam texture (\(n_\text {f} \)), a quantity that represents the number of bubbles (or lamellae) per unit volume. Mechanisms of foam creation and coalescence play an important role in the model [15, 17]. The major hypothesis adopted for the lamella-coalescence mechanism is that bubbles collapse near the limiting water saturation (\(S_\text {w}^* \)) or, equivalently, the limiting capillary pressure. In this context, a foam model based on the well-known steady-state behavior of foam in porous media was proposed by Ashoori et al. in [2]. It considers a large, nearly constant, reduction in gas mobility at high water saturation and an abrupt weakening or collapse of foam at a limiting water saturation. Foam texture in local equilibrium (\(n_\text {D}^{\text {LE}} \)), where bubble generation and destruction reach a local equilibrium state, depends only on the water saturation (\(S_\text {w}\)):
$$\begin{aligned} n_\text {D}^{\text {LE}} ( S_\text {w}) = {\left\{ \begin{array}{ll} 0, &{} S_\text {w}\le S_\text {w}^* \\ \tanh \left[ A (S_\text {w}- S_\text {w}^*) \right] , &{} S_\text {w}> S_\text {w}^* \end{array}\right. }, \end{aligned}$$
(1)
with constant A. The dynamic foam net generation is given by a first-order approach, introduced in [24] and later related to the local-equilibrium bubble texture in [2], with a time constant \(1/K_\text {c} \), as follows:
$$\begin{aligned} r_\text {g}-r_\text {c}= K_\text {c} n_\text {max}\left( n_\text {D}^{\text {LE}} \left( S_\text {w}\right) - n_\text {D}\right) , \end{aligned}$$
(2)
where \(r_\text {g}\) and \(r_\text {c}\) are the foam generation and coalescence rates, respectively, \(n_\text {max}\) is the maximum foam texture and \(n_\text {D}= n_\text {f}/n_\text {max}\) is the dimensionless foam texture. This model represents a simplification of foam behavior in porous media without significantly sacrificing the physical phenomena [24]. Other models that associate bubble generation and destruction to the limiting capillary pressure or the gradient of gas pressure can be found in [15, 17].
In this model, the reduction in the mobility of gas by foam is viewed as a reduction of the gas relative permeability \(k_\text {rg}\):
$$\begin{aligned} k_\text {rg}(S_\text {w}, n_\text {D}) = \dfrac{k_\text {rg}^0 \left( S_\text {w}\right) }{18500 n_\text {D}+ 1}, \end{aligned}$$
(3)
where \(k_\text {rg}^0 \) is the gas relative permeability when no foam is formed. Another view on the mobility reduction is based on the apparent viscosity of foam [13, 15, 17, 24]. Comprehensive reviews on the mechanisms of bubble creation, destruction, and also on the reduction of gas mobility can be found in [9, 21].
The following system of equations describes an incompressible two-phase flow in a porous medium:
$$\begin{aligned} \dfrac{\partial }{\partial t}(\phi S_\text {g}\,n_\text {D}) + \nabla \cdot ({\varvec{u}}_\text {g}\,n_\text {D})= \dfrac{\phi S_\text {g}(r_\text {g}-r_\text {c})}{n_\text {max}}, \end{aligned}$$
(4)
$$\begin{aligned} \dfrac{\partial }{\partial t}(\phi S_{\alpha }) + \nabla \cdot {\varvec{u}}_{\alpha } = 0,\quad \alpha \in \{\text {g,w}\}, \end{aligned}$$
(5)
$$\begin{aligned} {\varvec{u}}_{\alpha } = -\mathbb {K}\lambda _{\alpha }\left( \nabla p_{\alpha }- \rho _{\alpha }{\varvec{g}} \right) ,\quad \alpha \in \{\text {g,w}\}, \end{aligned}$$
(6)
where (4) is a population balance equation for foam texture [6] and (5)–(6) account for fractional flow and hydrodynamics. We use \(\phi \) to denote the porosity of the medium, and \(\rho _{\alpha }\), \(S_{\alpha }\), \({\varvec{u}}_{\alpha }\), and \(p_{\alpha }\) to denote density, saturation, superficial velocity, and pressure, respectively, of phase \(\alpha \). Also, \(\mathbb {K}=\mathbb {K}({\varvec{x}})\) is the intrinsic permeability tensor, and \({\varvec{g}}\) is the gravity vector. From the fractional flow theory, \(\lambda _\text {w}=k_\text {rw}/\mu _\text {w}\) and \(\lambda _\text {g}=k_\text {rg}/\mu _\text {g}\) denote the mobility of water and gas phases, respectively, where the viscosity of water and gas are given by \(\mu _\text {w}\) and \(\mu _\text {g}\). It is assumed that the porous medium is fully saturated, i.e., \(S_\text {w}+ S_\text {g}= 1\).

The numerical approach for solving this system of PDEs should be capable of handling several complexities due to discontinuity, non-linearity, stiffness, natural instabilities, among others. The numerical methods should also preserve important properties, such as local conservation of mass, shock capture, non-oscillatory solutions, accurate approximations, and reduced numerical diffusion effects.

To the extent of our knowledge, this problem is usually solved using explicit-in-time finite difference schemes [1, 16, 21, 25]. Also, the use of commercial software is prevalent in the literature [7, 20, and references within]. The most common approach in commercial software is to represent the effect of foam by a factor that reduces the mobility of the gas phase; therefore, bubble creation and destruction are not represented explicitly [9, 21].

An effective numerical scheme to solve this kind of model and to address its inherent complexities is based on rewriting the problem in terms of global pressure, as in [4]. In this scheme, one has two distinct coupled problems: an elliptic problem and a degenerate hyperbolic problem. The next step is to decouple the system of PDEs into two subsystems of equations, each one of a different nature. In doing so, each subsystem can be solved by specialized methods, such as finite element and finite volume methods, according to their mathematical properties and the relation between precision and computational efficiency required in the resolution of each step. In this sense, for the spatial discretization of the hyperbolic problems we can employ the finite volume method, for instance; for time discretization, a common choice is a finite difference method, while a hybrid finite element method can be applied to the elliptic equations.

In this context, we develop a staggered algorithm to decouple the hydrodynamics from the hyperbolic system, resulting in a scheme that uses a locally conservative hybrid mixed finite element method to approximate the velocity and pressure fields and a high-order finite volume scheme to solve the hyperbolic equations. The two problems are solved in different time scales. Thus, the proposed staggered algorithm is employed to simulate two-phase (water and gas) flow in a heterogeneous porous medium. We compare pure gas-water injection with the gas-water-foam flow. The results show a reduction of gravity override and viscous fingering effects when the foam is present.

This work is organized as follows: in Sect. 2, we define a fractional flow formulation for Eqs. (4)–(6) using the concept of global pressure; in Sect. 3, we present an algorithm to solve the problem using a hybrid mixed finite element method for the elliptic problem and a high-order finite volume method methodology to solve the hyperbolic equations; numerical results are shown in Sect. 4. Finally, in Sect. 5, we present some concluding remarks.

2 Model Problem

To build a fractional flow model for the water-gas-foam flow in porous media we follow the global pressure approach from [4]. The global pressure is defined as
$$\begin{aligned} p = p_\text {g} - \int _{1-S_\text {gr}}^{S_\text {w}}f_\text {w}\frac{\mathrm {d}P_\text {c}}{\mathrm {d}\eta } \mathrm {d}\eta \quad \text {and} \quad f_\text {w}= \frac{\lambda _\text {w}}{\lambda } = \frac{\lambda _\text {w}}{\lambda _\text {w}+\lambda _\text {g}}, \end{aligned}$$
(7)
where \(P_\text {c}(S_\text {w}) = p_\text {g} - p_\text {w}\) is the capillary pressure. From (6) and (7) the total velocity \({\varvec{u}}\) is written as [4]:
$$\begin{aligned} {\varvec{u}} = {\varvec{u}}_\text {g} + {\varvec{u}}_\text {w} = -\mathbb {K}\lambda \left( \nabla p - {\varvec{G}}\left( S_\text {w}\right) \right) , \quad \text {with} \quad {\varvec{G}}\left( S_\text {w}\right) = \frac{\lambda _\text {g}\rho _\text {g}+ \lambda _\text {w}\rho _\text {w}}{\lambda }{\varvec{g}}, \end{aligned}$$
(8)
where \({\varvec{g}} = -9.81 {\varvec{\hat{\jmath }}}\;m/s^2\) and \({\varvec{\hat{\jmath }}}\) is the unitary vector in vertical direction.
It follows directly from the previous definitions that
$$\begin{aligned} {\varvec{u}}_\text {w}&= f_\text {w}{\varvec{u}} + \mathbb {K}\lambda _\text {g}f_\text {w}\nabla P_\text {c}- {\varvec{b}},\\ {\varvec{u}}_\text {g}&= f_\text {g}{\varvec{u}} - \mathbb {K}\lambda _\text {g}f_\text {w}\nabla P_\text {c}+ {\varvec{b}}, \end{aligned}$$
where \({\varvec{b}} = \mathbb {K}\lambda _\text {g}f_\text {w}\left( \rho _\text {g}-\rho _\text {w}\right) {\varvec{g}}\).
Let \(\varOmega \subset \mathbb {R}^d\), \(d=2\) or 3, have Lipschitz boundary \(\varGamma = \partial \varOmega \). Using the hypothesis of rigid porous medium, the total fluid velocity \({\varvec{u}}\), the global pressure p, the water saturation \(S_\text {w}\), and the foam texture \(n_\text {D}\) satisfy, in \(\varOmega \times (0,T]\), the following system of equations:
$$\begin{aligned}&{\varvec{u}} = -\mathbb {K}\lambda \left( \nabla p - {\varvec{G}}\left( S_\text {w}\right) \right) , \end{aligned}$$
(9)
$$\begin{aligned}&\nabla \cdot {\varvec{u}} = 0, \end{aligned}$$
(10)
$$\begin{aligned}&\phi \dfrac{\partial {\varvec{S}}}{\partial t}+ \sum _{i=1}^d \frac{\partial {\varvec{f}}_i}{\partial x_i} - \nabla \cdot \left( \mathbb {C}\nabla {\varvec{S}} \right) = {\varvec{\varPhi }}, \end{aligned}$$
(11)
where i denotes a spatial direction, andand boundary and initial conditions
$$\begin{aligned}&{\varvec{u}}\cdot {\varvec{n}} = \bar{u}&\quad&\text { on } \varGamma _{N}\times (0,T],&\qquad&p = \bar{p}&\quad&\text { on } \varGamma _{D}\times (0,T], \\&{\varvec{S}} = {\varvec{\bar{S}}}&\quad&\text { on } \varGamma _{N}^-\times (0,T],&\qquad&{\varvec{S}}\left( {\varvec{x}}, 0\right) = {\varvec{S}}^0&\quad&\text { in } \varOmega , \nonumber \end{aligned}$$
(12)
where \(\varGamma =\varGamma _{N}\cup \varGamma _{D}\), \(\varGamma _{N}\cap \varGamma _{D}=\emptyset \), with \(\varGamma _{N}\) denoting the boundary region with Neumann condition (specified injection velocity), \(\varGamma _{D}\) defining the boundary region with Dirichlet condition on the potential, \(\varGamma _{N}^- = \left\{ {\varvec{x}}\in \varGamma _{N}; \bar{u}({\varvec{x}})<0\right\} \) and \({\varvec{n}}\) is the unit outer normal vector to \(\varGamma \). For simplicity, we assume \(\varGamma _{D} \ne \emptyset \) and \(\varGamma _{N}^- \ne \emptyset \).

3 Numerical Method

In this section, we introduce the sequential algorithm that combines two kinds of numerical methods to solve (9)–(11).

The hydrodynamics (9)–(10) is approximated using a naturally stable mixed finite element method introduced in [22]. This method is locally conservative, relying on the strong imposition of the continuity of normal fluxes and on a discontinuous pressure field. The combination of a hybrid formulation with a static condensation technique reduces the number of degrees of freedom in the global problem.

The transport system (11) is solved using the KNP method, a conservative, high-order, central-upwind finite volume scheme introduced in [18] that shows reduced numerical diffusion effects. The KNP scheme is an extension of the KT method [19] that generalizes the numerical flux using more precise information about the local propagation velocities. At the same time, the KNP scheme has an upwind nature, since it respects the directions of wave propagation by measuring the one-sided local velocities. KNP is a semi-discrete method based on the REA (Reconstruct Evolve Average) algorithm of Godunov [8]. Furthermore, the KNP scheme allows for using small steps in time without requiring an excessive refinement of the spatial mesh, since the numerical diffusion does not depend on the time step. After discretization in space, the resulting system of ODEs is integrated in time using a BDF (Backward Differentiation Formula), an implicit, multi-step method that is especially indicated to solve stiff equations [5].

3.1 The Sequential Algorithm

The system of Eqs. (9)–(11) is strongly coupled. It is possible, however, to apply a staggered algorithm to solve an approximate problem composed of two sub-systems: an elliptic one, with time step \(\Delta t_{\text {u}}\), and a hyperbolic one, with time step \(\Delta t_{\text {s}}\). Each of them is solved separately using adaptive time steps, as described in Algorithm 1, i.e., one can use smaller time steps to bound the error in the approximations under a certain tolerance. In addition, it is often recommended that \(\Delta t_{\text {u}}>\Delta t_{\text {s}}\), as the time scale of the hydrodynamics is usually much slower than of the transport. In each iteration, approximations for velocity \({\varvec{u}}^{n+1}\) and pressure \(p^{n+1}\) fields at \(t=t^{n+1}\) are computed from
$$\begin{aligned}&{\varvec{u}}^{n+1} = -\mathbb {K}\lambda \left( \nabla p^{n+1} - {\varvec{G}}\left( S_\text {w}^{n}\right) \right)&\quad&\text { in } \varOmega ,\end{aligned}$$
(13a)
$$\begin{aligned}&\nabla \cdot {\varvec{u}}^{n+1} = 0&\quad&\text { in } \varOmega , \end{aligned}$$
(13b)
supplemented by the boundary conditions (12).
Then an iterative algorithm is used to find approximations for water saturation (\(S_\text {w}^{n+1}\)) and foam texture (\(n_\text {D}^{n+1}\)) by solving the following system of PDEs in \(\varOmega \times (t^n,t^{n+1}]\) (for simplicity, we omit the superscript \(n+1\)):
$$\begin{aligned} \phi \dfrac{\partial {\varvec{S}}^{n+1}}{\partial t}+ \sum _{i=1}^d \frac{\partial {\varvec{f}}_i^{n+1}}{\partial x_i} - \nabla \cdot \left( \mathbb {C}\nabla {\varvec{S}}^{n+1} \right) = {\varvec{\varPhi }}^{n+1}, \end{aligned}$$
(14)
with boundary and initial conditions
$$\begin{aligned} {\varvec{S}}&= {\varvec{\bar{S}}} \text { on } \varGamma _{N}^-\times (t^n,t^{n+1}],&{\varvec{S}}\left( {\varvec{x}}, t^n\right)&= {\varvec{S}}^n \text { in } \varOmega . \end{aligned}$$
(15)

In the following sections we comment on the methods employed to solve each problem.

3.2 Hybrid Mixed Finite Element Method for Darcy Flow

When a mixed finite element formulation is used to approximate the Darcy system (13), it is necessary to simultaneously fulfill the compatibility condition between spaces and to impose the continuity of the normal vector across interelement edges. In addition, the resulting linear system is indefinite, which can restrict the numerical solvers that could be applied. By using a hybrid formulation, the continuity requirement is imposed via Lagrange multipliers, defined on the interelement edges. Furthermore, if the local problems are solvable, it is possible to eliminate all degrees of freedom related to local problems using a static condensation technique, resulting in a considerable reduction of the computational cost, since the global system involves only the degrees of freedom of the Lagrange multiplier. Also, in this case, the global problem is positive-definite. Once the approximation for the Lagrange multipliers is found, the original degrees of freedom (associated with velocity and pressure) can be computed in local, independent problems.

We first introduce some notations and definitions, for simplicity restricting ourselves to \(\varOmega \subset \mathbb {R}^2\). The three-dimensional case follows directly. Let \(L^2(\varOmega )\) denote the Hilbert space of square-integrable functions in \(\varOmega \), with the usual inner product \((\cdot ,\cdot )_\varOmega \), and let \(H(\text {div},\varOmega )\) be the space of vector functions having each component and divergence in \(L^2(\varOmega )\).

Assuming \(\varOmega \) is a polygon, we define a partition \(\mathcal {T}_h\) of \(\varOmega \) composed of quadrilaterals and use K to denote an arbitrary element of the partition. The set of edges of K is denoted by \(\partial K\), the set of edges in \(\mathcal {T}_h\) is denoted by \(\mathcal {E}_h\), and \(\mathcal {E}^{\partial }_h\) denotes the set of all boundary edges, i.e., those with all points in \(\varGamma \). Finally, the set of interior edges is denoted by \(\mathcal {E}_h^0 = \mathcal {E}_h\setminus \mathcal {E}^{\partial }_h\). For every element \(K\in {\mathcal {T}_h}\), there exists \(c>0\) such that \(h\le c h_e\), where \(h_e\) is the diameter of the edge \(e \in \partial K\) and h, the mesh parameter, is the element diameter. For each edge of an element K we associate a unit outward normal vector \(\mathbf {n}_K\).

The (discontinuous) \({\mathcal {RT}}\) spaces of index k [22] are here denoted by \(\mathcal {U}_h^k\times \mathcal {P}_h^k\). We define the following sets of functions on the mesh skeleton:
$$\begin{aligned} \mathcal {M}_h^k&= \left\{ \mu _h \in L^2(\mathcal {E}_h);~ \mu _h|_e \in p_k(e), ~\forall e \in \mathcal {E}_h,~ \mu _h|_e = \bar{p}, \forall e \in \mathcal {E}_h^\partial \cap \varGamma _D \right\} , \end{aligned}$$
(16)
$$\begin{aligned} \bar{\mathcal {M}}_h^k&= \left\{ \mu _h \in L^2(\mathcal {E}_h);~ \mu _h|_e \in p_k(e), ~\forall e \in \mathcal {E}_h,~ \mu _h|_e = 0, \forall e \in \mathcal {E}_h^\partial \cap \varGamma _D \right\} , \end{aligned}$$
(17)
where \(p_k(e)\) denotes the set of polynomial functions of degree up to k on e.

From these definitions, we can write the following hybrid mixed formulation for the hydrodynamics problem (13):

Given \(S_\text {w}^{n}\) and \(n_\text {D}^n\), find the pair \([{\varvec{u}}_h,p_h] \in \mathcal {U}_h^k \times \mathcal {P}_h^k\) and the Lagrange multiplier \(\lambda _h \in \mathcal {M}_h^k\) such that, for all \([{\varvec{v}}_h, q_h, \mu _h] \in \mathcal {U}_h^k \times \mathcal {P}_h^k \times \bar{\mathcal {M}}_h^k\),
$$\begin{aligned} \sum _{K\in \mathcal {T}_h} \left[ (\mathbb {A}{\varvec{u}}_h,{\varvec{v}}_h)_K - (p_h, \nabla \cdot {\varvec{v}}_h)_K + \int _{\partial K} \lambda _h {\varvec{v}}_h \cdot {\varvec{n}}_K \mathrm {d}s\right]&= ({\varvec{G}}\left( S_\text {w}^{n} \right) , {\varvec{v}}_h)_\varOmega \end{aligned}$$
(18)
$$\begin{aligned} \sum _{K\in \mathcal {T}_h} - (q_h, \nabla \cdot {\varvec{u}}_h)_K&= -(f,q_h)_\varOmega \end{aligned}$$
(19)
$$\begin{aligned} \sum _{K\in \mathcal {T}_h} \int _{\partial K} \mu _h {\varvec{u}}_h \cdot {\varvec{n}}_K \mathrm {d}s&= \int _{\varGamma _{N}} \bar{u}\,\mu _h \mathrm {d}s, \end{aligned}$$
(20)
where \(\mathbb {A}=\mathbb {A}(S_\text {w}^{n}, n_\text {D}^n) = (\mathbb {K}\lambda (S_\text {w}^{n}, n_\text {D}^n))^{-1}\).

To solve the hybrid formulation (18)–(19) we apply the static condensation technique that consists in a set of algebraic operations, done at the element level, to eliminate all degrees of freedom corresponding to the variables \({\varvec{u}}_h\) and \(p_h\), leading to a global system with the degrees of freedom associated with the multipliers only.

We can observe that static condensation causes a major reduction in the size of the global problem, which is now rewritten in terms of the multiplier only. Also, the new system of equations is positive-definite, allowing for using simpler and more robust solvers. In the end, a hybrid formulation associated with static condensation leads to a great reduction of the computational cost required to solve the global problem. In this work, the deal.II library [3] is used to solve this hydrodynamics problem.

3.3 High Order Central-Upwind Scheme for the Transport Problem

The numerical methodology used to approximate the water saturation and bubble texture Eqs. (14) and (15) is a high-order non-oscillatory central-upwind finite volume method proposed in [18] and here referred to as KNP. Like many other finite volume methods, the KNP scheme is based on a grid of control volumes (or cells).

The upwind nature of KNP is because it respects the directions of wave propagation by measuring the one-sided local speeds, given by
$$\begin{aligned} a^{\text {max/min}}_{l\pm 1/2,i}&= \max /\min {\left\{ \varLambda _{{\varvec{S}}^{-}_{l\pm 1/2,i}}^{\text {max/min}}, \varLambda _{{\varvec{S}}^{+}_{l\pm 1/2,i}}^{\text {max/min}}, 0 \right\} }, \end{aligned}$$
on direction i and a cell of index l, where \(l+1/2\) is the right (resp. top) face and \(j-1/2\) is the left (resp. bottom) face of a cell, \({\varvec{S}}^{-}_{l\pm 1/2,i}\) is the local reconstruction of \({\varvec{S}}\) at the left (resp. bottom) side of a face, and \({\varvec{S}}^{+}_{l\pm 1/2,i}\) is the local reconstruction of \({\varvec{S}}\) at the right (resp. top) side of a face; \(\varLambda _{{\varvec{X}}}^{\text {max}}\) and \(\varLambda _{{\varvec{X}}}^{\text {min}}\) are the maximum and minimum eigenvalues, respectively, of the Jacobian \(\partial {\varvec{f}}_i/\partial {\varvec{S}}\) at \({\varvec{S}}={\varvec{X}}\). The result of spatial discretization using KNP is the system of ODEs in conservative form:
$$\begin{aligned} \phi \frac{\mathrm {d}{\varvec{S}}_{l}}{\mathrm {d}t} = \sum _{i=1}^d\left( \dfrac{{\varvec{H}}_{l-1/2,i}-{\varvec{H}}_{l+1/2,i}}{h_i}+ {\varvec{P}}_{l,i}\right) + {\varvec{\varPhi }}_{l} , \end{aligned}$$
(21)
where \({\varvec{\varPhi }}_{l} = {\varvec{\varPhi }}\left( {\varvec{S}}_{l} \right) \), \(h_i\) is the cell size in the i-th direction, with the convective numerical fluxes given by
$$\begin{aligned} {\varvec{H}}_{l\pm 1/2, i}&= \dfrac{a^{\text {max}}_{l\pm 1/2,i}{\varvec{f}}_i\left( {\varvec{S}}^-_{l\pm 1/2,i} \right) - a^{\text {min}}_{l\pm 1/2,i}{\varvec{f}}_i\left( {\varvec{S}}^+_{l\pm 1/2,i} \right) }{a^{\text {max}}_{l\pm 1/2,i} - a^{\text {min}}_{l\pm 1/2,i}} \nonumber \\ {}&+ \dfrac{a^{\text {max}}_{l\pm 1/2, i}a^{\text {min}}_{l\pm 1/2,i}}{a^{\text {max}}_{l\pm 1/2,i}-a^{\text {min}}_{l\pm 1/2,i}}\left( {\varvec{S}}^+_{l\pm 1/2, i} - {\varvec{S}}^-_{l\pm 1/2, i}\right) , \end{aligned}$$
(22)
and diffusive numerical fluxes given by
$$\begin{aligned} \mathbf {P}_{l,i}(t)&= \dfrac{\tilde{\mathbb {D}}_{l+1/2,i}{\varvec{S}}_{l+1,i} - \left( \tilde{\mathbb {D}}_{l+1/2,i} + \tilde{\mathbb {D}}_{l-1/2,i} \right) {\varvec{S}}_{l} + \tilde{\mathbb {D}}_{l-1/2,i}{\varvec{S}}_{l-1,i}}{h_i^2}, \end{aligned}$$
(23)
where \(\tilde{\mathbb {D}}_{l\pm 1/2,i}\) is defined as the harmonic mean of \((\mathbb {D}\mathbb {B})_{l}\) and \((\mathbb {D}\mathbb {B})_{l\pm 1,i}\). The scheme (21)–(23), combined with minmod reconstruction of the type
$$\begin{aligned}&{\varvec{\tilde{S}}}_{l}({\varvec{x}}) = {\varvec{S}}^n_{l} + \sum _{i=1}^d{\varvec{d}}^{n}_{l,i}({x}_{i}-{x}_{l,i}),\\&{\varvec{d}}^n_{l,i} = \text {minmod}\left( \theta \dfrac{{\varvec{S}}^n_{l,i}-{\varvec{S}}^n_{l-1,i}}{h_i}, \dfrac{ {\varvec{S}}^n_{l+1,i}-{\varvec{S}}^n_{l-1, i}}{2h_i}, \theta \dfrac{{\varvec{S}}^n_{l+1,i}-{\varvec{S}}^n_{l,i}}{h_i} \right) \end{aligned}$$
is a TVD scheme if \(1 \le \theta \le 2\) [18], where \({\varvec{\tilde{S}}}_{l}\) is a piecewise linear approximation to the solution at time \(t^n\), i.e., \({\varvec{\tilde{S}}}_{l}({\varvec{x}}) \approx {\varvec{S}}^n_{l}({\varvec{x}})\). Then we can use the fact that \(x_{l\pm 1/2,i} = x_{l,i}\pm h_i/2\) to find \({\varvec{S}}^{\pm }_{l\pm 1/2,i}\).

Various numerical methods can be used to solve the system of ODEs (21). In this work, a variable order, adaptive step Backward Differentiation Formula (BDF) was chosen. This stable, implicit scheme allows for taking larger time steps than an explicit method would require, which reduces computational cost. In our numerical simulations we used the implementation of the BDF scheme from the CVode package, available in the SUNDIALS library [10].

4 Numerical Results

Applying the numerical methods described in Sect. 3, we now present results of numerical experiments that aim to assess the influence of foam and gravity effects in two-phase flow. Two scenarios are simulated: flow without and with foam. In the first scenario, we consider that only a mixture of water and gas is flowing through the porous medium, setting \(n_\text {D}=0\) in the hyperbolic problem and solving only for \(S_\text {w}\) in (11). The hydrodynamics and the mobility of the gas phase remain unchanged (\(k_\text {rg}= k_\text {rg}^0 \)). In the second scenario, we assume that surfactant is readily available in the water phase, allowing for foam creation and changes in the mobility of gas phase. This scenario is simulated using the full problem (9)–(11). In both scenarios, the capillary pressure and relative permeabilities are
$$\begin{aligned} P_\text {c}= 330 \dfrac{\left( 1-S_\text {w}- S_\text {gr}\right) ^{0.01} }{S_\text {w}-S_\text {wc}}, \; k_\text {rw}= \left( \dfrac{S_\text {w}- S_\text {wc}}{1-S_\text {wc}- S_\text {gr}}\right) ^4, \; k_\text {rg}^0 = \left( \dfrac{1-S_\text {w}- S_\text {gr}}{1-S_\text {wc}- S_\text {gr}}\right) ^2. \end{aligned}$$
The permeability is assumed isotropic \({\mathbb {K}}=\kappa ({\varvec{x}}){\mathbb {I}}\), where \(\kappa ({\varvec{x}})\) is the permeability field of layers 1 (case A, Fig. 1(a)) and 36 (case B, Fig. 1(b)) of the SPE10 project1, rotated to the xy plane. The right boundary is chosen to be the Dirichlet type (\(\varGamma _{D}\)) with \(\bar{p} = 0\), while left, top and bottom boundaries are set to Neumann condition (\(\varGamma _{N}\)) with \(\bar{u} < 0\) for the left boundary and \(\bar{u} = 0\) for the top and bottom boundaries. Coefficients and numerical parameters used in the simulations are shown in Table 1.
Table 1.

Simulation parameters.

Parameter

Value

Parameter

Value

Water viscosity Open image in new window [Pa s]

Open image in new window

Porosity

Open image in new window

Gas viscosity Open image in new window [Pa s]

Open image in new window

A

Open image in new window

Water residual saturation Open image in new window

Open image in new window

\(K_\text {c} \) [1/s]

Open image in new window

Gas residual saturation Open image in new window

Open image in new window

Dimensions [m]

Open image in new window

Critical water saturation Open image in new window

Open image in new window

Final time [s]

Open image in new window

Max foam texture Open image in new window [\(m^{-3}\)]

Open image in new window

\(\Delta t_{\text {u}} [s]\)

Open image in new window

Injection velocity Open image in new window [\(\text {m s}^{-1}\)]

Open image in new window

Number of cells

\(220\times 60\)

Initial water saturation Open image in new window

Open image in new window

Minmod parameter \(\left( \theta \right) \)

Open image in new window

Injected water saturation Open image in new window

Open image in new window

Absolute tolerance

Open image in new window

Initial foam texture (Open image in new window)

Open image in new window

Relative tolerance

Open image in new window

Injected foam texture (Open image in new window)

Open image in new window

\({\mathcal {RT}}\) index (k)

0

Fig. 1.

Permeability map of layer 1 (a) and layer 36 (b) of the SPE10.

The water saturation profiles for case A at \(t = 2\,000\) s and \(t=10\,000\) s are shown in Figs. 2 and 3, respectively. The gravity effects are much more pronounced in the no-foam simulation. Also, as expected, the water phase displacement occurs more slowly in the foam presence due to the gas mobility reduction caused by foam. Note that, without foam, the gas breakthrough has already taken place at \(t = 10\,000\) s (Fig. 3), which does not occur when foam is present. Moreover, for the foam model adopted [2], viscous fingering and gravity override are reduced with foam as time advances. As a result, a better sweep efficiency of the medium is observed when foam is present, as can be seen in Fig. 6(a). In our experiments, foam injection increased total water recovery by approximately \(100\%\).
Fig. 2.

Case A: water saturation at \(t=2\,000\) s. Left column: without gravity effects; right column: with gravity effects; top row: without foam; bottom row: with foam.

Fig. 3.

Case A: water saturation at \(t=10\,000\) s. Left column: without gravity effects; right column: with gravity effects; top row: without foam; bottom row: with foam.

Fig. 4.

Case B: water saturation at \(t=2\,000\) s. Left column: without gravity effects; right column: with gravity effects; top row: without foam; bottom row: with foam.

Fig. 5.

Case B: water saturation at \(t=10\,000\) s. Left column: without gravity effects; right column: with gravity effects; top row: without foam; bottom row: with foam.

In case B, the permeability field has a more evident preferential channel in the lower region (see Fig. 1(b)). The results for this channelized porous formation (Figs. 4 and 5) reinforce the foam’s ability to reduce the effects of gravity override and viscous fingering, according to the model used, even though this case presents a more pronounced preferential path. The water cumulative production curves for case B (Fig. 6(b)) show that gravity effects on the production are much more pronounced when no foam is present; this is due to the influence of gravity on diverting the flow from the high permeability channel, resulting in higher sweeping efficiency. Moreover, foam injection in this case increases total water production by approximately \(50\%\), when gravity is considered, and by about \(100\%\) when gravity is neglected.
Fig. 6.

Water cumulative production for cases A and B.

5 Conclusions and Remarks

In this work, we presented a locally conservative numerical algorithm to solve the gas-water flow including foam injection. The system of PDEs that models this phenomenon was derived considering a fractional flow formulation based on the global pressure. The numerical staggered approach proposed combines a high-order central upwind finite volume method for the hyperbolic equations adopting BDF time integrations with a hybrid finite element method to solve the Darcy’s problem employing Raviart-Thomas spaces.

The proposed methodology was applied to simulate regimes with pure gas-water injection and gas-water-foam flow. In this context, we have established a comparison between these two regimes considering two layers of SPE10 project with different heterogeneous permeability fields. The results, based on the model proposed in [2], point to the foam’s ability to reduce the gravity override and viscous fingering even in cases of porous media with rather pronounced preferential channels.

Footnotes

Notes

Acknowledgements

The authors are thankful to Professor Pacelli P. L. Zitha for fruitful preliminary discussions.

References

  1. 1.
    Afsharpoor, A.: Mechanistic foam modeling and simulations: gas injection during surfactant-alternating-gas processes using foam-catastrophe theory. Ph.D. thesis, Louisiana State University (2009)Google Scholar
  2. 2.
    Ashoori, E., Marchesin, D., Rossen, W.R.: Roles of transient and local equilibrium foam behavior in porous media: traveling wave. Colloids Surf. A Phys. Chemical Eng. Asp. 377, 228–242 (2011).  https://doi.org/10.1016/j.colsurfa.2010.12.042CrossRefGoogle Scholar
  3. 3.
    Bangerth, W., Hartmann, R., Kanschat, G.: deal.II - a general-purpose object-oriented finite element library. ACM Trans. Math. Softw. 33(4) (2007).  https://doi.org/10.1145/1268776.1268779
  4. 4.
    Chavent, G., Jaffré, J.: Mathematical Models and Finite Elements for Reservoir Simulation: Single Phase, Multiphase and Multicomponent Flows Through Porous Media, vol. 17. North-Holland, Amsterdam (1986)zbMATHGoogle Scholar
  5. 5.
    Curtiss, C.F., Hirschfelder, J.O.: Integration of stiff equations. Proc. Natl. Acad. Sci. U. S. A. 38(3), 235 (1952)MathSciNetCrossRefGoogle Scholar
  6. 6.
    Falls, A.H., Hirasaki, G.J., Patzek, T.W., Gauglitz, D.A., Miller, D.D., Ratoulowski, T.: Development of a mechanistic foam simulator: the population balance and generation by snap-off. SPE Reserv. Eng. 3, 884–892 (1988).  https://doi.org/10.2118/14961-PACrossRefGoogle Scholar
  7. 7.
    Farajzadeh, R., Lotfollahi, M., Eftekhari, A.A., Rossen, W.R., Hirasaki, G.J.: Effect of permeability on implicit-texture foam model parameters and the limiting capillary pressure. Energy Fuels 29(5), 3011–3018 (2015).  https://doi.org/10.1021/acs.energyfuels.5b00248CrossRefGoogle Scholar
  8. 8.
    Godunov, S.K.: A difference method for numerical calculation of discontinuous solutions of the equations of hydrodynamics. Mat. Sb. 89(3), 271–306 (1959)MathSciNetzbMATHGoogle Scholar
  9. 9.
    Hematpur, H., Mahmood, S.M., Nasr, N.H., Elraies, K.A.: Foam flow in porous media: concepts, models and challenges. J. Nat. Gas Sci. Eng. 53, 163–180 (2018).  https://doi.org/10.1016/j.jngse.2018.02.017CrossRefGoogle Scholar
  10. 10.
    Hindmarsh, A.C., et al.: SUNDIALS: suite of nonlinear and differential/algebraic equation solvers. ACM Trans. Math. Softw. 31(3), 363–396 (2005)MathSciNetCrossRefGoogle Scholar
  11. 11.
    Hirasaki, G.J.: A review of the steam foam process mechanisms (1989). SPE 19518Google Scholar
  12. 12.
    Hirasaki, G.J.: The steam-foam process. J. Pet. Technol. 41(5), 449–456 (1989).  https://doi.org/10.2118/19505-PACrossRefGoogle Scholar
  13. 13.
    Hirasaki, G.J., Lawson, J.B.: Mechanisms of foam flow in porous media: apparent viscosity in smooth capillaries. SPE J. 25(02), 176–190 (1985)Google Scholar
  14. 14.
    Jones, S.A., Getrouw, N., Vincent-Bonnieu, S.: Foam flow in a model porous medium: I. The effect of foam coarsening. Soft Matter 14, 3490–3496 (2018).  https://doi.org/10.1039/C7SM01903C
  15. 15.
    Kam, S.I.: Improved mechanistic foam simulation with foam catastrophe theory. Colloids Surf. A Physicochem. Eng. Asp. 318(1), 62–77 (2008).  https://doi.org/10.1016/j.colsurfa.2007.12.017CrossRefGoogle Scholar
  16. 16.
    Kam, S.I., Nguyen, Q.P., Li, Q., Rossen, W.R.: Dynamic simulations with an improved model for foam generation. In: SPE Annual Technical Conference and Exhibition. Society of Petroleum Engineers (2004)Google Scholar
  17. 17.
    Kovscek, A.R., Patzek, T.W., Radke, C.J.: A mechanistic population balance model for transient and steady-state foam flow in boise sandstone. Chem. Eng. Sci. 50(23), 3783–3799 (1995).  https://doi.org/10.1016/0009-2509(95)00199-FCrossRefGoogle Scholar
  18. 18.
    Kurganov, A., Noelle, S., Petrova, G.: Semidiscrete central-upwind schemes for hyperbolic conservation laws and Hamilton-Jacobi equations. SIAM J. Sci. Comput. 23(3), 707–740 (2001).  https://doi.org/10.1137/S1064827500373413MathSciNetCrossRefzbMATHGoogle Scholar
  19. 19.
    Kurganov, A., Tadmor, E.: New high-resolution central schemes for nonlinear conservation laws and convection-diffusion equations. J. Comput. Phys. 160(1), 241–282 (2000).  https://doi.org/10.1006/jcph.2000.6459MathSciNetCrossRefzbMATHGoogle Scholar
  20. 20.
    Ma, K., Farajzadeh, R., Lopez-Salinas, J.L., Miller, C.A., Biswal, S.L., Hirasaki, G.J.: Non-uniqueness, numerical artifacts, and parameter sensitivity in simulating steady-state and transient foam flow through porous media. Transp. Porous Media 102(3), 325–348 (2014).  https://doi.org/10.1007/s11242-014-0276-9CrossRefGoogle Scholar
  21. 21.
    Ma, K., Ren, G., Mateen, K., Morel, D., Cordelier, P.: Modeling techniques for foam flow in porous media. SPE J. 20(3), 453–470 (2015)CrossRefGoogle Scholar
  22. 22.
    Raviart, P.A., Thomas, J.M.: A mixed finite element method for 2-nd order elliptic problems. In: Galligani, I., Magenes, E. (eds.) Mathematical Aspects of Finite Element Methods. LNM, vol. 606, pp. 292–315. Springer, Heidelberg (1977).  https://doi.org/10.1007/BFb0064470CrossRefGoogle Scholar
  23. 23.
    Smith, D.H. (ed.): Surfactant-Based Mobility Control. No. 373 in ACS Symp. Ser., Am. Chem. Soc., Washington, D.C. (1988)Google Scholar
  24. 24.
    Zitha, P.L.J.: A new stochastic bubble population model for foam in porous media. In: SPE/DOE Symposium on Improved Oil Recovery. Society of Petroleum Engineers (2006)Google Scholar
  25. 25.
    Zitha, P.L.J., Du, D.X., Uijttenhout, M., Nguyen, Q.P.: Numerical analysis of a new stochastic bubble population foam model. In: SPE/DOE Symposium on Improved Oil Recovery. Society of Petroleum Engineers (2006)Google Scholar

Copyright information

© Springer Nature Switzerland AG 2020

Authors and Affiliations

  1. 1.Laboratório de Matemática Aplicada – LAMAPJuiz de ForaBrazil
  2. 2.Graduate Program on Computational ModelingFederal University of Juiz de ForaJuiz de ForaBrazil

Personalised recommendations