1 Introduction

The number of ships with dynamic positioning (DP) control system has risen from the initial several to thousands, and the increasing trend has continued. And DP ships are generally used in pipeline laying, submarine rescue and so on [1]. In addition, DP control system is a complex nonlinear system with the characters of multi-input multi-output, uncertain disturbances, parameter uncertainties and so on. Through real-time measurement of marine vehicles’ position, DP control system with its own actuators does not depend on other thrusters, but by comparing to the desired state and using some control law to command the error between desired position and real position, then delivering orders to actuators. Thus, actuators generate forces and moments to eliminate effect of environmental disturbances so as to steer DP ships to desired position.

The research of DP control system has gone through several stages, from proportion integration differentiation (PID) control to nonlinear adaptive control and hybrid intelligent control, which has been improving the performance and maneuverability of DP ships [2, 3]. Now, mixed two or more control methods [4,5,6,7,8,9,10,11,12] (such as robust control, backstepping control technique, adaptive control, fuzzy control, sliding mode control, neural network control) are commonly used in DP control system. In particular, combined the adaptive fuzzy control and backstepping control method is adopted in DP control [13,14,15,16,17]. An adaptive fuzzy controller combined with the vectorial backstepping method was introduced to solve problems of unknown parameters and environmental disturbances in the paper [13]. And a robust fuzzy controller with optimal \(H^{\infty }\) control techniques was proposed for DP control system to exterminate the effects of environmental disturbances [18]. In order to assess performances of DP control system, paper [19] compared the fuzzy controller with PID controller in same environmental conditions. Considering of wave-frequency motions and the actuators’ dynamics, nonlinear observer based on backstepping was proposed for DP system which allowed a convenient tuning of the gains for the control signal to be compatible with the limitation of the actuators [20]. However, due to actuator’s mechanical properties, time-delay problem generally exists in most of control system. Furthermore, the general time-delay will lead to some disadvantages such as overshoot changed bigger, longer adjustment time. In addition, general time-delay also lead to bad impact on dynamic characteristics of control system such as instability and degrade, which increases difficulties of controller designed. Therefore, it is important to deal with problem of time-delay in process of control system designed.

Recently, there are many papers about time-delay system. And these control methods which mixed adaptive control method, backstepping control method and fuzzy logic control method are used in time-delay system [21,22,23,24]. In order to solve problem of time-delay, Lyapunov stabilization theories are regarded as one of the common methods [25,26,27,28,29,30]. Besides, combined with fuzzy adaptive backstepping control technique, dynamic surface control was introduced to solve input-delay and unknown nonlinear functions existing in nonlinear strict-feedback system [25]. To handle problems of unmodeled dynamics and time-delay in strict-feedback nonlinear systems, an adaptive fuzzy controller was developed in the paper [26]. In order to solve problems of uncertainties, output delays and disturbances, H-infinite control algorithm was applied in fuzzy adaptive tracking control for nonlinear systems in the paper [23]. In addition, considering uncertain time-delay system, the adaptive sliding mode control was used to deal with the state time-delay and external disturbances [23, 28, 30].

From the above, although the time-delay problem has caught attentions to many scholars, problems of time-delay in DP controller designed are rarely mentioned. On the one hand, the limitation of actuator is one of aspects leading to time-delay; specifically, the transition time from largest negative forces to largest positive forces will make the actuator not immediately respond to control commands. On the other hand, the respond time of actuators for control instructions is a dynamic process since each sampling time in this process is limited. Thus, the problem of time-delay in DP ships increases difficulty of control system designed. Using a state-derivative control law, a robust H∞ control of neutral system turned the input-delay system to a neutral time-delay system in the paper [31]. The feedforward and feedback optimal active control law was used to deal with time-delay in offshore platform and demonstrated the effectiveness and feasibility by numerical example in the paper [27]. Thus, solving the time-delay problem and approaching the unmodeled items are the main difficulties to be settled in this paper. Therefore, the main contribution of this paper is utilized fuzzy approximation to approach unmodeled items and adaptive control law is proposed based on backstepping technique and Lyapunov stabilization theories to steer ships to desired position. With good performance of dealing with time-delay problem, the advantage of the proposed control scheme has good ability of approaching unmodeled dynamics.

The rest of the paper is organized as follows. Problem formulation is presented in Sect. 2. Based on backstepping technique and Lyapunov stabilization theories, the control law is proposed, and fuzzy approximation is applied to approach unmodeled dynamics in Sect. 3. MATLAB simulation results are compared to conventional PID control in cases of with and without time-delay in Sect. 4. Finally, the conclusion is summarized in Sect. 5.

2 Problem Formulation

2.1 DP Ship’s Mathematic Model with Time-Delay

In order to analyze the motion of DP ships, two reference coordinate systems including earth-fixed reference frame denoted as \(O_{E} - X_{E} Y_{E} Z_{E}\) and body-fixed reference frame denoted as \(o_{b} - x_{b} y_{b} z_{b}\) are introduced and the two frames have the following relationship, shown in Fig. 1.

Fig. 1
figure 1

Two reference frames

As shown in Fig. 1, horizontal motion in 3 degrees of freedom (DOF) which are surge, sway and yaw is commonly described in DP control system. Due to the difficult in describing DP model with input time-delay in high frequency, the low frequency of DP motion is studied on this paper. Models for DP are derived under the assumption of low speed. Under low-speed motion of DP ships, Coriolis and centripetal matrix is neglected and damping matrix is considered as a linear matrix. Assuming that the ship is bilateral symmetry, DP ship’s mathematical model of low frequency in 3-DOF is [32]:

$$\begin{aligned} {\dot{\varvec{\upeta }}} & = {\mathbf{R}}(\psi ){\varvec{\upupsilon}} \\ M{\dot{\varvec{\upupsilon }}} + D{\varvec{\upupsilon}} & = {\varvec{\uptau}} + {\mathbf{R}}^{\rm T} (\psi ){\mathbf{b}} + {\varvec{\Delta}} \\ \end{aligned}$$
(1)

