# Prediction and Optimization of Stability Parameters of Borehole Sensor for Deep Water Drilling Based on Genetic Algorithm

Authors: Jing Huang; Qian Xia; Rao Cai; Kunling Zhou; Zhiquan Ren; Huachi Yan; Mohammad Asif
Journal: Journal of Sensors
 (2022)

---

## Abstract

In order to study the prediction and optimization of borehole stability parameters in deepwater drilling based on genetic algorithm. First, a genetic hybrid algorithm based on pattern search is proposed. Then, based on the adaptive genetic algorithm, the evolutionary population is searched for patterns, which makes the hybrid algorithm not only has a strong global search ability but also improves the local optimization accuracy. Finally, the unit footage cost in the drilling process is taken as the objective function, and the algorithm is verified by taking the drilling in Karamay area as an example. The calculation results show that if the bit wear reaches 0.8-0.9 and then the bit is pulled out, the utilization rate of the bit can be increased, the design efficiency and accuracy can be improved, and the drilling cost can be reduced. The wear amount of the optimized bit is higher than that of the actual bit. Increasing the utilization rate of the bit can reduce the cost of drilling meters to a certain extent and improve the economic benefits of drilling. The objective function and constraint conditions for the optimization of drilling parameters are determined, and the algorithm is verified with the drilling data of Karamay Oilfield. The results show that the algorithm improves the stability and speed of iterative convergence and improves the reliability of data analysis results. Based on the regional three-dimensional formation rock parameter data volume, the optimization method can be used to optimize the drilling parameters before drilling and provide a basis for formulating the drilling design scheme.


---

## Body

## 1. Introduction

Drilling costs are affected and restricted by many factors. The optimization design of drilling parameters is to establish the objective function and model of drilling cost according to the influence law of different parameters on drilling cost and taking footage cost as the standard to measure the technical and economic effect and use the optimization method to select drilling parameters, as shown in Figure1, so as to make the drilling process reach the optimal technical and economic effect [1]. The traditional method is to correct the Younger model with an empirical formula, which has good analytical performance and a high coincidence rate with the actual drilling situation. In recent years, some scholars have proposed the ROP model and real-time optimization objective function of drilling parameters based on the drillability representation, but the application results are not ideal. This is a nonlinear optimization combination problem. Currently, the commonly used solving methods mainly include the classic multivariate function extremum method and the pattern search method (PSA). The mathematical derivation and calculation process of function extreme value method is complex, which requires manual intervention, and the design process has long cycle and low efficiency. The pattern search method is essentially a natural evolutionary selection algorithm, which is the basis of genetic algorithms. The penalty function method is used to solve the model through population optimization search, which has great advantages in solving such nonlinear optimization problems. The combination model of genetic algorithm and pattern search is used to study the optimization method of drilling parameters. Combined with the strong global search ability of genetic algorithm and the characteristics of high local optimization accuracy of the pattern search method, the optimal drilling parameter combination is found. Compared with the conventional design method of trial calculations and optimization schemes based on experience, the new method is more efficient and can directly determine the optimal scheme under given conditions [2, 3].Figure 1
Schematic diagram of drilling gravity.The combined model of genetic algorithm and pattern search and the optimal optimization parameters are studied. Compared with the conventional design method of empirical trial calculation and optimization scheme, the new method is more efficient and can directly determine the optimal scheme under a given condition.


## 2. Literature Review

