# Observer-Based Sliding Mode Control for Path Tracking of a Spherical Robot

Authors: Majid Taheri Andani; Zahra Ramezani; Saeed Moazami; Jinde Cao; Mohammad Mehdi Arefi; Hassan Zargarzadeh
Journal: Complexity
 (2018)

---

## Abstract

Due to their complicated dynamics and underactuated nature, spherical robots require advanced control methods to reveal all their manoeuvrability features. This paper considers the path tracking control problem of a spherical robot equipped with a 2-DOF pendulum. The pendulum has two input torques that allow it to take angles about the robot’s transverse and longitudinal axes. Due to mechanical technicalities, it is assumed that these angles are immeasurable. First, a neural network observer is designed to estimate the pendulum angles. Then a modified sliding mode controller is proposed for the robot’s tracking control in the presence of uncertainties. Next, the Lyapunov theorem is utilized to analyse the overall stability of the proposed scheme, including the convergence of the observer estimation and the trajectory tracking errors. Finally, simulation results are provided to indicate the effectiveness of the proposed method in comparison with the other available control approaches.


---

## Body

## 1. Introduction

Spherical robots are a class of rolling robots, which can be used in many applications: surveillance [1], environmental monitoring [2], exploration operations in unknown environments [3], rehabilitation [4], hobbies [5], and so on [6]. Due to the ball-shaped shell, the enclosed components in a spherical robot are protected from collision and environmental states such as dust, humidity, and radiations. Spherical robots have highly manoeuvrable dynamics that enjoy the advantage of never tipping over [7] and the minimum skidding and resistance with the surface [8]. Nonetheless, the underactuated nature of these robots calls for advanced control schemes to succeed with the path tracking problem [9, 10].Over the last few years, numerous studies have been conducted on modelling, point stabilization [11], and tracking control of the spherical systems. The motion of the sphere under rolling constraints is studied in [12]. In [13], two computationally path-planning algorithms are presented for the rolling sphere. A first-order model for a spherical robot is derived in [14] from noninclined limitation and conservation of the angular momentum, as well as a path tracking method with minimum energy and time. In [15], a dynamic equation model is obtained for a spherical robot’s motion with a mobile mass, which is placed inside the shell and it proposes its path planning on a surface with the presence of obstacles. Euler parameters are utilized in [16] to establish the kinematic equations for a spherical robot and represent the trajectory planning problems. The dynamics model and control of a spherical robot with a driving wheel on the bottom of the sphere are investigated in [8] where the platform is not plain. The dynamics model of a spherical robot with a rolling mechanism consisting of a 2-DOF is studied in [17], and the rotation matrices are derived to analyse the kinematics of the system. Then the Euler-Lagrange formalism is applied to develop the decoupled dynamic modelling for the motion of the robot in transverse and longitudinal axes. Also, fuzzy and feedback linearization controllers are employed for the trajectory tracking problem. In [18], utilizing the Lagrange method, the dynamics model and the motion control of a pendulum-based spherical robot on an inclined plane were investigated using a PID controller.In the literature, a variety of control schemes is introduced for the tracking control of spherical robots. By considering the spherical robot’s model, a backstepping feedback controller for the kinematic equations is developed in [3]. In [6], a real-time fuzzy guidance approach for the trajectory tracking of a 2-DOF pendulum spherical robot is introduced, with a focusing on simultaneous convergence of attitude and position of the robot. The work in [19] proposes a neural network (NN) PID controller that has the advantages of simple forward and dynamic self-processing structure for an amphibious spherical robot. Modelling errors and uncertainties have motivated many researchers to utilize sliding mode control (SMC), as a kind of nonlinear robust controller [20, 21], for the spherical robot path tracking problem. For example, in [22], a 1-DOF spherical robot is modelled where a SMC online learning method with fuzzy neural network controller is used for velocity control of the robot. In [23], a hierarchical sliding mode is introduced to control the spherical robot in the presence of unwanted disturbances and uncertainties in real time.The aforementioned control approaches are designed with the assumption that all the states of the system are measurable. Nonetheless, it is sometimes technically costly or mechanically impossible to measure all the states of the physical systems. To address this issue, linear and nonlinear observers are introduced [24–26]. There have been numerous efforts conducted on estimating unknown parameters and immeasurable states in spherical robots. For instance, in [27], disturbance in an omnidirectional spherical robot is estimated, and then it is delivered to an observer-based generalized proportional integral (GPI) for cancelation of the disturbance. In [28], an extended observer-based adaptive hierarchical sliding mode for longitudinal motion of the spherical robot is designed, in which the uncertain rolling resistance can be obtained without using traction sensors.In this paper, the trajectory tracking problem of a popular spherical robot is studied for a robot that uses a 2-DOF pendulum for driving the motion by moving the sphere’s mass centre, which creates gravitational torque [17]. While all the robot’s states need to be measurable for the controller design, the mechanical structure makes it a challenge to acquire the pendulum angles using sensors. Even if sensors are installed, the acquired values may not be precise due to the noise and measurement delays. Besides, uncertainties and nonlinear dynamics are intrinsic to spherical robots. To overcome these problems, in this paper, a sliding mode controller is introduced [29] that estimates the immeasurable states via a NN-based nonlinear observer [30].NNs are widely utilized as adaptive observers to estimate the system nonlinearities and the immeasurable states of the nonlinear systems [31]. Moreover, NNs are extensively used in path tracking by mobile robots [27]. In [32], an adaptive NN with a robust controller is applied to overcome the challenge of environmental border trajectory tracking of underactuated mobile robots with uncertain dynamics as well as the presence of disturbances. In [33], the authors employ an adaptive path tracking control with an interneural computing approach for a mobile robot to follow a moving target. This controller is a mathematical scheme that employs neural pruning to the functions of rewards and punishment.Due to the complicated nonlinear dynamics, in this paper, the spherical robot is modelled in a way that the dynamics are decoupled in two separated subsystems about transverse and longitudinal axes [17]. It is assumed that the pendulum’s angles around these axes are immeasurable. To measure the unknown states, a NN-based observer is designed that is adaptive against the robot’s nonlinearities and unknown parameters. Then an extended SMC is developed that uses the estimated states in the presence of the model structural uncertainties. The SMC provides the torques for the spherical robot around transverse and longitudinal axes to track the desired trajectory. The proposed adaptive observer-based SMC not only rejects the uncertainties but can also estimate immeasurable states while the robot dynamics nonlinearities are assumed to be unknown. The Lyapunov theorem is utilized to guarantee that the overall closed-loop system is semiglobally uniformly ultimately bounded (SGUUB). The performance of the proposed scheme is verified with application to the spherical robot for tracking a desired trajectory on the horizontal plane. To the best knowledge of the authors, this is the first time that an adaptive observer-based SMC that estimates immeasurable states has been introduced to a nonlinear system in the presence of uncertainties and unknown nonlinearities.The main contributions of this paper are as follows: (1) designing an observer to estimate immeasurable states, which are the angles of the pendulum about transverse and longitudinal angles, (2) designing a radial basis function (RBF) neural network to approximate the uncertainties and nonlinearities of the robot model, and (3) designing a modified SMC that guarantees the SGUUB of the overall closed-loop scheme in the presence of the state estimation errors, uncertainties, and unknown nonlinearities.The rest of the paper is organized into six sections: the model of the robot is introduced in the second section; in the third section, kinematics and dynamics of the system are introduced; in section four, an observer for the robot is designed; and section five presents an NN and SMC. The simulation results and comparison with relative approaches in the literature are discussed in section six, followed by the conclusions in the last section.