where speed and position vectors of DP ship are \({\varvec{\upupsilon}} = [u,v,r]^{\rm T}\), \({\varvec{\upeta}} = [x,y,\psi ]^{\rm T}\), respectively. \(M \in \Re^{3 \times 3}\) is the total mass matrix containing the inertia mass matrix \(M_{RB} \in \Re^{3 \times 3},\) \(M_{RB} = M_{RB}^{\rm T} ,\dot{M}_{RB} = 0\) and the added mass matrix \(M_{A} \in \Re^{3 \times 3}\) caused by the inertia of surrounding fluid; \(D \in \Re^{3 \times 3} ,D > 0\) is the hydrodynamic damping matrix; in low-speed motion, the damping matrix is usually satisfied with property of \(D = D^{\rm T}\); \({\varvec{\uptau}} \in \Re^{3}\) is control force caused by the thrusters of DP ship; \({\mathbf{b}} \in \Re^{3}\) is environmental disturbing vectors including wind, wave and current; \({\varvec{\Delta}} \in \Re^{3}\) is the unmodeled dynamics due to ship structural disturbances and uncertain parameters; \({\mathbf{R}}(\psi ) \in \Re^{3 \times 3}\) is coordinate transforming matrix between the earth-fixed frame and body-fixed frame, and \({\mathbf{R}}(\psi )\) is represented as

$${\mathbf{R}}(\psi ) = \left[ {\begin{array}{*{20}c} {\cos \left( \psi \right)} & { - \sin \left( \psi \right)} & 0 \\ {\sin \left( \psi \right)} & {\cos \left( \psi \right)} & 0 \\ 0 & 0 & 1 \\ \end{array} } \right]$$
(2)

Thus, 3-DOF horizontal kinematic and dynamic motion equation of DP ships with the character of input time-delay can be rewritten as:

$$\begin{aligned} {\dot{\varvec{\upeta }}} & = {\mathbf{R}}(\psi ){\varvec{\upupsilon}} \\ M{\dot{\varvec{\upupsilon }}} + D{\varvec{\upupsilon}} & = {\varvec{\uptau}}(t - T) + {\mathbf{R}}^{\text{T}} (\psi ){\mathbf{b}} + {\varvec{\Delta}} \\ \end{aligned}$$
(3)

where \(T = [T_{1} ,T_{2} ,T_{3} ]^{\text{T}}\) represents for time-delay of response which is given rise by the time-delay of actuator in direction of surge, sway and yaw (that is in frame of \(o_{b} - x_{b} y_{b} z_{b}\)) and \(t = [t_{1} ,t_{2} ,t_{3} ]^{\text{T}}\) is time vector.

Considering input time-delay caused by actuators on DP ships, the time-delay of actuators can be transferred to the time-delay of state variables [3]. In order to determine the special formula of motion equation with time-delay states and simplify calculation of motion equation, formula (3) can be replaced by the following time-delay system:

$$\begin{aligned} {\dot{\varvec{\upeta }}} & = {\mathbf{R}}(\psi ){\varvec{\upupsilon}} \\ M{\dot{\varvec{\upupsilon }}}(t - T) + D{\varvec{\upupsilon}}(t - T) & = {\varvec{\uptau}} + {\mathbf{R}}^{\rm T} (\psi ){\mathbf{b}} + {\varvec{\Delta}} \\ \end{aligned}$$
(4)

where \({\varvec{\upupsilon}}(t - T) = [u(t - T),v(t - T),r(t - T)]^{\text{T}} \in \Re^{3}\) and the derivative of \({\varvec{\upupsilon}}(t - T)\) is determined as

$${\dot{\varvec{\upupsilon }}}(t - T) = \frac{{\partial {\varvec{\upupsilon}}}}{\partial (t - T)}\frac{\partial (t - T)}{\partial t} = \frac{{\partial {\varvec{\upupsilon}}}}{\partial t} = {\dot{\varvec{\upupsilon }}}(t)$$
(5)

Combining (4) and (3), the kinematic and dynamic motion equations of DP ships with property of time-delay are rewritten as

$$\begin{aligned} {\dot{\varvec{\upeta }}}(t - T) & = {\mathbf{R}}(\psi ){\varvec{\upupsilon}}(t - T) \\ {\dot{\varvec{\upupsilon }}}(t - T) & = M^{ - 1} [{\varvec{\uptau}} - D{\varvec{\upupsilon}}(t - T) + {\mathbf{R}}^{\rm T} (\psi ){\mathbf{b}} + {\varvec{\Delta}}] \\ \end{aligned}$$
(6)

2.2 Control Objective

Define desired position vector as \(\eta_{d} = \left[ {x_{d} ,y_{d} ,\psi_{d} } \right]^{\rm T}\). And the control objective is to design backstepping control law and fuzzy approximation approach so as to steer DP ship to \(\eta_{d}\) with problems of time-delay, unmodeled items and disturbances from wind, wave, current.

3 Adaptive Controller Design Based on Backstepping Method and Fuzzy Approximation Approach

Firstly, to handle the problem of time-delay, adaptive controller is designed to steer ships to desired position based on backstepping method and Lyapunov stabilization theories. Then, fuzzy logic language and fuzzy control theories are adopted to approximate the unmodeled items. In addition, environmental disturbances are determined when sea state is known such as wind speed, wind direction and so on.

3.1 Backstepping Controller Design with Fuzzy Approximation Approach

The backstepping control law is designed as following steps.

First step:

Define error variables as

$$\begin{aligned} {\mathbf{z}}_{1} & = {\varvec{\upeta}}(t - T) - {\varvec{\upeta}}_{d} = \left[ {z_{1x} ,z_{1y} ,z_{1\psi } } \right]^{\rm T} \\ {\mathbf{z}}_{2} & = {\varvec{\upupsilon}}(t - T) - {\varvec{\upalpha}}_{1} = \left[ {z_{2x} ,z_{2y} ,z_{2\psi } } \right]^{\rm T} \\ \end{aligned}$$
(7)

