Active Disturbance Rejection with Sliding Mode Control Based Course and Path Following for Underactuated Ships

The compound control of active-disturbance-rejection control (ADRC) with sliding mode is proposed to improve the performance of the closed-loop system and deal with the constraint condition problem of a surface ship. The advantages of ADRC with sliding mode were verified by ship course control simulations. Meanwhile, to solve the path-following problem of underactuated surface ships with uncertainties of internal dynamic and external disturbances, the ADRC controller with sliding mode is introduced to steer the ship to follow the desired path. In order to overcome the cross-track error caused by wind and current, drift angle is compensated in the controller by designing a coordinate transformation equation. Simulations were performed on a nonlinear kinematics model of a training ship to validate the stability and excellent robustness of the proposed path-following controller.


Introduction
Control of underactuated ships is an active field due to its important applications such as passenger and goods transportation, environmental surveying, and offshore oil installations.Based on its practical requirement, motion control of an underactuated surface vessel on the horizontal plane can be divided into ship course, path following, and trajectory tracking.Ship course control is mainly concerned with keeping its heading angle to a desired course angle, which is not an underactuated control problem.However, nowadays, by making use of the position feedback signals obtained from a GPS navigation device, a ship guidance system, namely, a tracking control system, can be designed to make the ship track a desired path.Path following is here defined as a control problem of forcing an underactuated ship to follow a specified path at a desired forward speed [1,2].
Ship control problems are challenging due to the fact that the motion of underactuated surface ships possesses more degrees of freedom to be controlled than the number of the independent controls under some nonintegrable second-order nonholonomic constraints [3].In particular, underactuated ships do not usually have an actuator in the sway axis on the horizontal plane, whose configuration is by far the most common among marine vessels.Therefore, Brockett's condition indicates that any continuous timeinvariant feedback control law does not make a null solution of the underactuated surface ship dynamics asymptotically stable in the sense of Lyapunov.Furthermore, as observed in [3], the underactuated ship system is not transformable into a standard chain system.Consequently, existing control schemes [4] developed for chained systems cannot be applied directly.
Due to the high dependence on the reference model and complicated control laws of the trajectory tracking approach, several researchers have studied the path following problem, which is more suitable for practical implementation.The problem of path following was introduced in [5] where some local results were obtained using linearization techniques.A fourth-order ship model in the Serret-Frenet frame was used in [6] to develop a control strategy to track both a straight line and a circumference under constant ocean current disturbance.A path-following controller was proposed in [7] by using a kinematic model written in polar coordinates, which is inspired by the solution for mobile robots in [8].However, the controller was designed at the kinematic level with an assumption of constant ocean current and its direction known to achieve an adjustable boundedness of the pathfollowing error.Since ocean vessels do not have direct control over velocities, a static mapping implementation might result in an unstable closed-loop system due to nonvanishing environmental disturbances.A path-following controller based on a transformation of the ship kinematics to the Serret-Frenet frame, which was used for mobile robot control [9], on the path was proposed in [10], where an acceleration feedback and linearization of ship dynamics were used.Since underactuated surface ships have fewer numbers of actuators than the to be controlled degrees of freedom and are subject to nonintegrable acceleration constraints, their dynamic models are not transformable into a system without drifts.Therefore, the above control scheme is not directly applicable.
The simplest track-keeping system can be designed from a conventional course-keeping autopilot by using information from a positioning system.The whole system approach may be considered as applying "analytical control strategies" dependent techniques including self-tuning control, LQG control, multivariable optimal control, and  ∞ control.The main drawback of analytical control strategies is their dependence on a reliable model.As a matter of fact, a surface ship is strongly influenced by the model internal dynamic uncertainties as well as external disturbances of wind, waves, and ocean current flow.Furthermore, the surface ship motion usually has large inertia, large time lag, nonlinearity, and constraint condition characteristics which reflects in the ship yaw angular rate with a constraint.
In some literature, several methods have been proposed to deal with the uncertainties of the system and the external perturbations.An adaptive robust controller combining the Nussbaum gain technique with a backstepping approach was developed in [11] to cope with ship straight-line tracking control system with parametric uncertainties and unknown control gain coefficients without a priori knowledge of its sign.In [12], a global controller was presented without velocity measurements for feedback.To deal with nonlinear damping coefficients, an adaptive observer was used to estimate the inaccuracies.In order to avoid the need of explicit knowledge of the detailed ship dynamics, application to the marine field of techniques of neural network, fuzzy logic control, and other artificial intelligence (AI) was also investigated in recent years.However, in most of these works, the uncertainty of external perturbation of the nonnegligible ocean current was seldom explicitly involved.These controllers are able to drive the cross-track error to zero in the absence of a constant direction current disturbance.When a surface ship is proceeding under perturbation of a cross ocean constant direction current or wind, it is necessary to maintain a deliberate deviation angle known as "drift angle and leeway." In [13], based on a technique of feedback linearization and backstepping, a control algorithm for a fourth-order ship model was developed with an estimation of the uncertain constant ocean current with known direction to track both line and circumference.However, the assumption and precondition of a priori knowledge of current's direction are very restrictive from a practical point of view.
Based upon the above observations, this paper aims at developing a ship-tracking controller with improved performance in adaptation and robustness by employing the ADRC technique which has been proved to very effective due to its independence of accurate mathematical model of the plant.Aiming specially at the uncertain system, the ADRC technique was proposed by Han [14,15].Then, the linear ADRC (LADRC) was developed to achieve the parameterization by Gao [16].LADRC is a simplified algorithm comparing to nonlinear ADRC, but it also inherits ADRC's advantages; furthermore, it is easy to apply in engineering.
It is well known that the sliding mode control (SMC) has also attractive features to keep the systems insensitive to uncertainties on the sliding surface; its applications have been extensively studied in [17][18][19][20][21][22][23][24].In this paper, compound control combines the advantages of ADRC and SMC to apply to ship course and path-following control, so that improves the performance of the ship closed-loop systems and makes the parameters of more obvious physical meaning.The cross-track error resulting from constant direction wind and current is removed.
The rest of this paper is organized as follows.The ship model is described in Section 2; three degrees of freedom model for simulation are given.Section 3 proposes the design of ADRC with SMC.Section 4 designs the ship course controller and validates control performance.The ship pathfollowing controller design and simulations are studied in Section 5. Finally, Section 6 contains the main conclusions.