## 2. Description of the Robot Model

In this paper, a 2-DOF pendulum-driven spherical robot is studied. The pendulum rolls the robot in two directions by shifting the sphere’s centre of gravity to different points. The schematic of this robot is shown in Figure1. In the sphere, there are two aligned diagonal holes through which a shaft is fixed to the sphere. A 2-DOF pendulum is hanged from the centre point of the shaft. As indicated in Figure 1, two motors are employed to provide torque, so the pendulum takes the required direction. Motor 1 rotates the pendulum about the sphere’s shaft that is considered as the transverse shaft. Motor 2 rotates the shaft about the longitudinal axis about the horizon. Rotation of the pendulum about the transverse axis moves the gravity centre towards the longitudinal axis, which causes the sphere to roll about that axis. Rotating the pendulum about the longitudinal axis makes the sphere roll about the longitudinal axis. Therefore, by using two motors, the motion of the robot can be controlled over a flat surface.Figure 1
Mechanical schematic of a 2-DOF pendulum-based spherical robot.For deriving the dynamics model of the robot, it is assumed that two degrees of freedom do not have interaction on each other [17]; therefore, the equations of motion consist of two decoupled subsystems. With this assumption, the motions of a sphere on a flat surface (rolling without slipping) formulation of the kinematic and dynamic equations are derived in [17].There exist three frames in Figure2—oxyz represents the reference frames that is fixed to the ground, o1x1y1z1 is the moving reference on the spherical centre that can translate with respect to oxyz,, and o2x2y2z2 is a moving reference to the spherical centre which rotates with the sphere with respect to o1x1y1z1. The relative rotation angle of o2x2y2z2 around o1x1 is θ, and the relative rotation angle of o2x2y2z2 around o1y1 is ϕ. Figure 3 depicts the sphere’s turning motion about its transvers axis. In Figures 2 and 3, θ, ϕ, and ψ are the rotational angles of the robot around the o–x, o–y, and o–z axes.Figure 2
Reference frames and kinematic schemes of rotation around the transverse axis resulting in longitudinal motion.Figure 3
Reference frames and kinematic schemes of rotation around the longitudinal axis resulting in transverse motion of the sphere.


## 3. Kinematics and Dynamics of the Spherical Robots

In this section, the kinematics and dynamics of the presented spherical robot are expressed. Linear and turning motions of the robot are represented in Figures2 and 3, respectively.


### 3.1. Kinematics Equations

For deriving the kinematics model, we use two rotations around the transverse and longitudinal axes.i,j,kT, i1,j1,k1T, and i2,j2,k2T denote unit vectors which are attached to the oxyzCfix, o1x1y1z1C1, and o2x2y2z2C2 coordinates, respectively. The first rotation is written by the following transformation matrix.
(1)R1=Rotx,θ=1000cosθsinθ0−sinθcosθ,i1j1k1=Rotx,θi2j2k2=1000cosθsinθ0−sinθcosθi2j2k2.The second transformation matrix for the second rotation is represented as follows:(2)R2=Roty,ϕ=cosϕ0−sinϕ010sinϕ0cosϕ,i1j1k1=Roty,ϕi2j2k2=cosϕ0−sinϕ010sinϕ0cosϕi2j2k2.According to Figure2, the angular and linear velocities of the sphere are written as follows:
(3)ωsCfix=−θ̇i,ωsCfix=−ϕ̇j,Vx=−ρθ̇i,Vy=ρϕ̇j,where ρ is the radius of the sphere. The position of the centre of mass of the pendulum can be written as follows:
(4)rxC2=hsinαj−2hcosαk2,(5)ryC2=−hsinβi−2hcosβk2,in (4) and (5), α and β denote the angle of the pendulum about transverse and longitudinal axes, respectively, and h is the length of the shaft which connects the pendulum to the center of the sphere. Using transformation matrices, the position of the pendulum in the o1x1y1z1 coordinate is written as follows:
(6)rxC1=Rotx,θrxC2=hsinα−θj1−hcosα−θk1,ryC1=Roty,ϕryC2=−hsinβ−ϕj1−hcosβ−ϕk1,where the position of the centre of mass of the pendulum in fixed coordinate Cfix is equal to rxC1 and ryC1. The angular velocities of the pendulum in o2x2y2z2 and o1x1y1z1 coordinates are written as
(7)ωxpC2=α̇i2,ωxpC1=ωsC1+Rotx,θωxpC2=α̇−θ̇i1,ωypC2=β̇j2,ωypC1=ωsC1+Roty,ϕωypC2=β̇−ϕ̇C1,where the angular velocities in the fixed coordinates are equal to ωxpC1 and ωypC2. The linear velocities of the centre of mass of the pendulum in two subsystems are as follows:
(8)Vxp=Vx+ωxp×rx−ρθ̇+hcosα−θα̇−θ̇j+hsinα−θα̇−θ̇k,Vyp=Vy+ωyp×ry−ρφ̇−hcosβ−φβ̇−φ̇j+hsinβ−φβ̇−φ̇k.