In order to simply calculating the process, virtual stabilization function is chosen as:

$${\varvec{\upalpha}}_{1} = {\mathbf{R}}^{\text{T}} (\psi )({\dot{\varvec{\upeta }}}_{d} - K_{1} {\mathbf{z}}_{1} )$$
(8)

Here, \(K_{1} = K_{1}^{\text{T}} \in \Re^{3 \times 3}\) is the positive matrix, and \(K_{1} = {\text{diag}}\left( {0.1,0.2,0.3} \right)\). Thus, DP ship’s motion Eq. (6) can be transferred into:

$$\begin{aligned} {\dot{\mathbf{z}}}_{1} & = {\mathbf{R}}(\psi ){\mathbf{z}}_{2} - K_{1} {\mathbf{z}}_{1} \\ M{\dot{\mathbf{z}}}_{2} & = - D{\varvec{\upupsilon}}(t - T) - M{\dot{\varvec{\upalpha }}}_{1} + {\varvec{\uptau}} + {\mathbf{R}}^{\rm T} (\psi ){\mathbf{b}} + {\varvec{\Delta}} \\ \end{aligned}$$
(9)

Based on Lyapunov stabilization theories, first Lyapunov function is defined as:

$$V_{1} = \frac{1}{2}{\mathbf{z}}_{1}^{\text{T}} {\mathbf{z}}_{1}$$
(10)

The derivate of \(V_{1}\) is derived by combining with (8) and (9) as

$$\dot{V}_{1} = {\mathbf{z}}_{1}^{\text{T}} {\dot{\mathbf{z}}}_{1} = - {\mathbf{z}}_{1}^{\text{T}} K_{1} {\mathbf{z}}_{1} + {\mathbf{z}}_{1}^{\text{T}} {\mathbf{R}}(\psi ){\mathbf{z}}_{2}$$
(11)

Due to positive definite property of \(K_{1}\), variable of \({\mathbf{z}}_{1}\) is stabilization when \({\mathbf{z}}_{2} = 0\).

Second step:

The second Lyapunov function \(V_{ 2}\) is chosen as

$$V_{ 2} = V_{1} + \frac{1}{2}{\mathbf{z}}_{2}^{\text{T}} M{\mathbf{z}}_{2}$$
(12)

Combining (10) with (11), the derivate of \(V_{2}^{*}\) is derived as

$$\begin{aligned} \dot{V}_{ 2} & = \dot{V}_{1} + {\mathbf{z}}_{2}^{\text{T}} M{\dot{\mathbf{z}}}_{2} \\ & = - {\mathbf{z}}_{1}^{\text{T}} K_{1} {\mathbf{z}}_{1} + {\mathbf{z}}_{1}^{\text{T}} {\mathbf{R}}(\psi ){\mathbf{z}}_{2} + {\mathbf{z}}_{2}^{\text{T}} ( - D{\varvec{\upupsilon}}(t - T) \\ & \quad - \,M{\dot{\varvec{\upalpha }}}_{1} + {\varvec{\uptau}} + {\mathbf{R}}^{\rm T} (\psi ){\mathbf{b}} + {\varvec{\Delta}}) \\ \end{aligned}$$
(13)

The control system is stabilization under Lyapunov function \(\dot{V}_{ 2} < 0\). Thus, the Backstepping control law \({\varvec{\uptau}}\) is designed as

$${\varvec{\uptau}} = M{\dot{\varvec{\upalpha }}}_{1} + D{\varvec{\upupsilon}}(t - T) - K_{2} {\mathbf{z}}_{2} - {\mathbf{R}}^{\text{T}} (\psi ){\mathbf{z}}_{1} - {\mathbf{R}}^{\rm T} (\psi ){\mathbf{b}} - {\varvec{\Delta}}$$
(14)

where \(K_{2} \in \Re^{3 \times 3}\) is diagonal positive definite matrix, and here \(K_{2} = 1{\text{e8}} \times {\text{diag}}\left( {1,1,100} \right)\).

Therefore, derivate of \(\dot{V}_{ 2}\) is changed as

$$\dot{V}_{ 2} = - {\mathbf{z}}_{2}^{\text{T}} K_{2} {\mathbf{z}}_{2} - {\mathbf{z}}_{1}^{\text{T}} K_{1} {\mathbf{z}}_{1} < 0$$
(15)

Since parameter matrix \(K_{2} = K_{2}^{\text{T}} > 0_{3 \times 3}\), so second Lyapunov function \(V_{2}^{*}\) is stabile. And \(0_{n \times n}\) means \(n \times n\)-dimensional zero matrix.

Third step:

Due to effect of unmodeled dynamics existing in DP motion process, the above designed control law \({\varvec{\uptau}}\) cannot meet the requirements. It is necessary to approach the unmodeled items. Thus, the control law \({\varvec{\uptau}}\) is redesigned as:

$${\varvec{\uptau}}^{ *} = \hat{f}({\dot{\varvec{\upalpha }}}_{1} ,{\varvec{\upupsilon}}(t - T)) - {\mathbf{R}}^{\text{T}} (\psi ){\mathbf{z}}_{1} - K_{2} {\mathbf{z}}_{2} - {\mathbf{R}}^{\rm T} (\psi ){\mathbf{b}}$$
(16)

where

$$\begin{aligned} \hat{f}({\dot{\varvec{\upalpha }}}_{1} ,{\varvec{\upupsilon}}(t - T)) & \to f({\dot{\varvec{\upalpha }}}_{1} ,{\varvec{\upupsilon}}(t - T)) \\ f({\dot{\varvec{\upalpha }}}_{1} ,{\varvec{\upupsilon}}(t - T)) & = D{\varvec{\upupsilon}}(t - T) + M{\dot{\varvec{\upalpha }}}_{1} - {\varvec{\Delta}} \\ \end{aligned}$$
(17)

