Fuzzy Sliding Mode Control Based on Backstepping Synthesis for Unmanned Quadrotors

The main purpose of this paper is to integrate fuzzy logic technique and backstepping synthesis to sliding mode control to develop a Fuzzy Backstepping-Sliding Mode Controller (FBSMC) to resolve the problem of altitude and attitude tracking control of unmanned quadrotor systems under large external disturbances. First, a backstepping-sliding mode control for quadrotor is introduced. Moreover, a fuzzy logic system is employed to adapt the unknown switching gains to eliminate the chattering phenomenon induced by switching control on the conventional Backstepping-Sliding Mode Controller (BSMC). The dynamical motion equations are obtained by EulerNewton formalism. The stability of the system is guaranteed in the sense of the Lyapunov stability theorem. Simulation results are carried out using Matlab/Simulink environment to illustrate the effectiveness and robustness of the proposed controller.


Introduction
In recent years, Unmanned Aerial Vehicles (UAVs) have become a topic of interest in many research organisations because of their wide applications in several areas, such as enforcement of traffic rules and road networks surveillance, industrial plants and high-tension power lines, mapping three-dimensional environments and surveillance dangerous tasks that put human integrity at risk, etc. [1], [2], [3] and [4].These appli-cations require good flight control capabilities.Altitude and attitude tracking control are of main interests in quadrotors study.However, the controller design difficulty increases due to the dynamic nonlinearity, parametric uncertainty and external disturbances.This problem has attracted much attention from researchers due to its potential practical applications [4], [5], [6], [7] and [8].
In practical applications, the UAVs position in space is generally controlled by an operator through a remote-control system, while the attitude can be automatically stabilised via an onboard controller.The attitude controller is an important feature since it allows the vehicle to maintain the desired orientation and, hence, prevents the vehicle from flipping over and crashing when the pilot performs the desired maneuvers [4].A quadrotor is a dynamic vehicle with four input forces, six output coordinators, highly coupled and unstable dynamics [9] and [10].
In the literature, different control algorithms have been proposed to altitude and attitude control problem of unmanned quadrotor systems.
The linear control methods such as the application of Proportional-Integral-Derivative (PID) control and Linear-Quadratic (LQ) are proposed in [1], Linear Quadratic Regulator (LQR) control in [11], and PD control in [12].A nonlinear control method such as a backstepping based controller for UAV trajectory tracking is studied in [13].In [14], an exact linearisation is used for a quadrotor.In [15], a command filtered backstepping is used not only for stabilising attitude but also for tracking a trajectory for a quadrotor aerocraft.In [16], a direct inverse neural network control is presented to stabilise the quadrotor.In [17] authors present a fuzzy logic based controller for altitude, attitude, and position control of a quadrotor.In [18] stabilisation of altitude and attitude of a quadrotor using PID control is explored.
Sliding mode control is well known for its effectiveness through the theoretical studies versus the parameter variations and disturbances, and has been widely applied to robotics and aerocraft control design [19] and [20].A sliding mode and backstepping controllers of an indoor micro quadrotor are presented in [21].In [22], the application of second order sliding mode control is applied for position and attitude tracking control of a small quadrotor, in which the nonholonomic constraints are not taking into account.
Chattering phenomenon (high frequency of control action) is the major problem associated with Sliding Mode Control (SMC), which is caused by the inappropriate selection of the switching gain.In order to reduce the chattering phenomenon, various methods have been proposed, such as boundary layer, neural network, and fuzzy logic [23], [24] and [25].The fuzzy logic combined with the SMC can be used to achieve better performance [26] and [27].
The contributions of this paper could be summarised as follows: An effective and robust altitude-attitude controller is developed for unmanned quadrotor.The proposed controller combines the advantage of the SMC with backstepping synthesis to build BSMC, which is itself also enhanced by a fuzzy logic system to develop an FBSMC.The main idea of the proposed control scheme is the use of fuzzy logic systems in order to adapt the unknown switching gains to eliminate the chattering phenomenon induced by switching control in BSMC and obtain a good dynamic response in presence of large external disturbances.This paper is organised as follows: In Sec. 2. modeling of quadrotor is presented.In Sec. 3. states space representation of the quadrotor model is formulated.In Sec. 4. the FBSMC is designed to address the problem of altitude and attitude tracking control.The effectiveness of the proposed controller for the trajectory tracking is illustrated through numerical simulations in Sec. 5. Finally, conclusions are summarised in Sec. 6.

