Parameters’ Identification of Vessel Based on Ant Colony Optimization Algorithm

In this paper, the ant colony optimization (ACO) method is used to identify the parameters of a 3-DOF nonlinear vessel model. Identifying the parameters is abstracted as a nonlinear optimization problem to solve through the ant colony optimization algorithm. The identification procedure is divided into two parts. The first part of the identification procedure is to identify the parameters related to surge motion. The second part of the identification procedure is to identify the rest parameters of the vessel’s kinetics model. In the surge model identification procedure, the transient motor speed is used to generate the training data, and in the sway and yaw motion identification procedure, the zigzag maneuvering with different motor speeds is used to generate the training data. All the parameters are identified by the ACO method and the least-square (LS) method based on the training data and then validated on the validation data. The prediction performance of parameters identified by different methods is compared in the simulation to demonstrate the effectiveness of the ACO algorithm.


Introduction
Unmanned technology has developed rapidly in recent years and attracted more and more attention from academia and industry. Many kinds of unmanned products such as unmanned vehicles, unmanned aerial vehicles, unmanned surface vessel, and unmanned submersibles have been widely deployed as a network in various situations such as scientific research, environmental missions, ocean resource exploration, military use, and other applications [1] to help people improve work efficiency. As an intelligent device that works on the water, the unmanned surface vessel can work as a node of the overall unmanned network and extend the working range of the entire unmanned network to the surface of the water and underwater. e level of intelligence of the unmanned network is related to the level of intelligence of every node in the network. A sufficiently intelligent unmanned surface vessel contains a lot of techniques such as navigation techniques [2,3], guidance techniques [4,5], and control techniques [6][7][8].
e modeling of the unmanned surface vessel is imperative for both control method design and simulation study purposes [1]. To describe the vessel motion in the surge, sway, and heave, a nonlinear 6-DOF model with different dimension motions coupled together is imperative. However, the nonlinear 6-DOF model has lots of parameters which are very difficult to identify, the vessel algorithms designed based on the nonlinear model are very difficult, and the real-time performance of the algorithms is hard to guarantee. For algorithm design, some simple models such as the first-order Nomoto model proposed by Nomoto in 1957 [9, 10] are used. e Nomoto model describes vessel motion approximately under the assumption that the forward speed of the vessel changes slowly. Except for the Nomoto model, the 3-DOF model, including surge velocity, sway velocity, and yaw angular velocity, is also widely used in vessel control [11][12][13].
e prediction results of the Nomoto model and 3-DOF model cannot meet the requirements of the simulation study. How to identify the parameters of the nonlinear 6-DOF model is a challenging problem. e towing carriage can identify the parameters of the vessel model such as CyberShip II [14], but the size of the towing carriage limits the size of the identified vessel. Some research use CFD [15] to simulate the ship motion and to identify the parameters [16], but the accuracy of the CFD in a complex situation is still worthy of further research. Many research studies choose full-scale vessel trials to identify the vessel model; the approach to model identification involved adapting model parameter value which was proposed in [17]. In [18], a new transformed multi-innovation least-squares (TMILS) algorithm is developed; the model structure is identified first and then the parameters are identified with full-scale trial data. An artificial neural network was used in [19] to model a high-speed craft with sea trial data.
As for the identify method, the least-squares method [20][21][22][23] has been a widely used method in system identification procedure, but the least-squares method can only deal with the linear problem; some identified procedure are abstracted as a nonlinear optimization problem. Support vector machines have the advantage in solving the nonlinear optimization problem, and it was used to identify the parameters of the vessel in [24][25][26][27]. Except for the least-square method and support vector machines method, some other methods are also used to identify the parameters. In [28], the identification procedure was divided into two steps: the first step was to determine the structure of the nonlinear model and the second step was parameter estimation refinement by using a nonlinear prediction error method with the unscented Kalmen filter. In [29], a sensitivity analysis and SQP method were used to identify the hydrodynamic coefficients of the Esso Bernicia tanker.
In this paper, the ant colony optimization method is used to identify the parameters of the vessel kinetics model. e parameter-identified problem is summarized as a nonlinear least-square problem, and the ant colony optimization method is used to solve the nonlinear least-square problem. e solution to the problem is the parameters to be identified. e identification procedure is divided into two parts [23]: the parameters related to surge motion were identified first by an experiment and then the rest of the parameters related to sway and yaw motion were identified by the zigzag test. e organization of this paper is as follows. In Section 2, a nonlinear discrete 3-DOF state-space model of USV with surge speed, lateral speed, and yaw angle as state variables is established. Section 3 discusses the ant colony optimization method. Section 4 illustrates and analyzes the identification results. Section 5 summarizes the conclusions.
(1) (i) Vector ] � u v r ⊤ denotes vessel surge velocity, sway velocity, and yaw angular velocity, respectively. (ii) Matrix M accounts for inertial effects: (iii) Matrix C(]) accounts for centrifugal and Coriolis effects: where (iv) Matrix D(]) accounts for viscous and dissipative effects: where (v) Vector τ denotes the force and torques generated by actuators. (vi) τ wind denotes force and torques caused by wind (vii) τ wave denotes force and torques caused by wave. e vessel model used in this paper is CyberShip II [14], which has a bow thruster, two thrusters, and two rudders. For the convenience of modeling force and torques, the bow thruster is excluded from the actuator model, and two thrusters and rudders are equivalent to one. us, the actuator model can be written as τ � Bτ act (ν, n, δ), where matrix B is the actuator configuration matrix and vector τ act (], n, δ) is the force and torques related to speed of the motor n and rudder angle δ: 2 Mathematical Problems in Engineering with T � T |n|n |n|n − T |n|u |n|u, 2.2. Discrete Nonlinear Model. In the vessel experiments, the experiment data are collected in the discrete form. Also, vessel motion controllers are usually designed in the discrete zone. erefore, the continuous-time model equation (1) is approximated as a discrete model, and the parameters of the discrete model are identified in this paper. e external force is all ignored for the convenience of discretizing the continuous-time model, and equation (1) can be rewritten as where the matrix A c and vector α denote the time-varying terms and constant parameters in the vessel model: e sample time of collecting data in simulation is denoted as T s ; equation (10) can be approximated by the back Euler integration method at time k as where B c � Because the matrix B c and T s M − 1 A c are both constant matrix, thus, equation (12) can be rewritten as e parameters a 1 , . . . , a 7 , b 1 , . . . , b 10 , and c 1 , . . . , c 10 are unknown parameters. In Section 3, an ACO method is used to identify parameters of equations (13)-(15).