Cao et al. used the linear elastic constitutive model and Mohr-Coulomb strength criterion to analyze the wellbore stability of the deep-water Medusa oilfield in the Gulf of Mexico and applied the calculation results to field operations [4]. Due to the lack of sufficient geological and logging data for deep-water drilling, it usually results in deviations in the calculation results of the safe drilling fluid density window. When studying the wellbore stability of bijupira and salema oilfield in deep water in Brazil, Zhang and others analyzed the calculation results by using the method of quantitative risk assessment. The results show that the prediction accuracy of in situ stress and formation strength has the greatest impact on the calculation results of drilling fluid density window [5]. Through the analysis of foreign deep-water wellbore stability research (Figure 2). A deep water drilling water pipe system and vibration active control system including a sensor, actuator, signal processing module control module for monitoring longitudinal and lateral vibration of the drain water pipe system. Zhang et al. found that although deep-water formations have their own characteristics compared with land and shallow-water formations, it is the same in wellbore stability research methods [6]. Zheng et al. studied the influence of water depth on the fracture pressure and found that the fracture pressure of the deep-water wellbore is relatively close to the pressure of the overlying strata, but no specific model [7]. Han et al. used the established model to study the wellbore stability of a deepwater gas field in the South China Sea. The results show that the low overburden pressure and low fracture pressure of the deepwater formation are the main factors affecting the safety of deepwater drilling. [8]. Mousavi et al. established a special safe drilling fluid density window calculation model for the shallow deep water formation in a nearly plastic state. Conventional models can be used to calculate deep strata [9].Figure 2
Deep water drilling system control system.


## 3. Optimization Model of Drilling Parameters

The purpose of drilling parameter optimization is to find the drilling parameter coordination to achieve the best technical and economic effect in the drilling process. Therefore, it is necessary to establish the optimal drilling objective function, which can reflect the influence law of various parameters on the drilling process and can also measure the technical and economic effects of drilling. The parameter combination that satisfies the extreme conditions of the objective function is the optimal drilling parameter combination [10].
(1)
Objective functionThere are many functions to measure the overall technical and economic indicators of the drilling process. More commonly used and intuitive is to take the drilling unit footage cost as the evaluation index of drilling parameter optimization. The expression is:(1)Cpm=Cb+Crt+ttH.In the formula,Cr is the drilling rig operating fee, yuan/h, t is the drilling time, tt is the tripping and single connection time, h, and H is the drill footage.Formula (1) analyzes and solves the problem while only considering the cost of the drill bit and the operating cost of the drilling rig, without the cost of drilling fluid and drill tool assembly. The modified F. S. Young mode drilling rate equation is as follows:
(2)vpc=KCPCHW−Mnλ11+C2h,where vpc is the ROP, m/h, W, M is the weight-on-bit and threshold weight-on-bit, respectively, kN, n is the speed, r/min, k is the formation drillability coefficient, CpCH are the differential pressure influence coefficient and the hydraulic purification coefficient, respectively, λ is rotation speed index, C2 is the wear coefficient of the drill bit teeth, and h is the tooth wear, 0≤h≤1.Formula (2) can be converted to the relationship between drill working time and drill footage:
(3)dH=KCPCHW−Mnλ11+C2hdt.The expression of the drill tooth wear equation is:(4)dhdt=Afa1n+a2n3Z2−Z1W1+C1h.In the formula,Af is the formation abrasiveness coefficient, a1, a2 is the rotational speed influence coefficient, which is determined by the bit type, Z1, Z2 is the weight-on-bit influence coefficient, which is related to the diameter of the drill bit, and C1 is the tooth wear slowdown coefficient [11–13].


### 3.1. Improved Genetic Function