Ship Motion Control Model
2.1.The Ship Kinematics Model.The kinematics and dynamics (MMG) model [25] of an underactuated ship moving in surge, sway, and yaw in the earth-fixed and body-fixed frames (Figure 1) can be described as where , , and  are the longitudinal displacement, lateral displacement, and heading angle, respectively, in the earthfixed frame,   and   are the longitudinal and lateral velocities over ground, respectively,  is the yaw angular rate in the ship-fixed frame,   and V  denote surge and sway velocities through water, and   and   denote the speed and set of current in the earth-fixed frame.The vector summation of both determines the magnitude and direction of current. is rudder angle.,   ,   ,   , and   denote the ship inertia, added mass, and added moment of inertia., , and  terms with subscripts , , , and , respectively, are longitudinal and lateral forces and moments induced by hydrodynamic damping, propeller, rudder, and other external effects except current.

Ship Course and Path-Following Control Problem.
In this paper, in order to design ADRC ship-tracking controller, the following path-following design model derived from ( 1) is used: where (, ) is a multivariable function of both the states and external disturbances as well as time. is the combined external disturbance from wind and current. > 0 is the control gain which is the design parameter.In the system of (2), the last two equations can be defined as ship course control system which is not an underactuated system.In practice, when an underactuated surface ship travels at sea, its rudder angle is the only control input used to follow a desired path and to steer a comparatively steady course.However, cross track cannot be regulated to zero by coordinate transformation for the sake of rudder angle under drift caused by wind and current, and it must be compensated by a loxodrome (or sideslip compensation) since no sway control means are available.Because of this, the equilibrium point of the system is not at the origin of transformed coordinates but at a drifting point since the wind and current are time and regional variant.Moreover, the only measurable state variables are the ship's position and heading in earthfixed coordinates.The path-following problem is rephrased as the stabilization to zero of a suitable scalar path error function based on basic knowledge of the steering feature.The goal of ship path following is to design a robust controller that can force an underactuated surface ship with the abovementioned constraints to follow a desired path.

