1. Introduction
In the process of the drilling and production of oil and gas wells, in order to ensure the safe exploitation of oil and gas resources, oil and gas well cementing operation is one of the most important links. Cementing is to inject cement slurry into the annulus between casing and formation, as well as casing and casing. After it is solidified to form cement stone, the formation fluid is shielded and sealed, and the casing is supported and protected, which provides a safe barrier for the subsequent development and production of oil and gas resources [
1,
2,
3,
4].
Because the cement sheath needs to bear a lot of external force in the drilling operation, such as pressure, shear force, bending moment, etc., the deterioration of mechanical properties will lead to the destruction of the bonding interface between cement and casing or the destruction of the cement sheath body as well as the formation of a micro gap, resulting in sealing failure [
5]. Therefore, the mechanical properties of the cement sheath determine the bearing capacity and deformation capacity of the cement sheath. Among them, the elastic parameters of the cement sheath have a direct impact on the stability and integrity of the structure. It is an important parameter index to measure the quality of its cementation and sealing. It is also one of the necessary parameters for analyzing the cement sheath’s variable capacity and long-term sealing capacity. It plays a vital role in structural analysis and mechanical performance evaluation [
6,
7,
8].
The elastic modulus of hardened cement paste is an important mechanical parameter to evaluate its performance, and it is also the basis for the optimization design of concrete materials. To this end, domestic and foreign scholars carried out some fruitful research in both experimental and simulation analysis. In terms of experimental research, Boumiz et al. [
9] used ultrasonic technology to measure the Young ’s modulus and Poisson’s ratio of early-age cement stone, and focused on the variation in Young ’s modulus with age, hydration degree, temperature, and other factors. It is found that the degree of connection between cement hydration particles and the filling of hydroxides in capillary pores are two main mechanisms for the increasing elastic modulus of cement stone. Constantinides et al. [
10,
11] confirmed the existence of two kinds of C-S-H colloids with different density and elastic modulus in cement paste by using the nanoindentation technique. The volume ratio and elastic modulus of the two kinds of C-S-H colloids and the elastic modulus of unhydrated cement and CH were measured, which laid a foundation for further study of the microstructure and macroscopic mechanical properties of cement paste. Haecker and Sun et al. [
12] used the elastic resonance frequency method to test the elastic modulus of cement stone, and studied the influence of water cement ratio and hydration degree on the elastic modulus of cement stone.
In terms of simulation analysis, in recent years, scholars at home and abroad have been committed to using computers to simulate the microstructure, hydration process, and its variation in cement-based materials, trying to reveal the internal mechanism of cement hydration and its variation. The acquisition or improvement of the special properties of any material is actually achieved through the change in its meso-structure. The macroscopic properties of the material mainly depend on its meso-structure. Constantinides et al. [
10] regarded cement stone as a four-phase composite material and proposed a homogenization model for predicting elastic modulus. Lin et al. [
13] proposed a micromechanical method for calculating the elastic modulus of hardened cement stone. Therefore, the application of a micromechanical numerical simulation method can replace part of the test under the condition that the calculation model is reasonable and the material properties of each phase of cement are accurate and can avoid the objective limitation of test conditions and the influence of human factors on the results. Therefore, it is a reasonable choice to study cement hydration and its micromechanical properties through numerical simulation. When calculating and predicting the elastic modulus of cement stone by the micromechanics method, it is necessary to first understand the material properties of each phase of cement and obtain the elastic modulus of each phase component of cement stone.
Calcium hydroxide (CH) is the hydration product of oil well cement stone second only to C-S-H gel, and it is also the most abundant crystalline phase product in hydration products [
14,
15]. Therefore, the elastic modulus of CH has a direct effect on the elastic modulus of cement stone. Domestic and foreign scholars conducted a lot of research on the determination method and prediction method of CH content. Commonly used methods include chemical extraction, thermogravimetric analysis (DSC-TG), and X-ray diffraction (XRD) [
16,
17]. In the early stage, due to the simple equipment and easy operation of the chemical extraction method, it was often used for determination. The most popular method in the chemical extraction method was proposed by B. Franke [
18], that is, using a mixed solution of acetyl acetate and isobutanol as an extractant to extract calcium hydroxide in the solution. However, the extraction method has a certain erosion effect on the C-S-H colloid so that it is extracted together with CH, resulting in a higher measurement result than the actual value. Zhang et al. used comprehensive thermal analysis (DSC-TG) to quantitatively analyze the content of CaCO
3 and calcium hydroxide in carbonated cement stone powder. Compared with the test results of chemical analysis, thermogravimetric analysis is quantitative, fast and convenient, and is less affected by environmental and human factors, but the sample is easy to carbonize during preparation and treatment. The X-ray diffraction method is not affected by the change in experimental conditions, but it can only determine the crystalline calcium hydroxide, and cannot determine the amorphous calcium hydroxide, resulting in measurement results that are lower than the actual.
In terms of the prediction method of CH content, Pierre Mounanga et al. [
19] established a semi-empirical model to predict the content of calcium hydroxide in the early stage of cement hydration based on the hydration reaction equation of cement. The model can calculate the amount of calcium hydroxide in cement paste according to the content of the main mineral components in cement clinker and the degree of hydration. Khunthongkeaw et al. [
20] calculated the amount of calcium hydroxide produced by unit mass of C
3S and C
2S hydration and the amount of calcium hydroxide consumed by unit mass of SiO
2 through secondary hydration through the chemical equations of hydration reaction and pozzolanic reaction, and then obtained the calculation formula of the amount of calcium hydroxide in fly ash concrete. Tatsuhiko Saeki et al. [
21] established a prediction model after regression analysis of the experimental data. The model uses the degree of hydration of mineral admixtures and the rate of consumption of calcium hydroxide as variables to calculate the amount of calcium hydroxide in cement-based composites with fly ash and ground slag. Yan et al. [
22] deduced the calculation formula of calcium hydroxide content in the product when the cement clinker was completely hydrated by the hydration reaction equation of Portland cement and its chemical composition calculation formula.
Since the vigorous development of quantum mechanics and the significant improvement of computer computing ability in the 20th century, molecular simulation emerged as an emerging method for calculating the properties of molecular structures and molecular systems. At present, molecular simulation has become the main research method to calculate the properties of materials at the microscopic scale. Al-Ostaz et al. [
23] calculated the mechanical properties of calcium hydroxide (CH), jennite, and tobermorite14Å. Studies have shown that the size of the structural model and the molecular dynamics study of the structure and mechanical properties of the main components of the cement selected for simulation have an impact on the calculation results. Manzano et al. [
20] used the force field method to study the elastic properties of calcium hydroxide and obtained the anisotropic effect of the elastic properties of calcium hydroxide. The value is Ex = Ey = 93.68 GPa, Ez = 32.8 GPa, which is in good agreement with the experimental data. Yuanzhi Liang et al. [
24] studied the mechanical properties and fracture properties of calcium silicate hydrate and calcium hydroxide composites by reactive molecular dynamics simulation. The results show that the tensile strength and Young’s modulus of calcium hydroxide are the highest, followed by calcium silicate hydrate. The research results provide the necessary parameter input for the multi-scale mechanics and fracture research of cement paste.
The machine learning method has high accuracy and fast convergence. In recent years, it received extensive attention in various fields, especially in civil engineering. In the study of cement and concrete, such as the preferred proportion of composite materials [
25,
26] and performance prediction [
27,
28], it has a large number of applications. However, there are few related applications in the elastic modulus of the cement phase. In this paper, the elastic modulus of calcium hydroxide under a different temperature and pressure is simulated by MS, and the prediction is carried out by machine learning technology, which provides a new prediction method for the elastic modulus of each phase of oil well cement stone under high temperature and high pressure.
At present, domestic oil and gas exploration and development is moving towards the “two deep and one non” oil and gas field. Oil well cement is facing extreme operating environments, such as high temperature (>150 °C) and high pressure (>105 MPa). However, the hydration of oil well cement changes with time and environmental conditions. There is no suitable method to calculate and predict the elastic modulus of each phase under high temperature and high pressure. Therefore, it is of great significance to realize the prediction of the elastic modulus of each phase in oil well cement under high temperatures and high pressure to quantify the change in mechanical properties of cement stone and to measure the cementation and sealing quality of oil well cement stone under high temperatures and high pressure.
In this study, the elastic modulus and Poisson’s ratio of CH in oil well cement stone under different temperatures and pressure conditions were obtained by combining molecular dynamics simulation with the first-principles calculation method and machine learning technology, and finally the prediction method of elastic modulus of calcium hydroxide in oil well cement stone was established.
2. Data and Methodology
2.1. Dataset Establishment and Method
In order to comprehensively parameterize the mechanical properties of calcium hydroxide, relevant mechanical parameters are obtained through the first principle-related mechanical properties, and the relevant data of the elastic modulus are enriched. From a microscopic point of view, the elastic modulus is a reflection of the bonding strength between atoms, ions, or molecules. Any factor that affects bond strength can affect the elastic modulus of the material, such as the bonding method, chemical composition, microstructure, temperature, pressure, and other related factors. The elastic stiffness constant matrix of the three-dimensional material is 6 × 6, as shown in
Figure 1, and Cij is the elastic constant in the figure below. It describes the stiffness of the crystal in response to applied strain. The stresses and strains of the system satisfy Hooke’s law over the range of linear deformations of the material. That is, for a sufficiently small deformation, the stress is proportional to the strain. At the same time, because the stiffness matrix is a symmetric matrix, the number of independent matrix elements of the elastic constants is up to 21.
The type of crystal system of three-dimensional materials determines the number of elastic constants, that is, the number of independent matrix elements of stiffness matrix. Temperature and pressure affect the change in lattice volume and density. Temperature is positively correlated with lattice volume and negatively correlated with density. As the temperature increases, the lattice volume increases and the density decreases. Pressure is negatively correlated with lattice volume and positively correlated with density. As the pressure increases, the lattice volume decreases and the density increases. The lattice volume and density will affect the elastic constant, lattice constant, and lattice angle. Through the first-principles calculation, the elastic modulus of calcium hydroxide will be affected.
Since calcium hydroxide is a hexagonal crystal system, there are five independent matrix elements, which are elastic constants C11, C12, C13, C33, and C44, respectively. Therefore, in this paper, temperature, pressure, lattice constant a, lattice constant b, lattice constant c, lattice angle α, lattice angle β, lattice angle γ, lattice volume, density, and elastic constant C11, C12, C13, C33, and C44 fifteen parameters are used as the eigenvalues of elastic modulus prediction.
In this study, the formation pressure of the Puguang gas field is used as a reference. At the same time, according to the depth of 100 m underground, the temperature will increase by about 2 °C. The simulated temperature is 298 K to 473 K, and the pressure is from 0.1 MPa to 145 MPa.
The crystal structure of CH was obtained by accessing the Crystallographic Open Database as shown in
Figure 2. The obtained crystal structure of CH was simulated by Material Studio (MS) 2018 and the simulation process is shown in
Figure 3. Firstly, the Castep module was used to optimize the structure to obtain the lowest energy chemical configuration of calcium hydroxide crystal, and the chemical configuration was supercelled. Next, molecular simulations were carried out by using the Forcite module, based on molecular dynamics, selecting the COMPASS II force field, and utilizing the canonical ensemble (NVT) and the isothermal–isobaric ensemble (NPT). The step size is set to 1 fs and the Q-ratio is 0.10. The Ewald addition method is used for Coulomb electrostatic interaction, and the atom-based addition method is used for van der Waals interaction. Then, the first nature principle-related mechanical property methods as well as the Voigt–Reuss method were utilized to obtain the temperature, pressure, lattice constant a, lattice constant b, lattice constant c, lattice angle α, lattice angle β, lattice angle γ, lattice volume, density, elasticity constants C
11, C
12, C
13, C
33, and C
44, and other related mechanical property parameters, totaling 162 groups for CH under different temperature and pressure conditions (298–473 K, 0.1–145 MPa).
2.2. Outlier Processing
In order to ensure the quality of the subsequent model, the data must be preprocessed, and the elastic modulus of each group of data was used as the basis for judging the outliers. It was known from
Figure 4 that the elastic modulus of a total of five groups of sample points deviates significantly from the normal value. The abnormal values were deleted and the data were sorted out. Finally, 157 pieces of data were obtained for research.
2.3. Feature Importance
Before establishing the elastic modulus prediction model, it is very important to select the factors that affect the elastic modulus of calcium hydroxide. Feature selection is the process of analyzing and evaluating the relevant factors and determining which ones are most important and which ones can be ignored. Secondly, the feature selection technology is used to reduce the dimension of the feature space and improve the accuracy of the model. It can also effectively avoid redundant information and overfitting phenomenon between features. A total of 15 parameters of temperature, pressure, lattice constant a, lattice constant b, lattice constant c, lattice angle α, lattice angle β, lattice angle γ, lattice volume, density, and elastic constants C
11, C
12, C
13, C
33, and C
44 were obtained by MS simulation. Due to the long names of some properties, these properties are numbered for ease of representation, and the process is shown in
Table 1.
Among the above influences, there may be features that do not have a significant effect on the CH elastic modulus. If not removed, these features may interfere with model performance and reduce prediction accuracy. The random forest algorithm (RF) was used in this study to calculate feature importance [
29,
30,
31]. The random forest algorithm evaluates the importance of features by calculating the split contribution of the features in constructing the decision tree and performs feature selection by ranking the importance of the features. It can automatically deal with the correlation and non-linear relationship between features and has good fitting and generalization ability.
By using the RF model to rank the importance of the features of the 15 parameters, the results are shown in
Figure 5. Ten parameters with high correlation were selected. Here, temperature, pressure, lattice constant c, lattice angle γ, density, and elastic constants C
11, C
12, C
13, C
33, and C
44 were selected as input, and elastic modulus as output.
The correlation coefficient between each feature was calculated and visualized using a heat map. Positive values indicate that the features are positively correlated and negative values indicate that the features are negatively correlated. The absolute value of the correlation coefficient represents the degree of correlation of the features, with larger values indicating a higher degree of correlation. The results are shown in
Figure 6.
6. Conclusions
The main purpose of this paper is to predict the elastic modulus of CH phase in oil and gas well cement by using the machine simulation method. The crystal structure of CH was obtained through the Crystallography Open Database. The molecular dynamics simulation was carried out by using Material Studio and the first-principles calculation method, and the initial data set was constructed by obtaining the relevant mechanical properties.
The hidden layer parameters are adjusted to make the three prediction models of BP, RBF, and RF achieve the best results. The fitting effects of the three machine learning algorithms are compared to verify the predictability of the proposed model. According to the research results and analysis, the following conclusions are drawn:
- (1)
Based on the basic processing of the original data, the first 10 factors with greater influence were selected from the 15 factors affecting the elastic modulus of CH. The results show that the elastic constant is the most important factor affecting the elastic modulus of CH, and the influence of temperature, pressure, and density on the elastic modulus of CH is slightly smaller, but it cannot be ignored.
- (2)
In this paper, the hidden layer parameters of BP, RBF, and RF prediction models are analyzed by the orthogonal experiment with range analysis, and the best level is selected by the mean value of each factor: The best combination of the BP model is that the initial value of the generated random number is 2, the number of neurons is 8, the number of iterations is 1000, and the learning rate is 0.05. The best combination of the RBF model is that the extension speed of generating radial basis function is 400. The best combination of the RF model is that the number of optimization parameters is 8, the number of populations is 4, the maximum number of iterations is 40, the number of decision trees is 300, and the minimum number of leaves is 1.
- (3)
Compared with BP and RF models, the RBF model has the highest prediction accuracy for CH elastic modulus. The R2 values of the training and testing processes are 0.99999 and 0.9988, respectively, which are the closest to 1 among the three models. RMSE, MAE, and MSE values are also one level smaller than the RMSE, MAE, and MSE values of the other two models, and the fitting effect is the most satisfactory.
The RF model is less effective compared with the other two models. The R2 values in the training phase and the test phase are 0.9631 and 0.8877, respectively, and the results are quite different, indicating that there may be over-fitting.
Compared with previous studies, this paper realizes the prediction of the elastic modulus of calcium hydroxide under different temperatures and pressures through MS simulation and machine learning. Compared with the traditional instrument measurement method, this method is simple and rapid, time-saving and labor-saving, and the prediction accuracy is high. At the same time, this prediction method can be applied to other phases of oil well cement, which solves the problem that the phase content of oil well cement stone changes with time and environmental conditions, and it is difficult to measure. At the same time, combined with the micromechanics method, it provides a prediction method for the elastic modulus of oil well cement under high temperatures and high pressures that is difficult to be measured experimentally, which can save a lot of manpower and material resources and achieve economy.