Impact of physical phenomena and cyclical reinjection in miscible CO2-WAG recovery in carbonate reservoirs

Carbonated reservoirs with high percentage of CO2 have been discovered and produced in the Brazilian pre-salt cluster. Recovery techniques, such as CO2-WAG, have hence been evaluated and applied, as in the Lula field. Although studies demonstrate the advantages of this technique, it is still difficult to estimate an increase in oil recovery. Thus, this work presents a methodology to evaluate the impacts of the main phenomena that occur and how CO2 recycling can benefit the management of these fields. The results showed an increase in recovery with the modeling of the main phenomena such as relative permeability hysteresis and aqueous solubility of CO2, accompanied by a significant increase in CO2 injection. However, the recycling of the CO2 produced was shown to be fundamental in the reduction in this injection and to increase the NPV. The results showed a 4% increase in oil production and 9% in NPV, considering a producer–injector pair.


Introduction
Recent discoveries of reservoirs with high concentrations of carbon dioxide (CO 2 ) have boosted the research and applications of EOR methods involving this gas. In Brazil, the pre-salt carbonate reservoirs can have up to 50% of the molar fraction of CO 2 . This high percentage of CO 2 in the reservoirs, together with the long distance from the coast, limitations of handling, drainage and storage of the gas produced, as well as the possible environmental impacts caused by the release of this gas into the atmosphere, made the technique of water alternating CO 2 injection (CO 2 -WAG) one of the main special recovery methods to be used in these reservoirs. In fact, this method has already been used by Petrobras in the Lula field, in the Santos Basin, since 2011, but the increase in its recovery factor cannot yet be safely estimated.
In fields with a high percentage of CO 2 , it is extremely relevant to investigate the best type of recovery, such as continuous gas injection (CGI), injection of water alternated with CO 2 (CO 2 -WAG), simultaneous injection of water and CO 2 (SWAG), as well as the reinjection of the natural gas produced (hydrocarbon gas) or other gases. Regarding the miscibility of CO 2 in the oil, we can still have immiscible WAG (IWAG) and miscible WAG (MWAG). The type of gas injected is also a highlight; applications with CO 2 injections have produced better results than hydrocarbons or other gases (Christensen et al. 1998). The literature results also showed higher efficiency of CO 2 -WAG injections compared to pure CO 2 injections (Duchenne et al. 2014). However, these recovery methods present high operating costs due to the gas, which represents a large fraction of the total cost, besides requiring compression and gas injection equipment, especially for CO 2 . The main problems encountered were related to the early arrival of water or gas (breakthrough), injectivity in the wells and formation of asphaltenes and hydrates. For CO 2 injection, severe corrosion problems were also observed, although they also occur with other types of gases at lower intensity (Christensen et al. 1998).
Studies and production results have shown that the use of CO 2 as an injection fluid can also be very attractive in highly heterogeneous and fractured reservoirs, such as in pre-salt carbonate reservoirs, increasing oil recovery (Christensen et al. 1998;Brown et al. 2013;Laochamroonvorapongse et al. 2014;Teklu et al. 2016). In fact, Laochamroonvorapongse et al. (2014) presented analytical tools to monitor the performance in the miscible WAG injection (MWAG) in carbonate reservoirs. The results showed the efficiency of these tools in analyzing producer-injector connectivity and in evaluating WAG performance. Teklu et al. (2016) studied the CO 2 -WAG injection with low salinity water (LS-WAG-CO 2 ) in the recovery of carbonate reservoirs. The WAG method studied involved only one cycle, and the results were 14% and 25% increases in oil recovery in two samples of carbonates. Brown et al. (2013) developed a three-dimensional, three-phase and parallel simulator to treat a large computational effort involving CO 2 in the WAG process in a carbonate reservoir model. The algorithms were developed to calculate three-phase relative permeability and capillary pressure, including the effects of gas entrapment and relative permeability hysteresis. They concluded that it was extremely important to correctly model the entrapment of oil, water and gas, because the incorrect estimation of the imprisoned fluids resulted in the over or underestimation of the CO 2 stored in the reservoir and the increase in the oil recovery.
Thus, the process of alternating water and gas injection aims to increase the efficiency of sweeping and, consequently, the recovery factor of the reservoir. The continuous injection of CO 2 can cause a high gas mobility in the reservoir, which could lead to the early arrival of this gas in the wells (early breakthrough). One way to overcome this problem is to make it miscible in the reservoir fluid, to delay the effect. Thus, increased efficiency will occur more strongly above the minimum miscibility pressure (MMP) (Christensen et al. 1998;Kulkarni and Rao 2005). A combination of the advantages of CO 2 and water injections is expected by improving microscopic displacement and macroscopic sweeping efficiency (Christensen et al. 2001), respectively, reducing the residual oil. As is known, the efficiency of macroscopic sweeping due to water is obtained by the product of vertical and horizontal sweeping efficiencies. In turn, the efficiency of the microscopic displacement occurs with the decrease in the gas mobility and capillary forces, guaranteeing greater efficiency in the displacement due to the gas, by causing a low interfacial tension between the oil and gas phases, tending to zero when the gas becomes miscible in the reservoir fluid (Egermann et al. 2006). Because recovery efficiency is the product of vertical and horizontal efficiencies with displacement efficiencies, these expected and combined effects will result in increased reservoir recovery. Batruny and Babadagli (2015) showed that a large volume of water initially injected significantly reduces the miscibility of the gas in the oil, hindering the oil recovery. In their work, there was a critical limit for the initial water volume injection. Wang et al. (2017) carried out experiments to measure the minimum miscibility pressure (MMP) and to guarantee the CO 2 miscibility condition, to evaluate the recovery and the reduction in permeability caused by asphaltene and inorganic deposition in low permeability sandstone reservoirs. Laochamroonvorapongse et al. (2014) also studied the miscible and immiscible conditions. Teklu et al. (2016) experimentally verified the condition of miscibility using rising bubble apparatus (RBA) and multiple mixing cell (MMC). Kulkarni and Rao (2005) showed that the results with WAG recovery were better than CGI and the miscible condition was more favorable than the immiscible. Duchenne et al. (2014) investigated the microscopic efficiency of CO 2 in the WAG injection well above the minimum pressure of miscibility (MMP) in the samples. They found recovery factors of the order of 80%, measured through a precise system of monitoring the saturations of the three phases and by calculating the volume produced. Wang et al. (2020) studied the transition from immiscible to near miscible conditions in CO 2 -WAG injection and continuous CO 2 in two simple models (1D and 2D). These models were used to analyze two physical mechanisms, namely compositional effects and low interfacial tension (IFT). The first produced oil stripping effects while the second implied an increased mobility of oil phase due to enhanced film formation. The latter was studied through two different models, Betté and Coats, due to an alteration in the oil relative permeability. The authors used tracer analysis in simulations to demonstrate the effect of combining both mechanisms, a viscous crossflow between non-preferential and preferential flow paths. They concluded that IFT effects could have a great impact on the fluid behavior and the oil recovery in near miscible WAG injection. However, their work did not consider the impact of relative permeability hysteresis and aqueous solubility of CO 2 in these mechanisms and the optimization of operational parameters in CO 2 -WAG.
In WAG recovery, there is also the need to optimize several parameters, the main ones being the relation between the water injected and gas flows, known as WAG ratio, and the duration of the cycle of alternating injections, known as the WAG cycle. A few studies have focused on the CO 2 -WAG injection optimization process (Rahmawati et al. 2013;Panjalizadeh et al. 2015;Chen and Reynolds 2017;You et al. 2020). This is largely due to the EOR optimization processes requiring many simulations, with high computational and financial costs. Rahmawati et al. (2013) used an optimization approach called mixed integer for nonlinear problems (MINLP) and an optimization method called Nelder-Mead simplex reflection to maximize the NPV. However, they studied only a single cycle of gas (hydrocarbon) injection followed by water and used only top hole pressure (THP) as the control variable. Chen and Reynolds (2017) employed a method called ensemble based for the simultaneous optimization of bottom hole pressures (BHP), well rates and inflow control valves (ICVs). Spiteri and Juanes (2006) did not use any optimization method to maximize the recovery, using three WAG cycles, 1:1 WAG ratio, BHP constants and 100% of voidage replacement (VREP) as constant parameters. You et al. (2020) developed a robust computational framework that couples artificial neural networks (ANN) and multi-objective optimization in CO 2 -EOR recovery. They used multiple-objective optimization to maximize oil recovery, CO 2 storage volume and project NPV. The authors concluded that this multi-objective optimization could provide a significant insight into the decision-making process of the CO 2 -EOR project. They also failed to consider the impact of physical phenomena and main operational parameters in the optimization process, such as the WAG ratio and cycle. In none of the reviewed articles was the reinjection of the CO 2 produced by the reservoir evaluated. Therefore, the development of a methodology that is efficient in optimizing CO 2 reinjection in WAG processes in carbonates is an important gap in the literature.
The WAG injection recovery method involves more complexity due to the occurrence of the relative permeability hysteresis caused by the injection alternation (imbibition and drainage processes) that occurs during the recovery method. Thus, the compositional simulation of a WAG injection becomes more complex, as they affect the capillary pressures and relative permeabilities in the two and three-phase systems; also, other phenomena are involved, such as solubility and diffusion. The current knowledge involved in the threephase flow is limited, and quantifying and predicting the results of these processes is therefore difficult. Measuring the relative permeability is very difficult, costly and timeconsuming. Thus, many correlations have been proposed to calculate the relative permeability in the three-phase system from available biphasic data. Phenomena such as solubility also have relevant roles, are poorly evaluated in the WAG injection and are often ignored. Thus, using a compositional simulator, we aim to adequately represent the multiphase flow and the mass transfer of the gas phase components to the oil phase and vice versa. Wang et al. (2017) performed the analysis of permeability reduction due to asphaltene precipitation and solubility. Some articles have studied only the three-phase relative permeability and hysteresis (Shahverdi et al. 2011;Spiteri and Juanes 2006), while other articles have only evaluated the solubility effects of CO 2 due to altered salinity in the water injected (Kulkarni and Rao 2005;Teklu et al. 2016). However, in the case of the WAG model, it is not possible to determine the effect of capillary pressure. Brown et al. (2013) have developed algorithms to calculate three-phase relative permeability and capillary pressure and thus to include the effects of gas entrapment and relative permeability hysteresis. Few articles on WAG considered the occurrence of physical phenomena in the recovery process.
It is fundamental to model the fluids and to adjust the state equations to study the optimal number of pseudo-components in the compositional model, to evaluate the influence of rock wettability (hysteresis in WAG) and the solubility of CO 2 in water. This type of injection was also strongly influenced by rock type, injection strategy, gas miscibility and well spacing (Christensen et al. 1998).
This article aims to develop an optimization framework to understand the advantages and disadvantages of recovery in carbonate reservoirs, focusing on the water alternated with CO 2 injection. For this, we employed the fast genetic algorithm to optimize the main parameters related with this recovery method and compositional simulator for modeling the physical phenomena (hysteresis and solubility) and reinjection of the CO 2 produced by the reservoir.

