Abstract
In this paper, we deeply study the high-precision barycentric Lagrange interpolation collocation method to solve nonlinear wave equations. Firstly, we introduce the barycentric Lagrange interpolation and provide the differential matrix. Secondly, we construct a direct linearization iteration scheme to solve nonlinear wave equations. Once again, we use the barycentric Lagrange interpolation to approximate the (2+1) dimensional nonlinear wave equations and (3+1) dimensional nonlinear wave equations, and describe the matrix format for direct linearization iteration of the nonlinear wave equations. Finally, the comparative experiments show that the barycentric Lagrange interpolation collocation method for solving nonlinear wave equations have higher calculation accuracy and convergence rate.
Similar content being viewed by others
Avoid common mistakes on your manuscript.
1 Introduction
As a type of nonlinear model to describe natural wave phenomena, the effective solution of nonlinear wave equations can not only help understand the motion laws of waves under nonlinear effects [1], but also promote the development of related disciplines and engineering fields, such as fluid mechanics [2], electromagnetic waves [3] and nonlinear optics [4]. Establishing accurate nonlinear wave models is an inevitable issue to study nonlinear science. However, most nonlinear problems cannot be solved analytically, and even if an analytical solution can be obtained, it often contains many limiting conditions, which restraints the practical application of nonlinear wave models [5]. Therefore, researchers have turned their attention to studying numerical solutions to solve nonlinear wave equations. When the numerical solution meets the required accuracy, it has physical significance.
There are many methods to solve the numerical solutions of nonlinear wave equations. Among them, inverse scattering method [6], straight line method based on cubic recursion relation [7], hyperbolic tangent function expansion method [8], Laplace transform method [9] are studied to obtain the approximate solution of Sine/Klein–Gordon equation. Homotopy analysis method [10, 11], optimal homotopy analysis method [12], finite difference method [13,14,15], direct meshless local Petrov-Galerkin method [16, 17] are used to study some nonlinear wave problems in engineering problems. In addition, there are numerical methods such as modified simple equation (MSE) method [18] and spectral method based on Legendere wavelet basis [19].
Lagrange interpolation is a type of polynomial interpolation that plays an important role in numerical analysis and theoretical analysis. However, as the number of interpolation nodes increases, it exhibits significant numerical instability, resulting in a sharp decrease in interpolation accuracy. To solve this problem, Berrut et al deformed the Lagrange interpolation formula and put forward the barycentric Lagrange interpolation method, which greatly improved the stability of the method [20, 21]. A modified Lagrange form and barycentric Lagrange form was used to analyze the error of the interpolation polynomial, showing that when the interpolation nodes were not selected properly, the accuracy of the barycentric Lagrange interpolation formula might be obviously lower than that of the modified Lagrange interpolation formula [22]. It was shown that computing the roots of a polynomial expressed in barycentric form via the eigenvalues of an associated companion matrix pair was numerically stable [23]. The barycentric Lagrange interpolation method was applied to solve nonlinear vibration systems [24]. Reference [25] applied the barycentric Lagrange interpolation method to solve (1+1) and (2+1)-dimensional Sine–Gordon equations. The barycentric Lagrange interpolation method and Crank-Nicolson scheme are combined to solve the two-dimensional Allen-Cahn equation [26]. In addition, the barycentric Lagrange interpolation method was used to solve telegraph equation [27], heat conduction equation [28], beam vibration equation [29], and so on.
Here, we introduce a class of (2+1) and (3+1) dimensional nonlinear wave equations. We show the (2+1) dimensional nonlinear wave equations
Where\((x,y,t)\in \Omega \times [0,T]\),\(\Omega =[a,b]\times [c,d]\), F(x, y, t, u) for a given function containing nonlinear term.
Then, we show the (3+1) dimensional nonlinear wave equations
Where\((x,y,z,t)\in \Omega \times [0,T]\),\(\Omega =[a,b]\times [c,d]\times [e,f]\). F(x, y, z, t, u) is a given function containing nonlinear term.
There are three main sources of nonlinearity in nonlinear wave equations. The first type nonlinearity is form the nonlinearity of unknown function, the second type from of the derivative of the unknown function, and the third type form the unknown function and its derivative. We studies the second and third types of (2+1) dimensional nonlinear wave equations, and validates the effectiveness of the method proposed later in solving nonlinear wave equations with nonlinear terms of \(\sin ({{u}_{t}})\), \({{u}_{t}}\sin (u)\) and \(u_{t}^{2}\) as examples. With the (3+1) dimensional nonlinear wave equations, we study the first and third types nonlinearity, and verifies the effectiveness and computational efficiency of the method to (3+1) dimensional nonlinear wave equation with nonlinear terms \(\sin (u)\) and \({{u}^{2}}{{u}_{t}}\) as examples.
In this paper, the barycentric Lagrange interpolation method is further extended to (2+1)- and (3+1)-dimensional nonlinear wave equations with derivative and mixed nonlinear terms. In the first section, the barycentric Lagrange interpolation method for solving (2+1)- and (3+1)-dimensional nonlinear wave equations with different types of nonlinear terms is derived, and the expressions of nonlinear wave equations and the types of nonlinear terms are introduced. The second section, introduces the barycentric Lagrange interpolation and differential matrices. In the third section, we describe the direct linearization iterative schemes for (2+1)- and (3+1)-dimensional nonlinear wave equations are given. In the fourth section, we present a direct linearized iterative matrix scheme for (2+1)- and (3+1)-dimensional nonlinear wave equations. The fifth section, we describe the discretization scheme of the initial boundary condition of nonlinear wave equations and the method of applying the boundary condition. In the sixth section, we perform comparative experiments to show that the high precision and stability of this method for solving nonlinear wave equations.
2 Barycentric Lagrange Interpolation and Its Differential Matrix
2.1 Barycentric Lagrange Interpolation
if we give n different interpolation nodes \(\{{{x}_{j}},j=1,2,\ldots ,n\}\) and define the function value of u(x) at the interpolation node as \({{u}_{j}}=u({{x}_{j}})\), then the barycentric Lagrange interpolation polynomial can be represented as
where \({{w}_{j}}\) is the barycentric Lagrange interpolation weight function, expressed as
If we assume \({{L}_{j}}(x)={\frac{{{w}_{j}}}{x-{{x}_{j}}}}/{\sum \nolimits _{j=1}^{n}{\frac{{{w}_{j}}}{x-{{x}_{j}}}}}\;\), the equation (3) can be abbreviated as
where \({{L}_{j}}(x)\) is the barycentric Lagrange interpolation basis function. A derivative of formula (4) is \({u}'(x)=\sum \nolimits _{j=1}^{n}{{{{{L}'}}_{j}}(x)}{{u}_{j}}\), where
The recurrence formula for the higher-order derivative of the interpolation basis function \({{L}_{j}}(x)\) at the interpolation node is
2.2 Differential Matrix
If the discrete interpolation node \(\left\{ {{x}_{i}},i=1,2,\ldots ,n \right\}\) is substituted into equation (4), the discrete form of the higher-order derivative of Eq. (4) is
It can be expressed in differential matrix is
where \(\varvec{{u}^{(k)}}={\left[ {{u}^{(k)}}({{x}_{1}}),{{u}^{(k)}}({{x}_{2}}),\ldots ,{{u}^{(k)}}({{x}_{n}}) \right] }^{{T} }\), \(\varvec{u}={\left[ {{u}_{1}},{{u}_{2}},\ldots ,{{u}_{n}} \right] }^{{T} }\),
when \(k=0\), \({\varvec{D}^{(0)}}={\varvec{I}_{n}}\), of which \({\varvec{I}_{n}}\) is n order unit matrix. When \(k\ge 1\), the \({\varvec{D}^{(k)}}\) of the matrix elements can be inferred according to the Eqs. (5) and (6).
3 A Linearized Iterative Scheme for Nonlinear Wave Equations
3.1 (2+1) Dimensional Nonlinear Wave Equation Linearization Iterative Scheme
Considering the (2+1) dimensional nonlinear wave equation (1) with nonlinear terms \(\sin ({{u}_{t}})\), \({{u}_{t}}\sin (u)\), and \(u_{t}^{2}\), \(F(x,y,t,u)=f(x,y,t)-g(u)\), where g(u) is a nonlinear term function, the wave equation can be abbreviated as
Any given iterative initial value function \({{u}^{*}}\) can be directly substituted into the nonlinear term g(u) of Eq. (7) to obtain a directly linearized equation
By a given transformation \(u\rightarrow {{u}^{\omega }}\), \({{u}^{*}}\rightarrow {{u}^{\omega -1}}\) (\(\omega \in {{N}^{+}}\) indicates the number of iterations), we can construct a direct linearization iterative format for Eq. (8) as
Therefore, for the nonlinear terms \(\sin ({{u}_{t}})\), \({{u}_{t}}\sin (u)\) and \(u_{t}^{2}\), the direct linearization iterative formats are described as follows:
3.2 ((3+1) Dimensional Nonlinear Wave Equation Linearization Iterative Scheme
Considering the (3+1) dimensional nonlinear wave equation (2) with nonlinear terms \(\sin (u)\) and \({{u}^{2}}{{u}_{t}}\), let \(F(x,y,z,t,u)=f(x,y,z,t)-g(u)\), where g(u) is a nonlinear term function, the wave equation can be abbreviated as
The direct linearization iterative formats for the (3+1) dimensional wave equation with nonlinear terms \(\sin (u)\) and \({{u}^{2}}{{u}_{t}}\) are as follows
4 Matrix Format for Nonlinear Wave Equations
Let the function u(x, y, t), where \((x,y,t)\in \Omega \times [0,T]\), \(\Omega =[a,b]\times [c,d]\), continuously differentiable over the defined domain. On the x-axis, set m interpolation nodes \({{x}_{i}}({{x}_{1}}=a,{{x}_{m}}=b)\), on the y-axis set n interpolation nodes \({{y}_{j}}({{y}_{1}}=c,{{y}_{n}}=d)\), and in the time domain, set h interpolation nodes \({{t}_{k}}({{t}_{1}}=0,{{t}_{h}}=T)\). Using the tensor product method, construct interpolation nodes \(({{x}_{i}},{{y}_{j}},{{t}_{k}}),\) \((i=1,\ldots ,m;j=1,\ldots ,n;k=1,\ldots ,h)\) on the domain \(\Omega \times [0,T]\). The function u(x, y, t) evaluated at the nodes \(({{x}_{i}},{{y}_{j}},{{t}_{k}})\) is denoted as \(u({{x}_{i}},{{y}_{j}},{{t}_{k}})\), abbreviated as \({{u}_{i,j,k}}\).
Using the tensor product form of the three dimensional barycentric Lagrange interpolation formula, the barycentric Lagrange interpolation of a three variable function can be written as
where
is the barycentric Lagrange interpolation basis function and weight function.
The \({{g}_{1}}+{{g}_{2}}+{{g}_{3}}\) derivative of the Eq. (16) can be expressed as
therefore, the function value of Eq. (17) at the interpolation node \(({{x}_{p}},{{y}_{q}},{{t}_{r}})\), \(p=1,\ldots ,m\), \(q=1,\ldots ,n\), \(r=1,\ldots ,h\) is discretized as
The matrix form of Eq. (18) is given by
where
Therefore, the matrix
is an \(mnh\times mnh\) dimensions, and when \(\varvec{{g}_{1}}=\varvec{{g}_{2}}=\varvec{{g}_{3}}=0\), we define \(\varvec{D}_{{}}^{(\varvec{{g}_{1}}\varvec{00})}={\varvec{I}_{m}}\), \(\varvec{E}_{{}}^{(\varvec{0}\varvec{{g}_{2}}\varvec{0})}={\varvec{I}_{n}}\), \(\varvec{C}_{{}}^{(\varvec{00}\varvec{{g}_{3}})}={\varvec{I}_{h}}\), where \(\quad {\varvec{I}_{m}}\), \({\varvec{I}_{n}}, {\varvec{I}_{h}}\) represents m-dimensional, n-dimensional, h-dimensional identity matrices, respectively. Here \(\otimes\) represents the Kronecker product between matrices, and \(\varvec{D}_{{}}^{(\varvec{{g}_{1}}\varvec{00})},\varvec{E}_{{}}^{(\varvec{0}\varvec{{g}_{2}}\varvec{0})},\varvec{C}_{{}}^{(\varvec{00}\varvec{{g}_{3}})}\) represents the differential matrices of x, y, t respectively.
4.1 (2+1) Dimensional Nonlinear Wave Equation in Direct Linearized Iterative Matrix Format
By combining (16) and (10), we can obtain
by substituting the interpolation nodes \(({{x}_{p}},{{y}_{q}},{{t}_{r}})\) into (20), we can obtain
The Eq. (21) can be written in matrix form as
where
Equation (22) can be abbreviated as
where
By combining (16) and (11), we can obtain
by substituting the interpolation nodes \(({{x}_{p}},{{y}_{q}},{{t}_{r}})\) into Eq. (24), we can obtain
The system of equations (25) can be written in matrix form as
abbreviated as
where
By combining Eqs. (16) and (12) and substituting the interpolation nodes \(({{x}_{p}},{{y}_{q}},{{t}_{r}})\), we can obtain
The system of equations (28) can be written in matrix form as
and further abbreviated as
The nonlinear terms \(\varvec{U}_{t}^{(\varvec{\omega -1})}\text {sin(}{\varvec{U}_{{}}}^{(\varvec{\omega -1})}\text {)}\) and \({{(\varvec{U}_{t}^{2})}^{(\varvec{\omega -1})}}\) in Eqs. (27) and (30) are
\({{u}_{t,ijk}}\) represents the first-order partial derivative of function u(x, y, t) to t, the function value at node \(({{x}_{i}},{{y}_{j}},{{t}_{k}})\), \(u_{t,ijk}^{2}\) represents the first-order partial derivative of function u(x, y, t) to t and the square of the function value at node \(({{x}_{i}},{{y}_{j}},{{t}_{k}})\).
4.2 (3+1) Dimensional Nonlinear Wave Equation Directly Linear Iterative Matrix Format
Let the four-dimensional function u(x, y, z, t), \((x,y,z,t)\in \Xi \times [0,T]\), where \(\Xi =[a,b]\) \(\times [c,d]\times [e,f]\) is continuously differentiable over the defined domain. On the x-axis, we set m interpolation nodes \({{x}_{i}}({{x}_{1}}=a,{{x}_{m}}=b)\), on the y-axis, we set n interpolation nodes \({{y}_{j}}({{y}_{1}}=c,{{y}_{n}}=d)\), on the z-axis, we set s interpolation nodes \({{z}_{l}}({{z}_{1}}=e,{{z}_{s}}=f)\), in the time domain, we set h interpolation nodes \({{t}_{k}}({{t}_{1}}=0,{{t}_{h}}=T)\). Using the tensor product method, we construct interpolation nodes \(({{x}_{i}},{{y}_{j}},{{z}_{l}},{{t}_{k}}),\begin{matrix} {} \\ \end{matrix} (i=1,\ldots ,m;j=1,\ldots ,n;l=1,\ldots ,s;k=1,\ldots ,h)\) on the domain \(\Xi \times [0,T]\). The function u(x, y, z, t) at the nodes \(({{x}_{i}},{{y}_{j}},{{z}_{l}},{{t}_{k}})\) is denoted as \(u({{x}_{i}},{{y}_{j}},{{z}_{l}},{{t}_{k}})\) and abbreviated as \({{u}_{i,j,l,k}}\).
The barycentric Lagrange interpolation of a four variable function can be written as
By combining (31) and (14), and substituting the interpolation nodes \(({{x}_{p}},{{y}_{q}},{{z}_{v}},{{t}_{r}})\), we can obtain
Equation (32) can be written as matrix form
and further abbreviated as
where
By combining (31) and (15), and substituting the interpolation nodes \(({{x}_{p}},{{y}_{q}},{{z}_{v}},{{t}_{r}})\), we can obtain
Equation (35) can be written as matrix form
and further abbreviated as
where
5 The Discrete Initial Conditions and Boundary Conditions
Considering Eq. (2) the initial conditions
and the boundary conditions of x
and the boundary conditions of y
and the boundary conditions of z
Employing the barycentric Lagrange interpolation formula (44), we can approximate Eqs. (38)–(41), and get the discrete expression of (38)
Discrete expression of (39)
Discrete expression of (40)
Discrete expression of (41)
Similarly, the discrete format of the initial condition (42) can be expressed in a matrix form as
where
\({\varvec{I}_{{\varvec{h1}}}}\) represents the first row of the h-order identity matrix, and \(\varvec{C}_{{\varvec{t1}}}^{\varvec{(1)}}\) represents the first row of the first-order differential matrix with respect to t.
The matrix forms of equations (43)–(45) are respectively represented as
So far, we have obtained the direct linearized iterative matrix equations (23), (27), (30) for (2+1) dimensional nonlinear wave equations with nonlinear terms \(\sin ({{u}_{t}})\), \({{u}_{t}}\sin (u)\) and \(u_{t}^{2}\) respectively. The direct linearization iterative matrix equation (34), (37) for (3+1) dimensional nonlinear wave equations with nonlinear terms \(\sin (u)\) and \({{u}^{2}}{{u}_{t}}\) respectively. The matrix equations for the initial and boundary conditions are obtained from (46)–(49). Next, the boundary conditions are imposed on the nonlinear wave equation in matrix form.
In this article, we use the method of additional initial conditions and boundary conditions. The initial condition matrix format of Eq. (46) is \(\left[ \varvec{{I}_{m}}\otimes \varvec{{I}_{n}}\otimes \varvec{{I}_{s}}\otimes \varvec{{I}_{h1}} \right]\), which is directly appended below the system of nonlinear wave equations. Substituting the corresponding \(\varvec{\varphi }\) terms from Eq. (46) results, in a system of equations with \(mnsh+mnh\) dimensions. Then, the matrix format of Eq. (46), \(\left[ \varvec{{I}_{m}}\otimes \varvec{{I}_{n}}\otimes \varvec{{I}_{s}}\otimes \varvec{C}_{\varvec{t1}}^{\varvec{(1)}} \right]\) is further appended below the system of nonlinear wave equations. Substituting the corresponding \(\varvec{\phi }\) terms from Eq. (46) results, in a system of equations with a dimension of \(mnsh+2mnh\). The attachment methods of x-boundary conditions, y-boundary conditions and z-boundary conditions can similar developed.
Following the aforementioned attachment, we obtain a matrix equation system of dimension \(mnsh+2mnh+2nsh+\) \(2msh+2mns\). Let \(\omega =1\), with a given initial value \({{u}^{(0)}}\) and iteration precision e, and then the iteration begins. The iteration stops when the condition
is satisfied or after exceeding 20 iterations, obtaining the numerical solution of the equations.
6 Numerical Examples
To validate the effectiveness of the method and iterative format submitted in this paper, numerical simulations are carried out on the given analytical solution examples, with computational programs written in MATLAB(R2019b) for all examples below.
Select the second Chebyshev nodes
and equidistant nodes
as the interpolation nodes. The Chebyshev nodes are defined on the interval [− 1,1], using the transform \({\widetilde{x}}=\frac{b-a}{2}x+\frac{b+a}{2}\) Chebyshev interpolation nodes can be transform into [a,b] with any reasonable value.
Order of convergence
where \({{e}_{1}}\) and \({{e}_{2}}\) represent the \({{L}_{2}}\)-norm of the previous error and the subsequent error of the two adjacent node number errors, respectively. \({{N}_{2}}\) represents the number of nodes with error \({{e}_{2}}\), and \({{N}_{1}}\) represents the number of nodes with error \({{e}_{1}}\).
The definition of absolute error \({{E}_{a}}\) and relative error \({{E}_{r}}\), can be respectively defined as:
where \({{\left\| \centerdot \right\| }_{2}}\) represents the 2-norm of a vector, \({{U}^{A}}\) is the column vector of the analytical solution, and \({{U}^{N}}\) is the column vector of the numerical solution. In this paper, the iterative accuracy of the example is \(e=10\times {{10}^{-10}}\), and the number of iterations is not more than 20.
Example 1
where \(\Omega =[0,1]\times [0,1]\), \(f(x,y,t)=(1+2{{\pi }^{2}}){{e}^{t}}\cos (\pi x)\sin (\pi y)+\sin ({{e}^{t}}\cos \pi x\sin \pi y)\) The analytical solution of this example is \(u(x,y,t)={{e}^{t}}\cos (\pi x)\sin (\pi y)\), and the boundary condition is obtained from the analytical solution, so that the final time value \(T=1\), \(N=m=n=h\). The errors of Chebyshev nodes and equidistant nodes under the direct linearization iteration format were estimated (Table 1), with the Chebyshev nodes, when there are 15 nodes, the error accuracy reaches the highest, with an absolute error of the order of \({{10}^{-10}}\), a relative error of the order of \({{10}^{-12}}\), and a convergence order of 31.6. With equidistant nodes, when there are 13 nodes, the error accuracy reaches the highest, with an absolute error of \({{10}^{-9}}\), the relative error of \({{10}^{-10}}\), and a convergence order of 31.4. After reaching the optimal accuracy for equidistant nodes, there is a tendency of decreasing precision when increasing the number of nodes. Actually, the approach using the Chebyshev nodes show better error stability compared to that of equidistant nodes. Both approaches exhibit high computational accuracy, indicating the effectiveness of them in solving nonlinear problems. Let \(S=m=n\), the number of time interpolation nodes is \({{S}^{2}}\), The error and convergence order of the example under the three-point central difference method at \(t=2\Delta t\), show that when the number of spatial nodes reaches 96, the accuracy of absolute error is \({{10}^{-7}}\), the accuracy of relative error is \({{10}^{-8}}\), and the maximum order of convergence is 3.2 (Table 2), which is lower than the optimal accuracy and convergence rate of the barycentric Lagrange interpolation method, where \(\Delta t\) represents the time step.
When the Chebyshev nodes reaches 15 in the direct linearization iteration format at \(t=1\), a high degree of agreement is achieved between the numerical solution and the analytical solution at that time (Fig. 1). the error diagrams of the Chebyshev nodes and the equidistant nodes at \(t=1\) are shown under the direct linearization iteration format at the node size of 15 (Fig. 2). The error accuracy of the Chebyshev nodes is on the order of \({{10}^{-12}}\), while that with the equidistant nodes is on the order of \({{10}^{-10}}\). This supports the high accuracy of our approaches in solving (2+1)-dimensional nonlinear wave equations with the second type of nonlinear terms.
Example 2
where \(\Omega =[0,1]\times [0,1]\),
The analytical solution in this example is \(u(x,y,t)=x+y+2{{t}^{2}}+\cos (\pi x)\cos (\pi y)\cos (\pi t)\), and the boundary condition can be obtained from the analytic solution, considering the final value \(T=1\), \(N=m=n=h\). The errors with the Chebyshev nodes and equidistant nodes under the direct linearization iteration format were shown (Table 3),and show that the Chebyshev nodes the optimal error accuracy is achieved, when the number of nodes reaches 13, with an absolute error of \({{10}^{-9}}\), a relative error of \({{10}^{-11}}\), and a convergence order of 31.8, exhibits good error stability. Equidistant nodes achieve optimal error accuracy when the number of nodes is 13, with an absolute error of the order of \({{10}^{-9}}\), a relative error of the order of \({{10}^{-11}}\), and a convergence order of 15.1, as the number of nodes continues to increase, there will be a tendency of decreased accuracy.
The numerical solution at time \(t=1\) with 15 Chebyshev nodes agrees the best with the analytical solution in the direct linearization iterative format (Fig. 3). The errors with the Chebyshev nodes and the equidistant nodes at the node size 15 at \(t=1\) show that the accuracy with the Chebyshev nodes is on the order of \({{10}^{-11}}\) while that of the equidistant nodes is on the order of \({{10}^{-10}}\) (Fig. 4) This implies the high precision of our methods in solving nonlinear (2+1)-dimensional wave equations.
Example 3
where \(\Omega =[0,1]\times [0,1]\), \(f(x,y,t)={{e}^{-2t}}\sin (\pi x)\sin (\pi y)\left[ 4+2{{\pi }^{2}}+4{{e}^{-2t}}\sin (\pi x)\sin (\pi y) \right]\) The analytical solution in this example is \(u(x,y,t)={{e}^{-2t}}\sin (\pi x)\sin (\pi y)\), and the boundary condition can be obtained from the analytic solution, considering the time terminal value \(T=1\), \(N=m=n=h\). The error with Chebyshev nodes and the equidistant nodes under the direct linearization iteration format is shown (Table 4), the optimal error accuracy is achieved at 15 with the Chebyshev nodes, with an absolute error of the order of \({{10}^{-11}}\) and a relative error of the order of \({{10}^{-12}}\), and as the number of nodes continues to increase, the error accuracy remains the same. The optimal error accuracy is achieved at 13 with the equivalent nodes, with an absolute error of the order of \({{10}^{-9}}\) and a relative error of the order of \({{10}^{-10}}\), and as the number of nodes continues to increase, there will be a trend of decreasing accuracy.
The numerical and analytical solutions at \(t=1\) with the Chebyshev nodes at a number of 15 in the direct linearization iteration format are displaced (Fig. 5). The errors with the Chebyshev nodes and the equidistant nodes are shown (Fig. 6)
Example 4
where \((x,y,z,t)\in \Omega \times [0,T]\), \(\Omega =[0,1]\times [0,1]\times [0,1]\), the analytical solution of this example is \(u(x,y,z,t)=xyz{{e}^{x+y+z-t}}\), and the boundary condition can be obtained from the analytical solution, considering the time terminal value \(T=1\), \(N=m=n=h=s\). The absolute and relative errors with the Chebyshev nodes and the equidistant nodes of the three-dimensional Sine–Gordon equation under the direct linearization iteration format are estimated (Table 5). When the Chebyshev node number reaches 11 the absolute error reaches a maximum of \({{10}^{-8}}\) and, the relative error reaches a maximum of \({{10}^{-10}}\). Comparatively, when there are 9 nodes a maximum convergence order of 24.6 is achieved. For the equidistant nodes, the maximum absolute error is on the order of \({{10}^{-8}}\) the maximum relative error is on the order of \({{10}^{-10}}\), and the maximum convergence order is 25.0. The above findings show that stability of the Chebyshev nodes is better than that of equidistant nodes, and both node types have high numerical accuracy. Let \(S=m=n=h=\), the number of time interpolation nodes is \({{S}^{2}}\), Table 6 shows the error and convergence order of this example under the three-point central difference method at \(t=3\Delta t\), from the data in the table, it can be seen that when the number of spatial nodes is 62, the accuracy of absolute error is \({{10}^{-5}}\), the accuracy of relative error is \({{10}^{-8}}\), and the maximum order of convergence is 2.4, which is lower than the optimal accuracy and convergence rate of the barycentric Lagrange interpolation method.
Example 5
where \((x,y,z,t)\in \Omega \times [0,T]\), \(\Omega =[0,1]\times [0,1]\times [0,1]\), the boundary condition is obtained from the analytical solution.
The analytical solution of this example is \({{e}^{-t}}\sin (\pi x)\sin (\pi y)\sin (\pi z)\), considering the time terminal value \(T=1\). The absolute and relative errors with the Chebyshev nodes and the equidistant nodes of the three-dimensional nonlinear wave equation under the direct linearization iteration format are estimated (Table 7). When the Chebyshev node number reaches 13, the absolute error reaches a maximum of \({{10}^{-8}}\) and, the relative error reaches a maximum of \({{10}^{-9}}\). Comparatively, when there are 13 nodes a maximum convergence order of 25.9 is achieved. For the equidistant nodes, the maximum absolute error is on the order of \({{10}^{-8}}\), the relative error reaches a maximum of \({{10}^{-9}}\), and the maximum convergence order is 28.6.
7 Conclusion
In this paper, the barycentric Lagrange interpolation collocation method is adopted to solve three kinds of nonlinear wave equations, and the direct linearized iterative schemes are constructed. We developed the linearization iteration matrix formats for (2+1) dimensional nonlinear wave equations and (3+1) dimensional nonlinear wave equations. The numerical results indicate that using the Chebyshev nodes provides greater stability than using equidistant nodes. This method also offers high convergence speed and error accuracy when solving nonlinear wave equations. In addition, the experimental part is also compared with the three-point central difference method, the results show that the proposed method is better than the three-point central difference method in both computational accuracy and convergence rate in solving (2+1) and (3+1)-dimensional nonlinear wave equations, and higher error accuracy can be obtained by using only a few interpolation nodes. this method can also be used to solve fractional order nonlinear wave equations, which to some extent promotes the development of nonlinear problems.
Availability of Data and Materials
Data sharing is not applicable to this article as no new data were created or analyzed in this study.
Code Availability
Not applicable.
References
Rincon, M.A., Quintino, N.: Numerical analysis and simulation for a nonlinear wave equation. J. Comput. Appl. Math. 296, 247–264 (2016)
Liepmann, H.W., Laguna, G.A.: Nonlinear interactions in the fluid mechanics of helium II. Ann. Rev. Fluid Mech. 16(1), 139–177 (1984)
Quan, B., Liang, X., Ji, G., Cheng, Y., Liu, W., Ma, J., Zhang, Y., Li, D., Xu, G.: Dielectric polarization in electromagnetic wave absorption: review and perspective. J. Alloys Compd. 728, 1065–1075 (2017)
Autere, A., Jussila, H., Dai, Y., Wang, Y., Lipsanen, H., Sun, Z.: Nonlinear optics with 2D layered materials. Adv. Mater. 30(24), 1705963 (2018)
Ahmad, H., Seadawy, A.R., Khan, T.A., Thounthong, P.: Analytic approximate solutions for some nonlinear parabolic dynamical wave equations. J. Taibah Univ. Sci. 14(1), 346–358 (2020)
Ablowitz, M.J., Kaup, D.J., Newell, A.C., Segur, H.: Method for solving the Sine–Gordon equation. Phys. Rev. Lett. 30(25), 1262 (1973)
Bratsos, A.G.: The solution of the two dimensional Sine–Gordon equation using the method of lines. J. Comput. Appl. Math. 206(1), 251–277 (2007)
Kolpak, E.P., Ivanov, S.E.: On the three dimensional Klein–Gordon equation with a cubic nonlinearity. Int. J. Math. Anal. 10(13), 611–622 (2016)
Ibrahim, W., Tamiru, M.: Solutions of three dimensional nonlinear Klein-Gordon equations by using quadruple laplace transform. Int. J. Differ. Equ. 2022(1), 2544576 (2022)
Liao, S.: A new branch of solutions of boundary-layer flows over an impermeable stretched plate. Int. J. Heat Mass Transf. 48(12), 2529–2539 (2005)
Liao, S.: A new branch of solutions of boundary layer flows over a permeable stretching plate. Int. J. Nonlinear Mech. 42(6), 819–830 (2007)
Ullah, H., Islam, S., Dennis, L.C.C., Abdelhameed, T.N., Khan, I., Fiza, M.: Approximate solution of two-dimensional nonlinear wave equation by optimal homotopy asymptotic method. Math. Probl. Eng. 2015(1), 380104 (2015)
Vong, S., Wang, Z.: A compact difference scheme for a two dimensional fractional Klein-Gordon equation with neumann boundary conditions. J. Comput. Phys. 274, 268–282 (2014)
Han, H., Zhang, Z.: Split local artificial boundary conditions for the two dimensional Sine–Gordon equation on \(R^2\). Commun. Comput. Phys. 10(5), 1161–1183 (2011)
Huang, R., Pan, W., Lu, C., Zhang, Y., Chen, S.: An improved three-point method based on a difference algorithm. Precis. Eng. 63, 68–82 (2020)
Darani, M.A.: Direct meshless local Petrov–Galerkin method for the two dimensional Klein–Gordon equation. Eng. Anal. Bound. Elem. 74, 1–13 (2017)
Shivanian, E.: Meshless local Petrov–Galerkin (MLPG) method for three dimensional nonlinear wave equations via moving least squares approximation. Eng. Anal. Bound. Elem. 50, 249–257 (2015)
Khan, K., Akbar, M.A.: Exact solutions of the (2+1) dimensional cubic Klein-Gordon equation and the (3+1) dimensional Zakharov–Kuznetsov equation using the modified simple equation method. J. Assoc. Arab Univ. Basic Appl. Sci. 15, 74–81 (2014)
Yin, F., Tian, T., Song, J., Zhu, M.: Spectral methods using legendre wavelets for nonlinear Klein/Sine–Gordon equations. J. Comput. Appl. Math. 275, 321–334 (2015)
Berrut, J.P., Trefethen, L.N.: Barycentric Lagrange interpolation. SIAM Rev. 46(3), 501–517 (2004)
Berrut, J.P., Baltensperger, R., Mittelmann, H.D.: Recent developments in barycentric rational interpolation. In: Trends and Applications in Constructive Approximation, pp. 27–51 (2005)
Higham, N.J.: The numerical stability of barycentric Lagrange interpolation. IMA J. Numer. Anal. 24(4), 547–556 (2004)
Lawrence, P.W., Corless, R.M.: Stability of rootfinding for barycentric Lagrange interpolants. Numer. Algorithms 65, 447–464 (2014)
Wu, H., Wang, Y., Zhang, W., Wen, T.: The barycentric interpolation collocation method for a class of nonlinear vibration systems. J. Low Freq. Noise Vib. Active Control 38(3–4), 1495–1504 (2019)
Li, J., Qu, J.: Barycentric Lagrange interpolation collocation method for solving the Sine–Gordon equation. Wave Motion 120, 103159 (2023)
Deng, Y., Weng, Z.: Operator splitting scheme based on barycentric Lagrange interpolation collocation method for the Allen–Cahn equation. J. Appl. Math. Comput. 68(5), 3347–3365 (2022)
Li, J., Su, X., Qu, J.: Linear barycentric rational collocation method for solving telegraph equation. Math. Methods Appl. Sci. 44(14), 11720–11737 (2021)
Li, J.: Linear barycentric rational collocation method for solving nonlinear partial differential equations. Int. J. Appl. Comput. Math. 8(5), 236 (2022)
Li, J., Sang, Y.: Linear barycentric rational collocation method for beam force vibration equation. Shock Vib. 2021, 1–11 (2021)
Acknowledgements
The authors wish to acknowledge the referees for their valuable comments and suggestions, which helped to improve the article. Authors would like to thank North China University of Science and Technology for facilitating this research.
Funding
No funding was received for conducting this study.
Author information
Authors and Affiliations
Contributions
HWY, JL and XYW have defined the problem and given the methodology and complete all experimental procedures and write the content of the paper. XYW and HWY provides guidance on issues arising during the research process, and revise English grammar and paper format. JL and XYW provides guidance on the problems encountered in the experimental and theoretical sections, and propose suggestions for modification.
Corresponding authors
Ethics declarations
Conflict of interest
The authors declare that they have no known competing financial interests or personal relationships that could have appeared to influence the work reported in this paper.
Ethics approval
Not applicable.
Rights and permissions
Open Access This article is licensed under a Creative Commons Attribution 4.0 International License, which permits use, sharing, adaptation, distribution and reproduction in any medium or format, as long as you give appropriate credit to the original author(s) and the source, provide a link to the Creative Commons licence, and indicate if changes were made. The images or other third party material in this article are included in the article's Creative Commons licence, unless indicated otherwise in a credit line to the material. If material is not included in the article's Creative Commons licence and your intended use is not permitted by statutory regulation or exceeds the permitted use, you will need to obtain permission directly from the copyright holder. To view a copy of this licence, visit http://creativecommons.org/licenses/by/4.0/.
About this article
Cite this article
Yuan, H., Wang, X. & Li, J. Solving Nonlinear Wave Equations Based on Barycentric Lagrange Interpolation. J Nonlinear Math Phys 31, 41 (2024). https://doi.org/10.1007/s44198-024-00200-5
Received:
Accepted:
Published:
DOI: https://doi.org/10.1007/s44198-024-00200-5