Quadrotor Dynamic Modelling
Quadrotor robot is an under-actuated system because it has six Degree of Freedom (DOF) and only four actual inputs.The six DOF include translational motion in three directions and rotational motion around three axes.The quadrotor adopted in this study is introduced in [9] and [10] (see Fig. 1) and is equipped with four actuators placed at the end of a cross configu-ration.Using a symmetrical design of the quadrotor allows for a centralisation of the control systems and the payload.In flight, the quadrotor can evolve along its axis: yaw, pitch and roll.To counter the effect of natural yaw of such robot, the most common way is to run two propellers in opposite way and the other two in the reverse direction.Consequently, the movements of the quadrotor are directly related to the propellers velocities.
The kinematic equations of the movements are obtained by means of the transformation matrix R t between body-frame and earth-frame [28].
where S and C represent the Sinus and Co-sinus functions, respectively.
Using the Newton-Euler laws of mechanics , the motion equations of the quadrotor can be written as follows: where ξ = (x, y, z) T and ν = ( ẋ, ẏ, ż) T represent respectively the position and the translation speed of the quadrotor mass center in the earth-fixed reference {E}.m is the total mass of the quadrotor.F t , F g and F f are respectively the drag force, the gravity force and the forces generated by the propeller system, such as: where K f t = diag(K f tx , K f ty , K f tz ) represents the translation drag coefficients.
where g a is the gravitational constant.
where F i is the lift force generated by the rotor i.
C p is the lift coefficient and ω i is the angular speed of rotor i.
J = diag(Ix, Iy, Iz) ∈ R 3×3 is the inertia matrix.(∧ denote the vector cross-product).Γ(Ω) is a skewsymmetric matrix defined by: where τ f is the moment developed by the quadrotor according to the body-fixed reference and expressed by: l is the distance between the quadrotor mass center and the propeller rotation axis.C d is the drag coefficient.
τ a is the result of aerodynamic frictions torques: K f a = diag(K f ta , K f ta , K f ta ) represents the aerodynamic frictions coefficients.
τ g is the resultant torque due to the aerodynamic and gyroscopic effects produced by the rotors rotation: where J r is the rotor inertia.
The dynamic equation of the quadrotor is driven and described as following: where d represents the disturbances applied to the quadrotor.u x and u y are two virtual control inputs: The control inputs of the system u 1 , u 2 , u 3 , and u 4 (see Fig. 2) are written according to the angular velocities of the four rotors as follows: with: Ω = (ω 1 − ω 2 + ω 3 − ω 4 ) is the total gyroscopic torque affecting the quadrotor.
The dynamic modelling Eq. ( 13) is completed by the following control inputs constraints [9]: where w max is the maximal angular speed of the rotor.
From Eq. ( 12), it is easy to show that:

Rotor Dynamic Model
A standard DC motor is usually a second order system.It is possible to model the dynamics of a DC motor system as a first order system [29].In this paper, the transfer function describes the dynamics of a DC motor system, given by Eq. ( 16) is used: where k mi and τ mi are the gain and the time constant of the motor, respectively.

State Space Representation
be the state and the control input vectors, respectively.
The dynamic model Eq. ( 11) can be written using the state space method as: where Then, the following state representation is obtained:

Controller Design and Stability Analysis
For the development of the control laws, the many assumptions are needed: Motivated by practise, the measured quadrotor UAV variable are the positions {x 1 , x 3 , x 5 , x 9 , x 11 } = {φ, θ, ψ, x, y, z}.
The objective is to design a robust tracking controller so that the states vector X = {x 1 , x 2 , ..., x 12 } = {φ, φ, θ, θ, ψ, ψ, x, ẋ, y, ẏ, z, ż} T can track a given desired reference even in presence of large external disturbances in the dynamic model.The controller is designed in three steps: Altitude control, position control (x and y motions) and attitude control (roll, pitch and yaw) as shown in Fig. 2. In this section, a fuzzy backstepping sliding mode controller is designed; this controller combines the advantage of the SMC with backstepping approach and FLS for the quadrotor.The SMC is designed to ensure the trajectory tracking and robustness against large external disturbances.Backstepping approach is used as a recursive algorithm for the lowcontrol synthesis, based on Lyapunov method.FLS is used to adapt the unknown switching gains to eliminate the chattering phenomenon induced by switching control.The structure of the control strategy is shown in Fig. 2.
The synthesised control laws are given as follows:  where sign(.)denotes the signum function.

Backstepping-Sliding Mode Control of the Rotations Motion (Attitude Control)
To develop this controller, let defined a tracking error between actual yaw and desired yaw as