Methodology
The methodology was developed to provide the modeling to evaluate the CO 2 -WAG recovery, making the analyses more realistic considering: carbonate reservoir modeling, PVT handling, physical phenomena involved and reinjection of the CO 2 produced, in order to maximize the NPV through global optimization, considering the costs in the process. The flowchart of the general methodology is shown in Fig. 1.

Carbonate reservoir model
The geological model was elaborated by Mello et al. (2013) and represents a typical region of a carbonate reservoir with grainstone facies. This model was built using RMS ® software. It was elaborated considering the relation between the petrophysical properties (porosity and permeability) and interparticle porosity relation (Lucia 2002). In this model, porosity ranges from 6.8 to 18.7% with a mean of 11.8% and a wide permeability range (30 to 2233 mD) with a mean of 426 mD were used. The transform between permeability and interparticle porosity can be defined for each of the three petrophysical classes. Reduced major axis (RMA) transforms calculated based on data presented by Lucia (2002) for petrophysical class 3 (dolostones) are given by the equation: where k is the permeability in mD and ∅ ip is the porosity as a fraction. The relation between the vertical and horizontal permeabilities is 0.1 (Lucia 2002).

PVT handling
PVT data published by Moortgat et al. (2010) were used herein. For handling PVT data, the method of Scanavini