### 3.2. Dynamics Equations

As mentioned in Section2, for deriving the dynamics equations of the robot, it is considered that the degrees of freedom do not have interaction on the dynamics of each other, so the dynamic equations consist of two decoupled subsystems, in which the following assumptions are made:
(1)
Rotations about transverse and longitudinal axes do not have any interaction with each other
(2)
Around the vertical axis, there is no rotational motionUsing the Lagrangian equations, dynamic equations of the systems can be derived. The Lagrangian formula for a system of particles can be defined by(9)L=T−V,where T is the total kinetic energy of the system and V is the potential energy of the dynamic system. Since the kinetic energy of the system is equal to the kinetic energies of the whole particles of the systems, the kinetic energy of the system is presented as
(10)T=Ts+Tp,where Ts and Tp, are equal to the kinetic energy of the sphere and pendulum, respectively.
(11)Ts=12MsVs2+12Isωs2,Tp=12MpVp2+12Ipωp2.In (11), the moments of inertia of the sphere and pendulum are
(12)Is=23Msρ2,Ip=112Mph2+Mph22,where Ms and Mp are masses; the weight of the sphere and pendulum, ωs,ωp,Vs and Vp, represents angular velocities of sphere and pendulum and linear velocities of them, respectively. As the centre of mass of the sphere remains in constant height, the potential energy of the spherical robot depends on the pendulum’s mass and its vertical distance from the centre of the sphere.
(13)V=Mpgh.Let us decouple (8) into (11) and decouple the Lagrangian equation into two parts based on rotation in the transverse axis Lx and vertical axis Ly.
(14)Lx=12MsẊ2+12Isωx2+12MpẊ+hcosα−θα̇−θ̇2+hsinα−θα̇−θ̇2+12Ipα̇−θ̇2+Mpghcosα−θ,Ly=12MsẎ2+12Isωy2+12MpẎ−hcosβ−ϕβ̇−ϕ̇2+hsinβ−ϕβ̇−ϕ̇2+12Ipβ̇−ϕ̇2+Mpghcosβ−ϕ.Euler’s equations for systems can be presented as follows:(15)ddt∂Lx∂q̇i−∂Lx∂qi=Qi,ddt∂Ly∂q̇j−∂Ly∂qj=Qj,where qi expresses θ and αq1=θ,q2=α and represents generalized coordinates. Besides, Qi is considered as input torque in the transverse axis Q1,2=τx. Also, in the above equations, qj is equal to ϕ and βq3=ϕ,q4=β and they are generalized coordinates. Qj represents input torque in the longitudinal axis Q3,4=τy.Let us plug (14) into (15) and rearrange the derived equations in a united state space and write the equation of motion in the matrix form [17].
(16)Mqtq¨t+Zqt,q̇t=τ,where τ=τx,τx,τy,τyT,
(17)M11=2Mpρhcosq2−q1+Mph2+Mpρ2+IP+Msρ2+Is,M12=−Mpρhcosq2−q1−Mph2−Ip,M13=0,M14=0,M21=−Mpρhcosq2−q1−Mph2−Ip,M22=Mph2+Ip,M23=M24=M31=M32=0,M33=2Mpρhcosq3−q4+Mph2+Mpρ2+Ip+Msρ2+Is,M34=−Mpρhcosq4−q3−Mph2−Ip,M41=M42=0,M43=−Mpρhcosq4−q3−Mph2−Ip,M44=Mph2+Ip,Z11=−Mpghsinq2−q1+Mpρhsinq2−q1q̇22+Mpρhsinq2−q1q̇12−2Mpρhsinq2−q1q̇1q̇2,Z21=Mpghsinq2−q1,Z31=−Mpghsinq4−q3+Mpρhsinq4−q3q̇42+Mpρhsinq4−q3q̇32−2Mpρhsinq4−q3q̇3q̇4,Z41=Mpghsinq4−q3.The objective of this paper is to design a path tracking control scheme for this robot, in the following sections: first, an observer will be designed to estimate the immeasurable states; then an adaptive neural network observer-based sliding mode controller will be proposed.


## 3.1. Kinematics Equations

