Design and Stability Analysis of Fuzzy Switched PID Controller for Ship Track-Keeping *

The fuzzy switched PID controller which combines fuzzy PD and conventional PI controller is proposed for ship track-keeping autopilot In this paper. By using rudder angle, the whole voyage is divided into two operating regimes which named transient operating regime and steady operating regime respectively. The fuzzy PD controller is employed in transient operating regime for increasing response, reducing overshoot and shorting transition time. And conventional PI controller is used to improve the stable accuracy in steady operating regime. The global controller is achieved by fuzzy blending of all local controllers. Routh stability criterion is utilized to obtain the stability condition of closed-loop system. The simulation results show the effectiveness of proposed method.


Introduction
Ship autopilot mainly used to keep the course at designed trajectory within minimum deviation.In terms of characteristics of nonlinear and underactuated of cargo ship, finding an effective autopilot control algorithm has been the significant topic in area of ship steering control.This has evoked interest into the field of autopilot in marine cargo ship controlling community recently.Fossen, et al. proposed adaptive controller to improve performance and reduce fuel consumption on both of course-keeping and course-changing maneuvers [1].In [2], the problem is solved by the adaptive robust fuzzy method, which called state input-output theory is adopted.The work in [3] has proposed adjust ship course by using track error-driven control algorithm.
Ship voyage involves several straight-line segmentations.During straight-line voyage, the control requirement mainly focuses on stable accuracy, which are called tack-keeping.Rudder angle changes frequently and the controller output is small.Most of time, autopilot operating in the mode of track-keeping process, so we called is as steady operating regime in this paper.Whereas, when the ship changing into a new direction from original course, the control requirements mainly depends on response, overshoot and transition time, what are named course-changing process, the controller provides a larger control signal to achieve faster response.There are dozens of course-changing points in whole voyage, what depends on the ocean environment and port of destination as well.When course error decreasing, the controller outputs would gradually reduce according to control laws.The course-changing process is generally short-term and countable, so it can be called transient operating regime.
The good control strategy could adaptively switch to the most matching control law based on operating regime according to switching rules.The fuzzy switching PID control algorithm combines Takagi-Sugeno PD controller with general PI controller to improve the control performance in terms of fast response and high stable accuracy throughout the voyage.During track-keeping process, the so called TS-PD controller is employed to keep the stability accuracy, and when course-changing process, the general PD controller is used to improve the response speed.The TS-PD controller and general PI controller switched according to the operating regime switching rules.
Fuzzy logic has been proved to be an universal approximator for any real continuous function.It can be constructed in many different configurations.However, since Takagi-Sugeno fuzzy inference is nonlinear in nature, we utilize it to construct the supervisory rules.The global controller output is used to be antecedent variable of supervisory rules.The stability of fuzzy control systems may not be easily analyzed.Lyapunov approach and variable structure or the phase-plane approach normally be employed.Besides, it is difficult to find a common Lyapunov's function for a fuzzy controller.In this paper, the Routh stability criterion is used to achieve stability condition for closed loop system.The fuzzy switched inference guarantees the smooth characteristic between adjacent controllers.

Problem Describe
Between departure port and destination port, the sailing route is planned considering the factors of ocean environment, navigational safety and economy.It usually combined with several straight lines as shown in Figure 1.From departure port A to destination port D, the designed route is A→B→C→D, where B and C are coursechanging points.The setting of controller is constant during the straight A→B, B→C, C→D, the function is used to keep trajectory at predetermined routs under external disturbance.When sailing to B and C point, the course would changes to a new course from initial, controller used to drive the ship into new course within smaller deviation and shorter response time.

