1 Introduction

Nowadays, contamination of soil and groundwater becomes a serious problem due to the lack of control of pollutants from the source of production. Such sources include industrial and agricultural activities (EPA 1989). Every year, about 600 million tons of waste is produced by industrial activities, and this is growing at an annual rate of 10% (Ngo and Natowitz 2009). Contamination of soil and groundwater, at concentrations higher than the standard, will cause potential risk to health and the environment (Wuana and Okieimen 2011).

Soil remediation is done in different physical, chemical, and biological methods (Hamby 1996), and is divided into two major ex situ and in situ fields (Agarwal and Liu 2015). Soil vapor extraction is a physical in situ method for cleaning the volatile contaminants from the non-clay soils relying on their low evaporation temperature (EPA 2006). To improve the efficiency of the method, new initiatives have taken place and thermal enhancement is one of them (Air Force Center for Environmental Excellence 2001). Soil type and permeability, chemical and physical properties of contaminants, environmental factors such as weather and hydrological conditions, pollutant volume, transfer ability, and toxicity are some factors affecting the level of soil contamination (Switzer and Kosson 2007; Truex et al. 2013).

In this study, the thermal enhancement method was used through injecting the water vapor and hot air. The reason for selecting these two ways is that these are the most common and widely used methods for thermal enhancement of vapor extraction in laboratory and industrial levels (Dablow et al. 2000; Di et al. 2002). Moreover, providing equipment and high temperatures is too expensive and with uncertainty (Beyke and Fleming 2005; Lowe et al. 2000).

Previously, some researches have been conducted on vapor extraction in laboratory scales and numerical forms. The laboratory researches include the efficiency of the SVE method in layered soils contaminated with TCE (Stinson 1989), the efficiency of this method in clay soils contaminated with thinner (Gibson et al. 1993), the influence of clay and temperature on remediation of sandy soil contaminated with diesel (Sabour et al. 2014), thermal remediation of light and heavy petroleum contaminations with electric heating (Beyke and Fleming 2005), and several other researches. Less attention has been paid to numerical study and modeling. Researches have been done to determine the mass transfer processes with the help of a three-dimensional model of vapor extraction (Nguyen et al. 2013). Vapor extraction data were also analyzed to determine the mass transfer limitations and predict mass flux from the source (Brusseau et al. 2010). In this study, a comprehensive model and formula has been presented for thermal enhancement removal rate in contaminated sandy soils.

2 Materials and Methods

Sandy soil was selected for modeling due to its having the highest cleaning efficiency and the lowest uncertainty (Albergaria et al. 2008; Peng et al. 2013). The contaminant used to obtain data is n-alkane (C13–C19) which is the most common range of volatile organic contaminant in petroleum products (Irwin et al. 2013; Li et al. 2016).

To obtain the data, the results of previous tests were used. These results are from the “Investigating the Influence of Clay & Heating in Remediation of Contaminated Soil from Gas-Oil by Soil Vapor Extraction” article (Sabour et al. 2014). For the validation part of the modeling, data were extracted from the article “Predicting Hydrocarbon Removal from Thermally Enhanced Soil Vapor Extraction Systems” (Poppendieck et al. 1999). These data were extracted using chart analysis software 3D CAD CATIA, GRABIT toolbox in MATLAB, and GetData Graph Digitizer. A total amount of 67 packs of data were used for modeling. After screening and data processing, they were used for modeling. Screening was done using Plackett-Burman designs. This method helps to process data and minimize the errors. To apply this method, a Hadamard matrix in MATLAB was used.

After screening, the first model was created with MATLAB software with the help of a neural network for validation. Neural network modeling was chosen in view of the fact that since the relation between input data and objective function is not linear, a powerful and complex method is needed to understand this complicated relationship. Artificial neural network is a trainable method of modeling which consists of algorithms that can be used to perform nonlinear statistical modeling and has the ability to implicitly detect complex nonlinear relationships between dependent and independent variables, the ability to detect all possible interactions between predictor variables, and the availability of multiple training algorithms (Tu 1996).

Modeling was done using a feedforward backpropagation method and scaled conjugate gradient algorithm. This algorithm was used due to its having less dispersion and error compared to other algorithms. It is worth noting that the sigmoid function of the desired network was used due to the nature of the reviewed data.

After neural network modeling and data validation, the final model was analyzed and a removal formula was presented by using the response surface method (RSM) and modeling in historical data environment. According to Table 1 and regression coefficients obtained by data analysis, a second-order quadratic model was obtained for removal efficiency. In this equation, the response surface method considered the second-grade effects and interactions of tested variables in addition to linear effects of parameters.

Table 1 The sum of the squares, df (degrees of freedom), mean square, F value, and p value for different modeling functions

3 Results and Discussion

In this study, by using a multilayer artificial neural network, the relation between time, temperature, and removal efficiency has been validated.

