• Tidak ada hasil yang ditemukan

Chapter 5. Upscaling Two-Phase Flows

5.1. Pressure Equation

analytical upscaling method. We will design a numerical upscaling method based on the MSFEM, which was introduced by Hou and Wu [28].

The MSFEM is particularly suitable for our purpose because it allows for down- scaling. The idea is to define basis functions over coarse cells that satisfy the elliptic operator in a local problem subject to linear boundary conditions on the boundary of the cell. The basis functions resolve the fine scale. The operator that downscales all quantities from the coarse to the fine grid is given by the basis functions. Besides the theoretical importance of being able to compress multiscale operators using a mul- tiscale basis set, the MSFEM can lead to an efficient upscaling method if we don’t recompute the basis functions at every pressure time step. Then we have a method with a computational time that is a function of the number of coarse cells. The fact that the basis functions don’t need to be updated has not been proven rigorously but has been observed in many two-phase flow experiments [22]. This experimental validation shows that the basis functions truly capture most of the fine scale behavior and that the MSFEM method rests on a sound idea.

As in every finite element method the continuous problem is discretized by project- ing the solution onto a finite dimensional space that is spanned by the basis functions.

The basis functions satisfy the same equation as the pressure on the coarse blocks of the domain. The main difficulty is to determine the boundary condition for the basis functions. A second drawback of the conforming MSFEM is the presence of resonance error in the basis functions near the cell boundary. This was noted by Hou, Wu, and Cai in [28], and they proposed the method of oversampling to improve on it [23]. However MSFEM with oversampling is non-conforming, which implies that the pressure is be continuous across the coarse blocks, and we cannot use it to com- pute the fine velocity. The mixed MSFEM of Chen and Hou [9] gives a conservative fine velocity within each basis and a coarse velocity that is also conservative. Their computations have excellent conservation properties. In our case we cannot use their algorithm because the fine velocity field will be nonconservative across coarse blocks, which can make the transformation singular. In this chapter we will see how to deal with both of these difficulties by changing to an adaptive coordinate frame.

5.1.2. The Modified MSFEM. It is well known that the domain of dependence for an elliptic operator is the whole domain over which the problem is defined. In practical terms this means that changing the value of the permeability at one point will affect the solution at every other point in the domain. In MSFEM methods we decompose the computation into a local part of computing the basis functions and a global part where all the local solutions are coupled together. The MSFEM basis functions are determined locally in each coarse cell and contain only information about the local structure of the operator to be upscaled.

For the case when the permeability has structures with long-range correlation that need to be captured, such as high permeability channels, Efendiev, Ginting, and Hou [22] proposed to incorporate more global information into the basis functions. They use the solution to the fine pressure problem at the initial time for supplying the boundary condition of the cell problem. Their method is referred to as the modified MSFEM. The motivation is that the connectivity of the fast channels will be reflected in the initial pressure and, through the cell boundary condition, in the basis functions as well. Even though the computation of the basis functions are decoupled in the sense that they can be done independent of each other, the basis functions contain some information about the global structure of the permeability.

The modified MSFEM is a conforming method and gives a continuous fine velocity field. Like the computation of the basis functions, computing the fine pressure initially is also a one time overhead of the method. In their study Efendiev, Ginting, and Hou observed that the modified MSFEM performs better than MSFEM. They were also able to demonstrate this analytically in certain cases. More importantly for us, the modified MSFEM performs better than MSFEM with oversampling, which means that it also removes the resonance error.

5.1.3. The Modified MSFEM in the Pressure-Streamline Frame. The framework of the modified MSFEM fits our purposes well. We want to tackle problems with fast channels, and we need to be able to compute the fine velocity field to upscale the saturation equation. We adapt it slightly at no extra computational cost to fit the

philosophy of our upscaling method for the saturation equation that was described in section 4.1.1.

For the saturation equation we picked the coarse blocks over which we average to have constant size in the pressure-streamline frame. We will follow the same idea for the pressure as well. Upscaling means finding the effective behavior or simply averaging, and our choice of frame will group regions of high and low velocity in separate cells. The variations in the velocity are to a large extent caused by the variations in λK. So we expect the variation of λK to be smaller in each coarse cell than if we had selected square cells in a Cartesian frame, which will lead to a smaller upscaling error for the pressure.

As in the modified MSFEM we solve for the initial pressure for the boundary condition for the bases. However we will then transform to the frame of the initial pressure P0 and streamfunction Ψ0 to pick the shape of the coarse blocks. The coarse blocks will be defined by the lines p0 = ihc, ψ0 = jhc. For the basis functions of the MSFEM, we select a linear boundary condition on edges with p0 = ihc and no-flux boundary conditions on edges with ψ0 = jhc. Initially the exact solution of the pressure equation in the pressure-streamline frame is of course the identity P(t = 0, p0, ψ0) = p0. This means the boundary condition for our basis functions coincides with the fine pressure solution initially, as in the modified MSFEM. In our method the long-range correlations of the basis functions are captured by the coordinate frame, whereas they are captured by the basis functions in the modified MSFEM.