For deriving the kinematics model, we use two rotations around the transverse and longitudinal axes.i,j,kT, i1,j1,k1T, and i2,j2,k2T denote unit vectors which are attached to the oxyzCfix, o1x1y1z1C1, and o2x2y2z2C2 coordinates, respectively. The first rotation is written by the following transformation matrix.
(1)R1=Rotx,θ=1000cosθsinθ0−sinθcosθ,i1j1k1=Rotx,θi2j2k2=1000cosθsinθ0−sinθcosθi2j2k2.The second transformation matrix for the second rotation is represented as follows:(2)R2=Roty,ϕ=cosϕ0−sinϕ010sinϕ0cosϕ,i1j1k1=Roty,ϕi2j2k2=cosϕ0−sinϕ010sinϕ0cosϕi2j2k2.According to Figure2, the angular and linear velocities of the sphere are written as follows:
(3)ωsCfix=−θ̇i,ωsCfix=−ϕ̇j,Vx=−ρθ̇i,Vy=ρϕ̇j,where ρ is the radius of the sphere. The position of the centre of mass of the pendulum can be written as follows:
(4)rxC2=hsinαj−2hcosαk2,(5)ryC2=−hsinβi−2hcosβk2,in (4) and (5), α and β denote the angle of the pendulum about transverse and longitudinal axes, respectively, and h is the length of the shaft which connects the pendulum to the center of the sphere. Using transformation matrices, the position of the pendulum in the o1x1y1z1 coordinate is written as follows:
(6)rxC1=Rotx,θrxC2=hsinα−θj1−hcosα−θk1,ryC1=Roty,ϕryC2=−hsinβ−ϕj1−hcosβ−ϕk1,where the position of the centre of mass of the pendulum in fixed coordinate Cfix is equal to rxC1 and ryC1. The angular velocities of the pendulum in o2x2y2z2 and o1x1y1z1 coordinates are written as
(7)ωxpC2=α̇i2,ωxpC1=ωsC1+Rotx,θωxpC2=α̇−θ̇i1,ωypC2=β̇j2,ωypC1=ωsC1+Roty,ϕωypC2=β̇−ϕ̇C1,where the angular velocities in the fixed coordinates are equal to ωxpC1 and ωypC2. The linear velocities of the centre of mass of the pendulum in two subsystems are as follows:
(8)Vxp=Vx+ωxp×rx−ρθ̇+hcosα−θα̇−θ̇j+hsinα−θα̇−θ̇k,Vyp=Vy+ωyp×ry−ρφ̇−hcosβ−φβ̇−φ̇j+hsinβ−φβ̇−φ̇k.


## 3.2. Dynamics Equations

As mentioned in Section2, for deriving the dynamics equations of the robot, it is considered that the degrees of freedom do not have interaction on the dynamics of each other, so the dynamic equations consist of two decoupled subsystems, in which the following assumptions are made:
(1)
Rotations about transverse and longitudinal axes do not have any interaction with each other
(2)
Around the vertical axis, there is no rotational motionUsing the Lagrangian equations, dynamic equations of the systems can be derived. The Lagrangian formula for a system of particles can be defined by(9)L=T−V,where T is the total kinetic energy of the system and V is the potential energy of the dynamic system. Since the kinetic energy of the system is equal to the kinetic energies of the whole particles of the systems, the kinetic energy of the system is presented as
(10)T=Ts+Tp,where Ts and Tp, are equal to the kinetic energy of the sphere and pendulum, respectively.
(11)Ts=12MsVs2+12Isωs2,Tp=12MpVp2+12Ipωp2.In (11), the moments of inertia of the sphere and pendulum are
(12)Is=23Msρ2,Ip=112Mph2+Mph22,where Ms and Mp are masses; the weight of the sphere and pendulum, ωs,ωp,Vs and Vp, represents angular velocities of sphere and pendulum and linear velocities of them, respectively. As the centre of mass of the sphere remains in constant height, the potential energy of the spherical robot depends on the pendulum’s mass and its vertical distance from the centre of the sphere.
(13)V=Mpgh.Let us decouple (8) into (11) and decouple the Lagrangian equation into two parts based on rotation in the transverse axis Lx and vertical axis Ly.
(14)Lx=12MsẊ2+12Isωx2+12MpẊ+hcosα−θα̇−θ̇2+hsinα−θα̇−θ̇2+12Ipα̇−θ̇2+Mpghcosα−θ,Ly=12MsẎ2+12Isωy2+12MpẎ−hcosβ−ϕβ̇−ϕ̇2+hsinβ−ϕβ̇−ϕ̇2+12Ipβ̇−ϕ̇2+Mpghcosβ−ϕ.Euler’s equations for systems can be presented as follows:(15)ddt∂Lx∂q̇i−∂Lx∂qi=Qi,ddt∂Ly∂q̇j−∂Ly∂qj=Qj,where qi expresses θ and αq1=θ,q2=α and represents generalized coordinates. Besides, Qi is considered as input torque in the transverse axis Q1,2=τx. Also, in the above equations, qj is equal to ϕ and βq3=ϕ,q4=β and they are generalized coordinates. Qj represents input torque in the longitudinal axis Q3,4=τy.Let us plug (14) into (15) and rearrange the derived equations in a united state space and write the equation of motion in the matrix form [17].
(16)Mqtq¨t+Zqt,q̇t=τ,where τ=τx,τx,τy,τyT,
(17)M11=2Mpρhcosq2−q1+Mph2+Mpρ2+IP+Msρ2+Is,M12=−Mpρhcosq2−q1−Mph2−Ip,M13=0,M14=0,M21=−Mpρhcosq2−q1−Mph2−Ip,M22=Mph2+Ip,M23=M24=M31=M32=0,M33=2Mpρhcosq3−q4+Mph2+Mpρ2+Ip+Msρ2+Is,M34=−Mpρhcosq4−q3−Mph2−Ip,M41=M42=0,M43=−Mpρhcosq4−q3−Mph2−Ip,M44=Mph2+Ip,Z11=−Mpghsinq2−q1+Mpρhsinq2−q1q̇22+Mpρhsinq2−q1q̇12−2Mpρhsinq2−q1q̇1q̇2,Z21=Mpghsinq2−q1,Z31=−Mpghsinq4−q3+Mpρhsinq4−q3q̇42+Mpρhsinq4−q3q̇32−2Mpρhsinq4−q3q̇3q̇4,Z41=Mpghsinq4−q3.The objective of this paper is to design a path tracking control scheme for this robot, in the following sections: first, an observer will be designed to estimate the immeasurable states; then an adaptive neural network observer-based sliding mode controller will be proposed.


