*Article* **Eliminating Stick-Slip Vibrations in Drill-Strings with a Dual-Loop Control Strategy Optimised by the CRO-SL Algorithm**

**Jorge Pérez-Aracil 1,\*, Carlos Camacho-Gómez 2, Emiliano Pereira 1, Vahid Vaziri 3, Sumeet S. Aphale <sup>3</sup> and Sancho Salcedo-Sanz <sup>1</sup>**


**Abstract:** Friction-induced stick-slip vibrations are one of the major causes for down-hole drill-string failures. Consequently, several nonlinear models and control approaches have been proposed to solve this problem. This work proposes a dual-loop control strategy. The inner loop damps the vibration of the system, eliminating the limit cycle due to nonlinear friction. The outer loop achieves the desired velocity with a fast time response. The optimal tuning of the control parameters is carried out with a multi-method ensemble meta-heuristic, the Coral Reefs Optimisation algorithm with Substrate Layer (CRO-SL). It is an evolutionary-type algorithm that combines different search strategies within a single population, obtaining a robust, high-performance algorithm to tackle hard optimisation problems. An application example based on a real nonlinear dynamics model of a drill-string illustrates that the controller optimised by the CRO-SL achieves excellent performance in terms of stick-slip vibrations cancellation, fast time response, robustness to system parameter uncertainties and chattering phenomenon prevention.

**Keywords:** stick-slip; drill-strings; vibration control; coral reefs optimisation; meta-heuristics

#### **1. Introduction**

Stick-slip phenomena occur when, due to a particular confluence of parameters, the bit–rock interaction is such that rather than a constant (ideally synchronous) rotating speed of the top drive and the drill-bit, the drill-bit speed varies between zero and six times the speed of the top drive at the top of the drill-string. This unwanted phenomenon severely impacts the achieved rate of penetration during most drilling operations. In severe cases, this can lead to faster degradation of drill-bits and in rare cases warping or breaking of the drill-string [1]. To thoroughly understand this highly nonlinear phenomena, several drillstring models have been proposed in the literature [2–5]. Consequently, several bit–rock interaction models have also been proposed and validated [4,6,7]. The importance of the stick-slip vibrations problem has been widely analysed in [8–11]. In these previous works, researchers focus on understanding of the drill-string dynamics, the bit–rock interaction and the quantification of stick-slip vibrations. The current research aims to reduce the effects of the stick-slip phenomena during the drilling operation.

Vibration control in nonlinear systems is a problem that can be solved by linear and nonlinear controllers [3,12]. These controllers may be designed by using optimisation algorithms [13]. The problem of mitigating stick-slip vibrations in drill-strings is a wellknown nonlinear control problem [3]. Some of the more recent and noteworthy approaches include the bit speed and torque independent stick-slip compensator [14], sliding-mode

**Citation:** Pérez-Aracil, J.; Camacho-Gómez, C.; Pereira, E.; Vaziri, V.; Aphale, S.S.; Salcedo-Sanz, S. Eliminating Stick-Slip Vibrations in Drill-Strings with a Dual-Loop Control Strategy Optimised by the CRO-SL Algorithm. *Mathematics* **2021**, *9*, 1526. https:// doi.org/10.3390/math9131526

Academic Editor: Stevan Dubljevic

Received: 1 June 2021 Accepted: 25 June 2021 Published: 29 June 2021

**Publisher's Note:** MDPI stays neutral with regard to jurisdictional claims in published maps and institutional affiliations.