ADRC Controller Design
3.1.ADRC Structure and Its Algorithm.Consider a generally nonlinear time-varying second dynamic system: where  and  are output and input, respectively, and () is the external disturbance.Here, ( ẏ (), (), ()) represents the nonlinear time-varying dynamics of the plant, that is, unknown. is control gain and unknown, although some knowledge of  can be got; that is,  ≈  0 .Rewrite (3) as where  = ( ẏ (), (), ()) + ( −  0 ) is referred to as the generalized disturbance.Assuming that  is differentiable, let  3 =  and ℎ = ḟ ; (4) can be written in an augmented state space form where  = [ 1  2  3 ]  .An extended state observer (ESO) of (5) will estimate the derivatives of  and  since ( 5) is now a state in extended state model.With  and  as inputs of ESO, the ESO of ( 5) is given as where x = [x 1 x2 x3 ]  is the estimate of the state of (5), and   ,  = 1, 2, 3, are the observer gain parameters to be chosen.The observer gains are chosen such that the characteristic polynomial  3 + 1  2 + 2 + 3 is Hurwitz.For tuning simplicity, all the observer poles are placed at −  .It results in the characteristic polynomial of (6) to be where the observer bandwidth   is the sole turning parameter, and Generally, the larger the observer bandwidth is, the more accurate the estimation will be.However, a large observer bandwidth will increase noise sensitivity.Therefore, a proper observer bandwidth should be selected in a compromise between the tracking performance and the noise tolerance [16].
Once the observer is designed and well tuned, its outputs will track  1 ,  2 , and  3 , respectively.By canceling the effect of  using x3 , the ADRC actively compensates for  in real time.The ADRC control law is given by where V is the reference signal and   and   are the controller gain parameters selected to make  2 +    +   which is Hurwitz.
The closed-loop system becomes Note that with a well-designed ESO, the estimation error in x ,  = 1, 2, 3, is ignored, and let . The plant ( 4) is reduced to which is a classic PD control law.

Feedback Control Law Design with Linear Sliding Mode.
The method of determining   and   was proposed using the bandwidth idea in [16], but its physical meaning is not clear.Furthermore, the tracking is hard to achieve perfect performance.Therefore, linear sliding mode idea is applicable to the design of error feedback control law in this section.
Letting  = 1/ 1 and (0) = 1, we have where () is an exponential decline curve.Meanwhile, the time constant is .We have For (12), Owing to  1 ė () → 0, while  → ∞ and   > 0, obviously, system (15) is a simple proportion negative feedback system; that is, The essence of PD control for a second-order system is similar to the design of only one-step sliding mode in form.The control law of ( 10) is written as where  1 > 0 and  2 > 0 are the design parameters.In addition,  2 >  1 normally.1/ 1 is the system convergence time constant. 1 is tuned based on how fast we want the output to track the set point.A large  1 generally increases the response speed, but it may push the system to its limit, leading to oscillations or even instability.So  1 should be adjusted based on the competing requirements of performance of the actuator.We should consider the limit of the actuator to calculate the value of  1 .For instance, we set the value of  1 according to the desired turn back time and the limit of ship turning rate. 2 determines the response speed of control input directly.A large  2 within a limited range usually increases the rate of change in control signal, but it may lead the system to oscillations or even instability.

