Adaptive Proportional Integral Derivative Nonsingular Dual Terminal Sliding Mode Control for Robotic Manipulators

: This article aims to develop a new Adaptive Proportional Integral Derivative (PID) Nonsin-gular Dual Terminal Sliding Mode Control, designed for tracking the position of robot manipulators under disturbances and uncertainties. Compared with existing PID Nonsingular Fast Terminal Sliding Mode (PIDNFTSM) controllers, this work effectively avoids singularity problems in control while signiﬁcantly enhancing the convergence speed of errors. An adaptive reaching law is proposed to estimate the bound information of the ﬁrst derivative of lumped disturbance by regulating itself based on sliding variables. The overall system stability is proven by using the Lyapunov approach. Subsequent simulation results verify the effectiveness of the proposed controller regarding tracking error reduction


Introduction
Sliding Mode Control (SMC) [1,2] is well known as an efficient nonlinear robust control strategy employed to deal with nonlinearities, uncertainties, and disturbances.The core principle of SMC involves driving and maintaining the system states on a predefined sliding surface.In the context of conventional Linear Sliding Mode Controllers (LSMCs), a linear hyperplane is utilized as the sliding surface, ensuring that the system states asymptotically converge to zero once the sliding mode surface is reached [3].In scenarios where the switching gains of SMC are higher than the upper bound of the disturbances and uncertainties term, the system states attain fast convergence.However, this comes at the expense of demanding high control inputs, which can result in reaching actuator saturation.Moreover, using large switching gains may cause undesired oscillations in the control signal, known as the chattering problem [4,5].
To overcome the convergence problem in LSMCs, Zhihong [6] developed Terminal Sliding Mode (TSM) controllers, a technique designed to achieve finite convergence without requiring high control input.Compared to LSMCs, the TSM controller has gained popularity in robust control because of its advantages, including faster time convergence and small steady-state errors.However, early TSM controllers suffer from two primary drawbacks: a slower convergence rate compared to LSMCs for states distant from the equilibrium point, and a singularity problem, arising from negative power in its application [7].The singularity problem leads to an infinite control input, which is impracticable in application [8].To deal with the first problem, Yu [9] introduced Fast Terminal Sliding Mode (FTSM) controllers to increase the convergence speed of the errors by combining TSM and LSM controllers.In addition, Ma [10] also presented Dual Terminal Sliding Mode (DTSM) controllers to improve the convergence speed of the system by incorporating nonlinear terms into sliding surfaces.These approaches not only inherit the advantages of SMC but also increase the stability performance of the system and accelerate the convergence rate near the equilibrium point.Despite these advancements, singularity problems still exist in these methods.To handle the singularity problem and increase the convergence speed, Refs.[11][12][13] introduced Nonsingular Terminal Sliding Mode (NTSM) controllers.These controllers effectively eliminate the singular problem of the TSM controller; however, they require more time for the states to reach the sliding surface.Therefore, TSM and FTSM controllers have already been employed widely in practical applications [14], often with the utilization of boundary layer approaches [15] or saturation techniques [16] to circumvent the singularity issues.However, these controllers still produce unexpected chattering [17], characterized by high-frequency switching in the control input.Chattering causes undesired results such as a diminished control accuracy, increased heat loss in electric circuits and heightened wear of moving parts [18].In addition, it may stimulate unmodeled dynamics and trigger unforeseen instability.There are several ways to deal with this problem by reducing or softening chattering action.In [19], a boundary layer using a saturation function was employed to alleviate the chattering of the control input.However, this method degrades the robustness and system performance.A wide boundary layer can result in a large steady-state error, while a narrow boundary layer may not efficiently reduce the chattering phenomenon.Another effective control is to use High Order Sliding Mode Control (HOSMC) [20,21], which hides the discontinuity of control in its higher derivatives.Therefore, to enhance the robustness of controllers and reduce chattering, Mobayen [22] developed a PID-based TSM controller.This idea was further developed by Mien [23], where PID Nonsingular Fast Terminal Sliding Mode (PIDNFTSM) inherits the advantages of both PID and Nonsingular Fast Terminal Sliding Mode (NFTSM) to increase the finite time convergence of NFTSM.Zhong in [24] also combined the PID and FTSM to enhance the performance of FTSM in redundant robots.These combinations significantly improved the properties of SMC.However, in the control law [23], a singularity problem arises due to the | ė(t)| 1−p/q , p/q > 1 term at ė(t) = 0 in the control input.Similarly, in the control law [24], there exists a singularity introduced by the term |e(t)| ω 2 −1 , ω 2 < 1 at e(t) = 0 as well.
Motivated by the above discussion and to the author's best knowledge, this work may be the first proposed controller integrating the PID and DTSM to improve the convergence speed of DTSM controllers.Additionally, this integrated approach offers chattering-free operation and addresses singularity problems.The proposed controller is implemented in a robot manipulator, which is a benchmark of interest in developing and evaluating new nonlinear controllers [25,26].The main contributions of this article are summarized as follows: (1) This study introduces a new type of PID-based DTSM controller aimed at improving the convergence and tracking accuracy of the DTSM controller.In contrast to the existing PIDNFTSM [23,24], the proposed controller avoids the singularity problem in control input.Compared to the DTSM and PIDNFTSM, the proposed controller demonstrates superior robustness, enhanced tracking accuracy, chattering-free operation and effective singularity avoidance.(2) The reaching law in [23] is a pure integrator which presents challenges in hardware implementation [27].Therefore, this work employs a continuous reaching law to provide the smooth control input as a low pass filter.(3) The continuous reaching law strictly requires the bound of the derivative of lumped disturbances and uncertainties.Therefore, an adaptive continuous reaching law is developed to estimate this crucial information.In this approach, obtaining knowledge of disturbances is unnecessary for designing the proposed controller.
The structure of the remaining manuscript is organized as follows.Section 2 presents the dynamic model of the robot manipulator and problem formulation.The proposed controller is introduced in Section 3. Section 4 outlines simulation studies and comparisons.Finally, the conclusions drawn from the study are encapsulated in Section 5.