Parameter Identification Based on the ACO Method
In this section, the parameter of discrete vessel nonlinear model equations (13)-(15) is identified based on the ACO method.

Parameter Identification Formulation.
Consider that the vessel has two main motion states: one is the straight-line surge motion and the other is the turning motion. erefore, parameter identification includes two steps: the first step is to identify the parameters related to surge motion and the Mathematical Problems in Engineering 3 second step is to identify the residual parameters. In the straight-line surge motion, the lateral velocity and yaw angular velocity are both close to zero. us, the surge motion can be decoupled from the other motion, the parameters related to straight-line motion and thrust force can be identified. By ignoring the terms related to the lateral and yaw motion, equation (13) can be simplified as where Based on equation (16), the predicted vessel surge velocity at time k + n, denoted as u(k + n + 1), can be calculated by the motor speed at time k + n, denoted as n(k + n), and predicted as surge velocity u(k + n). en, the surge motion model identification problem can be described as a nonlinear optimization problem: where u denotes the predicted surge speed based on the parameter θ and u denotes the surge speed collected in the experiments.
Since the parameters θ are identified in equation (17), then the rest parameters can also be described as a nonlinear optimization problem to identify. Based on equations (13)- (15), the vessel state can be predicted by where Based on equation (18), the predicted vessel state at time k + n, denoted as ](k + n + 1), can be calculated by the motor speed n(k + n), rudder angle δ(k + n), the predicted surge velocity u(k + n), the predicted lateral velocity v(k + n), and the predicted yaw angular velocity r(k + n).
en, the parameters' identification problem can be described as a nonlinear optimization problem: e parameters now can be identified by solving two nonlinear optimization problem equations (17) and (20).

