Path following for underactuated surface vessels with disturbance compensating predictive control

It is common that underactuated surface vessels sailing on the sea suffer from strong external sea disturbances, such that the large roll motion can be probably caused resulting to the bad performance of path following. In order to realize the coordinate control of the rudder roll stabilization and path following, a robust controller with roll constraints is designed by combining predictive control with disturbance observer. Firstly, the rudder angle operating range is divided in the Serret–Frenet coordination frame, and then linear models corresponding to different equilibrium can be established with heading control and roll dynamics. Secondly, considering external disturbance and unmodeled error as the lumped disturbances, the disturbance observer can be utilized to achieve the real-time feedforward compensation leading to the improved system robustness. Thirdly, the output redefinition method is adopted to transfer the original system into a new minimum phase system. Based on the receding horizon and state prediction strategies of the predictive control, the analytical control law can be obtained, and the linear programming method is used to guarantee the roll constraint for the simplified computational burden. Lastly, the simulations have been carried out to show the good performance of the proposed algorithm with the heading control and roll reduction.


Introduction
Referring to the marine problems, path following has been a mainstream direction due to military and civilian necessities in recent years. Numerous control methods have been designed to tackle with kinds of vessels and detailed practical difficulties, such as feedback control, neural network control, and adaptive control technique. [1][2][3][4][5] The sailing vessels are mostly underactuated, as the rudder is usually used as the control input to manipulate the heading, yaw velocity, and lateral displacement, and the surge velocity is maintained by the propeller. For this kind of manipulation strategy, there exist several issues which ought to be considered: the underactuated characteristic and the external disturbances in the sea. 6 It is worth mentioning that it is not unique for practical application, as in real robotics applications, the publications 7,8 related to nonholonomic systems can reveal the same issue. When the vessel sails on the sea, it is inevitable to take the external disturbance into account. Among all vessel states of surge, sway, heave, yaw, pitch, and roll, the roll motion caused by stochastic wave disturbance is the most significant. The severe roll motion can cause the seasickness, reduce the performance of the shipping equipment and crew members, and even lead to the shipwreck. 9 The disturbances cannot be omitted in the control design, and cited publications above have taken into account the disturbance in the design process. In addition to disturbances, the tracking problem in the presence of sensor noise showed a more general condition for practical application. 10 As is well known, the rudder plays the role in the heading control. However, the roll moment generated by the rudder operation can be offset by the disturbance moment caused by the wave disturbance. Further, the respond period of roll motion is much longer than that of the yaw motion, and it makes the rudder roll stabilization feasible in the physical and control aspects. Compared with some other roll damping methods, without the equipped appendages, it has the advantages of low cost, small occupation space, and good roll reduction performance. 11 As mentioned, owing to the chief role of the rudder in the heading control, the two goals of heading control and roll reduction cannot be considered separately, which implies that strong coupling exists. On account of the facts that the simple pursuit of roll reduction can deteriorate the path following performance and much more consideration about following the path can lead to excessive roll motion, it is urge to make the appropriate trade-off between these two tasks. In the study by Zhou and Wang, 12 based on the different rudder frequency responses of roll and yaw, the H1 control method was utilized for the realization of path following and rudder roll stabilization separately, and then the weighting functions can be chosen with the weighting function method. The path following can be accurately achieved with the external disturbance reduction, but the good trade-off performance had not been realized due to the transfer function-based separated control design method for path following and rudder roll stabilization. Using T-S fuzzy model, the nonlinear system of the yaw and roll motions can be obtained, and with the principle of parallel distribution compensation, a fuzzy control method was designed to improve the performance of roll reduction, but the path following performance had not been taken into account although it had already been affected by the roll reduction operation. 13 The advantages of fuzzy logic system in dealing with uncertainties have made it popular. The direct fuzzy control in Yu et al. 14 was proposed to compensate for effects caused by actuator saturation, but a new fuzzy sliding mode control method had achieved the same objective in Chu et al. 15 Actually, not only sliding mode control but also backstepping method can be integrated. Based on this idea, 16 the 3-D path following was realized. Furthermore, on the premise that the presented publications have pushed forward the theoretical research, many scholars and engineers in the shipping industry and related robotics area have put their best efforts to achieve big progress in practical implementation. 17,18 Based on pure sliding model control and its combination with smooth control method, the effectiveness and applicability of this algorithm has been demonstrated in numerical simulation and practical experiment. 19 So far, these publications have concerned the tracking problem of single object, but with the rapid economic development, the control problem of multiple surface vessels have emerged. Many welldeveloped method and theories cannot be applied directly due to the peculiar researching difficulty, and then some bionics-based methods have grown and spread out rapidly. Based on swarm control, the collision avoidance and distribution for multiple vessels had been achieved. 20,21 For the process control with slow dynamics, model predictive control (MPC) is one of the effective methods to tackle the multi-objective optimal control with multivariable couplings and constraints, due to its receding horizon strategy and explicit consideration for constraints in the open loop optimization. Recently, besides the wide application in the industrial control, MPC has been appeared in the motion control with reduced computational burden and improved hardware condition. 22,23 Based on the nonlinear model with roll dynamics, roll angle was considered as the state constraint, such that the safety range of the roll angle can be ensured with online constrained optimization of MPC property. The heading control and roll reduction had been achieved, but the time varying disturbances had not been discussed. 24 To deal with constraints and disturbances, the nonlinear disturbance observer was adopted with the nominal model, such that the system stability and robustness can be guaranteed. 25 In Zhang et al., 26 a path following method was proposed with the combination of Kalman filter, disturbance observer, and robust constrained MPC. With partial measured states, the full states were estimated, and the control system robustness had been significantly improved due to the disturbance compensation in the control design. However, the computational burden was much large due to the online optimization for feedforward compensation and control with the application of linear matrix inequalities.
Inspired by Zhang et al., 26 a robust path following control method is proposed in order to realize the coordinate control of path following and rudder roll stabilization. The main objectives of this study include: 1. With the disturbance compensating strategy, a robust MPC control is proposed for the nonlinear models of surface vessels with roll constraint in order to achieve the path following and rudder roll stabilization simultaneously.
2. Considering the non-minimum phase dynamics of the control system, 5 the output redefinition method is adopted to transfer the original system into a new minimum phase system. 3. For the computation reduction, analytical control law and linear programming method have been utilized.
This article is organized as follows. The objective of this article is briefly presented in the second section. In the third section, the disturbance compensating strategy is given, followed by a novel robust predictive control method in the fourth section. Several simulations have been carried out in the fifth section, and conclusions are in last section.

