#### Abstract

The one-dimensional advection-diffusion-reaction equation is a mathematical model describing transport and diffusion problems such as pollutants and suspended matter in a stream or canal. If the pollutant concentration at the discharge point is not uniform, then numerical methods and data analysis techniques were introduced. In this research, a numerical simulation of the one-dimensional water-quality model in a stream is proposed. The governing equation is advection-diffusion-reaction equation with nonuniform boundary condition functions. The approximated pollutant concentrations are obtained by a Saulyev finite difference technique. The boundary condition functions due to nonuniform pollutant concentrations at the discharge point are defined by the quadratic interpolation technique. The approximated solutions to the model are verified by a comparison with the analytical solution. The proposed numerical technique worked very well to give dependable and accurate solutions to these kinds of several real-world applications.

#### 1. Introduction

Water quality must be protected and maintained for several uses, the principal ones being domestic water supply, energy production, industry, agriculture, fish, and wildlife. Mathematical modeling of the water pollution measurement and control in the water area has been examined. In [1], a simulation process showing that water pollution levels can be reduced to an agreed standard at the lowest cost is proposed.

In [2], mathematical modeling of the transport salinity, pollutants, and suspended matter in shallow water that involves the numerical solution of an advection-diffusion equation is proposed. A novel technique of finite difference methods is proposed. In [3], the authors also proposed a mathematical modeling of the transport salinity, pollutants, and suspended matter in shallow water that involves the numerical solution of an advection-diffusion equation in the technique of flux-corrected scheme of finite difference methods. It is available for the solution of the depth-integrated form of the advection-diffusion equation. In [4, 5], the advection and diffusion terms are solved by two different numerical methods.

In [6], the authors used a weighted discretization method with the modified equivalent partial differential equation for solving the one-dimensional advection-diffusion equation. In [7], the authors introduce the central difference approximation that gives some negative concentration in the neighboring cell due to a large advection flux. In [8], the authors proposed a numerical dispersion by introducing an upstream interpolation method, namely, QUICK (Quadratic Upstream Interpolation Convective Kinematics), for one-dimensional unsteady flow. In [9], parabolic partial differential equations with a nonstandard initial condition, featured in the mathematical modeling of many phenomena, are proposed. Saulyev’s explicit schemes are an economical implement to use. These unconditionally explicit schemes are very simple to program and compute. The new explicit schemes developed are very efficient and they need less CPU time than the implicit methods. The explicit finite difference schemes are very easy to implement for similar higher-dimensional problems. In [10], a user friendly and a flexible solution algorithm are proposed for the numerical solution of the one-dimensional advection-diffusion equation (ADE), and an explicit spreadsheet simulation (ESS) technique is used instead of a computer code. In the numeric solution of ADE using finite differences, either a small value of the Courant number such as 0.05–0.10 is used for oscillation-free results or an artificial diffusion is used in order to reduce oscillation. In order to provide for small Courant numbers, it is necessary to choose a small time step and/or grid size; however, this increases the computation time. While the proposed ADEESS solution technique uses an unconditional stable Saulyev scheme, it gives highly accurate results even for the values of the Courant numbers as high as 2-3. By varying only the values of the temporal weighted parameter , namely, 0, 0.5, and 1, respectively, the problems are solved. The model results for the value of appear to be in good agreement with the analytical solutions.

In [11], a better finite difference scheme to solve the dynamic one-dimensional advection-dispersion-reaction equations (ADRE) is focused upon, and the effect of nonuniform water flows in a stream is considered. There are two mathematical models used to simulate pollution due to sewage effluent. The first model is a hydrodynamic model for numerical techniques. The Crank-Nicolson method is used to approximate the solution. The second model is an advection-dispersion-reaction model; the explicit schemes are introduced. The revised explicit schemes are modified from two computation techniques of uniform flow stream problems: forward time central space (FTCS) and Saulyev schemes for the dispersion model. A comparison of both schemes regarding the stability aspect is provided so as to illustrate their applicability to the real-world problem.