## 4. Observer Design

To the best knowledge of the authors, in the works that have been done on the spherical robots, it is assumed thatα and β are available [17, 18, 23]. However, since all the parts of the spherical robot, installed in the shell, rotate about some axis, measurement of α and β with sensors is costly or impractical due to mechanical inaccessibility. To overcome this problem, in this paper, an observer is designed to estimate the unavailable system states which are the degrees of freedom of the pendulum with respect to the transverse and longitudinal axes.Considering the dynamics of system (16), two outputs of systems are to be controlled via the two inputs. In this study, X and Y are the outputs and the torques are control inputs of the system. Let us transform the dynamic system into the following form:
(18)q¨t=−M−1Zqt,q̇t+M−1τ,(19)q¨1q¨2q¨3q¨4=−M−1Z11Z21Z31Z41+M−1τxτxτyτy.In order to design an observer, (19) can be rewritten in the following state space form:
(20)ẋ1=x2,ẋ2=f2x,u,ẋ3=x4,ẋ4=f4x,u,ẋ5=x6,ẋ6=f6x,u,ẋ7=x8,ẋ8=f8x,u,where x∈ℜ8×1 are states of the system in which x1=θ, x3=α, x5=ϕ, x7=β, u=τ∈ℜ4×1, and fix,u∈ℜ with i∈2,4,6,8 and f2x,u=q¨1,f4x,u=q¨2,f6x,u=q¨3,f8x,u=q¨4.Moreover, (20) can be rewritten in the following form:
(21)ẋ=Ax+BFx,u,y=CTx,where Fx,u=f2x,uf4x,uf6x,uf8x,uT and
(22)A=0100000000000000000100000000000000000100000000000000000100000000,B=01000000000100000000010000000001T,CT=10000000010000000000100000000100,since θ,θ̇,ϕ, and ϕ̇ are available and measurable states, the output matrix is considered to be CT.Fx,u can be taken as
(23)Fx,u=Fx,u−Ω+Ω=hx¯+Ω,where hx¯∈ℜ4×1 and Ω∈ℜ4×1 are a neural network-based affinizing term that will be defined in (32). So, (21) can be represented in the following form:
(24)ẋ=Ax+Bhx¯+Ω,where x¯=x,u,ΩT. Consider an observer represented as follows:
(25)x^̇=Ax^+k0y−y^,where x^ is the estimation of the vectors x and y^=CTx^. k0∈ℜ8×4 is a vector which is called observer gain, and it is taken to make the characteristic polynomial of A0=A−k0CT Hurwitz matrix. Defining the estimation error as x~=x−x^, we have
(26)x~̇=A0x~+Bhx¯+Ω.SinceA0 is a Hurwitz matrix, there exists P∈ℜ8×8
(27)A0TP+PA0=−Q,and Q∈ℜ8×8 is an arbitrary positive definite matrix.SinceCTx~ relies on available states, the strictly positive real (SPR) Lyapunov design approach is used to guarantee the stability of the closed-loop system [34]. Considering (26) as a linear system with hx¯+Ω as its input, we define Hs=CTsI−A0−1B. So, we have CTx~=Hshx¯+Ω. The transfer function Hs is known as a stable transfer function. In order to utilize the SPR-Lyapunov design approach, CTx~=Hshx¯+Ω can be taken as
(28)CTx~=HsLsL−1shx¯+L−1Ω,with
(29)Lis=smi+b1ismi−1+⋯+bmimi≤8,i=1,2,…,4,Ls=diagL1s,…,L4s.Ls is chosen, so that L−1s is a proper stable transfer function and HsLs is a proper SPR transfer function. Now, system (28) can be realized in state space as follows:
(30)x~̇=A0x~+BcL−1shx¯+Ω,where BC is chosen such that PBC=C.Moving on,hx¯ needs to be approximated by utilizing a RBF neural network [35]. RBF is a neural network that is used in the practical applications for its simple structure and its capabilities of nonlinear function approximation [35, 36]. Afterwards, hx¯ is used to develop an adaptive controller with its adaptation law to meet the control objective and guarantee boundedness of all signals in the closed-loop system. hx¯ is approximated (z∈ΩNN⊂ℜn is the input vector) by using RBF NN, as follows:
(31)h^x¯=ψ^ξx¯,where ψ^=ψ^11,ψ^12,…,ψ^1l is the weight vector of the neural network system function vector with l nodes and ψ^1i∈ℜ4×l,i=1,2,…,l. And ξx¯=ξ1x¯,ξ2x¯,…,ξlx¯T is a basis function with Gaussian function ξix¯=expx¯−μi2/ηi2, with centre μi=μi1,μi2,…,μilT and width η, and δx,x^=hx¯−h^x^∣ψ^ is the neural network approximation error. The neural network controller is designed.
(32)Ω=−ψ^ξx^.Hence,ψ~=ψ^−ψ where ψ^ is an estimate of ψ. The adaptive law is
(33)ψ^̇=γBcTPx~L−1sξTx^.Assumption 1.
δm=L−1sδx,x^ is bounded, i.e., δm<δ¯.
Consider the following Lyapunov function for systems (30) and (33):
(34)V1=12x~TPx~+12γψ~ψ~T.
By calculating the time derivative of Lyapunov function and using (27), we obtain
(35)V̇1=12x~TA0TP+PA0x~+x~TPBcL−1shx¯+Ω+1γψ~ψ~̇T.
In (35), hx¯=ψξx+δx,x^=ψ^ξx^−ψ~ξx^+δx,x^ can be approximated based on (31). Then by replacing neural network controller (32) in (35), we have
(36)V̇1=12x~TA0TP+PA0x~+x~TPBcL−1sψ^ξx^−ψ~ξx^+δx,x^−ψ^ξx^+1γψ~ψ~̇T.
By replacing (27) in (36), we have:
(37)V̇1=−12x~TQx~+x~TPBcL−1sψ^ξx^−ψ~ξx^+δx,x^−ψ^ξx^+1γψ~ψ~̇T.
Now,ψ~̇T=ψ^̇T and then by using (33) in (37), we have
(38)V̇1=−12x~TQx~+x~TPBcL−1sψ^ξx^−ψ~ξx^−ψ^ξx^+δx,x^+1γψ~γξx^x~TPBcL−1s=−12x~TQx~+x~TPBcL−1sδx,x^.
So, based on Assumption (1), the above equation can be written in the following equation:
(39)V̇1≤−12x~TQx~+x~TPBcδ¯.
In the above equation, based on Young’s inequality, we have(40)∣x~TPBcδ¯=x~TCδ¯≤12x~2+12δ¯2,and then we have
(41)V̇1≤−12x~TQx~+12x~2+12δ¯2≤−12q0x~2+12δ¯2,where q0=λminQ−1 and λminQ is the minimum characteristic value of Q. So, the observer is provided; in the next section, the SMC is given to control the spherical robot.