ACO Formulation.
As mentioned above, the key to identify the model parameters is solving an optimization problem as equation (17) or equation (20). Generally, the typical unconstrained continuous optimization problem is shown in equation (21), where f(x) is the objective function and X is the decision variable (D.V) in the form of an Ndimensional vector in which the member changes continuously: As far as equations (17) and (20) are concerned, f(θ) and f(θ 2 ) are objective functions of the two identification problems, respectively. Accordingly, θ and θ 2 are high-dimensional D.Vs.
Traditional optimization algorithms find it difficult to solve the nonlinear high-dimensional optimization problems described in equations (17) and (20). A new computational paradigm called "Ant System" is proposed in [31], which is used for stochastic combinatorial optimization and motivated amounts of interrelated solutions to improve the performances. e representative one is Ant Colony Optimization (ACO). e parameter identification problem we focused on, however, is a typical optimization problem of which decision variables (D.V) vary in continuous domains.
Despite the method that discretizes, the feasible region takes the effect to a certain extent; the accuracy and efficiency are severely restricted. Socha and Dorigo [32] extend ACO to continuous domains and keep the relevant conceptual structure invariable. e complete flowchart of the CACO is shown in Figure 1. In CACO, the fundamental work is initializing the elementary data structures and parameters to abstract the actual optimization problem and determine the initial state. Pheromone, inspired by the natural behavior of ants, which records the excellent solutions, is the significant feature of ACO. Different from the ACO which uses a highdimensional matrix to represent the pheromone, CACO applies the continuous probability density function (CPDF), such as the Gaussian function. Furthermore, CACO maintains a solution archive of capacity k composed of k ndimensional decision variables (S 1 j , S 2 j , . . . , S n j ), which are constructed by ants, and the corresponding fitness f(S j ) is to memorize the several former solutions. For the surge model identification problem, the variable n is 4 and the fitness is given by f(θ). As for the remaining parameters identification problem, the variable n is determined by θ 2 , that is, 22, and the fitness is calculated by f(θ 2 ). Moreover, the solution vectors are supposed to be initialized using Mathematical Problems in Engineering random values, sampling from the search space R. e other related parameters which will be discussed below are supposed to be set reasonably at this stage. As shown in Figure 1, once the initialization work is accomplished, the algorithm will step into searching for solutions in R and further instruct to update the pheromone. In the course of searching for solutions for an individual ant, the first step is choosing a target; that is, select a solution from the archive based on the selected probability following equations (22) and (23) and the roulette method. e value l is the rank of the corresponding solution, k is the size of the archive, and q is an extra parameter to adjust the standard deviation, which has an effect on the shot probability of different ranks. Namely, q is a trade-off factor between the global and local optimal solutions: It is worth noting that the ants in ACO or CACO are not a container (i.e., a vector composed of decision variables) but a solution builder (i.e., a pathfinder in the search space to construct the solution vector). For an n-dimensional decision variable, an ant needs n steps to accomplish the construction per iteration. Once the target is selected, the destination of the i th dimension variable is assigned by Gaussian sampling using the function described as e parameter μ i l � s i l , and σ i l is calculated as equation (25), where ξ has equivalent effect with the pheromone evaporation rate which can influence the speed of convergence: On account of the pheromone reflects on the solution archive, an update-pheromone operation may be accomplished by renewing the table. After all of the ants complete the construction of solutions, there will be m + k solutions. For the sake of the superior solution to maintain the archive, all solutions should be ordered according to the evaluation index (e.g., the root mean square error between predicting results and sample data). In the subsequent step, the worst m solutions would be discarded and the others remain in the archive.
After updating the archive, the algorithm tests' termination conditions (such as the maximum iterations and convergence precision) are in accordance with the optimization results of the current generation. If the termination condition is not met, the optimization problem will repeat the searching, evaluating, and renewing process mentioned above until the condition is satisfied. Otherwise, the iteration should be broken up and the optimization results should be output, which are the optimized model parameters θ and θ 2 and the corresponding model performance.

Simulation Results
In this paper, the CyberShip II is used as a study example. e kinetics model structure of the vessel is already known, and the parameters of the kinetics model are unknown. e parameters are identified by the ACO method and the LS method, respectively, and the identification results are compared to demonstrate the effectiveness of the ACO method. Normally, in the vessel identification experiments, the vessel states and actuator states such as velocity, angular velocity, motor speed, and rudder angle are collected by the sensor with noise. erefore, the Gaussian white noise is added in the whole identification simulations to simulate the sensor noise. e whole identification procedure is divided into two steps, the first step is to identify the parameters related to the surge motion and the second step is to identify the parameters related to the sway and yaw motion.

