Computational study of the convection-diffusion equation using new cubic B-spline approximations

Abstract: This paper introduces an efficient numerical procedure based on cubic B-Spline (CuBS) with a new approximation for the second-order space derivative for computational treatment of the convection-diffusion equation (CDE). The time derivative is approximated using typical finite differences. The key benefit of the scheme is that the numerical solution is obtained as a smooth piecewise continuous function which empowers one to find approximate solution at any desired position in the domain. Further, the new approximation has considerably increased the accuracy of the scheme. A stability analysis is performed to assure that the errors do not magnify. Convergence analysis of the scheme is also discussed. The scheme is implemented on some test problems and the outcomes are contrasted with those of some current approximating techniques from the literature. It is concluded that the offered scheme is equitably superior and effective.


Introduction
The convection-diffusion equation(CDE) governs the transmission of particles and energy caused by convection and diffusion. The CDE is given by

Materials and method
Derivation of the scheme Define ∆t = T N to be the time and h = d−c M the space step sizes for positive integers M and N. Let t n = n∆t, n = 0, 1, 2, ..., N, and z j = jh, j = 0, 1, 2...M. The solution domain c ≤ z ≤ d is evenly divided by knots z j into M subintervals [z j , z j+1 ] of uniform length, where c = z 0 < z 1 < ... < z n−1 < z M = d. The scheme for solving (1.1) assumes approximate solution V(z, t) to the exact solution v(z, t) to be [23] V(z, t) = M+1 j=−1 D j (t)B 3 j (z), (2.1) where D j (t) are unknowns to be calculated and B 3 j (z) [23] are cubic B-spline basis functions given by Here, just B 3 j−1 (z), B 3 j (z) and B 3 j+1 (z) are last on account of local support of the cubic B-splines so that the approximation v n j at the grid point (z j , t n ) at n th time level is given as V(z j , t n ) = V n j = k= j+1 k= j−1 D n j (t)B 3 j (z). (2.3) The time dependent unknowns D n j (t) are determined using the given initial and boundary conditions and the collocation conditions on B 3 j (z). Consequently, the approximations v n j and its required derivatives are found to be        v n j = α 1 D n j−1 + α 2 D n j + α 1 D n j+1 , (v n j ) z = −α 3 D n j−1 + α 4 D n j + α 3 D n j+1 , (2.4) where The new approximation [24] for (v n j ) zz is given as (v n 0 ) zz = 1 12h 2 (14D n −1 − 33D n 0 + 28D n 1 − 14D n 2 + 6D n 3 − D n 4 ), (v n j ) zz = 1 12h 2 (D n j−2 + 8D n j−1 − 18D n j + 8D n j+1 + D n j+2 ), j = 1, 2, ..., M − 1 (v n M ) zz = 1 12h 2 (−D n M−4 + 6D n M−3 − 14D n M−2 + 28D n M−1 − 33D n M + 14D n M+1 ), (2.5) The problem (2.1) subject to the weighted θ-scheme takes the form where h n j = ϑ(v n j ) zz − ω(v n j ) z and n = 0, 1, 2, 3, .... Now utilizing the formula, (v n j ) t = v n+1 j −v n j k in (2.6) and streamlining the terms, we obtain v n+1 Observe that θ = 0, θ = 1 2 and θ = 1 in the system (2.7) correspond to an explicit, Crank-Nicolson and a fully implicit schemes respectively. We use the Crank-Nicolson approach so that (2.7) is evolved as v n+1 Subtituting (2.4) and (2.5) in (2.8) at the knot z 0 returns From (2.9), (2.10) and (2.11), we acquire a system of (M + 1) equations in (M + 3) unknowns. To get a consistent system, two additional equations are obtained using the given boundary conditions. Consequently a system of dimension (M + 3) × (M + 3) is obtained which can be numerically solved using any numerical scheme based on Gaussian elimination. Initial State: To begin iterative process, the initial vector D 0 is required which can be obtained using the initial condition and the derivatives of initial condition as follows: (2.12) The system (2.12) produces an (M + 3) × (M + 3) matrix system of the form where,

