# Research on a Support System for Automatic Ship Navigation in Fairway
## 5 Numerical Simulation and Result Discussion  
### The Conditions and Requirements of the Simulation  
In this section, numerical simulations were carried out in MATLAB to verify the effectiveness of the proposed system for automatic ship navigation in a fairway environment. For simulation purposes, the latitude and longitude of the Mokpo area were normalized into non-dimensional units by using the equations given in (17):  
Figure 8: The membership functions of the controller: (**a**) Heading error; (**b**) yaw rate; (**c**) bow thruster.  
\begin{table}
\begin{tabular}{c c c c c c c c c} \hline \hline  & & \multicolumn{6}{c}{**Heading Error**} \\ \cline{2-10}  & & \(-\)B & \(-\)M & \(-\)S & Z & +S & +M & +B \\ \hline \multirow{5}{*}{**Yaw Rate**} & \(-\)B & +B & +B & +B & +B & +M & +S & \(-\)M \\  & \(-\)M & +B & +B & +B & +M & +S & Z & \(-\)M \\ \cline{1-1}  & \(-\)S & +B & +M & +S & Z & \(-\)S & \(-\)M & \(-\)B \\ \cline{1-1}  & +S & +B & +S & Z & \(-\)S & \(-\)M & \(-\)B & \(-\)B \\ \cline{1-1}  & +M & +M & \(Z\) & \(-\)S & \(-\)M & \(-\)B & \(-\)B & \(-\)B \\ \cline{1-1}  & +B & +M & \(-\)S & \(-\)M & \(-\)B & \(-\)B & \(-\)B \\ \hline \hline \end{tabular}
\end{table}
Table 5: The reasoning rules of heading controller.  
Because the dimensions of the port area (longitude and latitude) and the length of the ship are shortened in computer simulations, the port area and ship length must be normalized into a non-dimensional form by dividing the latitude and longitude to the length of the ship (_L_). The geographical coordinates of Mokpo fairway area (Figure 4) and the ship position were normalized to non-dimensional form (non-dimensional unit) as the following form:  
\[\eta^{\prime}=\frac{\textit{Longitude}}{L},\ \xi^{\prime}=\frac{\textit{Latitude}}{L}. \tag{17}\]  
The non-dimensional area of the Mokpo fairway is shown in Figure 9. The planned route for ship navigation included waypoints which were marked by \"plus\" symbols.  
The details of these points are as follows: Waypoints (non-dimensional latitude, non-dimensional longitude) = \((-29,\ -40)\); \((-33,\ -30.3)\); \((-30,\ -26)\); \((-3,\ -7.3)\); \((5.5,\ -5)\); \((6.3,\ 0.5)\); \((5,\ 6)\); \((0,\ 10.5)\); \((0,\ 12.5)\); and \((4,\ 13.5)\). The initial position of the ship is located at a point having the coordinates \((-48,\ -15)\) with \(4\) (m/s) in surge velocity and a propeller rev/sec of \(2.75\) (the effect of wind disturbance is assumed to be \(5\) knots in velocity from North (N) to South (S).  
The proposed system consists of three functions with respect to ship control: First, the ship is brought to first waypoint WP\({}_{1}\) to start the track-keeping process. The first fuzzy controller is activated to regulate the ship's rudder and control the ship to track along the planned route from (WP\({}_{1}\)) to (WP\({}_{10}\)). Second, the propeller's PRM is decreased from \(2.75\) to \(0\) (rps) by the PID controller when the ship arrives at waypoints (WP\({}_{6}\), WP\({}_{7}\), WP\({}_{8}\), WP\({}_{9}\)), respectively. At waypoint (WP\({}_{9}\)), the ship's engine is stopped so that the ship approaches (WP\({}_{10}\)) on only its own residual inertia. Finally, the heading stabilizing controller is employed to bring the ship's heading onto \(346.5\) degrees (this direction is appropriate for approaching the wharf point from (WP\({}_{9}\))). In this stage, the rudder's effectiveness is not sufficient to turn the ship's heading independently. Therefore, the bow thruster is proposed as an effective solution when the ship is difficult to control by rudder alone. After completing tasks of automatic ship navigation, this system can be combined with an automatic ship berthing system to bring the ship from area WP\({}_{10}\) to the wharf point.  
Figure 9: Mokpo fairway simulation planned route after normalizing the latitude and longitude.