2) Design Control Law
The objective of the controller is to enforce the sliding mode into the surface s φ = 0 .A first Lyapunov function is selected as follows: Then, its time derivative is computed as: In order to realise V1 negative definite ( V1 ≤ 0), by using backstepping algorithm, we consider the virtual system x 2 = s φ − c 1 e 1 + φd .Then, Using Eq. ( 20) and Eq. ( 22), V1 can be derived as follows: V1 = e 1 s φ − c 1 e 2 1 .If s φ = 0 then V1 ≤ 0. Therefore, the next step is required.A second augmented Lyapunov function is defined as: Therefore, V2 = V1 + s φ ṡφ .
From Eq. ( 22) Then, Eq. ( 24) becomes Assume that the state variables in Eq. ( 18) are available, and in order to realise V2 negative definite, the backstepping-sliding mode control law for roll motion is designed as follows: where c 2 ≥ 0, k 1 ≥ D are positive real numbers.Therefore, which yields, e 1 tends to zero and ė1 tends to zero as t tends to infinity.Therefore, the stability of the closedloop subsystem along the sliding surface s φ = 0 is guaranteed.Similar steps can be followed to design BSMC laws for trajectory tracking control of pitch, and yaw angle.The corresponding control laws are designed as follows respectively: where c i ≥ 0, i = 3, 6, and k 2 , k 3 ≥ D are positive real numbers.

1) Altitude Control
The altitude BSMC can be obtained by similar design procedures where c i ≥ 0, i = {11, 12}, and k 6 ≥ D are positive real numbers.

2) Position Control
The position control concerns the displacement in the direction of x and y.From the dynamic equation Eq. ( 11), it can be seen that the motion through the axes x and y depends on u 1 .In fact, u 1 is the total thrust vector oriented to obtain the desired linear motion, by considering u x and u y are directing of u 1 responsible for the motion through x and y axes, respectively.Using BSMC, the control motion, the direction of x and y are obtained using the same steps described above The designed BSMC provides an effective robust control approach for quadrotor system Eq.( 18).However, the control laws Eq. ( 25), (26), Eq. ( 27), Eq. ( 28), Eq. ( 29), Eq. ( 30) and Eq. ( 31) can cause the chattering phenomenon resulting from the use of the sign function.In this context, high switching gain k i will lead to an increase in oscillations of the control input signal, and therefore an excitation of highfrequency dynamics will take place, as results, a chattering phenomenon will be created.However, increasing the gain causes an increase of the oscillations in input control around the sliding surface.Moreover, a decrease in switching gain k i can reduce the chattering phenomenon and improve the tracking performance despite large external disturbances.To achieve more appropriate performance, this gain must be adjusted.This adjustment is based on the distance between the system states and the sliding surface.i.e., when the trajectory of the system state deviates from the sliding surface, the switching gain should be increased in order to reduce chattering and vice versa.This idea can be realised by combining Fuzzy logic with Backstepping-Sliding Mode Control to construct FBSMC to facilitate the adaptive switch-gain (see Fig. 2) according to some appropriate fuzzy rules.The Architecture of the FLS is shown in Fig. 3.For this reason, one-input one-output FLS is designed, in which the multiplication of the sliding surface s i (i = 1, 6) by its differential ṡi (i = 1, 6) as FLS input and switching gain K f uzzy as FLS output.The fuzzy sets are defined as follows:

Defuzzifier
Based on the experiences, the type of fuzzy rules is decided as "IF-THEN ".
The membership functions of input and output are chosen as illustrated in Fig. 4, in which the follow-ing linguistic variables have been used: Negative Big (NB), Negative Middle (NM), Zero (Z), Positive Middle (PM), and Positive Big (PB).The fuzzy base rule of the adopted FLS contains 5 rules, which have been given in Tab. 1.
Tab. 1: Fuzzy rule set.These rules govern the input-output relationship between s ṡ and k by adopting the Mamdani-type inference engine.A fuzzy logic system with singleton fuzzifier, product-inference rule and centre average defuzzifier is given by the following form: , where N is the total number of fuzzy IF-THEN rules in the rule base, n is the number of system states.A l i and B l i denote fuzzy sets, ζ l is the point at which µ B l achieves its maximum value assuming that µ B l (ζ l ) = 1.
Using integral method, the supper bound of ki (t) is adapted: where G is proportionality coefficient and is adjusted according to the experiences.
Finally, the final control laws developed by fuzzy backstepping-sliding mode control are defined as Eq.(19), where ki (i = 1, 6) are the adaptive switching gains obtained by FBSMC.
The simplification of all computation steps concerning the tracking errors, sliding surfaces and Lyapunov functions is defined as follows:

Simulation and Discussions
In this section, numerical simulation is conducted to demonstrate the performance of the developed controllers.In this simulation, the system nominal parameters are shown in Tab. 2 [9] and [10].The proposed algorithm, applied to the above quadrotor, is simulated on a PC using matlab environment (version 8.6.0.267246).
K f a = diag(5.5670;5.5670; 6.3540)The initial condition for the quadrotor is X(0) = [0, 1, 0, 2, 0, 2, 1, 0, 1, 2, 0, 2] T , the motor dynamic factors are assumed to be k m = 1, τ m = 0.  First, the system under backstepping-sliding mode control law is simulated in order to show its drawback.The controller parameters are selected as follows: k = diag(7, 7, 5, 5, 5, 5), c = diag(c 1 , ..., c 12 ) = diag(3, 20, 3, 20, 3, 1, 1, 4, 1, 4, 1, 1.5).The results obtained for the altitude and attitude tracking control of the quadrotor are given in Fig. 6 and Fig. 7.It is easy to note that the tracking performance is satisfactory when large external disturbances are applied (see Fig. 6).However, as it can also be seen in Fig. 7, the control performance is not satisfactory due to chattering phenomenon caused by the inappropriate selection of the switching gains.In order to tackle this problem, the smoothing property of fuzzy logic is exploited as seen in the previous section.The proposed control law Eq.( 19) is applied in order to resolve this problem.mance of the fuzzy backstepping-sliding mode controller.Figure 8 illustrates the tracking outputs system in presence of disturbances and shows that the performance and robustness of the proposed controller, under large external disturbances, are very acceptable.The states converge to their desired ones, which show satisfactory tracking during the flight.Figure 9 represents tracking errors, which all tend to zero after a finite time with a perfect convergence.The new obtained control inputs are depicted in Fig. 10, compared with the old one in Fig. 7; it can be clearly seen that the chattering phenomenon is almost disappeared.Compared to  previous studies e.g., [26], [27], [28], [2], [29], [30] and [31], the proposed control approach effectively reduces chattering phenomenon and obtained a good dynamic response.The adapted fuzzy switching gains and applied external disturbances are depicted in Fig. 11 and Fig. 12, respectively.Also, the global trajectory of the quadrotor is illustrated in 3D on Fig. 13.

Conclusion
In this paper, an altitude-attitude tracking control for unmanned quadrotor under large external disturbances, using fuzzy backstepping-sliding mode controller, is presented.This approach is applied and it is enhanced by a fuzzy system to adapt the unknown switching gains for eliminating the chattering phenomenon induced by switching control on the conventional BSMC.
It is concluded from the simulations that the proposed controller gives good results.This reflects the robustness and performance of the fuzzy backsteppingsliding mode control, which is also confirmed by the tracking errors convergence (see Fig. 9).The stability of the proposed control is guaranteed by Lyapunov approach.Simulation results confirme the ability of the proposed controller to ensure a good tracking and yield superior control performance for nonlinear system control against large external disturbances.

Fig. 2 :
Fig. 2: Control scheme of the quadrotor robot with the hierarchical controller.

2 )
15 and ω max = 200 rad•s −1 .The uncertainty which is injected in the structure to verify the robustness of the controller, is a large external disturbance d(t) = 5e ( −(t−0.03) 2 10 •sin(π/4 t)•I 6×1 , where I 6×1 is an identity matrix and it is applied at t = 5 s.The upper bound of the disturbances is assumed to be D = max(|d|) = 5 and G = 0.01.The desired trajectory is chosen to be x d = 2 m, y d = 2 m, z d = 5 m, θ d = 45°.The global diagram of the control structure is shown in Fig. 5.
Biskra, Algeria, in 2010 and 2012 respectively.He is currently a Ph.D. student in robotics and artificial intelligence at Electronics Department, University of Batna 2, Algeria.His research interests include dynamics, robotics, systems and controls, optimization, soft computing and simulation.Noureddine SLIMANE was born in Batna, Algeria.He received the Engineer degree in Elecrtonics from National Polytechnic School of Algiers in 1979, Magister and Ph.D. in Industrial Control and Robotics from Batna University in 1995 and 2005 respectively.Since 1982, he has worked as a Research Assistant in Batna University and Head of Electronics Department between 1999 and 2003.Between 2004 and 2005 he spent eighteen months at the Complex Systems Laboratory, University of Evry, France.Currently he is an Associate Professor in Automation and Robotics and responsible of Robotics and Artificial Intelligence Doctorate in Batna 2 University.His research interests include autonomous systems, intelligent control, modeling and simulation, optimal control, robotics and automation.Kheireddine CHAFAA was born in Batna, Algeria, in 1971.He received the Engineer, Magister and Doctorate Es-Secience diplomas in Industrial Control from Batna University, Algeria, in 1994, 1999 and 2006 respectively.Currently he is a Professor with the department of Electronics, Faculty of Technology, Batna 2 University, Algeria.His research interests include modeling and identification of nonlinear systems, nonlinear and adaptive control, soft computing and biomedical signal processing.