Physical phenomena modeling
Results from the literature have shown that ignoring the physical phenomena that occur in WAG recovery may over or underestimate the results, leading to inconsistent results and conclusions regarding the data observed in the production. We therefore briefly describe the models used in the modeling of relative permeability hysteresis and solubilization of CO 2 in water.

Relative permeability hysteresis
Hysteresis refers to the phenomenon of directional saturation, exhibited by the relative permeability curves, when a given phase saturation of a fluid is increased or decreased. In a two-phase system, the relative permeability of oil decreases as the water injection is performed, until the residual oil saturation is reached. At the same time, the relative permeability of water increases until a maximum value is reached, when the oil is injected until the water stops draining. This oil can flow back through the same pores that were previously emptied by the water cycle, that is, the relative permeability of oil can increase along the same path. However, the relative permeability of water presents hysteresis because the drainage and imbibition curves do not follow the same process. As a result, the new minimum irreducible water saturation value does not return to the original connate water saturation. In a multiphase flow, a typical CO 2 injection process, which includes injecting water alternately with CO 2 , causes changes in saturations during each cycle. These changes in saturation also result in changes in the relative permeability of the non-wetting and intermediate phases.
These are related to the effect that CO 2 has on the relative permeability of water after the first CO 2 injection cycle. In the same way, CO 2 is affected by the relative permeability of water.
This work used the model of Larsen and Skauge (1998) to reproduce the behavior of relative permeability curves in the imbibition and drainage processes, valid for water-wet systems as the one used herein. This model is incorporated in the GEM compositional simulator of CMG ® and is also known as 3P-WAG model (CMG 2019). The main feature of the model is the reduction in gas mobility with the increase in mobile water saturation. Figure 2 shows the hysteresis of the relative permeability of gas in two cycles of water alternated with gas injection. We can see a significant reduction in the relative permeability of gas from the first to the second process of increasing gas saturation.   (Larsen and Skauge 1998) In this model, the gas phase (non-wetting phase) hysteresis model follows the theory of Land (1968) and Carlson (1981). The water phase (wetting phase) model interpolates between two-phase and three-phase relative permeability curves, whereby the three-phase water relative permeability is interpreted as the relative permeability after gas flooding. The final element of the model is the reduction in the minimal oil saturation (S om ) used in Stone's first model for three-phase oil relative permeability. For the non-wetting phase (gas), consider a typical drainage process (increasing gas saturation) reaching a maximum gas saturation (S gm ) followed by an imbibition process (decreasing gas saturation) leading to a trapped gas saturation (S gr ). The trapped gas saturation is given by Eq. 2: where C is Land's parameter, calculated to be consistent with S gcrit and the maximum S g . S gcrit is the critical gas saturation.
The gas relative permeability on the drainage to imbibition scanning curve is given by: The free gas saturation (S gf ) is calculated from Land's equation: If the gas saturation once again decreases, then a secondary drainage curve will follow. The secondary drainage curves are calculated using the following equation: In this equation, K drain rg is the relative permeability calculated for the secondary drainage, K input rg is the input relative permeability at S g , K input rg S start g is the input relative permeability at the gas saturation at the start of the secondary drainage curve, S wcon is the connate water saturation, S start w is the water saturation at the start of the secondary drainage curve, K imb rg S start g is the relative permeability at the start of the secondary drainage process (that is the K rg at the end of the imbibition curve), and α is the reduction exponent input.
The term raised to exponent α in Eq. (5) accounts for reduction in the gas phase relative permeability in the presence of mobile water. Equation (5) implies that the gas phase relative permeability is a function of the history of both the gas and water phase saturations. Further imbibition curves are handled by transforming the saturation using Land's Eq. (4) with the trapped gas saturation S gr defined as the maximum trapped gas over all the WAG cycles. The transformed saturation is then verified on the secondary drainage curve. If Stone's first model for the three-phase oil relative permeability model is used, the minimal residual oil saturation S om may be modified to account for the trapped gas saturation: where "a" is the input by the user in the compositional simulator (CMG 2019). It has been observed that water mobility following a gas flood is significantly reduced relative to its mobility in the original oil-water system. In addition to the usual twophase relative permeability curve (oil-water flow), another curve for a three-phase flow scenario, which represents the water relative permeability following a gas flood, is required.
For an imbibition process (S w increasing), the relative permeability is interpolated between the two-and threephase curves as follows: In this equation, K imb rw is the calculated imbibition relative permeability, K W2 rw is the relative permeability at S w read from the two-phase curve, K W3 rw is the three-phase relative permeability at S w , Sg max is the maximum attainable gas saturation (1 − S wcon − S oirg ), S I g is the gas saturation at the start of the increasing water saturation (imbibition) process, S wcon is the connate water saturation, and S oirg is the irreducible oil.
A subsequent drainage relative permeability will be calculated by interpolation between the imbibition curve and either the three-phase curve or the two-phase curve, depending on the gas saturation.
Thus, for this model three constants are required: constant α that assumes a constant value for the case of the rock to be water wet (as the model employed herein); constant a also depends on the rock wettability; and Sgr max , which is the maximum residual gas saturation (CMG 2019).
Parameter a was assumed to be equal to the work by Larsen and Skauge (1998), and the other two parameters were obtained from the work by Laboissière et al. (2013). The three-phase water relative permeability was assumed to be 25% of the biphasic, an experimental observation due to Rogers et al. (2000), because of the absence of isoperm data. Thus, the values assumed were: α = 4.9, Sgr max = 0.22 e a = 1.1.

