Recibido: 15 de febrero de 2024; Revision Received: 22 de julio de 2024; Aceptado: 29 de julio de 2024
CEMPRI, a primary cementing software for vertical onshore wells as a tool for petroleum engineering education
CEMPRI, un software de cementación primaria para pozos verticales terrestres como herramienta para la educación en ingeniería petrolera
Abstract
The use of simulation software applicable to the various stages of petroleum engineering facilitates decision-making and, at the same time, minimizes possible failures, problems, and incidents during each well intervention. In addition, a computer tool provides the user with instant and accurate results that can be used during personnel training and higher education. The objective of the present work was to develop an open-source computational tool with a graphical, numerical, and schematic interface to facilitate the teaching and learning of operations related to primary cementing. The tool considers four sections: (a) wellbore diagram, (b) identification of the relation between volumetry and the geometric design of the well, (c) integration of the mechanical state with the number of intervals, slurry design, and operating characteristics of the pumps, and (d) the wellbore diagram integrated by drilling, displacement and slurry fluids, according to each of the cementing stages. Among the results, it was combined programming with specialized technical and scientific material, considering academic and field experience characteristics. The program is a versatile tool that integrates the general mechanical state and each of the five stages with a maximum depth of 5,000 m.
Keywords:
onshore oil well, primary cementing, software, wellbore diagram, casing.Resumen
El uso de software de simulación aplicable a las distintas etapas de la ingeniería petrolera facilita la toma de decisiones y, al mismo tiempo, minimiza posibles fallas, problemas e incidentes durante cada intervención en el pozo. Además, una herramienta informática proporciona al usuario resultados instantáneos y precisos que pueden utilizarse durante la formación del personal y la educación superior. El objetivo del presente trabajo fue desarrollar una herramienta computacional de código abierto con una interfaz gráfica, numérica y esquemática para facilitar la enseñanza y el aprendizaje de operaciones relacionadas con la cementación primaria. La herramienta considera cuatro secciones: (a) diagrama de pozo, (b) identificación de la relación entre volumetría y diseño geométrico del pozo, (c) integración del estado mecánico con el número de intervalos, diseño de lechada y características operativas del pozo, las bombas, y (d) el diagrama de pozo integrado por los fluidos de perforación, desplazamiento y lodo, según cada una de las etapas de cementación. Entre los resultados, se combinó programación con material técnico y científico especializado, considerando características académicas y de experiencia de campo. El programa es una herramienta versátil que integra el estado mecánico general y cada una de las cinco etapas con una profundidad máxima de 5.000 m.
Palabras clave:
pozos petroleros terrestres, cementación primaria, estado mecánico, tubería de revestimiento.1. Introduction
The use of simulation software applicable to the various stages of petroleum engineering allows for maximizing decision-making and, in parallel, minimizing possible failures, problems, and incidents during each intervention. Furthermore, a computer tool provides the user with instant and accurate results that can be used during personnel training and education. Several researchers have studied the effective displacement of drilling fluid by cement slurry and the mixing of the two fluids during primary cementing operations [1-3]. The first 2D annular displacement simulator was introduced in 1990; however, the industry has kept its attention on the issue of mud displacement for the last 60 years [4].
Various studies have described the importance of cementing, software development, automation, and several operations in the petroleum industry. Among these, primary cementing is the most important task performed during well completion. This involves depositing a specific amount of cement slurry in the space between the drilled formations and the casing pipes installed inside the well [5]. The primary purpose of this operation is to provide zonal isolation, improve wellbore stability, seal off oil and gas in the formation, and prevent uncontrolled flows that could occur at the wellhead [6-8]. To ensure the integrity of oil wells, it is essential to avoid problems during primary cementing and before any additional thermal, mechanical, and/or chemical loads are applied [9]. Significant losses of mud or slurry into the formation can have a negative impact on the petroleum industry, the economy, the integrity, and the life cycle of the well [10]. It is essential to carry out primary cementing activities with profound knowledge of the actual behavior of the fluids in the wellbore. Otherwise, a possible change in the turbulent flow profile might occur, reducing the isolation between the edge of the formation and the pipes [11]. The efficiency of the displacement process is influenced by several factors, including the condition of the well, the formulation and properties of the drilling fluid and cement (including the spacer and flushing fluid), and the flow regime during displacement, among others [12, 13]. If the pipes were corroded or damaged, it could lead to contamination of the hydrocarbon flowing to the surface or it could be conducted to an area of lower pressure. Cementing aims to protect the outer walls of the pipes against blows during the drilling process and to create a seal between the areas of lost circulation. Hence, primary cementing is vital during wellbore completion.
The importance of a primary cementing system for personal computers as support for the soundness of cementing jobs has been identified by [14]. They also justified the development of this system by pointing out that it saves operation time and simplifies decision-making. However, Villegas-Javier later identified that the development and execution of integral cementing in wells with severe conditions, such as reduced annular spaces and depressed zones, are current technical challenges in the Mexican petroleum industry [15], while [16] consider that investigating displacement efficiency is crucial for improving the quality of cementing. Visual Basic is one of the most used programming languages in engineering, as it is frequently used for simulator development in the petroleum industry. According to [17], engineers can develop various applications using Visual Basic, which is an easy-to-learn and flexible programming tool that can be tailored to their needs. For instance, an interactive pipe selection and laying software with commonly used engineering physical units was developed using Visual Basic [18]. Additionally, [19] mentions that the Shell "SPOT" software has its origins in Microsoft Excel's Visual Basic, while Utsalo et al. [20] created a Microsoft Excel Visual Basic application for casing selection.
Primary cementing involves complex calculations and considerations, which can be overwhelming even with the availability of sufficient information, tools, physical and chemical characteristics of additives, and laboratory equipment for slurry design. The purpose of this work is to develop an open-source computational tool with a graphical, numerical, and schematic interface to simplify the teaching and learning of primary cementing-related operations.
2. Methodology of the CEMPRI software development
The software was developed by following the steps outlined below: i) Firstly, a wellbore diagram is created, which includes the wellbore, casing, and liner as per the oil well design. ii) The relationship between the volumetric equations for annular, internal, and total volume is established based on the geometric design of the well. iii) The following factors are then integrated to develop the software: wellbore volumetry, slurry design, percentage of each slurry additive, operating characteristics of the mud pumps (liner diameter, rod diameter, and length, volumetric efficiency), volume of displacement fluids, rheology, and others. iv) Finally, a wellbore diagram is created that includes drilling, displacement, and slurry fluids, as per each cementing stage. The CEMPRI software is developed using the methodology described in the specialized literature for the training of engineering and operational technical personnel in the field of drilling and well maintenance [21]. This is shown in the flow diagram in Fig. 1.
Figure 1: Functional structure of the software.
The CEMPRI software was written in Visual Basic for Applications in Microsoft Excel. One of the advantages of this application is its simple and intuitive design with a comfortable and user-friendly interface. Additionally, The CEMPRI software provides clear and concise graphical data visualization.
3. Cover
Fig. 2 shows the main cover of the CEMPRI software named: “Datos del Pozo/Well Data”, requesting the following information: name, number, location, placement, and classification of the well. Additionally, the name of the engineer or technician responsible for designing the well is also required.
Figure 2: Software cover screen.
3.1. Wellbore diagram
Fig. 3 shows the wellbore diagrams composed of the wellbore, casing, and liner (a short pipe that does not extend back to the wellhead and generally is suspended or anchored), respectively. The first case corresponds to the wellbore with five casing pipes and the second a wellbore with four pipes and a liner. The black lines represent the walls of the formations, and the yellow lines are the pipes or liner (the last pair of yellow lines, as appropriate to the design); the distance between each pair of parallel and yellow lines corresponds to the diameter of the wellbore and the outer and inner diameter of each pipe.
Figure 3: Wellbore diagram with a liner and a) Five casing pipes, b) four casing pipes.
Fig. 4 begins with the upper label “Wellbore Diagram-Cementing”. The yellow boxes on the left correspond to the input data, and the ones on the upper part are for the diameters, and the initial and final depths of each stage. The lower boxes are for the outer and inner diameters of each of the casing pipes, with their respective depths. This will finally outline the wellbore diagram as follows: the yellow, green, blue, purple, and orange columns represent the annular spaces between the wellbore and the casing pipes, which will be the slurry volumes to be determined. In CEMPRI, all the labels specify variables and parameters with their respective units of measurement. These physical units correspond to those used in primary cementing operations in national drilling equipment, for example: for internal and external diameters and lengths for casing or liner pipe, inches (in) are used; for bulk cement densities, density of slurry and water in g/cm3, bags of cement in kg, drilling depth in m, annular volumes in L, among others. Furthermore, it was pertinent to use the same units that are applied in field operations.
Figure 4: Data entry and wellbore diagram
This program can represent wells with depths of up to 5,000 m. The black lines, shown below the yellow ones, indicate that drilling continues with a smaller bit diameter after the casing has been placed. This causes the pipe to have a telescopic shape and forms an annular space between the walls of the formations and their respective pipes and depths.
3.2. Cementing design
In Fig. 5, the section titled “Cementing Operation” is comprised of five sub-sections: a) Hole-conductor and Graph 1, b) Conductor-surface and Graph 2, c) Surface-intermediate and Graph 3, d) Intermediate-production and Graph 4, e) Production-liner and Graph 5. In each of them, the volume of slurry for the annular space is determined, according to the values of the drill and pipes, allowing the user to assign an additional percentage of slurry since the annular space to be cemented is generally irregular at each stage [22]. The internal volume for each pipe is then determined. Using the data on slurry density, cement type, and bulk cement density, the values for the number of cement sacks, performance, and the volume of water for cementing are obtained for each stage, considering the annular volume and the additional percentage.
Figure 5: Calculation section on volumetry, additives, lead and tail volume, and others.
The “Laboratory data” section corresponds to the percentage values of each of the additives that will make up the slurry, which will allow calculating the mass of each of them to finally know the total mass of all the solid additives of the slurry mixture, as reported by [23] and [24]. Additionally, the slurry design is tested in specific areas where cement is placed, such as fractured areas or areas with low pore pressures [25]. During the testing, the following parameters are observed: pore pressure, fracture gradient, downhole temperature and pressure, physical properties of the formation, geometric deviation of the well, and others.
The program provides five names of additives and allows the addition of up to three more additives, subject to prior laboratory approval. To determine the total volume of the slurry, the user can use two methods: The first method involves calculating the initial and final depth of the perforated stage in two intervals: lead volume and tail volume. The second method has three options: 1. The total depth of the stage is divided equally for each section, “lead and tail”; 2. The length or depth of the lead section is greater than the tail section; and 3. The length or depth of the lead section is less than the tail section.
It is important to note that the program will notify the user of any errors that may occur when assigning depth and length values to the sections of the stage. This is because both values need to match the total depth of the stage. These warnings are crucial in following the observation made by [26], where the design of the fluids, the operating conditions of the displacement flow, and a tool that helps to understand the flow dynamics play a crucial role in achieving an efficient placement of cement.
Fig. 6 displays the “Hole-Conductor” tab, which depicts the integration of the operation data of pumps and volumes of washing, viscous, and separating fluids. This integration helps to determine the flow rate and pumping time of duplex and triplex pumps while considering the sleeve diameter, rod diameter, and length diameter, as required by the operation [21]. The Fann viscometer readings at 600 rpm and 300 rpm are used to determine the flow behavior index “n”, consistency index “K”, and the critical Reynolds number. These readings are also used to find the minimum flow rate in the annular and interior space of the pipe, in case of a turbulent flow occurs.
Figure 6: Calculation section on volumetry, additives, lead and tail volume, and others.
3.3. Cementing distribution
Effective fluid displacement during drilling operations is essential for ensuring high-quality cementing jobs. This, in turn, guarantees zonal isolation and strong bonding of the cement to the casing and formation. Incomplete mud removal can result in poor cement placement, which can cause several critical operational problems and significant environmental hazards [7]. Similarly, [27] suggested using spacer fluids to prevent drilling fluid contamination in the annular space between mud and cement. Since mud and cement are incompatible, using spacer fluids as buffers can help avoid contact between the two substances. The spacer fluids can also aid in removing mud from the annular space. The cement contains calcium that can cause the clay in the drilling fluid to flocculate, resulting in contamination if the two substances come into contact.
In Fig. 7, the numerical values for volumes, lengths, and hydrostatic pressure generated by each fluid are presented. The central image in Fig. 7 represents the distribution of different types of fluids that will move inside the casing and will be distributed in the corresponding annular space. The yellow columns in the figure represent the drilling fluid already present in the annulus, which will be displaced by the displacement fluids. In addition, the upper right graph shows “Density & Time” while the lower one shows “Accumulated Flow Rate & Time” during cement pumping. The program allows for adjusting the volume, density, and flow rate of the scrubber, viscous, and separator fluids to manage the free fall phenomenon mentioned in [11] and [28] during slurry placement. This is done by determining the required amounts of fluid and pumping times and setting the operating parameters for each stage. It is crucial to understand this phenomenon to avoid any misinterpretation as a loss of circulation during cementing. When planning for effective mud removal and cement placement, two main flow regimes are considered: effective turbulent flow and laminar flow [29]. The quality of cementing in the wellbore depends on the quality of mud displacement by the fluids injected into the annular space during the cementing work [30]. Optimal displacement requires knowledge of flow patterns, frictional pressure losses, and the interactions of the mud, spacers, and cement in the annular spaces [31]. According to [32], rheology plays only a minor role in these turbulent flows, although the density differences are still significant. On the other hand, cement slurry rheology and the fluid behind the casing are commonly considered as Bingham-type [33].
Figure 7: Distribution of fluids in the wellbore, pumping profile of density, and flow rate.
4. Results and discussion
An illustrative example was chosen to demonstrate the capabilities of the CEMPRI software, consisting of three parts. Table 1 provides the input data for wellbore diagram schematization. Table 2 contains the information to carry out the design and calculations of each stage to generate the diagram. The cementing space can be designed for one or two intervals, the slurry density, cement type, and the type and percentage of additives can differ between these intervals.
Source: Own elaboration.
Table 1: Information that is entered into the program for the wellbore diagram.
* Quantities determined in Laboratory data as described in Figure 6. Dc: Pump jacket diameter, Dv: Rod diameter, Lv: Rod length, EPM: stroke/min. Source: Own elaboration.
Table 2: Information that is entered into the program for the wellbore diagram.
The exercise example results obtained for each stage in the primary cementing are presented in Table 3. Fig. 8 comprises six images, which outline the wellbore diagram of each stage according to its design considerations and characteristics. For each of the five stages, the specific design characteristics are considered while generating the two graphs shown in Fig. 8: "Density & Time" and "Accumulated Flow Rate & Time." The wellbore diagram for the sample well is depicted in Figure 8a. The diagram shows the annular spaces (slurry volume) for each stage in five colored rectangles: yellow, green, blue, purple, and orange. The wellbore diagram is composed of four casing pipes and a liner. For Figures 8(b-f), the yellow color represents the drilling fluid volume, while the red, green, and purple colors correspond to the displacement fluids before and after the slurry volume. The dark green and gray colors represent lead and tail slurry volumes, respectively.
Source: Own elaboration.
Table 3: Results of the primary cementing of each of the stages.
Figure 8: General wellbore diagram of each stage.
Fig. 8b corresponds to the first stage, where the volume of slurry (represented by dark green and grey lines) and the displacement fluids (shown in red, green, and purple) constitute 91.3% of the internal capacity of the pip. The remaining 8.7% is occupied by the drilling fluid (in yellow) and is present in the annular space. The second stage is represented by Figure 8c, where the total slurry volume was divided into two equal portions referred to as “lead” and “tail”. Here, the total volume of displacement fluids (in red, green, and purple) and slurry (dark green and gray) occupy 99.2% of the internal capacity of the pipe while the remaining 0.8% is occupied by the drilling fluid (yellow). It is important to note that in this case, “Lead” Vslurry is equal to “Tail” Vslurry.
The third stage is represented by Figure 8d. At this stage, the slurry volume and displacement fluids together occupy 46.3% of the internal capacity of the pipe, while the drilling fluid occupies the remaining 53.7%. In this case, we consider “Lead” Vslurry < “Tail” Vslurry.
Figure 8e represents the fourth stage, in which 38.9% of the internal pipe capacity is occupied by the total volume of mud and displacement fluids, while the remaining 61.1% is occupied by drilling fluid. In this case "Lead" Vslurry > "Tail" Vslurry.
The fifth stage corresponds to Figure 8f, where a cemented casing (liner) is observed. This pipe is anchored at a shallower depth than the last pipe, depending on the overlap length between the last pipe and the liner.
It is important to note that the physical unit of the additives that make up the slurry is the percentage symbol (%) [34]. Chaudhry [35] presents a diagram of the pipe and wellbore for each stage of the process but does not include a wellbore diagram or graphs showing the pumping and distribution of different types and volumes of fluids used for primary cementing.
5. Conclusions
The CEMPRI program was created using Visual Basic for Applications in Microsoft Excel, with a macro environment. It is an efficient and useful software for instantaneously calculating primary cementing. The interface design is simple, intuitive, and easy to use, with fast communication and adaptation between the user and the program. It is a versatile tool that integrates a wellbore diagram for up to five stages, allowing for both numerical and graphical calculations individually, with a maximum depth of 5,000 m.
The CEMPRI software was developed to integrate theoretical knowledge with practical activities in oil well design and field departments. The program includes wellbore schematization, diagrams, and graphics that follow the real values of the bits, casing pipes, cementing intervals, chemical materials in the slurry design, pump operating characteristics, volumes, depths, hydrostatic pressures, total hydrostatic pressure, circulation equivalent density, and much more. It is important to have prior knowledge of all these parameters and variables when conducting calculations, analyses, and interpretations. CEMPRI is an open-access academic tool that aims to become a leading program in the field.
References
- [4] Tardy, P.M., Flamant, N.C., Lac, E., Parry, A., Sutama, C.S., and Almagro, S.P., New generation 3D simulator predicts realistic mud displacement in highly deviated and horizontal wells. Day 2 Wed, March 15, 2017, The Hague, The Netherlands, SPE, D021S011R004. 2017. DOI: https://doi.org/10.2118/184677-MS. [URL] 🠔
- [16] Zhang, H., Guo, J., Yang, L., Wu, P., Xue, H., and Yang, M., Optimization of cementing displacement efficiency based on circulation pressure of a shale gas horizontal well in low pressure and leakage formations. Energy Reports 8, pp. 11695-11706, 2022. DOI: https://doi.org/10.1016/j.egyr.2022.08.253. [URL] 🠔
- [24] Cammarata, N., and Rosero, I., CEM 2 Primary cementing. 1st ed. Cementing in Touch. Schlumberger, Sugarland, Texas, 2017, 213 P. 🠔
- [27] Zulqarnain, M., and Tyagi, M., Development of simulations-based correlations to predict the cement volume fraction in annular geometries after fluid displacements during primary cementing. Journal of Petroleum Science and Engineering 145, pp. 1-10, 2016. DOI: https://doi.org/10.1016/j.petrol.2016.03.012. [URL] 🠔