Sliding-Mode Control of Unmanned Underwater Vehicle Using Bio-Inspired Neurodynamics for Discrete Trajectories

Trajectory tracking control can be considered as one of the main researches of unmanned underwater vehicles (UUV). The bio-inspired neurodynamics model was used to make the output continuous and smooth for the inflection points to deal with the speed jump of the conventional tracking controller for discrete trajectories. A horizon-plane trajectory tracking control law is designed using the bio-inspired neurodynamics model and sliding-mode method without chattering. Finally, the simulation of the mentioned two methods is compared with the results showing this as effective and feasible.


Introduction
Unmanned underwater vehicles (UUV) have been widely utilized in the academic fields, oil and gas industries, and military applications. Trajectory following control using minimum position sensors and modern control strategies is an essential problem for UUV. Due to the complexity and unpredictability of the underwater and under-actuated environment, powerful coupling and nonlinear features of UUV make UUV's tracking control a very challenging research area.
In the real word, most trajectories are made of discrete lines and some path planning algorithms generate the discrete trajectories. Conventional trajectory-tracking controller can only deal with continuously differentiable trajectories. Because of the non-holonomic constraints, the conventional solution produces discontinuous velocities with discrete trajectories, which is impossible in practice. Therefore, the study of tracking control for the discrete trajectory is an important issue in practice. We propose a novel control method by adding a neural system to solve the problems in tracking discrete trajectories.
Since the calculation of the hydrodynamics forces is complicated, the UUV control using classic model-based approaches is impossible. Due to its prominent advantages, including robustness to parametric uncertainties and satisfactory disturbance rejection capability, the sliding-mode control (SMC) is known as one of the popular control strategies employed in robust tracking control of mobile robots and UUV. Nevertheless, high fluctuations in its control signal, called the chattering phenomenon, is its essential deficiency [3,4], leading to significant heat losses in electrical power circuits and early destroying of actuators. Besides, it can stimulate high-frequency unmodeled components, affecting the controller efficiency.
The back stepping control approach has been utilized in mobile robots and UUV. The essential principle of this control strategy is to construct a simple velocity controller for Lyapunov-based stabilization of the closed-loop system. Although significant initial state errors can be compensated through the mentioned approach, its drawback is completely evident: The state errors can considerably affect the velocity control law, leading to significant velocities in major initial error situations and sudden speed variations induced by abrupt tracking errors. Accordingly, the control actions may exceed their permissible values at abrupt velocity changes.
To clarify the drawbacks of conventional model-based control approaches, SMC, and the back stepping approach, neural networks have been utilized by various controllers to provide more suitable control actions. Accordingly, there is no need for accurate modeling of underwater vehicles. Moreover, thruster and vehicle nonlinearities can be better described. However, to enhance the UUV performance, the online or offline tuning algorithm is inevitable in the mentioned neural network model, which can be considered as an essential drawback for these tracking control systems. The high computational load of this tuning algorithm procedure confines its application in actual plants.
Fuzzy tracking control strategies have a simple calculation algorithm that does not require online or offline tuning. Although the mentioned control strategies can compensate for the significant initial velocities effect, an empirical knowledge with trial and error is required to determine the fuzzy rules. In addition to the mentioned control strategies, several approaches have been presented for UUV control, including the feedback linearization technique [17][18][19], and H1 control [20,21] Selecting a comprehensive control approach among all the approaches mentioned above for resolving each of the mentioned issues for UUV is challenging.
Due to the shunting features of the bio-inspired neurodynamic model [10,22], the output of the bioinspired neurodynamic model is confined to a limited range and smoothed without any abrupt changes under sudden input variations. The hybrid controller using the bio-inspired model [10,23] have two major limitations: the tracking trajectory is continuous, not discrete, and the only one bio-inspired neurodynamic was constructed to make the velocity controller output smooth, and prevent abrupt changes of underwater vehicles and meet the thruster control limitation for the initial stage. The current research deals with the issue of abrupt changes in UUV for all tracking process, and two biological neural models are employed to design the tracking controller, and the speed in all dimensions is described through a shunting relation to make the output continuous and smooth for the inflection points. Therefore, a kinematic system integrating the SMC and two bio-inspired neurodynamic models are presented for tracking control of the discrete trajectory.
The rest of the current work is organized as the following. The kinematic model of UUV is introduced in Section 2. Section 3 discusses the SMC principles. We present the bio-inspired neurodynamic model in Section 4. In Section 5, we design a neural dynamics full-state SMC for discrete trajectories. The algorithm simulations are given in Section 6. In the last section, we conclude the paper and discuss the future scope of improvement.