Problem statement
For path following control of underactuated surface vessels (USVs), two different methods have been addressed: (1) control design with error dynamics in the inertial coordination frame; (2) the adoption of the Serret-Frenet frame. The latter one is often utilized for the simplification of the control design. In Figure 1, the frame fSFg used for path following control is shown. O is the given desired path, e is the distance between the origins of fSFg and the bodyfixed frame fBg, SF is the desired tangential direction of the given path, and is the heading angle.
The error dynamics of path following in the Serret-Frenet frame are given by where ¼ À SF is defined as the heading error. u, v, and r are the surge, sway, and yaw, respectively. k is the curvature of the given path. For most path following issues in open water, the desired path is a straight line or a waypoint path consisted of piecewise straight lines with k ¼ 0.
Assumed that the sway velocity is small enough to be neglected, which means v % 0. Then, the error dynamics (1) can be simplified as For the error dynamics, it is well understood that the control objective of path following is to drive path error e and heading angle error to be zero. From the above analyses, the USV performance and stability can be severely affected by large roll motion, so the roll dynamics must be established to ensure the roll angle in the safety range. The coupled nonlinear dynamics with four degrees of freedom of surge u, sway v, roll p, and yaw r are given by 22 where m is the vessel mass, I xx and I zz are the inertial moment about x-and z-axes, and I xz is the coupled inertial moment of x-and z-axes. x G and z G are the locations of the gravity center in the x-axis and z-axis. p is the roll angular velocity, and is the roll angle. The hydrodynamic forces X ; Y and moments K; N are usually third-order Taylor serial polynomials of nonlinear hydrodynamic constants, and specific definitions can be referred in Fossen. 27 t x , t y , t k , and t n are denoted as different hydrodynamic effects due to the control input. Since the dynamic model (3) is a nonlinear system with uncertainties and strong couplings, it is difficult to be directly used in the control design. Due to the limited operating range of the control input produced by the rudder, it is assumed that there are three operating equilibrium points corresponding to different operation modes in the whole operating envelope for the USV. 27 With the linearization of the original nonlinear model, the linear models with disturbances at different operating modes can be represented as ; where x ¼ ½ ; v; r; p; T is defined as the system state, and A i ; B i are the system state and input matrix of the ith subsystem. d is the lumped disturbances of the external wave disturbance and unmodeled error caused by piecewise linearization. d is the rudder angle served as the control input, and X ¼ fx jjx 5 j max g is the roll angle constraint. O i is the operation area of the ith subsystem corresponding to the different operation range with i 2 N ¼ f1; 2; 3g, and the ith model and related parameters should be utilized if x 2 O i . The adjacent area between the ith and jth subsystems is denoted as O ij , which is represented as Based on the polyhedral modeling method, referring to the rudder angle range, the three subsets can be described by the polyhedrons as follows where these three subsets are referred to two different path following conditions about the heading changing and heading keeping, respectively.
When the USV sails on the sea, the external sea waves can excite the large roll motion which can deteriorate the performance and stability. In order to verify the better disturbance compensation efficiency, it is obviously necessary to simulate the wave-induced motion accurately. The response amplitude operator-based method, namely response amplitude operator (RAO) can be utilized to realize the motion simulation. Conventionally, the vessel motion caused by hydrodynamic forces and moments can be simulated in the inertial coordination frame. Different from this method, the steady forward motion can also be simulated in the inertial seakeeping coordination frame, which coincides with the other common coordination frame, body-fixed coordination frame at the average time. 28 Obviously, the two simulated motion results obtained from two different frames cannot directly be used to carry out some simple mathematical manipulations. As the roll motions obtained from the two frames are in the same direction, the roll motion can then be used to achieve the roll simulation in the system model, such that the performance and stability of the proposed method in this article can be demonstrated.
In the wave theories, the wave is considered to be consisted of the long-crested waves to facilitate the study, such that the wave amplitude can be assumed to be the sum of some harmonic waves. The assumption can be described as where zðtÞ is the wave amplitude. z i and w i are the amplitude and angular frequency of the ith harmonic wave, respectively. e i represents the random phase of the ith harmonic wave, and it is randomly distributed at the range ½0; 2p.
The wave energy spectrum is the key for the wave issues, the wave spectrum recommended by International Towering Tank Conference is used in this article, and it is formulated as where S is the power density, g is the gravity, and w is the angular frequency of the wave. H 1=3 is denoted as the significant wave height, and it is the parameter used to represent the sea conditions. With the adopted wave spectrum, the amplitude of the harmonic wave can be described as where Dw is the fixed range of the angular frequencies in the wave spectrum. Substituting (10) into (8), the wave amplitude can then be obtained. As RAO is the linear transfer function from wave to vessel motion, there exists the linear property, such that with the wave slope related RAO, the vessel motion can be formulated as where h j is the amplitude of the jth motion.
=g is the wave number, and l is the wave length. jG i;j j and ffG i;j are the amplitude and phase of jth RAO motion.
After the wave analysis, considering the advantages of robust MPC in tacking with constrained multivariable optimization problems, it is adopted to achieve the coordinate control of path following and rudder roll stabilization. Then, the analyzed problem in this article can be described as: For the path following model (2) with ship dynamics (4), taking the wave disturbances on the sea into account, an integrated controller dðkÞ ¼ d mpc ðkÞ þ d dc ðkÞ is designed, such that the desired heading angle can be followed with the constrained roll angle and restrained disturbances in order to improve the system stability and robustness. For the designed controller, d mpc ðkÞ and d dc ðkÞ are referring to control inputs produced by nominal MPC and disturbance compensation, respectively.

