1 Introduction

The simulation of immiscible displacement and the description of two-phase interface movement are essential in many industries, e.g., oil and gas recovery, CO2 sequestration (Wang 2018; Tzelepis 2015; Yang 2020; Yang et al. 2020). Even in an individual channel, viscous fingering will occur when a less viscous fluid displaces a more viscous one, not to mention in porous media. However, if the viscosity ratio or the capillary number is small enough, this phenomenon will not appear. The study of viscous fingering in mesoscopic channels has been extended from smooth channels to rough ones, whereas the threshold values of diverse parameters forming viscous fingering have been given through a series of numerical simulations and sensitivity analyses. Zhong 2018 studied the transport and phase change of a complex fluid mixture with a lab-on-chip technology and found that immiscible gas flooding in nanoporous medium (shale) produces capillary finger-like fluids, which is similar to microspore medium dynamics. Kang et al. 2004 studied the relationship between viscous finger morphology and wall wettability, capillary number and viscosity ratio using Lattice Boltzmann method (LBM). The result shows that high capillary number is conducive to the formation of viscous fingers, while the effect of dynamic contact angle and moving contact line on flow cannot be ignored. Zhu 2016 used the phase-field model to determine the position of the water–oil interface and analyzed different dynamic contact angle models as well as the factors affecting the dynamic contact angle. Fan et al. 2001 simulated the contact line dynamics of immiscible fluid displacements in a two-dimensional capillary channel with an ideally smooth wall using a Lattice Boltzmann model. However, compared to numerous studies researching in the moving contact line dynamics and dynamic contact angle for the stable displacement of two-phase interface, studies on the two-phase interface movement in rough channels are relatively rare. Therefore, the conclusions of this study will have a significant influence on the understanding of enhanced oil recovery by water injection.

At present, with the development of lab-on-chip technology (Zhong 2018) and numerical simulation technology (Wang 2018, 2020; Tzelepis 2015; Davar and Sadri 2018; Sussman et al. 1994; Liu 2021; Yang 2019), numerous studies have been carried out on pore scale two-phase flow in order to investigate its influencing factors. Davar and Sadri 2018 studied the effect of fracture roughness on the porous media permeability by direct simulation method and found that roughness had a great influence on porous media with small pore radius. Luo 2006) used the fluid volume method to study the moving contact line dynamics in a wavy tube and analyzed the influence of rough wall surface on the jumping phenomenon of moving contact line. Zhang 2019 used LBM to analyze the influence of microflow effect and wall roughness on flow rate, finding the equilibrium point between two factors to reveal the mechanism of microflow in two-dimensional fractures. Mahoney 2017 analyzed the relationship between wall roughness and wetting angle. Most studies on pore scale two-phase flow focused on the influence of wettability, interfacial tension, viscosity ratio and other factors on two-phase flow, while the influence of wall roughness on interfacial movement was ignored.

Several pore scale methods have been used for multiphase flow simulations in porous media, such as pore-network model (Blunt and King 1991), lattice Boltzmann method (LBM) (Lei, et al. 2015; Zhang 2016; Zhang, et al. 2019) level set method (Osher and Sethian 1988), the volume-of-fluid (VOF) method (Hirt and Nichols 1981) and phase-field method(Zhu and Li 2020). Every method has its advantages and disadvantages. In this paper, the displacement process of two-phase fluid in a rough channel is simulated by solving N–S equation directly, whereas the two-phase interface is tracked by using the phase-field method (Zhu 2019a, 2020). The theory of the phase-field method is explained in detail in Sect. 2. The wall roughness is simulated by adding regular geometries on the wall, whose influence on interface movement is investigated by comparing the flow pattern with that in smooth channels. Besides, the influence of wall wettability and capillary number on two-phase flow in rough channels is also analyzed.

2 Mathematical Model

2.1 Fluid Flow Model

The continuity equation is written as (Finel et al. 2018):