## 5. Sliding Mode Control

The aim of this paper is designing a robust controller, so the spherical robot tracks a desired trajectory, where the torques of the spherical robot about the transverse and longitudinal axes are the system inputs. To that end, the controller for the kinematics part of the robot will be designed. The kinematic models of the robot are written as follows.(42)Ẋ=−ρθ̇,X¨=−ρθ¨,Ẏ=ρφ̇,Y¨=ρφ¨,where X and Y are the position of the spherical robot. By substituting θ¨ and φ¨ into (42) from (19), second derivatives of X,Y are calculated as follows:
(43)G¨=Dx+JxU,with
(44)G¨=X¨Y¨,U=τxτy,Jx=J1,1xJ1,2xJ2,1xJ2,2x=J1,1x00J2,2x,where the first row of Dx∈ℜ2×1 is derived from multiplying −ρ and the first row of −M−1G and the second row of Dx is derived from multiplying ρ and the third row of −M−1G. And, in Jx∈ℜ2×2, J1,1x and J1,2x are derived from multiplying −ρ and the first row of M−1, and J2,1x and J2,2x are derived from multiplying ρ and the third row of M−1. One should note that from (17), the matrix M∈ℜ4×4 can be represented in a subblock-wise format as follows:
(45)M=MA00MD,M−1=MA−100MD−1,where MA,MB∈ℜ2×2. Therefore, in (43), J1,2x and J2,1x are zero. Since all the states are not available for measurement, the observer state estimation from the previous section will be used, i.e., the estimated states x^ are used instead of the immeasurable states x.Taking the sliding surface,(46)SxSy=Ẋ−ẊdẎ−Ẏd+λ100λ2X−XdY−Yd=ė+λe,where Xd, Yd, and their derivatives are the desired position of the robot’s centre and its linear velocity. λ1 and λ2 are strictly positive and constant values. The derivative of the sliding surface is calculated as
(47)Ṡt=ṠxṠy=X¨−X¨dY¨−Y¨d+λ100λ2Ẋ−ẊdẎ−Ẏd.To reach trajectory tracking,Ṡt should remain zero as long as the robot is moving. So, the following equivalent control law ueq is taken:
(48)ueq=J−1x^−Dx^+G¨d−γς−1S,Ġd=ẊdẎd,G¨d=X¨dY¨d,ς=112−112,where γ is a constant value. One should note that J is invertible due to the invertibility of M. As mentioned above, trajectories should reach a sliding manifold in a limited bound and remain being bound in the presence of uncertainty and unmodelled dynamics. Hence, the control law U is taken as
(49)U=ueq+us,where us is taken for robust stability of the spherical robot in facing uncertainties and unmodelled dynamics.
(50)us=invJx^−kς−1sgnS−λĠ−Ġd,S=SxSy,k=K100K2,where K1,K2 are positive design parameters. Also, we take the Lyapunov stability theorem for this system as follows:
(51)V2=12STςS.By considering the sliding surface in (46), the control signal is
(52)U=J−1x^−Dx^+G¨d−γς−1S−kς−1sgnS−λĠ−Ġd.The derivative of Lyapunov function with respect to time is(53)V̇2t=STςG¨−G¨d+λĠ−Ġd=STςDx^+Jx^U−G¨d+λĠ−Ġd.By replacingU in (53), we have
(54)V̇2t=STςDx^+Jx^J−1x^−Dx^+G¨d−γς−1S−kς−1sgnS−λĠ−Ġd−G¨d+λĠ−Ġd=ST−γS−ksgnS≤−γS2−kS2≤−γ+kS2.Now, the design of the observer-based SMC is complete and the steps of the design can be summarized as the following steps: first, designing a NN-based observer whose stability is studied in (34) and developing a SMC for tracking control of the spherical robot using the Lyapunov function in (51) with the stability analysis in (53). Now, we are ready to prove the overall stability of the proposed controller in the following theorem.
(55)V=V1+V2.By replacing (41) and (54) in the time derivative of V, it takes the following form:
(56)V̇=V̇1+V̇2≤−12q0x~2+12δ¯2−γ−kS2.By defining ζ=γ−k and by choosing k≥γ, we have
(57)V̇≤−12q0x~2+12δ¯2−ζS2that indicates V̇≤0 as long as
(58)x~≥q0δ¯2,or
(59)S≥δ¯22ζ.SinceS=ė+diagλ1,λ2e,, (59) implies that [37]
(60)e≥1λminδ¯22ζ,where λmin=minλ1,λ2. Now, from (57), (59), and (60) one can conclude that (x~,ψ~,e) are semi globally uniformly ultimately bounded with the bounds of q0/δ¯2 and 1/λminδ¯2/2ζ for x~ and e, respectively.The next section is dedicated to the numerical evaluation of the proposed controller and comparing it with other controllers in the literature.


