Experimental comparison of PID based RPM control for long horizontal vs. vertical drillstring

: Drilling vibrations have been identified as a key performance limiter that prevents successful energy transfer from the surface to the bit. The resultant irregular bit rotation speed causes drilling challenges like poor hole quality and reduction in rate of penetration to name a few. Amongst other vibration suppression techniques, active control of vibrations is widely used and recommended. Active control system utilizes a closed loop feedback control to continuously adapt to downhole vibrations detected at the surface. The system requires regular tuning and upgrades for optimized performance. The papers highlights the need of optimizing PID paramters based on well configuration instead of a “ one size fits all ” approach. Through experimental testing of PID controller parameters, differences in system response have been observed for horizontal vs vertical configurations. The paper also talks about the impact of drilling dynamics on PID system response in both cases. Successful reduction of settling time has been achieved with optimized PID parameters for both well configurations.


Introduction
The rotary system of drilling rig is an integral component of the drilling system. It includes the top drive system responsible for providing rotational torque to the drill bit through the drill string. Figure 1 shows a simplified schematic of the rotary system used in a drilling rig. The top drive system can be either hydraulic or electric motor driven, however the modern drilling rigs are using electric drives. These electric drives can be AC or DC. Since drilling is a destructive process, vibrations along the drill string and at the bottom hole assembly are commonly observed. However, when economics of drilling a well is compromised through reduction of hole quality, life of downhole tools and rate of penetration, vibration control mechanisms are utilized to suppress harmful drilling vibrations and optimize the drilling process. These control systems can be broadly classified as passive and active in nature [1,2]. Passive strategies avoid external intervention and use the energy in the system by parametrical determination of an optimum drilling zone, BHA and bit re-design and utilization of vibration reduction tools.
Active control strategies on the other hand include real-time intervention in the drilling process to mitigate vibrations. This includes application of an external force, equal and opposite in nature, to dampen the existing vibrations in the system. Based on input and output parameter of active control strategies, feedback control can be divided into open-loop and closed-loop systems. The focus of the remainder of the paper is on active control strategies. One of the oldest active control techniques is to utilize a torque feedback controller to reduce amplitude of torsional vibrations [4]. High surface torque is compensated by lowering the rotary speed at the surface and vice versa. This greatly reduces the coefficient of torsional energy that is reflected at the rotary surface. Other studies have also shown the suppression of torsional vibrations using a hydraulic top drive that is tuned as a vibration damper to absorb vibrational energy at the surface [5]. Another widely adopted technique is the soft torque rotary systems (STRS) by Shell that electronically imposes stiffness in the top drive system to critically dampen the amplitude of vibrations in the drill string [6]. This control system can be observed in figure 2. Other conventional controllers such PI and PID type have been successfully implemented over the years that are robust to variable and uncertain drilling parameters [7]. In some of the recent literature, a hybrid sliding mode controller [8] was designed to improve the drilling performance under high frequency tortional vibration conditions. In [9] a super-twisting controller was proposed to suppress stick-slip vibration and maintain the angular velocity of the drill string at the desired value, despite the operating conditions.The basis of all the above-mentioned control systems is to develop elaborate drill sting models that include dynamic non-linear forces and external excitations. This is also referred as the classic white box approach. However, due to computational complexities, we are limited to simpler models like the lumped pendulum mass model with one or two degree of freedom that fails to capture the complexities of a high-fidelity drill string model. Furthermore, very few models capture complexities of a directional well. Models that are based on adjustable parameters are called grey box models and models that are approximated within acceptable limits of controllability are called black box models [10].
In either of the cases, there is a need for extensive experimental testing of the active control systems for consistent finetuning and improvement of the feedback system. Srivastava and Teodoriu, [11] present a summary of downscaled experimental test rigs for investigating drill string vibrations. The author further summarizes the variability in type of electric motors utlized for top drive control in experimental setups and it's impact on precise angular measurements using rotary encoders. The accurate experimental data measurements play a big role in the development and improvementm of physical drill string models. Using PID controllers for autonomous vertical lab-scale test rig is commonly observed. Losoya et al., [12] utilized a scheduled-gain PID controller with WOB (weight on bit) as input. The author defined further aggressive, moderate, and conservative controller gain parameters and compares PID controller response for each of the cases. Loeken et al., [13] utilized a PI controller to optimize WOB based drilling control and also discussed the possibility of integrating a torque based PID controller to develop a multiloop system. This system would help achieve a high-torque setpoint for a given WOB. Similarly, Ullah and Bohn, [14] utilized a top drive velocity based PID controller with no feedback from the bit.
The author highlighted the need of continous tuning for such a control system. In all experimental laboratory test rigs with active control systems, a vertical drilling system is configured. However, most wells are drilled directionally. This requires us to rethink our physical models and testing configuration to include dynamics of directional drilling. This paper presents a comparative study of PID based active control algorithm for vertical and horizontal experimental drilling. In doing so, PID tuning parameters are compared and analyzed. The paper talks about PID control, the unique experimental setup used for the experiments and the PID tuning results for the two configurations at different rpm.

