Introduction

Pollution of water in rivers, lakes, and underground reservoirs is one of the serious concerns in the environmental field (Al-Mamun et al. 2018; Osman 2020). This infection is usually due to human activities; industrial and domestic contaminates are the main causes of water pollution (Farahbod et al. 2012; Osman 2020). Information about the consequences of pollution and its prediction through the modeling process can play an important role in controlling and eliminating contamination (Rathinam et al. 2018). The use of adsorbents, especially nano-adsorbents, can play a significant role in reducing water pollution (Mo et al. 2018). Also, if nano-adsorbents with magnetic properties are used, the process of removing contaminants from the water will be accelerated (Chen et al. 2019; Abdel Maksoud et al. 2020). Moreover, the researches show that the use of membranes in bioreactors to remove sludge contaminants can be effective (Zhang and Jiang 2019). Also, if mineral salts such as calcium and magnesium are dissolved in the water stream, the use of zeolites can play a significant role in softening the water flow (El-Nahas et al. 2020). But in general, it is necessary to examine this issue due to its importance and because it is vital to predict the amount and type of pollution to purify water flow and eliminate pollutants in many cases (Taherizadeh et al. 2020). In any case, understanding the mechanism of entry and distribution of pollution in water flow using the rules of mass transfer and the mechanisms of movement of matter plays a significant role in predicting the amount of pollution and accurate calculation of water pollution at any time and any location (Lu et al. 2020; Long 2020). The contaminants after getting into the water gradually spread and contribute as a part of flow (Karandish et al. 2020). The emissions are created irreversibly and nonuniform by diffusion and convection into two directions (Wu and Ye 2020): (1) In parallel with the flow of water, greenhouse gas emissions are dominant in this case, through the convection mechanism and the penetration of emissions can be ignored. (2) Perpendicular to the water flow, in this case emissions follow the variation of particles in water, and the contaminant emission by diffusion is the dominant mechanism (Zou and He 2018). The water flow morphology can affect volumetric and diffusion mechanisms commonly found in contamination phenomena (Zuo et al. 2018). Therefore, recognizing all the variables affecting the rate of pollution penetration will make a better assessment of this phenomenon of mass transfer (Fu et al. 2020). In general, because the research on calculating the exact amount of pollutants entering the water flow is very rare, therefore, in this study, a mathematical model with the aim of accurately predicting the amount of greenhouse gases introduced into the water flow has been studied. Therefore, this study investigates the concentration of the greenhouse gases as pollutants in the flow of water at the desired location and time. Finally, the diffusion and decomposition of pollutants are investigated in this paper, theoretically.

Mathematical modeling

Since the rate of change in the concentration of pollutants during water flow and time is significant, therefore, in this study, the rate of changes in the concentration of pollutants along the waterway and over time has been studied. In other words, what is important from an engineering point of view in this study is the study of changes in the concentration of pollutants along different lengths of the water flow path over time. Also, due to laboratory limitations, it is not possible to conduct practical studies in all spatial dimensions at different times. Finally, it will not be possible to compare operational data with the results of the theoretical model. However, since some tests have been performed on a case-by-case basis to determine the amount of pollution along the length at different times, the results of experimental measurements show a very good correlation with the model’s theoretical data.

In fact, the main aim of this part is expression of mathematical model for diffusion of contaminants into the water stream. The physical principles and simple assumptions are expressed by mass balance equations for modelling of pollutants diffusion.

Also, the simplistic assumptions used in this modeling are as follows:

  1. 1.

    One-dimensional or two-dimensional flow is considered.

  2. 2.

    The diffusion of contaminants is considered to be at nonsteady state.

  3. 3.

    The constant temperature is assumed. Therefore, there is no need to solve the energy equation.

  4. 4.

    Pressure drop is neglected. Therefore, there is no need to solve the momentum equation for pressure changes.

  5. 5.

    Parameters such as water velocity, diffusion coefficient of contaminants, and reaction rate are assumed as a constant.

  6. 6.

    It is assumed that emissions will participate in a chemical reaction.

On the base of simple assumptions by writing mass balance for the element of dx in water flow, differential equations were obtained for pollutant density. By solving the equations, density distribution of pollutants was achieved versus time and length of the water flow path.

Results and discussion

Investigation of pollutants emission