Feedback Control Law Design with Nonlinear Sliding
Mode.The important feature of linear sliding is that its projection in each phase plane is a straight line.Linear sliding mode requests the system state has a larger convergence rate when it is at a greater deviation, which can be achieved by higher speed and larger control input.However, in the actual control system, to ensure the control quality of the system when the deviation is large, it often needs to reduce approach speed due to the limited control input, and the cost is to sacrifice the control quality when the deviation is small, where the result is that the system is too slow to be stable.Therefore, linear sliding mode is essentially the same as linear control system, which applies to the small neighborhood of system.To solve the above problem of linear sliding mode (LSM), the form of nonlinear sliding mode (NLSM) in the phase plane as shown in Figure 2 can be taken.The characteristic of nonlinear sliding mode is that the system has fast convergence rate when the deviation is small, and with the increase of deviation, the convergence rate increases as nonlinear until it tends to a constant, so that the nonlinear sliding mode could ensure good control quality in a wide range.
The actual state of system has constraint condition due to the limitation of control input, so we can select the monotone bounded hyperbolic tangent function as the nonlinear sliding mode function.Let The feedback control law of system (10) becomes where   ∈ R + ,  = 0, 1, 2, are the parameters to be tuned.
If  → 0, then ė → − 1 tanh( 0 ), where max(| ė |) →  1 and −1 < ė < 1.That is, the maximum system convergence rate is less than  1 .While  is large enough,  will converge as almost fixed rate  1 .While  is small enough,  will converge as index law.At the same time,  0 and  1 determine the slope of sliding mode in phase plane.

Ship Course Controller Design and Simulation
where   is the tracking target, and the meaning of the other symbols is the same as system (2).Similar to ( 6), the 3rd-order LESO of the plant (20) can be written as where ψ1 and ψ2 are the estimators of  and ψ , respectively, and f is the estimator of (, ) + ( −  0 ), which contains the total uncertainties of internal dynamic and external disturbances.
Similar to (8), the controller is defined as  Similar to (17), linear sliding mode control law is Or similar to (19), nonlinear sliding mode control law is In this section, a simple ship response model is used to simulate.In the system (20), let While the ship speed of Yulong is 7.2 m/s,  1 = 216,  1 = 1, and  3 = 30 [11].External disturbance  is given as white noise of amplitude 0.001.
First of all, two simulations were based on linear sliding mode feedback control law as ( 22) and ( 23).
Case 1.The tracking target   = 1rad; that is,   = 57.3∘ .While a linear sliding mode control law was used, the parameters are chosen as  1 = 0.01 and  2 = 0.1, control gain  0 = 0.0022, and the bandwidth of observer   = 0.4.The results were shown in Figures 3 and 4.
Case 2. Let the parameter of linear sliding mode control law  1 = 0.02; the other parameters of controller, observer, control gain, and ship state are the same as Case 1.The results were shown in Figures 5 and 6.
Based on the simulation results of Figures 3, 4  4/ 1 , whereas, while  1 = 0.02, the time of ship course reaching designated course is about 200 s which also equals 4/ 1 .Meanwhile, the rudder angle being used has increased in order to prompt response.The results of simulations validated the meaning of time constant 1/ 1 .In practical work, deck officers can choose the appropriate parameter of  1 according to the angle of ship course to be changed and the desired time to reach the designated course.
Then, the following two simulations were based on nonlinear sliding mode feedback control law as (22) and (24).
Case 3. The tracking target   = 60 ∘ .While nonlinear sliding mode control law was used, the parameters are chosen as  0 = 10,  1 = 0.004, and  2 = 0.1, and the other parameters of observer, control gain, and ship state are the same as Case 1.The results were shown in Figure 7.
We can find the maximum ship turning rate was restricted within 0.004 rad of the range.Case 4. Let the parameter of nonlinear sliding mode control law  1 = 0.01; the other parameters of controller, observer, control gain, and ship state are the same as Case 3. The results were shown in Figure 8.
We can find that the maximum ship turning rate was restricted within 0.01 rad/s of the range, and the time of reaching the designated course was shortened.