As can be seen in Fig. 1, an artificial neural network with 30 hidden layers was used. In this network, two factors of time and temperature were used as input factors. Seventy percent of available data was used to train the network; 15% of data was used for validation and the rest for test.

Fig. 1
figure 1

The structure of the neural network for estimation

According to the mean squared error curve (Fig. 2), the process of reducing the mean squared error (MSE) lost its downward trend after epoch 9 and then it increased. As a result, the process of network training for all three curves of training, validation, and test is in its best situation in stage 9.

Fig. 2
figure 2

Mean squared error curve

The cease of the reduction error after stage 9 is due to the data screening before modeling. The data became uniform due to screening processes. The irrelevant data, which contains error, have been removed before entering the modeling process. Therefore, the model reached the best mode with the least errors after nine epochs.

In the neural network regression diagrams related to different aspects of training, validation, and test (Fig. 3), the accuracy of regression conducted in phases of training validation and test has been investigated. These correlation coefficients are equal to 0.96964, 0.98969, and 0.93453, respectively. This coefficient is equal to 0.96653 for the overall state of the model. By comparing the correlation coefficients, two points can be realized. First, the correlation coefficient at each stage is close to 1. Therefore, the model is accurately in compliance with reality. Second, the proximity of the coefficients in various stages of modeling indicates that the model has followed a consistent trend at all stages of its implementation and no error has occurred. Therefore, the obtained values by the model are close to true values with good approximation.

Fig. 3
figure 3

Neural network regression diagram

The values of RMSE, MAE, and R indicate root mean square error, mean absolute error, and correlation coefficient, respectively. Their formulas are as follows:

$$ \mathrm{RMSE}=\sqrt{\frac{1}{n}\sum_{i=1}^n{\left({y}_{i-}{\hat{y}}_i\right)}^2} $$
(1)
$$ \mathrm{MAE}=\frac{1}{n}\sum_{i=1}^n\left|{f}_i-{y}_i\right|=\frac{1}{n}\sum_{i=1}^n\left|{e}_i\right| $$
(2)
$$ R=\sqrt{1-\frac{\sum_{i=1}^n{\left({y}_i-{f}_i\right)}^2}{\sum_{i=1}^n{\left({y}_i-\frac{1}{n}\sum_{i=1}^n{y}_i\right)}^2}} $$
(3)

The errors related to the model are shown in Table 2. The lesser correlation coefficient in the test mode compared to the training and validation modes is due to the application of a variety of tests in this stage to check the quality of the model. The lesser correlation coefficient in the training mode compared to the validation mode is due to large data volume and lack of network training. However, the proximity of the correlation coefficients and the square of the correlation coefficients to number 1 and each other shows the proper performance of the model.

Table 2 Calculated errors for neural network model

As can be seen, the neural network model based on experimental data has the least error and acceptable correlation coefficient. The low error rate and the difference between predicted and actual data is due to the measurement errors in the laboratory, uncertainties related to contaminants, and the movement and accumulation of contaminants in the soil matrix.

After validation by the neural network model, another modeling was performed using response surface methodology. In this analysis, the obtained results of all the effects governing the issue including the first-grade effects, the second-grade effects, and interaction of two influencing factors were considered to reach an overall judgment about the significance of factors.

In Fig. 4, the process of efficiency changes with respect to time is shown. As can be seen, with the passage of time, the efficiency increased. The reason for this increase is that, with the passage of time, the contact area between the air and water vapor and contaminant increases. Consequently, the vapor pressure increases and the contaminant state changing from liquid to gas increases.

Fig. 4
figure 4

Efficiency changes with respect to time

In Fig. 5, the process of efficiency changes with respect to temperature is shown. In this diagram, as expected, the removal rate increased with increasing of the temperature. Obviously, this increase is due to increase of vapor pressure and the proximity of the injected vapor and air temperature to the evaporation temperature of volatiles.

Fig. 5
figure 5

Efficiency changes with respect to temperature

For better understanding, in Fig. 6, the actual values and the values provided by the model are shown in a diagram. In this diagram, the vertical axis shows the values predicted by the model and the horizontal axis indicates the values observed in the tests. Since the data concentration is on the fitted line, this means that values estimated by the model are close to laboratory values. The proximity of the obtained points to the axis Y = X shows high adequacy of the model.

Fig. 6
figure 6

Predicted and observed values in the model

In order to check the validity of the model, the correlation coefficient (R 2), analysis of variance is investigated. In this section, the model competency is approved given the amount of p value <0.05. The possible value for each parameter can be seen. The results of the variance analysis in investigating the removal rate are shown in Table 3.

Table 3 Analysis of variance (ANOVA)

