A New Trigonometric Spline Approach to Numerical Solution of Generalized Nonlinear Klien-Gordon Equation

The generalized nonlinear Klien-Gordon equation plays an important role in quantum mechanics. In this paper, a new three-time level implicit approach based on cubic trigonometric B-spline is presented for the approximate solution of this equation with Dirichlet boundary conditions. The usual finite difference approach is used to discretize the time derivative while cubic trigonometric B-spline is applied as an interpolating function in the space dimension. Several examples are discussed to exhibit the feasibility and capability of the approach. The absolute errors and error norms are also computed at different times to assess the performance of the proposed approach and the results were found to be in good agreement with known solutions and with existing schemes in literature.


Introduction
The generalized nonlinear Klien-Gordon (KG) equation arises in various problems in science and engineering. This paper focuses on the analysis and numerical solution of the generalized nonlinear KG equation, which is given in the following form [14]: where u~u x,t ð Þ denotes the wave displacement at position and time x,t ð Þ, a and b are real constants, G u ð Þ is a nonlinear function of u and f x,t ð Þ, v 1 x ð Þ, v 2 x ð Þ, w 1 t ð Þ and w 2 t ð Þ are known functions.
In particular, the KG equation is important in mathematical physics especially in quantum mechanics and it is well known as a soliton equation. A study on the interaction of soliton in collisionless plasma, the recurrence of initial states and examination of the nonlinear wave equations was in [1].
Several methods, in addition to several finite difference schemes, have been developed to solve the nonlinear KG equation. Jiminez and Vazquez [2] introduced four numerical schemes for solving the nonlinear KG equation. Ming and Guo utilized a Fourier collocation method for solving the nonlinear KG equation [3]. The KG equation was approximated using decomposition scheme by Deeba and Khuri [4] and using the Legendre spectral method by Guo et al [5]. Wong et. al. solved an initial value problem involving the nonlinear KG equation using fully implicit and discrete energy conserving finite difference scheme [6]. Wazwaz introduced the tanh and sine-cosine method to obtain compact and noncompact solutions for the nonlinear KG equation [7]. Sirendaoreji solved the nonlinear KG equation using the auxiliary equation method to construct new exact traveling wave solutions with quadratic and cubic nonlinerity [8]. Yucel solved the nonlinear KG equation using homotopy analysis method [9] and Chowdhury and Hashim solved the equation using homotopy-pertubation method [10].
B-spline functions can be used to solve numerically linear and non-linear differential equations. Caglar et. al. [11] has introduced a cubic B-spline interpolation method to solve the two-point boundary value problem. Hamid et al. [12] has introduced an alternative cubic trigonometric B-spline interpolation method to solve the same problem. Dehghan and Shokri [13] have obtained a numerical solution of the nonlinear KG equation using Thin Plate Splines radial basis functions. Khuri and Sayfy [14] have solved the generalized nonlinear KG equation using a finite element collocation approach based on third degree B-spline polynomials.
In this work, a new three-time level implicit approach which combines a finite difference approach and cubic trigonometric Bspline collocation method (CTBCM) is proposed to solve generalized nonlinear KG equation. The finite difference approach is proposed to discretize time derivative and cubic trigonometric collocation method is applied to interpolate the solutions at timet. Two numerical experiments are carried out to calculate the numerical solutions, absolute errors, L ? error norms and order of convergence for each problem in order to show the accuracy of method.