The sensor genetic algorithm is based on Darwin’s natural selection theory as its basic idea, a computational model that simulates the process of biological genetics and evolution. The basic theoretical idea of genetic algorithm is to randomly generate a series of solutions to be selected, namely, chromosomes, to form a population, where each individual represents a set of solutions, represented by a string structure composed of a set of genes (gene, chromosome value). Evaluate individuals through a certain standard, retain good performance, eliminate poor performance, and allow each group of solutions to generate new solution sets through information crossover or mutation, and then perform evaluation and optimization, and repeat until solutions that meet the requirements of the standard are obtained. Genetic algorithms include 3 basic operations such as selection, crossover, and mutation, which are also called genetic operators. The genetic algorithm has a relatively strong global search ability and can solve the global optimization problem of the objective function, but the genetic algorithm has poor precision for local optimization. If a single-genetic algorithm is used, it is difficult to obtain the optimal parameter combination. The genetic algorithm includes three basic operations: selection, crossover, and mutation, which are also called genetic operators. If a single-genetic algorithm is used, it is difficult to obtain the optimal parameter combination. The pattern search method has good local optimization accuracy, and genetic algorithm has good scalability. Through the mixed use of these two algorithms, it can learn from each other and optimize the parameter combination with higher accuracy.(1)
Principle of pattern search methodThe pattern search method is a derivative free optimization (DFO) method. Generally, the search is performed in a loop along the coordinate direction set, and it is verified whether the direction is a descending direction, to obtain next iteration point.(2)
Improved genetic algorithm modelThe pattern search method is a very efficient method without derivative free optimization (DFO) and does not need to calculate the search direction, while the genetic algorithm (GA) itself is also a derivative free optimization method used to solve optimization problems, but also have the strong local optimization ability of pattern search method, and the hybrid algorithm is still a DFO method [14–17].


### 3.2. Optimization of Drilling Parameters Based on Improved Genetic Algorithm

In view of the drilling parameter optimization problem to be solved, the sensor real number encoding is selected. The encoding method does not need to convert the real number value into binary and other genotype string structure data, but directly performs the operation of each operator on the phenotype data. Each chromosome is a real vector [18].Calculate fitness values for individual chromosomes in the population, and select excellent individuals to enter the next generation population according to the selection probability. The higher the individual fitness value, the greater the probability of being selected. Choosing the roulette method for selection operation is a selection strategy based on the fitness ratio. The probability of an individuali being selected is:
(5)pi=Fi∑j=1NFj.In the formula, Fi is the fitness value of the individual i and N is the number of individuals in the population.
(3)
Crossover operationAfter the selection, the individuals in the new population are paired, and one or a certain gene segment is cross-exchanged, so that the excellent genes of the parent can be retained and inherited to the next generation. Use real numbers to encode individuals, and use real number crossover method for crossover operation, then the crossover operation method for thek chromosome ak and the l chromosome al at the position j is:
(6)akj=akj1−b+aljb.(4)
Pattern search optimizationSet an algebraic counter. When the genetic algorithm completes a fixed number of iterations, it enters the pattern search process to perform local optimization [19].The pattern search method is initialized, and the individual with the largest fitness value obtained by the genetic algorithm is used as the starting iteration point of the pattern search, which is:(7)R0=Xbest.And set the initial step length to be the half of the difference between the final optimal individual and the worst individual, which is:(8)δ0=Xbest−Xworst2.In the pattern search iteration process, if the step size is reduced below the convergence toleranceδtol, the search is terminated, the iteration point at this time Rk is output, and the chromosome individual encoded is substituted into the genetic algorithm population to continue the evolutionary iteration [20].


## 3.1. Improved Genetic Function

The sensor genetic algorithm is based on Darwin’s natural selection theory as its basic idea, a computational model that simulates the process of biological genetics and evolution. The basic theoretical idea of genetic algorithm is to randomly generate a series of solutions to be selected, namely, chromosomes, to form a population, where each individual represents a set of solutions, represented by a string structure composed of a set of genes (gene, chromosome value). Evaluate individuals through a certain standard, retain good performance, eliminate poor performance, and allow each group of solutions to generate new solution sets through information crossover or mutation, and then perform evaluation and optimization, and repeat until solutions that meet the requirements of the standard are obtained. Genetic algorithms include 3 basic operations such as selection, crossover, and mutation, which are also called genetic operators. The genetic algorithm has a relatively strong global search ability and can solve the global optimization problem of the objective function, but the genetic algorithm has poor precision for local optimization. If a single-genetic algorithm is used, it is difficult to obtain the optimal parameter combination. The genetic algorithm includes three basic operations: selection, crossover, and mutation, which are also called genetic operators. If a single-genetic algorithm is used, it is difficult to obtain the optimal parameter combination. The pattern search method has good local optimization accuracy, and genetic algorithm has good scalability. Through the mixed use of these two algorithms, it can learn from each other and optimize the parameter combination with higher accuracy.(1)
Principle of pattern search methodThe pattern search method is a derivative free optimization (DFO) method. Generally, the search is performed in a loop along the coordinate direction set, and it is verified whether the direction is a descending direction, to obtain next iteration point.(2)
Improved genetic algorithm modelThe pattern search method is a very efficient method without derivative free optimization (DFO) and does not need to calculate the search direction, while the genetic algorithm (GA) itself is also a derivative free optimization method used to solve optimization problems, but also have the strong local optimization ability of pattern search method, and the hybrid algorithm is still a DFO method [14–17].