where \(\hat{f}({\dot{\varvec{\upalpha }}}_{1} ,{\varvec{\upupsilon}}(t - T))\) is used to approximate function of \(f({\dot{\varvec{\upalpha }}}_{1} ,{\varvec{\upupsilon}}(t - T))\). In order to approach the function of \(f({\dot{\varvec{\upalpha }}}_{1} ,{\varvec{\upupsilon}}(t - T))\), (17) can be replaced by

$$\begin{aligned} \hat{f}({\dot{\varvec{\upalpha }}}_{1} ,{\varvec{\upupsilon}}(t - T)) & = M{\mathbf{R}}^{\text{T}} (\psi )({\varvec{\ddot{\upeta }}}_{d} - K_{1} {\dot{\mathbf{z}}}_{1} ) + D{\varvec{\upupsilon}}(t - T) \\ & \quad \dot{\psi }M{\dot{\mathbf{R}}}^{\text{T}} (\psi )({\dot{\varvec{\upeta }}}_{d} - K_{1} {\mathbf{z}}_{1} ) - {\varvec{\Delta}} \\ \end{aligned}$$
(18)

The input variables of fuzzy controller are six fuzzy subsets, and input variables are defined as

$$\begin{aligned} {\mathbf{x}} & = \left[ {\begin{array}{*{20}c} {\begin{array}{*{20}c} x & y & \psi \\ \end{array} } & u & v & r \\ \end{array} } \right]^{\rm T} \\ & = \left[ {\begin{array}{*{20}c} {x_{1} } & {x_{2} } & {\begin{array}{*{20}c} {x_{3} } & {x_{4} } & {x_{5} } & {x_{6} } \\ \end{array} } \\ \end{array} } \right]^{\rm T} \\ \end{aligned}$$
(19)

Assume that number of fuzzy rule is \(N\), and the \(i\)th fuzzy rule is expressed as [3, 33,34,35]

$$R^{\left( i \right)} :IF\;x_{1} \;{\text{is}}\;\mu_{1}^{i} ,{\text{and}}, \ldots ,{\text{and}}\;x_{n} \;{\text{is}}\;\mu_{n}^{i} \;,THEN\;\hat{f}\;{\text{is}}\;E^{i} \left( {i = 1,2, \ldots ,N,\;n = 1,2, \ldots ,6} \right)$$
(20)

where \(\mu_{n}^{i}\) is the membership function of \(x_{n}\). Here, fuzzy set is define as \(l_{i} = 1,2,3,4,5\), and thus, number of fuzzy rule is defined as \(N = 6^{{l_{i} }}\). And the membership functions in fuzzy approximation approach are chosen as \(\mu_{n}^{i} = {\text{e}}^{{\left( { - \left( {\frac{{x - a_{i} }}{{b_{i} }}} \right)^{2} } \right)}}\).

Combining product inference machine with single-valued fuzzification controller, the fuzzy system is obtained by using center of gravity defuzzification as

$$\hat{f}({\mathbf{x}}\left| {\varvec{\uptheta}} \right.) = \frac{{\sum\nolimits_{i = 1}^{N} {\theta_{i} \prod\nolimits_{j = 1}^{n} {\mu_{j}^{i} (x_{i} )} } }}{{\sum\nolimits_{i = 1}^{N} {\prod\nolimits_{j = 1}^{n} {\mu_{j}^{i} (x_{i} )} } }} = {\varvec{\upxi}}^{\rm T} ({\mathbf{x}}){\varvec{\uptheta}}$$
(21)

where

$${\varvec{\upxi}}({\mathbf{x}}) = \left[ {\xi_{1} ({\mathbf{x}}), \ldots ,\xi_{N} ({\mathbf{x}})} \right]^{\rm T}$$
(22)
$${\varvec{\uptheta}} = \left[ {\theta_{1} , \ldots ,\theta_{N} } \right]^{\rm T}$$
(23)
$$\xi_{i} ({\mathbf{x}}) = {{\left( {\prod\limits_{j = 1}^{n} {\mu_{j}^{i} (x_{i} )} } \right)} \mathord{\left/ {\vphantom {{\left( {\prod\limits_{j = 1}^{n} {\mu_{j}^{i} (x_{i} )} } \right)} {\left( {\sum\limits_{i = 1}^{N} {\prod\limits_{j = 1}^{n} {\mu_{j}^{i} (x_{i} )} } } \right)}}} \right. \kern-0pt} {\left( {\sum\limits_{i = 1}^{N} {\prod\limits_{j = 1}^{n} {\mu_{j}^{i} (x_{i} )} } } \right)}}$$
(24)

The fuzzy approximation function \(\hat{F}\) of \(\hat{f}({\varvec{\upalpha}}_{1} ,{\dot{\varvec{\upalpha }}}_{1} )\) is defined as

$$\hat{F} = \left[ {\begin{array}{*{20}c} {\hat{F}_{1} } & {\hat{F}_{2} } & {\hat{F}_{3} } \\ \end{array} } \right]^{\rm T} = {\varvec{\upxi}}^{\rm T} ({\mathbf{x}}){\varvec{\uptheta}}$$
(25)

Based on approximating principle, there exists an optimal fuzzy parameters’ vector \({\varvec{\uptheta}}^{*}\) satisfying \(\hat{F}^{ *} = {\varvec{\upxi}}^{\rm T} ({\mathbf{x}}){\varvec{\uptheta}}^{ *}\) and \(\left\| {\hat{F} - \hat{F}^{ *} } \right\| \le \varepsilon ,\varepsilon < 0\), and \(\varepsilon\) is arbitrarily small.

Let \({\tilde{\varvec{\uptheta }}} = {\varvec{\uptheta}}^{*} - {\varvec{\uptheta}}\), thus