Aqueous solubility of CO 2
Data from the literature of coefficients of CO 2 aqueous solubilization and light hydrocarbons in the water formation were acquired. If the temperature is above 200 °C, for example, the solubility may be as high as 18% of the mass fraction. Even so, it is very common not to even consider by Henry's Law the aqueous solubility of these components in compositional simulation studies. For estimating Henry's constant (dissolution) of the CO 2 in the reservoir brine, the parameter adjustment found in Duan and Sun (2003) and Sander (1999) was calibrated using the Winprop software of CMG ® .
CO 2 was determined to have a solubility of 0.799627 mol/ kg at a temperature of 58.2 °C (the same as the PVT data used), 6400 psi (initial pressure of the reservoir) and salinity of 200,000 ppm (solution of 3.42 molal).
For determining the Henry constant, we used the Sander relation: For the initial estimation of the volume of infinite dilution of CO 2 in the brine, Enick's relation (Enick and Klara 1990) was used: For the calculations, we considered that the salinity of the water formation and the water injection was 200,000 ppm (Lake 2007). For the solubilization of supercritical compounds, such as carbon dioxide, methane, ethane and propane in brine, Henry's Law modified by Harvey (1996) was used. The parameters were taken from Duan and Sun (2003), Harvey (1996) and Haynes (2014) and adjusted in the Winprop software of CMG ® by means of a flash liberation and regression. The values found are shown in Table 1.

CO 2 recycling
The CO 2 produced to be reinjected into the reservoir was recycled using keywords of the GEM software of CMG ® . The recycling option in GEM allows mimicking certain processes in surface facilities, such as the stripping of certain components and the addition of a makeup stream. It defines the pressure and temperature conditions of the separators, the wells of which participate in the recycling, 1799.36 − 17.8218 * T + 0.06599297 * T 2 − 1.05786 * 10 −4 T 3 + 6.2275 * 10 −8 T 4 10 3 l mol as well as the fraction of CO 2 produced that will be reinjected (CMG 2019).