## 3.2. Optimization of Drilling Parameters Based on Improved Genetic Algorithm

In view of the drilling parameter optimization problem to be solved, the sensor real number encoding is selected. The encoding method does not need to convert the real number value into binary and other genotype string structure data, but directly performs the operation of each operator on the phenotype data. Each chromosome is a real vector [18].Calculate fitness values for individual chromosomes in the population, and select excellent individuals to enter the next generation population according to the selection probability. The higher the individual fitness value, the greater the probability of being selected. Choosing the roulette method for selection operation is a selection strategy based on the fitness ratio. The probability of an individuali being selected is:
(5)pi=Fi∑j=1NFj.In the formula, Fi is the fitness value of the individual i and N is the number of individuals in the population.
(3)
Crossover operationAfter the selection, the individuals in the new population are paired, and one or a certain gene segment is cross-exchanged, so that the excellent genes of the parent can be retained and inherited to the next generation. Use real numbers to encode individuals, and use real number crossover method for crossover operation, then the crossover operation method for thek chromosome ak and the l chromosome al at the position j is:
(6)akj=akj1−b+aljb.(4)
Pattern search optimizationSet an algebraic counter. When the genetic algorithm completes a fixed number of iterations, it enters the pattern search process to perform local optimization [19].The pattern search method is initialized, and the individual with the largest fitness value obtained by the genetic algorithm is used as the starting iteration point of the pattern search, which is:(7)R0=Xbest.And set the initial step length to be the half of the difference between the final optimal individual and the worst individual, which is:(8)δ0=Xbest−Xworst2.In the pattern search iteration process, if the step size is reduced below the convergence toleranceδtol, the search is terminated, the iteration point at this time Rk is output, and the chromosome individual encoded is substituted into the genetic algorithm population to continue the evolutionary iteration [20].


## 4. Simulation Analysis