$$\begin{aligned} \hat{F} & = {\varvec{\upxi}}^{\rm T} ({\mathbf{x}}){\varvec{\uptheta}} \\ F^{*} & = {\varvec{\upxi}}^{\rm T} ({\mathbf{x}}){\varvec{\uptheta}}^{ *} \\ \tilde{F} & = {\varvec{\upxi}}^{\rm T} ({\mathbf{x}}){\tilde{\varvec{\uptheta }}} \\ \tilde{F} & = F^{*} - \hat{F} \\ \end{aligned}$$
(26)

Therefore, the adaptive control law \({\varvec{\uptau}}\) is

$${\varvec{\uptau}}^{ *} = \hat{F} - {\mathbf{R}}^{\text{T}} (\psi ){\mathbf{z}}_{1} - K_{2} {\mathbf{z}}_{2}$$
(27)

Thus, the second Lyapunov function \(V_{2}\) is modified as

$$\begin{aligned} V_{2}^{ *} & = V_{1} + \frac{1}{2}{\mathbf{z}}_{2}^{\text{T}} M{\mathbf{z}}_{2} + \frac{1}{2}{\tilde{\varvec{\uptheta }}}^{\text{T}} \varGamma^{ - 1} {\tilde{\varvec{\uptheta }}} \\ & = V_{1} + \frac{1}{2}{\mathbf{z}}_{2}^{\text{T}} M{\mathbf{z}}_{2} + \frac{1}{2}\sum\limits_{i = 1}^{n} {{\tilde{\varvec{\uptheta }}}_{i}^{\rm T} \varGamma_{i}^{ - 1} {\tilde{\varvec{\uptheta }}}_{i} } \\ \end{aligned}$$
(28)

where \(\varGamma_{i}^{ - 1} \in \Re^{N \times N}\) is the positive definite matrix.

At this time, the derivative of \(V_{2}\) is determined from (16) to (28)

$$\begin{aligned} \dot{V}_{2}^{ *} & = - {\mathbf{z}}_{1}^{\text{T}} K_{1} {\mathbf{z}}_{1} - {\mathbf{z}}_{2}^{\text{T}} K_{2} {\mathbf{z}}_{2} + {\mathbf{z}}_{2}^{\text{T}} \left( {\hat{F} - f({\dot{\varvec{\upalpha }}}_{1} ,{\varvec{\upupsilon}}(t - T))} \right) + {\tilde{\varvec{\uptheta }}}^{\text{T}} \Gamma^{ - 1} {\dot{\tilde{\varvec{\uptheta }}}} \\ & = - {\mathbf{z}}_{1}^{\text{T}} K_{1} {\mathbf{z}}_{1} - {\mathbf{z}}_{2}^{\text{T}} K_{2} {\mathbf{z}}_{2} + {\tilde{\varvec{\uptheta }}}^{\text{T}} \Gamma^{ - 1} {\dot{\tilde{\varvec{\uptheta }}}} \\ & \quad + \,{\mathbf{z}}_{2}^{\text{T}} \left( {\hat{F} - F^{*} - \left( {f({\dot{\varvec{\upalpha }}}_{1} ,{\varvec{\upupsilon}}(t - T)) - F^{*} } \right)} \right) \\ & = - {\mathbf{z}}_{1}^{\text{T}} K_{1} {\mathbf{z}}_{1} - {\mathbf{z}}_{2}^{\text{T}} K_{2} {\mathbf{z}}_{2} - {\mathbf{z}}_{2}^{\text{T}} \left( {f({\dot{\varvec{\upalpha }}}_{1} ,{\varvec{\upupsilon}},t) - F^{*} } \right) \\ & \quad + \,{\mathbf{z}}_{2}^{\text{T}} \tilde{F} + {\tilde{\varvec{\uptheta }}}^{\text{T}} \Gamma^{ - 1} {\dot{\tilde{\varvec{\uptheta }}}} \\ & = - {\mathbf{z}}_{1}^{\text{T}} K_{1} {\mathbf{z}}_{1} - {\mathbf{z}}_{2}^{\text{T}} K_{2} {\mathbf{z}}_{2} - {\mathbf{z}}_{2}^{\text{T}} {\varvec{\upomega}} + {\mathbf{z}}_{2}^{\text{T}} {\tilde{\varvec{\uptheta }}}^{\text{T}} {\varvec{\upxi}}({\mathbf{x}}) + {\tilde{\varvec{\uptheta }}}^{\text{T}} \Gamma^{ - 1} {\dot{\tilde{\varvec{\uptheta }}}} \\ \end{aligned}$$
(29)

where \({\varvec{\upomega}} = f({\dot{\varvec{\upalpha }}}_{1} ,{\varvec{\upupsilon}}(t - T)) - F^{*}\). The parameters’ adaptive law can be chosen as

$${\dot{\tilde{\varvec{\uptheta }}}} = - \varGamma {\varvec{\upxi}}^{\rm T} ({\mathbf{x}}){\mathbf{z}}_{2}$$
(30)

Thus, \(\dot{V}_{2}\) is determined as

$$\dot{V}_{2} = - {\mathbf{z}}_{1}^{\text{T}} K_{1} {\mathbf{z}}_{1} - {\mathbf{z}}_{2}^{\text{T}} K_{2} {\mathbf{z}}_{2} - {\mathbf{z}}_{2}^{\text{T}} {\varvec{\upomega}} \le 0$$
(31)

Therefore, system is stabile when \(\dot{V}_{2} < 0\).

3.2 Environmental Disturbances

Considering the external environmental disturbances as slowly varying disturbances (SVD), the environmental disturbances are estimated by the mathematical model of wind, wave and current. And the forces and moments caused by wind, wave and the current on DP ships are calculated by the following part [36, 37].

The SVD vector is represented as

$${\mathbf{b}} = {\varvec{\uptau}}_{\text{wind}} + {\varvec{\uptau}}_{\text{wave}} + {\varvec{\uptau}}_{\text{current}}$$
(32)

