## 3 Estimation of the Appropriate Fairway Width
### Vessel Traffic Pattern Analysis  
In this study, vessel traffic patterns were analyzed based on the maritime traffic status in the target sea area. A method for identifying and classifying vessel navigation patterns that involved learning a vessel's trajectory pattern and clustering the accumulated trajectory data was used. However, this method can be applied to ships with a certain pattern, and it is difficult to derive valid results for ships that do not maintain a constant pattern, particularly for small ships such as fishing boats. Since small ships are rarely restricted by water depth when navigating to reach their destination and do not set a specific change point and angle when establishing a voyage plan, the same voyage route is not maintained even if they travel to the same destination and will change depending on the environment [29]. Therefore, in this study, pattern analysis using machine learning was performed on ships with patterns of 50 m or longer. The model used for the trajectory pattern learning is shown in Figure 5.  
The first step in the ship navigation pattern clustering process is the extraction of learning data. In this step, AIS data were extracted for seven days and used as target data. Since data are received at random, five points of data were grouped into one group according to the order of data reception. As shown in Equations (3) and (4) below, the three pieces of information of latitude, longitude, and course in the order of time were considered as one set, and each set of 5 data points was used to generate data with 15 dimensions. The extracted AIS data are shown in Figure 6.  
\[data_{\in put}=\left\{D_{t1},D_{t2},D_{t3},D_{t4},D_{t5}\right\} \tag{3}\]  
\[D_{t}=\left\{ \begin{array}{ccc}La_{t},&Lo_{t},&C_{t}\\ \Delta La_{t},&\Delta Lo_{t},&\Delta C_{t}\end{array} \right\} \tag{4}\]  
where: \begin{tabular}{l l} _La_ & Latitude; \\ _Lo_ & Longitude; \\ \(C\) & Course over ground. \\ \end{tabular}   
Figure 4: (**a**) vessel traffic in the coastal waters near Gun-san Port; and (**b**) L-converted traffic volume based on GICOMS data for seven days (24 May–30 May). After that, data scaling and clustering were performed for each point of trajectory data, which showed similar traffic patterns. For clustering, the K-Means algorithm was used. The K-Means algorithm is an algorithm that groups given data into k clusters and operates in a way that minimizes the dispersion of the distances between each cluster. The K-Means algorithm is a kind of machine learning process based on unsupervised learning and is also used to label data that have not been previously labeled [30,31]. Figure 5: Traffic pattern clustering process. Figure 6: Vessel trajectories for GICOMS data. Given a set of d-dimensional data observations, \((x_{1},x_{2},\cdots,x_{n})\), the K-Means algorithm aims to maximize cohesion between the observations in each set, \(\text{S}=\{S_{1},S_{2},\cdots,S_{k}\}\), by partitioning the k(\(\leq n\)) data set of \(n\) data observations. Where \(\mu_{i}\) is the center of the \(i^{th}\) cluster and \(S_{i}\) is a set of points belonging to the cluster, the overall variance is calculated as follows in Equation (5). \[\text{V}=\sum_{i=1}^{k}\sum_{x\in S_{i}}\|x-\mu_{i}\|^{2} \tag{5}\]  
After clustering, classification by state is performed using the kNN algorithm. The K-Nearest Neighbor (KNN) algorithm operates by identifying k nearest sample data from the training data set and including the untrained sample data in the most frequent group. The term kNN is a name given in the sense of using the k nearest data, and the kNN algorithm is a very intuitive method of classifying by inputting non-learning data to a set of learning data that are classified according to their similarity [32; 33]. After clustering, the result data are finally evaluated, and the performance is verified. Figure 7 shows the results obtained for completing the clustering of data and plotting each clustering data point. The detailed plot diagrams are shown in Figure A1 of Appendix B.