The Dynamic Model of the Robot Manipulator and Problem Formulation
The general dynamic model of the n-link robotic manipulator is described by the following Euler-Lagrange formulation [11]: H(q(t)) q(t) + C(q(t), q(t)) q(t) + G(q(t)) = τ(t) + τ d (t), where q(t), q(t), q(t) ∈ R n×1 denote the vector of acceleration, velocity and joint angular position, respectively; H(q(t)) ∈ R n×n is the inertia matrix; C(q(t), q(t)) ∈ R n×n denotes the centrifugal and Coriolis matrix; G(q(t)) ∈ R n×1 contains gravitational forces; τ(t) ∈ R n×1 is the control input; and τ d (t) ∈ R n×1 is the external disturbance.
In practice scenarios, the accurate values of these matrices H(q), C(q, q), G(q) are difficult or impossible to obtain due to measurement errors, load variations and external disturbances [28].Therefore, only nominal values are available for control design, and the actual parameters are assumed as follows: C(q, q) = C 0 (q, q) + ∆ ∆ ∆C(q, q), where H 0 (q), C 0 (q, q), G 0 (q) are nominal values.∆ ∆ ∆H(q), ∆ ∆ ∆C(q, q), ∆ ∆ ∆G are uncertain values of these parameters.Thus, the dynamic model of the robot manipulator in (1) is rewritten as H 0 (q) q + C 0 (q, q) q + G 0 (q) =τ(t) + F d (t), where F d is a lumped disturbance, which is defined by The main goal of this work is to introduce a new controller that embodies qualities such as a higher tracking accuracy, a faster convergence speed, singularity avoidance and a higher stability.Let q d (t), qd (t) and qd (t) be the desired position, velocity and acceleration, respectively.Thus, the position error e(t) ∈ R n×1 , velocity error ė(t) ∈ R n×1 and acceleration tracking error ë(t) ∈ R n×1 are defined as e(t) q(t) − q d (t),