PID Control
There are two types of control systems: (i) open-loop, and (ii) close-loop. The difference between the two is in terms of the feedback wherein in an open-loop system the output is only dependent on the input whereas for a closed-loop system the output depends on the present input and the previous output (feedback signal). The feedback in a close-loop system makes it a self-correcting system which is essential in automation and controls applications.    can cause oscillations and make the system unstable, this is when the derivative action is used to stabilize the system. One drawback of this control action is that it is very sensitive to noise. where 'TI' is the integration time and 'TD' is the derivative time.

Experimental Setup
The setup used for this paper is a custom designed laboratory scale drilling test rig equipped with several sensors and actuators to simulate the process of oil well drilling. A National Instruments cDAQ data acquisition device is central to the setup, and it is what all the sensors and actuators are connected to. The control system software is designed using National Instruments LabVIEW. A detailed description of the setup is presented in a previous work [15].

Figure 6. Horizontal Setup
The setup was originally designed for vertical experiments but has been modified to feature an interchangeable horizontal and vertical configuration, as shown in figure 6. Another upgraded to the setup is the implementation of closed-loop control strategies, one of which is closed-loop RPM control. RPM is one of the most critical drilling parameters and is directly related to the rate of penetration (ROP) of the drill-bit. A 18V DC motor provides rotational energy to the drillstring which is outfitted with multiple rotary encoders to measure the RPM along the drillstring. The block diagram representation of the closedloop RPM control is shown in the figure 7.

Figure 7. Block diagram representation of the closed-loop RPM control
LabView PID toolset is used to design the PID control. It calculates the error i.e., the difference between the RPM setpoint and the RPM feedback and generates a control signal which is a 0-5V voltage signal from one of the analog outputs on the cDAQ data acquisition device. The control signal is fed to a motor controller which takes in the 0-5V signal and produces a 0-18V output which is the driving voltage for the DC motor.

