# Prediction and Comparison of In-Vehicle CO\({}_{2}\) Concentration Based on ARIMA and LSTM Models
## 4 Discussion
\begin{table}
\begin{tabular}{c c c c c} \hline \hline \multirow{2}{*}{**Datasets**} & \multicolumn{2}{c}{**MAPE (\%)**} & \multicolumn{2}{c}{**RMSE (ppm)**} \\ \cline{2-5}  & **ARIMA** & **LSTM** & **ARIMA** & **LSTM** \\ \hline T1 & 0.48 & 0.49 & 25.37 & 25.11 \\ T2 & 0.52 & 0.65 & 23.02 & 29.37 \\ T3 & 0.42 & 0.65 & 9.25 & 13.51 \\ T4 & 0.54 & 0.52 & 23.34 & 24.57 \\ T5 & 0.49 & 0.65 & 17.55 & 23.09 \\ T6 & 0.35 & 0.39 & 19.19 & 20.93 \\ Average value & 0.46 & 0.56 & 19.62 & 22.76 \\ \hline \hline \end{tabular}
\end{table} 
Table 9: Comparison of model prediction results. somewhat lower than that of ARIMA, it still has numerous advantages as a deep-learning model compared to ARIMA. Firstly, the process of utilizing ARIMA prediction is more intricate than that of LSTM. It involves a series of steps such as time series stabilization detection, model order determination, and validity inspection. In contrast, LSTM can detect regularity in raw data without any mathematical processing, making the prediction process more convenient. Secondly, the use of ARIMA prediction must ensure that the data are stationary. Not all data can be stable after differencing processing, and the data may lose important information after differencing processing, which means that ARIMA may not be able to achieve good results when predicting certain types of data. However, LSTM can be used for non-stationary data prediction. Finally, due to its memory units and gating mechanisms, LSTM is capable of predicting complex multivariate nonlinear data, whereas ARIMA, being a linear model, falls short in this regard. The non-linear nature of the changes in data renders ARIMA incapable of producing accurate predictions for complex multivariate time series data [62], which demonstrates the broader applicability of LSTM. Furthermore, both models have their respective shortcomings. The ARIMA model is not well suited for analyzing data with long-term dependencies, and its predictive capability for nonlinear data is limited. The model's predictive performance tends to degrade when handling large datasets. On the other hand, LSTM models involve a significant number of hyperparameters that require tuning. They are computationally expensive and demand considerable computational resources compared to simpler models like ARIMA. From the comparative research of the two models, it is found that machine learning is not superior to traditional statistical models in all cases, and it is necessary to select an appropriate prediction model according to the amount of data. When the amount of data used for training reaches 1000, LSTM shows better predictive performance [57; 58; 70; 71; 72]. Both of these two models have their advantages when the amount of training data is between 100 and 1000 [44; 45; 71; 72; 73; 74; 75]. ARIMA exhibits better accuracy when the amount of training data is less than 100 [59; 60; 76; 77]. In addition, although our research focuses on the in-vehicle CO\({}_{2}\) concentration in a Nissan-Sylphy and a Honda-Fit under the driving conditions outlined in Table 3, the prediction method used is also applicable to the prediction of CO\({}_{2}\) concentration changes in different vehicles under other driving conditions. The research findings can provide a theoretical foundation for the development of more complex prediction models in the future and serve as crucial evidence for establishing a CO2 concentration prediction model within the traffic safety management system. However, this research also has several limitations. Firstly, our anemometer lacks the capability to record airflow data. Secondly, our prediction model solely relies on historical data for forecasting future trends, without considering influential factors or elucidating the underlying mechanisms. Therefore, forthcoming research should incorporate influential factors and establish multivariable time series prediction models.