The important gaseous pollutants such as SO2, NO, NO2, CO, O3, total oxidants, and total hydrocarbons are considered greenhouse gases. These gases cause rapid destruction of atmospheric layers and a relative increase in global temperature. In other words, this study investigates the concentration of these pollutants in the flow of water at the desired location and time. Therefore, the diffusion and decomposition of pollutants are investigated in this paper, theoretically.

The conditions that affect the diffusion and decomposition of pollutants are so variable. So, boundary conditions and mathematical models are required to determine this subject, meticulously. As shown, the typical flow chart of model is illustrated in Fig. 1.

Fig. 1
figure 1

Typical flow chart of model

One-dimensional modeling for pollutant emission in nonsteady state

One-dimensional flow of water is shown in Fig. 2. For example, the water is polluted in upstream. The contaminant is released downstream and partially decomposed by the chemical reactions. In this section, the mass conservation equation was used for the density of contaminants. The solving of the equation was carried out in numerical method by the MATLAB 9.4 software, and densities of contaminants were plotted as a function of time and location for two- and three-dimensional chart.

Fig. 2
figure 2

Polluted flow in upstream

Consider dx in the distance of x from water flow, the amount of mass transfer flux at the distance of x and x + dx can be written as

$$ {N}_x=j+ VC $$
(1)
$$ {N}_{x+ dx}={N}_x+\frac{{\delta N}_x}{\delta_x} dx $$
(2)

In Eqs. 1 and 2, N represents the mass transfer flux, j is diffusion flux, V is velocity, and C is the concentration of pollutant. Also, in Eq. 2, to get the mass transfer flux at x + dx , the linear section of Taylor expansion was used. The Fick’s law with a constant rate \( {\mathit{\mathsf{N}}}_{\mathit{\mathsf{x}}+\mathit{\mathsf{dx}}} \) is used for obtaining diffusion motion. In addition, the j can be calculated from Eq. 3.

$$ {N}_{x+ dx}={N}_x+\mathrm{V}\frac{\delta \mathrm{C}}{\delta_x} dx-D\frac{\partial^2C}{{\partial x}^2} dx $$
(3)

The parameter D is diffusion coefficient of contaminates. However, the mass balance between z and z + dz consider as the following:

Mass concentration = mass production and mass consumption ± output - input

The mass balance can be written as Eq. 4:

$$ {N}_xA-{N}_{x+ dx}A- RAdx=A9=\left(\frac{d\mathrm{C}}{dt}\right)\mathrm{dx} $$
(4)

In this equation, parameter of A refers to the surface area and R is the rate of disappearance of pollutants that can be irreversibly and primarily decomposed according to Eq. 5:

$$ R= kC\left(x,t\right) $$
(5)

The parameter k is the decomposing factor of the pollutant. By combining Eqs. 3, 4, and 5, the overall relationship of pollutants in water flow is reached:

$$ D=\frac{\partial^2C\left(x,t\right)}{{\partial x}^2}-V\frac{\delta \mathrm{C}\left(\mathrm{x},\mathrm{t}\right)}{\delta x}- kC\left(x,t\right)=\frac{d\mathrm{C}\left(\mathrm{x},\mathrm{t}\right)}{dt} $$
(6)

The values of input parameters for the solution as well as constant values presented in Table 1.

Table 1 Input parameters for solution of equation

In addition, the concentration of pollutants in the beginning of the path is considered as following Eq. 7:

$$ C\left(x,0\right)=\left\{\begin{array}{l}2\sin \left(\frac{\pi x}{2}\right),\kern0.5em x\le 2\\ {}0\kern0.5em ,x>2\end{array}\right. $$
(7)

Equation 6 was solved in the MATLAB 9.4, numerically. The implicit method was used for solving the equations. The results of the model for the one-dimensional were offered, and the effect parameters such as diffusion of contaminants, reaction rate constant, and flow speed on the emissions were investigated.

Results of one-dimensional model as function of time and location

In Figs. 3, 4, and 5, contaminant density distribution is shown as a function of time and the length of the path. As shown in Fig. 3, the concentration of the pollutants is high, and a bit of path is contaminated, but over the time, the water path is more infected with reduced concentration. The concentration of the path is reached in the amount of 0.2 mmol/cm3, which is close in concentration close to high water flow. Figure 4 shows the three-dimensional graph of the concentration of contaminants in the terms of time and location. In addition, Fig. 5 shows the concentration of pollution in relation to the length of the water and time path.

Fig. 3
figure 3

Distribution of pollutant concentration as a function of length of water path in different times

Fig. 4
figure 4

Three-dimensional distribution of pollutant concentration as a function of length of water path and time

Fig. 5
figure 5

Two-dimensional counter of pollutant concentration as a function of length of water path and time

Figure 3 shows that the contaminant concentration is in contrast with time and length of water flow. As shown in Fig. 3, the maximum and minimum pollutant concentrations occurred at the time of 0.0 and 200 s of the contact.

Figure 4 shows three-dimensional diagram of the pollutant concentration in terms of time and location. As shown in Fig. 4, the fluctuation of contaminant concentration in the length of 0.0 to 2.0 m is high. Also, the variation of time versus length is investigated in Fig. 5. Figure 5 shows two-dimensional contour (partition) of pollutant concentration in terms of time and location. The fluctuation will grow in the x > 10m as length of the water path.

Figure 6 shows the effect of increasing mass transfer coefficient from D = 0 to D = 2 m2/s on the concentration distribution in the x direction and at the different times. As it is clear that, by increasing the mass transfer coefficient, the concentration of pollutants is distributed, but it will not move the wave of pollutants forward. The coefficient of mass transfer in this special case is proportional to the diffusion coefficient and inversely proportional to the film. This phenomenon is commonly known as the film theory. This is because that the transfer of low-penetration mass is comparable with cannery mass transfer and chemical reactivity.

Fig. 6
figure 6

The effect of mass transfer coefficient increscent on concentration distribution in x direction and different times

Figure 7 shows the effect of increasing water velocity from V = 0 to V = 0.2 m/s on the distribution of contaminant concentration in the x direction at different times. As shown, if the flow velocity is equal to zero, the wave of pollution does not move forward but only distributed by diffusion mass transfer as well as consumed by chemical reaction. With increasing water velocity, the emission wave moves faster towards the water flow, so the water flow was polluted more quickly. For example, when the speed is 0.2 m/s, the concentration after 60 s is reached to steady state and the final length is 10 m, but in the case of speed 0.1 m/s, this event occurred after 200 s.

Fig. 7
figure 7

The effect of speed in crescent on concentration distribution in x direction and different times

Figure 8 shows the effect of a reaction rate constant increasing (from k = 0 to k = 0.04 min−1) on the distribution of contaminant concentration in the x direction at different times. If the constant reaction rate was zero, there is no use of mass inside the system, so the total mass of pollutants is liberated by water diffusion. By increasing the reaction rate constant, there is no pollutant wave in the longitudinal direction, but the wave height will be reduced due to the mass consumption. In the case of reaction rate constant, k = 0.04 min−1, after 200 s, the total amount of pollutants consumed at the end of the path by the chemical reaction and concentration reaches to zero in the port.

Fig. 8
figure 8

The effect of reaction rate constant increscent on concentration distribution in x direction and different times

Two-dimensional modeling for pollutant emission in nonsteady state

Suppose a two-dimensional current of water flow according to Fig. 2. In this case, spread of pollutants occurred in the direction of water and perpendicular direction. If the element has a length of dx and width of the dy, ultimately Eq. 8 for two-dimensional flow will be derived:

$$ D\frac{\partial^2C\left(x,\mathrm{y},t\right)}{{\partial x}^2}+D\frac{\partial^2C\left(x,\mathrm{y},t\right)}{{\partial y}^2}-{V}_x\frac{\delta \mathrm{C}\left(\mathrm{x},\mathrm{y},\mathrm{t}\right)}{\delta_x}-{V}_y\frac{\delta \mathrm{C}\left(\mathrm{x},\mathrm{y},\mathrm{t}\right)}{\delta_y}- kC\left(x,y,t\right)=\frac{d\mathrm{C}\left(\mathrm{x},\mathrm{y},\mathrm{t}\right)}{dt} $$
(8)

Because the velocity is negligible in perpendicular direction of flow, so the displacements term of direction y in the equation of conservation of mass neglected and we finally reached Eq. 9. By solving this equation, pollutant concentration distribution as a function ofx, y and the time were obtained. Initial and boundary conditions for the solution Eq. 9 are considered in Eq. 10. Equation 9 can be written as

$$ D\frac{\partial^2C\left(x,\mathrm{y},t\right)}{{\partial x}^2}+D\frac{\partial^2C\left(x,\mathrm{y},t\right)}{{\partial y}^2}-{V}_x\frac{\delta \mathrm{C}\left(\mathrm{x},\mathrm{y},\mathrm{t}\right)}{\delta_x}- kC\left(x,y,t\right)=\frac{d\mathrm{C}\left(\mathrm{x},\mathrm{y},\mathrm{t}\right)}{dt} $$
(9)

And Eq. 10:

$$ {\displaystyle \begin{array}{l}C\left(\mathrm{x},\mathrm{y},0\right)=0\\ {}\begin{array}{l}C\left(0,\mathrm{y},\mathrm{t}\right)=0\\ {}\begin{array}{c}C\left(\mathrm{x},0,\mathrm{t}\right)=\left\{\begin{array}{c}2\sin \left(\frac{\pi }{2}x\right),\kern0.5em x\le 2,\mathrm{t}\le 40\ \sec \\ {}\begin{array}{cc}0.2,\kern0.95em ,& \mathrm{x}>2\end{array}\end{array}\right.\\ {}\begin{array}{l}\frac{\partial C\left(10,y,\mathrm{t}\right)}{\partial_x}=0\\ {}\frac{\partial C\left(x,2,\mathrm{t}\right)}{\partial_y}=0\end{array}\end{array}\end{array}\end{array}} $$
(10)

In this case, it is assumed that the flow for 40 s in y = 0 is exposed to contaminants wave, and after 40 s, the wave was removed.

Results of two-dimensional model as function of time and location

The distribution of contaminant density until 35 s when the flow exposed to the pollutant wave is shown in Figs. 9 and 10, which show the distribution of the contaminant concentration in the wave after the removal of the wave. As shown in Fig. 9, increasing the time results in contaminant diffuse in both directions x and y by the wave removing in 40th second; the concentration of pollutant wave reduced gradually (consider the dimensions of the z axis).

Fig. 9
figure 9

Three-dimensional distribution of pollutant concentration before the removing of pollutant wave

Fig. 10
figure 10

Three-dimensional distribution of pollutant concentration after the removing of pollutant wave

Figure 10 shows the concentration diffusion of pollutant in two dimension of location and also the time. As shown in Fig. 10, 40 s is a critical time for maximum pollutant concentration. In other words, increasing in time can remove contaminant concentration by chemical reaction mechanism, diffusion, and volume mechanism. So, the concentration of contaminant in dimensions of x and y is investigated in this figure.

Figure 11 demonstrates two-dimensional distribution of concentration on the x direction and y = 1 at different times.

Fig. 11
figure 11

Two-dimensional distribution of concentration in x direction, y = 1, and different times

As shown in Fig. 11, increasing the time until 40 s results in density amplifier in the directions x and z by the wave removing after 40 s, and because of pollutant consumption by chemical reaction and transfer by diffusion and convection, the concentration of pollutant wave reduced. In fact, the critical time is 40 s, which is effective in wave removal. So, the variation of the concentration of pollutant is shown in Fig. 11.

Figure 12 demonstrates the distribution of concentration on the x direction and y = 1 at different times without removing the wave. The pollutant concentration will increase by increasing contact time from 0.003 to 0.197 mmol/cm3. In this case, as expected, the value of concentration in the x direction is always increasing, and on the contrary to the previous mode, there is a reduction. The amount of concentration of pollutant will increase in the different time without removing the wave (in Fig. 12 rather than in Fig. 11). So, the effect of wave removing is shown by comparison of pollutant concentration in different path stream.

Fig. 12
figure 12

Two-dimensional distribution of concentration in x direction, y = 1, and different times

Conclusion

Two models are defined to predict the diffusion of contaminants in the water stream. The first one is one-dimensional and the second is two-dimensional. The results are achieved for one-dimensional state; the concentration of the path is reached in the amount of 0.2 mmol/cm3, which is close in concentration near the upstream flow. For second model, it can be concluded that increasing the time results in contaminant diffuse in both directions x and y by the wave removing in 40th second; the concentration of pollutant wave reduced gradually (consider the dimensions of the z axis). In addition, increasing the time until 40 s results in density booster in directions x and z by the wave removing after 40 s, and because of pollutant consumption by chemical reaction and transfer by diffusion and convection, the concentration of pollutant wave reduced.