As can be seen, the possibility of a model regression equation is less than 0.0001 and smaller than 0.05 (considering the confidence level of 0.95). This shows that the second-order quadratic model complies with laboratory results. Regarding the regression equation, the low rate of p value (α ≤ 0.5) shows that the results are not random. The amount of p value (less than 0.5) indicates that the parameters are significant. According to the table above, the F value (test statistic) is equal to 2205.991. Therefore, it confirms the competency of the model. It also indicates that the model is significant and there is the possibility of a slight incompetence of the model. The F value for lack of fit is equal to 3.208121. This amount is appropriate since the p value is equal to 0.0953. This shows that the possibility of incompetence occurrence is 0.09%. According to the results of the data analysis in the variance analysis table, each of the factors and their interactions affect the test results.

The correlation coefficient R 2 is an indicator to express the precision of regression and relation between the experimental data and predicted responses. High level of correlation coefficient (close to 1) is desirable. High level of R 2 indicates that, in fitted models, the predicted and experimental responses have adapted well to each other. In results analysis, the correlation coefficients are as below (Table 4):

Table 4 Error rates

Figure 7 is related to two-dimensional contour, and Fig. 8 indicates the three-dimensional surfaces of the model. As shown, the pollutant removal efficiency increases as temperatures and time increase. According to the contour and surface diagram, it can be realized that the removal rate is more sensitive to temperature factor. Actually, temperature is more effective in the removal rate compared to time. Therefore, higher removal efficiency can be achieved by increasing the temperature (compared to time). In surfaces, it can be observed that the surface towards the axis of temperature is slightly curved. This reflects the greater impact of temperature on the removal efficiency.

Fig. 7
figure 7

Contour diagram of temperature and time reaction on the removal efficiency

Fig. 8
figure 8

The surface describing the temperature and time reaction on the removal efficiency

Based on the mentioned points, the second-order polynomial overall model is as follows:

$$ \mathrm{Removal}\ \mathrm{rate}=-5.70387-0.4284\times \mathrm{Time}+0.0099119\times \mathrm{Temp}+0.009613\times \mathrm{Time}\times \mathrm{Temp}+0.002131 \times {\mathrm{Time}}^2-0.00199 \times {\mathrm{Temp}}^2 $$
(4)

After simplifying and eliminating the parameters with lower effect coefficient, with the assumption that t represents the time measured by day passes from the start of the extraction, T represents the temperature measured by Celsius scale, and “R.R” represents the removal rate, the formula will be as follows:

$$ \mathrm{R}.\mathrm{R}=-5.703-0.428 t+0.01 T\left(1+\mathrm{t}\right)+0.002\left({t}^2-{T}^2\right) t\ge 45, T\ge 65 $$
(5)

4 Conclusion

In this study, the remediation process of the sandy soils contaminated with n-alkanes (C13–C19) has been modeled based on the thermal optimization of vapor extraction through injecting the water vapor and pumping hot air. A neural network with 30 hidden layers and 15 epochs has been obtained to evaluate the data. This neural network provided a good and accurate prediction of time and removal efficiency.

The aim of the neural network was to validate data to prevent over-fitting. For this purpose, the existing data were divided into three categories: training, validation, and test. The mean error is equal to 4.2556, and the root mean square error is equal to 5.7303. It indicates the slight dispersion of modeling values around the actual values. The low rate of mean absolute error and root mean square error indicates that the error rate is very low. It also shows that the observed values are very close to the predicted values. The high rate of the correlation coefficient and R 2 confirms the same issue. Moreover, the removal rate presented by the model is equal to laboratory and actual values with a slight error. The general correlation coefficient of the model is equal to 0.967, and the correlation coefficient square is approximately 0.931. This is very close to 1 and indicates the proximity of the actual and calculated values.

According to the contour and surface diagrams and response surface diagrams related to parameter interaction, it can be concluded that, in all interactions, the removal rate increases by increasing the temperature and time. By increasing the temperature, the vapor pressure of volatile organic compounds in the soil increases. Therefore, evaporation and state changing from liquid to gas increase in unit of time. Time increases the duration of contact between air and vapor pumped to the injection wells and contamination. Therefore, it increases the contaminant removal rate. Consequently, this model can be used to predict the optimization rate of cleaning sandy soils through the vapor extraction method.

The effect of time factor on removal efficiency rate will have a more severe slope after about 80 days; therefore, it will be more effective. The reason is that, after passing this period from the beginning of the removal, the vapor pressure of volatile substances will be so that the state change will occur and the volatile substances will be extracted. For that reason, after 80 days, the removal rate and efficiency will increase. The slope of the effect of temperature on the removal of contaminant will decrease after almost 100 °C. The reason is that, as temperatures rise over 100 °C, the soil moisture evaporates and a significant amount of moisture in the soil is absorbed. Consequently, the contaminants that need to be solved in the water will not be absorbed and removed; hence, the removal efficiency will be reduced.