Based on the Isherwood formula, the wind forces and moment are determined as

$$\begin{aligned} X_{\text{wind}} & = \frac{1}{2}C_{X}^{\text{wind}} \left( {\alpha_{R} } \right)\rho_{a} V_{{_{R} }}^{2} A_{T} \\ Y_{\text{wind}} & = \frac{1}{2}C_{Y}^{\text{wind}} \left( {\alpha_{R} } \right)\rho_{a} V_{{_{R} }}^{2} A_{L} \\ N_{\text{wind}} & = \frac{1}{2}C_{N}^{\text{wind}} \left( {\alpha_{R} } \right)\rho_{a} V_{{_{R} }}^{2} A_{L} L \\ \end{aligned}$$
(33)

where \(C_{X} ,C_{Y} ,C_{N}\) are coefficients of wind forces and moment, \(\rho_{a}\) is air density, \(A_{T} ,A_{L}\) are frontal projection area and lateral projection area above waterline, respectively, \(L\) is the total length of DP ship, and \(V_{R}\) is the relative wind velocity.

And the coefficients of wind forces and moment are accurately determined by wind tunnel test. However, the wind tunnel test is time waste, energy waste and cost waste. Then, the researchers proposed the empirical formula to calculate the coefficients. Most commonly used in these methods is the Isherwood formula. And this method adapted the multiple regression technique to analyze the measurement data.

Thus, the most optimum fitted equation of the measurement data is determined by regression analysis. And the coefficients of wind forces and moment \(C_{X}^{\text{wind}} ,C_{{_{Y} }}^{\text{wind}} ,C_{{_{N} }}^{\text{wind}}\) are derived as

$$\begin{aligned} C_{X}^{\text{wind}} & = A_{0} + A_{1} \frac{{2A_{L} }}{{L^{2} }} + A_{2} \frac{{2A_{T} }}{{B^{2} }} + A_{3} \frac{L}{B} + A_{4} \frac{S}{L} + A_{5} \frac{C}{L} + A_{6} G \\ C_{{_{Y} }}^{\text{wind}} & = - \left( {B_{0} + B_{1} \frac{{2A_{L} }}{{L^{2} }} + B_{2} \frac{{2A_{T} }}{{B^{2} }} + B_{3} \frac{L}{B} + B_{4} \frac{S}{L} + B_{5} \frac{C}{L} + B_{6} \frac{{A_{ss} }}{{A_{L} }}} \right) \\ C_{{_{N} }}^{\text{wind}} & = - \left( {C_{0} + C_{1} \frac{{2A_{L} }}{{L^{2} }} + C_{2} \frac{{2A_{T} }}{{B^{2} }} + C_{3} \frac{L}{B} + C_{4} \frac{S}{L} + C_{5} \frac{C}{L}} \right) \\ \end{aligned}$$
(34)

where \(B\) is beam of DP ship, \(S\) is lateral projection perimeter above waterline, \(G\) is the number of mast or the strut, \(A_{SS}\) represents the lateral projection above waterline, \(C\) is the fixed distance, \(A_{i} ,B_{i} \left( {i = 0, \ldots ,6} \right),C_{j} \left( {j = 0, \ldots ,5} \right)\) are constant values, and their detailed values are in [32].

Therefore, wind forces and moment of 3-DOF directions with surge, sway and yaw are considered as

$${\varvec{\uptau}}_{\text{wind}} = \left[ {\begin{array}{*{20}c} {X_{\text{wind}} } & {Y_{\text{wind}} } & {N_{\text{wind}} } \\ \end{array} } \right]^{\rm T}$$
(35)

In DP ship’s low-frequency (LF) motion process, 2-order waves are considered as the main factors in SVD. Caused by the 2-order waves, the wave drift forces and moment not only change the heading and tracking of DP ship but also have an important effect on position in DP ship and the drilling platform. Assuming the 2-order waves are regular beam waves, the wave forces and moment are determined as the following part. And the wave forces and moment vector are represented as

$$\begin{aligned} X_{\text{wave}} = \frac{1}{2}\rho La^{2} C_{X}^{\text{wave}} \left( \lambda \right)\cos \chi \hfill \\ Y_{\text{wave}} = \frac{1}{2}\rho La^{2} C_{Y}^{\text{wave}} \left( \lambda \right)\sin \chi \hfill \\ N_{\text{wave}} = \frac{1}{2}\rho La^{2} C_{N}^{\text{wave}} \left( \lambda \right)\sin \chi \hfill \\ \end{aligned}$$
(36)

where \(\chi\) represents wave encounter angle, \(a\) is ratio of wave length to ship length. Related to the wave length, the coefficients \(C_{{_{X} }}^{\text{wave}} \left( \lambda \right),C_{Y}^{\text{wave}} \left( \lambda \right),C_{N}^{\text{wave}} \left( \lambda \right)\) of wave forces and moment are regressed by ship model test as

$$\begin{aligned} C_{{_{X} }}^{\text{wave}} \left( \lambda \right) & = 0.05 - 0.2*\left( {\frac{\lambda }{L}} \right) + 0.75*\left( {\frac{\lambda }{L}} \right)^{2} - 0.51*\left( {\frac{\lambda }{L}} \right)^{3} \\ C_{Y}^{\text{wave}} \left( \lambda \right) & = 0.46 + 6.83*\left( {\frac{\lambda }{L}} \right) - 15.65*\left( {\frac{\lambda }{L}} \right)^{2} + 8.44*\left( {\frac{\lambda }{L}} \right)^{3} \\ C_{N}^{\text{wave}} \left( \lambda \right) & = - 0.11 + 0.68*\left( {\frac{\lambda }{L}} \right) - 0.79*\left( {\frac{\lambda }{L}} \right)^{2} + 0.21*\left( {\frac{\lambda }{L}} \right)^{3} \\ \end{aligned}$$
(37)