Selection of main parameters
This section presents the optimization parameters selected to evaluate the CO 2 -WAG recovery. These parameters were chosen because they are the parameters that most impact the NPV maximization: the WAG cycle duration (period between the beginning of the water injection and the end of the gas injection), WAG ratio (ratio between water and CO 2 injection rates), maximum oil rate production, water and gas injection rates, limits of water cut (WCUT) and gas-oil ratio (GOR).

Adjustment of numerical control
The numerical adjustment was made to minimize three main components: the processing time, the percentage of error in the material balance and the percentage of failures in the simulation. For this, we used maximum timestep control, showing that the timestep size could have significant impact on the simulator performance. Normal variation per timestep was also used, applying maximum change in specific variables: pressure, saturation and global composition. The values were reached through manual tuning in order to improve the numerical performance. The WAG injections were only able to be completed until the end time using AIM (adaptive implicit method). Parallel processing was also used to reduce the computational time, specifying the number of parallel threads to be used in each simulation.

Optimization process
For the optimization process, we employed a global optimization method called fast genetic algorithm (FGA) which is more efficient than basic genetic algorithms. This Infinite dilution coefficient (L/ mol) 3.18 × 10 −2 4.8 × 10 −2 6.8 x 10 −2 algorithm was used to optimize all the cases (described in the next section).