Convergence analysis
In this section, we present the convergence analysis of the proposed scheme. For this purpose, we need to recall the following Theorem [21,22]: and V * (z) be the unique B-spline function that interpolates v. Then there exist constants λ i independent of h, such that First, we assume the computed B-spline approximation to (2.1) as For this purpose, we rewrite the equation (2.8) as: can be written in matrix form as: where, R = ND n + h and If we replace v * by V * in (3.4), then the resulting equation in matrix form becomes Subtracting (3.6) from (3.5), we obtain Now using (3.4), we have From (3.8) and Theorem (1), we have It is obvious that the matrix A is diagonally dominant and thus nonsingular, so that Now using (3.9), we obtain Let a j,i denote the entries of A and η j , 0 ≤ j ≤ M + 2 is the summation of jth row of the matrix A, then we have From the theory of matrices we have, where a −1 k, j are the elements of A −1 . Therefore Substituting (3.13) into (3.11) we see that where M 2 = M 1 |ξ l | is some finite constant.
Proof. Consider, Then, we have as required.

Now, consider
Using (3.14) and Theorem 2, we obtain

Applications of numerical scheme
In this section, some numerical calculations are performed to test the accuracy of the offered scheme.
In all examples, we use the following error norms The numerical order of convergence p is obtained by using the following formula: where L ∞ (n) and L ∞ (2n) are the errors at number of partition n and 2n respectively.

22)
with IC, v(z, 0) = exp(5z) sin(πz) (3.23) and the BCs, The analytic solution of the given problem is v(z, t) = exp(5z − (0.25 + 0.01π 2 )t) sin(πz). To acquire the numerical results, the offered scheme is applied to Example 1. The absolute errors are compared with those obtained in [25] at various time stages in Table 1. In Table 2, absolute errors and error norms are presented at time stages t = 5, 10, 100. Figure 1 displays the comparison that exists between exact and numerical solutions at various time stages. Figure 2 depicts the 2D and 3D error profiles at t = 1. A 3D comparison between the exact and numerical solutions is presented to exhibit the exactness of the scheme in Figure 3.      The approximate solution when t = 1, k = 0.01 and M = 20 for Example 1 is given by  The analytic solution is v(z, t) = exp(0.22z − (0.0242 + 0.5π 2 )t) sin(πz). The numerical results are obtained by utilizing the proposed scheme. In Table 3, the comparative analysis of absolute errors is given with that of [25]. Absolute errors and errors norms at time levels t = 5, 10, 100 are computed in Table 4. Figure 4 shows a very close comparison between the exact and numerical solutions at various stages of time. Figure 5 plots 2D and 3D absolute errors at t = 1. In Figure 6, a tremendous 3D contrast between the exact and approximate solutions is depicted.     The numerical solution when t = 1, k = 0.01 and M = 20 for Example 2 is given by z ∈ [ 17 20 , 9 10 ] −0.0199915 + 0.108568z − 0.129703z 2 + 0.0411262z 3 , z ∈ [ 9 10 , 19 20 ] −0.0196901 + 0.107616z − 0.128701z 2 + 0.0407746z 3 , z ∈ [ 19 20 , 1].

Conclusions
This research uses a new approximation for second-order derivatives in the cubic B-spline collocation method to obtain the numerical solution of the CDE. The smooth piecewise cubic B-splines have been used to approximate derivatives in space whereas a usual finite difference has been used to discretize the time derivative. Special consideration is paid to the stability and convergence analysis of the scheme to ensure the errors do not amplify. The approximate solutions and error norms are contrasted with those reported previously in the literature. From this analysis, we can conclude that the estimated solutions are in perfect accord with the actual solutions. The scheme can be applied to a wide range of problems in science and engineering.