## 4 Edge Prediction Algorithm Based on ARMA  
### ARMA Model  
A time series refers to the results of observing a certain process at a given sampling rate in an equally spaced time period [49]. Environmental monitoring data such as temperature and salinity in the application of underwater three-dimensional monitoring are a form of time series data. The change in the time series has a tendency, periodicity, and seasonality. The change process of the time series can be defined as a set of variables: \(y_{t}\) is dependent on the parameter t. The core of edge prediction is time series prediction, that is, to find out the change law with time of underwater environmental data, such as temperature and salinity, from historical data, and to predict future data. Considering the computing performance of underwater nodes and the prediction accuracy of underwater monitoring applications, the ARMA model is used as the core model of edge prediction. ARMA is often used for stationary time series prediction [49]. If the monitoring data are a stationary series, the monitoring data can be expressed by the  
Figure 3: Operation flow of the agents: (**a**) data acquisition and edge prediction process; (**b**) data sending process; (**c**) data receiving process; (**d**) edge prediction and data recovery process. combination of pre-sequence data and prediction error, and the expression is as shown in [49]:  
\[y_{t}=\beta_{0}+\beta_{1}y_{t-1}+\cdots+\beta_{p}y_{t-p}+\varepsilon_{t}+ \alpha_{1}\varepsilon_{t-1}+\cdots+\alpha_{q}\varepsilon_{t-q}, \tag{1}\]  
where y is the predicted or observed values, and \(\varepsilon\) indicates the prediction errors; \(\alpha\) and \(\beta\) are the coefficients; p and q are the orders, indicating the number of the observed values and prediction errors, respectively. Formula (1) represents time series \(y_{t}\) following the ARMA(p,q) model. When the monitoring data are non-stationary series, that is to say, the time series contains the characteristics of trend, seasonality and periodicity, the nonstationary sequence can be converted into a stationary sequence through difference processing. The second-order difference expression is as shown in [49]:  
\[\
abla^{2}y_{t}=\
abla\big{(}y_{t}-\ y_{t-1}\big{)}=y_{t}-\ 2y_{t-1}+y_{t-2}, \tag{2}\]  
where \(\
abla\) is the difference operator, and \(\
abla^{2}\) is the second-order difference operator. The difference reflects the change between discrete quantities. The first-order difference represents the difference between the current value and the previous value, and the second-order difference represents the difference between the current first-order difference and the previous first-order difference. Formula (2) represents the second-order difference of time series \(y_{t}\). \(\
abla^{d}y_{t}\) is the d-order difference of \(y_{t}\) After the difference transformation, \(\
abla^{d}y_{t}\) becomes a stationary time series, which can be expressed as shown in [49]:  
\[\lambda(B)\Big{(}\
abla^{d}y_{t}\Big{)}=\theta(B)\varepsilon_{t}, \tag{3}\]  
where B is the delay operator, which follows \(y_{t-p}=B^{p}y_{t},\ (\forall p\geq 1)\) and \(\
abla^{k}=(1-B)^{k}\). \(\lambda(B)=1-\lambda_{1}B-\lambda_{2}B^{2}-\cdots-\lambda_{p}B^{p}\) is the autoregressive polynomial, and \(\theta(B)=1-\theta_{1}B-\theta_{2}B^{2}-\cdots-\theta_{q}B^{q}\) is the moving average polynomial. \(\varepsilon_{t}\) is a white noise sequence of the zero-mean. Formula (3) is also called the ARIMA(p,d,q) model, which is used to realize edge prediction. The autocorrelation function (ACF) is often used to determine the order d of the ARIMA model [50; 51; 52]. After d-order difference transformation, if the ACF value corresponding to the difference series is close to 0, the time series passes the stationarity test. Smaller values of d represent a better choice. When selecting the p and q parameters, the Akaike information criterion (AIC) and Bayesian information criterion (BIC) can achieve a better selection effect than using the mean square error (MSE) [53].