# Analysis of the Landfill Leachate Treatment System Using Arima Models: A Case Study in a Megacity
## 2 Materials and Methods
### Information Analysis  
The information analysis considered three phases. Phase 1: Daily information of all variables under study was aggregated to obtain time series on a monthly scale (2003-2015). A descriptive statistical analysis was performed to detect trends or anomalies in time series. The normal distribution of time series was evaluated by a Kolmogorov-Smirnov test (\(p\)-value > 0.05). Relationships between variables were also studied using Pearson's correlation coefficient (r) to establish possible control parameters or indicators of the functioning of LTS. In this study, it was assumed that the parameters with the best correlations were those that possibly explained the functioning of LTS. A principal component analysis was also applied to complement the previous analysis. Phase 2: A comparative analysis of the chemical parameters of leachate was carried out in relation to reference guidelines: Colombian Resolution 631 of 2015 [32] and Royal Spanish Decree 646 of 2020 [33]. Spanish legislation was selected in this study as it was more demanding compared to Colombian legislation, and was also adapted to the European context. The contaminant removal efficiency of the leachate treatment plant was also studied in accordance with the guidelines of [PERSON] et al. [34]. Lastly, the influence of climate variables (rainfall and temperature) on leachate concentrations before and after the treatment plant was studied. Phase 3: ARIMA models were developed using the iterative method of [PERSON] et al. [15], to study the chemical parameters time series of leachate before (untreated) and after (treated) the treatment plant. Daily data for all variables under study were averaged monthly. Thus, the time series considered for the ARIMA analysis were monthly. This time scale was also used to identify trends in the chemical parameters of untreated and treated leachate. The iterative stages reported by [PERSON] et al. [15] were considered in the development of ARIMA models: (i) model identification, (ii) parameter estimation, (iii) assumption verification, and (iv) model use. These stages were executed using the statistical software IBM-SPSS V.18.0. During the model identification stage, the stationarity of the time series was analysed. To obtain a stationary time series, if necessary, we used the square root and natural logarithmic transformations. In addition, the orders of the auto-regressive and moving average polynomials were determined, as well as the degree of differentiation to cancel the non-seasonality of the time series. The terms AR and MA of the stationary time series were obtained by analysing the patterns in the autocorrelation function (ACF) and partial autocorrelation function (PACF) diagrams [35]. This process involved several trial and error tests. The models identified were also contrasted with results from the expert modelling tool of the IBM-SPSS software [36]. Therefore, the orders 'p', 'd', and 'q' of the ARIMA models identified for each time series of chemical parameters under study were determined. In the second stage, the parameters of the auto-regressive (\(\omega\)1,..., \(\varphi\)p or Lag 1,..., Lag p) and moving average (\(\omega\)1,..., \(\theta\)p or Lag 1,..., Lag p) polynomials were determined for each model identified by the maximum likelihood method [35]. In this study, a constant was not included in ARIMA models when differentiation was applied [36]. Outliers were also not considered for the ARIMA models developed. In the third stage, the eight assumptions proposed by [PERSON] et al. [15] were verified, to select the best models for each time series. The goodness-of-fit of each ARIMA model was evaluated by the R\({}^{2}\) value (determination coefficient). The suitability of modelling was assessed using the Ljung-Box (Q) statistic. This is also recognized as the modified Box-Pierce statistic. This statistic tests the null hypothesis that there is no significant autocorrelation left in the model residuals, and provides an indication of whether the model is specified correctly.