Therefore, the wave forces and moment are derived as

$${\varvec{\uptau}}_{\text{wave}} = \left[ {\begin{array}{*{20}c} {X_{\text{wave}} } & {Y_{\text{wave}} } & {N_{\text{wave}} } \\ \end{array} } \right]^{\rm T}$$
(38)

A simple calculating method of current forces and moment is assumed the current as the uniform flow, using experienced coefficients \(C_{X}^{\text{current}} ,C_{Y}^{\text{current}} ,C_{N}^{\text{current}}\) of current forces and moment. Define the current forces and moment vector as

$${\varvec{\uptau}}_{\text{current}} = \left[ {\begin{array}{*{20}c} {X_{\text{current}} } & {Y_{\text{current}} } & {N_{\text{current}} } \\ \end{array} } \right]^{\rm T}$$
(39)

And the current forces and moment can be calculated at the same method of waves, and thus the current forces and moment are derived as

$$\begin{aligned} X_{\text{current}} & = 0.5\rho V_{\text{c}}^{2} A_{T} C_{X}^{\text{current}} \\ Y_{\text{current}} & = 0.5\rho V_{\text{c}}^{2} A_{S} C_{Y}^{\text{current}} \\ N_{\text{current}} & = 0.5\rho V_{\text{c}}^{2} A_{T} LC_{N}^{\text{current}} \\ \end{aligned}$$
(40)

where \(V_{\text{c}}\) represents the current velocity, and here \(V_{\text{c}} = 0.5\,{{\text{m}} \mathord{\left/ {\vphantom {{\text{m}} {\text{s}}}} \right. \kern-0pt} {\text{s}}}\).

The external environment disturbances tend to stable in a small range of a fixed value. However, in actual operating condition, the external environment disturbances are changed with the character of irregular, nonlinear, complex and so on. Especially in the extreme sea conditions, the complex of calculating environmental disturbances increases the difficulty of the design of the control system for DP ships. Therefore, the changing condition of DP operation is another control range of switching control or the hybrid control. And one detail case of switching control on ship motion control system was designed in the paper [38].

And SVD in this paper is more close to the real environmental disturbances. In addition, the related parameters for SVD are listed in Table 1.

Table 1 Related parameters

3.3 PID Controller Design

A conventional PID control is introduced in this subsection and is to be compared to the proposed control law. Thus, the advantages and differences between PID control and the proposed control law are more clear and intuitive. Define \({\mathbf{e}} = \eta - \eta_{d} = \left[ {e_{x} ,e_{y} ,e_{\psi } } \right]^{\rm T} ,{\dot{\mathbf{e}}} = \dot{\eta } - \dot{\eta }_{d}\), and the PID control law [2] is

$${\varvec{\uptau}} = K_{P} {\mathbf{e}} + K_{I} \int\limits_{0}^{t} {{\mathbf{e}}\,{\text{d}}t} + K_{D} {\dot{\mathbf{e}}}$$
(41)

where \(K_{P} ,K_{I} ,K_{D} \in \Re^{3 \times 3}\) are the control gains. Here \(K_{P} ,K_{I} ,K_{D}\) are selected as in the case of without time-delay

$$\begin{aligned} K_{P} & = {\text{diag}}\left( {6.5e5,7.5e5,6.5e8} \right) \\ K_{I} & = {\text{diag}}\left( {1e1,1e1,10.1} \right) \\ K_{D} & = {\text{diag}}\left( {3.5e6,10.5e6,7e9} \right) \\ \end{aligned}$$
(42)

In the condition of time-delay, \(K_{P} ,K_{I} ,K_{D}\) are chosen as

$$\begin{aligned} K_{P} & = {\text{diag}}\left( {4.6e5,14.2e5,8.1e8} \right) \\ K_{I} & = {\text{diag}}\left( {10,0.5,0.4} \right) \\ K_{D} & = {\text{diag}}\left( {3.0e6,7.4e6,3.5e9} \right) \\ \end{aligned}$$
(43)

The simulation results are implemented with and without time-delay in two cases of disturbances.

4 Numerical Simulation

Based on horizontal motion (6) of DP ship with time-delay in Sect. 2, the main parameters are shown as follows [3]:

$$M = \left[ {\begin{array}{*{20}c} {9.1948 \times 10^{7} } & 0 & 0 \\ 0 & {9.1948 \times 10^{7} } & {9.6979 \times 10^{8} } \\ 0 & {9.6979 \times 10^{8} } & {1.0724 \times 10^{11} } \\ \end{array} } \right]$$
(44)
$$D = \left[ {\begin{array}{*{20}c} {1.5073 \times 10^{6} } & 0 & 0 \\ 0 & {8.1687 \times 10^{6} } & {9.6979 \times 10^{8} } \\ 0 & {9.6979 \times 10^{8} } & {1.2568 \times 10^{11} } \\ \end{array} } \right]$$
(45)

