1 Introduction

The last decades have witnessed a tremendous progress in the development of autonomous surface vehicles (ASVs). Real-time tracking control is one of important issues in the motion control of ASVs, which is concerned to design control commands/laws to force ASVs to reach and follow the desired time parameterized curves [1, 2]. Due to disturbance, severe operation condition and sensor noise, it is often very difficult to avoid errors between the desired and actual trajectories. Therefore, how to effectively and efficiently control an ASV to precisely track the desired paths is still an open challenging question.

There have been many studies on the tracking control of ASVs in the past few years. Typical tracking control methods are classified into sliding-mode control [36], nonlinear Lyapunov-based control [79] and neural network control [1012]. Sliding-mode control has the outstanding characteristics of insensitivity to parameter variations and good rejection to disturbances. It is very attractive to employ sliding-mode tracking controllers for ASVs. However, one major drawback of the sliding-mode approach is the high frequency of control action (chattering), which may result in discontinuous and non-smooth control laws. Nonlinear Lyapunov-based approaches for robotic systems usually start by constructing multiple control Lyapunov functions and then employ recursive backstepping or other combined techniques [79] to derive the control laws. The stability of the control system is guaranteed by a Lyapunov theory. However, the designed control laws are directly related to the tracking errors that may be initially very large, and the generated velocity commands start with very large values (velocity jumps). As a result, the required accelerations and forces will be infinitely large at those sharp change points, which is not practically possible.

To deal with the impractical problem of large initial velocities, Ghommam et al. [7] proposed a dynamic controller by generating torque signals using backstepping design methodology. However, it requires the vehicle nonlinear and complex dynamics, which are not always available. As effective methods for uncertain nonlinear systems, approximation-based neural networks (NNs) have been widely employed. For example, Lin et al. [13] developed a recurrent wavelet neural network (RWNN)-based controller. Chen et al. [14] proposed an adaptive NN tracking controller by incorporating the actuator configuration matrix and considering actuator saturation constraints. In [10, 12], a simple one-layer NN controller and an adaptive output feedback NN controller were proposed. Unfortunately, the existing NN-based tracking control algorithms require either on-line learning or off-line training procedures before the controllers are capable of controlling the vehicle properly. The learning algorithms are computationally complicated. Recently, Guerrero-González et al. [15] proposed a biologically inspired NN kinematic controller, where the model algorithm is shown to be computationally efficient. However, an on-line training phase is still needed, making its applicability dubious.

On the other hand, ASVs in practice must also be capable of operating in the environment subject to unknown ocean currents, which are usually unknown, stochastic and hard to model. Considering the fact that some ocean waters far away from the shore flow in one direction only, many researchers studied the control design of marine vehicles under the assumption that these currents are irrotational and constant [1618]. However, few results on the real-time tracking control of ASVs can be found. In order to compensate the influence of the currents, one feasible solution is to find a suitable observer that can deduce the unknown currents, and then design a proper feedback control. For example, Yang et al. [19] constructed an observer to provide an estimation of unknown time-variant disturbances for the tracking control of a ship. Tee and Ge [20] designed a high-gain observer for the surface vessel to tackle the output feedback problem. Moreover, a general observer scheme was presented in [21] for the path following control of an underactuated surface vessel. Interested readers concerning the surveys on disturbance observers are referred to [22, 23] and their references. In this paper, we employ an efficient exponential observer for the constant unknown ocean currents when a novel bio-inspired neurodynamics-based controller is proposed to directly tackle the impractical velocity-jump problem.

Motivated by the above considerations, this paper proposes a novel bioinspired neural dynamics-based approach to directly handle the impractical velocity-jump problem in the tracking control of ASVs subject to unknown ocean currents. Similar to many existing path tracking control methods, it is assumed that the location of the vehicle is completely and accurately known through various sensor measurement and signal processing systems, such as global positioning systems (GPS) and ultra-short baseline (USBL) acoustic positioning systems [24, 25]. The proposed tracking controller is first derived based on the error dynamics using conventional Lyapunov design method. Then, inspired by the unique features of the neural dynamics models derived from Hodgkin and Huxley’s membrane equation [26] for a biological neural system, three neural dynamics shunting models are integrated into the tracking controller. Meanwhile, a simple but efficient observer is designed to estimate the velocities of the unknown ocean currents. The stability of the control system under the controller and observer is rigorously guaranteed by a Lyapunov stability theory for cascaded systems. Distinct from the previous neural network-based approaches, the proposed neurodynamics-based control approach is designed without any on-line/off-line learning procedures. The control algorithm is therefore computationally efficient. In addition, the proposed approach is capable of eliminating the sharp velocity jumps due to sudden tracking error changes, generating smooth and continuous control signals, even under the influence of unknown ocean currents.

The paper is organized as follows. Section 2 briefly introduces some background for the proposed approach, including the kinematic model of an ASV, the tracking control problem and the neural dynamics model. Section 3 presents the design of the proposed neural dynamics-based tracking controller and the stable current observer. The stability of the control system and the tracking error convergence are analyzed in Sect. 4. Section 5 presents the simulation studies of the ASV to track a straight line and an elliptic path. A comparison to the conventional Lyapunov-based controller is presented. Concluding remarks are finally summarized in Sect. 6.

2 Background and problem formulation

This section first briefly describes the kinematic model of an ASV. Then, the corresponding tracking control problem is formulated. The biological membrane model and bioinspired shunting neural dynamics model are finally outlined.

2.1 Model of ASV