## 6. Simulation Results

### 6.1. Path Tracking

This section provides the simulation results through MATLAB, to verify the efficiency of the designed trajectory tracking controller observer-based SMC represented. The parameters of the spherical robot areMs=3 (kg), Mp=2 (kg), ρ=0.2 (m), l=0.075 (m), and g=9.81 (m/s2). Simulation is carried out with initial conditions as follows:
(61)Gd=XdYd=sintcost,Gt0=X0Y0=0.50.In the path tracking scheme, it is assumed that the centre of the spherical robot shell should move about the reference trajectory. The aim of the control is that the output tracks the reference path. The design parameters of the presented controller are chosen by trial and error asλ1=50,λ2=50,γ1=40,γ2=4,k1=0.1,k2=0.1. The observer gain is given by
(62)K0=1402000000001402000000001402000000001402T.The positive definite matrixQ=10I8×8 is chosen where I8×8 is an identity matrix. Besides, A0 is computed as follows:
(63)A0=−140−13900−140−14000−2−200−2−200−140−14001−140−14000−2−200−2−200−140−14000−140−13900−2−200−2−200−140−14000−140−14001−2−200−2−200.And the filter is chosen as(64)Li−1=s+2.The parameters of the proposed NN are selected by trial and error. In the simulations, for making the NN, 18 nodes are used. Moreover, to avoid the chattering caused by the SMC, the discontinuous sign function in the control law is substituted with the continuous tanh function [37]. The equations of the system are sampled with a sampling period of 1.0 ms for the trajectories. The simulation results are obtained as demonstrated in Figures 4–7.Figure 4
Robot trajectory aroundX and Y directions.Figure 5
Robot trajectory around theX–Y plane.Figure 6
Trajectory error aroundX and Y directions.
(a)
(b)Figure 7
The input torques applied to the robot.
(a)
(b)Figures4–7 show that X and Y are able to track the desired path successfully where X and Y are illustrated against the time and in an X–Y plane, respectively. It can be observed that the tracking error is bounded and the designed observer-based SMC can effectively reach the desired trajectory of the plant. In Figure 7, the input torques, τx and τy, about transverse and longitudinal axes for the desired trajectory are shown.Simulation results are presented in Figures4–7. Figures 4 and 5 show that X and Y are able to track the desired path successfully. Moreover, in Figure 6, it is crystal clear that the system errors are converging to a small neighbour around the origin. In order to examine the robustness of the proposed controller, another simulation was carried out in the presence of measurement noise. A white noise with a power of 0.01 and sampling time of 0.1 s that passed through a filter with the transfer function of 1/2s+1 was applied to the position sensor output signals.While disturbed by noise, Figure8 shows that the robot is successfully able to track the desired trajectory with a bounded tracking error. Figure 9(a) shows the position of the robot with respect to time. Therefore, from the above results, it can be concluded that the spherical robot with the observer-based SMC-designed controller can robustly track a desired circular path in the presence of the measurement noise. The applied input torques in the presence of noise are illustrated in Figure 9(b). To prevent impractical large input torques, they are bounded by applying saturation functions with ranges of 10 N·m.Figure 8
Robot trajectory in theX–Y plane.Figure 9
(a) Robot trajectory tracking performance around theX and Y directions in the presence of measurement noise. (b) Input torques applied to the robot in the presence of the measurement noise.
(a)
(b)


### 6.2. The Controller Design Comparison with SMC and Feedback Linearization

In this subsection, the performance of the proposed approach is compared with the two other controllers in the literature. To this end, two of the most recent and well-known control methods, namely, the SMC [29] and feedback linearization [17], are selected. Figures 10 and 11 depict the performance of the above controllers against the desired trajectory in (61) with G0=−1−1T. As it is expected, under relatively similar conditions, the feedback linearization has the convergence time due to the assumption that the dynamics nonlinearities are known. However, while SMC and observer-based SMC are slower, they have more robustness to the uncertainties and oscillations. In addition, despite the SMC and feedback linearization that enjoys the measurability of all the states, the observer-based SMC must estimate the immeasurable states (α,β). This fact has made the proposed controller the slowest one in terms of convergence. Overall, in comparison with other methods, the proposed controller demonstrates the same accuracy with a slightly slower response in the tracking performance.Figure 10
Comparing the observer-based SMC performance with the SMC and feedback linearization controllers in theX–Y plane.Figure 11
Comparing the observer-based SMC performance with the SMC and feedback linearization controllers: (a) trajectory tracking performance aroundX and Y directions and (b) trajectory tracking error convergence.
(a)
(b)


### 6.3. Conclusions

In this work, we introduced an extended sliding mode control scheme for trajectory tracking control of a spherical robot that uses a pendulum with 2-DOFs to provide the rolling motion around the transverse and longitudinal axes. The angles of the pendulum with respect to these axes are assumed to be immeasurable due to mechanical technicalities. To estimate the immeasurable states, an adaptive neural network-based observer was proposed. The observer adaptively estimates the nonlinearities and rejects the uncertainties of the robot while estimating the sphere states using an output feedback. The SMC uses the estimated states instead of the actual ones to stabilize the robot’s path tracking error. Finally, using the Lyapunov theorem, we showed that the proposed scheme is able to SGUUB stabilize the overall closed-loop system. Simulation results verify the proposed control scheme performance in comparison with other available approaches in the literature.The following improvements are considered in future work: (1) manufacturing the spherical robot and practical implementation of the proposed observer-based SMC on the spherical robot and (2) modelling the spherical robot by taking into account the friction between the shell and the ground and without decoupling the two actuation mechanisms.