The dispersion model provides the pollutant concentration field. In [12], a modified MacCormack method is subsequently employed in the dispersion model. The proposed method is a simply remarkable alteration to the MacCormack method so as to make it more accurate without any significant loss of computational efficiency. The results obtained indicate that the proposed modified MacCormack scheme does improve the prediction accuracy compared to the traditional MacCormack method. In [13], the authors proposed a simple revision to the MacCormack and Saulyev schemes that improves their accuracy for high Peclet number problems, which are named the Saulyev and MacCormack schemes, respectively, greatly improving the prediction accuracy over the original ones. They proposed a new scheme that guarantees the positivity of the solutions for arbitrary step sizes. In [14], they developed a numerical technique to approximate the solution of an advection-diffusion-reaction equation in one spatial dimension with constant velocity and diffusion. In [15], the Preissmann four-point partial-node implicit scheme is used to solve a one-dimensional hydrodynamic and water-quality model. In [16], a nondimensional form of a two-dimensional hydrodynamic model with a generalized boundary condition and initial conditions for describing the elevation of water wave in an open uniform reservoir is proposed. The separation of variables method with mathematical induction is employed to find an analytical solution to the model. In [17], the traditional Crank-Nicolson method is also used in the hydrodynamic model. At each step, the flow velocity fields calculated from the hydrodynamic model are the inputs into the water-quality model. A new fourth-order scheme and a Saulyev scheme are simultaneously employed in the water-quality model. In [18], the hydrodynamics model coupled with water quality is established by MIKE21FM software to simulate the current situation of Erhai Lake. The water quality is also simulated by the two-dimensional hydrodynamics and water-quality coupled model. The simple explicit schemes have the advantages of simplicity in computing without losing more accuracy and these schemes are precedent for several model applications. To identify the best one of these simple schemes, comparative studies of these are necessary.

The collected field data is not suitable to input into a mathematical model. The data is varied by time. The time-dependent distributions of discharged pollutant concentration and water flow velocity are required. It is complicated work if we input them into computer implementation while a given function has a simpler operation. The object of this research is to propose an interpolation technique to all of the collected field data such as water pollutant concentration at the released polluted water point and the water flow velocity along the considered water stream. The revision shows good agreement solutions. The proposed technique is suitable to be used in several real-world problems because it is easy to program and because of the straightforwardness of the implementation. According to field water-quality data, the data will be implemented to be a function of the boundary condition. The Lagrange interpolation technique is used to synthesize their boundary conditions as required. A simple advection-diffusion-reaction numerical simulation is proposed using the Saulyev scheme. The proposed numerical technique uses an unconditionally stable method. A large or small time step and/or grid size can be employed in the proposed techniques. We apply the method to two problems with different data for obtaining the right and left boundary conditions. The results of the model show that the calculated results are reliable approximations.

#### 2. One-Dimensional Water-Quality Model

##### 2.1. The Governing Equation

In this section, we consider the parabolic equation. The mathematical model describing the transport and diffusion processes is a one-dimensional advection-diffusion-reaction equation (ADRE):

##### 2.2. Initial and Boundary Conditions

The initial condition isand boundary conditions arewhere is the longitudinal distance along the stream, is time, is the last time, and , , and are interpolated functions, while is the concentration averaged in depth at the point and at time , is the water flow velocity in the direction for all at time , is the dispersion coefficient, and is the mass decay rate.

#### 3. Numerical Technique

##### 3.1. An Explicit Finite Difference Technique

The solution domain of the problem is covered by a mesh of grid lines. The grid point is defined by for all and for all in which and are positive integers, where and are parallel to the space and time coordinate axes. The constant spatial and temporal grid spacing are and .

Consider the following approximations of the derivative in the advection-diffusion equation which incorporate time weights as follows [10]:where is the weighting factor. Substituting (4) into (1), we get [10]for and , where is Courant number and is Peclet number.

Although (5) does not seem explicit, because and are on the left-hand side, a suitable use of the equation makes it explicit.

Therefore, (5) can be written in the following form:For the advection term, we apply the scheme of either or . Thus, the scheme is restricted to single-direction velocity fields, with being transported from left to right by the flow, so the Saulyev scheme is the appropriate choice for discretizing the advective term. In (6), the term at time level , , has already been computed at spatial point by marching in the direction of increasing . This scheme is an explicit finite difference method. In this case, only a single value, , will be unknown. This scheme is known as Saulyev’s formula and the main advantage of it is that it is unconditionally stable and explicit [10].

##### 3.2. Iterative Method for the Initial and Boundary Conditions

*Interpolation*

Theorem 1 (Weierstrass approximation theorem, [19]). *Suppose that is defined and continuous on For each there exists a polynomial , with the property that , for all in *

The Taylor polynomials agree as closely as possible with a given function at a specific point, but they concentrate their accuracy near that point. A good interpolation polynomial needs to provide a relatively accurate approximation over an entire interval, and Taylor polynomials do not generally do this. The Taylor polynomials are [19]For the Taylor polynomials, all the information used in the approximation is concentrated at the single number , so these polynomials will generally give inaccurate approximations as we move away from . This limits Taylor polynomial approximation to the situation in which approximations are needed only at numbers close to . For ordinary computational purposes, it is more efficient to use methods that include information at various points. The primary use of Taylor polynomials in numerical analysis is not for approximation purposes, but for the derivation of numerical techniques and error estimation.