Disturbance compensating design
As the time-varying disturbances and unmodeled errors exist, the control input d mpc ðkÞ obtained based on the nominal system model prediction cannot eliminate the steadystate error in path following, such that it can lead to the poor system robustness. Referring to the separation principle, the disturbance estimation can be independent to the control design, and then the disturbance estimation is firstly implemented.
In order to deal with the existed disturbance in the control system, the disturbance observer is derived and developed. 15 With the designed disturbance observer, the real-time disturbance in the system can be estimated with input and output states of the control system, and then the feedforward compensation can be carried out to eliminate the effects caused by unknown disturbances, unmodeled dynamics, and other factors. Besides, the disturbance observer still has the advantages of simple structure and low computational complexity, such that the disturbance compensation mechanism has been widely used in many areas. Referring to Yang et al., 29 the linear disturbance observer is designed as follows where z is the auxiliary state, L ¼ diagfl 1 ; l 2 ; l 3 ; l 4 ; l 5 g is the gain matrix of the linear observer, andd is the estimation of the lumped disturbance d. The structure diagram of the disturbance observer is shown in Figure 2. The estimation error of the lumped disturbance is defined as For the accurate estimation of the lumped disturbance, the disturbance estimationd tends to equal to the lumped disturbance d. Equivalently, the estimation error defined as (9) tends to be zero. The derivative of the estimation error is given by According to the ship kinematics, the motion state of the USV is the composition of the low-frequency and highfrequency motions. Among the two kinds of motions, the high-frequency motion can only result to the slight motion with the average position unchanged, such that the highfrequency motion can be neglected, and only the lowfrequency motion is considered. Then, it is naturally assumed that the lumped disturbance remains unchanged during the sampling periods with d : % 0. If the observer gain L is properly chosen to make ÀLB d the Hurwitz matrix, the estimation error can then tend to be zero.
In order to implement the disturbance compensation mechanism, the stability analysis of the designed disturbance observer is necessary. The Lyapunov function of the linear disturbance observer is chosen as Using the estimation error derivative (14), the derivative of the selected Lyapunov function can be obtained as If there exists LB d > 0, then _ V ¼ Àe T d LB d e d < 0 can be guaranteed resulting to the convergence of the designed disturbance observer. The detailed theoretical analyses can be referred in Li and Sun. 23 As the nominal MPC is a discrete model-based optimization method, a discrete form of the disturbance observer (12) is needed in order to maintain the consistency. Using the first-order Euler discretization method, the discrete disturbance observer can be formulated as T is denoted as the sampling time, and I represents the identity matrix with the appropriate dimension 5 here.
As the control matrix B d is not the square matrix due to the underactuated characteristics of the linearized model (4), the feedforward compensation is only considered for the yaw moment, and the time-varying compensation is designed as

