Summary
Automation and digitalization of drilling require shared knowledge about the state of the drilling process: Is the bit on-bottom drilling or is the string in-slips; is there an overpull or is there a formation fluid influx? The research question addressed here is whether it is possible to define clear, sharable, and usable definitions of what a drilling process state is, and an agreed method to calculate it. The method to define the drilling process state originates from the fact that a drilling operation can be described by a set of partial differential equations, respecting boundary conditions. Therefore, the set of possible discrete changes of boundary conditions defines the set of all possible drilling process states. The possible state values for each of these boundary conditions can be clearly defined by a set of logical expressions utilizing boundary values at the partial differential equations. Each boundary condition is called a microstate. If the set of microstates is linearly independent and complete, then the overall state of the drilling process is uniquely described by the state of each of the microstates. The boundary values are either measured or estimated using a digital twin of the drilling process. In either case, an uncertainty is associated with the boundary value. It is therefore possible to estimate the probability of being in one state or another for each of the microstates. This is an important property as often the actual state of the drilling process is uncertain. If several digital twins or measurements are available, it is also possible to use sensor fusion to update the uncertainty of the boundary value. A common drilling process interpretation engine and well-defined drilling process states may help with the coordination of multiple advisors participating in the control of the drilling process. An example is given showing how an event-based drill-a-stand procedure involving several external advisors is automatically executed using a common source for the interpretation of the drilling process state. A shared definition and method of calculation of the drilling process state is a fundamental element of an infrastructure to enable interoperability at the rigsite. This work is part of the Drilling and Wells Interoperability Standard (D-WIS) initiative. D-WIS is a cross-industry work group providing the industry with solutions facilitating interoperability of computer systems at the rigsite.
Introduction
The drilling industry, and other industries, use the concept of “state” across many operations and scales. For example, equipment state refers to the current condition of the rig machines (starting, running, stopping, and stopped) are all viable equipment states of a generic rig machine. Fig. 1 shows a machine states graph based on the International Society of Automation’s (ISA) batch control standard (ISA-88 1995). The International Association of Drilling Contractors Daily Drilling Report (DDR) and DDR print and electronic system codes (Shackleton et al. 2020), often referred to as rig activity codes, define the operational states of a drilling rig. They address common rig operations, such as drilling, reaming, and coring, and common rig activities, such as pickup, lay-down, and connection. These codes were primarily used for manual reporting, and recent papers have focused on the natural language processing of these digitized reports (Ucherek et al. 2020) to improve usability (and standardization).
Deployment of computers at the wellsite for mud logging led to their use in monitoring drilling operations, and, because drilling is a noncontinuous operation, it was necessary to detect the “status” of the operation. Examples of this are the automatic detection of connections while drilling, or of breaking and making connections during tripping. These features were added to commercial monitoring software at the wellsite in the late 1970s, and their use in analysis software is documented by Parigot and Havrevold (1988) and Schenato et al. (1991).
The use of computers to monitor rig states for key performance indicators has led to the inferencing of states—or more correctly, changes in rig states—by algorithms (see, e.g., Svensson et al. 2016). Inferencing refers to the ability to conclude the current “state” using measurements and logic. The purpose of these states is to calculate statistics for human consumption: How fast does the rig make a connection? They have played a significant role in identifying and tracking nonproductive-time and invisible-lost-time for better management of assets.
With the advent of system automation, there has been work on possible grouping of states, such as automation state, well state, and environment state (de Wardt et al. 2015), to bring focus on various aspects of the system. With the work of the industry group on D-WIS, an understanding of the need for inferring the drilling process state has emerged. Essentially, in this construct, there are several software advisors running externally to the rig and specifying set points and limits for the rig equipment (see Fig. 2 ).
The D-WIS architecture is inspired by the “Blackboard” software architecture (Erman et al. 1980). In such an architectural model, a drilling data hub (Blackboard in short) is the place where components of the architecture exchange information. To facilitate the understanding of the information that is published on the Blackboard, data are accompanied with semantical descriptions in the form of a semantic network, that is, a concept introduced in the 1950s as an interlingua for communication with computer systems (Lehmann 1992). With such an architecture, the different components of the architecture query the Blackboard for information that can be relevant for their task by posting semantical queries and then pushing back the results to the Blackboard together with the semantic description of the new piece of information.
External data sources, such as data acquisition systems (abbreviated as DAQ in Fig. 2 ), contextual data sources, and advisors, publish information on the Blackboard. A contextual data builder reads the published planning and configuration data (the well reference data) and publishes a consolidated well and section plan, as well as a current context description. A scheduler reads the consolidated well and section plans and schedules actions that it publishes back on the Blackboard. These actions make use of functionalities made available by the automated drilling control system (ADCS). In fact, the ADCS publishes on the Blackboard the capability descriptions of the available functions. Advisors can read the capability descriptions and publish them on the Blackboard configuration parameters for the available ADCS functionalities.
An advice composer reads the published configuration parameters and composes them into a consolidated parameter set that it publishes on the Blackboard. The ADCS interface reads the requested actions as well as the composed parameter sets for each of the functions and makes a request to the ADCS to execute them in sequence. In such an environment, the advisors, the contextual data composer, the scheduler, and the advice composer would benefit greatly from a common understanding of the drilling process state. This is the role of the drilling process state interpretation engine. It reads necessary information from the Blackboard and publishes back the currently evaluated drilling process state on the Blackboard. Finally, a logger keeps track of all the changes occurring on the Blackboard to maintain an audit trail of the system interactions.
However, the system states inferred in the context of automation are different from those for calculating key performance indicators. The drilling process state interpretation engine runs in real time, and the architectural components use the system states in online decision-making for scheduling new tasks, configuring parameters to ADCS functions, and managing prioritization between actions. In other words, it has tight time constraints and the penalties for incorrect inferencing are severe.
As the drilling industry matures, automation of the drilling system has progressed from procedurally connected discrete machines to encompass capabilities that extend and interoperate across both localized and remote system functions. There is a need to extend the data, and logic, to include the context of both discrete- and system-level operations.
A Physics-Based Description of the Drilling Process
A set of partial differential equations that describe the conservation of mass, momentum, and energy for the drilling system can describe the drilling process. The drilling system is composed of the drillstring, the drilling fluid, material under transport, and the wellbore.
The mass conservation applied to the drilling fluid is (Landau and Lifshitz 2013)
where is the drilling fluid density and is a fluid velocity vector.
The conservation of momentum on the drilling fluid is (Landau and Lifshitz 2013)
where is the pressure, is the stress tensor, is the gravitational acceleration, and represents the external body force per unit volume.
The force and torque balances on particles or bubbles transported by the drilling fluid are (Ouchene et al. 2015, 2016)
where is the density of the background fluid, is the particle volume, is the particle position vector, is the external force vector applying on the particle, is the particle density, is the angular position of the particle, is the second moment of area, and is an external torque applying on the particle.
The energy conservation for heat transfer is (Corre et al. 1984)
where is the enthalpy per mass unit, is the forced convective term, is the conductive and natural-convective term, and is the heat generated by mechanical and hydraulic frictions.
The force and torque balances on the drillstring are (Belaid 2005)
where is the internal tension vector in the solid, is a curvilinear abscissa, is an external force per unit length, is the density of solid constituting the string, is an area, is the position of the control element of a portion of the string, is the internal torque in the solid, is the tangential vector of the Frenet-Serret coordinate system, is an external torque per unit length, is the second polar moment of area, is the angular position of a control element of a portion of a string, is the Young’s modulus, is the moment of inertia, is the lateral deflection, and is the external moment per unit length.
The solution of these partial differential equations is constrained by time-dependent boundary conditions, like axial and angular velocity at the top of the string, and the drilling fluid volumetric flow rate at the top of the string.
Some of these boundary conditions may exist for some time and then disappear at other moments as is the case with the contact force and torque at the bit: it may or may not be in contact with the bottom of the hole (BH). In other cases, the change in boundary condition may correspond to a load transfer as when the drillstring is set in-slips.
The two examples mentioned above correspond to the desired change in boundary conditions. However, it may also happen that some changes in boundary conditions are undesired. For instance, a stabilizer may hang in a ledge of the formation causing an additional contact along the drillstring. In other cases, it could be that tool joints dragging in cuttings beds result in additional forces at the tool-joint level. Similarly, the formation may fracture, providing an additional flow path for the drilling fluid into the formation.
In a cellular automaton perspective (an arrangement of cells, each of which is in a finite number of states), what matters is the change in these boundary conditions:
Are they equal to zero or not?
If they are different from zero, are they positive or negative?
And so on...
Each change in these boundary conditions has consequences on the state of the drilling system, as seen from a cellular automaton perspective. The change of a single boundary condition can be associated with a logical statement, which can take only two values, true or false.
Consider all the possible boundary conditions for a particular drilling system. Logical statements are definable for each of these individual boundary conditions. If there are such logical statements for a given boundary condition and if these logical statements are exclusive from each other, then the associated number of possible states for that boundary condition is . A logical statement is exclusive from another logical statement if there are no values that would lead to more than one logical statement being true at the same time. For instance, , , and are three exclusive logical statements, while and are not exclusive logical statements because is true for both the first and the second logical statement. A set of logical statements for a boundary condition is complete if at least one logical statement is true for any value of the boundary condition. For example, and is a complete set of logical statements, but and is not a complete set of logical statements because none of them are true for .
A boundary condition is called a microstate. A set of microstates is defined as , where is the number of microstates and is a microstate. Every microstate is associated with a set of logical statements: , where is the number of logical statements associated with the microstate and is the jth logical statement of the boundary condition . A microstate can take possible values, denoted . The set of microstates, , is said to be linearly independent if it does not exist in any combination of logical statements from other microstates that would generate the same set of logical statements, , for this microstate, i.e., where is either or and is either or the identity logical operator. A tuple of microstate values, , describes the overall process state. The set of microstates is said to be complete if two different overall process states are not represented by the same tuple, i.e., , where and are two overall process states and and are, respectively, the tuples representing the process state and in the set of microstates . In a linearly independent and complete set of microstates, any change of boundary conditions always leads to a state that is representable in this basis.
Process State Description
Taking an example: One boundary condition is the top of string (TOS) speed, denoted . This boundary condition can be associated with three logical statements:
where is a threshold value for considering that the TOS velocity is zero.
These three logical statements are complete because for any value of , one of the logical expressions is true and they are exclusive because only one statement is true at a time regardless of the value of . These three logical statements can be seen as an enumeration with three possible values, for instance, 1, 2, and 3, or symbolic names that are more convenient for human beings: string at rest, string lowered, or string raised, considering that the sign convention of the TOS velocity is positive downward (see Fig. 3 ).
In the context of boundary conditions for partial differential equations, what matters is the TOS velocity relative to a fixed point on Earth. Note that the TOS velocity is typically not directly measured; the traveling block velocity is measured. If the string is in-slips, the block velocity is not the same as the TOS velocity. In addition, in the case of an offshore operation performed with a floating rig, a heave compensation (HC) system may influence the TOS velocity. Therefore, even though the logical statements operate on a TOS velocity signal, the real-time value of that signal is likely to be a derived value based on other measurements, combined with some logic and processing. The microstate definitions rely on process boundary variables derived or estimated from actual measurements. In the case of the TOS velocity, the logic used to convert the measured values to an expected process boundary value is simple. For other process boundary signals, the conversion may be much more complicated and involve using a digital twin to estimate the desired values.
Such complexity often needs to rely on methods or algorithms that are the intellectual property of the provider of the signal. As the microstate evaluation is part of an interoperability infrastructure, it is troublesome to make it dependent on complex calculations that may be proprietary or perceived as a technical advantage compared to competitors. This problem is resolved by taking advantage of the D-WIS infrastructure. Third-party applications may provide the desired process boundary values to the Blackboard and the microstate interpretation utilizes these published signals to estimate the state of the drilling process uniquely using simple logical statements that do not involve any method or algorithm that a company can consider its specific intellectual property. This is a direct application of a classical method in software engineering: the separation of concerns (Dijkstra 1982). Therefore, data providers can participate in the data exchange using the D-WIS infrastructure and yet protect their intellectual property.
Fig. 4 shows the typical data flow involved in generating interpreted microstates. One or several data acquisition systems publish raw measurements on the Blackboard. One or several third-party applications, here referred to as a digital twin, subscribe to the necessary raw measurements and publish back to the Blackboard interpreted process boundary variables. The microstate interpretation engine subscribes to the process boundary variables that are necessary for the estimation of the drilling process state. The interpretation only involves simple logical statements that are publicly described and therefore completely transparent. It publishes back the interpreted overall state of the drilling process according to the publicly available interpretation principles.
Continuing the above-mentioned principle of transparency for the interpretation of the microstate, another important boundary condition is to interpret whether the drillstring is in-slips or not. Let us consider the tension at the TOS denoted here , the force on the bottom of the topdrive (TD) (BTD) shaft, , and the force applied on the elevator, . It is possible to define two logical statements associated with :
where is a threshold value for the equivalence of tension or force at the TOS. The TOS tension boundary condition can therefore have two values with the possible symbolic names, respectively, to the two logical statements, which are out-of-slips and in-slips. Alternatively, we could have used a force on the rotary table, and the following logical statements:
.
Note that during the transfer of weight to the slips, both definitions consider that the process state is out of slips. It is possible to capture the weight transfer state in the following way:
1. , or using the alternative definition,
2. , or with the alternative definition,
3. , or using the alternate definition,
Then, the boundary condition for the tension at the TOS can have three symbolic names, respectively, which are out of slips, in-slips, and weight transfer to/from slips (see Fig. 5 ). Here also, there is not usually a direct measurement of the process boundary signals of tension at the TOS, force at the BTD, force on the elevator, or force on the rotary table. They are the results of a conversion made using actual signals such as the hookload, and internal logic variables indicating if the TD or the elevator supports the string. Alternate definitions of a microstate are useful, as they allow using multiple possible process boundary signals and therefore increase the chance of success of calculating the microstate.
The stability of a boundary condition is also an important characteristic of the boundary. It is possible to use logical statements that utilize the standard deviation of the boundary value over a time window, compared with a threshold value to express this characteristic. For instance, a stable flow rate out at the annulus can be associated with two logical statements:
where is the standard deviation of the flow rate at the outlet of the annulus and is a threshold value. The corresponding symbolic values are unstable flow rate at the outlet of the annulus and stable flow rate at the outlet of the annulus.
Fig. 6 shows an example of the evolution of the stability signal for the flow rate out microstate during a pump startup operation. Here = 1.5 L/min.
It is also interesting to know whether the position of one of the first tool joints of the drillstring is at a position that could matter in making decisions. For instance, it is interesting to know if a tool joint is at the stick-up (SU) height, then it may be possible to make a connection. Considering that elevations are counted positively upward and relative to the drill floor, the SU height is denoted , and the elevation of the first four tool joints (TJ) are denoted, respectively, , , , and . Note that the tool-joint numbering starts from the TOS. If the first tool joint is at the level of the SU height, then it is possible to add a new stand. If the third tool joint is at the level of the SU height, then it is possible to remove a triple. If it is required to remove a single, then one only needs to monitor the microstate for the second tool joint. See Fig. 7a for a schematic view of the tool-joint heights and the SU height.
When drilling with a TD, it is necessary to drill until something touches the drill floor (e.g., typically when the retracted elevator touches the iron roughneck rails). This elevation can be called the lowest drilling height, . Note that often this elevation is negative if the zeroing of the block position is with the bail arms extended. So, another interesting microstate is when the elevation of the first tool joint is about at the level of , as this means that it is not possible to drill deeper with that stand (see Fig. 7b ).
There are other microstates associated with the top-side boundary condition of a conventional drilling operation (see Table S-1 in the Supplementary Material). It should be noted that in some cases, it is not possible to calculate a microstate, and therefore its value is undefined. The value zero is referred for that purpose.
Furthermore, boundary conditions can also be downhole. For instance, if the force applied by the formation on the bottom of the string is denoted , the two logical statements and can be associated with two states with the following symbol names: bottom of string off-bottom and bottom of string on-bottom. Here, is a tolerance margin for no reaction forces between the bit and the formation.
If the drillstring has an underreamer (UR), then it is possible to use the force on UR boundary condition, , to define the following logical statements:
which can be denoted symbolically with UR off-bottom UR on-bottom and where is a tolerance margin for no reaction forces between the underream/hole opener and the formation.
Fig. 8 illustrates different combinations of on- and off-bottom for the bottom of the string and a UR/hole opener.
Another interesting boundary condition is whether it is possible to reach the BH with the current length of the string. The question also expands to whether a UR or hole opener can reach the top of the rathole. This can be expressed as follows:
where is the curvilinear abscissa of the bottom of the string, is the curvilinear abscissa of the BH, is the curvilinear abscissa of the UR or hole opener, and is the curvilinear abscissa of the top of rathole. See Fig. 9 for an illustration of the two possible states.
There are several more microstates for downhole boundary conditions of a typical drillstem (see Table S-2 in the Supplementary Material).
Abnormal downhole drilling conditions are also additional boundary conditions. For example, the passage of a large drillstring element across a ledge results in a force between the side of the element and the ledge, . We can define three logical statements:
where is a tolerance margin for having a force between an element and a ledge (see Fig. 10 ).
Considering that the orientation of the force is positive downward, these logical statements have symbolic names: no ledge abnormal condition, ledge underpull, and ledge overpull.
Similarly, the fluid flow at the level of the formation is a boundary condition. Let us denote the flow rate from or to the formation. This boundary condition can be associated with three logical statements:
meaning, respectively: no well integrity problem, loss circulation, and influx. is a tolerance margin for considering that there is substantial flow or loss to the formation.
There are other microstates that are associated with downhole abnormal boundary conditions (see Table S-3 in the Supplementary Material).
In addition, downhole equipment may be “activated” (e.g., opening or closing a UR, activating a circulation sub, breaking the shear pins of a whipstock, or setting a plug). This also corresponds to changes in boundary conditions. Let us take the example of a float valve in the BH assembly. We denote by the pressure across the float valve, counted positively in the downward direction, and the minimum pressure to close the valve (i.e., a negative number). Then two logical statements define, respectively, the following symbolic states: float sub open and float sub closed:
.
.
There are additional microstates corresponding to boundary conditions of downhole elements that can change state (see Table S-4 in the Supplementary Material).
Microstate Bases for Different Drilling Methods
In the previous section, we documented the microstates corresponding to a conventional drilling operation from a land rig or a fixed platform. We will now cover a few additional cases.
Conventional Drilling from a Floating Rig
When drilling conventionally from a floating rig, there are some additional boundaries to consider. For instance, because of the large dimensions of the marine riser, it is often necessary to pump through the booster line to lift the cuttings to the surface while drilling in small-hole sections.
In addition, as the rig is subject to heave, there is an HC system, which may be active occasionally. Typically, the HC system can be inactive or active. However, there may be a period during which it is neither fully active nor fully deactivated. For that reason, two Boolean values can describe whether the HC system is fully inactive, , and fully active, . The following states can be defined:
The first state corresponds to fully inactive, the second to fully active, and the third one to be in transition between active and inactive. There is a fourth possibility when . This situation should never happen because the HC system cannot be at the same time fully inactive and fully active, therefore it is associated with state zero (i.e., undefined).
There are several additional microstates that are specific to a drilling operation from a floating rig (see Table S-5 in the Supplementary Materials).
Backpressure Managed Pressure Drilling
Using a managed pressure drilling (MPD) system to control backpressure introduces a few more control options. For example, when the drillstring is on-bottom (drilling), the position of the MPD choke opening determines the pressure that is maintained at the surface, before the returns are released farther downstream. When the choke is barely open, the pressure is higher. When the choke is close to fully open, the pressure is lower.
Consider now the case when there is no flow, for instance, during a connection. The choke has to close completely to trap pressure (and maintain the desired backpressure). Furthermore, closing the choke may not be sufficient to maintain the desired pressure. In those cases, a backpressure pump provides a small amount of flow at a point just upstream from the choke. This flow now allows the choke to stay open (i.e., maintaining a certain level of control—a closed choke means one less control variable), while at the same time, it allows a wider range of pressure values to be maintained.
Additional microstates describe the state of the backpressure MPD pump and the MPD choke (see Table S-6 in the Supplementary Material). Note that the state and are abnormal states because pressure control is no longer possible when the choke is respectively fully closed or fully open.
Dual-Gradient Drilling
In dual-gradient drilling, the riser contains some lighter fluid (such as seawater) above the conventional drilling fluid. This reduces the hydrostatic head and partially compensates for the increased drilling fluid head at the seabed (full compensation is riserless drilling). The lighter fluid is the blanket fluid; a fill pump maintains the column of the blanket fluid. A lift pump transports drilling fluid, containing entrained cuttings, from the annulus (riser) below the blanket fluid to the surface.
The low-level annulus return drilling is an extension to the dual-gradient drilling method where the blanket fluid is completely absent and replaced by air. A lift pump is necessary to control the level of fluid in the annulus. Note that a fill pump establishes a downward flow inside the riser (above the suction point of the lift pump) to avoid entrained gas (possible dissolved gas) from percolating above the inlet of the lift pump. If that were possible, then there would be a risk of explosive ejection of fluids through the riser when the contaminated mud reaches pressures below the bubblepoint of the dissolved gas.
There are several microstates related to dual gradient drilling operations (see Table S-7 in the Supplementary Material).
Combination of Microstates
It should be noted that tuples of values for the microstates describe more complex states. For instance, the tuple describes steady-state flow conditions. Fig. 11 shows an example pump startup. The flow rate in, , the flow rate out, , the standard deviation of the flow rate in, , and the standard deviation of the flow rate out, , are displayed as a function of time together with their respective tolerance limits, , , , and . Using the above-defined criterion for steady-state flow conditions, there are three periods that respect this condition (from 46 to 50 seconds, from 71 to 85 seconds, and from 250 seconds onward).
It is possible to encode the tuple of microstates as a binary string. Bitwise operations on the binary string allow for very efficient pattern matching of individual and combined state definitions.
Microstates and Semantics
A microstate engine is used to estimate each of the microstates. It searches on the Blackboard for the available process boundary signals used in the definitions of the microstate, using semantic queries. Semantic queries are used to retrieve information from the Blackboard based on semantic definitions published on the Blackboard (Cayeux et al. 2023). An example of a semantic query for the process boundary variable is shown in Fig. 12a . It illustrates searching for the live signal associated with a derived measurement of the physical quantity, velocity. The data point is at a TOS location and it is measured in a reference frame that corresponds to the wellbore, which is a fixed reference.
The Blackboard supports a query mechanism that is called publish/subscribe (Gamma et al. 1993). In the publish/subscribe design pattern, producers of data publish their data on a broker, and data consumers subscribe to the desired data. If the desired data are available, they are forwarded to the subscriber. In the case of the microstate engine, the program subscribes to all possible process boundary signals that it may use. When there are available signals for a particular semantic query, it uses the values to calculate the state of the corresponding microstates. If signals are not yet available, the evaluation returns an “undefined” state. However, if the signal becomes available at a later stage, the microstate engine is informed of its availability and, therefore, can estimate the associated microstates. In contrast, if a signal is not available anymore, the microstate engine is informed, and the evaluation of the corresponding microstates is set to “undefined.”
Because of the messaging mechanism of the publish/subscribe design pattern, new values for signals are sent as they are updated. The microstate engine receives these asynchronous messages and processes them as they arrive. If any of the microstates change, then a new overall state is calculated.
The microstate engine publishes the currently evaluated overall state of the drilling process to the Blackboard. The semantic associated with the real-time signal is shown in Fig. 12b . Note that the blue box represents the open platform communication unified architecture (OPC-UA) node that contains the actual live value. The only delay introduced by the microstate engine is caused by the time taken to receive a message, the time to process the logical statements, and the time to send an update message. In practice, the communication with the Blackboard is made with OPC-UA, which is capable of refresh rates in the order of a kilohertz, and therefore, each of these steps takes at most a few milliseconds. In practice, the effect of the latency in evaluating the overall drilling process state is marginal for most applications.
Sensor Fusion
When subscribing for a boundary signal defined by a semantic query, it is possible that the Blackboard returns several signals that match the query. These signals may have been generated by multiple digital twins, all attempting to replicate the current drilling operation.
Supposing that there are different signals that match the semantic query and that each of these signals is characterized by a normal probability distribution , where is the mean value and is the standard deviation. Then the easiest way to fuse these signals is to use the inverse variance weighting method. The result is a new normal probability distribution with the mean value and the standard deviation :
With this method, the mean value of each of the signals is the estimated value by the corresponding digital twin. In the ideal case, the digital twin has also estimated the uncertainty on the estimated value, which is also published on the Blackboard in the form of a standard deviation, . The semantic query is therefore formulated to retrieve both the estimated value and its standard deviation. However, some digital twins may not publish any uncertainty estimations. In this case, a default standard deviation is used, usually rather large, as there is no provided information about the quality of the estimated value.
It is possible that each of the digital twins provides estimated values that are somewhat different from the others, but which nevertheless follow relatively well the dynamic response of the drilling process. In other words, the estimated values of each individual digital twin may be biased. The bias can be a systematic additive error and it can be a scaling multiplicative error. The provided signal may be modeled as follows: , where is the true value, is the provided value, is a scaling error, and is a systematic bias. It is then possible to extract the true value, considering that and are estimated:
Furthermore, the digital twins may not produce their outputs synchronously (i.e., there may be a systematic delay between the output of each digital twin). The fused value is therefore estimated using the digital twin results along with their respective delays. The resulting fused value will therefore be delayed by at least the same amount as the most delayed output from the digital twins. Denoting the current time, the fused data time, and the delay of the digital twin compared to , then there is the following relationship:
Considering a series of measurements, index by and taken with a timestep , then the delay for each digital twin can be denoted . The problem consists in finding such that the sum of the square differences between each pair of estimated values is minimized:
where .
At the minimum, all the partial derivatives of the sum are equal to zero. Noting , this gives the following system of equations:
It should be noted that the partial derivatives relative to and to give the same equation. Therefore, one equation is missing to obtain a determined system of equations. In practice, it is possible to consider that , therefore removing one unknown. Then, should be interpreted as being relative to . Eq. 9 is solved using for instance a Levenberg-Marquardt method (Levenberg 1944). The estimation of is made on a moving window of digital twin outputs. The initial solution of the Levenberg-Marquardt algorithm is the result from the estimation made with the previous time window. For the first time window, the following initial values are used: .
After estimating the biases and delays, the fused value is calculated using the following expression:
Probabilistic Microstates
Having an estimation of the mean value and of the standard deviation of the real-time signals that are used in the logical expressions to determine the microstate of the drilling process, it is then possible to define a probabilistic microstate value.
For instance, the microstate definition for the velocity at the TOS is defined as follows:
State 1 if
State 2 if
State 3 if
where is the velocity at the TOS. If is described by a normal probability distribution , where is the mean value and is the standard deviation, then it is possible to calculate the cumulative probability density function, denoted CDF:
where is the error function.
The microstate is either a Bernoulli probability distribution if it has two states, or a categorical probability distribution if it has three states. It is then possible to calculate the probability of each of the states by utilizing the logical statements. In the example of the TOS velocity microstate, these probabilities are as follows:
Probability to be in State 1:
Probability to be in State 2:
Probability to be in State 3:
where is the probability function.
With the notion of probabilistic microstates, the drilling process is in all the possible states of a given microstate at the same time, but with more or less probability. If the standard deviation is small, then the probability of being in one state compared with the another will be rather large, but if the standard deviation is large, there may be less certainty of being in one state compared with another.
For logical expressions that involve several real-time signals combined with logical “and” and “or” statements, the calculation of the probability for each state must use standard Bayesian rules, such as:
, which can be simplified to when and are independent events.
.
It should also be noted that some logical expressions involve binary variables. The probability distribution of a binary variable may also be available by querying the Blackboard. The binary variable is then considered as a Bernoulli distribution. It is then possible to use the standard probability rules mentioned above to calculate the probability of each state of the microstate.
Case Study
To illustrate the use of the above principles, the case of a rate of penetration (ROP) management is considered. Among the different functionalities of any ROP advisors, it must manage which drilling parameters shall be used when entering a hard stringer, while drilling the hard stringer, and when exiting the hard stringer. ROP advisors use the microstate detection provided by the microstate interpreter. From the microstate basis, an ROP advisor reads the microstates 62 and 63 (see Table S-2 in the Supplementary Material). The formation change microstate is defined as follows:
State 1 if (e.g., same formation hardness),
State 2 if (e.g., penetrating harder formation),
State 3 if (e.g., entering softer formation,
where is the gradient of the formation strength and is a tolerance margin for considering to be in the same formation hardness.
The hard-stringer microstate is defined like this:
State 1 if (e.g., inside the normal formation).
State 2 if (e.g., inside hard formation, where is the formation strength and is a threshold value for considering the formation strength corresponds to a hard stringer).
The ROP optimization advisor looks at the following combination of states:
corresponds to entering in a hard stringer.
corresponds to drilling the hard stringer.
corresponds to exiting the hard stringer.
On its side, the microstate interpreter engine retrieves the two real-time signals and . There are two providers for these signals:
One estimates the formation strength and its gradient by calculating the mechanical specific energy (Dupriest et al. 2022). As it has been pointed out by Dupriest and Koederitz (2005), the mechanical specific energy can be considered as related to the confined compressive strength and therefore the unconfined compressive strength of the formation.
The second estimates the formation strength and its gradient by calibrating the bit-rock interaction model described by Detournay et al. (2008). The calibration of the model parameters uses a particle filter as described by Ambrus et al. (2020).
Both sources for the formation strength and its gradient estimate also have a standard deviation for their estimations. The outputs of the two estimators are not synchronized, and there is a scaling difference and systematic bias between the two. Nevertheless, the sensor fusion method described above allows us to reconciliate the two estimations and to improve the standard deviation of the fused signals. The ROP advisors monitor the probability of the states for the two microstates ( and ) and determine when to apply specific ROP management procedures when entering, inside, and exiting any hard stringers that are encountered, according to the drilling operation rig action plan (RAP).
This behavior is illustrated in Fig. 13 , which shows a weight-to-weight automatic drill-a-stand procedure as simulated during a test of the D-WIS interoperability infrastructure. The “Scheduler,” “Microstate Engine,” and “Composer” are standard elements of the D-WIS architecture. The “RAP Advisor” is an external component provided by one company, while the “ROP Optimizer Advisor” is another external element issued by another service company. They communicate with an ADCS using the “Standard ADCS Interfaces” defined by D-WIS. The “Scheduler” is event-driven and starts and stops ADCS standard functions depending on microstate patterns. A more detailed description of the “Scheduler” is given by Cayeux et al. (2024). In practice, the parameters of each ADCS function are issued by the “Composer” and the “Scheduler” sends requests for these parameters to the “Composer.” However, for the sake of clarity, the sequence shows a direct link from the “Scheduler” to the “ADCS” when there has been only one input source managed by the “Composer,” as in this case the “Composer” acts like a replicator for these desired parameters. One can see how the startup procedure is event-driven with the next step after “gel breaking” triggered when the flow is stable as described in Fig. 11 . Similar principles are used for starting the TD and for the decision to tag bottom.
The role of the “Composer” is illustrated when the “on bottom” event is set true. Both the “RAP Advisor” and the “ROP Optimizer Advisor” read the new state and send recommended drilling parameters. The “Composer” utilizes both inputs to generate composed drilling parameters that are passed to the auto-driller of the ADCS.
When the first hard-stringer is encountered, the “RAP Advisor” reacts by sending new drilling parameters. In reality, the “ROP Optimizer Advisor” also reacts to the discovery of the hard formation, but, for simplicity, only the “RAP Advisor” reaction is illustrated here. New requested drilling parameters are sent to the auto-driller of the ADCS, and the hard stringer is drilled with lower rotational speed and flow rate and limited weight on bit. After exiting the hard stringer, the drilling parameters are resumed to standard values. The same procedure happens during the drilling of the second hard stringer, except that the “ROP Optimizer Advisor” issues after 10 minutes a request to change the rotational speed to address a drillstring vibration problem that is observable through other signals that are not displayed on this graph (TD torque and downhole mechanical subdata).
This example illustrates the role of the “Microstate Engine” in the D-WIS architecture as a source for interprocess synchronization. By listening to a unique source for the drilling process state interpretation, then multiple advisors can interplay in a synchronous way even though they have been designed and developed independently. However, the D-WIS interoperability architecture does not impose that every advisor uses the results of the “Microstate Engine.” They can have their own drilling process state interpretation, but then the possibility of synchronous behavior is not guaranteed.
Discussion
In contrast with the International Association of Drilling Contractors DDR and DDR print and electronic system code that must be interpreted by humans, the proposed description of an overall drilling process state that is decomposed on a basis of independent microstates can be interpreted and consumed by computer systems. The underlying general principle for decomposing the drilling process state originates from the observation that what matters is the boundaries of the partial differential equations that govern the drilling process. These boundary conditions refer to process boundary variables that do not necessarily match actual measurements. For that reason, there is a need for methods and algorithms to convert raw measurements into the process boundary variables that are relevant to the physical equations describing the drilling process. This step involves most likely proprietary competences that can be kept protected from the interoperability architecture by using the Blackboard to exchange information.
So far, the provided examples are rather simple, and it is legitimate to question whether the principles of characterizing the state of the drilling process by using microstates work for more complex cases. To illustrate that microstates can indeed describe a complex situation, an actual drilling incident from the North Sea is analyzed in Fig. 14 . The case corresponds to a situation during which a packoff is experienced. This is visible through abnormal annulus pressure increases, captured by the microstate (annulus flow impeded), multiple overpulls and underpulls, indicated by the microstate (cuttings bed state), several string rotation impediments, visible through the microstate . At 6:37, the mud pumps are stopped because of the packoff situation, and shortly after a kick is experienced, reported on microstate (well integrity state), as the last stand has been drilled through a high-pressure zone. This example is taken from Fig. 56 of Cayeux (2020). The determination of the state value of the four microstates is based on the maximum tolerances estimated by the underlying digital twin. These margins are calculated based on the automatic calibration of a transient hydro-heat-transfer-mechanical-material-transport model. The margins are shown as a green region in the hookload, TD torque, and standpipe pressure tracks of the time-based plot of Fig. 14 . Also the expected active pit volume is estimated and is used to estimate possible gain/loss conditions (Cayeux and Daireaux 2017). This shows that the method allows to capture drilling process states that are not so common like having simultaneously an underpull, an overtorque, and a kick ().
The simple logical statements that define each of the microstates are themselves defined in a transparent manner, ensuring that there is no ambiguity on what to expect when the microstate engine reports the value of any of the microstates. However, the estimation of the state for each of the microstates depends on the accuracy of the digital twins that provide the real-time signals used in the logical statement. The microstate interpretation engine utilizes sensor fusion and probability estimation of the states to leverage this dependence on multiple sources if several of them are available. As an element of an interoperability infrastructure, it is not the responsibility of the microstate interpretation engine to estimate the quality of the provided signals by the digital twins. This responsibility is on the drilling organization at the rigsite—they decide who provides the digital twins. Yet, the risk of a major failure in the drilling process state interpretation is reduced if there are several such digital twins, as the sensor fusion method effectively utilizes collective intelligence principles and, therefore, avoids dependence on a possible single point of failure.
However, there are some important aspects that have not been addressed.
First, the notion of microstates can be extended beyond boundary conditions for the partial differential equations of the drilling process. It can also encompass limits associated with safe operating envelopes (Hurt 1965) and levels for fault detection (Isermann 1997). It is then conceivable to describe whether the state of the system has exceeded any alert or alarm levels.
Second, the values of the components of the basis of microstates describe the current drilling process state, not the drilling activity that is being executed. To label which drilling activity is being performed, it could be envisaged to consider that the current state of the drilling process is a “letter” in an alphabet of possible states. Then, after defining a “grammar,” for example, using the Backus Naur Form (Aho et al. 1985), it would be possible to associate a label to an observed sequence of microstates. These labels could be hierarchically structured, for instance, following the terminology from ISA 88 (e.g., a section method consists of procedures, which consists of phases, which consists of advisory elements). A sequence of microstates could thereby be labeled—this could help address, or label, situations during which drilling incidents have occurred.
Third, equipped with a mechanism for labeling drilling activities and possible abnormal drilling conditions would open the possibility for applying causal analysis methods, such as root-cause analysis (Andersen and Fagerhaug 2006), Bayesian network (Pearl 1995), or causal inferencing (Pearl 2010).
In summary, the proposed method—determining the drilling process state using an orthogonal basis of microstates—could start more advanced solutions for automatically interpreting the drilling process.
Conclusion
The digitalization and automation of the drilling process drive the need for an interoperability platform between the different systems of the various companies involved in a drilling operation. It is important that these interoperating companies have a shared and well-accepted definition of drilling process states that are computer readable and interpretable.
A general framework for defining the drilling process state has been described, and the interpreted drilling process state can be consumed by multiple parties. This common drilling process state is, therefore, unifying information for the interoperability infrastructure, which includes external advisors. Lacking this common reference, which describes the state of the drilling process, can have serious consequences for the synchronization of all the systems contributing to automation in a multiplayer environment.
The generation of the drilling process state relies on the availability of one or several digital twins that can provide estimated values for the boundary conditions of the drilling process. The fusion of signals provided by multiple data sources increases the reliability of the interpreted drilling process state. This is an illustration of the fact that interoperability can be a source of greater robustness for automation—the entire construct of advisors and ADCS—as working together reduces the risk of failure due to the weakness of a single element.
Nomenclature
acceleration of signal at timestep k
- A
area, L2, m2
- Aij
logical statement of the jth state of microstate μi
set of logical statement for microstate μi
external torque per unit length, MLT-2, N
- E
Young’s modulus, ML-1T-2, Pa
- fchoke
MPD choke opening ratio, dimensionless
external body force per unit volume, ML-2T-2, N/m3
external force per unit length, MT-2, N/m
- Fbos_rock
force applied by the formation on the bottom of the string, MLT-2, N
- Fbtd
force on the top-drive shaft, MLT-2, N
- Felev
force on the elevator, MLT-2, N
- Fel_ledge
force between the element and a ledge or key seat, MLT-2, N
- Fur_rock
force between an underreamer or hole opener and the formation, MLT-2, N
external force vector applied on the particle, MLT-2, N
force applied by the slips on the rotary table, MLT-2, N
gravitational acceleration, LT-2, m/s2
- hldh
lowest drill height, counted positvely upward and relative to drill floor, L, m
- hSU
stick-up height counted positively upward and relative to drill floor, L, m
- hTJ1
elevation, counted positively upward and relative to drill floor, of the first tool joint of the drillstring, L, m
- hTJ2
elevation, counted positively upward and relative to drill floor, of the second tool joint of the drillstring, L, m
- hTJ3
elevation, counted positively upward and relative to drill floor, of the third tool joint of the drillstring, L, m
- hTJ4
elevation, counted positively upward and relative to drill floor, of the fourth tool joint of the drillstring, L, m
- H
enthalpy per mass unit, L2T-2, J/kg
- Ip
second moment of area for particle, L4, m4
- Is
second polar moment of area for string, L4, m4
- Iw
second moment of area for string, L4, m4
- ki
number of timesteps necessary to obtain a delay Δti, dimensionless
- kmin
start index for the summation of the squared difference between the estimated values, dimensionless
- mij
value of state j of microstate μi
external moment per unit length, MLT-2, N
internal torque in the solid, ML2T-2, N·m
external torque applying on the particle, ML2T-2, N·m
set of microstates
- n
number of microstates
- ni
number of possible states for microstate μi
normal probability law
- p
pressure, ML-1T-2, Pa
overall drilling process state
- q
potential energy per unit length of external loads, MLT-2, J/m
- qs
heat generated by mechanical and hydraulic frictions, MLT-3, W/m
- Qc
conductive and natural-convective term, W
- Qf
forced convective term, ML2T-3, W
flow rate from or to the formation, L3T-1, m3/s
- Qout
flow rate of cuttings at the outlet of the annulus, L3T-1, m3/s
- Qtos
flow rate at the top of the string, L3T-1, m3/s
- s
curvilinear abscissa, L, m
- sbh
curvilinear abscissa of the bottom of the hole, L, m
- sbos
curvilinear abscissa of the bottom of the string, L, m
- srh
curvilinear abscissa of the top of the rat hole, L, m
- sur
curvilinear abscissa of the underreamer or hole opener, L, m
- S
binary string representing the current drilling process state
- Sf
binary string representing a filter to retrieve only the binary values at the desired microstate positions
- St
binary string representing the binary values of the desired microstate positions
- t
time, seconds
- T
temperature, Θ, K
- Ttos
tension at the top of the string, MLT-2, N
tangential vector of the Frenet-Serret coordinate system, dimensionless
internal tension vector in the solid, MLT-2, N
particle position, L, m
position of control element of a portion of string, L, m
- vtos
top of string velocity counted positively downward, LT-1, m/s
- Vp
particle volume, L3, m3
fluid velocity vector, LT-1, m/s
rate of change of signal at timestep k
- w
deflection in a perpendicular direction to , L, m
- X
state vector of the sensor fusion method based on the Kalman filter
true value
true value of a signal at timestep k
provided value by the ith digital twin
provided value by the ith digital twin at timestep k
- αi
scaling error of the 𝑖th digital twin
- βi
systematic bias of the 𝑖th digital twin
- ∂sσUCS
gradient of the formation strength, ML-2T-2, Pa/m
- Δpfv
pressure across the float valve, counted positively in the downward direction, ML-1T-2, Pa
minimum pressure to close the valve, ML-1T-2, Pa
- Δt
timestep, T, seconds
- Δti
delay to be accounted for when using the estimated value from the 𝑖th digital twin, T, seconds
tolerance margin for no reaction force between the bottom of the string and the formation, MLT-2, N
tolerance margin for detecting an overpull or underpull on a ledge, MLT-2, N
tolerance margin for no reaction force between the underreamer or hole opener and the formation, MLT-2, N
tolerance margin for detecting a kick or loss, L3T-1, m3/s
tolerance margin for zero flow at the well outlet, L3T-1, m3/s
tolerance margin for zero flow at the top of the string, L3T-1, m3/s
tolerance margin for equivalence of tension or force at the top of the string, MLT-2, N
tolerance margin for a zero top of string velocity criterion, LT-1, m/s
tolerance margin for considering to be in the same formation hardness, ML-2T-2, Pa/m
threshold value for considering the formation strength corresponds to a hard stringer, ML-1T-2, Pa
angular position of the particle, rad
angular position of a control element of a portion of a string, rad
- μi
individual microstate
- ρf
density of the background fluid, ML-3, kg/m3
- ρm
drilling fluid density, ML-3, kg/m3
- ρp
density of particle, ML-3, kg/m3
- ρs
density of solid constituting the string, ML-3, kg/m3
- σ
standard deviation of a fused signal
- σi
standard deviation of signal 𝑖 use during sensor fusion
standard deviation of the flow out of the annulus, L3T-1, m3/s
threshold value, L3T-1, m3/s
standard deviation of the flow rate at the top of the string, L3T-1, m3/s
threshold value, L3T-1, m3/s
- σUCS
formation strength, ML-1T-2, Pa
stress tensor, ML-1T-2, Pa
internal torque, ML2T-2, N·m
Symbols
Acknowledgments
The authors would like to thank the other team members of the workstream “Drilling Process Protection” of the D-WIS subcommittee of SPE-DSATS for their continuous contributions to the development of interoperability solutions for drilling operations.
Article History
This paper (SPE 212537) was accepted for presentation at the SPE/IADC International Drilling Conference and Exhibition, Stavanger, Norway, 7–9 March 2023, and revised for publication. Original SPE manuscript received for review 26 February 2024. Revised manuscript received for review 26 July 2024. Paper peer approved 11 September 2024. Supplementary materials are available in support of this paper and have been published online under Supplementary Data at https://doi.org/10.2118/212537-PA. SPE is not responsible for the content or functionality of supplementary materials supplied by the authors.