Marine vehicles require six independent coordinates to determine their complete configuration (position and orientation). The six different motion components are conveniently defined as surge, sway, heave, roll, pitch, and yaw [1]. It is common to reduce the general six degrees of freedom of the model to motion in the surge, sway, and yaw directions by neglecting the heave, roll, and pitch modes, which consequently obtains a general model for an ASV. Consider a two-dimensional (2D) Cartesian workspace, two coordinate frames are defined as the inertial reference frame \(\{I\}\) and the body-fixed coordinate frame \(\{B\}\) (see Fig. 1). In the case of a fixed current vector \(v_{{\rm c}}=[{v_{{{\rm c}}_{x}}},{v_{{{\rm c}}_{y}}}]^\top\), the kinematic equations of motion for the ASV can be written as

$$\begin{aligned} \left[ \begin{array}{ccc} \dot{x} \\ \dot{y} \\ \dot{\phi } \end{array}\right] = \left[ \begin{array}{ccc} \cos \phi &{} -\sin \phi &{} 0 \\ \sin \phi &{} \cos \phi &{} 0 \\ 0 &{} 0 &{} 1 \end{array}\right] \left[ \begin{array}{ccc} u \\ v \\ r \end{array}\right] + \left[ \begin{array}{ccc} {v_{{{\rm c}}_{x}}} \\ {v_{{{\rm c}}_{y}}} \\ 0 \end{array}\right] , \end{aligned}$$
(1)

where \(x\) and \(y\) represent the inertial coordinates of the center of mass (CM) of the vehicle; \(u\) and \(v\) are the surge (forward) and sway (side) velocities, respectively, defined in the body-fixed frame; \(\phi\) is the orientation of the vehicle measured from the inertial-\(X\) axis and \(r\) is its yaw (angular) velocity; \({v_{{{\rm c}}_{x}}}\) and \({v_{{{\rm c}}_{y}}}\) are nonzero ocean current velocities. In order to simplify the controller design, the ocean current here is assumed to be irrotational and constant.

Fig. 1
figure 1

Model of an autonomous surface vehicle (ASV)

The posture of the ASV in the inertial reference frame is uniquely determined by a vector \(P=[x,y,\phi ]^\top\). Given that a reference path provides the desired posture \(P_{{\rm d}}=[x_{{\rm d}},y_{{\rm d}},\phi _{{\rm d}}]^\top\), it connects a given set of way points. Consider the tracking of trajectory \(P_{{\rm d}}\) with the desired velocities \(u_{{\rm d}}\), \(r_{{\rm d}}\), and \(v_{{\rm d}}=0\), where no sway velocity is desired. The trajectory thus satisfies

$$\begin{aligned} \left[ \begin{array}{ccc} \dot{x}_{{\rm d}} \\ \dot{y}_{{\rm d}} \\ \dot{\phi }_{{\rm d}} \end{array}\right] = \left[ \begin{array}{ccc} \cos \phi &{} -\sin \phi \\ \sin \phi &{} \cos \phi \\ 0 &{} 0 \end{array}\right] \left[ \begin{array}{ccc} u_{{\rm d}} \\ r_{{\rm d}} \end{array}\right] , \end{aligned}$$
(2)

Define the tracking error in the initial reference frame as \(E_{{\rm I}}(t)=P-P_{{\rm d}}=[x_{{\rm e}},y_{{\rm e}},\phi _{{\rm e}}]^\top\). Then, the error expressed in the body-fixed frame \(E_{{\rm B}}(t)=[e_{{\rm x}},e_{{\rm y}},e_{{\phi}}]^\top\) is obtained using the global diffeomorphic coordinate transformation

$$\begin{aligned} \left[ \begin{array}{ccc} e_{{\rm x}} \\ e_{{\rm y}} \\ e_{\phi } \end{array}\right] = \left[ \begin{array}{ccc} \cos \phi &{} \sin \phi &{} 0 \\ -\sin \phi &{} \cos \phi &{} 0 \\ 0 &{} 0 &{} 1 \end{array}\right] \left[ \begin{array}{ccc} x_{{\rm e}} \\ y_{{\rm e}} \\ \phi _{{\rm e}} \end{array}\right] . \end{aligned}$$
(3)

Clearly, \(E_{{\rm I}}(t)= 0 \Leftrightarrow E_{{\rm B}}(t)= 0\). Taking the time derivative of Eq. (3) yields