If we assume that the pressure at time ∆thas not changed much from the pressure at time 0, then the level sets P(∆t, p =ihc, ψ) = ihc have not changed much either, and our boundary condition for the basis functions remains accurate. In figure 5.1.1 the solid lines show a coarse block in the (x, y) and (p(0), ψ(0)) frames. The dashed lines show the level sets of the pressure and streamfunction a short time afterwards.

The are very close to the boundaries of the cell. A justification why this is so is that the pressure does not have a two-scale structure to lowest order for permeabilities with periodic fast variables according to homogenization theory. We cannot use the

Figure 5.1.1. Boundary conditions for the cells of the pressure equation

In a pressure streamline frame, lines of constant pressure and saturation form a uniform grid.

same line of reasoning for the no-flux boundary conditions because they depend on the derivative of the pressure.

5.1.4. Derivation of the Equations. We write the pressure equation in terms of the new variables. Let ζ = p0 and η = ψ0. First we derive the elements of the Jacobian matrix and its inverse. They relate the differentials in x, y to differentials in ζ, η in the following way

 dX dY

 =

Xζ Xη

Yζ Yη

 dζ dη

=J−1

 dζ dη

 dζ dη

 =

ζx ζy

ηx ηy

 dX dY

=J

 dX dY

. Solving the second equation for dX, dY we get

 dX dY

= 1 ζxηy −ζyηx

ηy −ζy

−ηx ζx

 dζ dη

.

Comparing the two equations fordX, dY we find the elements of the Jacobian matrix and its inverse

ζx = λu00K ζy = λv00K ηx = −v0 ηy = u0

Xζ = kvu00k2λ0K Xη = k−vv0k02

Yζ = kvv00k2λ0K Yη = kvu00k2

J0 = kλv0k2

0K J0−1 =kv0k−2λ0K.

We have used v0 = λ0K∇P0, ∇Ψ0 = v0. Using the chain rule on the pressure we

find 

 Pζ

Pη

=

Xζ Yζ

Xη Yη

 Px

Py

.

Solving this equation forPx,Py we derive the rule for the transformation of derivatives Px = 1

J0−1 ((YηPζ)−(YζPη)) Py = 1

J0−1 (−(XηPζ) + (XζPη)).

We can take the pressure derivatives of the innermost parentheses outside the paren- theses

Px = 1

J0−1 ((YηP)ζ−(YζP)η) Py = 1

J0−1 (−(XηP)ζ+ (XζP)η). Applying this rule twice we get

xλKPx = 1 J0−1

(YηλK 1

J0−1((YηP)ζ−(YζP)η))ζ−(YζλK 1

J0−1 ((YηP)ζ−(YζP)η))η

yλKPy = 1 J0−1

−(XηλK 1

J0−1 (−(XηP)ζ+ (XζP)η))ζ+ (Xζ 1

J0−1 (−(XηP)ζ+ (XζP)η))η

. We can write the transformed operator using the metric tensor

∇λK∇P 7−→ 1 J0−1ζ,η

λKYη2J+X1η2 λK−YηYJζ−X1 ηXζ

λK−YηYJζ−X1 ηXζ λKY

2 ζ+X2ζ

J1

∇ζ,ηP.

Using the expressions for the elements of the Jacobian matrix we find 1

J0−1ζ,η

λ

λ0 0

0 λλ0K2

∇ζ,ηP.

The saturation equation becomes

St+ (v· ∇P0)Sζ+ (v· ∇Ψ0)Sη = 0.

We propose a second transformation to solve the saturation in the frame of P,Ψ.

It is defined in terms of the velocity vζ,η in the ζ,η frame with vζ,η = Aoζ,ηP,

ζ,ηΨ0 =vζ,η . The chain rule gives a useful relation

vζ,η = Aoζ,ηP =A0

Xζ Yζ

Xη Yη

∇P

=

λ

λ0 0

0 λλ0K2

u0

kv0k2λ0K kvv0

0k2λ0K

−v0

kv0k2

u0

kv0k2

∇P

= λKJ0−1

u0

λ0K v0

λ0K

−v0 u0

∇P =J0−1

v· ∇P0

v· ∇Ψ0

⇒ J0vζ,η =

v· ∇P0 v· ∇Ψ0

.

Using this relation we rewrite the velocity (v·∇P0,v·∇Ψ0)·∇ζ,ηP in theP, Ψ frame, and we arrive at the following saturation equation

St+J0vζ,ηA−1o vζ,ηSp = 0.

The full algorithm is shown in figure 5.1.2. There are three different time steps involved in the algorithm: ∆tB, the time between two updates of the bases, ∆tP, the time between two updates of the pressure, and the time step of the saturation equation. In practice we rarely have to update the basis functions. In all experiments that follow, updating the basis functions lead to no significant improvement.