Real-time automatic controller for managed temperature drilling
The RDFM and system identification techniques enable real-time management of downhole temperature and pressure, addressing tool failure issues by automatically adjusting drilling parameters, thereby improving drilling efficiency and reducing costs in geothermal and HPHT wells.
Patent Information
- Application Number
- PCT/US2025/017691
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2025-02-03
- Filing Date
- 2025-02-27
- Publication Date
- 2025-10-23
AI Technical Summary
Existing drilling technologies face challenges in maintaining optimal downhole temperature and pressure conditions, leading to tool failure and increased non-productive time due to manual adjustments of drilling parameters, which result in over- or under-compensation, affecting energy efficiency and tool durability.
A control-oriented platform utilizing a reduced drift-flux model (RDFM) and system identification techniques to develop controllers that automatically manage downhole temperature and pressure, incorporating PID, optimal, and adaptive control algorithms, along with choke adjustments and flow rate modulation, to regulate downhole conditions in real-time.
The solution effectively maintains optimal downhole conditions, reducing tool failure and non-productive time, enhancing drilling efficiency and reducing costs by accurately controlling temperature and pressure in geothermal and HPHT wells.
Smart Images

Figure US2025017691_23102025_PF_FP_ABST
Abstract
Description
REAL-TIME AUTOMATIC CONTROLLER FOR MANAGED TEMPERATURE DRILLING CROSS-REFERENCE TO RELATED APPLICATIONS
[0001] This Application claims benefit of priority from U.S. Provisional Patent Application No. 63 / 753,076, filed on February 3, 2025 and U.S. Provisional Patent Application No. 63 / 558,463, filed on February 27, 2024. Each of these patent applications is incorporated herein by reference in its entirety. BACKGROUND Field
[0002] Embodiments of the present disclosure generally relate to rigs, such as drilling or service rigs, and particularly to methods and apparatus for forming a wellbore. In particular, embodiments of the present disclosure relate to controlling the downhole temperature and pressure while forming a well.
[0003] Description of the Related Art
[0004] When drilling for hydrocarbon and geothermal energy, a well is constructed to reach the energy reservoir located miles beneath the earth surface. With the advance of drilling engineering, longer and deeper wells are constructed. The length of the well can be over thirty thousand feet and the well construction can last for several days to months. A drill string, measuring several inches in diameter, is utilized to transfer the applied loads, such as weight and torque, from the surface to the bottom hole to effectively form the borehole.
[0005] A primary obstacle to drilling deeper or more cost-effective wells is tool failure under extreme temperatures. For example, high enthalpy geothermal wells present high-temperature and sometimes high-pressure (HPHT) conditions. Tools and sensors vulnerable to these conditions often fail, leading to increased cost and non-productive time (NPT). Although there are high temperature tools rated for up to 350 °F, most downhole tools are currently rated up to a maximum temperature of 300 °F degrees.PATENT Attorney Docket No.: UTXA / 8328PC
[0006] To prevent these tools from failing, techniques such as insulated pipe, continuous circulation, and mud coolers are employed so that sufficiently cool drilling mud can be efficiently circulated to the bottomhole to cool downhole tools. However, when using cooler while drilling, or using continuous circulation while making pipe connections, the surface drilling parameters such as flow rates, mud cooler amounts, are manually set, leading to an over- or under-compensation of downhole mud temperature. Over-compensation reduces energy efficiency, while under- compensation leads to high-temperature tool failure and NPT. Accurate knowledge of the downhole temperature is vital for maintaining the optimal downhole conditions.
[0007] There is, therefore, a need for an improved controller for controlling the downhole temperature and pressure while drilling. SUMMARY
[0008] In one embodiment, a method of controlling temperatures of a wellbore includes supplying a wellbore fluid into the wellbore and measuring the temperature of the wellbore fluid. The measured temperature is compared to a predetermined downhole temperature. The method also includes determining, using a controller, an operational adjustment to a drilling parameter and adjusting the drilling parameter to modify the downhole temperature. In some embodiments, the downhole temperature is modified in real time.
[0009] In some embodiments, the controlled drilling parameter is one of an inlet temperature of the wellbore fluid, an inlet flow rate of the wellbore fluid, an opening of a choke valve, the back-pressure of the outlet wellbore fluid, a fluid composition, or combinations thereof.
[0010] In some embodiments, the controller comprises a feedforward proportional integral derivative (PID) controller. In some embodiments, the controller determines the operational adjustment using a reduced drift-flux model.
[0011] In some embodiments, in response to an increase in the downhole temperature caused by an increase in the inlet temperature, the downhole temperature is adjusted by increasing the inlet flow rate. In some embodiments, in response to anPATENT Attorney Docket No.: UTXA / 8328PC increase in the downhole temperature caused by a decrease in the inlet flow rate, the downhole temperature is adjusted by decreasing the inlet temperature. In some embodiments, in response to an increase in the downhole temperature caused by a kick of formation fluid flowing into the wellbore, the downhole temperature is adjusted by increasing the inlet flow rate, decreasing the inlet temperature, or both.
[0012] In some embodiments, in response to an increase in the downhole temperature caused by an increase in thermal conductivity of a drill string, the downhole temperature is adjusted by increasing the inlet flow rate, decreasing the inlet temperature, or both.
[0013] In some embodiments, the method is performed during a drilling operation.
[0014] In some embodiments, the controller comprises a multi-input multi-output controller or a single-input, single-output controller.
[0015] In some embodiments, the controller determines the operational adjustment using a system identification technique.
[0016] In some embodiments, the method includes measuring a downhole pressure and comparing the downhole pressure to a predetermined downhole pressure.
[0017] In some embodiments, the method includes determining, using the controller, an operational adjustment to a second drilling parameter. BRIEF DESCRIPTION OF THE DRAWINGS
[0018] So that the manner in which the above recited features of the present disclosure can be understood in detail, a more particular description of the disclosure, briefly summarized above, may be had by reference to embodiments, some of which are illustrated in the appended drawings. It is to be noted, however, that the appended drawings illustrate only exemplary embodiments and are therefore not to be considered limiting of the scope of the disclosure, as the disclosure may admit to other equally effective embodiments.PATENT Attorney Docket No.: UTXA / 8328PC
[0019] Figure 1 schematically illustrates an exemplary rig, according to some embodiments.
[0020] Figure 2 schematically illustrates a downhole temperature control system of the rig of Figure 1, according to some embodiments.
[0021] Figure 3 schematically illustrates an exemplary numerical solution procedure a RDFM, according to some embodiments.
[0022] Figure 4 schematically illustrates an exemplary controller suitable for use with the rig of Figure 1.
[0023] Figure 5 shows the results for BHA 9 validation.
[0024] Figure 6 shows the results for BHA 18 validation.
[0025] Figure 7 shows the results of a comparison of transient bottomhole temperature between the DFM and RDFM.
[0026] Figure 8 shows the results for decrease in mud cooler performance control scenario using a flow rate (Q) controller.
[0027] Figure 9 shows the results for pump failure control scenario using an inlet temperature (Tin) controller.
[0028] Figure 10 shows the results for thermal kick control scenario using a flow rate (Q) controller.
[0029] Figure 11 shows the results for thermal kick control scenario using an inlet temperature (Tin) controller.
[0030] Figure 12 shows the results for pipe insulation flaking control scenario using a flow rate (Q) controller.
[0031] Figure 13 shows the results for pipe insulation flaking control scenario using an inlet temperature (Tin) controller.
[0032] Figure 14 shows the system identification results for mud pump rate.PATENT Attorney Docket No.: UTXA / 8328PC
[0033] Figure 15 shows the system identification results for mud inlet temperature.
[0034] Figure 16 shows the system identification results for choke opening.
[0035] Figure 17 shows an exemplary MIMO control diagram of a coupled controller, according to some embodiments.
[0036] Figure 18 shows an exemplary MIMO control diagram of a SISO controller, according to some embodiments.
[0037] Figure 19 shows the MIMO control response when mud pump rate and mud inlet temperature are used.
[0038] Figure 20 shows the MIMO control response when mud pump rate and choke are used.
[0039] Figure 21 shows an exemplary well trajectory.
[0040] Figure 22 shows the relation between the mud temperature and the DP apparent thermal conductivity, ^^^^^.
[0041] Figure 23 shows the relation between the remaining coating area ratio, ^^, and the DP apparent thermal conductivity, ^^^^^.
[0042] Figure 24 shows the relation between the remaining coating thickness ratio, ^^, and the DP apparent thermal conductivity, ^^^^^.
[0043] To facilitate understanding, identical reference numerals have been used, where possible, to designate identical elements that are common to the figures. It is contemplated that elements and features of one embodiment may be beneficially incorporated in other embodiments without further recitation. DETAILED DESCRIPTION
[0044] Embodiments of the present disclosure provides a control-oriented platform to achieve automated managed temperature drilling in real-time. In one embodiment, an improved reduced drift-flux model (RDFM) that considers temperature dynamics, interface mass transfer, and a new lumped pressure dynamics model is used. InPATENT Attorney Docket No.: UTXA / 8328PC another embodiment, system identification techniques are used to develop a reduced- order model that captures the thermal-hydraulic interactions, thereby allowing for efficient and yet accurate controller design. By considering these factors, the model is used to digitally twin the transient thermal behavior of geothermal wells.
[0045] In some embodiments, the RDFM is used in conjunction with a controller to maintain sufficiently cool bottom-hole temperature for downhole tools in various drilling scenarios. The control-oriented platform may be used to automatically manage the downhole temperature in a geothermal or HPHT well.
[0046] Multi-input-multi-output (MIMO) or single-input-single-output (SISO) controllers can be developed based theories like PID, optimal control, robust control, adaptive control, etc., to control one or both of the bottomhole pressure and bottomhole temperature. In this manner, embodiments of the present disclosure employs automatic and predictive control algorithms to reduce negative thermal effects during drilling, thereby significantly decreasing non-productive time events and the cost of constructing a geothermal well.
[0047] In some embodiments, an integrated managed pressure drilling and managed temperature drilling (MPD-MTD) control strategy utilizes one or more of choke adjustments, flow rate modulation, and mud cooling to simultaneously regulate downhole pressure and temperature.
[0048] Embodiments of the present disclosure provides methods and system for evaluating the performance of well temperature and pressure management. In one embodiment, the integrity of the drill pipe coating during actual drilling operation is estimated through the comparison between well temperature and its digital twin. Using the measured wellbore temperature, the insulation coating condition is determined and the remaining lifespan of the insulation coating is estimated.
[0049] Figure 1 schematically illustrates a portion of a rig 100. In some embodiments, the rig 100 is a drilling rig or a service rig. The rig 100 includes a derrick 102 that extends above a floor 104. A crown block 108 is located at an upper end of the derrick 102. A drawworks 120 is located at the floor 104. A traveling block 110 is suspended below the crown block 108 by a cable 106 that extends from the drawworksPATENT Attorney Docket No.: UTXA / 8328PC 120 and around the crown block 108. The traveling block 110 is raised by using the drawworks 120 to retract the cable 106, and is lowered by using the drawworks 120 to pay out the cable 106. In some embodiments, a tubular handling tool 116, such as a top drive, power swivel, or elevator, is suspended from the traveling block 110. In some embodiments, the tubular handling tool 116 is omitted.
[0050] The drill string 325 includes interconnected sections of drill pipe 327, a bottom hole assembly (BHA) 340, and a drill bit 348. The BHA 340 may include stabilizers, drill collars, and / or measurement-while-drilling (MWD) or wireline conveyed instruments, among other components. The drill bit 348 is connected to the bottom of the BHA 340. In this example, the top drive 116 is utilized to impart rotary motion to the drill string 325.
[0051] A mud pump system 330 delivers the mud to the drill string 325 through a hose 328 or other conduit. The mud flows through the drill bit 348 and fills the annulus that is formed between the drill string 325 and the inside of the wellbore 335, and is circulated to the pump system 330. A choke valve 337 may be positioned between the wellhead 338 and the pump system 330 to control the fluid outlet pressure of the wellbore 335. A rotating control device 339 is disposed on the wellhead 338. A return temperature sensor 366 and pressure sensor 367 may be disposed between the wellhead 338 and the choke valve 337
[0052] The drilling rig system 100 also includes a rig control system 400 configured to control of one or more components of the drilling rig system 100. For example, the control system 400 may be configured to transmit operational control signals to one or more of the top drive 116, the drawworks 120, the BHA 340, the choke valve 337, or the mud pump system 330. The control system 400 may be installed somewhere on or near the derrick 102 or at a remote location away from the derrick 102.
[0053] In some embodiments, the control system 400 may receive one or more state variables, such as the flow rate, the drill string and / or annulus side pressure, the inlet or / and outlet temperature of the mud from the mud system 330, the opening of the choke valve 337. The control system 400 may also receive downhole variables such as downhole temperature and pressure from the BHA 340, drilling fluid temperature and pressure at different depths along the wellbore 335. The controlPATENT Attorney Docket No.: UTXA / 8328PC system 400 is configured to calculate values for adjusting one or more inputs of the mud system 330 including inlet temperature and flow rate, the opening in the choke valve 337, the fluid composition such as mud composition, or combinations thereof. In some embodiments, the values are calculated in real-time using pre-defined dynamic models and control algorithms. Thus, for example, a first value may be generated to adjust the flow rate of the mud system 330, a second value may be generated to adjust the temperature of the inlet mud, a third value may be generated to adjust the opening of the choke valve 337, or combinations thereof. In this respect, one or more of the flow rate, mud temperature, and choke opening variations can be used to adjust the downhole temperature.
[0054] In some embodiments, the control system 400 includes a system controller 410. The controller 410 includes a central processing unit 423 (CPU), a memory 424 containing instructions, and support circuits 425 for the CPU, as illustrated in Figure 2. The memory, or non-transitory computer readable medium, is one or more of a readily available memory such as random access memory (RAM), read only memory (ROM), floppy disk, hard disk, flash drive, or any other form of digital storage, local or remote. The support circuits are coupled to the CPU for supporting the CPU. The support circuits include cache, power supplies, clock circuits, input / output circuitry and subsystems, and the like. Operations and operating parameters are stored in the memory as a software routine that is executed or invoked to configure the controller 410 into a specific purpose controller to control the operations of the rig 100, such as controlling the temperature and flow rate of the mud and the opening of the choke valve 337. The controller 410 is configured to conduct one or more of the operations described herein. In some embodiments, the controller 410 is configured to take action in response to data received from one or more sensors or tools of the rig 100. The instructions stored on the memory, when executed, cause one or more of the operations described herein to be conducted.
[0055] In this embodiment, the control system 400 of the rig 100 is integrated with the mud system 330, the choke valve 337, the BHA 340, and with additional components of the rig 100, such as the top drive 116 and the drawworks 120. In some embodiments, the control system 400 includes the controller 410, a userPATENT Attorney Docket No.: UTXA / 8328PC interface 422, and a display 426. The user interface 422 may be independent from the controller 410 or may be a part of the controller 410.
[0056] The display 426 may be used for visually presenting information to the user in textual, graphic, or video form. The display 426 may also be utilized by the user to input drilling parameters or set point data via an input mechanism of the user interface 422. The user interface 422 may be used to receive drilling parameters, including mud temperature, mud flow rate, and the choke opening, before and / or during drilling operations. Additionally, a user may input information relating to the drilling parameters of the drill string 325, such as the BHA 340, drill pipe size, bit type, depth, formation information, and drill pipe material, among other things.
[0057] The pump system 330 may include a flow rate sensor 346, a mud composition sensor 347, and a mud inlet temperature sensor 349. The pump system 330 may also include a mud pump and a pump controller 255. The mud pump controller 255 may be in communication with the system controller 410. In some examples, the mud composition may be stored in memory 424.
[0058] The BHA 340, drill string 327, and the constructed wellbore 335 may include one or more sensors configured to detect parameters relating to the downhole drilling environment and other information. For example, the BHA 340 may include a downhole temperature sensor 341 configured to measure the downhole temperature and a downhole pressure sensor 342 configured to measure the downhole pressure. The wellbore 335 may include multiple temperature sensors (e.g., 361, 362) at different depths configured to measure the wellbore temperature and multiple downhole pressure sensors (e.g., 363, 364) at different depths configured to measure the wellbore pressure. The sensor data detected via one or more of these downhole sensors 341, 342 along with other sensors (e.g., 346, 347, 349, 366, 367) in the rig 100 or the wellbore 335 may be sent via electronic signal or other signal to the controller 410 via wired or wireless transmission. The controller 410 may consider this data when it determines how to adjust the mud system 330 and the choke valve 337 operation. In some embodiments, the system controller 410 is configured to adjust one or more of the mud inlet temperature, mud flow rate, choke opening, and fluid composition in response to the data received from one or more of the sensors toPATENT Attorney Docket No.: UTXA / 8328PC control the downhole temperature and pressure. In some embodiments, the controller 410 is configured to adjust the fluid composition, such as the mud composition. For example, the fluid composition is adjusted to increase or decrease its viscosity. In some embodiments, the adjustments made may cause the downhole temperature to increase or decrease. It is contemplated the downhole temperature may include the bottomhole circulation temperature as well as the temperature along any section of the wellbore, including the annulus or the drill string. Similarly, it is contemplated the downhole pressure may include the bottomhole pressure as well as the pressure along any section of the wellbore, including the annulus or the drill string.
[0059] In some embodiments, the dynamics defining the RDFM include temperature, pressure, liquid propagation, and gas propagation dynamics. The thermo-hydraulic model includes the mass, momentum, and energy conservation equations to simulate the flow of fluid in a wellbore.
[0060] Equations 1-3 describe the lumped pressure dynamics model used in the RDFM. Eq.1 describes the pressure distribution within the well. ^^^is the pressure at the outlet boundary, ^^^^^௩is the gravitational force per unit volume, and ^^௪^is the wall friction per unit volume. Eq.2 is pressure boundary condition for an open system. ^^^,^௫is the exogenous pressure at the outlet boundary. Finally, Eq.3 describes the pressure boundary condition for a restricted system. ^̅^ is the effective bulk modulus, ^^ is the total volume of the pipe or annulus, ^^^,^^^is the volumetric flow rate of the liquid source, ^^^,^^^is the volumetric flow rate of the gas source, ^^^ா^,்is the volume source termrelated to liquid expansion due to temperature variation, ^^^ா^,ௌ is the volume sourceterm related to the gas expansion, ^^^^^^௩ is the volume source term related to pressurevariation due to fluid convection, and ^^^is the volumetric flow rate at the outlet boundary.PATENT Attorney Docket No.: UTXA / 8328PC
[0061] A heat resistance network is used to model the radial heat transfer. The RDFM makes the following assumptions with respect to heat transferred: 1. Heat will transfer between the drill string and the annulus fluids by convection in the drill string, conduction through the drill pipe (DP) and convection in the annulus. 2. Heat will transfer between the annulus fluid and the formation of the cased zone by convection in the annulus fluid, conduction through the casing, and conduction through the cement. 3. Heat will transfer between the annulus fluid and the formation in the open hole section by convection in the annulus.
[0062] The formation temperature around the well will change during simulations due to heat transfer between the fluid and the formation. The rock formation is discretized radially at each cell to get the radial distribution of temperature and heat conduction adjacent to the wellbore. Only radial heat conduction in the formation is considered because heat exchange in the axial direction is negligible.
[0063] To solve for the temperature dynamics, the mixture energy conservation equation, shown in Eq.4, is used. ^^^^௧is the rate of heat transfer through the walls per unit volume, Γ^,^^^is the rate of total enthalpy generation from all sources per unit volume, and ^^^^^௧is the rate of heat generation at the bit per unit volume. Eqs.5 and 6 describe the energy per unit mass and enthalpy per unit mass that is used in the energy conservation equation, respectively. ^^௩is the specific heat capacity at constant volume, ^^ is temperature, ^^ is gravitational acceleration, ^^ is vertical position, ^^ is energy per unit mass, ^^ is pressure, and ^^ is density. Eqs.7 and 8 describe the rate of heat transfer flowing into the drill string and annulus, respectively. ^^^,^௨௧is the temperature of the medium outside the annulus, ^^^,ௗ^is the temperature of the drill string medium, ^^^௨௧^^is the thermal resistance in the outer surface of the drill string / annulus, ^^^,^^is the temperature of the medium inside the annulus, ^^^,^^^is the temperature of the annulus medium, and ^^^^^^^is the thermal resistance of the inner surface of the annulus.PATENT Attorney Docket No.: UTXA / 8328PC
[0064] Eqs. (9) and (10) describe the liquid and gas propagation dynamics used in the RDFM. Γ^,^is the rate of liquid mass generation per unit volume and Γ^,^is the rate of gas mass generation per unit volume. They are each solved separately for liquid / gas fractions and equivalent density of a dissolved gas.
[0065] In addition to the pressure, temperature, and liquid and gas propagation dynamics, Eqs.11-15 show the closure conditions calculated in the model. Eqs.11 and 12 represent liquid and gas density models that calculate density as a function of the pressure and temperature. For regions with free and dissolved gas, Eq. 13 represents that equivalent dissolved gas density also calculated using pressure and temperature. Eqs. 14 and 15 represent the gas and liquid velocity distribution equations. ^^ is the volume fraction, ^^ௗis the drift velocity, and ^^^is the distribution parameter.PATENT Attorney Docket No.: UTXA / 8328PC
[0066] The RDFM uses a first-order upwind scheme in space and explicit Euler method in time. Figure 3 shows the numerical procedure used in the model. When solving the differential equations in Eqs.2, 4, 9, and 10, the explicit Euler method is applied. This allows any differential equation in the form of Eq.16 to be discretized in the form of Eq.17 where ∅ is some physical quantity. The partial differential equations in Eqs.4, 9, and 10 are solved using the form of Eq.17. In each node of the discretized grid.
[0067] In some embodiments, the controller 410 is used to control the well’s bottomhole temperature. In one embodiment, the controller 410 is a feedforward proportional, integral, derivative (PID) controller. Figure 4 shows the control scheme of the controller 410, according to some embodiments. In one example, based on field parameters or steady state conditions, the user inputs the desired bottomhole temperature (Tbh,max). The difference between the bottomhole temperature and the input temperature value is calculated as the error that is then fed to the PID block. The PID block, adjusted by the tuned gains, produces an input for the plant (uPID) that gets summed with the feedforward control signal to become the total input for the plant. In some embodiments, the feedforward value is determined using the RDFM.PATENT Attorney Docket No.: UTXA / 8328PC
[0068] Because the control scheme does not specify what the input is within the drilling system, any parameter that influences the bottomhole temperature may be used. In some examples, the surface inlet temperature and the pump flow rate are used as inputs for the controller 410. Additionally, the feedforward input is the steady state value of the specified input (e.g., surface inlet temperature or pump flow rate) prior to any changes occurring in the drilling system thermal dynamics or pressure dynamics. In this respect, the input is allowed to transmit steadily based on the controller’s steady state value without significant overshoot or instability. In some embodiments, the controller 410 is set to turn on only when the bottomhole temperature is greater than the desired bottomhole temperature. In this respect, the bottomhole temperature is not increased to compensate for errors from the bottomhole temperature being lower than the desired output.
[0069] In another embodiment, the Reduced Drift-Flux Model (RDFM), system identification techniques, and control algorithms are unified into a coupled MPD-MTD framework. In some embodiments, system identification techniques are beneficially employed to derive an effective control model that accurately represents the coupled pressure and temperature dynamics in drilling systems. In particular, the temperature dynamics, interface mass transfer, and improved pressure dynamics are integrated to identify the transfer function between mud inlet temperature, pump flow rate, choke opening, and the bottomhole pressure (BHP) and / or the bottomhole circulating temperature (BHCT), forming a control-oriented reduced-order model.
[0070] In some embodiments, the present disclosure provides methods of predicting and managing of bottomhole conditions in elevated temperature and pressure environments. In some embodiments, the present disclosure provides a multi-input-multi-output (MIMO) control method and system for simultaneous regulating the downhole pressure and temperature in real time, while addressing the complex interactions present in geothermal and HPHT wells. Mud inlet temperature and mud pump rate or mud pump rate and choke opening are selected as the control input to control one or both of the downhole temperature and pressure.PATENT Attorney Docket No.: UTXA / 8328PC
[0071] System identification is beneficial for understanding a system’s dynamic behavior and subsequently informing the design of its controller. For any dynamic systems, the model is given in the frequency domain byOr in the time domainwhere ^^^^^^is the response variable—such as the BHP or BHCT in this context. And ^^^^^^ is the control variable, which may be mud pump rate ^^, mud inlet temperature^^^^, or choke opening. Here, ^^^^^^^^^denotes the k:th derivative of ^^^^^^with respect totime, and ^^^^^^^^^ denotes the k:th derivative of ^^^^^^ with respect to time. The model coefficients can be calculated via a least-squares approach, given by
[0072] Using this technique, transfer functions from control variables to the response variables are identified. Figures 14 to 16 compare the original system with the identified system where the control variables are mud pump rate, mud inlet temperature and choke opening, respectively. Figure 14 shows the system identification results from the control input of mud pump rate. The mud pump rate (left panel) remains at 400 gpm, then increases to 600 gpm at 500 minutes. The middle panel shows bottomhole pressure, and the right panel shows the bottomhole circulation temperature, with observed simulation data compared against identification results.
[0073] Figure 15 shows the system identification results from the control input of mud inlet temperature. The mud inlet temperature remains at 77 °F, then increases to 120 °F at 500 minutes. The middle panel shows bottomhole pressure, and the rightPATENT Attorney Docket No.: UTXA / 8328PC panel shows the bottomhole circulation temperature, with observed simulation data compared against identification results.
[0074] Figure 16 shows the system identification results from the control input of choke opening. The choke opening (left panel) remains at 0.3, then increases to 0.5 at 500 minutes. The right panel shows BHP, with observed simulation data compared against identification results.
[0075] In some embodiments, Proportional-Integral (PI) controllers are utilized in the system. Specifically, PI controllers ^^^^are designed for each identified transfer function ^^^^. When mud pump rate and mud inlet temperature are employed as control variables, the MIMO control diagram of the MIMO controller is presented in Figure 17.
[0076] The calculation of control variables is shown in Equation 24
[0077] To highlight the effectiveness of the coupled controller, it is compared with two SISO controllers, where the off-diagonal entries in the controller ^^^^are set to 0. This configuration implies that the control variable ^^^^is solely regulated by BHCT, while ^^ is exclusively controlled by BHP, as depicted in Figure 18. Figure 18 shows an exemplary embodiment of a MIMO control diagram of the decoupled controllers. In some embodiments, the choke is preferable for controlling BHP. In some embodiments, similar MIMO and SISO control algorithm is adopted when choke opening and mud pump rate are the control variables.
[0078] Examples and Discussion
[0079] The open-source Utah FORGE geothermal well data is used to validate the RDFM for geothermal temperature simulation and estimation. Specifically, well 16A78- 32 (Utah Forge Data, 2022) was selected due to the availability of downhole sensor data. Two bottomhole assembly (BHA) sections (the 9thand the 18th) were selected for simulation because of their stable sensor data readings. Tables 1 to 3 list thePATENT Attorney Docket No.: UTXA / 8328PC drilling fluid properties, formation geothermal properties, and wellbore configuration used in both BHA 9 and 18 for model validation.
[0080] Table 1. Drilling fluid properties for Utah FORGE 16A78-32 well. Drilling Fluid Properties BHA BHA 9 18 Fluid density (ppg) 9 8.9 Fluid plastic viscosity 27151 41771 (lbf*s / 100ft2) Specific heat capacity (BTU / (lb*F))Thermal conductivity 2 5.200 5.200 ((BTU*in) / (hr*ft*F))
[0081] Table 2. Formation geothermal properties for Utah FORGE 16A78-32 well. Formation Geothermal BHA BHA Properties 9 18 Formation surface temperature 67.85 67.85 (F) Formation temperature gradient(F / ft) Rock density (ppg) 23.367 23.367 Formation specific heat capacity(BTU / (lb*F)) Formation thermal conductivity 2 16.016 16.016 ((BTU*in) / (hr*ft *F)
[0082] Table 3. Wellbore configuration for Utah FORGE 16A78-32 well. Wellbore BHA 9 BHA 18 Configuration Wellbore depth (ft) 5900-6300 Wellbore inclination 0 0-0.756 (deg)
[0083] After inputting all the parameters for simulation into the RDFM and fine- tuning the model, Figures 5 and 6 compare the bottomhole temperature and the outletPATENT Attorney Docket No.: UTXA / 8328PC temperatures for BHA 9 and BHA 18, respectively. The mean average percentage error (MAPE) is calculated for both outputs for each well to assess the accuracy. For BHA 9, the bottomhole circulating temperature had a MAPE of 0.5814 and the outlet temperature had a MAPE of 1.6875 compared to field results. Comparing BHA 18’s results with field data results in a MAPE of 0.6280 for the bottomhole circulating temperature and a MAPE of 1.4033 for the outlet temperature. Since all the errors are well below 5 percent, the RDFM used in this study was deemed reliable for bottomhole temperature and outlet temperature estimation and control for geothermal wells.
[0084] RDFM is also effective in estimating the bottomhole temperature, which make it suitable for use in a temperature controller. Figure 7 shows results comparing the simulation using the DFM and the RDFM at the same time step size of 0.0525 sec. Despite having a slight variance in the bottomhole temperature estimation during the transient phase, both models converge to nearly identical results at steady state. This observation affirms the RDFM’s accuracy, making it an effective tool for bottomhole temperature control.
[0085] The primary advantage of using the RDFM over the conventional drift-flux model (DFM) is its computational efficiency combined with increased stability. To demonstrate this, simulations were run for both models using the same computer and input parameters. Table 4 provides a side-by-side comparison between the DFM and the RDFM simulation time, focusing on the Utah FORGE 16A78-32 well at 5,900 ft. All simulations were run on a laptop with an 11th Gen Intel Core i7 processor @3.00GHz.When comparing the DFM and RDFM for simulations with small time steps (e.g., 0.02 and 0.0525 sec), the RDFM took longer. In this particular case, the simulations for the RDFM are about 3 times longer than the DFM. However, RDFM i9s stable enough to achieve a similar accuracy with a larger time step, which gives it an overall better computation efficiency
[0086] Despite its simplicity and the no pressure wave assumption, the increase in computation time for the RDFM is primarily due to the increased number of parameters to solve for (i.e., ^^^ா^,ௌand Γௗ) during each iteration. However, with respect to the chosen well configuration, and using the recommended time steps based on the Courant Friedrichs-Lewy (CFL) condition, the RDFM show greater numerical stabilityPATENT Attorney Docket No.: UTXA / 8328PC than the DFM, allowing for faster computation times. The RDFM proves particularly beneficial for real-time temperature control scenarios, achieving computation times up to 8.6 times faster than the DFM’s fastest time step.
[0087] Table 4. Computational time comparison for simulations running Utah FORGE 16A78-32 at 5900ft. Time step DFM RDFM (sec) (min) (min)0.0525 14.7 41.6 1 unstable 4.2 5 unstable 3.8 10 unstable 2.3 100 unstable 2.1 1000 unstable 1.9 10000 unstable 1.7
[0088] Temperature Control Examples and Discussion
[0089] The following control examples are designed to demonstrate the utility of the bottomhole temperature controller: 1. A mud cooler malfunction, increasing inlet temperature; 2. A pump failure leading to a decrease in inlet flowrate; 3. The well encounters a pressurized thermal reservoir filled with hot water; 4. Pipe insulation failure leading to an increase in drill string thermal conductivity.
[0090] The open-source Utah FORGE geothermal well data is used to test the MIMO controller for geothermal temperature simulation and control (Utah Forge Data, 2022). Again, Table 1 and Table 2 list the drilling fluid properties and formation geothermal properties.PATENT Attorney Docket No.: UTXA / 8328PC
[0091] All control examples lead to an elevation in observed bottomhole temperature above the temperature of 300 °F, which would cause failure for downhole tools rated for 300 °F. The controller is used to reduce the bottomhole temperature to an operable 290 °F by adjusting the inlet flowrate or surface inlet temperature. The control examples will use the Utah FORGE 16A78-32 well at 9,700 ft. Sudden changes will be introduced when the well reaches steady state at 500 minutes into the simulation. The results of these control examples assume a cooler mud supply is readily available and serves as a general guideline for managed temperature drilling operations.
[0092] In the first control example, the simulation emulates a mud cooler malfunction resulting in a higher surface inlet temperature. Specifically, the inlet temperature shifts suddenly from 120 °F to 160 °F. The simulation results for the control scenario are shown in Figure 8. After 350 minutes of the mud cooler malfunction, the controller is able to successfully maintain a bottomhole temperature of 290 °F by increasing the flow rate (Q) from 400 gpm to 550 gpm. It is contemplated that, in addition to or in the alternative, the controller 410 can adjust the fluid composition, such as adjusting its viscosity.
[0093] The second control example simulates a pump failure on the surface leading to half the inlet flow rate. Figure 9 shows the results for the simulated control scenario. After the initial transient behavior, the inlet surface temperature reaches its steady state value at 800 min into the simulation (going from 120 °F to 55.7 °F). After reaching the steady state value, the temperature controller reduces the bottomhole temperature to the desired output (314 °F in the base case versus 297 °F when using the controller).
[0094] In the third control example, a pressurized water kick enters the bottom of the well 500 minutes into the simulation. In this example, the controller responds by controlling the flow rate and inlet temperature independently. Figures 10-11 show the kick entering at a flow rate of 10 gpm and being controlled by the flow rate and inlet temperature, respectively. The kick is assumed to be the same temperature as the surrounding formation at the injection point and consist entirely of water. The effect of this sudden change increases the bottomhole temperature from 292.4 °F to 308.9 °F. The flow controller reduces the bottomhole temperature to 286.1 °F by increasing thePATENT Attorney Docket No.: UTXA / 8328PC flow rate from 400 gpm to 550 gpm. The inlet temperature controller reduces the bottomhole temperature to 294.9 °F by decreasing the inlet temperature from 120 °F to 76.5 °F. The steady state value for the flow controller occurs in 300 minutes after the initial injection time whereas the inlet temperature controller reaches steady state in 100 minutes.
[0095] In the fourth control example, the model simulates an insulated drill pipe experiencing a sudden increase in thermal conductivity due to flaking of all the insulation material in the drill string. Figures 12-13 show the simulation results where the thermal conductivity increases from 4.585 BTU / (h*ft*°F) to 26.017 BTU / (h*ft*°F) for a flow and inlet temperature controller, respectively. The insulated coating is assumed to be 0.02 in. thick and have a thermal conductivity of 0.116 BTU / (h*ft*°F). By increasing the thermal conductivity of the drill string, the mud coming from the inlet heats up to a higher bottomhole temperature before reaching the annulus. In this example, the bottomhole temperature increases from 264.0 °F to 301.4 °F as a result of pipe insulation flaking. To compensate for this change, the controller changes the flow rate from 400 gpm to 557.5 gpm, which drops the bottomhole temperature to 280.8 °F. For the inlet temperature controller, the input is changed from 120 °F to 93.9 °F which drops the bottomhole temperature to 292.6 °F. The steady state value is achieved in about 200 minutes for the flow controller and 50 minutes for the temperature controller.
[0096] Examples and Discussion of MIMO controller
[0097] Control Examples: Using Both Mud inlet temperature and Mud Pump Rate as Control Variables
[0098] In this example, the mud pump rate and mud inlet temperature are set to 400 gpm and 120 °F, respectively. By 200 minutes, the system reaches a steady state, and the controller is activated. The target pressure starts from its steady-state value prior to 200 minutes and increases by 80 psi over 10 minutes. The target temperature decreases by 40 °F during the same period. The control variables and corresponding response variables are depicted in Figure 19.PATENT Attorney Docket No.: UTXA / 8328PC
[0099] It can be observed that the MIMO controller and the SISO controller perform similarly in regulating the BHCT. However, when controlling the BHP, the MIMO controller exhibits noticeable oscillations. These oscillations result from an overshoot in the mud pump rate, which is caused by the slow response of the BHCT. Furthermore, the MIMO controller demonstrates an undesirable spike in the mud temperature at inlet, occurring because the pressure responds so rapidly that it exceeds the target pressure.
[0100] In contrast, the SISO controller effectively regulates both the BHP and BHCT without oscillations or overshoot. This improved performance is attributed to the inherent differences in the natural frequencies of the two processes, which the SISO controller manages more effectively by eliminating cross-influences.
[0101] Thus, in this scenario, the SISO controller outperforms the coupled controller by avoiding cross-coupling effects and delivering more stable control.
[0102] Control Examples: Using Both Choke Opening and Mud Pump Rate as Control Variables
[0103] In this example, the mud pump rate and choke opening are set to 400 gpm and 0.3, respectively. By 200 minutes, the system reaches a steady state, and the controller is activated. The target pressure starts from its steady-state value prior to 200 minutes and decreases by 30 psi over 10 minutes, while the target temperature decreases by 10 °F during the same period. The mud pump mud inlet temperature is set to be 77 °F during the whole process. The control variables and corresponding response variables are depicted in Figure 20.
[0104] In can be observed he MIMO controller achieves a slightly shorter settling time in regulating BHCT compared to the SISO controller. Additionally, it demonstrates superior performance in controlling BHP, with a shorter settling time and reduced overshoot. Moreover, the MIMO controller ensures smoother operation by minimizing variations in control variables, such as choke opening and mud pump rate. Therefore, the MIMO controller outperforms the SISO controller in this example, delivering more efficient and stable control.
[0105] Pipe Insulation Coating Loss EvaluationPATENT Attorney Docket No.: UTXA / 8328PC
[0106] In some embodiments, the present disclosure provides methods of determining the condition of the insulation coating during drilling. The bottomhole circulating temperature (BHCT) and the surface temperature are functions of the DP apparent radial thermal conductivity ^^^^^. In some examples, the apparent radial thermal conductivity ^^^^^is calculated via simulation. For example, the ^^^^^is assumed and the downhole temperature is simulated until steady state to get the BHCT. Then the BHCT at different assumed ^^^^^is calculated, and the BHCT-^^^^^curve is plotted.
[0107] Also, the cross-section of the DP is a circular ring. Assuming the coating has a uniform thickness, the cross-section of the coating is also a circular ring. The ^^^^^of the DP-coating system can be represented by equation (25):where ^^^^and ^^^௨௧are the inner and outer radii of the corresponding layer, ^^ is the unit length, ^^ is the thermal conductivity, subscript ^^^^^^^^^^^^^^ refers to the coating layer, and subscript ^^^^ refers to the steel part of the DP.
[0108] There are two typical damage modes for the coating, peeling and thinning. Peeling occurs when part of the coating peels off the DP while the remaining coating keeps the thickness. Thinning occurs when the coating is worn out uniformly. If peeling is the dominant coating damage mode, ^^^^^is a function of the ratio of the remaining coating, ^^, and the thermal conductivity of the drill pipe and the coating.where ^^^^^^^^௧is the apparent radial thermal conductivity when there is no coating damage, and ^^^௧^^^is the thermal conductivity of steel / non-coated DP.PATENT Attorney Docket No.: UTXA / 8328PC
[0109] If thinning is the dominant coating damage mode, the remaining ratio of coating thickness, ^^ can be determined. First, the inner radius of the coating can be represented by:where ^^^^^௧^^^is the initial thickness of the coating.
[0110] Substituting Eq. (28) into Eq. (25) and expanding the log terms, Eq. (25) becomes:
[0111] Eq. (29) can be rearranged to obtain the below.
[0112] The ^^^^^of the DP-coating system can be plotted against the BHCT. The ^^^^^can then be easily looked up from the curve using the measured BHCT. In some embodiments, Eq. (27) and Eq. (31) can also be plotted for easy reference.
[0113] By monitoring and extrapolating how ^^ and ^^ decrease during drilling, the remaining lifespan of the insulation coating can be estimated.
[0114] Examples
[0115] The examples use a representative L-shape horizontal well in the Haynesville basin. The well trajectory is shown in Figure 21. Its true vertical depthPATENT Attorney Docket No.: UTXA / 8328PC (TVD) is 12,000 ft and the formation temperature at 12,000 ft is 385 F. A coating is painted on the inner surface of the 4.5” DP for insulation purpose.
[0116] The well is modeled using the advanced hydraulics software developed by van Oort et al., which model is incorporated herein by reference in its entirety. (Fallah, 2021; Khaled et al., 2023; Wang et al., 2023). The DP is modeled as a uniform material of ^^^^^which is calculated from Eq.25.
[0117] In this example, at measured depth (MD) 19,000 ft, which is in the middle of the lateral section, the BHCT at different ^^^^^is modeled and simulated. The BHCT and mud temperature at outlet are plotted in Figure 22. According to Figure 22, BHCT can be significantly decreased by as much as 100 F if ^^^^^is sufficiently low. When the normalized ^^^^^grows to about 30%, the BHCT is almost as high as that of using non-insulated DP. In the field, the BHCT can be measured and ^^^^^can then be looked up using Figure 22.
[0118] Figure 23 shows the ^^^^^-^^ curve calculated from Eq.27. The ^^^^^grows linearly as ^^ drops. To achieve a normalized ^^^^^of above 30%, the remaining coatingarea ratio required is ^^ ^ 70%. Assuming peeling is the dominant damage mode ofthis DP, if the measured BHCT is 300 F, Figure 22 is used to get ^^^^^ ൌ 0.1, and Figure23 is used to get ^^ ൌ 0.9. By calculating ^^ at different measured depths, the speed ofcoating damage can be calculated, and the remaining lifespan of the coating can be determined.
[0119] Figure 24 shows the ^^^^^-^^ curve calculated from Eq.30. The ^^^^^grows nonlinearly as ^^ drops. To achieve a normalized ^^^^^of above 30%, the requiredremaining coating thickness ratio ^^ ^ 18%. Assuming thinning is the dominantdamage mode of this DP, if the measured BHCT is 300 F, we look up Figure 22 to get^^^^^ ൌ 0.1, and look up Figure 24 to get ^^ ൌ 0.7. By calculating ^^ at different MD, thespeed of coating damage can be calculated, and the remaining lifespan of the coating can be estimated.
[0120] In this manner, embodiments of the present disclosure provides methods of online determination of the DP insulation coating without pull-out-of-hole. Based onPATENT Attorney Docket No.: UTXA / 8328PC the calculated coating damage speed and remaining coating lifespan, the driller can better plan the maintenance schedule of the DP and decide when to switch to a new set of DPs.
[0121] If the insulation coating is damaged, the mud flowing through the DP receives excessive heat and may not sufficiently cool the bottom hole area. The BHCT is increased and may lead to BHA’s accelerated aging or even sudden failure.
[0122] Embodiments of the present disclosure beneficially provides methods and procedures to determine the insulation coating of insulated DP in real-time. Although drill pipe is disclosed, embodiments of the present disclosure are equally application to other suitable tubulars, such as casing, tubing, and the like.
[0123] Globally scaled use of geothermal wells for sustainable energy generation has been limited due to high drilling costs. By better controlling the bottomhole temperature, downhole tools can remain in their operating conditions without any permanent damage, reducing costs and NPT during the construction of geothermal wells.
[0124] Embodiments of the present disclosure provides an improved reduced drift- flux model (RDFM) for controlling bottomhole temperature. The RDFM improves simulation accuracy by including temperature dynamics and interface mass transfer. Because of its more robust numerical scheme, the model is able to handle much larger time steps than the traditional drift-flux model without becoming unstable, enabling it to be used in a real-time bottomhole temperature controller.
[0125] In any of the embodiments described herein, the controller may be a feedforward and / or classical feedback controller, such as proportional integral derivative (PID) controller, lead / lag compensator, and feedback regulator (such as LQR, LQI, LQG controllers), or any other suitable controller. In some embodiments, the controller is a multi-input multi-output controller, a single-input, single-output controller, or a decentralized controller.
[0126] Four control examples were simulated to demonstrate the utility of using the RDFM as a bottomhole temperature controller for geothermal wells. All control examples that used the surface inlet temperature or flow rate as an input successfullyPATENT Attorney Docket No.: UTXA / 8328PC achieved the desired bottomhole temperature with limited overshooting. It was found that the controller using the inlet temperature as an input was able to reach its steady state value faster than the flow rate controller.
[0127] Embodiments of the present disclosure provides a novel coupled Managed Pressure and Temperature Drilling (MPD-MTD) controller using a MIMO control framework for combined and automated temperature and pressure management in geothermal and high-pressure, high-temperature (HPHT) wells. The MPD-MTD controller leverages an improved reduced drift-flux model (RDFM) with enhanced pressure and temperature dynamics, thereby offering excellent computational efficiency and accuracy for real-time control in extreme drilling environments. The MPD-MTD approach enhances operational reliability, optimizes drilling performance, and mitigates thermal and pressure-related challenges such as temperature-induced downhole tool failures.
[0128] A method of controlling a temperature of a wellbore includes supplying a wellbore fluid into the wellbore and measuring the temperature of the wellbore fluid. The measured temperature is compared to a predetermined downhole temperature. The method also includes determining, using a controller, an operational adjustment to a drilling parameter; and adjusting the drilling parameter to modify the downhole temperature. In one embodiment, the downhole temperature is managed in real time.
[0129] In some embodiments, the drilling parameter is one of an inlet temperature of the wellbore fluid, an inlet flow rate of the wellbore fluid, an opening of a choke valve, or combinations thereof.
[0130] In some embodiments, the method is performed in real time.
[0131] In some embodiments, the wellbore fluid comprises drilling fluid.
[0132] In some embodiments, the controller comprises a feedforward and / or a feedback controller, such as proportional integral derivative (PID) controller, lead / lag compensator, and feedback regulator.
[0133] In some embodiments, the controller determines the operational adjustment using a reduced drift-flux model.PATENT Attorney Docket No.: UTXA / 8328PC
[0134] In some embodiments, in response to an increase in the downhole temperature caused by an increase in the inlet temperature, the downhole temperature is adjusted by increasing the inlet flow rate.
[0135] In some embodiments, in response to an increase in the downhole temperature caused by a decrease in the inlet flow rate, the downhole temperature is adjusted by decreasing the inlet temperature.
[0136] In some embodiments, in response to an increase in the downhole temperature caused by an increase of formation fluid flowing into the wellbore, the downhole temperature is adjusted by increasing the inlet flow rate, decreasing the inlet temperature, or both.
[0137] In some embodiments, in response to an increase in the downhole temperature caused by an increase in thermal conductivity of a drill string, the downhole temperature is adjusted by increasing the inlet flow rate, decreasing the inlet temperature, or both.
[0138] In some embodiments, the method is performed during a drilling operation.
[0139] In some embodiments, the downhole temperature is adjusted until it is within 10% of the predetermined downhole temperature.
[0140] In some embodiments, the controller comprises a multi-input multi-output controller or a single-input, single-output controller, or a decentralized controller.
[0141] In some embodiments, the controller determines the operational adjustment using a system identification technique.
[0142] In some embodiments, the method includes measuring a downhole pressure and comparing the downhole pressure to a predetermined downhole pressure.
[0143] In some embodiments, the method includes determining, using the controller, an operational adjustment to a second drilling parameter.PATENT Attorney Docket No.: UTXA / 8328PC
[0144] In some embodiments, the second drilling parameter is one of an inlet temperature of the wellbore fluid, an inlet flow rate of the wellbore fluid, an opening of a choke valve, or combinations thereof.
[0145] In some embodiments, the drilling parameter is adjusted only if the downhole temperature is greater than the predetermined downhole temperature.
[0146] In some embodiments, the method includes determining a condition of a coating on a tubular.
[0147] In some embodiments, determining the condition of the coating includes determining a bottomhole circulation temperature; determining an apparent radial thermal conductivity ^^^^^; and monitoring changes to a ratio of the remaining coating, a remaining ratio of coating thickness, or both.
[0148] In some embodiments, the method includes determining the condition of the coating is caused by a peeling effect or a thinning effect.
[0149] In some embodiments, the downhole condition causes an increase in the downhole temperature.
[0150] In some embodiments, the downhole temperature is the bottomhole circulating temperature.
[0151] In some embodiments, the measured temperature is the downhole temperature.
[0152] It is contemplated that any one or more elements or features of any one disclosed embodiment or example may be beneficially incorporated in any one or more other non-mutually exclusive embodiments or examples. While the foregoing is directed to embodiments of the present disclosure, other and further embodiments of the disclosure may be devised without departing from the basic scope thereof, and the scope thereof is determined by the claims that follow.
Claims
PATENT Attorney Docket No.: UTXA / 8328PC What is claimed is:
1. A method of controlling a temperature of a wellbore, comprising: supplying a wellbore fluid into the wellbore; measuring the temperature of the wellbore fluid; comparing the measured temperature to a predetermined downhole temperature; determining, using a controller, an operational adjustment to a drilling parameter; and adjusting the drilling parameter to modify the downhole temperature.
2. The method of claim 1, wherein the drilling parameter is one of an inlet temperature of the wellbore fluid, an inlet flow rate of the wellbore fluid, an opening of a choke valve, or combinations thereof.
3. The method of claim 1, wherein the method is performed in real time.
4. The method of claim 1, wherein the wellbore fluid comprises drilling fluid.
5. The method of claim 1, wherein the controller comprises a feedforward and / or a feedback controller, such as proportional integral derivative (PID) controller, lead / lag compensator, and feedback regulator.
6. The method of claim 1, wherein the controller determines the operational adjustment using a reduced drift-flux model.
7. The method of claim 1, wherein in response to an increase in the downhole temperature caused by an increase in the inlet temperature, the downhole temperature is adjusted by increasing the inlet flow rate.
8. The method of claim 1, wherein in response to an increase in the downhole temperature caused by a decrease in the inlet flow rate, the downhole temperature is adjusted by decreasing the inlet temperature.PATENT Attorney Docket No.: UTXA / 8328PC 9. The method of claim 1, wherein in response to an increase in the downhole temperature caused by an increase of formation fluid flowing into the wellbore, the downhole temperature is adjusted by: increasing the inlet flow rate; decreasing the inlet temperature; or both.
10. The method of claim 1, wherein in response to an increase in the downhole temperature caused by an increase in thermal conductivity of a drill string, the downhole temperature is adjusted by: increasing the inlet flow rate; decreasing the inlet temperature; or both.
11. The method of claim 1, wherein the method is performed during a drilling operation.
12. The method of claim 1, wherein the downhole temperature is adjusted until it is within 10% of the predetermined downhole temperature.
13. The method of claim 1, wherein the controller comprises a multi-input multi- output controller or a single-input, single-output controller, or a decentralized controller.
14. The method of claim 1, wherein the controller determines the operational adjustment using a system identification technique.
15. The method of claim 1, further comprising measuring a downhole pressure and comparing the downhole pressure to a predetermined downhole pressure.
16. The method of claim 15, further comprising determining, using the controller, an operational adjustment to a second drilling parameter.PATENT Attorney Docket No.: UTXA / 8328PC 17. The method of claim 15, wherein the second drilling parameter is one of an inlet temperature of the wellbore fluid, an inlet flow rate of the wellbore fluid, an opening of a choke valve, or combinations thereof.
18. The method of claim 1, wherein the drilling parameter is adjusted only if the downhole temperature is greater than the predetermined downhole temperature.
19. The method of claim 1, further comprising determining a condition of a coating on a tubular.
20. The method of claim 19, wherein determining the condition of the coating comprises: determining a bottomhole circulation temperature; determining an apparent radial thermal conductivity ^^^^^; and monitoring changes to a ratio of the remaining coating, a remaining ratio of coating thickness, or both.
21. The method of claim 19, further comprising determining the condition of the coating is caused by a peeling effect or a thinning effect.
22. The method of claim 19, wherein downhole condition causes an increase in the downhole temperature.
23. A non-transitory computer-readable medium storing instructions that, when executed on a processor, perform operations for controlling a temperature of a wellbore, the operations comprising: supplying a wellbore fluid into the wellbore; measuring the temperature of the wellbore fluid; comparing the measured temperature to a predetermined downhole temperature; determining, using a controller, an operational adjustment to a drilling parameter; andPATENT Attorney Docket No.: UTXA / 8328PC adjusting the drilling parameter to modify the downhole temperature.
24. The non-transitory computer-readable medium of claim 23, wherein the drilling parameter is one of an inlet temperature of the wellbore fluid, an inlet flow rate of the wellbore fluid, an opening of a choke valve, or combinations thereof.
25. The non-transitory computer-readable medium of claim 23, wherein the operations are performed in real time.
26. The non-transitory computer-readable medium of claim 23, wherein the operations are performed during a drilling operation.
27. The non-transitory computer-readable medium of claim 23, wherein the operations further comprise measuring a downhole pressure and comparing the downhole pressure to a predetermined downhole pressure.
28. The non-transitory computer-readable medium of claim 33, wherein the operations further comprise determining, using the controller, an operational adjustment to a second drilling parameter.
29. The non-transitory computer-readable medium of claim 23, wherein the controller comprises a feedforward and / or a feedback controller, such as proportional integral derivative (PID) controller, lead / lag compensator, and feedback regulator.
30. The non-transitory computer-readable medium of claim 23, wherein the controller determines the operational adjustment using a reduced drift-flux model.