Fast genetic algorithm (FGA)
This optimization method was successfully applied in the optimization processes with inflow control valves in the intelligent wells (Sampaio et al. 2015a), closed-loop optimization (Sampaio et al. 2015b) and in the well rates optimization under production constraints (Sampaio et al. 2019).
In this work, this algorithm was used in the performance of CO 2 -WAG recovery. Genetic algorithms (GA) are an extremely efficient search technique in scanning the solution space and in finding solutions close to the optimal solution, being indicated in problems especially difficult (the so-called NP-Complete problems), given the high number of variables. These algorithms are based on the simulation of the evolution of species through selection, mutation and reproduction (Goldberg 1989, Koza 1992, Mitchell 1996. It uses a population of structures called chromosomes or individuals, which are then subjected to genetic operators such as recombination and mutation, among others, that simulate reproduction and genetic mutation, respectively. Each individual is submitted to an evaluation that determines its quality as a solution to the problem. This evaluation determines which chromosomes will apply genetic operators to generate offspring. The performance of a GA depends heavily on which operators are used in the algorithm. There are those that are easier to implement computationally, that make up the so-called simple GA (SGA), but that are less efficient in finding the global maximum (Mitchell 1996). Among these simpler operators are: single-point crossover, mutation and crossover with static rates, method of fitness selection by roulette wheel and evaluation with direct application of the objective function. Single-point crossover is the simplest form: a single crossover position is chosen at random and the parts of the two parents after the crossover position are exchanged to form two offspring. Static rates for crossover and mutation are also present in the SGA. These rates remain fixed throughout the execution of the algorithm, but have different characteristics at the beginning and end. In the selection known as roulette wheel, a proportion of the wheel is assigned to each of the possible selections based on their fitness value. This could be achieved by dividing the fitness of a selection by the total fitness of all the selections, thereby normalizing them to 1. Then, a random selection is made similarly to the way the roulette wheel is rotated. Finally, the simple evaluation can be made using the objective function directly in problem to be solved.
As this work aims at the good performance of the GA, the operators that present the best efficiency in the convergence of the best individuals used are presented below. The algorithm used, called the fast genetic algorithm (FGA), uses advanced operators: uniform crossover, mutation and crossover with deterministic rates, selection of parents by uniform stochastic sampling and modification of the evaluation function by Sigma Scaling. A brief explanation of each of these operators is provided as follows.
In the uniform crossover, a mask of random binary numbers is used and applied to the two individuals selected for the crossing. Where number zero appears on the mask, the gene for each individual is preserved, that is, there is no exchange of genes. Where number one is on the mask, there is an exchange of genes between individuals in that position. As this type of crossing has a greater capacity to combine schemes than those of a single point, whether large or small, its performance is eventually superior and tends to obtain the best results. Hu and Di Paolo (2007) showed the efficiency gain of the genetic algorithm when using the uniform crossover for an air traffic problem.
Deterministic rates for mutation and crossover can modify these parameters depending on the algorithm execution time. Using high crossover rates with low mutation rates alongside large population size refers to the diversity in the large population; however, in the small population size, the mutation rates become larger in order to provide diversity and to increase the search quality, bringing diversity to the population using crossover rates and mutation rates to increase the efficiency of the GA (Hassanat et al. 2019).
In the uniform stochastic sampling, the individuals are mapped to contiguous segments of a line, such that each individual segment is equal in size to its fitness exactly as in the roulette wheel selection. Equally spaced pointers are placed over the line in the same number as the individuals to be selected. Considering N the number of individuals to be selected, then the distance between the pointers is 1/N and the position of the first pointer is given by a randomly generated number in the range [0, 1/N]. Thus, the individuals with the highest evaluation will have a greater chance of reproducing, as they will be represented by larger line segments, without totally excluding the possibility of reproduction of individuals with lower evaluation, although with less probability of occurring, just as occurs in nature, improving the selection (Mitchell 1996).
Sigma scaling is a variant of linear scaling whereby an individual's fitness is scaled according to its deviation from the mean fitness of the population, measured in standard deviations. Diwaker and Dhull (2011) published an article specifically to analyze the effects of sigma scaling on GA performance. They concluded that it prevents the GA from premature convergence, maintains diversity in the population and always improves the performance of GA.
Thus, by replacing each simple operator by an advanced operator that improves the efficiency at each stage of the algorithm, we can ensure that replacing the SGA with the FGA 1 3 will make the search for the optimal solution more efficient. Table 2 presents a summary of the SGA operators and the changes in the FGA for better understanding the algorithms.
To solve the problem proposed herein, a program was coupled to the commercial reservoir simulator. The genes in this study are the values of parameters previously mentioned. Thus, the methodology used can be considered an optimal strategy of the WAG injection at different times over the exploitation of the field to maximize the NPV.

Case studies
This section presents the case studies in which the methodology will be applied and the reservoir model, with one producer and one injector, in order to also analyze the influence between producer-injector.

Reservoir model
The simulation model used is shown in Fig. 3; the rock and fluid properties are based on the Brazilian pre-salt field, a model previously used by Mello (2015). For the petrophysical data of the model, only grainstone facies were considered. The dimensions of the grid are of 20 × 20 × 7 blocks, each block being 200ft × 200ft × 30ft in size. The grid used in the models was Cartesian. The oil used was light oil with 27 • API, bubble pressure of 5581 psi and initial water saturation of 13.5%. The initial pressure of the field was 6400 psi and the minimum miscibility pressure was estimated at 4400 psi, the maximum MMP calculated by GlasØ (1985).

Well configurations
One producer and one injector were used, in a configuration of a quarter of five spots, all vertical, with 200ft in length. The producer and injector wells were completed in all the layers of the model. The operational restrictions of the wells are listed in Table 3.
These values remained fixed throughout the optimization process. An operating condition, voidage replacement (VREP), was also used to limit the maximum amount of water injected to the total volume of fluid produced, so as to avoid the high pressurization of the reservoir.

Optimization parameters
For optimizing the WAG injection, the following parameters were used: • Limit water cut (WCUT lim ): maximum water cut to reach the maximum NPV. These values assumed 0.1 to 1.0; • Gas-oil ratio (GOR): maximum value of gas-oil ratio; • Maximum oil produced (STO): maximum oil production rate; • Maximum water injection (STW): maximum water injection rate; • Maximum gas injection (STG): maximum gas injection rate. • Only for case 5 is there an additional parameter: • Fraction of CO 2 reinjection (recycling): fraction between 0.1 and 1. This value is the fraction of CO 2 produced that will be reinjected in the reservoir;  Fig. 3 Model employed, representing a region between the producer and the injector of a synthetic model of a Brazilian pre-salt field The ranges of the values of each variable are shown in Table 4. As can be seen, the FGA is composed of variables with two ranges, one from 0.1 to 1 and the other from 3000 to 12,000. This was possible by dividing the population of the FGA into two subpopulations, each with different intervals, that evolve in parallel and are used in the same evaluation. The crossover and mutation operators had to be adapted to respect these intervals.

Fast genetic algorithm (FGA)
Table 5 presents the FGA parameters used in each control variable. The stopping criterion used in this optimization was established when 15 generations occurred without increasing the maximum NPV. The population size was defined by tests made previously. The size was six times the number of control variables. The rates of mutation and crossover have values varying linearly along the execution of the algorithm; mutation rate begins with 0.1, increasing until reaching 0.9. The crossover rate had an inverse behavior.
Although GAs are indicated for especially difficult problems, with a high number of variables, the number of variables herein was reduced. This was done aiming at the next stage, which is the application in a complete reservoir model where we have not only one producer-injector pair, but several pairs. This results in a high number of variables, where the FGA has better computational efficiency and has its application recommended.

Economic scenario
The values for the probable scenario are shown in Table 6. The economic base model is selected following a simplified Brazilian fiscal regime, assuming: 25% of the corporate tax rate, 10% of the royalties, 9% of the social benefit contributions and 10-year linear depreciation. Also presented are data on the CO 2 production costs in the reservoir and the cost of reinjection (NETL 2017). In all the cases studied, the investments were not considered.

Cases
To carry out this work, five cases were created. Case 1 was the base case, without modeling phenomena and without the reinjection of CO 2 produced. Case 2 added the modeling of the relative permeability hysteresis to case 1. Hence, case 2 was created to analyze the effects of hysteresis in relative permeability in relation to case 1, without modeling. Case 3 added the modeling of CO 2 solubility to the water in case 1. This case was created to analyze the effects of aqueous solubility in relation to case 1. Case 4 added the modeling of relative permeability hysteresis and aqueous solubility to case 1. This was done to jointly analyze the effects of hysteresis of relative permeability and CO 2 solubility in water. Finally, case 5 added relative permeability hysteresis, aqueous solubility and CO 2 recycling to case 1. In this case, we can analyze the effects of the modeled phenomena together with the reinjection of the CO 2 produced. The modeling of each case is summarized in Table 7.
For each case, we created four options. These options had different WAG cycle values. The first option has a 6-month   Table 8. These options were created to find the best WAG cycle for each case.
As can be seen, we have 5 cases, each with 4 options, totalizing 20 scenarios to be equally optimized. All the cases were optimized with the parameters listed in "Optimization parameters" section. The only difference between cases in the optimization is the inclusion of the parameter that defines the fraction of CO 2 to be reinjected in case 5. All the other cases used the same parameters in the optimization process. Thus, cases 1 to 4 had five parameters and only case 5 has six optimization parameters. Table 9 provides the results of the optimization process; case 1 shows that the best option was A, with a 6-month WAG cycle. In this option, we can verify the greater oil recovery obtained. However, this increase in oil production was accompanied by higher water production and injection, while lower CO 2 injection was obtained. This option can thus achieve the maximum NPV. In our comparisons, as explained earlier, this case will be considered the base case to establish relations between all the cases. Figure 4 provides the graphs for the water and CO 2 injection rate curves, cumulative production and water injection for case 1. There is alternation between the water and CO 2 injections, the injection of water being more expressive than CO 2 . In fact, the best WAG ratio for this case was 14.67. This graph also shows 49 cycles of water alternating with CO 2 over 30 years. Relative permeability hysteresis + aqueous solubility of CO 2 5

Results and discussions
Physical phenomena and CO 2 recycling   . 4 Graphs of (a) water and CO 2 injection rate curves and (b) cumulative productions and water injection for WAG recovery in case 1 For the results of case 2, Table 10 shows that even with hysteresis modeling, option A was also the best option. The oil production and NPV are observed to increase in relation to case 1, showing that the modeling of the hysteresis phenomena presented a favorable result in WAG recovery. In fact, the incorporation of physical phenomena, especially relative permeability hysteresis, favors the oil recovery factor (Spiteri and Juanes 2006;Ghomian 2008). This increase in oil recovery is caused by a reduction in the residual oil saturation by gas trapping, forcing the water flow to nonswept areas. CO 2 production, water production and injection decrease in relation to case 1. Note that the injection of CO 2 increased four times in relation to the base case. This occurred due to one of the most common problems associated with changes in relative permeability during a WAG process, which is the loss of injectivity (Rogers et al. 2000). Therefore, it becomes necessary to raise the injection to compensate this loss.
In Fig. 5, the graphs show the curves for case 2. In this case, the water injection rate is more expressive than CO 2 , but with a smaller proportion than in the previous case, with the best WAG ratio equal to 3.34. The curves of the oil production and water production and injection are compared with base case.
For case 3, with aqueous solubility of CO 2 , as shown in Table 11, the best option was A again. As observed, this case increases the NPV more than the other cases. This can also be seen in the lower value of the WAG ratio found. Due to the solubility of CO 2 in the water, in this case there is a three times greater CO 2 injection than in the base case. This can be explained by the fact that the dissolution of CO 2 in the water can prevent a part of the CO 2 injected from coming into contact with the oil, which can be compensated by increasing the CO 2 injection (Enick and Klara 1992).
In Fig. 6, the graphs show the results for case 3. The WAG ratio was 5.26, lower than the base case and higher than the previous case. We can also see that cumulative water production and injection are higher than in the base case, but the oil production was anticipated in relation to the base case, resulting in higher NPV than the previous cases.
For case 4, with the joint modeling of both physical phenomena, as shown in Table 12, the best option was A. In this option, the water production and injection and CO 2 production decrease in relation to the base case, increasing the NPV. Oil production was practically the same as in the base case, with the difference of the anticipation of production, as observed in the previous case. In this case, we can observe a mixture of the two effects previously studied.

Fig. 5
Graphs of (a) water and CO 2 injection rate curves and (b) cumulative production and water injection for WAG recovery in case 2 in comparison with case 1 Figure 7 presents the graphs for alternated injections and comparison of cumulative productions and injection between case 4 and the base case. Note the reduction in water production and injection at the end of production. In this case, the best WAG ratio was 3.23.
Finally, for case 5, with the joint modeling of the physical phenomena and reinjection of the CO 2 produced, as shown in Table 13, the best option was A again, with the lowest WAG cycle, lasting 6 months. This was the case with the highest NPV among the all cases analyzed. The oil production increases together with the little increase in water production and injection. The CO 2 production also decreases, increasing the NPV, while CO 2 injection was a little higher than the base case. The oil production increased 3.9%, and the NPV increased 8.8% in relation to the base case. Figure 8 presents the graphs for water and CO 2 injection rate curves, besides the cumulative production and injection in case 5. The WAG ratio for this case was 12.93. We can highlight that the cumulative oil production increases in relation to the base case. We can also conclude that the CO 2 reinjection had a fundamental role in this case, since CO 2 production was the lowest of all the cases, generating the highest oil recovery and resulting in the highest NPV. Table 14 reproduces the best solutions of each case to facilitate comparison. Case 5, with physical phenomena and CO 2 reinjection modeling, besides being the most realistic case, was the one that provided the best results by increasing the oil production and the NPV in relation to the base case. It can also be observed that the increase in CO 2 injections with the modeling of physical phenomena can be significantly  . 6 Graphs of (a) water and CO 2 injection rate curves and (b) cumulative production and injection for WAG recovery in case 3 in comparison with the base case reduced with CO 2 reinjection modeling. The last column highlights the difference in the NPV of each case in relation to the base case (case1). Case 5 provided a gain of about 10 million dollars over the base case. Note that the computational cost among the six cases did not vary much (around 720 s) requiring only an adequate adjustment of the numerical control for each case. As the optimization process required several simulations, the total time for the cases remained very close. An additional cost occurred in case 6 due to an extra variable in the optimization. Fig. 7 Graphs of (a) water and CO 2 injection rate curves and (b) cumulative production and injection for WAG recovery in case 4 in comparison with the base case  . 8 Graphs of (a) water and CO 2 injection rate curves and (b) cumulative production and injection for WAG recovery in case 5 in comparison with base case Table 15 shows the optimized values for each case in option A. These values of the parameters generated the results in Table 14. The best value of the fraction of CO 2 produced and reinjected in the reservoir was 0.57, that is, 57% of the CO 2 produced was reinjected into the reservoir to maximize NPV. Figure 9a depicts the behavior of the WAG ratio throughout the cases, showing that the modeling of the phenomena demanded the increase in the CO 2 injection in relation to the water injection. Figure 9b shows the evolution of the maximum NPV for the base case and case 5 over the generations of the genetic algorithm. Figure 10 shows the results of the sensitivity analysis with all the parameters used, along with the influence of each parameter on the NPV and the ranges of values that influence the results, when analyzed individually. This graph was obtained by analyzing one parameter at a time (OPAAT Analysis) using the CMOST software of CMG ® in case 6 option A. As observed, the maximum water injection rate was the parameter that most impacted the WAG recovery. The other parameters that had less influence on NPV were maximum oil rate production and limit of water cut (WCUT). The parameters gas injection rates and gas-oil ratio (GOR) had almost no effect on the results, probably because of the low cost of CO 2 . It is worth mentioning that  . 9 (a) Behavior of WAG ratio in all the cases and (b) evolution of NPV for cases 1 and 5 during the execution of the FGA the impact of the WAG cycle and WAG ratio were previously measured in the case optimizations, evidencing the great impact on the CO 2 -WAG recovery. Figure 11a shows the evolution of the average pressure of reservoir over the production lifetime. It can be seen that the pressure was above the minimum miscibility pressure (MMP) of 4400 psi, which guarantees the miscibility of the WAG recovery, showing that the process studied herein was of the CO 2 -MWAG (miscible CO 2 -WAG) type. Water was injected to pressurize the reservoir until reaching the MMP to enhance the macroscopic sweep efficiency. After the water injection, CO 2 was used to improve microscopic displacement efficiency, forming a miscible front with reservoir fluids. Figure 11b depicts the impact of the phenomena and CO 2 reinjection on oil recovery. Case 6 presents the greatest increase in recovery in relation to the base case, about 3.4%, reaching the value of 70.7%. This value is significant, since the maximized objective function was the NPV and not the recovery factor.

Conclusions
The results from modeling the physical phenomena and cyclic reinjection in a CO 2 -WAG process showed that: • It is not enough to analyze the increase in oil recovery in WAG methods, since besides the water and CO 2 productions, we have their respective injections, presenting costs that must be reduced to maximize the NPV; • The absence of modeling the physical phenomena can cause significant differences in the results; • As previously observed by other authors, the modeling of relative permeability hysteresis showed to favor oil recovery, causing loss of injectivity, which can increase injection costs and reduce the benefits of increased recovery; • The modeling of the solubility of CO 2 in water can raise costs due to the need to increase the injection of CO 2 dissolved in water. However, this phenomenon showed to be able to anticipate oil production, positively reflecting in the cash flow; • In WAG recovery methods aiming at the reuse of the CO 2 produced, it is necessary to model the cyclic reinjection, which showed better results. In fact, the modeling of physical phenomena increases by three or four times the CO 2 injection, but the CO 2 reinjection modeling can decrease significantly, maximizing the NPV; • The results show that the joint modeling of the physical phenomena can have an incremental consequence to the recovery, around 4% in a producer-injector pair. In turn, the modeling of CO 2 separation, followed by reinjection, provided the highest NPV among all cases, increasing about 9% in relation to the base case.