Kinematic Model of UUV
To make research for the UUV, we often build two frames: inertial and body-fixed frames (see Fig. 1) shows. There are six degrees of freedom (DOF), including surge, sway, heave, roll, pitch, and yaw. q ¼ ½uvwpqr T denotes the spatial velocity state vector of UUV along with the body-fixed frame, and g ¼ ½xyzfhw T defines the position and direction state vector along with the inertial frame.
According to the thruster distribution of UUV (Sea-Kite II), there are only 4 DOF: Surge, heave, pitch and yaw. For horizon-plane motion control, without lateral force, there are 2 DOFs: Surge and yaw, we could get the non-holonomic constraints as follows [24], To realize the trajectory tracking control, UUV must track a predefined trajectory in the Cartesian workspace with a definite timing rule. The desired trajectory satisfies the UUV non-holonomic constraint. Equivalently, it tracks a trajectory generated by a reference UUV (Fig. 2).
To attain the horizontal plane motion control of the UUV, the reference state of the vehicle in the inertial frame is defined as For horizon-plane motion control of Seakite II, the UUV's kinematic model is described as: The motion tracking issue of the UUV is defined as the following: Under the non-holonomic constraints (v ¼ 0), design a control law to generate the bounded control input q c to force the UUV to move, such that the state errors e tend to zero.

The SMC
The state errors in the body frame are denoted by e ¼ e x e y e w Â Ã T . Here, g d À g ¼ x d À xy d À yw d À w ½ T denotes the path following error in the inertial frame. J is the conversion function from the body-fixed frame to the inertial one for the position and orientations.
The equivalent path following error in the body-fixed frame is described as The tracking controllers are designed to enforce the UUV to follow the desirable path by setting the surge and yaw motion speed and tend the state errors e ¼ e x e y e w Â Ã T to zero.
According to the relevant deduction [25], we could get when e x ¼ 0, consider Lyapunov function Using e w ¼ À arctanðu d e y Þ, taking the time derivative of Eq. (6), it yields _ V y ¼ e y _ e y ¼ e y ðÀe x r þ u d sin e w Þ ¼ Àe y e x r þ u d e y sinðÀarctanðu d e y ÞÞ ¼ Àe y e x r À u d e y sinðarctanðu d e y ÞÞ From the lemma 1 [8], one obtains u d e y sinðÀarctanðu d e y ÞÞ ! 0, (only when equality constraint is satisfied for u d e y ¼ 0), then _ V y 0, so we could make the conclusion that only e x converges to zero and e w converges to Àarctanðu d e y Þ, then the system converges to zero.
Based on the conclusion, the following sliding surfaces are proposed [3]: Through designing the SMC to realize s 1 ! 0, s 2 ! 0, e x and e w converge to zero and Àarctanðu d e y Þ, respectively, then it yields e y ! 0, e w ! 0.
The reaching law of equal speed is chosen as To decrease the chattering phenomenon, the sign function is replaced with the following continuous function.
where d i describes the positive decimal fraction.
Using a ¼ arctanðu d e y Þ, according to Eq. (5) and Eq. (8), it yields After some algebraic operations, one obtains the control law where The Bio-Inspired Neurodynamic Model To overcome the abrupt velocity changes and the control limitation issue, a bio-inspired neurodynamic model is incorporated with the virtual velocity controller. Due to the bio-inspired neurodynamic model's shunting features, it is confined to a specific range and kept smooth without any sudden changes under abrupt input changes, leading to a considerable improvement in the controller efficiency.
The bio-inspired neurodynamic model has been initially constructed by Grossberg [26]. This model can represent the real-time adaptive treatment of humans. It has been initially extracted using the membrane model developed by Hodgkin et al. [27] for a membrane patch based on electrical components.
The membrane model can describe the voltage dynamics through the membrane with the following state-space equations where the membrane capacitance is denoted by C m . The Nernst potentials for potassium and sodium ions, and the passive leak current in the membrane can be described through coefficients E K , E Na , and E P , respectively. g K , g Na , and g P describe the conductances of the potassium, sodium, and passive channels, and depend on the time-varying input signals.
S þ ¼ g Na and S À ¼ g K , the following shunting relation can be obtained where V indicates the regular activity (membrane potential) of the neuron. The passive decay rate and the upper and lower bounds of the neural and inhibitory input are denoted by coefficients A, B, and D, respectively. The shunting dynamics of a single neuron can be described using the mentioned relation.
The neutron dynamics are confined to a finite range ÀD; B ½ with automatic gain control. Thus, the following shunting expression can be obtained: where F e i ð Þ ¼ maxðe i ; 0Þ and G e i ð Þ ¼ maxðÀe i ; 0Þ. In a system with properly selected inputs, several desired functional features like competition, short-term memory, and upper and lower bounds can be extracted from the model. The shunting model can be described with an appropriate differential equation.
It is ensured that the system output V will be retained in the interval ÀD; B ½ for all excitatory and inhibitory inputs. It is continuous and smooth. Various benefits, including insured stability and computational performance, can be attained via the bio-inspired neurodynamic model for the UUV path following control. The bio-inspired neurodynamic model gives a smooth velocity response regarding the path following errors.