ADRC Based Ship Path-Following
Controller Design and Simulation  where  = arctan(V/) is called the ship leeway angle or drift angle, as Figure 1, which can be measured by GPS in real time on a modern ship. is also the ship heading angle. +  is the ship course over the ground, and it is also called course made good in navigation.
In this paper, a nonlinear function of combining  with  +  by designing a coordinate transformation equation is defined as where  0 > 0 and  >  1 > 0 are design parameters.
In (27),  0 is used to compress coordinate and  1 is used to adjust ship track convergence rate.Meanwhile,  1 can restrict the maximum course angle over ground + to be used when the ship returns to the planned route.Accordingly, the physics meaning of parameters is obvious and parameters would be tuned easily.
Let  * = − 1 tanh( 0 ( −   )) − ;  * is the desired ship heading angle that makes the ship cross-track error converge to zero.Hence, the ship track control problem is transformed into ship course control.Based on the theory of ship course ADRC with sliding mode control, similar to ( 20)-( 23), path following can be achieved by letting ship heading angle track the desired ship heading angle  * which is regarded as reference signal.The controller can automatically seek "drift angle and leeway" and the input control quantity of rudder angle can remove the cross-track error in real time resulting from wind and current.

Straight-Line Path Following.
To demonstrate the practicality of the design, simulations were performed using the ship Yulong based on the kinetic model as (1), and the control law was selected as the form of ADRC with linear sliding mode.
The initial states were chosen to be as follows: the main engine was set to be 103.4revolutions per minute (RPM),  = 0,  = 500,  = 0, and   = 7.2 m/s.Planned route is a straight line to the north of   = 0. External disturbances are as the following: constant wind direction of NE with speed 5 m/s and constant current set of SW with velocity of 1 m/s.
The parameters of ADRC below simulations in this paper were chosen as   = 0.4 and  0 = 0.0022; the parameters of linear sliding mode control law were chosen as  1 = 0.02 and  2 = 0.1, where  1 = 0.02 means that the time constant of ship heading angle reaching maximum is 50 seconds; the parameters of the transformation (27) were chosen as, respectively,  0 = 0.03 and  1 = /12, where  1 = /12 indicates that max( + ) = /12 will be used before ship is stable.
In Figure 9, when the system is stable, heading angle is not zero because the ship was affected by wind and ocean current.

Curve Path Following.
In the earth-fixed frame, ship initial heading angle and position ( 0 ,  0 ,  0 ) are (20 ∘ , 0, 0), and planned route is a curve of   = 300 sin(0.0005).The others of ship initial state and external disturbances are the same as the above simulation.The parameters of controller are chosen as  1 = 0.03,  2 = 0.1,  1 = /6, and  0 = 0.03.The simulation results are shown in Figure 10.
Remark 2.  1 and  1 here are larger than the ones of straightline path following because faster turning rate and larger heading angle are needed while curve path following.
By analyzing the results of Figures 9 and 10, we can summarize some conclusions as follows.
Firstly, the cross-track error resulting from constant wind and current has been overcome.The tracking control precision is high.Rudder and course response are smooth, and the rudder-turning angle is not large in spite of external disturbances, such as wind and current.
Secondly, the results indicate that the ADRC controller has powerful robustness to the environment and the nonlinearity of ship tracking motion control with constraint condition.And the ship tracking control is fast and smooth with lower energy consumption.

Conclusion
This paper has presented a novel path-following control approach to underactuated vessels under environmental disturbances of ocean current and wind.A compound control approach of ADRC with sliding mode has been applied to the design of ship course and path-following control utilizing the characteristic of ADRC independence of the controlled plant's mathematical model.The parameters of controller have more obvious physical meaning; meanwhile, the constraint condition problem of a ship has been solved.The leeway angle was compensated in the controller by means of designing a coordinate transformation equation.The ADRC controller has guaranteed that the cross-track error converges to the planned path, and the parameters of controller can be easily tuned according to the ship's maneuverability.The high precision ship tracking controller is robust to the internal dynamic uncertainties of a ship and the external disturbances.

Figure 1 :
Figure 1: Ship's planimetric position and kinematics with current disturbance.

Figure 2 :
Figure 2: Comparison of linear with nonlinear sliding modes.

Figure 9 :
Figure 9: Straight-line path and input-output based on trace tracking method.

Figure 10 :
Figure 10: Curve path and input-output based on ship trace tracking method.