According to the mathematical model established above, the improvement measures of the adaptive genetic algorithm are introduced, and the application package is compiled for a certain example of a well drilling parameter combination to complete the optimization design task. The known parameters of this well section are formation drillability coefficientK=213×10−3, abrasiveness coefficient Af=2.28×10−3, threshold weight-on-bit Wn=10KW, speed index γ=0.168, weight-on-bit influence coefficient D2=6144, D1=11443×10−5, speed influence coefficient Q1=115, Q2=6153×10−5, drilling rig Operation fee Cr=225 yuan/h, and the tripping time tt=5.57 h.The classical extreme value method, the pattern search method, and the improved self-adaptive genetic algorithm are, respectively, applied to solve the problem, and the obtained drilling parameters are shown in Table1. From the data in the table, it can be seen that the parameter values obtained by the improved AGA algorithm are similar to those obtained by the commonly used extreme value method and the pattern search method (PSA), and the final drilling cost C is slightly lower. Therefore, the application of the improved AGA algorithm can complete the task of optimizing the design of drilling parameters. And in terms of work efficiency, it has obvious advantages compared with the extreme value method of manual solution, which is automatically completed by the algorithm program [21].Table 1
Optimization results of drilling parameters.
ProjectCHCPhf/pn/r⋅min−1W/kNClassical extremum method1.01.01.050355PSA algorithm0.81.00.958351Improved AGA algorithm0.90.81.062340It can be seen from Figure3 that the evolution time of the improved AGA is significantly shorter than that of the pattern search method. At the same time, it can be seen that its ability to inhibit algorithm fluctuations is stronger, which is manifested in many ways: the inferior individuals in the population are eliminated efficiently, the proportion of dominant gene segments in individual gene segments increases [22], the amplitude of fitness fluctuation decreases rapidly in the early stage of evolution, and the direction of population evolution tends to be the same before and after 50 iterations, while PSA needs to be iterated to about 220 times to reach this inhibition level. The convergence process of the two algorithms is shown in Figures 3 and 4, respectively. The improved AGA method is more stable than the PSA method. It only takes about 50 iterations to reduce the average fitness of the population from 500 to 90 for the improved AGA, while the convergence process of PSA method is relatively slow. Based on the above analysis, it can be seen that using improved AGA to solve the drilling parameter design problem has higher stability and solution speed.Figure 3
The convergence process of the PSA method.Figure 4
The convergence process of improved AGA method.Figure5 is the optimization of drilling parameter combination by improved genetic algorithm based on pattern search. It can be seen from Figure 5 that the solution process of the pattern search algorithm has a large fluctuation range and the convergence process is relatively slow. After 150 times of iteration, the evolution tends to be the optimal solution, but there is still a slight fluctuation phenomenon. After only about 70 times of population evolution, it can be concluded that adopting an improved genetic algorithm based on pattern search to solve the optimization of drilling parameter combination can obtain higher stability and solution convergence speed [23].Figure 5
The optimization process of improved genetic algorithm based on pattern search.


### 4.1. Example Calculation

Take a deep well in Karamay as an example. The well is in the Permian Upper Wuerhe Formation from 3864 to 4158 m. The lithology is mainly brown, gray-brown mudstone, and gray sandy conglomerate. The extreme value of formation drillability has little change and the coefficient of abrasivenessAf=2.5×10−3. Three cone bit HJT517GK with a diameter of 215.9 mm is designed for drilling, and it is found that the bit parameters of the bit are: weight-on-bit influence coefficient z1=0.618, z2=6.11, rotational speed influence coefficient a1=0.5, a2=0.218×10−4, tooth wear slowing factor C1=2, bit cost Cb=25000 yuan/piece, daily drilling fee Cd=53064 yuan/d, and the drilling operation fee is Cr=2211 1 yuan/h.Three HJT517GK roller cone bits that participated in the complete drilling of this well section were selected from the mud logging data. The drilling parameters are shown in Table2.Table 2
Actual drilling parameters of each bit.
Bit numberDepth in/mDepth out/mAverage WOB/kNAverage speedBit wear63864.003942.16150750.69B3972.634009.06175560.79C4013.284067.04171640.8It can be seen from Table2 that the optimized WOB is slightly higher than the actual WOB average value. It is recommended to use high WOB for drilling in this formation. The optimized speed is not much different from the actual average drilling speed. The optimized bit wear is greater than the actual bit wear. If the bit is pulled out when the bit wear reaches 0.8~0.9, the bit utilization rate can be improved, the drilling cost can be reduced to a certain extent, and the drilling economic benefit can be improved [24].Figure6 shows the calculation result of the safe drilling fluid density window. The well is a normal pressure system, and the water depth has no effect on the formation pressure. The pore pressure changes in deep water formations are the same as land formations. The safety drilling fluid density window for deep water formations is very narrow, which is mainly due to the rupture pressure value caused by the low level of in situ stress. Given the formation pressure is not affected by the water depth, the minimum horizontal in situ stress is taken as the leakage pressure, and the density window between it and the collapse pressure is approximately 0.3 g/cm3, which is prone to drilling fluid leakage. From the perspective of drilling conditions, the calculated value of collapse pressure is consistent with the density of the practical drilling fluid, and the fracture pressure and leakage pressure are consistent with the measured values, indicating the rationality of the calculation model [25].Figure 6
Change of formation density and in situ stress with depth.