Constrained MPC control design
With the wave disturbance on the sea, the disturbance observer has been designed to estimate the lumped disturbance. Further, in order to realize the coordinate control of heading control and roll rudder stabilization, the constrained MPC method combined with the disturbance observer is proposed to ensure the system stability and performance with the safety range of roll angle. As is known, MPC is an effective method to deal with the multivariable problem with the state and input constraints.
To facilitate the control design, the discrete form of the nominal system model can be formulated as time k. A i and B i are discrete system states matrix and control input matrix respectively corresponding to the operation range. With the first order Euler discretization, it can be obtained that With the discrete nominal model (18), the optimization in this article can be described as minJ s:t: where x 2 X ¼ fx jjj max g refers to the state constraint of roll angle, and d 2 U ¼ fdjjdj d imax g is the control input constraint of rudder angle. The objective function J with the quadratic form can be defined as 30 where y d ¼ C x d is the desired system output, and x d is the desired system state with the coordination of roll angle and path following error. N p and N C are the prediction and control horizons respectively, generally subject to N C N P . The positive semi-definite matrix Q and positive definite R are the gain matrices of system state and control input with Q ! 0 and R ! 0. With the designed disturbance observer and nominal model optimization description, the coordinate control design of rudder roll stabilization and path following can then be realized in the following processes.