## 6.1. Path Tracking

This section provides the simulation results through MATLAB, to verify the efficiency of the designed trajectory tracking controller observer-based SMC represented. The parameters of the spherical robot areMs=3 (kg), Mp=2 (kg), ρ=0.2 (m), l=0.075 (m), and g=9.81 (m/s2). Simulation is carried out with initial conditions as follows:
(61)Gd=XdYd=sintcost,Gt0=X0Y0=0.50.In the path tracking scheme, it is assumed that the centre of the spherical robot shell should move about the reference trajectory. The aim of the control is that the output tracks the reference path. The design parameters of the presented controller are chosen by trial and error asλ1=50,λ2=50,γ1=40,γ2=4,k1=0.1,k2=0.1. The observer gain is given by
(62)K0=1402000000001402000000001402000000001402T.The positive definite matrixQ=10I8×8 is chosen where I8×8 is an identity matrix. Besides, A0 is computed as follows:
(63)A0=−140−13900−140−14000−2−200−2−200−140−14001−140−14000−2−200−2−200−140−14000−140−13900−2−200−2−200−140−14000−140−14001−2−200−2−200.And the filter is chosen as(64)Li−1=s+2.The parameters of the proposed NN are selected by trial and error. In the simulations, for making the NN, 18 nodes are used. Moreover, to avoid the chattering caused by the SMC, the discontinuous sign function in the control law is substituted with the continuous tanh function [37]. The equations of the system are sampled with a sampling period of 1.0 ms for the trajectories. The simulation results are obtained as demonstrated in Figures 4–7.Figure 4
Robot trajectory aroundX and Y directions.Figure 5
Robot trajectory around theX–Y plane.Figure 6
Trajectory error aroundX and Y directions.
(a)
(b)Figure 7
The input torques applied to the robot.
(a)
(b)Figures4–7 show that X and Y are able to track the desired path successfully where X and Y are illustrated against the time and in an X–Y plane, respectively. It can be observed that the tracking error is bounded and the designed observer-based SMC can effectively reach the desired trajectory of the plant. In Figure 7, the input torques, τx and τy, about transverse and longitudinal axes for the desired trajectory are shown.Simulation results are presented in Figures4–7. Figures 4 and 5 show that X and Y are able to track the desired path successfully. Moreover, in Figure 6, it is crystal clear that the system errors are converging to a small neighbour around the origin. In order to examine the robustness of the proposed controller, another simulation was carried out in the presence of measurement noise. A white noise with a power of 0.01 and sampling time of 0.1 s that passed through a filter with the transfer function of 1/2s+1 was applied to the position sensor output signals.While disturbed by noise, Figure8 shows that the robot is successfully able to track the desired trajectory with a bounded tracking error. Figure 9(a) shows the position of the robot with respect to time. Therefore, from the above results, it can be concluded that the spherical robot with the observer-based SMC-designed controller can robustly track a desired circular path in the presence of the measurement noise. The applied input torques in the presence of noise are illustrated in Figure 9(b). To prevent impractical large input torques, they are bounded by applying saturation functions with ranges of 10 N·m.Figure 8
Robot trajectory in theX–Y plane.Figure 9
(a) Robot trajectory tracking performance around theX and Y directions in the presence of measurement noise. (b) Input torques applied to the robot in the presence of the measurement noise.
(a)
(b)


## 6.2. The Controller Design Comparison with SMC and Feedback Linearization

In this subsection, the performance of the proposed approach is compared with the two other controllers in the literature. To this end, two of the most recent and well-known control methods, namely, the SMC [29] and feedback linearization [17], are selected. Figures 10 and 11 depict the performance of the above controllers against the desired trajectory in (61) with G0=−1−1T. As it is expected, under relatively similar conditions, the feedback linearization has the convergence time due to the assumption that the dynamics nonlinearities are known. However, while SMC and observer-based SMC are slower, they have more robustness to the uncertainties and oscillations. In addition, despite the SMC and feedback linearization that enjoys the measurability of all the states, the observer-based SMC must estimate the immeasurable states (α,β). This fact has made the proposed controller the slowest one in terms of convergence. Overall, in comparison with other methods, the proposed controller demonstrates the same accuracy with a slightly slower response in the tracking performance.Figure 10
Comparing the observer-based SMC performance with the SMC and feedback linearization controllers in theX–Y plane.Figure 11
Comparing the observer-based SMC performance with the SMC and feedback linearization controllers: (a) trajectory tracking performance aroundX and Y directions and (b) trajectory tracking error convergence.
(a)
(b)


## 6.3. Conclusions

In this work, we introduced an extended sliding mode control scheme for trajectory tracking control of a spherical robot that uses a pendulum with 2-DOFs to provide the rolling motion around the transverse and longitudinal axes. The angles of the pendulum with respect to these axes are assumed to be immeasurable due to mechanical technicalities. To estimate the immeasurable states, an adaptive neural network-based observer was proposed. The observer adaptively estimates the nonlinearities and rejects the uncertainties of the robot while estimating the sphere states using an output feedback. The SMC uses the estimated states instead of the actual ones to stabilize the robot’s path tracking error. Finally, using the Lyapunov theorem, we showed that the proposed scheme is able to SGUUB stabilize the overall closed-loop system. Simulation results verify the proposed control scheme performance in comparison with other available approaches in the literature.The following improvements are considered in future work: (1) manufacturing the spherical robot and practical implementation of the proposed observer-based SMC on the spherical robot and (2) modelling the spherical robot by taking into account the friction between the shell and the ground and without decoupling the two actuation mechanisms.



---

*Source: 3129398-2018-10-16.xml*