$$\nabla .{\text{u = 0}}$$
(1)

For a fluid in a two-dimensional porous medium, it can be expressed as (Chong 2016):

$$\rho \left[ {\frac{\partial u}{{\partial t}} + \left( {u.\nabla } \right)u} \right] = \nabla .\left( { - P{\text{I + }}\mu \left[ {\nabla u + \left( {\nabla u} \right)^{T} } \right]} \right) + \rho g + F_{st}$$
(2)

where P is fluid pressure; ρ is the density of the fluid; μ denotes the velocity of the fluid; I represents the unit vector; t is the time: Fst interfacial tension term.

2.2 Phase-Field Method

The fluid flow in porous media can be described by N–S equation. For the two-phase flow, the phase-field method is introduced to track topological changes of the interface between fluids in real time. In the method, a phase-field variable ϕ is introduced to represent two bulk phase, the interface is treated as a thin and continuous layer to eliminate the singularities. The phase-field variable is usually taken as 0 or 1 in the bulk phases, and it varies continuously between 0 and 1 across the interface. The Ginzburg–Landau free energy functional is generally used to represent the mixing energy inside the interface (Gunde et al. 2010):

$$F = \int\limits_{v} {\left[ {\lambda f\left( \phi \right) + \frac{\lambda }{2}\left| {\nabla \phi } \right|^{2} } \right]} dV$$
(3)

where the parameter λ determines the interfacial tension in the phase-field method; ε is the parameters associated with the interface thickness; the square gradient term \(\frac{1}{2}\lambda \left| {\nabla \phi } \right|^{2}\) represents weakly non-local interactions between fluids that contribute to the complete mixing of phases. The double-well potential f(ϕ) leads to the total separation of phases and the production of the classical sharp interface picture, and it can be written as (Yue 2004):

$$f\left( \phi \right) = \frac{1}{{4\varepsilon^{2} }}\phi^{2} \left( {1 - \phi^{2} } \right)$$
(4)

Through the variational derivative of the free energy functional F with respect to the phase-field variable ϕ, we can obtain the chemical potential G (Zhu 2018):

$$G = \frac{\delta F}{{\delta \phi }} = \lambda \left[ { - \nabla^{2} \phi + \frac{{\phi \left( {\phi^{2} - 1} \right)}}{{\varepsilon^{2} }}} \right]$$
(5)

The evolution of the interface between two fluids can be described by the classical Cahn–Hilliard equation (Zhu et al. 2017; Yue 2006; Boyer 2010; Zhu 2019b):