## 4.1. Example Calculation

Take a deep well in Karamay as an example. The well is in the Permian Upper Wuerhe Formation from 3864 to 4158 m. The lithology is mainly brown, gray-brown mudstone, and gray sandy conglomerate. The extreme value of formation drillability has little change and the coefficient of abrasivenessAf=2.5×10−3. Three cone bit HJT517GK with a diameter of 215.9 mm is designed for drilling, and it is found that the bit parameters of the bit are: weight-on-bit influence coefficient z1=0.618, z2=6.11, rotational speed influence coefficient a1=0.5, a2=0.218×10−4, tooth wear slowing factor C1=2, bit cost Cb=25000 yuan/piece, daily drilling fee Cd=53064 yuan/d, and the drilling operation fee is Cr=2211 1 yuan/h.Three HJT517GK roller cone bits that participated in the complete drilling of this well section were selected from the mud logging data. The drilling parameters are shown in Table2.Table 2
Actual drilling parameters of each bit.
Bit numberDepth in/mDepth out/mAverage WOB/kNAverage speedBit wear63864.003942.16150750.69B3972.634009.06175560.79C4013.284067.04171640.8It can be seen from Table2 that the optimized WOB is slightly higher than the actual WOB average value. It is recommended to use high WOB for drilling in this formation. The optimized speed is not much different from the actual average drilling speed. The optimized bit wear is greater than the actual bit wear. If the bit is pulled out when the bit wear reaches 0.8~0.9, the bit utilization rate can be improved, the drilling cost can be reduced to a certain extent, and the drilling economic benefit can be improved [24].Figure6 shows the calculation result of the safe drilling fluid density window. The well is a normal pressure system, and the water depth has no effect on the formation pressure. The pore pressure changes in deep water formations are the same as land formations. The safety drilling fluid density window for deep water formations is very narrow, which is mainly due to the rupture pressure value caused by the low level of in situ stress. Given the formation pressure is not affected by the water depth, the minimum horizontal in situ stress is taken as the leakage pressure, and the density window between it and the collapse pressure is approximately 0.3 g/cm3, which is prone to drilling fluid leakage. From the perspective of drilling conditions, the calculated value of collapse pressure is consistent with the density of the practical drilling fluid, and the fracture pressure and leakage pressure are consistent with the measured values, indicating the rationality of the calculation model [25].Figure 6
Change of formation density and in situ stress with depth.


## 5. Conclusion

This paper takes the optimization combination of drilling parameters during the drilling process as the research object, introduces constraints to control the lowest drilling cost, and establishes a nonlinear optimization mathematical model for the combination of multiple drilling parameters. In view of the shortcomings of the general adaptive genetic algorithm, improvement measures are proposed, and the improved algorithm is used to solve the model. The optimization simulation test results show that the drilling parameter optimization method based on the improved adaptive genetic algorithm (AGA) can complete the drilling parameter design task under constrained conditions and can reduce the drilling cost while improving the design efficiency and accuracy. The comparison between the calculation process and optimization results of the improved AGA method and the PSA method shows that when the bit wear reaches 0.8-0.9, the drill bit can be driven out again, which can improve the bit usage rate, improve the design efficiency and accuracy, and also reduce drilling costs. The wear amount of the optimized bit is higher than that of the actual bit. Increasing the utilization rate of the bit can reduce the cost of drilling meters to a certain extent and improve the economic benefits of drilling. The improved AGA method has rapid and stable convergence, small fluctuation of population fitness, low frequency, and significantly improved genetic evolution efficiency. Under certain conditions of technical equipment, using this parameter optimization method is an effective way to improve the efficiency of drilling parameter design.



---

*Source: 3779630-2022-05-14.xml*