Controller Design
The schematic control diagram of the proposed control for the robot manipulator is given in Figure 1.The sliding surface of the proposed controller is described as [22]: where If the condition σ(t) = 0 is satisfied, K p , K i and K d are selected to make K p ṡ(t) + K i s(t) + K d s(t) strictly Hurwitz [22], and the dynamic sliding surface s(t) converges to zero exponentially.s(t) ∈ R n×1 is the DTSM taken from [10] and is explained as follows: where e(t) [α] ∈ R n×1 , with the elements e i (t) [α] = |e i (t)| α sign(e i (t)), i = 1, 2, . . ., n, where α is a positive design parameter ranging in 0 < α < 1; ) ∈ R n×n are diagonal positive definite matrices.The detailed selection of K 1 and K 2 was provided in reference [10].
Taking the derivative of s(t) with respect to time, σ(t) is written as where • is the element-wise product, u f ∈ R n×1 , where the elements are given as follows: where the subscript i denotes the ith row in the vector and the ith entry in the diagonal matrix.Substituting ( 9) into (12), the sliding surface σ(t) becomes To simplify σ(t), define Γ Γ Γ(q, q, q d , qd , qd Then, σ(t) is constructed as Assumption 1 ([29]).The time derivative of Λ Λ Λ(q, F d ) in system ( 18) is bounded by where Υ d i > 0 is a constant.This upper bound is assumed to be unknown.
The control input τ(t) ∈ R n×1 consists of the equivalent control τ eq (t) ∈ R n×1 and switching control τ sw (t) ∈ R n×1 .The proposed controller is suggested as [24] where the equivalent control τ eq (t) in the controller is used to reach the nominal stability of the closed control system in the absence of the lumped disturbance while the switching control τ sw (t) is used to ensure the discontinuity of the control law across a sliding surface σ(t) and provide additional control for dealing with presence of a lumped disturbance [30].
The switching control τ sw is chosen as the continuous reaching law [27] and its elements are expressed as where τ sw i (0) = 0; ξ is a small positive constant; Υ d i is a constant defined in (19); and the two constants, k > 0 and Υ t i , are selected to satisfy the following condition: In designing switching control ( 22)-( 24), it is difficult to determine Υ d i in (19), which results from uncertainties and disturbances.Therefore, the adaptive continuous reaching law is proposed as follows: where Υi (t) is a time-varying scalar term which estimates the bounded constant Υ d i + Υ t i , and is adopted as Then, the estimated error Υi (t) is defined as Remark 1. From ( 21), ( 15) and ( 13), the singularity of equivalent control τ eq (t) appears in term u f when e i (t) = 0 and ėi (t) = 0. Therefore, the u f i term in ( 13) is alternated by a saturation function [16] sat(u f i , u s ) to avoid the singularity problem.The saturation function [16] is explained as with u s > 0. The system (5) stabilizes in finite time without singularity problems occurring during the regulation process.The proof is similar to the graphical analysis in [16].
Remark 2. In the proposed controller, K p s(t) maintains the properties of conventional DTSM [10].K i t 0 s(t) increases the robustness of the controller-like integral in SMC.K d ṡ(t) reduces the chattering similar to HOSMC [23].Therefore, the proposed PIDDTSM has simultaneously inherited the benefits of HOSMC, DTSM and integral SMC.Remark 3. Switching control is obtained in ( 25)-( 27) by the integral of switching control.Therefore, chattering caused by the sign function in ( 26) is eliminated.Moreover, the knowledge of the upper bound in Assumption 1 is relaxed by applying adaptive adjustment law (27).
Remark 4. q(t) is required in the proposed controller, which is difficult to measure directly.In general, differential signals are calculated directly by numerical difference.However, if the signal contains random noise, direct differentiation cannot be applied directly in the controller due to its noise sensitivity.Therefore, numerical differentiation could be used for the position signal q(t) with the low pass filter to avoid the effects of noise measurement [31].
Remark 5.The main difference between the proposed controller and [23] is that the singularity of control is avoided by Remark 1.In addition, the proposed controller improves the convergence speed of DTSM, which has a higher convergence speed than TSM.The adaptive reaching law of the proposed work works as the low-pass filter in practical experiments [12].Remark 6.In practice, σ(.) cannot be exactly driven to zero for all times due to measurement noise and time delays.Therefore, the adaptive law Υ(.) in (27) increases boundlessly, which causes a large overshoot and unwanted oscillation in the controller.The dead zone technique could be employed to solve this problem [32].The design adaptive law (27) is rewritten as where υ > 0. When the sliding surface σ i (t) > υ i , the adaptive parameters ˙Υ i (t) increase until they are large enough to cancel the disturbances and uncertainties Λ Λ Λ(q, F d ) i .The adaptive parameters are unchanged when the sliding surface σ i (t) < υ i .

Remark 7.
The choice of υ is essential.If υ is too small, σ i (t) cannot be lower than υ, which makes Υi (t) increase boundlessly.The control accuracy is reduced if υ is too large.
Based on the above analysis, the steps for implementing the proposed controller can be summarized as follows: Step 1. Define the position and velocity errors of joints using ( 7) and ( 8).

Simulation Results
The proposed controller, PIDNFTSM [23] and DTSM [10] have been developed for a two-link robot manipulator depicted in Figure 2 [11], enabling a performance comparison between them.
The dynamic model of two-link robotic manipulators given in ( 5) is described as follows [11]: G 0 (q) = p 5 cos(q 1 ) + p 6 cos(q 1 + q 2 ) where The parameters are given in SI units and set as m 1 = 0.5; m 2 = 1.5; r 1 = 1; r 2 = 0.85; J 1 = 5; J 2 = 5; g 1 = 9.8 [12].The lumped disturbance, including friction torques and uncertainties, is expressed as [35] F d (t) = 0.5 q1 + sin(3q 1 ) + 0.5sin( q1 ) The initial states are chosen as follows: q d (0) = [0 − 0.1] T (rad), and qd (0) = [0 0] T (rad/s) [36].The desired reference trajectories are given as follows [36]: The simulations are performed using the ODE-45 solver in MATLAB SIMULINK.The sampling period and simulation time are 0.001 s and 30 s, respectively.The corresponding parameters of different control systems will be set with the same values [37].The parameters K p , K i , K d of the proposed controller have the same values as those of the PIDNFTSM controller for each corresponding pair.The parameters α, K 1 and K 2 of the proposed controller are equal to those of the DTSM controller.Other parameters are selected based on the required conditions to achieve optimal performance.The parameters of controllers used in this simulation are given in Table 1.PIDNFTSM [23] p/q = 9/7; λ = 1.5;K 2 = diag(0.5,0.5); Remark 8. Generally, in practical implementation, the maximum torques of the first and second joints generated by the motor and reducer are typically limited.Therefore, in this work, the maximum torques given by the first and second joint are 100 Nm and 50 Nm, respectively.
Remark 9.The parameters are frequently chosen by trial and error to have the best performance.Therefore, this could be the limitation of this work.In future work, researchers can employ system identification to develop an accurate simulation model.With this improved model, offline optimization can be performed to determine the optimal controller parameters.
In this section, two simulation cases demonstrate the superiority of the proposed controller.
Figure 3 shows the position tracking of each joint corresponding to three different controllers.Three controllers enable each manipulator joint to move on the desired trajectory after different transient times.However, the overall tracking positions of the PIDNFTSM controller and the proposed controller are better than the DTDM controller.The proposed controller takes less transient time to track the desired profile, at about 6 s for both the first and second joint.The proposed controller and the PIDNFTSM controller achieve fast responses; however, the PIDNFTSM controller causes the largest overshoot in the initial stage and fluctuation in the tracking steady-state error.The tracking errors of each joint are determined between the actual trajectory and desired trajectory in Figure 4.The proposed controller drives the actual trajectory of the manipulator to track the desired trajectory without fluctuation.At the same time, there are small oscillations in PIDNFTSM and DTSM controllers.The proposed controller adjusts the positions of the joints to the desired trajectory in finite time with the small steady-state errors of 7 × 10 −4 rad and 2 × 10 −5 rad for the first joint and second joint, respectively, which are the highest tracking accuracies of the three controllers.The largest errors of the three controllers occur in the initial stage, caused by the initial condition of q(t).The tracking errors of the proposed controller enter the region of steady-state error after about 4 s for two joints and maintain a relatively small error.After the transition time of different controllers, the position errors of each joint converge to zero.The results indicate that the proposed controller achieves the highest accuracy and lower fluctuation errors than other controllers.For further quantitative analysis, the root mean square errors (RMSEs) of position tracking are given in Figure 5.The RMSE reflects how much the measured value deviates from desired values; the smaller the RMSE, the higher the accuracy.The proposed controller has the lowest RMSEs in the first and second joints of 0.03808 rad and 0.00889 rad, respectively.The actual control inputs are given in Figure 6, limited within 100 Nm and 50 Nm in the first and second joints, respectively.The proposed controller provides smooth control inputs and less oscillation than other controllers.
where e k is the kth sampling position error and n is the size of the position error vector.
The RMSE values of the proposed controller decreased by 25% and 50% for the first joint and 46% and 65% for the second joint, respectively, compared to the PIDNFTSM controller and the DTSM controller.To evaluate the energy consumption of each controller, energy control inputs (ECI) are designed as follows: where τ i (k) is the k(th) sampling control input of joint i and N is the size of the control input of the joint i vector.In Figure 7, the ECI values of the proposed controller are smaller than the PIDNFTSM in the first joint and second joint.Therefore, the proposed controller uses less energy than PIDNFTSM.However, the ECI of the proposed controller is slightly higher than DTSM in the second joint, whereas smaller than in the first joint.Case 2: To verify the robustness of the proposed controller, besides the presence of the lumped disturbance (51), the mass of the second joint m 2 can be assumed to increase to 2 kg after t ≥ 15 s.This is a sudden load variation involved in picking an object of the manipulator.
From Figures 8 and 9, it can be seen that the DTSM suffers unsatisfactory tracking performance under sudden loads, where the PIDNFTSM and the proposed controller quickly return to a steady state.The proposed controller requires about 4 s for both the first joint and second joint to reach the desired position profiles again, whereas the time recovery of other controllers is larger than the proposed controller in both joints.Moreover, the errors of both joints using the proposed controller are the smallest of the three controllers under the lumped disturbance and sudden load.Thus, the proposed controller is more robust, accurate and stable than other controllers.The RMSEs of the three controllers given in Figure 10 indicate that the proposed controller has the highest accuracy of the three controllers, where the RMSEs of the first joint and second joint are 0.03827 rad and 0.00903 rad, respectively.The control inputs of each controller are given in Figure 11.The control inputs of two joints using the PIDNFTSM controller are nearly identical to those of the proposed controller in the steady state.However, the singularity of the PIDNFTSM controller occurs frequently, resulting in sudden increases in the control signals.These sudden increases in control inputs cause oscillations in the tracking position and elevate steady-state errors.Figure 12 illustrates the energy consumption ECIs of each controller.Compared with PIDNFTSM, the proposed controller uses less energy in both joints.This can be explained by singularity avoidance in the proposed controller, which significantly reduces the control signal energy.

Conclusions
This paper proposes a novel controller that inherits the characteristics of both PID and DTSM controllers.Through its new design, the proposed controller avoids the singularity of DTSM and PIDNFTSM and guarantees the finite convergence of the tracking manipulator.The incorporation of an adaptive reaching law is designed to mitigate the requirement for precise knowledge of the derivative of the lumped disturbance.The proposed controller demonstrates rapid convergence, high accuracy and smooth control signals compared to DTSM and PIDNFTSM controllers.However, it should be noted that the present work is limited to simulation investigation solely.In order to show the feasibility of the approach and prove it from a theoretical perspective, experimental verification should be conducted in the course of the ongoing and future research, along with controller parameter optimization for a given particular problem considering modeling uncertainties.

Figure 1 .
Figure 1.Structure diagram of the overall control system.

Figure 3 .
Figure 3. Position tracking performance.(a) Position tracking performance of the first joint.(b) Position tracking performance of the second joint.

Figure 4 .Figure 5 .
Figure 4. Position tracking error of the second joint.(a) Position tracking error of the first joint.(b) Position tracking error of the second joint.

Figure 7 .
Figure 7. Energy control input of each controller.

Figure 8 .
Figure 8. Position tracking performance under sudden load.(a) Position tracking performance of the first joint.(b) Position tracking performance of the second joint.

Figure 9 .Figure 10 .
Figure 9. Position tracking errors under sudden load.(a) Position tracking error of the first joint.(b) Position tracking error of the second joint.

Figure 11 .Figure 12 .
Figure 11.Control inputs of manipulator.(a) Control input of the first joint.(b) Control input of the second joint.