**Copyright:** © 2021 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (https:// creativecommons.org/licenses/by/ 4.0/).

controllers [15], feedback controllers by including the axial and torsional motions in the numerical model [16], the use of robust controllers based on proportional-derivative feedback control design to keep a constant drill-bit rotation speed [17]. The use of Kalman filter based full-state feedback controllers was proposed in [18]. Sliding-mode controllers have shown very good results in the problem of reducing stick-slip vibration issues [19–21]. This fact arises from the good qualities of this controller, such as: robustness against inaccuracies related to the model and/or unpredicted dynamics. It also has a wide disturbance rejection and broad control bandwidth. It has been recently presented in [15,22] for eliminating stick-slip vibrations. The use of proportional-integral-derivative (PID) motivated linear controllers have also been proposed to address the stick-slip [23].

The complexity of the design of vibration controllers for drill-strings justifies the use of optimisation algorithms; in many cases, these are meta-heuristics approaches. Thus, the problem of stick-slip vibration has been solved by using optimisation algorithms [24,25]. In Reference [24], a torsional vibration control approach based on the genetic algorithm is studied. In [25], the authors show the use of a dynamic programming technique to design the optimal control of nonlinear systems. The Nelder–Mead method has been applied to design the controllers of multiple isolators situated on the same supporting structure [26]. In addition, some variants of the well-known genetic meta-heuristics algorithm have been applied to structural optimisation problems. In [27], the authors proposed a fuzzy control and a genetic algorithm for structural shape optimisation. In [28], the optimisation of 3D trusses was tackled with a Grouping Genetic Algorithm (GGA). In [29], a microgenetic algorithm (*μ*-GA) was used for impact load identification and characterisation of concrete structures. For the plane stress problem, a variant of the Evolutionary Structural Optimisation (ESO) algorithm was proposed in [30]. Finally, in [31], the GA and among other meta-heuristic methods were implemented to obtain the optimal parameters in the welded beam structure problem. The particle swarm optimisation (PSO) algorithm introduced in [32] is also an important meta-heuristic that has been successfully applied to structural optimisation problems such as in [33], where the so-called democratic-PSO was proposed for truss layout with frequency constraints, or in [34], where optimal sizing design of truss structures was studied. The teaching-learning-based algorithm [35] has also been applied to optimise mechanical design problems [36,37]. The Harmony Search (HS) approach [38] has also been applied to structural optimisation; however, in [39], the authors aimed at two main ideas: firstly, they gathered a large number of meta-heuristics that have been used in structural optimisation; secondly, they reflected about the lack of mathematical background in meta-heuristics basics and the contributions of the HS. In the last decade, a new kind of meta-heuristics based on physics phenomena have been applied to structural optimisation problems. The Big-Bang Big-Crunch algorithm was updated in [40] to a memetic algorithm by mixing it with a local search process called the quasi-Newton method and was proposed to find the optimal weight of the structure. The Colliding Bodies Optimisation [41], the Ray Optimisation [42] or the Charged System Search [43] algorithms were created by A. Kaveh and tested in the welded beam design problem.

The concept of modified output, which was firstly introduced in [44], is used in this paper to propose a new control approach for eliminating stick-slip vibrations in drillstrings. The controller is based on a dual-loop linear control scheme. The inner loop, whose feedback signal is a combination of output signals, damps the vibration of the system, eliminating the limit cycle due to nonlinear friction. The outer loop achieves the desired velocity with a fast time response. The performance of the controller is improved by the use of a multi-method ensemble meta-heuristic, the Coral Reefs Optimisation algorithm with Substrate Layer (CRO-SL) [45,46], is adopted. This ensemble method was successfully applied in other engineering problems, such as [47–49]. In [47], the problem of optimal design and location of tuned mass dampers for structures subjected to earthquake ground motions is solved. In [48], the complex problem of design and location of inertial mass dampers for floor based structures subjected to human induced vibration is tackled. In [49], the design of submerged arch structures is approached. All the problems show that CRO-SL

can be suitable for obtaining global optimum designs, with affordable computation time in complex vibration control problems. Consequently, the CRO-SL algorithm is applied to find the best configuration of the control parameters, i.e., obtaining the four controller parameters needed to eliminate stick-slip vibrations in a drill-string model with system uncertainties. The objective function to solve the problem is a functional that considers vibration, steady-state error and control effort.

The structure of the remainder of the paper is as follows: Section 2 presents the mathematical model of the drill-string, the bit–rock interaction and the model verification. Section 3 describes the proposed control scheme along with the CRO-SL optimisation algorithm, including the definition of a substrate layerand how this approach can be considered as a multi-method ensemble optimisation algorithm. Section 4 presents the optimisation results as well as the closed-loop results for the drill-string system, where the proposed algorithm's performance is evaluated. Section 5 closes the paper by giving some final conclusions and remarks on this research.

#### **2. System Model**

To realistically reproduce the stick-slip phenomena occurring in drill-strings and enable the implementation and testing of various control schemes, a scaled drill-string piece of equipment was set up at the Centre for Applied Dynamics Research, University of Aberdeen [22]. The following subsections describe the two-degrees-of-freedom (DOF) mathematical model that accurately captures the drill-string dynamics. The bit–rock interaction model is also described along with the system parameters on which the presented control design and analysis is based on.

#### *2.1. Mathematical Model*

As mentioned above, a 2-DOF model that accurately captures the stick-slip vibrations experienced by the drill-string is adopted. This is to ensure that the model is accurate, adequate and not overcomplicated. There are several works that have adopted a similar 2-DOF model [2,6,7,50].

The model lumps the drill-string components into two discs: (i) The upper disc that represents the top-drive system and (ii) the lower disc that represents the drill bit. Between the upper (top drive) and lower disc (drill bit), the drill-string is placed, mainly composed from a drill pipe and bottom hole assemble (BHA). A simple schematic of this model is shown in Figure 1. As labelled in Figure 1, the input torque that drives the system is denoted by *U*. The angular position of top drive is *φr*, its viscous damping is *cr*, and the inertia *Jr*. The pipe, which connects the top drive with the BHA, is modelled by its torsional damping *C* and the torsional stiffness *K*. The torque of friction on the lower disc, which models the interaction between the bit and the rock, is denoted by *Tb*. The angular position of the BHA is *φb*, and its inertia is *Jb*.

The equation of motion that encapsulates the entire system behaviour is then given by:

$$\bar{\phi}\_r = \frac{\mathcal{U}}{\bar{J}\_r} - \frac{\mathcal{C}\_r + \mathcal{C}}{\bar{J}\_r} \,\dot{\phi}\_r + \frac{\mathcal{C}}{\bar{J}\_r} \,\dot{\phi}\_b - \frac{\mathcal{K}}{\bar{J}\_r} (\phi\_r - \phi\_b) \tag{1}$$

$$\ddot{\phi}\_b = \frac{\mathcal{C}}{J\_b} \left\dot{\phi}\_r - \frac{\mathcal{C}}{J\_b} \dot{\phi}\_b + \frac{\mathcal{K}}{J\_b} (\phi\_r - \phi\_b) - \frac{T\_b}{J\_b} \tag{2}$$

However, to facilitate control design, the new state of the system can be initialised as follows:

$$\mathbf{x} = \left(\dot{\phi}\_{r\prime}\phi\_{r} - \phi\_{b\prime}\dot{\phi}\_{b}\right)^{T} = \left(\mathbf{x}\_{1\prime}\mathbf{x}\_{2\prime}\mathbf{x}\_{3}\right)^{T} \tag{3}$$

which further simplifies the system equation to:

$$\dot{\mathbf{x}}\_1 = \frac{\mathbf{U}}{I\_r} - \frac{\mathbf{C}\_r + \mathbf{C}}{I\_r} \mathbf{x}\_1 + \frac{\mathbf{C}}{I\_r} \mathbf{x}\_3 - \frac{\mathbf{K}}{I\_r} \mathbf{x}\_2 \tag{4}$$

$$
\dot{\mathbf{x}}\_2 = \mathbf{x}\_1 - \mathbf{x}\_3 \tag{5}
$$

$$\dot{\mathbf{x}}\_3 = \frac{\mathbf{C}}{I\_b}\mathbf{x}\_1 - \frac{\mathbf{C}}{I\_b}\mathbf{x}\_3 + \frac{\mathbf{K}}{I\_b}\mathbf{x}\_2 - \frac{T\_b}{I\_b} \tag{6}$$

**Figure 1.** Schema of the 2-DOF lumped-parameter model of the drill-string.

Equations (3)–(6) can be re-described as the following state-space system:

$$
\dot{\mathbf{x}} = \begin{bmatrix} -\frac{\mathbb{C}\_r + \mathbb{C}}{f\_r} & -\frac{\mathbb{K}}{f\_r} & \frac{\mathbb{C}}{f\_r} \\ 1 & 0 & -1 \\ \frac{\mathbb{C}}{f\_b} & \frac{\mathbb{K}}{f\_b} & \frac{\mathbb{C}}{f\_b} \end{bmatrix} \mathbf{x} + \begin{bmatrix} 1 \\ 0 \\ 0 \end{bmatrix} \frac{\mathcal{U}}{\mathcal{J}} + \begin{bmatrix} 0 \\ 0 \\ -1 \end{bmatrix} \frac{T\_b}{J\_b} . \tag{7}
$$

The problem of drill-string can be modelled as a linear part (Equation (7)) connected with the hard nonlinear model of the bit–rock interaction. This interaction is modelled by the torque *Tb* in Equation (7). This is explained below.

#### *2.2. Bit–Rock Interaction*

It is possible to distinguish three different phases in the bit–rock interaction: (i) stick phase: the drill-bit is not rotation since it is stuck with the rock, (ii) stick-to-slip phase: to begin slipping, the drill-bit has to achieve enough torque, (iii) slip phase: the drill-bit rotates and it is actually drilling [4,15,51,52].

It is important to note that the system is locked between phases (ii) and (iii). The sticking phase ends when the reaction torque reaches the peak value. The slip phase starts when the drill-bit starts to rotate. For *x*<sup>3</sup> = 0, the dry friction is estimated by combining a zero band velocity introduced in [53] and the switch model in [54].

When *x*<sup>3</sup> = 0, the dry friction is approximated by combining a zero band velocity introduced in [53] and the switch model in [54]. This is as follows:

$$T\_b = \begin{cases} \mathsf{r}\_{r\prime} & \text{if } |\mathsf{x}\_3| < \tilde{\zeta} \quad \text{and} \quad |\mathsf{r}\_r| \le \mathsf{r}\_s\\ \mathsf{r}\_s \cdot \text{sgn}(\mathsf{r}\_r), & \text{if } |\mathsf{x}\_3| < \tilde{\zeta} \quad \text{and} \quad |\mathsf{r}\_r| > \mathsf{r}\_s\\ \mu\_b \cdot \mathsf{R}\_b \cdot \mathcal{W}\_{ob} \cdot \text{sgn}(\mathsf{x}\_3), & \text{if } |\mathsf{x}\_3| \ge \tilde{\zeta} \end{cases} \tag{8}$$

where *sgn* stands for the *sign* function,

$$\operatorname{sgn}(x) = \begin{cases} 1 & x > 0 \\ 0 & x = 0 \\ -1 & x < 0 \end{cases}$$

The frictional torque when the drill–bit interaction occurs can be formulated as *τ<sup>r</sup>* = *C*(*x*<sup>1</sup> − *x*3) + *K*(*x*2), which is the reaction torque, whilst *τ<sup>s</sup>* = *μsbRbWob* is the friction torque, *μsb* is the static friction coefficient, *Wob* is the Weight on Bit (WOB), *Rb* is the bit radius. A set of drill-string realistic simulation parameters was obtained in [2,22], and these parameters are tabulated in Table 1.

**Table 1.** The basic realistic drill-string physical parameters for the model.


#### **3. Control Design and Parameter Optimisation**

The problem of control of stick-slip oscillations in drill-strings bears some similarity to the problem of control of one-link flexible manipulators. It is clear that as the sensors and actuators for these systems (flexible robot and drill-string) are not physically located at the same spot (not co-located). Therefore, these systems are non-minimum phase in nature. Moreover, the Coulomb friction present in the joint of the robotic manipulator can be treated as a complication similar to the drill-string's nonlinear friction in the bit–rock interaction model (presented in Equation (8)). In the case of the flexible manipulator, modified outputs, like the reflected tip position in one-link flexible manipulators [44,55], have been proposed in the past in order to solve this seemingly complicated problem. These modified outputs have been used to propose simple control schemes, which achieves the objectives of tracking and vibration control [44,55,56]. In addition, these controllers guarantee the stability of the highly unconsidered vibration mode (spillover).

The proposed linear control is inspired by the aforementioned controllers applied to flexible robotic manipulators, where the objective is to cancel the vibrations at the tip with an actuator placed at the joint. The proposed controller is shown in Figure 2. Note that there are two nested loops. The first one is used to stabilise the system, cancelling the vibration of drill-string, which is due to the vibration modes of the linear part and the nonlinear dynamics of the bit–rock interaction.

The controlled input of the inner loop (*UIL*) is as follows:

$$
\dot{\omega} I\_{IL} = \frac{\beta}{\alpha} (\phi\_r - \phi\_b) - \frac{1}{\alpha} \dot{\mathcal{U}}\_{IL\prime} \tag{9}
$$

where *α* and *β* are the parameters used to obtain the modified output of the drill-string. The objective of the outer loop is to achieve a desired velocity of the top drive. Thus, if the inner loop (9) cancels the vibration, the outer loop can achieve the desired velocity of BHA. This outer loop is as follows:

$$dL\_{OL} = P(\dot{\phi}\_{r,ref} - \dot{\phi}\_r) + I(\phi\_{r,ref} - \phi\_r), \tag{10}$$

where *P* and *I* are the proportional and integral constants of the tracking controller. The proposed control law can then be written as follows:

$$
\mathcal{U} = \mathcal{U}\_{IL} + \mathcal{U}\_{OL}.\tag{11}
$$

**Figure 2.** The adopted dual-loop control scheme. The inner loop consists of a damping controller, which uses the modified output *x*<sup>2</sup> *Cd*, and the outer loop consists of a tracking controller (proportional and integral).

The optimal control parameters are tuned according to a functional, which considered the following issues:


The functional is defined as follows:

$$J(\mathbf{z}) = \gamma\_1 I\_1 + \gamma\_2 I\_2 + \gamma\_3 I\_3 + \gamma\_4 I\_4. \tag{12}$$

where *γ*1, *γ*2, *γ*3, and *γ*<sup>4</sup> are the terms that ponderate each sub-functional. These subfunctionals are as follows:

$$\begin{aligned} J\_1 &= \left| \dot{\phi}\_{r,ref} - \dot{\phi}\_r(t\_f) \right|, \\ J\_2 &= \max\_{t \in (t\_i, t\_f)} |\dot{\phi}\_b(t) - \dot{\phi}\_r(t)|, \end{aligned} \tag{13}$$

$$\begin{aligned} J\_3 &= t\_{set,r} + t\_{set,b}, \\ J\_4 &= \frac{1}{N} \sum\_{t=t\_{set,r}}^{t\_f} (\mathcal{U}(t) - \mathcal{U}\_{OL}), \end{aligned} \tag{13}$$

where *ti* is the time at which the controller is engaged, *tf* is the final value of time considered in simulations and *N* is the number of samples considered between *tf* and *ti*. The variables *tset*,*<sup>r</sup>* and *tset*,*<sup>b</sup>* are the settling time of *φ*˙*<sup>r</sup>* and *φ*˙ *<sup>b</sup>* after the value of *ti* and considering a final value equal to *φ*˙ *<sup>r</sup>*,*ref* with an error of ±4 %. The variable **z** is defined by the controller parameters: *P*, *I*, *β* and *α*. Note that the initial conditions of Equation (7) are considered in *<sup>J</sup>*2, where the max*t*∈(*ti*,*tf*)|*φ*˙ *<sup>b</sup>*(*t*) − *<sup>φ</sup>*˙*r*(*t*)| depends on the system response before *ti*. The functional *J*<sup>1</sup> and *J*<sup>4</sup> consider the values of *φ*˙*<sup>r</sup>* and *U* after *tset*,*r*.

Due to the nonlinear nature of the system, control parameter tuning is not straightforward. Thus, a suitable optimisation algorithm can be used in order to automate the process, ensure stable results and significantly improve the control performance. The Coral Reef Optimisation (CRO) is a meta-heuristic algorithm for optimisation that has been recently proposed as a highly-effective algorithm for such problems [48,57–59]. This work uses an improved version of the CRO algorithm to generate the controller parameters namely *β*, *α*, *P* and *I*.

#### *Coral Reefs Optimisation Algorithm with Substrate Layer: A Multi-Method Ensemble Approach*

The CRO-SL is a further version of the original CRO [57], which was founded on the processes that occur in a coral reef, including reproduction, fight for space or depredation [46]. The basics can be shown in the pseudo-code below, Algorithm 1, with the different CRO phases where the individuals (also called corals) are initialised in the population (or reef), along with all the operators applied to guide the search.

#### **Algorithm 1** Pseudo-code for the original CRO

**Require:** Valid configuration of parameters controlling the CRO algorithm **Ensure:** A single individual with near-optimal value of its *fitness*

1: Initialize the corals and the reef


As has been mentioned before, the CRO-SL is an improved version of the CRO, firstly proposed in [60] and further developed in [45]. It is considered as a low-level ensemble method for optimisation, which combines several search processes in parallel over different subpopulations and with information exchange between them, leading to extremely good search capabilities. The CRO-SL has the same structure as shown in the pseudo code of the basic CRO, but including substrate layers or subpopulations, wherein each one is implementing a different search procedure or strategy. A substrate may represent different models, operators, parameters, constraints, repairing functions, etc., though this version, which represents different search operators, has been the most successful version so far. Thus, the CRO-SL is an ensemble approach that promotes cooperative co-evolution. The use of CRO-SL as a cooperative multi-method ensemble has been successfully tested in different applications and problems, such as battery scheduling and topology design in micro-grids [58,61], medical image registration [59], antenna design [62] and vibration cancellation problems in buildings [47] and open floors [48]. This wide application demonstrates the potency of the CRO-SL and deems it an ideal candidate for optimising controller parameters for eliminating stick-slip vibrations in drill-strings. Details of the overall CRO-SL algorithm and the mechanism to include substrate layers is well-reported in [45].

Although different search strategies have been defined at the practitioner's discretion, this work has taken into account a five-substrate construct of the CRO-SL. They are briefly described below:

1. Harmony Search (HS): It is a metaheuristic method based on stochastic optimisation [38]. It imitates the process found in music improvisation, which searches for better harmony. There are two parameters that determine the way in which new larvae are generated: (i) Harmony Memory Considering Rate (HMCR), which ranges from zero to one. If a uniformly spawned value is above the value of HMCR, then the encoded parameter value is uniformly drawn from the values in the coral, (ii) Pitch

Adjusting Rate (PAR), which ranges from zero to one, which sets the probability of choosing a neighbour value of the current larva.


$$f\_{G(0,\sigma^2)}(\mathbf{x}) = \frac{1}{\sigma\sqrt{2\pi}}e^{-\frac{\mathbf{x}^2}{2\sigma^2}}.$$

With the aim of exploring the search space at the beginning of the optimisation process and exploiting it at the end, the parameter *σ* is adapted during the simulation.

#### **4. Computational Evaluation**

This section presents the computational evaluation of the proposed control algorithm for stick-slip vibrations cancellation, optimised with the CRO-SL algorithm. The open-loop parameters of the drill-string system are given in Table 1. The torsional stiffness (*K*) is considered as a variable parameter and the velocity reference (*φ*˙ *<sup>r</sup>*,*ref*) is selected to be within 2 and 5 rad/s (acceptable practical range). The system is simulated for 40 s in an open-loop after which the loop is closed and the proposed dual-loop control scheme is engaged. The value of the control input (*U*) in Equation (11) is limited to *U* ∈ [20, 80] N·m. This is to ensure that the control input lies within the practical limits [7,22].

The CRO-SL algorithm searches for the best solution in terms of Equation (12) for *<sup>K</sup>* ∈ {5, 10, 20} <sup>N</sup>·m/rad and *<sup>φ</sup>*˙ *<sup>r</sup>*,*ref* ∈ {2, 3, 4, 5}. The values of torque needed to obtain this velocity are *U* ∈ {30.2, 41.42, 52.65, 63.9} N·m. The parameters of Equations (12) and (13) are:


The CRO-SL parameters used in the experiments are shown in Table 2.


**Table 2.** Parameters values used in the CRO-SL.

The optimisation results obtained with the CRO-SL are presented in Figure 3. Figure 3a shows the ratio for which each substrate generates the best larva in the CRO-SL approach.

**Figure 3.** Evolution of different quality parameters in the CRO-SL; (**a**) evolution of the number of larvae that are finally allocated into the reef as new solutions; (**b**) ratio of times that each substrate produces the best larva in each iteration of the CRO-SL algorithm; (**c**) evolution of the best solution within the CRO-SL.

It is possible to see how DE is the one exploration operator that contributes the most to the CRO-SL search. The contribution of the GM and 2Px are also significant, but they decrease during the search. Figure 3b shows the number of larvae that are produced in the reef for each iteration, as new solutions. Figure 3c shows the evolution of the best solution within the CRO-SL. It is important to note that around 20 iterations, the proposed approach achieves the optimal solution. The final value of the functional (Figure 3c) is *J* = 8.1560, which corresponds with *<sup>K</sup>* = 10 N·m and *<sup>φ</sup>*˙ *<sup>r</sup>*,*ref* = 5 rad/s. The controller parameters are shown in Table 3.

**Table 3.** Optimal control parameters obtained by means of CRO-SL.


The next subsection shows the performance in terms of stick-slip vibrations cancellation, fast time response, robustness to system parameter uncertainties and chattering phenomenon prevention.

#### *Results*

First of all, the closed-loop system configured with the above shown parameters is simulated to generate time responses for the nominal conditions (*K* = 10 N·m/rad and a *φ*˙ *<sup>r</sup>*,*ref* = 2.5 rad/s). The controller starts at 40 s, the value of *ti* used in optimal design. Two values of restrictions for control input torque are used. The first one corresponds to *U* ∈ [20, 80] N·m, which is the restriction used in the optimisation process. The second one is a naive selection corresponding to *U* ∈ [−100, 100] N·m. Figure 4 shows the angular velocity of the top-drive, drill-bit and input torque signal against the time variable. It is clear after some careful understanding of the system that negative values of control input torque require the top-drive to rotate in the opposite direction to the standard drilling. This is, in practice, an unacceptable scenario as physically reversing the motor's direction of rotation is an almost impossible task on the field. However, it is likely that this might be possible or even required in some scenarios (drill-bit retrieval). The objective of these experiments is to show that the controlled system optimised with the CRO-SL scheme is stable in both scenarios.

**Figure 4.** Time histories of the angular velocity of the top-drive, drill-bit and input torque signal for a desired velocity (2.5 rad/s) and *K* = 10 N·m/rad: (**a**) angular velocity of the top-drive and drill-bit when *U* ∈ [20, 80] N·m; (**b**) angular velocity of the top-drive and drill-bit when *U* ∈ [−100, 100] N·m; (**c**) input torque when *U* ∈ [20, 80] N·m; (**d**) input torque when *U* ∈ [−100, 100] N·m.

Figure 5 shows how the controller of Figure 2 can eliminate the limit cycle of the stick-slip. The controller starts at *t* = 75 s in order to guarantee that the limit cycle is in steady-state for all the reference values (*φ*˙ *<sup>r</sup>*,*ref*(*t*)) when *U* ∈ [20, 80] N·m (see Figure 5e). Figure 5a,b shows the stick-slip limit cycle in an open-loop for *U* = 36 N·m and its corresponding 2D phase-plane portrait, respectively. Figure 5c shows the corresponding 3D perspective with respect to time in order to better clarify the transient response. Figure 5d shows the motor torque *U*. In this example, the open loop torque is *U* = 36 N·m. The controller is turned on at *t* = 75 s, and the control input undergoes a brief period of transients, with its permanent value equal to *U* = 36 N·m. Figure 5e shows how the controller can stabilise the stick-slip for *U* ∈ [30, 69.5] N·m. It is important to highlight that desired velocity can be achieved from any initial value of input torque in an open loop.

**Figure 5.** The red line and the blue line stand for uncontrolled and scheme controlled, respectively. (**a**–**c**) The time-history, 2D and 3D phase-portraits, respectively. (**d**) The control input versus time. (**e**) The complete bifurcation diagram showing all types of behaviour.

An additional robustness analysis is carried out. Figure 6a shows the value of the functional (*J*) as a function of the desired velocity and stiffness value. Figure 6a shows that the maximum value of *<sup>J</sup>* is achieved for *<sup>K</sup>* = 10 N·m/rad and a *<sup>φ</sup>*˙ *<sup>r</sup>*,*ref* = 5 rad/s. In addition, the most unfavourable case for each value of *K* is the maximum value of the desired velocity. Then, three examples are plotted in order to show how the stick-slip limit cycle is cancelled. In these examples, like in Figure 5, the controller starts at *t* = 75 s in order to guarantee that this vibration is in a steady-state for all the cases. Thus, Figure 6b–d shows how the controlled system eliminates the stick-slip vibrations for *K* equal to 5, 10 and 20 N·m/rad, respectively. Note that, although a large torque control input is needed, after the settling time, all time responses are the same, showing that the controller effectively eliminates the stick-slip vibrations for all these cases. In addition, Figure 6e–g shows the input torque when *U* ∈ [20, 80] N·m for *K* equal to 5, 10 and 20 N·m/rad, respectively.

(**a**)

**Figure 6.** Robustness analysis: (**a**) value of the functional (*J*) for different values of the desired velocity and stiffness values; (**b**) angular velocity of the top-drive and drill-bit for *K* = 5 N·m/rad; (**c**) angular velocity of the top-drive and drill-bit for *K* = 10 N·m/rad; (**d**) angular velocity of the top-drive and drill-bit for *K* = 20 N·m/rad; (**e**) input torque when *U* ∈ [20, 80] N·m for *K* = 5 N·m/rad; (**f**) input torque when *U* ∈ [20, 80] N·m for *K* = 10 N·m/rad; (**g**) input torque when *U* ∈ [20, 80] N·m for *K* = 20 N·m/rad.

Finally, a final case is simulated in order to show the problem of the control effort (chattering phenomenon), which is avoided by including *J*<sup>4</sup> (see Equations (12) and (13)), justifying the use of the optimisation algorithm. Thus, the tuning of *P*, *I*, *β* and *γ* is carried out according to the following practical guide: (i) increases the values of *P* and *I* in order to achieve a good time response for the top-drive, (ii) modified *β* in order to reduce the oscillation between drill-bit and top-drive angular velocities and (iii) tune a small, but not equal to zero, value for *α*, in order to avoid possible practical problems with offset in *x*2. The control parameters are shown in Table 4.


**Table 4.** Control parameters for the non-optimised case.

Figure 7 shows the time histories for the angular velocity of the top-drive, drill-bit and input torque signal for a desired velocity of 2.5 rad/s and *K* = 10 N·m/rad (i.e., the nominal conditions). Note that the time responses of the top-drive and the drill-bit are good and comparable with Figure 4. However, the control effort (chattering phenomenon) for both cases is not admissible because it can damage the actuator. In addition, the design of this controller for a wider range of *K* (parameter uncertainty) and desired velocities is not obvious. This justifies the use of CRO-SL, which simplifies and improves the control parameter selection, consequently resulting in improved closed-loop performance.

**Figure 7.** Non-optimised design: time histories of the angular velocity of the top-drive, drill-bit and input torque signal for a desired velocity (2.6 rad/s) and *K* = 10 N·m/rad. (**a**) angular velocity of the top-drive and drill-bit when *U* ∈ [20, 80] N·m; (**b**) Angular velocity of the top-drive and drill-bit when *U* ∈ [−100, 100] N·m; (**c**) input torque when *U* ∈ [20, 80] N·m; (**d**) input torque when *U* ∈ [−100, 100] N·m.

#### **5. Conclusions**

This work proposes a dual-loop control strategy to alleviate stick-slip vibration problems in drill-string applications. The inner loop controller is based on the concept of modified output, which has been used in the past to control non-collated systems. The results show that the combination of both velocities, the top-drive and the drill-bit, can eliminate the limit circle of the nonlinear system. The outer loop is used to achieve the desired drill-bit velocity within a low settling time and without steady-state error.

The advantages of optimising the controller parameters have also been shown in this work. The controller has been optimally tuned by using a multi-method ensemble meta-heuristic approach, the Coral Reefs Optimisation algorithm with Substrate Layers (CRO-SL). A functional function is defined in this work, which involves: (i) steady-state error, (ii) the residual vibration, (iii) the settling time and (iv) the control effort. Thus, the optimised controller is robust to parameter systems uncertainties, control input torque limitations and different tip velocities references, eliminating the chattering phenomenon in the control effort. Therefore, this dual-loop strategy, together with the optimisation procedure defined by the functional, has big potential in drill-string applications.

**Author Contributions:** Conceptualisation, E.P., S.S.A., J.P.-A., V.V., S.S.-S. and C.C.-G.; methodology, S.S.A., E.P., S.S.-S., J.P.-A., V.V.; software, J.P.-A., C.C.-G.; validation, S.S.A., E.P., S.S.-S., V.V. and J.P.-A.; formal analysis, J.P.-A., E.P., S.S.A, V.V.; investigation, J.P.-A., S.S.A., E.P., S.S.-S., C.C.-G. and V.V.; resources, S.S.A., V.V. and E.P.; data curation, J.P.-A., C.C.-G., E.P. and S.S.-S.; writing—original draft preparation, J.P.-A., E.P., S.S.-S. and S.S.A.; writing—J.P.-A., E.P., S.S.-S. and S.S.A.; visualisation, J.P.-A., E.P. and S.S.A.; supervision, S.S.-S., S.S.A. and E.P.; project administration, S.S.-S., S.S.A. and E.P.; funding acquisition, S.S.A. All authors have read and agreed to the published version of the manuscript.

**Funding:** This work was partially supported by the Spanish Ministerial Commission of Science and Technology (MICYT) through project number TIN2017-85887-C2-2-P.

**Data Availability Statement:** Not applicable.

**Acknowledgments:** The authors would like to thank Marian Wiercigroch and Vahid Vaziri from the Centre for Applied Dynamics Research, University of Aberdeen, for providing the realistic drill-string parameters used in this work.

**Conflicts of Interest:** The authors declare no conflict of interest. The funders had no role in the design of the study; in the collection, analyses, or interpretation of data; in the writing of the manuscript, or in the decision to publish the results.

#### **References**