PID Tuning
LabView PID toolset is used to design the PID control. It calculates the error i.e., the difference between the RPM setpoint and the RPM feedback and generates a control signal which is a 0-5V voltage signal from one of the analog outputs on the cDAQ data acquisition device. The control signal is fed to a motor controller which takes in the 0-5V signal and produces a 0-18V output which is the driving voltage for the DC motor.
To tune a PID with using the trial-and-error method the first step is to set the proportional gain to a small value and the other two gains to zero. The value of the proportional gain can then be increased until an acceptable response time is achieved. At this point there are oscillations in the system which can be reduced by setting integral gain.
Again, a small value can be chosen to start with and then it can be increased to reduce the oscillations. Now if there is an overshoot in the system it can be fixed by using the derivative gain which can be set by using a similar approach. It must be mentioned here that the derivative gain must be kept very low or even avoided altogether if not needed. This is because the derivative gain is very sensitive to noise and can make the system unstable.
Some other popular PID tuning methods are Ziegler-Nichols rules, Chien-Hrones-Reswick PID tuning algorithm, and Cohen-Coon tuning algorithm. Daful [16] discusses and compares these PID tuning methods for two different systems. Garrido et al. [17], presented an interactive frequency domain focused PID controller tuning software tool.
Some of the helpful terminologies relating to PID tuning and performance are introduced below.
• Rise Time: It is the time it takes for the process-variable to go from 10% to 90% of the steady-state value • Settling Time: The time it takes to reach the steady state • Steady-state Error: The final difference between the setpoint and the process-variable.
• Overshoot: The maximum deviation of the process variable from the setpoint during the transient state To tune the PID controller in our setup, the Ziegler-Nichols method and the trial- and-error method were tested. Both PI and PID variables (shown in table 1) were calculated the Ziegler-Nichols method but the response obtained from these was very oscillatory with high overshoots. Figures 8 and 9, show the PID and PI response respectively. Table 1. PID parameters calculated using Ziegler-Nichols method On the other hand, the trial-and-error method produced much better results and was chosen to tune the setup. Multiple tests were conducted to tune the PID for both the vertical only setup and the vertical and horizontal setup. A steady-state error of ±5% and settling time of less than one second was considered acceptable. The LabVIEW PID vi is tuned by setting the proportional gain 'KP', integral time 'TI' (in minutes), and the derivative time and 'TD' (in minutes). Figure 10 shows a response of the vertical setup to an RPM step input of 0 to 150 RPM with the PID parameters KP, TI, and TD set to 0.01,0.003 and 0 respectively. The steady state is reached in about 6 secs which exceeds the required settling time. An overshoot can also be observed, and in a real-world drilling scenario such a big overshoot in the RPM can be detrimental to the equipment and can be a big safety concern. Excessive overshoot and oscillatory behavior during the transient state can result in vibrations along the drillstring which can cause wellbore instability and lead to non-productive time (NPT). The basic modes of vibration observed in a drillstring are: axial, lateral and tortional. During the drilling process a combination of these three modes is commonly observed. Controlling the RPM among other parameters is critical for efficient drilling. Dunayevsky et al. [18] developed a vibration model based on the parametric resonance theory to identify the critical rotary speeds at which severe drillstring vibrations can occur. Santos et al. [19] presents a clear relationship between drillstring vibrations and wellbore instability.  Figures 11 to 13 show the response to RPM steps from 0-100, 0-150 and 0-200 respectively. On the plots, the rise time, which is the time the system takes to get from 10% to 90% of the setpoint is marked with the black arrow and, the settling time, which is the time to get to steady-state is marked in red. It must be noted here that some small oscillations (restricted within the steady-state error of ±5%) can be observed in the steady-state. These oscillations are a result of the tortional vibrations in the systems which are captured by high precision 500 PPR rotary encoders used in the setup.

Results
Multiple tests for each of the nine cases presented in figures 11 to 19 were conducted and the average settling time was calculated as shown in Table 1.

Discussion
Our experiment has shown that the introduction of a horizontal section will alter the PID response, resulting in an RPM dependency of the Settling time. After recalibration of the PID parameters, the system response was improved, however the dependency of the RPM is still visible. There are two major factors why the RPM is affecting the PID Settling time: the friction of the system, which is negligible for the vertical section and the presence of the horizontal section itself which is altering the top drive response. However, we have noticed that the elevated friction in the system will allow for a faster settling time after PID tuning.
Currently most of the published data on PID control of drilling vibrations is based on synthetically generated data from simulations. The PID tuning presented in the paper is instead based on experimental tests and measurements. This methodology highlights the importance of considering drilling dynamics in accurate and robust PID tuning.

Conclusions
An experimental setup capable of switching between a vertical and a horizontal configuration has been built and used to understand the top drive response under a simple PID control system.