Surge Model Identification.
In the vessel surge motion, sway velocity and yaw angular velocity are approximately equal to zero. erefore, the couple terms of the vessel kinetics model related to sway and yaw motion can be ignored. e purpose of the surge model identification is to identify the parameters a 1 , a 2 , a 3 , a 5 , and a 6 in equation (13). e vessel motor speed is used as the excitation input which varies randomly between 5 rpm and 25 rpm, and the vessel surge velocity as the response to the excitation input varies between 0.2 m/s and 0.8 m/s, as shown in Figure 2. e transient motor speed and surge speed are used as training data to identify the parameters. e parameters related to the ACO method in solving surge model identification problem are shown Table 1, and the ACO method convergence curve are shown in Figure 3. From Figure 3, we can see the fitness which is the value of f(θ) in equation (17) gradually decreases and becomes stable after 450 iterations. e identified results of the ACO method and LS method are shown in Table 2.
In Figure 2, the prediction results of parameters identified by the different methods are very close. In addition, another two different surge motions are used as validation data to compare the performance of different algorithms, as shown in Figures 4 and 5. In Figure 4, the input motor speed is a PRBS sequence. From the results, we can see the prediction results of different methods are very close, except that the prediction results of the LS method are slower than the simulation data when the surge speed is larger than 0.9 m/s. In Figure 5, the input motor speed is maintained at 5 rpm, 10 rpm, and 20 rpm, so the surge speed can finally be maintained at around 0.16 m/s, 0.36 m/s, and 0.67 m/s. We can see from the results that the prediction results of different methods are almost the same when the motor speed is kept at 5 rpm and 10 rpm. However, the prediction surge speed of the LS method is larger than the simulation results when the motor speed is kept at 10 rpm.
In order to quantify the comparison result of different methods, the R-square is used as an index function. e closer the R-square to 1, the better the identified results, and in some situations, the R-square may be negative; then, we use the symbol − to indicate it. From the R-square results of different methods in Table 3, we can see the R-square values of the ACO method and the LS method are very close. However, the R-square value of the ACO method is better than the LS method in training data and validation data, so the ACO method has better performance than the LS method in the surge model parameters' identification simulation experiments.

Lateral and Yaw Model Identification.
In the sway and yaw model identification simulation experiments, the rest parameters related to the sway and yaw motion in equations (13)-(15) are identified. Zigzag tests are widely used in vessel parameters' identification experiments [16,24]. In this paper, a 20°/20°zigzag test contains constant motor speed which is used to generate the training data, as shown in Figure 6 and Table 4. e convergence process of the ant colony algorithm is shown in Figure 7. e result shows that the optimal solution      almost converges to the expected range after 1000 generations. e parameters identified by the LS method and ACO method are shown in Table 5.
From Figure 6 we can see that the LS method has better prediction performance than the ACO method at the surge model, sway model, and yaw model. To further verify the effectiveness and the performance of the ACO method, we use another two different excitation inputs to generate the validation data which are shown in Figures 8 and 9, and for the convenience of comparison, the heading angle is not changed to the range from 0°to 360°. In addition, the Rsquare value is used to quantitatively compare the prediction performance for the two different methods, as shown Table 6.
In Figure 8, the motor speed maintains at 10 rpm, 20 rpm, and 30 rpm at different times, and the rudder angle is a PRBS sequence with different amplitudes. From the results, we can see the prediction results of ACO are slightly better than the LS method at a motor speed of 10 rpm, but the prediction results of the two methods are similar at a motor speed of 20 rpm and 30 rpm. e R-square value of the ACO method is closer to 1 than the LS method on the surge model, sway model, yaw model, and heading model.
In Figure 9, the motor speed maintains at 10 rpm, 20 rpm, and 30 rpm at different times, and the rudder angle maintains at 5°, − 15°, and 25°at different times. From the results, we can see only at a motor speed of 5 rpm and rudder angle of 5°; the two methods have similar prediction results. From the R-square values, we can see the prediction results of the ACO method have very good performance, but the      prediction results of the LS method are only valid at low motor speed and small rudder angle.
In the identification results of the sway and yaw motion, although the prediction results of the LS method are better than the LS method in training data, the identified parameters of the LS method are invalid in predicting the surge, sway, and yaw motion when the motor speed and rudder angle maintain the constant value. However, the parameters identified by the ACO method have a good prediction result in the surge, sway, and yaw motion both in the training data and validation data.

Conclusions
is paper presents the parameters' identification under the known structure of the vessel kinetics model. e parameters' problem is summarized as a least-square problem; the least-square method and the ant colony optimization method are used to solve the least-square problem. e solution to the least-square problem is the parameters to be identified. e identification procedure is divided into two parts. e first part of the identification procedure is to identify the parameters related to surge motion. e second part of the identification procedure is to identify the rest parameters of the vessel kinetics model. In the identification procedure, the transient excitation inputs are used to generate the training data; the constant excitation inputs and different transient inputs are used to generate the validation data. e R-square value is used as an index function to quantitatively compare the prediction results of the ACO method and the LS method. e comparison of the identification results and maneuvering predictions demonstrate the effectiveness of the ACO method and reflect the performance advantage of the ACO method.

Data Availability
e data used to support the findings of this study are available within the article.

Conflicts of Interest
e authors declare that they have no conflicts of interest.