Temporal Discretization
Consider a uniform mesh V with grid points (x j ,t k ) to discretize the grid region D~½a,b|½0,T with x j~a zjh, j~0,1,2,:::,n and t k~k Dt, k~0,1,2,3,:::,N, T~NDt: h and Dt denote mesh space size and time step size respectively. The time derivative is approximated using the central finite difference formula Using the approximation of equation (4), equation (1) becomes  Using the h{weighted technique, the space derivatives of equation (5) becomes and the subscripts k and kz1 are successive time levels.
After simplification, equation (6) leads to Trigonometric B-Spline Collocation method In this section, CTBCM is used to solve Klien-Gordon equation. Cubic trigonometric B-spline are used to approximate the space derivatives. To construct the numerical solution, nodal points (x j ,t k ) defined in the region a,b The approximate solution u x,t ð Þ to the exact solution u u x,t ð Þ is defined as [18]: where C j t ð Þ are time dependent unknowns to be determined and T 4,j (x) are cubic trigonometric B-spline basis function given as: where Due to local support properties of B-spline basis function, there are only three non-zero basis functions T 4,j{3 (x j ), T 4,j{2 (x j ) and T 4,j{1 (x j ) are included over subinterval ½x j ,x jz1 : Thus, the approximation u k j and its derivatives with respect to x can be simplified as: where The solution to problem (1) is obtained by substituting equation (10) into equation (7). Initially, time dependent unknowns C 0 are calculated and shown in section 3.1. Next, the following initial condition is substituted into the last term of equation (7) for Subsequently, the time dependent unknowns, C k for k §1 should be generated. After simplification, equation (7) leads to where, The system obtained on simplifying (11) consists of nz3 in nz1 linear equations at the time level t~t kz1 : In order to obtain a unique solution, the equation (8) is applied to the boundary conditions given in equation (3) for two additional linear equations.
From equations (11), (12) and (13), the system can be written as where, Half explicit and half implicit scheme is produced by choosing h to be 0.5. This scheme is known as Crank-Nicolson scheme. System (14) becomes a tri-diagonal matrix system of dimension (nz3)|(nz3) that can be solved using the Thomas Algorithm [17]. Initial vector C 0 The initial vectors C 0 can be obtained from the initial condition as well as boundary values of the derivatives of the initial condition [11,15]: This yields a (nz3)|(nz3)matrix system: The solution can be obtained by using the Thomas Algorithm [17].

Stability analysis using von Neumann method
The von Neumann analysis of stability considers the growth of error in a single Fourier mode [19][20] where i~ffi ffiffiffiffiffiffi ffi {1 p and g is the mode number. It is known that this method can be used to analyze the stability of linear scheme. All the nonlinear term in (11) are assumed to be zero [19]. Thus, equation (11) becomes where c 1~D t ð Þ 2 b and c 2~D t ð Þ 2 a: Substituting the approximate solution (8) in equation (18) leads to where p 1~g1 zh r 1 ð Þ, p 2~g2 zh r 2 ð Þ, r 2~g5 c 1 zg 2 c 2 :    Table 8. The maximum L ? error norms and order of convergence, p for Problem 1.  In order to obtain the amplification factor d j j, the trial solution (17) is substituted in (19) and after some simplification, we obtain, where A~p 1 2 cos gh ð Þ zp 2 , B~p 3 2 cos gh ð Þ zp 4 and C~g 1 2 cos gh ð Þ zg 2 : Since A,B,C §0 and 0ƒhƒ1, the amplification factor of this scheme is where M~g 1 2 cos gh ð Þ zg 2 and N~r 1 2 cos gh ð Þ zr 2 : Hence, this scheme is unconditionally stable.

Numerical Results and Discussions
In this section, the CTBCM is applied on two numerical problems. In order to measure the accuracy of the method, absolute errors and L ? error norms are calculated using the following formulas [16] Absoluteerror~ u u i {u i j j ð22Þ where u u i and u i are analytical solution and approximate solution of proposed problem (1), respectively. The numerical order of convergence, p is obtained by using following formula [14] where L ? n ð Þ and L ? 2n ð Þ are the L ? at number of partition n and 2n respectively.

Problem.1
Consider the following nonlinear Klien-Gordon equation [13,14] u tt {u xx zu 2~{ x cos tzx 2 cos 2 t ð25Þ subject to the following boundary and initial conditions The analytical solution of problem (25) is known to be u u x,t ð Þ~x cos t and graphically shown in Fig.1 (a). This problem is tested using different values of h and Dt to show the capability of the present method. The final time is taken to be T~5:0: Fig.1 (b) and Fig.2 (a) show the approximate solution and Fig.2 (b) shows the error of this problem with n~40 and Dt~0:1: Two cases of this problem are discussed where Case 1 and Case 2 consider Dt~0:001 and Dt~0:005,respectively. Numerical solutions, absolute errors and order of convergence of each case are tabulated in Tables1-4 and Tables5-8. The L ? error norms are compared to Dehghan and Shokri [13] and Khuri and Sayfy [14] in Table3 and Table7. The comparison indicates that the present method is more accurate. The order of convergence of the present problem is calculated by the use of the formula given in (24) and is tabulated in Table4 and Table8. An examination of these tables indicates the method has a nearly second order of convergence.
Case.1. Numerical solutions, absolute errors, L ? error norms and order of convergence using time step size Dt~0:005 Case.2. Numerical solutions, absolute errors, L ? error norms and order of convergence using time step size Dt~0:001

Problem.2
The following nonlinear Klien-Gordon equation which is also known as Sine-Gordon equation is considered [14] u tt {u xx z sin u~0 ð26Þ It is subjected to initial conditions and boundary conditions as The analytical solution of this problem is u u x,t ð Þ~4 tan {1 t sech x ð Þ : Fig.3 (a) depicts a graph of this analytical solution. The final time is taken asT~5:0. The approximate solutions are calculated at time step size Dt~0:01with different mesh space size, h. Numerical solutions are recorded in Table9 and graphical solutions are plotted in Fig.3 (b) and Fig.4 (a). Absolute errors are calculated and shown in Table10 while the 3D error plot is depicted in Fig.4 (b). Table11 shows the comparison of L ? error norms between the present method with Khuri and Sayfy [14] method. This comparison shows that the present method gives better results.

Conclusions
In this work, Klien-Gordon equation has been successfully solved using CTBCM incorporating a finite difference scheme. Specifically, the central difference approach is used to discretize the time derivatives and cubic trigonometric B-spline is used to interpolate the solutions at displacement x: Well-known two test problem were solved using the proposed method and the solution obtained were in good agreement with the known solution. Accurate solutions at intermediate points can be easily obtained.