Control Strategy for Underwater Vehicles
To obtain continuous and practical outputs, two biological neural models are employed to design the tracking controller, and the velocity for any dimension can be described by a shunting relation. It can generate smooth velocity signals under sudden turns.
The structure of the presented neural dynamics based controller is shown in Fig. 3 T is the desired discrete trajectory to track and g ¼ xyw ½ T is the current state (including position and orientation). From the controller diagram, the proposed model includes two components. The first is the neural system, which can produce smooth velocity V v ¼ V vx V vy V vw Â Ã T and accurate virtual tracking trajectory T are the inputs for the first bio-inspired neurodynamic model. The produced virtual trajectory still consists discrete trajectories without considering the non-holonomic constraints of the UUV.
In the second part of the proposed model, the UUV's non-holonomic property is considered in the tracking controller to satisfy the special requirement. A second neural system is added to generate smooth virtual velocity V s ¼ V sx V sy V sw Â Ã T , which consists of the SMC inputs. Besides, the errors T describe the input for the second bio-inspired neurodynamic model. Then we could obtain the desired surge and yaw speed input q c ¼ u c r c ½ T for the UUV by sliding-mode controller. Through the UUV kinematic model and the conversion function J and the integrated process, we get the actual position and orientation of the UUV.
The X Àaxis and Y Àaxis velocities and angular velocity are represented by the shunting relations. Using the shunting equation discussed above, the following velocity dynamics can be derived ; 0 ð Þ, and g e x1 ð Þ ¼ max Àe x1 ; 0 ð Þ, Similarly, to obtain other variables, Eq. (3.2) could be integrated to get a virtual trajectory Ã T of the second biological neural model can be obtained in terms of the shunting model as where We obtain other variables similarly.
Using the virtual output V s ¼ V sx V sy V sw Â Ã T to replace the error e ¼ e x e y e w Â Ã T in Eq. (12), we obtain the control output of SMC given in Eq. (18) where Figure 3: Scheme of the proposed control system for underwater vehicles

Simulation
To evaluate the accuracy of the algorithms of bio-inspired control in comparison with the SMC for underwater vehicles, the two methods are simulated in MATLAB R2018b on a computer with Intel Core i7 CPU and a dominant frequency of 2.7 GHz with 8 GB RAM. We compare the bio-inspired control approach with the sliding-mode control method, including two cases: poly-line trajectory tracking and trapezoid-line trajectory tracking. The simulations are accomplished to clarify the benefits of the designed controller in tending an underwater to a predefined path.
The focus of the current study is on a discrete trajectory, which indicates that the path is discontinuous and does not satisfy the non-holonomic constraints. The fundamental issue we solve here is the sharp jumps from the initial state errors and the discontinuity when there are sharp turns in the desirable path.

