International Journal
on Marine Navigation
and Safety of Sea Transportation
Volume 4
Number 1
March 2010
25
1 INTRODUCTION
Fuzzy set theory has been used successfully in virtu-
ally all the technical fields including control, im-
age/signal processing and expert systems. One of the
most successful applications however seems to be in
the control field where the theory can utilize the hu-
man control operator’s knowledge and experience to
intuitively construct models so that they can emulate
human control behaviour to a certain extent (Ying
2000, Zadeh 1996).
Simulation studies give perfect opportunity to
record the expert knowledge of pilots commanding
vessels in the relevant area. An essential problem of
the acquisition and representation of navigator’s
knowledge referring the conduct rules (procedural
knowledge) and the analysis and evaluation of navi-
gational situation (declarative knowledge) can be
solved by gaining knowledge directly from electron-
ic records made during such research and creation of
the expert knowledge database can finally lead to fi-
nally to the concept of autonomous ship control dur-
ing FTS in confined waters. Fast time simulation can
be achieved easily by applying shorter period of
state change than established in the ship’s hydrody-
namic model, for instance dt = 0.01s, which is not a
problem for contemporary computers (Gucma et al.
2008), but ship’s fuzzy control in confined waters
requires further analysis.
2 FUZZY LOGIC CONTROLLER
In autonomous FTS the manoeuvring decision find-
ing can follow the procedure described in Zalewski
(2003). However if any of the present ship state vec-
tor parameters comes outside the scope of the expert
database it is assumed that the optimum manoeuvre
should lead the ship to regain safe values of state
vector parameters. For this purpose the fuzzy dis-
crete-time controller can be designed. The major
components of the typical fuzzy controller are fuzzi-
fication, fuzzy rule base, fuzzy inference, and de-
fuzzification. These components will be described
further in an exemplary MISO (multiple input single
output) controller of pitch for vessels with two pro-
pellers.
Figure 1. Structure of a MISO fuzzy control system which is composed of a Mamdani fuzzy logic controller and a system under
control (based on Ying (2000)).
Fuzzy Fast Time Simulation Model of Ship's
Manoeuvring
P. Zalewski
Maritime University of Szczecin, Szczecin, Poland
ABSTRACT: The paper presents a concept of fuzzy FTS (fast time simulation) model of twin-screw ship
manoeuvring autonomously (without tugs) in confined waters. The conceptual model has been based on the
fuzzy logic controller with expert database formed by manoeuvres obtained from the real-time non-
autonomous trials classified in relation to expert manoeuvre impact on ship’s advance, lateral and rotation
speed and her position in reference to the present ship status. Exemplary pitch controller for vessels with two
propellers at specified hydro-meteorological conditions has been presented.
26
Figure 2. Illustration of the v
x
input variable fuzzification.
2.1 Fuzzification
Fuzzification is a mathematical procedure for con-
verting an element in the universe of discourse into
the membership value of the fuzzy set.
In the Figure 1 controller output is designated by
u(n) and system output is designated by y(n), where
n is a positive integer representing sampling time dt.
The desired system output trajectory is denoted as
S(n).
In case of system being a ship, steered in accord-
ance to expert passage, u(n) will be pitches setting,
y(n) will be a vector containing six variables defin-
ing actual motion in 3-degrees of freedom: P
xy
- ac-
tual position of selected waterline point stored as
two variables, v
x
- actual longitudinal (advance) ve-
locity, v
y
- actual transverse (lateral) velocity, ω - ac-
tual angular (rotation) velocity, ψ actual ship’s
heading; and S(n) will be a vector containing six var-
iables defining required motion in 3-dof: P
xyr
- re-
quired position of selected waterline point stored as
two variables, v
xr
- required advance velocity, v
yr
-
required lateral velocity, ω
r
- required rotation ve-
locity, ψ
r
- required ship’s heading At time n, y(n)
and S(n) are used to compute the input variables of
the fuzzy controller (effect of pitches setting on mo-
tion): P
xy
- deviation between required and actual
position, v
x
- difference or deviation between re-
quired and actual longitudinal (advance) velocity,
v
y
- difference or deviation between required and
actual transverse (lateral) velocity, ω - difference
or deviation between required and actual angular
(rotation) velocity, ψ difference or deviation be-
tween required and actual ship’s heading. So gener-
ally the input variables vector can be designated by:
( ) ( ) ( )
nynSne =
(1)
Input variable scaling factors are used to conven-
iently manipulate the effective fuzzification on the
scaled universes of discourse. The scaled factors
used for e(n) vector in presented research are nor-
malization constants of the five mentioned devia-
tions, with their preserved positive or negative sign,
as accepted in Zalewski (2003). Assuming the scal-
ing factors for deviations as vector K
e
the scaled in-
put vector is:
( ) ( )
neKnE
e
=
(2)
The scaled variables are then fuzzified by input
fuzzy sets defined on the scaled universes of dis-
course: [0,1]. Figure 2 shows five input fuzzy sets
for one of the E(n) parameters that are used by the
fuzzy controller. At this conceptual phase of FTS
model development the research on the most suitable
fuzzy sets is still ongoing so the most popular mem-
bership functions types found in literature have been
selected, namely triangular and trapezoidal.
The fuzzification results for normalized v
x
value
of E(n), E
2
(n)= K
e2
×v
x
, shown in Figure 2, are
membership value of 0.65 for fuzzy set Positive
Small (PS) and 0.2 for fuzzy set Positive Large (PL).
The linguistic names “Positive” and “Negative” are
related directly to faster advance speed than required
and slower advance speed than required respective-
ly. The membership values for Near Zero (NZ),
Negative Small (NS) and Negative Large (NL) are 0.
Fuzzification can be formulated mathematically
replacing linguistic naming system by a numerical
index system, for instance five fuzzy sets used may
be represented by A
i
, i = -2 (NL), -1 (NS), 0 (NZ), 1
(PS), 2 (PL). The example fuzzification of e
2
(n) with
K
e2
=0.7s/m at time t: e
2
(n)=v
x
=0.5m/s, E
2
(n)=0.35
can be described as:
0(
))(
2
2
=
ne
A
m
(3)
0( ))(
2
1
=
ne
A
m
(4)
(5)
65.0( ))(
2
1
=ne
A
m
(6)
2.0(
))(
2
2
=
ne
A
m
(7)
No mathematically rigorous formulas or proce-
dures exist to accomplish the design of input fuzzy
Negative Large
Positive Large
E(n)
0.2
0.5
1
0
0.5
1
-0.5
-1
0.35
0.65
Negative Small
Near Zero
Positive Small
m(E(n))
27
sets the proper determination of design parameters
is strictly dependent on the experience with system
behaviour, hence the expert data coming from ship
manoeuvring trials is necessary.
2.2 Fuzzy rules
Fuzzification results are used by fuzzy logic AND
operations in the antecedent of fuzzy rules to make
combined membership values for fuzzy inference.
An example of a Mamdani fuzzy rule used for con-
trol of simulated ship advance speed is:
IF E
2
(n) is PL AND E
1
(n) is NS
THEN u(n) is SAs (8)
where PL and NS are input fuzzy sets and SAs
(Slow Astern) is an output fuzzy set. In essence rule
(8) states that if ship’s advance speed is significantly
larger than the desired advance speed and the ship’s
position is a little back of the desired one (calcula-
tion of vector connecting both positions must be
done) the controller output should be the pitch set-
ting corresponding to Slow Astern fuzzy set.
The quantity, linguistic names, and membership
functions of output fuzzy sets are all design parame-
ters determined by the controller developer. Similar-
ly to input fuzzy sets the most popular membership
functions of singleton type have been used (Fig. 3).
The exact number of fuzzy rules is determined by
the number of input fuzzy sets. For the considered
system of ship control the total number of fuzzy
rules will be the combination of 5 input variables
and 5 fuzzy sets (if for all variables the same number
of fuzzy input sets is designed): 5
5
=3125; quite a
large amount for only pitches setting. Actually this
number of fuzzy rules can be significantly reduced
by treating each input variable independently and
combining the output during defuzzification. This
can be achieved by utilizing coupled fuzzy control-
lers.
2.3 Fuzzy inference
The resultant membership values of input sets pro-
duced by fuzzy logic AND operation (Zadeh or
product operator can be used (Ying, 2000)) are then
related to the singleton output fuzzy sets by fuzzy in-
ference. The four common inference methods pro-
duce the same inference result if the output fuzzy set
is singleton. Assuming that for fuzzy sets A
i
mem-
bership values are given by (3)-(7), and for fuzzy
sets B
i
, corresponding to position deviation, the
membership values are:
5.0(
))(
1
1
=
ne
B
m
(9)
3.0( ))(
1
0
=ne
B
m
(10)
if four fuzzy rules similar to (8) will be activated at
time n, using the Zadeh fuzzy logic AND operator
and Mamdani minimum inference method (Ying
2000) yields the following inference results:
for u
1
(n)=DSAs (Dead Slow Astern):
5.0)5.0,65.0min(
((min(
)))()),(
12
11
1
==
==
nene
BA
Z
mmm
(11)
for u
2
(n)=STOP:
3.0)3.0,65.0min(
((min(
)))()),(
12
01
2
==
==
nene
BA
Z
mmm
(12)
for u
3
(n)=SAs (Slow Astern):
2.0)5.0,2.0min(
((min(
)))()),(
12
12
3
==
==
nene
BA
Z
mmm
(13)
for u
4
(n)=HAs (Half Astern):
2.0)3.0,2.0min(
((min(
)))()),(
12
02
4
==
==
nene
BA
Z
mmm
(14)
Figure 3. Singleton fuzzy sets as output fuzzy sets in the designed controller.
u( n) [%]
1
0
50
100
-50
-100
25
STOP
DSAh
m(u(n))
13
80
-25
-13
HAh
SAh
FAh
SAs
DSAs
HAs
FAs
28
If output fuzzy sets in rules are the same fuzzy
logic OR operation can be used to combine the
memberships. In the presented example all four out-
put singleton sets are different (DSAs, STOP, SAs,
HAs) so the calculation will continue without it.
2.4 Defuzzification
The membership values computed in fuzzy inference
must be finally converted into one number by a de-
fuzzifier. In the ongoing research the most prevalent
defuzzifier in literature centroid defuzzifier has
been used (Piegat 2003, Ying 2000). In the present-
ed example the defuzzifier output at time n is:
4321
4321
4321
)(
ZZZZ
ZZZZ
mmmm
umumumum
nu
+++
+++
=
(14)
where:
u
1
=-13% of pitch/throttle position (DSAs),
u
2
=0% of pitch/throttle position (STOP),
u
3
=-25% of pitch/throttle position (SAs),
u
4
=-50% of pitch/throttle position (HAs),
so u(n)= -18% of pitch/throttle position.
u(n) is the new output of the fuzzy controller at
time n which will be applied to the ship system to
achieve control. In comparison with conventional
controllers, what is lacking is the explicit structure
of the fuzzy controller behind the presented proce-
dure. On the other hand utilizing expert knowledge
for such a black box is much more straightforward
and comprehensive.
3 MIMO SYSTEM
The controller’s design process is further
complicated by its multidimensional output. The
possible solution of this problem has been presented
in [6] by utilizing coupled controllers. Also usage of
independent fuzzy controllers in the control of a
MIMO system (multiple input, multiple output) can
give good results.
Figure 4 presents exemplary structure of a
coupled fuzzy controller for 5 input variables and 2
output variables (pitch settings of both propellers).
Each controller utilizes its own fuzzy sets
membership functions and fuzzy rules covering
impact of pitches settings on the rotation and lateral
speed of the vessel.
Figure 4. MIMO coupled fuzzy controller.
4 CONCLUSIONS
The human shiphandling expertise and knowledge
can be captured and utilized in the form of fuzzy
sets, fuzzy logic and fuzzy rules. The expertise and
knowledge are actually nonlinear structures of phys-
ical systems which are represented in an implicit and
linguistic form rather than an explicit and analytical
form, as dealt with by the conventional system mod-
eling methodology. That is why fuzzy controllers
can be suitably implemented into nonlinear dynamic
model of ship control. Fast time simulation based on
such model should give satisfactory results even af-
ter logging only one or few expert passages in rele-
vant area and conditions. Afterwards the FTS model
can run autonomously provided that the proper ship
safety limits are achieved by designed fuzzification
(membership functions) and inference (fuzzy if-then
rules and operators) processes.
BIBLIOGRAPHY
[1] Gucma S., Gucma L., Zalewski P., Symulacyjne metody
badw inżynierii ruchu morskiego”, Wydawnictwo Na-
ukowe Akademii Morskiej w Szczecinie, Szczecin 2008.
[2] Piegat A., “Modelowanie i sterowanie rozmyte”, Akade-
micka Oficyna Wydawnicza EXIT, Warszawa, 2003.
[3] Ying H., “Fuzzy Control and Modelling - Analytical
Foundations and Applications”, IEEE Press, New York,
2000.
[4] Zadeh L. A., “The evolution of systems analysis and con-
trol: a personal perspective”, IEEE Control Systems Mag-
azine, 16, 95-98, 1996.
[5] Zalewski P., “Construction of the Knowledge Base for an
Expert System Supporting Navigator’s Manoeuvre Deci-
sion in Confined Waters”, in 9th IEEE MMAR,
Międzyzdroje, Technical University of Szczecin, pp. 195-
200, 2003.