$$\begin{aligned} \left\{ \begin{array}{l} \dot{e}_{{\rm x}} = u+re_{{\rm y}}-u_{{\rm d}}\cos e_\phi +{v_{{{\rm c}}_{x}}}\cos \phi +{v_{{{\rm c}}_{y}}}\sin \phi \\ \dot{e}_{{\rm y}} = v-re_{{\rm x}}+u_{{\rm d}}\sin e_\phi -{v_{{{\rm c}}_{x}}}\sin \phi +{v_{{{\rm c}}_{y}}}\cos \phi \\ \dot{e}_{\phi } = r-r_{{\rm d}} \end{array} \right. . \end{aligned}$$
(4)

Equation (4) describes the tracking error dynamics, which will be used to derive the tracking controller.

2.2 Tracking control problem

Consider the ASV represented by (1) in the presence of constant unknown ocean currents \({v_{{{\rm c}}_{x}}}\) and \({v_{{{\rm c}}_{y}}}\). Given the desired posture \(P_{{\rm d}}\). Design a smooth and continuous velocity control law for \(U=[u,v,r]^\top\) as a function of desired posture \(P_{{\rm d}}\), which drives the ASV to move, such that the actual vehicle state \(P(t)\) precisely tracks the desired posture \(P_{{\rm d}}\), i.e.,

$$\begin{aligned} \lim _{t\rightarrow \infty }P(t)=P_{{\rm d}}(t). \end{aligned}$$
(5)

In other word, the tracking error converges to zero as the time approaches infinite.

2.3 Model of shunting neural dynamics

Hodgkin and Huxley [26] proposed a model for a patch of membrane in a biological neural system using electrical circuit elements. This modeling work together with other experimental work led them to a Nobel Prize in 1963, for their discoveries concerning the ionic mechanisms involved in excitation and inhibition in the peripheral and central portions of the nerve cell membrane. In their membrane model, the dynamics of voltage across the membrane, \(V_{{\rm m}}\), can be described using the state equation technique as

$$\begin{aligned} C_{{\rm m}}\frac{{\rm d} V_{{\rm m}}}{{\rm d}t}&= -(E_{{\rm p}}+V_{{\rm m}})g_{{\rm p}}+(E_{\rm {Na}}-V_{{\rm m}})g_{\rm {Na}} \\&\quad -(E_{{\rm K}}+V_{{\rm m}})g_{{\rm K}}, \end{aligned}$$
(6)

where \(C_{{\rm m}}\) is the membrane capacitance. Parameters \(E_{{\rm K}}, E_{{\rm Na}}\) and \(E_{{\rm p}}\) are the Nernst potentials (saturation potentials) for potassium ions, sodium ions and the passive leak current in the membrane, respectively. Parameters \(g_{{\rm K}}, g_{{\rm Na}}\) and \(g_{{\rm p}}\) represent the conductance of potassium, sodium and passive channels, respectively. This model provided the foundation of the shunting model.

By setting \(C_{{\rm m}} = 1\) and substituting \(\xi _{{\rm I}} = E_{{\rm p}}+V_{{\rm m}},\,A = g_{{\rm p}},\,B = E_{{\rm Na}}\,+\,E_{{\rm p}},\,D\,=\,E_{{\rm K}}-E_{{\rm p}},\,S^{+}_{{\rm I}}\,=\,g_{{\rm Na}}\) and \(S^{-}_{{\rm I}}\,=\,g_{{\rm K}}\) in (6), a typical shunting model is obtained [26] as

$$\begin{aligned} \frac{{\rm d}\xi _{{\rm I}}}{{\rm d}t}\,=\,-A\xi _{{\rm I}}+(B-\xi _{{\rm I}})S_{{\rm I}}^+(t)-(D+\xi _{{\rm I}})S_{{\rm I}}^-(t), \end{aligned}$$
(7)

where \(\xi _{{\rm I}}\) is the neural activity (membrane potential) of the i-th neuron. Parameters A, B and D are nonnegative constants representing the passive decay rate, the upper bound and lower bound of the neural activity, respectively. Variable \(S_{{\rm I}}^+\) is the total external positive input to the neuron called excitatory input; variable \(S_{{\rm I}}^-\) is the total external negative input to the neuron called inhibitory input [27]. Note that the passive decay rate A determines the transient response to input signals, which play important roles in the model dynamics. Large A causes large passive decay rate of the neural activity and thus results in very slow response of the control system. The transient response to input signals does not depend on \(B\) and \(D\).

This shunting model was first proposed by Grossberg to understand the real-time adaptive behavior of individuals to complex and dynamic environmental contingencies. The dynamics behavior of this shunting model is featured by smooth and bounded output, that is, restricted to a bounded interval \([-D,\,B]\) and an automatic gain control. The interested reader is suggested to consult [27, 28] for more details. The shunting dynamics model has a lot of applications in biological and machine vision, sensory motor control and many other areas. For example, Yang and Meng [2931] developed the first innovative application to real-time path planning and tracking control of a mobile robot. Further, it was extended to various robotic systems [3234]. More recently, the similar control concept is used in the tracking control of deeply manned submarine vehicles [35].

3 Controller design

This section presents the fundamental idea of the proposed approach to solve the above mentioned tracking control problem. A tracking controller is designed by integrating three bioinspired neurodynamics components into the conventional Lyapunov synthesis to eliminate the sudden velocity jumps due to the smooth dynamics in the shunting neural models. In addition, an observer is proposed to estimate the unknown ocean currents.

3.1 Tracking controller

To drive the ASV reach the desired trajectory, a Lyapunov function candidate is first chosen as

$$\begin{aligned} V=\frac{1}{2}(e_{{\rm x}}^2+e_{{\rm y}}^2+e_\phi ^2). \end{aligned}$$
(8)

From (4), the time derivative of (8) is computed as

$$\begin{aligned} \dot{V}&= e_{{\rm x}}(u-u_{{\rm d}} \cos {e_\phi }+re_{{\rm y}}+{v_{{{\rm c}}_{x}}}\cos \phi +{v_{{{\rm c}}_{y}}}\sin \phi ) \\&\quad+e_{{\rm y}}(v+u_{{\rm d}} \sin {e_\phi }-re_{{\rm x}}-{v_{{{\rm c}}_{x}}}\sin \phi +{v_{{{\rm c}}_{y}}}\cos \phi ) \\&\quad+e_\phi (r-r_{{\rm d}}). \end{aligned}$$
(9)

Obviously, if we choose

$$\begin{aligned} \left\{ \begin{array}{l} u = -c_1e_{{\rm x}}+u_{{\rm d}} \cos {e_\phi }-\hat{v}_{{{\rm c}_{\rm x}}}\cos \phi -\hat{v}_{\rm c_y}\sin \phi \\ v = -c_2e_{{\rm y}}-u_{{\rm d}} \sin {e_\phi }+\hat{v}_{{{\rm c}_{\rm x}}}\sin \phi -\hat{v}_{\rm c_y}\cos \phi \\ r = -c_3{e_\phi }+r_{{\rm d}} \end{array} \right. , \end{aligned}$$
(10)

where \(c_{\rm 1},\,c_{\rm 2}\) and \(c_{\rm 3}\) are positive constants; \(\hat{v}_{{{\rm c}_{\rm x}}}\) and \(\hat{v}_{{{\rm c}_{\rm y}}}\) are the estimates of the current velocities \({v}_{{{\rm c}_{\rm x}}}\) and \({v}_{{{\rm c}_{\rm y}}}\), then the time derivative of V becomes

$$\begin{aligned} \dot{V}=-c_1e_{{\rm x}}^2-c_2e_{{\rm y}}^2-c_3{e_\phi }^2+\delta , \end{aligned}$$
(11)

with

$$\begin{aligned} \delta =\tilde{v}_{{{\rm c}_{\rm x}}}(e_{{\rm x}} \cos \phi -e_{{\rm y}}\sin \phi )\,+\,\tilde{v}_{\rm c_y}(e_{{\rm x}} \sin \phi +e_{{\rm y}} \cos \phi ), \end{aligned}$$
(12)

where \(\tilde{v}_{{{\rm c}_{\rm x}}}\) and \(\tilde{v}_{{{\rm c}_{\rm y}}}\) are the error variables defined as

$$\begin{aligned} \tilde{v}_{{{\rm c}_{\rm x}}}={v}_{{{\rm c}_{\rm x}}}-\hat{v}_{{{\rm c}_{\rm x}}},\,\,\tilde{v}_{\rm c_y}={v}_{\rm c_y}-\hat{v}_{\rm c_y}. \end{aligned}$$
(13)

Temporarily, \(\delta\) is treated as a variable, which will be addressed later by presenting a current observer based on Lyapunov stability theory.

By analyzing the performance of the tracking controller (10), it is found that velocity-jump problems are caused by the sudden changes in tracking errors \(e_{{\rm x}}\), \(e_{{\rm y}}\) and \({e_\phi }\). Inspired by the smooth neural dynamics of the shunting neural model, three components \(\xi _{{\rm x}}\), \(\xi _{{\rm y}}\) and \(\xi _\phi\) characterized by differential equations derived from the shunting model are used to replace the \(e_{{\rm x}},\,e_{{\rm y}}\) and \({e_\phi }\) in (10). Due to the dynamic behavior of \(x_{{\rm I}}\) in (7) as a function of the tracking errors, the proposed control commands should become smooth functions of tracking errors. The output of the shunting model changes as the input (tracking errors) changes, smoothly without any jumps even when sudden sharp changes in the input occur. Based on this control concept, the proposed tracking controller is given as

$$\begin{aligned} \left\{ \begin{array}{l} u = -\xi _{{\rm x}}+u_{{\rm d}} \cos {e_\phi }-\hat{v}_{{{\rm c}_{\rm x}}}\cos \phi -\hat{v}_{\rm c_y}\sin \phi \\ v = -\xi _{{\rm y}}-u_{{\rm d}} \sin {e_\phi }+\hat{v}_{{{\rm c}_{\rm x}}}\sin \phi -\hat{v}_{\rm c_y}\cos \phi \\ r = -\xi _{\phi }+r_{{\rm d}} \end{array} \right. , \end{aligned}$$
(14)

where \(\xi _{{\rm x}}\), \(\xi _{{\rm y}}\) and \(\xi _\phi\) are characterized by three shunting neural models as

$$\begin{aligned} \left\{ \begin{array}{l} \frac{d\xi _{{\rm x}}}{{\rm d}t}\,=\,-A_1\xi _{{\rm x}}\,+\,(B_1-\xi _{{\rm x}})f(e_{{\rm x}})\,-\,(D_1+\xi _{{\rm x}})g(e_{{\rm x}})\\ {} \frac{d\xi _{{\rm y}}}{{\rm d}t}\,=\,-A_2\xi _{{\rm y}}\,+\,(B_2-\xi _{{\rm y}})f(e_{{\rm y}})\,-\,(D_2+\xi _{{\rm y}})g(e_{{\rm y}}) \\ {} \frac{d\xi _\phi }{{\rm d}t}\,=\,-A_3\xi _\phi \,+\,(B_3-\xi _\phi )f({e_\phi })\,-\,(D_3+\xi _\phi )g({e_\phi }) \end{array} \right. . \end{aligned}$$
(15)

In (15), \(A_{i}\) (i = 1, 2, 3) are nonnegative constants representing the passive decay rates; \(B_{i}\) and \(D_{i}\) are the upper bound and lower bound of the velocity components \(\xi _{{\rm x}}\), \(\xi _{{\rm y}}\) and \(\xi _\phi\), respectively. Function \(f(x)\) is a linear-above-threshold function of the input x defined as \(f(x)\,=\,{\rm max} \{x, 0\}\), and \(g(x)\) is also a function of x defined as \(g(x)\,=\,{\rm max} \{-x, 0\}\). They can be explicitly expressed as

$$\begin{aligned} f(x)=\left\{ \begin{array}{l} x,{\quad }x \ge 0\\ 0,{\quad }x<0 \\ \end{array} \right. ,{\quad } {\rm and }{\quad } g(x)=\left\{ \begin{array}{l} 0,{\quad }x \ge 0\\ -x,{\quad }x<0 \\ \end{array} \right. . \end{aligned}$$

Replacing the variable x with \(e_{{\rm x}}, e_{{\rm y}}, e_\phi\) , respectively, yields the excitatory inputs \(f(e_{{\rm x}}), f(e_{{\rm y}})\) and \(f(e_\phi )\), and inhibitory inputs \(g(e_{{\rm x}}), g(e_{{\rm y}})\) and \(g(e_\phi )\) for Eq. (15).

3.2 Current observer

Let \(\hat{x}\) and \(\hat{y}\) be the estimates of the position x and y. Define

$$\begin{aligned} \left\{ \begin{array}{l} \dot{\hat{x}} = u\cos \phi -v \sin \phi +\hat{v}_{{{\rm c}_{\rm x}}}\,+\,k_{11} \tilde{x} \\ \dot{\hat{y}} = u\sin \phi +v \cos \phi +\hat{v}_{\rm c_y}\,+\,k_{21} \tilde{y} \\ \end{array} \right. , \end{aligned}$$
(16)

where \(\tilde{x}=x-\hat{x}\), \(\tilde{y}=y-\hat{y}\), \(k_{11}\) and \(k_{21}\) are positive constants. From (1) and (16), we obtain

$$\begin{aligned} \left\{ \begin{array}{l} \dot{\tilde{x}} = -k_{11} \tilde{x}+\tilde{v}_{{{\rm c}_{\rm x}}} \\ \dot{\tilde{y}} = -k_{21} \tilde{y}+\tilde{v}_{\rm c_y} \\ \end{array} \right. . \end{aligned}$$
(17)

If we choose

$$\begin{aligned} \left\{ \begin{array}{l} \dot{\hat{v}}_{{{\rm c}_{\rm x}}}=k_{12} \tilde{x} \\ \dot{\hat{v}}_{\rm c_y}=k_{22} \tilde{y} \\ \end{array} \right. , \end{aligned}$$
(18)

where \(k_{12}\) and \(k_{22}\) are positive constants, then the error system is obtained as

$$\begin{aligned} \left[ \begin{array}{ccc} \dot{\tilde{x}} \\ \dot{\tilde{y}} \\ \dot{\tilde{v}}_{{{\rm c}_{\rm x}}} \\ \dot{\tilde{v}}_{\rm c_y} \end{array}\right] = \left[ \begin{array}{cccc} -k_{11} &{} 0 &{} 1 &{} 0 \\ 0 &{} -k_{21} &{} 0 &{} 1 \\ -k_{12} &{} 0 &{} 0 &{} 0 \\ 0 &{} -k_{22} &{} 0 &{} 0 \end{array}\right] \left[ \begin{array}{ccc} {\tilde{x}} \\ {\tilde{y}} \\ {\tilde{v}}_{{{\rm c}_{\rm x}}} \\ {\tilde{v}}_{\rm c_y} \end{array}\right] , \end{aligned}$$
(19)

which can be written in a compact form as

$$\begin{aligned} \dot{Y}(t)=KY. \end{aligned}$$
(20)

Notice that the model (20) is a linear system, whose solution can be expressed as

$$\begin{aligned} {Y}(t)={Y}(0) e^{Kt}, \end{aligned}$$
(21)

where \(\tilde{Y}(0)\) is the initial state of the observer. Obviously, the observer system (20) is globally asymptotically stable if the gains \(k_{11},\,k_{12},\,k_{21}\) and \(k_{22}\) are chosen as positive such that the matrix K has negative real part eigenvalues.

Therefore, the system architecture of the proposed tracking controller can be depicted as Fig. 2. It contains three parts in addition to the plant: a motion planner, a neurodynamics-based tracker, and a current observer. The motion planner is used to generate real-time paths for the vehicle. The output of the motion planner gives the desired vehicle posture \(P_{{\rm d}}\). The current vehicle posture P is obtained through a positioning system. The error vector \(E_{{\rm B}}\) in the body-fixed frame is obtained through a transformation matrix \(T_{{\rm e}}\) using (3) from the posture error \(E_{{\rm I}}\) between the current and desired postures in the inertial reference frame. The inputs of the neurodynamics based tracker are the error vector \(E_{{\rm B}}\), the desired velocities \(u_{{\rm d}}\) and \(r_{{\rm d}}\), and the current estimate \(\hat{v}_{\rm c}\). The path tracker generates smooth and continues steering command vector U for the ASV. The current observer includes a state estimate of the vehicle position \([\hat{x}, \hat{y}]^\top\), a gain K and an integrator. The position estimate error between \([x, y]^\top\) and \([\hat{x}, \hat{y}]^\top\) is used to derive the estimate of the current for the tracker. The gain K is chosen such that the observer system is asymptotically stable. The ASV in the control system is disturbed by the unknown ocean current \(v_{\rm c}\).

Fig. 2
figure 2

Architecture of the proposed neurodynamics-based tracking control system

4 Stability analysis

The proposed control system can be proved to be globally asymptotically stable, and the tracking errors converge to zeros. In what follows, the stability of the overall system is analyzed using a Lyapunov theory for cascaded systems.

From Eqs. (4, 14, 15) and (20), the proposed tracking control system can be written in a cascaded form as

$$\begin{aligned} \dot{X}&= f_1(t,X)+g(t,X,Y)Y, \end{aligned}$$
(22)
$$\begin{aligned} \dot{Y}&= f_2(t,Y)=KY, \end{aligned}$$
(23)

where \(X\,=\,[e_{{\rm x}},e_{{\rm y}},e_\phi ,\xi _{{\rm x}},\xi _{{\rm y}},\xi _\phi ]^\top\), \(Y\,=\,[\tilde{x},\tilde{y},\tilde{v}_{{{\rm c}_{\rm x}}},\tilde{v}_{{{\rm c}_{\rm x}}}]^\top\);

$$\begin{aligned}&f_1(t, X) = \left[ \begin{array}{cccccc} -\xi _{{\rm x}}\,+\,re_{{\rm y}} \\ -\xi _{{\rm y}}\,-\,re_{{\rm x}} \\ -\xi _\phi \\ -\left[ A_1+f(e_{{\rm x}})+g(e_{{\rm x}})\right] \xi _{{\rm x}}\,+\,\left[ B_1f(e_{{\rm x}})-D_1g(e_{{\rm x}})\right] \\ -\left[ A_2+f(e_{{\rm y}})+g(e_{{\rm y}})\right] \xi _{{\rm x}}\,+\,\left[ B_2f(e_{{\rm y}})-D_2g(e_{{\rm y}})\right] \\ -\left[ A_3+f(e_\phi )+g(e_\phi )\right] \xi _{{\rm x}}\,+\,\left[ B_3f(e_\phi )-D_3g(e_\phi )\right] \end{array}\right] .\\&f_2(t, Y) = \left[ \begin{array}{cccccc} -k_{11} \tilde{x}\,+\,\tilde{v}_{{{\rm c}_{\rm x}}} \\ -k_{21} \tilde{y}\,+\,\tilde{v}_{\rm c_y} \\ -k_{12} \tilde{v}_{{{\rm c}_{\rm x}}} \\ -k_{22} \tilde{v}_{\rm c_y} \end{array}\right] ,{\quad } g(t,X,Y) = \left[ \begin{array}{cccc} 0 &{} 0 \\ 0 &{} 0 \\ \cos \phi &{} -\sin \phi \\ \sin \phi &{} \cos \phi \end{array}\right] ^\top . \end{aligned}$$

Notice that \(f_1(t,X)\) and \(f_2(t,Y)\) are continuously differentiable functions. If Y = 0, (22) becomes

$$\begin{aligned} \dot{X}=f_1(t,X). \end{aligned}$$
(24)

Therefore, (22) can be viewed as the system

$$\begin{aligned} \varSigma _1: \dot{X}\,=\,f_1(t,X), \end{aligned}$$
(25)

being perturbed by the output of the observer system

$$\begin{aligned} \varSigma _2: \dot{Y}\,=\,f_2(t,Y). \end{aligned}$$
(26)

The following Lemma [36] gives the stability for the cascaded systems (22) and (23).

Lemma 1

Consider the cascaded systems (22) and (23). Assume that

  1. (1)

    the system \(\varSigma _1\) in (25) is globally uniformly asymptotically stable with a Lyapunov function \(V_1(t,X)\) satisfying

    $$\left\| {\frac{{\partial V_{1} }}{{\partial X}}} \right\|\left\| X \right\| \le cV_{1} (t,X),\quad \forall \left\| X \right\| \ge \eta ,$$
    (27)

    where \(c>0\) and \(\eta >0\) are constants;

  2. (2)

    the function \(g(t,X,Y)\) satisfies

    $$\begin{aligned} \Vert g(t,X,Y)\Vert \le \rho _1(\Vert X\Vert )+\rho _2(\Vert Y\Vert )\Vert X\Vert . \end{aligned}$$
    (28)

    where \(\rho _1, \rho _2: \mathbb {R}_{\ge 0} \rightarrow \mathbb {R}_{\ge 0}\) are continuous functions.

  3. (3)

    the system \(\varSigma _2\) is globally uniformly asymptotically stable and for all \(t_0\ge 0\),

    $$\begin{aligned} \int _{t_0}^\infty \Vert Y(t, t_0, Y(t_0))\Vert dt \le \theta (\Vert Y(t_0)\Vert ), \end{aligned}$$
    (29)

    where the function \(\theta (\cdot )\) is a class \(\mathcal {K}\) function.

Then, the cascaded systems (22) and (23) are globally uniformly asymptotically stable.

In order to apply Lemma 1 to prove the asymptotical stability of the control system, a Lyapunov function candidate \(V_1\) for system (25) is chosen as

$$\begin{aligned} V_{1}=\frac{1}{2}\left( e_{{\rm x}}^2+e_{{\rm y}}^2+e_\phi ^2 +\frac{1}{B_1}\xi _{{\rm x}}^2+\frac{1}{B_2}\xi _{{\rm y}}^2+\frac{1}{B_3}\xi _{\phi }^2\right) , \end{aligned}$$
(30)

where \(\xi _{{\rm x}},\,\xi _{{\rm y}}\) and \(\xi _\phi\) are defined in (15). Taking the time derivative of (30) yields

$$\begin{aligned} \dot{V}_{1} = -e_{{\rm x}}\xi _{{\rm x}}-e_{{\rm y}}\xi _{{\rm y}}-e_\phi \xi _\phi +\frac{1}{B_1}\xi _{{\rm x}}\dot{\xi }_{{\rm x}}+\frac{1}{B_2}\xi _{{\rm y}}\dot{\xi }_{{\rm y}}+\frac{1}{B_3}\xi _{\phi }\dot{\xi }_\phi . \end{aligned}$$
(31)

Substituting (15) into (31) yields

$$\begin{aligned} \dot{V}_{1}&= -\beta _1\xi _{{\rm x}}^2+\left\{ \frac{1}{B_1}[B_1f(e_{{\rm x}})-D_1g(e_{{\rm x}})]-e_{{\rm x}}\right\} \xi _{{\rm x}} \\&-\beta _2\xi _{{\rm y}}^2+\left\{ \frac{1}{B_2}\left[ B_2f(e_{{\rm y}})-D_2g(e_{{\rm y}})\right] -e_{{\rm y}}\right\} \xi _{{\rm y}} \\&-\beta _3\xi _{\phi }^2+\left\{ \frac{1}{B_3}[B_3f(e_\phi )-D_3g(e_\phi )]-e_\phi \right\} \xi _\phi , \end{aligned}$$
(32)

where \(\beta _1=\frac{1}{B_1}[A_1+f(e_{{\rm x}})+g(e_{{\rm x}})],\,\beta _2=\frac{1}{B_2}[A_2+f(e_{{\rm y}})+g(e_{{\rm y}})],\,\beta _3=\frac{1}{B_3}[A_3+f(e_\phi )+g(e_\phi )]\). From the definition of functions \(f(\cdot )\) and \(g(\cdot )\), it knows that \(f(\cdot )\ge 0\) and \(g(\cdot )\ge 0\). In addition, the parameters \(A_i, B_i\) and \(D_i\) (\(i\,=\,1,2,3\)) are nonnegative constants, thus \(\beta _i \ge 0\).

Meanwhile, if we choose the constants \(B_i\,=\,D_i\) in the shunting equations, then (32) is rewritten as

$$\begin{aligned} \dot{V}_{1}&= -\beta _1\xi _{{\rm x}}^2+\left[ f(e_{{\rm x}})-g(e_{{\rm x}})-e_{{\rm x}}\right] \xi _{{\rm x}} \\&-\beta _2\xi _{{\rm y}}^2+\left[ f(e_{{\rm y}})-g(e_{{\rm y}})-e_{{\rm y}}\right] \xi _{{\rm y}} \\&-\beta _3\xi _{\phi }^2+\left[ f(e_\phi )-g(e_\phi )-e_\phi \right] \xi _\phi . \end{aligned}$$
(33)

From the definition of functions \(f(e_{{\rm x}})\) and \(g(e_{{\rm x}})\), if \(e_{{\rm x}}\ge 0\), then \(f(e_{{\rm x}})\,=\,e_{{\rm x}}\) and \(g(e_{{\rm x}})\,=\,0\). Thus,

$$\begin{aligned} \left[ f(e_{{\rm x}})-g(e_{{\rm x}})-e_{{\rm x}}\right] \xi _{{\rm x}}\,=\,e_{{\rm x}}-0-e_{{\rm x}}\,=\,0. \end{aligned}$$
(34)

Similarly, if \(e_{{\rm x}}\,<\,0\), then \(f(e_{{\rm x}})\,=\,0\) and \(g(e_{{\rm x}})\,=\,e_{\rm }x\). Thus,

$$\begin{aligned} \left[ f(e_{{\rm x}})-g(e_{{\rm x}})-e_{{\rm x}}\right] \xi _{{\rm x}}\,=\,0-(-e_{{\rm x}})-e_{{\rm x}}=0. \end{aligned}$$
(35)

In the same way, we can obtain

$$\begin{aligned} \left[ f(e_{{\rm y}})-g(e_{{\rm y}})-e_{{\rm y}}\right] \xi _{{\rm y}}\,=\,0, \end{aligned}$$
(36)
$$\begin{aligned} \left[ f(e_\phi )-g(e_\phi )-e_\phi \right] \xi _\phi&= 0. \end{aligned}$$
(37)

Hence, the time derivative of \(V_1\) is given as

$$\begin{aligned} \dot{V}_{1}\,=\,-\beta _1\xi _{{\rm x}}^2-\beta _2\xi _{{\rm y}}^2-\beta _3\xi _{\phi }^2 \le 0. \end{aligned}$$
(38)

Note that \(\dot{V}_1\,=\,0\) only when \(\xi _{{\rm x}}\,=\,0, \xi _{{\rm y}}\,=\,0\) and \(\xi _{\phi }\,=\,0\). By using (15) and the input–output properties of the shunting models, it can infer that if the outputs converge to some constant values (zeros), the inputs are supposed to go to constant values (zeros), namely, \(e_{{\rm x}}, e_{{\rm y}}, e_{\phi } \rightarrow 0\) as \(\xi _{{\rm x}}, \xi _{{\rm y}}, \xi _{\phi } \rightarrow 0\). By using invariance principle, it is known that the system \(\varSigma _1\) is globally uniformly asymptotically stable.

On the other hand, as shown in (21), the system \(\varSigma _2\) is also globally asymptotically stable. Furthermore, since \(\sin \phi\) and \(\cos \phi\) are bounded, \(g(t,X,Y)\) satisfies (28). Therefore, all the assumptions of Lemma 1 are satisfied, and it concludes that the proposed tracking system is globally asymptotically stable.

5 Simulation studies

In this section, the proposed tracking controller for the ASV is first applied to the tracking of a straight path and a circular path under unknown ocean currents. After that, a comparison study to the conventional controller is presented to show the efficiency of the proposed controller.

5.1 Tracking a straight path

To illustrate the effectiveness of the proposed approach, a simple straight line is first used as the desired path, which is described y = 2 and x = 0 in the Cartesian workspace. It can be generated using \(u_{{\rm d}}\,=\,2\,{\rm m/s}\) and \(r_{{\rm d}}\,=\,0\,{\rm m/s}\) for model (2). The ASV starts at \([0, 0, \pi /18]^\top\), while the desired initial posture is \([0.5, 2,0]^\top\). The initial posture error is thus \([-0.5, -2, \pi /18]^\top\). At the beginning period, the velocity of the ASV should be increase exponentially from zero to reach the desired velocities. Hence, the used reference velocity is \(u_{{\rm d}}\,=\,2(1-e^{-t/0.5})\). In addition, at \(t\,=\,7\,{\rm s}\), the ASV is disturbed by unknown (from the point of view of the controller) constant ocean currents described by \({v_{{{\rm c}}_{x}}}\,=\,0.5\,{\rm m/s},{v_{{{\rm c}}_{y}}}\,=\,-0.5\,{\rm m/s}\). The parameters for the proposed controller (14) are: \(A_1\,=\,5,\,B_1\,=\,D_1\,=\,3\); \(A_2\,=\,5,\,B_2\,=\,D_2\,=\,6\); and \(A_3\,=\,5,\,B_3\,=\,D_3\,=\,6\). The gains for the current observer are \(k_{11}\,=\,k_{21}\,=\,2\) and \(k_{12}\,=\,k_{22}\,=\,3\). The initial condition for the observer is \(\hat{v}_{{{\rm c}_{\rm x}}}\,=\,0,\hat{v}_{\rm c_y}\,=\,0\).

The tracking performance of the ASV is shown in Fig.  3a, where the actual vehicle path is denoted by the dash-dot line and the desired path is the solid line. The vehicle velocities generated using the proposed tracking controller are shown in Fig. 3b. It shows that the velocity commands are smooth and continues without any jumps. The error dynamics are shown in Fig. 3c, and the estimates of the unknown ocean currents are shown in Fig.  3d. Notice that although the ASV is disturbed by the ocean currents at \(t\,=\,7\,{\rm s}\), the proposed control approach with the current observer can drive the vehicle back to desired path shortly.

Fig. 3
figure 3

Simulation results of tracking a straight line using the proposed neurodynamics-based controller. a The dynamic tracking performance; b the generated velocity commands \(u,v\) and \(r\); c the tracking errors \(x_e,y_e\) and \(e_\phi\); d the estimates of \(v_{{c}_{x}}\) and \(v_{{c}_{y}}\)

5.2 Tracking an elliptic path

Then, an elliptic path, described by \((x-1)^2/1.5^2+(y-1)^2\,=\,1\), is used in the simulation study. Unlike the previous cases with a straight line, the reference velocities of an ellipse are not constant, but are time-varying, i.e., \(u_d=\sqrt{\dot{x}^2+\dot{y}^2}(1-e^{-t/0.5}), r_d=1.5/(\dot{x}^2+\dot{y}^2)(1-e^{-t/0.5})\) for model (2). The initial posture of the vehicle is \([-0.5,-0.6,\pi /10]^\top\), and the desired posture is \([1,0,0]^\top\), resulting in a big initial error \([-1.5,-0.6,\pi /10]^\top\). The parameters used in the controller are the same as the straight-line case. Assume that there are no ocean currents interfered in this case. The tracking performance of the ASV is shown in Fig. 4a. It shows that the ASV lands onto the desired circular path quickly. Fig.  4b shows the smooth and reasonable velocity commands. Fig. 4c shows the tracking errors approaching to zero as time increases.

Fig. 4
figure 4

Simulation results of tracking an elliptic path using the proposed neurodynamics-based controller. a The dynamic tracking performance; b the generated velocity commands \(u,v\) and r; c the tracking errors \(x_{{\rm e}},y_{{\rm e}}\) and \(e_\phi\)

5.3 Comparison to the conventional controller

To demonstrate the effectiveness of the proposed tracking controller, a comparison study to the conventional Lyapunov-based controller is conducted. The tracking controller defined in (10) is used in our simulation study under the same condition as that in Fig. 4. The control parameters are selected as \(c_1\,=\,3,c_2\,=\,3\) and \(c_3\,=\,0.2\). The tracking performance is shown in Fig. 5a. It is observed that the ASV takes a longer time to land on the desired elliptic path. The ASV velocities generated by the conventional controller are shown in Fig. 5b. It shows that the velocities change suddenly rather than gradually from zero at the beginning. This implies that the required accelerations are infinitely large at the beginning and also implies that the forces/torques should be infinitely large as well, which is not feasible in practice. However, using the proposed neurodynamics-based controller, the sharp velocity jumps are well eliminated, and the velocities become smooth and reasonable, as shown in Fig. 4b. In addition, the proposed controller tracks the elliptic path faster than the conventional controller.

Fig. 5
figure 5

Simulation results of tracking an elliptic path using the conventional Lyapunov-based controller. a The dynamic tracking performance; b the generated velocity commands \(u,v\) and r; c the tracking errors \(x_{{\rm e}},y_{e}\) and \(e_\phi\)

6 Conclusion

In this paper, a novel bioinspired neural dynamics-based tracking controller is proposed by integrating three shunting neural models into the conventional Lyapunov synthesis. A stable observer is designed to estimate the unknown ocean currents. The proposed tracking controller is capable of generating smooth, continuous control signals with zero initial values, even in the presence of unknown ocean currents. The tracking control system is proved to be globally asymptotically stable, and the tracking errors are guaranteed to converge to zeros. Simulation and comparison results show that the proposed tracking control algorithm is effective and efficient.

It is worth mentioning that although the practically impossible problem of velocity-jump is tackled by the proposed bioinspired approach, the dynamics of the surface vehicles with parameters which vary or are initially uncertain are not considered. In order to apply the proposed approach in practice more widely, it is interesting to integrating the proposed controller with other robust control methods such as model predictive control and adaptive control. This will be concerned in the future work.