And delayed time constant is \(T = [15\,{\text{s}}\;\;10\,{\text{s}}\;\;12\,{\text{s}}]^{\rm T}\). The initial position is \(\eta_{0} { = }\left[ {\begin{array}{*{20}c} { - 10\,{\text{m}}} & { - 5\,{\text{m}}} & { - 10^{ \circ } } \\ \end{array} } \right]^{\rm T}\). The desired position is \(\eta_{d} { = }\left[ {\begin{array}{*{20}c} {0\,{\text{m}}} & {0\,{\text{m}}} & {0^{ \circ } } \\ \end{array} } \right]^{\rm T}\). The initial value of parameter \({\varvec{\uptheta}}\) is zero. In fuzzy approximation approach, the scope of position can be set as \([ - 30\,{\text{m}},30\,{\text{m}}]\), and the domain of input speed can be set as \([ - 10\,{{\text{m}} \mathord{\left/ {\vphantom {{\text{m}} {{\text{s}},\;10\,{{\text{m}} \mathord{\left/ {\vphantom {{\text{m}} {\text{s}}}} \right. \kern-0pt} {\text{s}}}}}} \right. \kern-0pt} {{\text{s}},\;10\,{{\text{m}} \mathord{\left/ {\vphantom {{\text{m}} {\text{s}}}} \right. \kern-0pt} {\text{s}}}}}]\). The domain of heading angle deviation can be set as \([ - {\pi \mathord{\left/ {\vphantom {\pi {2,\,{\pi \mathord{\left/ {\vphantom {\pi 2}} \right. \kern-0pt} 2}}}} \right. \kern-0pt} {2,\,{\pi \mathord{\left/ {\vphantom {\pi 2}} \right. \kern-0pt} 2}}}]\), the angular velocity field can be set as \([ - 1\,{{\text{rad}} \mathord{\left/ {\vphantom {{\text{rad}} {{\text{s}},\;1\,{{\text{rad}} \mathord{\left/ {\vphantom {{\text{rad}} {\text{s}}}} \right. \kern-0pt} {\text{s}}}}}} \right. \kern-0pt} {{\text{s}},\;1\,{{\text{rad}} \mathord{\left/ {\vphantom {{\text{rad}} {\text{s}}}} \right. \kern-0pt} {\text{s}}}}}]\), and the quantification for unification can be set as \([ - 3,3]\).

In order to verify the performance of the designed controller, the two cases of with and without time-delay are used as the simulating conditions shown in Figs. 2, 3, 4, 5, 6 and 7. In Figs. 2, 3 and 4 are shown the simulation results without time-delay. So, Figs. 5, 6 and 7 are in the condition of time-delay. And all the designed control law is compared to common PID in case of MATLAB simulation, and thus some advantages of the designed controller are more intuitive. From Figs. 2, 3 and 4, without time-delay, backstepping control with fuzzy approximation approach (BCFAA) shows better performances in positioning accuracy and achieves the desired position in relatively faster trend than PID control. In Fig. 2, the ship motion is more accuracy under BCFAA than using PID control, the errors of 3-DOF are lower in control of BCFAA shown in Fig. 3, and real position and heading are maintained at the desired \(\eta_{d}\).

Fig. 2
figure 2

Ship motion without time-delay in condition of SVD

Fig. 3
figure 3

Errors without time-delay in condition of SVD

Fig. 4
figure 4

Forces and moment without time-delay in condition of SVD

Fig. 5
figure 5

Ship motion with time-delay in condition of SVD

Fig. 6
figure 6

Errors with time-delay in condition of SVD

Fig. 7
figure 7

Forces and moment with time-delay in condition of SVD

On the other hand, Figs. 5, 6 and 7 are in the condition of time-delay and there is some larger error in common PID control than in the designed control. From Fig. 5, the position of ships is shown smoother in BCFAA, which has a good performance in controller designed. From the two groups of error results in Fig. 6, the problem of time-delay has a bad influence on DP ships. As for the forces and moment shown in Figs. 7 and 4, the two methods are stable and basically meeting the control requirements. But PID control shows that force and torque will be oscillation, which causes the actuator to be wear and tear. By contrast, BCFAA has a more stable and better control effect.

In order to verify the performance of disturbance rejection of the designed controller, the SVD can be replaced by changing disturbances such as the sinusoidal function (SF):

$${\mathbf{R}}^{\rm T} (\psi ){\mathbf{b}} = \left[ {\begin{array}{*{20}c} {1e6 * \sin \left( {1.5t} \right)} & {1e6 * \cos \left( {1.5t} \right)} & {1e6 * \sin \left( {1.5t} \right)} \\ \end{array} } \right]^{\rm T}$$
(46)

And in this condition, the simulating results without time-delay are shown from Figs. 8, 9 and 10.

Fig. 8
figure 8

Ship motion without time-delay in condition of SF

Fig. 9
figure 9

Errors without time-delay in condition of SF

Fig. 10
figure 10

Forces and moment without time-delay in condition of SF

Without time-delay, the motion curves in 2-DOF directions are achieved to the desired position through some allowable errors under the control of BCFAA, but position curves are in slight overshoot. And for PID control, ship motion drifted off the desired position and produced big errors in \(x,y\) directions with slower response in Fig. 8. In addition, the errors of position and heading shown in Fig. 9 are in allowable errors under the control of adaptive fuzzy control, but the errors are in big errors under PID control. That is to say, the adaptive fuzzy controller is to steer the DP ship in the desired position heading. From Figs. 11, 12 and 13, in the condition of time-delay, the motion curves in 2-DOF directions are achieved to the desired position under BCFAA; however, the motion curve is in slight overshoot and not so smooth as in condition of SVD in Fig. 11 and the motion curves are strayed from the desired position and in slower response compared to BCFAA. The position errors are in big overshoot and take longer time to approach to the stabilization shown in Fig. 12. In other word, the BCFAA is to steer DP ship to desired position but with some errors. As for the forces and moment shown in Figs. 10 and 13, the two methods are stable and forces under BCFAA are more stable and better control effect.

Fig. 11
figure 11

Ship motion with time-delay in condition of SF

Fig. 12
figure 12

Errors with time-delay in condition of SF

Fig. 13
figure 13

Forces and moment with time-delay in condition of SF

5 Summary

In DP control system, the problem of time-delay cannot be ignored and has a bad influence of ship motion. And the disturbances and unmodeled items also have bad effect on ship motion. Due to time-delay, the orders of controller are not immediately responded, and thus disturbances cannot be compensated in time, which will cause the bad control effect, even oscillation. This paper comes up with a BCFAA to handle with problems of time-delay and disturbances under different disturbances such as SVD and SF. And the simulation results show that the proposed method has a good performance, accuracy and fast response compared with common PID control. But this method is not so comprehensive that may not feasible in case of varying delayed time and changing environmental disturbances. And these problems will be further researched in future.