System analysis of minimum phase characteristics
The non-minimum characteristic of the control system in this article is caused by the coordination control of heading control and roll reduction only with rudder served as the control input. Different from the general control system, the control system with the non-minimum phase has the unstable internal dynamics resulting to the increased difficulty for the control design. In order to tackle with such control systems, the output redefinition method can be adopted to ensure the stability of the internal system dynamics by choosing a new output and approaching the original system.
The output matrix C in the objective function (20) has the significant influence on the system stability. If all system states information is available, equivalently C ¼ ½ 1 1 1 1 1 , the root locus of the system transfer function is shown in Figure 3. From Figure 3, it can be seen that in the right half plane, there exists the zero-pole meaning that the control system is of non-minimum phase. With the original output matrix, the designed predictive control law can make the system root enter the right half plane resulting to the divergence and instability of the control system.
Due to the limited capacity for the non-minimum phase system using the predictive control method, the output matrix is redefined as C ¼ ½ 1 0 1 0 0 meaning the integration of the measured system states and r. The system root locus is shown in Figure 4. The system root is in the left half plane and the system is stable, such that the designed predictive control can ensure the system stability.

Nominal predictive control law design
Based on the nominal state space model (18), the system state prediction at the prediction horizon N p can be obtained as In order to facilitate the description, some sets are denoted as

Root Locus
Real Axis (seconds -1 ) Imaginary Axis (seconds -1 ) Figure 3. Root locus of non-minimum phase system.  Figure 4. Root locus of minimum phase system. G ¼ With the simplified denotations, the cost function and the state prediction can then be rewritten as For the unconstrained optimization problem, the necessary condition @J @U ¼ 0 for the minimization of the objective function can be utilized to obtain With the receding horizon optimization strategy, the current control (the first row of the optimal control sequence) can be applied to act on the system, and it can be obtained as d mpc ðkÞ ¼ ½I 0 0 ::: where

Constraints handling
Aiming at the reduced complexity and calculation burden caused by the constraints optimization using sequential quadratic programming, the linear programming method is adopted here introducing a new variable a, and the constraints handling problem can be formulated as min d mpc ðkÞ jaj s:t: where dðkÞ ¼ d mpc ðkÞ þ d dc ðkÞ is denoted as the integrated control with the nominal predictive control and the disturbance compensation. d dc ðkÞ ¼ d d ðkÞT , and T is the sampling period. From the optimization algorithm (25), it can be seen that the model choice is determined by the current control. In order to avoid the system vibration caused but the frequent model switching, a soft model switching approach is utilized, and the historical errors are taken into account. Then, at time k, it can be formulated as e yi ðkÞ ¼ yðkÞ where e yi ðkÞ is the residual between the system output measured from the actual vessel and output prediction with the ith model at kth instant. The performance objective can be formulated to indicate the matching degree of the USV model and utilized predictive model at the instant time, which is defined as q h e y ðk À hÞ ð 27Þ where h is historical window length, and q h is the weighting factor. The smaller J y equals to the bigger matching degree, such that the predictive model corresponding to the smallest J y ðkÞ is chosen to be implemented at the current time control. At the next time k þ 1, the predictive model is rechosen referring to the recalculation of J y ðk þ 1Þ.