$$\left\{ \begin{gathered} \frac{\partial \phi }{{\partial t}} + {\text{u}}{.}\nabla \phi = \nabla .\left( {\frac{\gamma \lambda }{{\varepsilon^{2} }}\nabla \psi } \right) \hfill \\ \psi = - \nabla .\varepsilon^{2} \nabla \phi + \left( {\phi^{2} - 1} \right)\phi \hfill \\ \end{gathered} \right.$$
(6)

where γ is a mobility parameter. The interfacial tension term in the momentum equation can be expressed as (Villanueva and Amberg 2006)

$${\mathbf{F}}_{st} = G\nabla \phi$$
(7)

Assuming the density function ρ and viscosity ν has the following linear relations (Yue 2004):

$$\rho = \frac{1 + \phi }{2}\rho_{n} + \frac{1 - \phi }{2}\rho_{w}$$
(8)
$$\mu = \frac{1 + \phi }{2}\mu_{n} + \frac{1 - \phi }{2}\mu_{w}$$
(9)

where w and n represent wetting phase and non-wetting phase, respectively.

On the solid surface, the following boundary conditions are imposed (Zhu 2019b):

$$\left\{ \begin{gathered} {\mathbf{u}}_{{\mathbf{n}}} = 0, \hfill \\ {\mathbf{n}} \cdot \frac{\gamma \lambda }{{\varepsilon^{2} }}\nabla \psi = 0 \hfill \\ {\mathbf{n}} \cdot \varepsilon^{2} \nabla \psi = \varepsilon^{2} \cos \left( {\theta_{w} } \right)\left| {\nabla \psi } \right|, \hfill \\ \end{gathered} \right.$$
(10)

The above phase-field two-phase flow model was verified by the case of capillary imbibition in the author’s previous studies (Yao 2019; Guo et al. 2019).

3 Results and Discussion

3.1 Influence of Rough Wall Surface on Oil–Water Flow

The influence of wall roughness on two-phase flow was studied by simulating oil–water two-phase flow in pore channel with a 40 μm × 110 μm model, while the size of rough wall particles is 3 μm × 3 μm. The pressure at the entrance is 3200 Pa, while the pressure at the outlet is 0 Pa. As Fig. 1 shows, the blue phase is water while the red phase is oil. The density of oil and water is 890 kg m−3 and 1000 kg m−3, respectively. In order to form a stable displacement process, the viscosity of oil and water phase is set to be 15 mPa s, the interface tension between oil and water is σ = 0.04 N m−1, the contact angle between the oil phase and the wall surface is 75°, which means the channel is an oil-wet one. The displacement distance of the interface is the displacement distance of the top of the two-phase interface.

Fig. 1
figure 1

Immiscible displacement in a smooth channel and a rough channel: a smooth channel; b rough channel

Figure 1 compares the movement process of oil–water interface in smooth and rough channels at different moments. It can be observed that at the same time, the movement distance of the two-phase interface in smooth channels is significantly longer than that in rough channels. As can be seen from Fig. 2, the moving velocity at the top of the interface in a smooth channel is also obviously higher than that in a rough channel. The roughness of the wall increases the resistance of the two-phase fluid flow and forms a "drag" effect on the movement of the two-phase interface. Under same displacement conditions, the velocity of interface movement in rough channels becomes obviously slower, and the flow rate in the channels decreases. In addition, as shown in Fig. 3, wall roughness also has effects on the morphology of the two-phase interface. The interface length is defined as the distance from the section at the top of the interface to the section at the three-phase contact point (as shown in Fig. 1a). In the initial stage of displacement, the deformation of the interface is determined by the displacement velocity, which is fast in smooth channel because of the smaller flow resistance, and the deformation degree of the interface is larger. The length of the interface in smooth channels is larger than that in rough channels. In the second stage of displacement, the interface morphology in smooth channel tends to reach stability; however, in the rough channels, the viscous fingering phenomenon appears due to the influence of rough wall. Overall, the influence of wall roughness on the two-phase interface is mainly divided into two aspects: one is to reduce the velocity of the interface due to the resistance; the other is to enhance the deformation of the interface, which tends to form a viscous finger.

Fig. 2
figure 2

Interface moving distance in a smooth channel and a rough channel

Fig. 3
figure 3

Evolution of interface length in a smooth channel and a rough channel

3.2 Influence of Wettability on Oil and Water Flow in Rough Channel

In order to study the influence of wall wettability on two-phase flow in rough channels as well as the interface movement, a water flooding simulation was carried out in a channel with more rough particles. The result will be compared with that in smooth channels. The size of this channel is 40 μm × 200 μm. The pressure at the left end is 2500 Pa, while at the right end it is 0 Pa. The particle size at the rough wall is 2 μm × 2 μm, and the distance between two particles is 2 μm. The contact angle in this simulation is the angle between the wall surface and the oil drop. When the contact angle increases, the wettability changes from oil–wet to water-wet. The relevant parameters of two-phase fluids are the same as those in Sect. 3.1.

As shown in Fig. 4, the two-phase flow of water flooding in rough channels shows different flow patterns under diverse wettability conditions. Under the water-wet condition, water will also enter into the grooves of rough wall surface under the function of capillary forces and dislodge part of remaining oil. Besides, the interface of displacement leading edge also enters the groove. Under the oil-wet condition, capillary force is the resistance to water flooding. Moreover, the groove size of rough surface is small, and the capillary resistance generated is relatively large, so that the injected water is difficult to enter the groove of rough wall surface. Here is the phenomenon of "jumping" in the contact point of water–oil displacement front. The stronger the lipophilicity is, the more obvious the phenomenon of "jumping" will be. In the oil-wet rough channel, the injected water will directly "slip through" the rough surface, and the rough wall has a great influence on the deformation of the two-phase interface.

Fig. 4
figure 4

Immiscible displacement in a rough channel under different wetting conditions: a oil-wet with a contact angle 45°; b water-wet with a contact angle 135°

Figure 5 compares the movement distance of the two-phase interface with time under different contact angles. The contact angle changes from 45°to 135°, from oil-wet to water-wet. It can be observed that the velocity of interface movement in water-wet channels is significantly higher than that in oil-wet channels, which is caused by capillary force. However, no matter under which condition, the roughness of the wall surface will increase the resistance of two-phase flow and slow down the interface movement velocity. Subsequently, more water flooding processes under different wettability conditions are studied, as shown in Fig. 6. In smooth channels and rough channels, the moving velocity of the interface is approximately linear to the contact angle. With the increase in the contact angle (hydrophilic enhancement), the moving speed of the two-phase interface increases rapidly. However, the influence of wall wettability on the velocity of the movement of interface is different under various wall conditions. The influence of wettability on interface movement in rough channels is significantly lower than that in smooth channels. As the interaction between the rough wall surface and the fluid increases, the frictional drag increases. The effect of capillary force, which is closely related to the wettability of the wall, decreases on the movement of the two-phase interface in the channels. Therefore, the influence of wettability on the velocity of two-phase interface is weakened in rough channels. Figure 7 compares the ratio of the interface movement velocity in rough channels under different wettability conditions to that in smooth channels. The result reflects the influence of roughness on the interface movement velocity under different wettability conditions. As the wettability of wall surface changes from oil-wet to water-wet, the influence of rough wall surface on the moving velocity of two-phase interface falls down.

Fig. 5
figure 5

Immiscible displacement of smooth channel and rough channel with different contacts angles: a smooth channel b rough channel

Fig. 6
figure 6

Moving velocities of interface in a smooth channel and a rough channel for different wetting conditions (the contact angle is defined as the contact angle between the wall of the channel and the oil)

Fig. 7
figure 7

The ratio of two velocities (Vrough/Vsmooth) for different wettability conditions (the contact angle is defined as the contact angle between the wall of the channel and the oil)

An another interesting case is when the rough particles are changed, as shown in Fig. 8. Under water-wet condition, the change of roughness height causes different patterns in wall surface. When the roughness height is 2.55um, a stable oil film is generated on the wall surface, presenting an oil-wet. By changing the roughness height to 2.525 μm, the oil film is not stable any more, and some discontinuity will occur, which presents mixed wettability. This interesting phenomenon reflects that roughness has a great influence on wettability. It seems that wall wettability cannot be represented by contact angle in the traditional sense. As far as we know, this wettability change is not only related to roughness, but also a process influenced by multiple factors, such as viscosity ratio and capillary number. This will be our main topic in our future work.

Fig. 8
figure 8

Effects of different roughness heights on wettability

3.3 Influence of Capillary Number on Oil–Water Flow in Rough Channel

The occurrence of viscous fingering is usually changed by capillary number. In this section, the effect of capillary number on rough channels is investigated. The capillary number Ca is defined as \(C_{a} = \frac{{\mu {\text{v}}}}{\sigma }\). The same model of Sect. 3.2 will be used to simulate the influence of different Ca on the two-phase flow and its interface movement along the rough walls. The channel size is 40 μm × 200 μm.

Figure 9 compares the influence of capillary number on water flooding at t = 0.002 s, while the capillary number ranges from 0.00656 to 0.04838. With the increase in capillary number, the length of the interface keeps increasing, which has a great impact on the stability of oil–water interface. Figure 9a shows the shape of the two-phase interface when the capillary number is 0.00656 and the interface is in a stable state. Figure 9b, c, d and e illustrates the process of continuous changes of the two-phase interface under the increasing capillary number. It can be observed that the increasing degree of interfacial curvature and the gradual formation of finger-like patterns. When the capillary number is higher than a certain critical value, finger phenomenon is obvious. Figure 9 only demonstrates that the increase in capillary number has a promoting effect on the generation of fingering phenomenon.

Fig. 9
figure 9

The distribution of oil and water under different capillary numbers at t = 0.002 s. a Ca = 0.00656 b Ca = 0.02209 c Ca = 0.03165 d Ca = 0.03975 e Ca = 0.04838

In order to find the threshold value, a quantitative study is conducted on the influence of capillary number on rough channels. A dimensionless number Lr is defined as the ratio of interface length to channel length, which describes the instability of the interface. The Lr numbers are calculated in a series of simulations with different Ca numbers, and the relationship between Lr and Ca is shown in Fig. 10, which is an exponential function-like relationship. It can be seen from the image that when the critical value is reached after the capillary number exceeds 0.03574, the Lr will increase dramatically, which attributes to the occurrence of fingering phenomenon at this time. Therefore, the larger the capillary number is, the greater the effect on the interface instability, which is approximately an exponential growth, will be.

Fig. 10
figure 10

Finger development under different rough conditions and Ca = 0.04838: a rough channel b smooth channel

Furthermore, the fingering phenomena are compared between rough channels and smooth channels for the highest capillary number case. Figure 11 presents that the interface changes under displacement condition of Ca = 0.04838. As shown in Fig. 11a, b, the two-phase interface of the smooth wall surface is still very stable, while the fingering phenomenon is obvious in rough channels under the same condition. This indicates that the occurrence of fingering is also multifactorial, and the roughness of wall surface is a vital factor to be noted, which plays a significant role in amplifying the effect of capillary number (Fig. 10).

Fig. 11
figure 11

Relationship between the ratio of interface length to channel length and capillary number

4 Conclusion

In this paper, a microcosmic two-phase flow model based on N-S equation and phase-field method is used to track the changes of two-phase interface. The process of water flooding in rough channels is studied, and the influence of wall roughness, wettability as well as capillary number on rough channels are investigated. Although this particular geometric study has some limitations because it differs from the real stratigraphic structure, the results of this study are very instructive for the impact of rough environments on flows. The following conclusions can be drawn:

  1. (1)

    The roughness of the wall will increase the resistance of two-phase flow. Compared to water flooding in smooth channels, the velocity of the phase interface will decrease significantly in rough ones, which results in the reduction in flow rate under the same conditions.

  2. (2)

    The rough surface will increase the deformation of the oil–water interface, promoting the formation of viscous fingering, which is not conducive to the displacement of remaining oil.

  3. (3)

    The effect of wall wettability on the velocity of two-phase interface in rough channels is smaller than that in smoother ones. In the process of water flooding, the influence of wall roughness on two-phase interface movement in oil-wet channels is greater than that in the water-wet channels.

  4. (4)

    Capillary number has a great influence on the instability of the interface in rough wall surface. With the increase in capillary number, the greater the instability of the interface is, the more likely it is to produce the phenomenon of viscous fingering, which is more obvious above 0.03574.

Based on the above conclusions, it can be concluded that the appearance of viscous fingering is influenced by the capillary number and wall roughness, although the effects of capillary number on rough and smooth walls are different. Wettability also has various impacts under diverse rough conditions. This paper gives us a general reference to the impact of rough wall surfaces on wettability and capillary number. In order to simulate the effects of detailed roughness on various parameters, it is meaningful to use different rough distributions and more diverse or complex geometric structures, which is also one of the future works.