Poly-Line Path Following
In the current section, a poly-line trajectory with two rotations is considered to clarify the efficiency of the presented neural dynamics-based full-state tracking controller. Tab. 1 gives the controller parameters.
The discrete trajectory includes three lines. The initial and final points in the Cartesian coordinate are located at (1, 1) and (5, 7), respectively. The initial orientation of the discrete path is chosen as 45°. At points (3,3) and (3,5), the direction of the discrete path is changed from 45°to 90°and from 90°to 45°, respectively. The UUV is initially located at (0.5, 0), with the direction at 0°. The UUV begins with position and direction errors (0.5, 1) and 45°, respectively. Moreover, the UUV has two 45°direction variations at points (3,3) and (3,5). As shown in Fig. 4, for the bio-inspired controller, at both rotating points, the UUV has position offsets from the predefined path such that the real path can meet the non-holonomic limitations; while for the path following performed by the SMC, the non-holonomic limitations are not fulfilled, generating discontinuous velocities. It indicates that more deviations from the desirable trajectory can be found at rotating points than the corresponding ones in the presented controller. The current states of UUV while tracking Poly-line trajectory using two methods are presented in Fig. 5. x(m) Besides, it can be observed from Fig. 6 that for the proposed controller, the UUV begins quickly to catch up with the desirable path, the forward and angular velocities grow slowly and smoothly at the start point. At two rotating points, the UUV's orientation varies slowly and smoothly without abrupt changes. For the remainder of the trajectory following, the UUV drives with an extremely stable velocity. While for the other method, the controller generates discontinuous angular velocities at two rotating points, and the angular velocities vary from 0 to 3.1 rad/s and 0 to −3.3 rad/s, respectively.

Poly-line Trajectory Tracking
In the current section, a trapezoid-line trajectory with four rotations is simulated to demonstrate the efficiency of the presented neural dynamics-based full-state path following controller. Tab. 2 presents the controller parameters.
The discrete trajectory includes four lines. The initial and final points lie at (1, 1) and (6.2, 1) in the Cartesian coordinate, respectively. The initial orientation of the discrete trajectory is considered as 0°. At points (7, 1), (5,3), (3,3) and (1, 1), the discrete trajectory changes its orientation for four times. The UUV's initial location is (0, 0.5), with the direction at 0°. The UUV begins with position and direction errors as (1, 0.5) and 0°, respectively. As presented in Fig. 7, for the bio-inspired controller, at both turn points, the UUV's position deviates from the desirable path such that the real trajectory can fulfill the non-holonomic limitations, while the SMC can follow the trajectory without the satisfaction of the nonholonomic constraints, which leads to discontinuous velocities. It can be concluded that the UUV has more significant offsets from the desirable trajectory at rotating points than the corresponding ones in the presented controller. The current states of UUV while tracking the Trapezoid-line trajectory using two methods are shown in Fig. 8.
Also, as presented in Fig. 9, for the designed controller, the UUV begins quickly to reach the desired trajectory. The forward and angular velocities grow steadily and smoothly at the starting point. At two rotating points, the UUV's direction is varied slowly and smoothly without sudden changes. For the remaining of the trajectory following, the UUV drives at an enormously stable velocity. While for the other method, the controller causes discontinuous angular velocities at four rotating points, and the angular velocities vary from 0 to 3.1 rad/s, 0 to 1 rad/s, 0 to 1.5 rad/s, and 0 to 2.8 rad/s, respectively.  Therefore, we conclude that the designed controller produces extremely smooth forward and angular velocities without any sudden changes and discontinuities in the entire path following process.

Conclusion
In the current work, the path following using the SMC approach and the bio-inspired neurodynamic model was proposed to make the output continuous and smooth for the inflection points. The simulation of the plane trajectory tracking control was presented under different discrete trajectories. From the simulation results, the designed control system shows stability and robustness clearly. The verification experiment in the pool will be carried out in the future. Moreover, to cope with actual conditions, ocean currents should be considered. Conflicts of Interest: The authors declare that they have no conflicts of interest to report regarding the present study.