*Lagrange Interpolating Polynomials. *The problem of determining a polynomial of degree one that passes through the distinct points and is the same as approximating a function for which and by means of a first-degree polynomial interpolation, or agreeing with the values of at the given points. Using this polynomial for approximation within the interval given by the endpoints is called polynomial interpolation. Define the functionsThe linear Lagrange interpolating polynomial through and isNote thatwhich implies thatThen, is the unique polynomial of degree at most one that passes through and In this case, we first construct, for each , a function with the property that , when and . To satisfy for each , it is required that the numerator of contains the term

To satisfy , the denominator of must be this same term but evaluated at . Thus,

Theorem 2 (see [19]). *If are distinct numbers and is a function whose values are given at these numbers, then a unique polynomial of degree at most exists with , for each **This polynomial is given bywhere, for each ,We will write simply as when there is no confusion as to its degree.*

Theorem 3 (see [19]). *Suppose are distinct numbers in the interval and . Then, for each in , a number (generally unknown) between , and hence in , exists withwhere is the interpolating polynomial given in (13). The error formula in (15) is an important theoretical result because Lagrange polynomials are used extensively in numerical differentiation and integration methods.*

The error in applied mathematics is the difference between a true value and an estimate, or the approximation of that value. In numerical analysis, round-off error is exemplified by the difference between the true values of the irrational number. The approximation error in some data is the discrepancy between an exact value and some approximation to it. An approximation error can occur because the measurement of the data is not precise because instruments and approximations are used instead of the real data. In (14), it is implied that the error in linear interpolation is , where is the interpolating polynomial.

Interpolating the th Lagrange interpolation polynomial can be described in a simpler form as . It is difficult to interpolate a river channel, because it has unknown functions of initial conditions and boundary conditions. The interpolation of field data uses (15) for interpolating (6). Use every 3 nodes that are distinct numbers in the interval by an iterative explicit finite difference technique to find the second Lagrange interpolation polynomial for , where is the interpolating polynomial [19].

#### 4. Numerical Experiments

Suppose that the measurement of pollutant concentration in a nonuniform flow stream is aligned with longitudinal distance, 1.0 (km) total length and 1.0 (m) depth. There is a plant which discharges wastewater into the stream and the pollutant concentrations at the discharge point are and at for all and at . The analytical solution to the one-dimensional advection-diffusion equation at is given asPrediction of field data at the boundary can be obtained using a quadratic interpolated initial and boundary condition (see (13)). The interpolation is used to interpolate the right boundary condition, the left boundary condition, and the initial condition: for all and at , where , and are interpolated functions.

The approximation of pollutant concentrations is obtained using a Saulyev finite difference technique (see (6)) with the interpolated initial-boundary condition functions (see (17) and (18)). The calculated results are shown in Tables 1–3 and Figures 1–6.

#### 5. Discussion

In this research, the approximation of the pollutant concentrations of a simple advection-diffusion reaction numerical simulation using the Saulyev schemes is shown in Tables 1–3 and Figures 1–6. The numerical techniques are proposed for three values: 0, 0.5, and 1, respectively. The case of gives a smooth solution compared to other values. Increasing the mass decay rate affects the maximum concentration level. The interpolation results must be crude mesh as field data. The numerical results can be fine mesh or crude mesh. In Table 1 and Figures 1–5, we can see that the maximum errors of approximated pollutant concentration are reducing while the Peclet numbers are decreased. The maximum error of analytical and interpolation technique is shown in Table 2; the right boundary condition is , the left boundary condition is , and the initial condition is . Comparison of the analysis and interpolation technique is shown in Figures 1–6. The proposed numerical interpolation technique gives good agreement results. The accuracy of the Lagrange interpolation technique is used to predict their initial and boundary conditions as needed.

#### 6. Conclusion

The proposed Saulyev finite difference scheme with the quadratic interpolation to the initial-boundary conditions technique is an unconditionally stable finite difference method. A large or small time step and/or grid size can be employed in the proposed techniques. The numerical experiment shows that the calculated results are reasonable approximations. The revision shows good agreement solutions. The proposed interpolation technique is suitable to be used in the real-world problem because it is easy to computer-code and because of the straightforwardness of the computer implementation. According to the collected water-quality data, functions that satisfy boundary conditions must be implemented. The computed results are verified by the numerical accuracy. The proposed technique gives reliable solutions to these processes.

#### Conflicts of Interest

The authors declare no conflicts of interest.

#### Acknowledgments

The authors appreciate the financial support from the Centre of Excellence in Mathematics, Commission on Higher Education, Thailand. They also greatly appreciate the valuable comments received from Professor Chatchai Leenawong.