Simulations
The parameters in the switching models of the USV can be referred in the literature, 24 and then the matrices of system state and input in (4) can be selected as and B 2 ¼ ½ 0 À0:04575 0:002279 0:003277 0 T . Assumed that the initial system state is x ¼ ð25 ; 0; 0; 0; 0 Þ. The surge speed is constant at u ¼ 7 m/s, and the encounter angle is 90 . The range constraints of roll and rudder angle are defined as X ¼ fx jjj 15 g and U ¼ fdjjdj 35 g, respectively. The sampling period is 0.08 s. Due to the adopted single step prediction, the weighting matrices of the cost function are selected as Q ¼ 400 and R ¼ 0:8, respectively. In order to evaluate the robustness and feasibility, the original nonlinear model is utilized in this section. Furthermore, due to the similar optimization strategy designed for rudder roll stabilization, the adaptive LQG-based control method 5 has been utilized for the comparison of the control performance in different conditions. The simulation results are as follows: 1. If the system measurement matrix is chosen as C ¼ ½ 1 1 1 1 1, it can be obtained from the analyses in the "System analysis of minimum phase characteristics" subsection that the nonminimum phase characteristic of the control system can lead to the system divergence. It can be seen from Figure 5 that the heading angle errors are seriously divergent with different rates using both control methods, and this navigation condition can severely deteriorate the control system performance, even cause the safety accidents on the seaway. 2. In order to facilitate the study, the original system can be transformed into an equivalent one with the non-minimum phase characteristic by the output matrix redefinition C ¼ ½ 1 0 1 0 0. Without the external disturbance, the simulation results for the performance comparison are shown in Figures 6 to 8. It can be seen that the heading angle error is convergent with the satisfactory ranges of roll angle and rudder angle. Using the predictive control proposed in this article, the heading error can convergent to the stable state faster, and overshoot of roll and rudder angles can become smaller resulting to the better control performance and longer service life of rudder. With the comparison between Figure 5 and Figure 6, the effectiveness of the output redefinition method can be illustrated.   3. With the significant wave height H 1=3 ¼ 0:8 m, the simulated wave amplitude has been shown in Figure 9 based on the wave spectrum theory, and comparison of heading angle error with or without the disturbance compensation mechanism is depicted in Figure 10. From Figure 10, the simulation results without and with the disturbance compensation are represented with the blue line and red line, respectively. From the blue line without the disturbance compensation, it can be seen that the existence of the wave disturbance can generate the significant error of the heading angle illustrating the disability of nominal predictive control in tackling with the time-varying disturbance. Compared with the red line, with the implementation of the disturbance observer, the steady error of heading angle tracking     has been significantly reduced. It can be seen clearly from Figures 11 and 12 that the oscillations in the curves of roll and rudder angles have been decreased remarkably decreased revealing the necessity validation for the combination of disturbance compensation in present of external wave disturbances.

Conclusion
Aiming at the coordination problem of path following and rudder roll stabilization, the integrated constrained MPC control is proposed combined with the disturbance compensation. According to rudder range limitation, the linear model is established, and the disturbance observer is adopted to estimate and compensate the lumped disturbance such that the capacity of nominal MPC can be enhanced to tackle timevarying disturbance. The non-minimum phase characteristic is analyzed, and a new minimum phase system approaching the original system is produced using the output redefinition method. For the sake of reduced calculation burden, the linear programming is utilized to tackle with the constrained optimization instead of quadratic programming. The simulations have been carried out to demonstrate the error convergence of the heading angle and path following with the constraints.
Although the proposed method offers an available realization of the coordination of the rudder roll stabilization and path following, the practical application still remains to be a big problem due to the complex sea conditions, and in the further works, the performance and stability of the proposed method will be tested in the experimental research.

Declaration of conflicting interests
The author(s) declared no potential conflicts of interest with respect to the research, authorship, and/or publication of this article.

Funding
The author(s) disclosed receipt of the following financial support for the research, authorship, and/or publication of this article: This work is supported by National Natural Science Foundation (NNSF) of China under Grant 51379044 and U1530119, Priority Academic Program Development of Jiangsu Higher Education Institutions.