# Optimization of Multistage Coilgun Based on Neural Network and Intelligent Algorithm
## 6 Conclusions  
This manuscript delineates a methodology for the optimization of feed time and coil quantity in a 2- to 10-stage SICG utilizing GRU and PSO algorithms. The entire experimental process comprised three steps:  
Step 1: An CFM model was established to simulate an MSSICG and calculate its electromagnetic and kinematic characteristics. The simulation data were validated against external circuit experimental data, with the error maintained within 10%. This indicated that it was feasible to use the simulation model's calculations in lieu of the actual experimental results. Step 1 provides a new method for acquiring large volumes of data for MSSICGs.  
Step 2: GRU neural networks were trained using the simulation data in order to establish a prediction model. The predicted root mean square error was only 0.022, indicating that the GRU-based prediction model can replace the current filament model. This model can further save computational resources and significantly reduce computation time.  
Step 3: The predicted output value of the prediction model was used as the objective function, with the target muzzle velocity of the projectile set at 50 m/s. A PSO algorithm was used to find the minimum number of coils that could achieve the target speed, thereby reducing component costs. The optimized design results were compared with the optimal results obtained from the orthogonal test design under the same coil level. When the minimum number of coils was three, the projectile could reach the target speed, with a corresponding initial muzzle velocity of 50.12 m/s. In contrast, the maximum initial muzzle velocity determined using the orthogonal design table was only 46.87 m/s. The PSO algorithm iteration optimization process only takes about 0.0156 s, while calculating parameters in the orthogonal design table using the CFM takes several days.  
In summary, this paper provides a simulation method for acquiring large volumes of data for MSSICGs and proposes a prediction model that combines GRU neural networks and PSO algorithms to optimize an MSSICG's feed time and coil quantity. The accuracy and optimization efficiency of the model have been verified, which can help to improve MSSICGs' service performance, save design time, and reduce maintenance costs.  
This method can be improved further. We did not consider the distance between the coils of the MSSICG as a factor when building the model. In fact, the distance between the coils also has a sequence relationship. When adding a coil, the best distance from the previous coil needs to be judged according to the distance between all the previous coils. Therefore, if the distance between the coils is added as a factor when constructing the dataset, the prediction model will be further improved. In addition, when training the prediction model, we ignored the output of the GRU but used the output of the hidden layer to transform it into the result we desired. In fact, if we can build a dataset concerning the optimal feed time, the optimal feed time can be predicted through the GRU, even without using an optimization algorithm.  
Conceptualization, Y.H.; Methodology, Y.H.; Software, H.T.; Validation, Y.H.; Formal analysis, H.T.; Resources, Y.H.; Data curation, Y.H.; Writing--original draft, Y.H.; Writing--review and editing, H.T.; Supervision, X.Y.; Project administration, X.Y.; Funding acquisition, X.Y. All authors have read and agreed to the published version of the manuscript.  
This work was supported by the Key Special Project for Introduced Talents Team of Southern Marine Science and Engineering Guangdong Laboratory (Guangzhou), under Grant GMI2019 ZD0502, and the high-tech ship research project of ministry of industry and information technology, JIT [2019] No. 357 of MIT.  
The study did not require ethical approval.  
Not applicable.  
The data are not publicly available due to some privacy restrictions.  
The authors declare no conflict of interest.