Fuzzy Operating Regime
The concept of operating regime is firstly proposed by Johansen [4].Any models and controllers have its specific period and space range.Only within this ranges, the model and controller have sufficient accuracy and efficiency to accomplish designed purpose.The operating regime can be defined by multiple factors, such as model hypothesis, linearization validity, stability condition and experiment restriction, etc.
Local controller is determined by both the steady operating regime and transient operating regime.How to find a variable can be used to divide the discourse domain into several local operating regimes is the key issue.The experience shows that the rudder angle is usually small during straight voyage.On the contrary, when the course changed, rudder angle would change by a large scale.So in this paper, the output of controller, i.e. the rudder angle order δ, is employed to divide the operating regime.
Fuzzy operating regime would guarantee the smooth switching of multiple controllers [5]. Figure 2 shows the fuzzy partition of operating regime in this paper, the membership functions are assumed to be trapezoid.Where fuzzy set ZE is fuzzy set used to describe transient operating regime, and NE and PE are fuzzy set used to describe steady operating regime related to positive and negative course error, respectively.Generally, starboard tuning of ship is defined as positive direction.The OM is the axis of symmetry of fuzzy set ZE, NE and PE.The cross-shadow area is overlap region of adjacent fuzzy operating regime.λ and μ are shape parameter of fuzzy sets.Assuming = 2     , λ and μ can be calculated indirectly according to given ε.
For any rudder angle  , the degree of membership may be represented as,

System Structure
The structure of closed-loop control system with rudder angle feedback and vessel position feedback is shown as Figure 3. PID control methods are widely used in ship autopilot.There are three performance indexes for closed-loop system, overshoot, transient time, and steady accuracy, these indexes are mutual constrained.
The controller output is related to the error changing because of fuzzy PD algorithm during running in transient operating regime.Otherwise, when running under steady operating regime, the controller would switch to PI controller to reduce the static deviation of trackkeeping.The supervisory rules employ Takagi-Sugeno -    The Fuzzy inference rules of global controller as follo where, I = 1, 2, 3, j = 1, 2, 3, deno and e  respective ler T u is,

Transient Operating Regime
ws.

If δ is NE or PE then
If e is A and e  is B then 1 1 w ij is ijth fuzzy inferenc rule starting stren ing "max-min" de-fuzzed m thod, e gth, by use Obviously, TS-PD controller has variable gain characteristics [6].
where, is output of steady operating regime, By using "max-min" de-fuzzed method, there is, By combining ( 4) and ( 5), where, are nonlinear proportional gain, integral gain and differential gain of global controller's output respectively.The transfer function of equation (11 as, ) can be rewritten

Plant Models
By considering only the closed loop sys error to ship heading, the Figure 3 can be simplified as model relating the rudder angle of tem from course

Figure 4.
The mathematical the ship to the heading was proposed by Norbin [7]       and τ are model parameters.Assuming zero initial conditions, (16) can be written as t  where φ is ship heading of ship, δ is rudder angle, k The parameter K, τ 1 , τ 2 , τ 3 is the function of ship speed u and length l The parame hip's forward ve odel can be written as ters u and l are function of s locity and its length.Steer gear m k E is steering gear gain coefficient, τ E is steer gea stant time coefficient.The transfer function of plant incl r conuding steering gear can be written as where, , is generalized controller amplification coefficient.For majority of cargo ships the rudder angle and the rudder rate are confined to be in the ranges It is u uired that rudder should move from 35 ˚ port to 35 ˚ starboard within 30 s. sually req

Stability Conditions
By considering the closed-loop control system constructed by controller (15) and generalized characteristic equation can be written as plant (20), its According Routh stability criterio conditions can be written as f n, system stability ollows, where we assume that for a cargo ship, K 0 = −3.86,τ 10 = 5.66, τ 20 = 0.38, τ 30 = 0.89, l = 161 m.Also, we assume that the ship is traveling in the x direction at a velocity of 10 knots (about 7.8 m/s).In Equation ( 23

Simulation Results
In

Conclusion
This paper proposes a performance-oriented control algorithm that will improve the efficiency and accuracy of whole voyage track-keeping.There are hardly any existing control laws that could meet the above needs.The advantages of fuzzy PD controller and conventional PI controller are combined to overcome the shortages of traditional PID controller.The proposed control strategy is easy to be performed.The simulation results on cargo ship prove this control strategy can achieve the desired consequent.

Figure 3 .
Figure 3. Structure of control system.uzzy inference, and antecedent variables employ output

i j e 3 . 2 . 2 . 2 .
Steady Operating Regime here, A , B j is f zzy sets of e le i ship function is used to describe NE and PE operating regime as in Figure sets of e ly.The output of steady local control-

Figure 2 ,
λ = 3, μ = 5.Assuming heading be changed by 30˚ to right direction, the curve of track-keeping, course error and rudder angle changing have been shown in Figures5 and 6respectively, they illuminate that the proposed fuzzy switched PID controller has fast ight overshoot and high accuracy in whole voyage.