1 Introduction

In this paper, we consider the nonlinear Schrödinger equation with wave operator (NLSW) in a bounded domain with dimension \(d\le 3\)

$$\begin{aligned}&u_{tt}-\Delta u+\text{ i }\alpha u_t+\beta (\pmb {x})f(|u|^2)u=0, \quad (\pmb {x}\in \Omega , \quad 0<t<T),\nonumber \\&u(\pmb {x},0)=u_{0}(\pmb {x}), u_t|_{t=0}=u_1(\pmb {x}), \quad (\pmb {x}\in \Omega ), \end{aligned}$$
(1.1)

where \(u(\pmb {x},t)\) is a complex function, \(\alpha \) is a real constant, \(\beta (\pmb {x})\) and \(f(x)\) are real functions, and \(\text{ i }^2=-1\). NLSW can be used in a wide range of physical applications such as the nonrelativistic limit of the Kelin–Gordon equation [17, 19, 21], the Langmuir wave envelope approximation in plasma [4] and the modulated planar pulse approximation of the sine-Gordon equation for light bullets [2, 25].

We will present the fully discrete local discontinuous Galerkin (LDG) scheme with the Crank–Nicholson time discretization to solve the nonlinear Schrödinger equation with wave operator. This scheme is implicit in time which is unconditionally stable and can preserve the energy in discrete level.

This equation had been discussed in [12] and its reference. An important property of Eq. (1.1) is energy conservation. Computing the inner product of Eq. (1.1) with \(u_t\) and then taking the real part, we can obtain the conservative law as follows

$$\begin{aligned} \Vert u_t\Vert ^2+\Vert \nabla u\Vert ^2+\int _{\Omega } \beta (\pmb {x})F(|u|^2)d\Omega =\text{ Constant }, \end{aligned}$$
(1.2)

where \(F(s)=\int _{0}^{s} f(r)dr\). Hence, the conservative scheme should work better than the nonconservative ones. In [30], Zhang et al. had pointed out the nonconservative schemes may easily lead the nonlinear Schrödinger equation blow up, and therefore they had developed a conservative difference scheme for the nonlinear Schrödinger equation. Even though adding a little dissipation could make the non-conservative scheme stable, it would destroy the accuracy. Many methods had been found to solve the nonlinear Schrödinger equation with wave operator. In [12], an implicit nonconservative finite difference method had been found, but it needed lots of algebraic operators. There was an explicit conservative finite difference scheme to be constructed in [31]. However, this method was conditionally stable. Moreover, in [24, 32] the conservative finite difference schemes were used to simulate the generalized nonlinear Schrödinger equations with wave operator. The results of these schemes worked well, however, the convergence order of all schemes was low. In [23], discrete-time orthogonal spline collocation methods for the nonlinear Schrödinger equation with wave operator had been constructed. A finite difference scheme could be found in [1] and Bao had given the uniform error estimate of this method. In [22], multisymplectic Fourier pseudospectral method had been presented for the nonlinear Schrödinger equation with wave operator. In [14], a compact finite difference scheme had been developed to solve the nonlinear Schrödinger equation with wave operator. In addition, many LDG methods had been developed to solve time dependent Schrödinger equations in [11, 15, 16, 27]. Xu and Shu gave the proof of error estimates about the linear Schrödinger equation in [29]. Energy conserving LDG methods for wave propagation problems had been developed in [26]. These schemes mentioned above were only considered in one-dimensional case.

In this paper, we consider the multi-dimensional case for the nonlinear Schrödinger equation with wave operator. We will present a high order energy conserving LDG method to simulate this equation. Discontinuous Galerkin (DG) methods are a class of finite element methods using completely discontinuous basis functions, which are usually chosen as piecewise polynomials. They were first designed to solve hyperbolic conservation laws with only first order spatial derivatives such as in [18] for solving steady state linear equations, and Cockburn in [58] for solving time dependent linear equations. The LDG method is an extension of DG method aimed to solve PDEs which contain high order spatial derivatives and it was first introduced by Cockburn and Shu in [9] to solve nonlinear convection diffusion equations which were motivated by successful numerical experiments in [3] for the compressible Navier–Stokes equations. The LDG method has several advantages as follows. Firstly, it can be designed as any order of accuracy. Since the order of accuracy can be locally determined in each cell, it has efficient \(p\) adaptivity. Secondly, the allowance of arbitrary triangulation even with hanging nodes makes efficient \(h\) adaptivity come true. Moreover, the method has embarrassingly high parallel efficiency because the elements only communicate with immediate neighbors regardless of the order of the accuracy of the scheme. More details about the LDG methods for high-order time dependent PDEs can be found in the review paper [28].

This paper is organized as follows. In Sect. 2, we develop the semi-discrete LDG method for the nonlinear Schrödinger equation with wave operator and give the proof of the energy conserving property. In addition, some optimal error estimates for the linear case in multi-dimensional space are analyzed in this section. The fully discrete LDG method coupled with the Crank–Nicholson time discretization and the energy conserving properties are presented in Sect. 3. Numerical results in multi-dimensional spaces are shown in Sect. 4 and the concluding remarks are given in Sect. 5.

2 Local Discontinuous Galerkin Method for the Nonlinear Schrödinger Equation with Wave Operator

In this section we will give the semi-discrete LDG method for the nonlinear Schrödinger Eq. (1.1). Here we use the homogenous Dirichlet or periodic boundary conditions in a bounded domain with dimension \(d\le 3\). We will discretize the space by using the LDG method and leave the time dependence continuous. For the simplicity, we first give some notations, inner products and norms in the complex space.

2.1 Notations, Inner Products and Norms in the Complex Space

In order to define the LDG method we should introduce some notations and inner products and norms in the complex space.

2.1.1 Notations

We first introduce the finite element spaces associated to the triangulation \(\mathcal {T}_{h}=\{K\}\) of \(\Omega \). The domain \(\Omega \) can be decomposed into the set of \(\mathcal {T}_{h}\). The boundary of \(\Omega \) can be denoted as \(\Gamma =\partial \Omega \). Let \({}_c{\mathcal {P}^{k}(K)}\) denote the space of complex polynomials of degree at most \(k\ge 0\) on each element \(K\). The piecewise complex polynomials space \({}_c{V_{h}}\) is defined as the space of piecewise complex polynomials of degree at most \(k\) in each variable,

$$\begin{aligned}&{}_c{V_{h}}=\{v\in L^2(\Omega ): \quad v|_K \in {}_c{\mathcal {P}^{k}(K)}, \quad \forall K\in \mathcal {T}_{h}\}. \end{aligned}$$

We also give this definition for vector-valued functions by defining

$$\begin{aligned}&{}_c{\Sigma _{h}}=\{\pmb {\phi }\in [L^2(\Omega )]^d: \quad \pmb {\phi }|_K \in [{}_c{\mathcal {P}^{k}(K)}]^{d}, \quad \forall K\in \mathcal {T}_{h}\}. \end{aligned}$$

For each \(K\in \mathcal {T}_h\), let \(h_K\) denote the diameter of \(K\) and we set \(h:=\max _{K\in \mathcal {T}_h} h_{K}\). The functions in \({}_c{V_{h}}\) and \({}_c{\Sigma _{h}}\) are complex valued functions and are allowed to have discontinuities across element interfaces. In order to define the flux functions some notations are necessary to be introduced. Let \(e\) be an interior edge shared by the “left” and “right” elements denoted by \(K_L\) and \(K_R\). The “left” and “right” can be uniquely defined for each \(e\) according to any fixed rule. If \(\pmb {\phi }\) is a function on \(K_L\) and \(K_R\), but possibly discontinuous across \(e\), let \(\pmb {\phi }_L:=(\pmb {\phi }|_{K_L})|_e\) and \(\pmb {\phi }_R:=(\pmb {\phi }|_{K_R})|_e\) be the left and right trace respectively.

2.1.2 Inner Products and Norms in the Complex Space

Let \(w^*\) denote the conjugate of \(w\) and define the inner product as

$$\begin{aligned}&(w,v)_K=\int _{K} wv^* dK, \quad (w,v)_{\partial K}= \int _{\partial K} wv^* ds,\\&(\pmb {p},\pmb {q})_K=\int _{K} \pmb {p}\cdot \pmb {q}^* dK, \quad (\pmb {p},\pmb {q})_{\partial K}= \int _{\partial K} \pmb {p}\cdot \pmb {q}^* ds, \end{aligned}$$

and the conjugate of the inner product is defined as

$$\begin{aligned} (w,v)^{*}_{K}=(v,w)_{K}, \quad (\pmb {p},\pmb {q})_K^{*}=(\pmb {q},\pmb {p})_K, \end{aligned}$$

for the scalar variables \(w\), \(v\) and the vector variables \(\pmb {p}\), \(\pmb {q}\) respectively. The definitions of the \(L^2\)-norm over \(K\) and on the boundary \(\partial K\) are given as

$$\begin{aligned}&\Vert \eta \Vert _{K}^2=\int _{K} |\eta |^2 dK, \quad \Vert \pmb {q}\Vert _{K}^2=\int _{K} |\pmb {q}|^2 dK,\\&\Vert \eta \Vert _{\partial K}^2=\int _{\partial K} |\eta |^2 ds, \quad \Vert \pmb {q}\Vert _{\partial K}^2=\int _{\partial K} |\pmb {q}|^2 ds. \end{aligned}$$

The \(L^2\)-norm in the domain \(\Omega \) is defined as

$$\begin{aligned} \Vert \eta \Vert _{\Omega }^2=\sum _{K\in \mathcal {T}_h} \Vert \eta \Vert _{K}^2, \quad \Vert \pmb {q}\Vert _{\Omega }^2=\sum _{K\in \mathcal {T}_h} \Vert \pmb {q}\Vert _{K}^2. \end{aligned}$$

The \(H^{l}(K)\)-norm over \(K\) is defined as

$$\begin{aligned} \Vert \eta \Vert _{H^{l}(K)}=\left( \sum _{|\alpha |\le l} \Vert D^{\alpha }\eta \Vert ^{2}_{K}\right) ^{\frac{1}{2}}, \quad l>0. \end{aligned}$$

The \(H^{l}(\Omega )\)-norm in the domain \(\Omega \) is defined as

$$\begin{aligned} \Vert \eta \Vert _{H^{l}(\Omega )}=\left( \sum _{K\in \mathcal {T}_{h}}\Vert \eta \Vert _{H^{l}(K)}^{2}\right) ^{\frac{1}{2}}, \quad \Vert \pmb {q}\Vert _{H^{l}(\Omega )}=\left( \sum _{K\in \mathcal {T}_{h}}\Vert \pmb {q}\Vert _{H^{l}(K)}^{2}\right) ^{\frac{1}{2}}, \end{aligned}$$

where \(l=0\) is the \(L^{2}\)-norm.

2.2 The LDG Scheme

In order to define the LDG method, we rewrite the nonlinear Schrödinger Eq. (1.1) into a system of the first order equations

$$\begin{aligned}&u_{tt}-\nabla \cdot \pmb {q}+\text{ i }\alpha u_t+\beta (\pmb {x})f(|u|^2)u=0, \\&\pmb {q}-\nabla u=0. \end{aligned}$$

The general formulation of the LDG scheme is to find \(u_{h} \in {}_c{V_{h}}\) and \(\pmb {q}_{h} \in {}_c{\Sigma _{h}}\) such that for all \(K \in \mathcal {T}_{h}\) and all test functions \(v \in {}_c{V_{h}}\) and \(\pmb {\phi } \in {}_c{\Sigma _{h}}\) we have

$$\begin{aligned}&((u_{h})_{tt}, v)_{K}+(\pmb {q}_{h} ,\nabla v)_ K-(\hat{\pmb {q}}_{h}\cdot \pmb {\nu },v)_{\partial K}+\text{ i }\alpha ((u_h)_t,v)_K+(\beta (\pmb {x})f(|u_h|^2)u_h,v)_K=0, \end{aligned}$$
(2.1)
$$\begin{aligned}&(\pmb {q}_{h},\pmb {\phi })_K+(u_{h},\nabla \cdot \pmb {\phi })_K -(\hat{u}_{h},\pmb {\phi }\cdot \pmb {\nu })_{\partial K}=0, \end{aligned}$$
(2.2)

The “hat” terms in (2.1)–(2.2) in the cell boundary terms from integration by parts are the numerical fluxes, which are functions defined on the edges and should be designed to ensure stability and \(\pmb {\nu }\) is the outward normal vector of the integrated domain. Here we use the simple alternating fluxes:

$$\begin{aligned} \hat{\pmb {q}}_{h}=\pmb {q}_{h}|_{R},\quad \hat{u}_{h}=u_{h}|_{L}. \end{aligned}$$
(2.3)

The choice of the fluxes is not unique.

We define the numerical entropy flux as

$$\begin{aligned} H_{\partial K}(v,\pmb {\phi };\hat{v},\hat{\pmb {\phi }})=(v,\hat{\pmb {\phi }}\cdot \pmb {\nu })_{\partial K}+(\hat{v},\pmb {\phi }\cdot \pmb {\nu })_{\partial K}-(v,\pmb {\phi }\cdot \pmb {\nu })_{\partial K}. \end{aligned}$$

By using the numerical flux defined above we have the following property (see [10, Lemma 2.2).

Lemma 1

(Dong and Shu [10]) Suppose \(e\) is an inter-element face shared by the elements \(K_1\) and \(K_2\), then

$$\begin{aligned} H_{\partial K_1\bigcap e}(v,\pmb {\phi };\hat{v},\hat{\pmb {\phi }})+H_{\partial K_2\bigcap e}(v,\pmb {\phi };\hat{v},\hat{\pmb {\phi }})=0, \end{aligned}$$

for any \(v \in {}_c{V_{h}}\) and \(\pmb {\phi } \in {}_c{\Sigma _{h}}\). Here \(\hat{v}_{e}=v_{L}\) and \(\hat{\pmb {\phi }}_{e}=\pmb {\phi }_{R}\). In addition, the periodic boundary conditions and the homogenous Dirichlet boundary conditions give

$$\begin{aligned} \sum _{K\in \mathcal {T}_{h}}H_{\partial K}(v,\pmb {\phi };\hat{v},\hat{\pmb {\phi }})=0. \end{aligned}$$

2.3 Energy Conservation

In this subsection, we will show that the semi-discrete LDG method conserves energy. This property is consistent with Eq. (1.2).

Proposition 2

The energy with time continuous

$$\begin{aligned} E_{h}(t)=\Vert (u_{h})_{t}\Vert _{\Omega }^2+\Vert \pmb {q}_{h}\Vert _{\Omega }^2+(\beta (\pmb {x}), F(|u_{h}|^2))_{\Omega }, \end{aligned}$$
(2.4)

is conserved by using the semi-discrete LDG method (2.1)–(2.2) for all time. Where \(F(s)=\int _{0}^{s} f(r)dr\).

Proof

We first take the derivative of Eq. (2.2) about time and choose the test function \(\pmb {\phi }=\pmb {q}_{h}\), then we have

$$\begin{aligned} ((\pmb {q}_{h})_{t},\pmb {q}_{h})_K+((u_{h})_{t},\nabla \cdot \pmb {q}_{h})_K-((\hat{u}_{h})_{t},\pmb {q}_{h}\cdot \pmb {\nu })_{\partial K}=0, \end{aligned}$$
(2.5)

and take the conjugate of (2.5), we get

$$\begin{aligned} (\pmb {q}_{h},(\pmb {q}_{h})_{t})_K+(\nabla \cdot \pmb {q}_{h}, (u_{h})_{t})_K-(\pmb {q}_{h}\cdot \pmb {\nu },(\hat{u}_{h})_{t})_{\partial K}=0. \end{aligned}$$
(2.6)

In Eq. (2.1), we choose the test function \(v=(u_{h})_t\) to obtain

$$\begin{aligned}&((u_{h})_{tt}, (u_{h})_t)_{K}+(\pmb {q}_{h} ,\nabla (u_{h})_t)_ K-(\hat{\pmb {q}}_{h}\cdot \pmb {\nu },(u_{h})_t)_{\partial K}\nonumber \\&\qquad +\text{ i }\alpha ((u_h)_t,(u_{h})_t)_K+(\beta (\pmb {x})f(|u_h|^2)u_h,(u_{h})_t)_K =0, \end{aligned}$$
(2.7)

and also take the conjugate of (2.7), one can obtain

$$\begin{aligned}&((u_{h})_t,(u_{h})_{tt})_{K}+(\nabla (u_{h})_t,\pmb {q}_{h})_ K-((u_{h})_t,\hat{\pmb {q}}_{h}\cdot \pmb {\nu })_{\partial K} \nonumber \\&\qquad -\text{ i }\alpha ((u_{h})_t,(u_h)_t)_K+(\beta (\pmb {x}) f(|u_h|^2)(u_{h})_t,u_h)_K=0. \end{aligned}$$
(2.8)

We add Eqs. (2.5)–(2.8) to get

$$\begin{aligned}&((u_{h})_{tt}, (u_{h})_t)_{K}+((u_{h})_t,(u_{h})_{tt})_{K} +((\pmb {q}_{h})_{t},\pmb {q}_{h})_K+(\pmb {q}_{h},(\pmb {q}_{h})_{t})_K \nonumber \\&\qquad +(\beta (\pmb {x})f(|u_h|^2)u_h,(u_{h})_t)_K +(\beta (\pmb {x})f(|u_h|^2)(u_{h})_t,u_h)_K \nonumber \\&\qquad +((u_{h})_{t},\nabla \cdot \pmb {q}_{h})_K +(\nabla (u_{h})_t,\pmb {q}_{h})_ K+(\nabla \cdot \pmb {q}_{h},(u_{h})_{t})_K +(\pmb {q}_{h} ,\nabla (u_{h})_t)_ K \nonumber \\&\qquad -((\hat{u}_{h})_{t},\pmb {q}_{h}\cdot \pmb {\nu })_{\partial K} -((u_{h})_t,\hat{\pmb {q}}_{h}\cdot \pmb {\nu })_{\partial K} -(\pmb {q}_{h}\cdot \pmb {\nu },(\hat{u}_{h})_{t})_{\partial K} -(\hat{\pmb {q}}_{h}\cdot \pmb {\nu },(u_{h})_t)_{\partial K}=0, \end{aligned}$$
(2.9)

and with the integration by parts of (2.9), one can obtain

$$\begin{aligned}&((u_{h})_{tt}, (u_{h})_t)_{K}+((u_{h})_t,(u_{h})_{tt})_{K}+((\pmb {q}_{h})_{t}, \pmb {q}_{h})_K+(\pmb {q}_{h},(\pmb {q}_{h})_{t})_K \nonumber \\&\qquad +(\beta (\pmb {x})f(|u_h|^2)u_h,(u_{h})_t)_K +(\beta (\pmb {x})f(|u_h|^2)(u_{h})_t,u_h)_K \nonumber \\&\qquad -H_{\partial K}((u_{h})_t,\pmb {q}_{h};(\hat{u}_{h})_t, \hat{\pmb {q}}_{h})-H_{\partial K}(\pmb {q}_{h},(u_{h})_t;\hat{\pmb {q}}_{h}, (\hat{u}_{h})_t)=0. \end{aligned}$$
(2.10)

Using the results in Lemma 1 and the numerical fluxes (2.3), we can obtain following equation by summing up Eq. (2.10) over all elements \(K\)

$$\begin{aligned} \frac{d}{dt}\left( \Vert (u_{h})_{t}\Vert _{\Omega }^2+\Vert \pmb {q}_{h}\Vert _{\Omega }^2+(\beta (\pmb {x}), F(|u_{h}|^2))_{\Omega }\right) =0. \end{aligned}$$

From this equation we can see that the energy \(E_{h}(t)\) is invariant for all time.\(\square \)

2.4 Error Estimates for the Linear Equation

In this section, we derive the optimal error estimates for the energy conserving LDG method proposed in Sect. 2.2 of the linear Schrödinger equation with wave operator that is

$$\begin{aligned}&u_{tt}-\Delta u+\text{ i }\alpha u_t+\beta (\pmb {x})u=0, \quad (\pmb {x}\in \Omega , \quad 0<t<T). \end{aligned}$$
(2.11)

We will give the energy norm and \(L^2\) norm in the different cases of \(\beta (\pmb {x})\). Moreover, in this section, we omit the subscript \(\Omega \) when need \(\Vert \cdot \Vert _{\Omega }\) for convenience. The proof is based on the rectangular meshes and we will first give some notations and projections on this special meshes.

2.4.1 Notations on Rectangular Meshes

Without loss of generality, we consider a two-dimensional rectangular domain \(\Omega \) and it is easy to be extended to the three-dimensional case. The computational domain is discretized into shape-regular rectangular meshes \(K_{i,j}=I_i\times J_j\) where \(I_i=[x_{i-\frac{1}{2}},x_{i+\frac{1}{2}}],\quad i=1,\ldots , N_x\), and \(J_j=[y_{j-\frac{1}{2}},y_{j+\frac{1}{2}}],\quad j=1,\ldots , N_y\). The center of each mesh is \((x_i,y_j)\) where \(x_i=(x_{i-\frac{1}{2}}+x_{i+\frac{1}{2}})/2\), \(y_j=(y_{j-\frac{1}{2}}+y_{j+\frac{1}{2}})/2\). The mesh sizes are denoted by \(h^x=\max _{1\le i \le N_x} h_i^x\), \(h^y=\max _{1\le j \le N_y} h_j^y\) where \(h_{i}^x=x_{i+\frac{1}{2}}-x_{i-\frac{1}{2}}\), \(h_{j}^y=y_{j+\frac{1}{2}}-y_{j-\frac{1}{2}}\) and \(h=\max (h_x,h_y)\) is the maximal mesh size. We denote by \(u(x_{i+\frac{1}{2}}^{+},y)\) and \(u(x_{i+\frac{1}{2}}^{-},y)\) the values of \(u\) at \(x_{i+\frac{1}{2}}\), from the right cell, \(K_{i+1,j}\), and from the left cell, \(K_{i,j}\), respectively; \(u(x,y_{j+\frac{1}{2}}^{+})\) and \(u(x,y_{j+\frac{1}{2}}^{-})\) are defined in the same way. We denote \(K_{i,j}\) by \(K\) for simple presentation.

Let \({}_c{\mathcal {Q}^{k}(K)}\) denote the space of tensor product of complex polynomials of degree at most \(k\ge 0\) on each element \(K\). In this case the spaces \({}_c{V_{h}}\) and \({}_c{\Sigma _{h}}\) can be written as,

$$\begin{aligned}&{}_c{V_{h}}=\{v\in L^2(\Omega ): \quad v|_K \in {}_c{\mathcal {Q}^{k}(K)}, \quad \forall K\in \mathcal {T}_{h}\},\\&{}_c{\Sigma _{h}}=\{\pmb {\phi }\in [L^2(\Omega )]^d: \quad \pmb {\phi }|_K \in [{}_c{\mathcal {Q}^{k}(K)}]^{d}, \quad \forall K\in \mathcal {T}_{h}\}. \end{aligned}$$

For the one-dimensional case, we have \({}_c{\mathcal {Q}^{k}(K)}={}_c\mathcal {P}^{k}(K)\) which is the space of complex polynomials of degree at most \(k\ge 0\) defined on \(K\).

2.4.2 Projections and Inequalities

We need to introduce some projections and inequalities which will be used to prove the error estimate. We consider the standard \(L^2\) projection \(P\) of a function \(w(\pmb {x})\) with \(k+1\) continuous derivatives into space \({}_c{V_{h}}\), that is

$$\begin{aligned} (P w, v)_{\Omega }=(w,v)_{\Omega }, \end{aligned}$$

for any \(v \in {}_c\mathcal {Q}^k\) on \(K\).

Moreover, we will give two special projections which will be used throughout this paper in the one-dimensional case. The one-dimensional projections \(P_{x}^\pm \) for a complex-valued function \(w\), which project \(w\) into the one-dimensional piecewise polynomial space of degree \(k\) while taking the values of \(w\) at the cell interface, are defined as follows

$$\begin{aligned}&(P_{x}^-w, v)_{I_{i}}=(w,v)_{I_{i}}, \quad \forall v\in {}_c\mathcal {P}^{k-1}(I_{i}) \quad \text{ and } \quad (P_{x}^{-}w)\left( x_{i+\frac{1}{2}}^{-}\right) =w\left( x_{i+\frac{1}{2}}^{-}\right) ,\\&(P_{x}^+w, v)_{I_{i}}=(w,v)_{I_{i}}, \quad \forall v\in {}_c\mathcal {P}^{k-1}(I_{i}) \quad \text{ and } \quad (P_{x}^{+}w)\left( x_{i-\frac{1}{2}}^{+}\right) =w\left( x_{i-\frac{1}{2}}^{+}\right) . \end{aligned}$$

The one-dimensional projections on the \(y\)-direction \(P_{y}^\pm \) are defined in the same way. Since in this paper we use the Cartesian meshes, we can extend the definitions of the above special projections to two dimension on a two-dimensional rectangular element \(K=I_{i}\times J_{j}\) , the projection \(P^-\) for scalar functions is defined as

$$\begin{aligned} P^-=P_{x}^-\otimes P_{y}^-. \end{aligned}$$

The projection \(P^-\) on the Cartesian meshes has the following super-convergence property (see [10], Lemma 3.7).

Lemma 3

(Dong and Shu [10]) Suppose \(\eta \in H^{k+2}(\Omega )\), \(\pmb {\rho } \in {}_c{\Sigma _{h}}\) and the projection \(P^-\), then we have

$$\begin{aligned} |(\eta -P^- \eta ,\nabla \cdot \pmb {\rho })_{\Omega }-(\eta -\widehat{P^- \eta },\pmb {\rho } \cdot \pmb {\nu })_{\Gamma }| \le Ch^{k+1}\Vert \eta \Vert _{H^{k+2}(\Omega )}\Vert \pmb {\rho }\Vert _{\Omega }, \end{aligned}$$

where the “hat” term is the numerical flux.

The projection \(\Pi ^{+}\) for vector-valued functions \(\pmb {\rho }=(\rho _{1}(x,y),\rho _{2}(x,y))\) is defined as

$$\begin{aligned} \Pi ^{+}\pmb {\rho }=(P^{+}_{x}\otimes P_{y} \rho _{1},P_{x}\otimes P^{+}_{y} \rho _{2}), \end{aligned}$$

where \(P_{x}\), \(P_{y}\) are the standard \(L^{2}\) projections in the \(x\) and \(y\) directions, respectively. It is easy to see that for any \(\pmb {\rho } \in [H^{1}(\Omega )]^{2}\), the restriction of \(\Pi ^{+}\pmb {\rho }\) to \(I\otimes J(=K_{i,j})\) is the elements of \([{}_c\mathcal {Q}^{k}(I \otimes J)]^{2}\) that satisfies

$$\begin{aligned} ( \Pi ^{+}\pmb {\rho }-\pmb {\rho },\nabla w)_{I\otimes J}=0, \end{aligned}$$

for any \(w \in [{}_c\mathcal {Q}^{k}(I \otimes J)]\), and

$$\begin{aligned}&{\left( \left( \Pi ^{+}\pmb {\rho }\left( x_{i-\frac{1}{2}},\cdot \right) -\pmb {\rho }\left( x_{i-\frac{1}{2}},\cdot \right) \right) \cdot \pmb {\nu },w\left( x_{i-\frac{1}{2}}^+,\cdot \right) \right) _{J}=0, \quad \forall w \in {}_c\mathcal {Q}^{k}(I \otimes J),}\\&{\left( \left( \Pi ^{+}\pmb {\rho }\left( \cdot ,y_{j-\frac{1}{2}}\right) -\pmb {\rho }\left( \cdot ,y_{j-\frac{1}{2}}\right) \right) \cdot \pmb {\nu },w\left( \cdot ,y_{j-\frac{1}{2}}^+\right) \right) _{I}=0, \quad \forall w \in {}_c\mathcal {Q}^{k}(I \otimes J).} \end{aligned}$$

There are some approximation results for the projections defined above (see, e.g. [10])

$$\begin{aligned}&\Vert \eta ^{e}\Vert _{\Omega } \le Ch^{k+1} \Vert \eta \Vert _{H^{k+1}(\Omega )}, \end{aligned}$$
(2.12)
$$\begin{aligned}&\Vert \pmb {\rho } ^{e}\Vert _{\Omega } \le Ch^{k+1} \Vert \pmb {\rho }\Vert _{H^{k+1}(\Omega )}, \end{aligned}$$
(2.13)

where \(\eta ^{e}=P \eta -\eta \), or \(\eta ^{e}=P^{\pm } \eta -\eta \), \(\pmb {\rho } ^{e}=\Pi ^{\pm } \pmb {\rho }-\pmb {\rho }\) and \(C\) is independent of mesh size \(h\).

2.4.3 A Priori Error Estimates

In order to obtain the error estimates for smooth solutions of the energy conserving LDG scheme, we first give the error equations.

Notice that the LDG scheme is also satisfied when the numerical solutions \(u_{h}\), \(\pmb {q}_{h}\) are replaced by the exact solutions \(u\), \(\pmb {q}=\nabla u\) (the consistency of the LDG scheme). The error equations are as follows

$$\begin{aligned}&((u-u_{h})_{tt}, v)_{K}+(\pmb {q}-\pmb {q}_{h} ,\nabla v)_ K-((\pmb {q}-\hat{\pmb {q}}_{h})\cdot \pmb {\nu },v)_{\partial K}\nonumber \\&\qquad +\text{ i }\alpha ((u-u_h)_t,v)_K+(\beta (\pmb {x})(u-u_h),v)_K=0, \end{aligned}$$
(2.14)
$$\begin{aligned}&(\pmb {q}-\pmb {q}_{h},\pmb {\phi })_K+(u-u_{h}, \nabla \cdot \pmb {\phi })_K-(u-\hat{u}_{h},\pmb {\phi }\cdot \pmb {\nu })_{\partial K}=0. \end{aligned}$$
(2.15)

Denote

$$\begin{aligned}&e_{u}=u-u_{h}=u-Pu+Pu-u_{h}=u-Pu+Pe_{u},\\&e_{\pmb {q}}=\pmb {q}-\pmb {q}_{h}=\pmb {q}-\Pi \pmb {q} +\Pi \pmb {q}-\pmb {q}_{h}=\pmb {q}-\Pi \pmb {q}+\Pi e_{\pmb {q}}. \end{aligned}$$

In this section, we choose the projections as follows without special illustration

$$\begin{aligned}&(P,\Pi )=(P^-,P^+)~~ \text{ in } \text{ one } \text{ dimension },\\&(P,\Pi )=(P^-,\Pi ^+)~~ \text{ in } \text{ multi-dimensions }. \end{aligned}$$

Lemma 4

Assume the initial conditions of the LDG scheme are given by

$$\begin{aligned} u_{h}(\pmb {x},0)=P^{-}u(\pmb {x},0), \quad (u_{h})_{t}(\pmb {x},0)=P u_{t}(\pmb {x},0), \end{aligned}$$
(2.16)

here \(P\) is the standard \(L^2\) norm, then we have

$$\begin{aligned}&\Vert Pe_{u}(0)\Vert =0, \quad \Vert \Pi e_{\pmb {q}}(0)\Vert \le Ch^{k+1},\quad \Vert (Pe_{u})_{t}(0)\Vert \le Ch^{k+1}, \end{aligned}$$
(2.17)
$$\begin{aligned}&((e_{u})_{t}(0),v)_K=0, \quad \forall v \in {}_c{\mathcal {Q}^{k}}. \end{aligned}$$
(2.18)

Proof

Here we only give the proof for the error estimate of \(\Vert \Pi e_{\pmb {q}}(0)\Vert \). The others are obvious.

Taking \(\pmb {\phi }=\Pi e_{\pmb {q}}\) in the error equation of (2.15), we have

$$\begin{aligned} (\pmb {q}-\pmb {q}_{h},\Pi e_{\pmb {q}})_K+(u-u_{h},\nabla \cdot (\Pi e_{\pmb {q}}))_K-(u-\hat{u}_{h},(\Pi e_{\pmb {q}})\cdot \pmb {\nu })_{\partial K}=0. \end{aligned}$$

With the help of the interpolation error estimates (2.12), (2.13) and Lemma 3 we can obtain the initial error estimate of \(\Vert \Pi e_{\pmb {q}}(0)\Vert \)

$$\begin{aligned} \Vert \Pi e_{\pmb {q}}(0)\Vert \le Ch^{k+1}. \end{aligned}$$

We complete the proof.\(\square \)

Lemma 5

Let \(u\) and \(\pmb {q}\) be the exact solutions of Eq. (1.1), and \(u_{h}\), \(\pmb {q}_{h}\) be the numerical solutions of the semi-discrete LDG method with the numerical fluxes in (2.3) and the initial conditions (2.16). Assume the function \(\beta (\pmb {x})\) is bounded and let \(\bar{\beta }=\frac{1}{|\Omega |}\int _{\Omega } |\beta (\pmb {x})|d\pmb {x}\ge 0\), then we have

$$\begin{aligned}&\frac{d}{dt}(\Vert \Pi e_{\pmb {q}}\Vert ^2+\Vert (Pe_{u})_{t}\Vert ^2+\bar{\beta }\Vert Pe_{u}\Vert ^2)\end{aligned}$$
(2.19)
$$\begin{aligned}&\quad \le Ch^{k+1}(\Vert \Pi e_{\pmb {q}}\Vert +\Vert (Pe_{u})_{t}\Vert )+2\max \limits _{\pmb {x}\in \Omega }|\beta (\pmb {x})-\bar{\beta }|\Vert Pe_{u}\Vert \Vert (Pe_{u})_{t}\Vert , \end{aligned}$$
(2.20)

where \(C\) is independent of the size mesh \(h\).

Proof

We take derivative about time in the error Eq. (2.15) and let \(v=(Pe_{u})_{t}\) in (2.14), \(\pmb {\phi }=\Pi e_{\pmb {q}}\) in (2.15), we have

$$\begin{aligned}&((u-u_{h})_{tt}, (Pe_{u})_{t})_{K}+(\pmb {q}-\pmb {q}_{h} ,\nabla (Pe_{u})_{t})_ K-((\pmb {q}-\hat{\pmb {q}}_{h})\cdot \pmb {\nu },(Pe_{u})_{t})_{\partial K}\nonumber \\&\qquad +\text{ i }\alpha ((u-u_h)_t,(Pe_{u})_{t})_K+(\beta (\pmb {x})(u-u_h),(Pe_{u})_{t})_K=0, \end{aligned}$$
(2.21)
$$\begin{aligned}&((\pmb {q}-\pmb {q}_{h})_{t},\Pi e_{\pmb {q}})_K+((u-u_{h})_{t},\nabla \cdot (\Pi e_{\pmb {q}}))_K-((u-\hat{u}_{h})_{t},(\Pi e_{\pmb {q}})\cdot \pmb {\nu })_{\partial K}\nonumber \\&\quad =0, \end{aligned}$$
(2.22)

let \(u-u_{h}=u-Pu+Pe_{u}\), \(\pmb {q}-\pmb {q}_{h}=\pmb {q}-\Pi \pmb {q}+\Pi e_{\pmb {q}}\) and using the properties of the projection \(\Pi \) we can derive

$$\begin{aligned}&((u-Pu)_{tt}, (Pe_{u})_{t})_{K}+\text{ i }\alpha ((u-Pu)_t,(Pe_{u})_{t})_K +\text{ i }\alpha ((Pe_{u})_t,(Pe_{u})_{t})_K\nonumber \\&\qquad +((Pe_{u})_{tt}, (Pe_{u})_{t})_{K}+(\Pi e_{\pmb {q}} , \nabla (Pe_{u})_{t})_ K-((\widehat{\Pi e_{\pmb {q}}})\cdot \pmb {\nu }, (Pe_{u})_{t})_{\partial K}\nonumber \\&\qquad +(\beta (\pmb {x})(u-Pu),(Pe_{u})_{t})_K +(\beta (\pmb {x})(Pe_{u}),(Pe_{u})_{t})_K\nonumber \\&\quad =0, \end{aligned}$$
(2.23)
$$\begin{aligned}&((\pmb {q}-\Pi \pmb {q})_{t},\Pi e_{\pmb {q}})_K+((u-Pu)_{t},\nabla \cdot (\Pi e_{\pmb {q}}))_K-((u-\widehat{Pu})_{t},(\Pi e_{\pmb {q}})\cdot \pmb {\nu })_{\partial K}\nonumber \\&\qquad +((\Pi e_{\pmb {q}})_{t},\Pi e_{\pmb {q}})_K+((Pe_{u})_{t},\nabla \cdot (\Pi e_{\pmb {q}}))_K-((\widehat{Pe_{u}})_{t},(\Pi e_{\pmb {q}})\cdot \pmb {\nu })_{\partial K}\nonumber \\&\quad =0, \end{aligned}$$
(2.24)

and take the conjugate of (2.23) and (2.24), we can obtain

$$\begin{aligned}&((Pe_{u})_{t},(u-Pu)_{tt})_{K}-\text{ i } \alpha ((Pe_{u})_{t},(u-Pu)_t)_K-\text{ i }\alpha ((Pe_{u})_t,(Pe_{u})_{t})_K\nonumber \\&\qquad +((Pe_{u})_{t},(Pe_{u})_{tt})_{K}+(\nabla (Pe_{u})_{t}, \Pi e_{\pmb {q}})_ K-((Pe_{u})_{t},(\widehat{\Pi e_{\pmb {q}}})\cdot \pmb {\nu })_{\partial K}\nonumber \\&\qquad +((Pe_{u})_{t},\beta (\pmb {x})(u-Pu))_K+((Pe_{u})_{t}, \beta (\pmb {x})(Pe_{u}))_K\nonumber \\&\quad =0, \end{aligned}$$
(2.25)
$$\begin{aligned}&(\Pi e_{\pmb {q}},(\pmb {q}-\Pi \pmb {q})_{t})_K+(\nabla \cdot (\Pi e_{\pmb {q}}),(u-Pu)_{t})_K-(\Pi e_{\pmb {q}},(u-\widehat{Pu})_{t}\cdot \pmb {\nu })_{\partial K}\nonumber \\&\qquad +(\Pi e_{\pmb {q}},(\Pi e_{\pmb {q}})_{t})_K+(\nabla \cdot (\Pi e_{\pmb {q}}),(Pe_{u})_{t})_K-((\Pi e_{\pmb {q}})\cdot \pmb {\nu },(\widehat{Pe_{u}})_{t})_{\partial K}\nonumber \\&\quad =0. \end{aligned}$$
(2.26)

By summing up Eqs. (2.23)–(2.26) over all rectangular elements \(K\) and with the integration by parts and let \(\beta (\pmb {x})=(\beta (\pmb {x})-\bar{\beta })+\bar{\beta }\), we can get

$$\begin{aligned}&\frac{d}{dt}(\Vert \Pi e_{\pmb {q}}\Vert ^2+\Vert (Pe_{u})_{t}\Vert ^2+\bar{\beta }\Vert Pe_{u}\Vert ^2)\\&\quad =\sum _{K\in \mathcal {T}_{h}} [H_{\partial K}((Pe_{u})_t,\Pi e_{\pmb {q}};(\widehat{Pe_{u}})_t,\widehat{\Pi e_{\pmb {q}}})\\&\qquad +H_{\partial K}(\Pi e_{\pmb {q}},(Pe_{u})_t;\widehat{\Pi e_{\pmb {q}}},(\widehat{Pe_{u}})_t)]\\&\qquad -[((\pmb {q}-\Pi \pmb {q})_{t},(\Pi e_{\pmb {q}}))_\Omega +((\Pi e_{\pmb {q}}),(\pmb {q}-\Pi \pmb {q})_{t})_\Omega \\&\qquad +((u-Pu)_{tt}, (Pe_{u})_{t})_{\Omega }+((Pe_{u})_{t},(u-Pu)_{tt})_{\Omega }]\\&\qquad -\sum _{K\in \mathcal {T}_{h}}[((u-Pu)_{t},\nabla \cdot (\Pi e_{\pmb {q}}))_K-((u-\widehat{Pu})_{t},(\Pi e_{\pmb {q}})\cdot \pmb {\nu })_{\partial K}\\&\qquad +(\nabla \cdot (\Pi e_{\pmb {q}}),(u-Pu)_{t})_K-(\Pi e_{\pmb {q}},(u-\widehat{Pu})_{t}\cdot \pmb {\nu })_{\partial K}]\\&\qquad -\text{ i }\alpha [((u-Pu)_t,(Pe_{u})_{t})_\Omega -((Pe_{u})_{t},(u-Pu)_t)_\Omega ]\\&\qquad -[(\beta (\pmb {x})(u-Pu),(Pe_{u})_{t})_\Omega +((Pe_{u})_{t},\beta (\pmb {x})(u-Pu))_\Omega ]\\&\qquad -[((\beta (\pmb {x})-\bar{\beta })(Pe_{u}),(Pe_{u})_{t})_\Omega +((Pe_{u})_{t},(\beta (\pmb {x})-\bar{\beta })(Pe_{u}))_\Omega ]. \end{aligned}$$

Now we use the results in Lemma 3, Lemma 1, the Cauchy–Schwartz inequality, and the interpolation error estimates (2.12) and (2.13) to achieve

$$\begin{aligned}&\frac{d}{dt}(\Vert \Pi e_{\pmb {q}}\Vert ^2+\Vert (Pe_{u})_{t}\Vert ^2+\bar{\beta }\Vert Pe_{u}\Vert ^2)\\&\quad \le 2\Vert (\pmb {q}-\Pi \pmb {q})_{t}\Vert \Vert \Pi e_{\pmb {q}}\Vert +2\Vert (u-Pu)_{tt}\Vert \Vert (Pe_{u})_{t}\Vert +C_{1}h^{k+1}\Vert u_{t}\Vert \Vert \Pi e_{\pmb {q}}\Vert \\&\qquad +2\alpha \Vert (u-Pu)_{t}\Vert \Vert (Pe_{u})_{t}\Vert +2\max \limits _{\pmb {x}\in \Omega }|\beta (\pmb {x})|\Vert u-Pu\Vert \Vert (Pe_{u})_{t}\Vert \\&\qquad +2\max \limits _{\pmb {x}\in \Omega }|\beta (\pmb {x})-\bar{\beta }|\Vert Pe_{u}\Vert \Vert (Pe_{u})_{t}\Vert \\&\quad \le Ch^{k+1}(\Vert \Pi e_{\pmb {q}}\Vert +\Vert (Pe_{u})_{t}\Vert )+2\max \limits _{\pmb {x}\in \Omega }|\beta (\pmb {x})-\bar{\beta }|\Vert Pe_{u}\Vert \Vert (Pe_{u})_{t}\Vert . \end{aligned}$$

The last inequality is established because the \(\beta (\pmb {x})\) is bounded.\(\square \)

Theorem 6

Let \(u\) and \(\pmb {q}\) be the exact solutions of Eq. (1.1), and \(u_{h}\), \(\pmb {q}_{h}\) be the numerical solutions of the semi-discrete LDG method with the numerical fluxes in (2.3) and the initial conditions (2.16). For the case that \(\beta (\pmb {x})\) is bounded, nonzero and \(\bar{\beta }=\frac{1}{|\Omega |}\int _{\Omega } |\beta (\pmb {x})|d\pmb {x}> 0\) and \(|\beta (\pmb {x})-\bar{\beta }|\le M\), where \(M\) is a positive constant. Then we have

$$\begin{aligned} \Vert (e_{u})_{t}\Vert \le C\exp (\alpha t) h^{k+1}, \quad \Vert e_{\pmb {q}}\Vert \le C\exp (\alpha t) h^{k+1},\quad \Vert e_{u}\Vert \le C\exp (\alpha t) h^{k+1}, \end{aligned}$$
(2.27)

for any \(t\in [0,T]\) where \(C\) and \(\alpha \) are constants which are independent of the size mesh \(h\) and \(C\) does not depend on \(M\) while \(\alpha \) depends on it.

Proof

From Lemma 5, we have

$$\begin{aligned}&\frac{d}{dt}(\Vert \Pi e_{\pmb {q}}\Vert ^2+\Vert (Pe_{u})_{t}\Vert ^2+\bar{\beta }\Vert Pe_{u}\Vert ^2)\\&\quad \le Ch^{k+1}(\Vert \Pi e_{\pmb {q}}\Vert +\Vert (Pe_{u})_{t}\Vert )+2\max \limits _{\pmb {x}\in \Omega }|\beta (\pmb {x})-\bar{\beta }|\Vert Pe_{u}\Vert \Vert (Pe_{u})_{t}\Vert \\&\quad \le Ch^{2k+2}+\Vert \Pi e_{\pmb {q}}\Vert ^2+\Vert (Pe_{u})_{t}\Vert ^2+M\Vert Pe_{u}\Vert ^2+M\Vert (Pe_{u})_{t}\Vert ^2\\&\quad \le \frac{M}{\bar{\beta }}\bar{\beta }\Vert Pe_{u}\Vert ^2+(M+1)\Vert (Pe_{u})_{t}\Vert ^2+\Vert \Pi e_{\pmb {q}}\Vert ^2+Ch^{2k+2}\\&\quad \le \max {\left( \frac{M}{\bar{\beta }},M+1,1\right) }(\Vert \Pi e_{\pmb {q}}\Vert ^2+\Vert (Pe_{u})_{t}\Vert ^2+\bar{\beta }\Vert Pe_{u}\Vert ^2)+Ch^{2k+2}, \end{aligned}$$

let \(\alpha =\max (\frac{M}{\bar{\beta }},M+1,1)\) and by using the Gronwall inequality and Lemma 4 we can obtain,

$$\begin{aligned}&\Vert (Pe_{u})_{t}\Vert \le C\exp (\alpha t) h^{k+1},\\&\Vert \Pi e_{\pmb {q}}\Vert \le C\exp (\alpha t) h^{k+1},\\&\Vert Pe_{u}\Vert \le C\exp (\alpha t) h^{k+1}. \end{aligned}$$

Together with the approximation errors in (2.12) and (2.13), the error estimate (2.27) can be derived. All the \(C\) in the proof may be different.\(\square \)

Remark 7

From this theorem we have derived the optimal energy norm and \(L^2\) norm error even though the coefficients of the estimates are exponential increase. Indeed, if the function \(\beta (\pmb {x})\) is positive constant, without loss of generality we assume \(\beta (\pmb {x})=1\) and at this case \(M=0\), we can obtain a linear increase about the coefficients of the estimate by suffering a little modification in the proof. That is

$$\begin{aligned}&\max \limits _{t\in [0,T]}\Vert (e_{u})_{t}\Vert \le Ch^{k+1}(T+1) , \quad \max \limits _{t\in [0,T]}\Vert e_{\pmb {q}}\Vert \le Ch^{k+1}(T+1),\nonumber \\&\max \limits _{t\in [0,T]}\Vert e_{u}\Vert \le Ch^{k+1}(T+1). \end{aligned}$$
(2.28)

However, when the function \(\beta (\pmb {x})\) is negative constant, we could not obtain the same result.

In the next, we will give the estimates when the function \(\beta (\pmb {x})=0\).

Theorem 8

Let \(u\) and \(\pmb {q}\) be the exact solutions of Eq. (1.1), and \(u_{h}\), \(\pmb {q}_{h}\) be the numerical solutions of the semi-discrete LDG method with the numerical fluxes in (2.3) and the initial conditions (2.16) and \(\beta (\pmb {x})=0\) we have the following error estimates

$$\begin{aligned} \Vert (e_{u})_{t}\Vert \le Ch^{k+1}(t+1) , \quad \Vert e_{\pmb {q}}\Vert \le Ch^{k+1}(t+1),\quad for~ t\in [0,T], \end{aligned}$$
(2.29)

and the \(L^2\) norm estimate

$$\begin{aligned} \max \limits _{t\in [0,T]}\Vert e_{u}(t)\Vert \le C (T+1)^2h^{k+1}, \end{aligned}$$
(2.30)

where \(C\) is independent of the mesh size \(h\).

Proof

  • Estimates of \(\Vert \Pi e_{\pmb {q}}\Vert \) and \(\Vert (Pe_{u})_{t}\Vert \)

We first give the estimates in the sense of energy that is the inequality (2.29). Since \(\beta (\pmb {x})=0\), Lemma 5 can be written as

$$\begin{aligned}&\frac{d}{dt}(\Vert \Pi e_{\pmb {q}}\Vert ^2+\Vert (Pe_{u})_{t}\Vert ^2)\\&\quad \le Ch^{k+1}(\Vert \Pi e_{\pmb {q}}\Vert +\Vert (Pe_{u})_{t}\Vert )\\&\quad \le Ch^{k+1}(\Vert \Pi e_{\pmb {q}}\Vert ^2+\Vert (Pe_{u})_{t}\Vert ^2)^{\frac{1}{2}} \end{aligned}$$

which leads to

$$\begin{aligned} \frac{d}{dt}(\Vert \Pi e_{\pmb {q}}\Vert ^2+\Vert (Pe_{u})_{t}\Vert ^2)^{\frac{1}{2}}\le Ch^{k+1}. \end{aligned}$$

After using the property of the initial condition (2.17) and integrating this equation with respect to time between 0 and \(t\) we can obtain

$$\begin{aligned} (\Vert \Pi e_{\pmb {q}}\Vert ^2+\Vert (Pe_{u})_{t}\Vert ^2)^{\frac{1}{2}}\le C(t+1)h^{k+1}. \end{aligned}$$

Together with the approximation errors in (2.12) and (2.13), the error estimates (2.29) can be obtained.

  • Estimate of \(\Vert (Pe_{u})\Vert \)

Then we give the \(L^2\) norm error estimate. By using the property of \(\Pi \) and the chain rule in time derivative we can rewrite the error Eq. (2.14) as

$$\begin{aligned}&- ((Pe_{u})_{t}, v_{t})_{K}+(\Pi e_{\pmb {q}} ,\nabla v)_ K-((\widehat{\Pi e_{\pmb {q}}})\cdot \pmb {\nu },v)_{\partial K}+\text{ i }\alpha ((u-u_h)_t,v)_K\nonumber \\&\quad =-((u-Pu)_{tt},v)_{K}-\frac{d}{dt}((Pe_{u})_{t},v)_{K}. \end{aligned}$$
(2.31)

For any time \(\tau \le T\), denote

$$\begin{aligned}&\bar{E}_{u}(t)=\int _{t}^{\tau } Pe_{u}(s)ds, \quad \bar{E}_{\pmb {q}}(t)=\int _{t}^{\tau } \Pi e_{\pmb {q}}(s)ds,\\&E_{u}^{\varepsilon }(t)=\int _{t}^{\tau } (u-Pu)(s)ds, \quad E_{\pmb {q}}^{\varepsilon }(t)=\int _{t}^{\tau } (\pmb {q}-\Pi \pmb {q})(s)ds. \end{aligned}$$

We take the integral of the error Eq. (2.15) between \(t\) and \(\tau \), then we have

$$\begin{aligned}&(E_{\pmb {q}}^{\varepsilon },\pmb {\phi })_{K}+(E_{u}^{\varepsilon },\nabla \cdot \pmb {\phi })_{K}-(\hat{E}_{u}^{\varepsilon },\pmb {\phi }\cdot \pmb {\nu })_{\partial K}\nonumber \\&\qquad +(\bar{E}_{\pmb {q}},\pmb {\phi })_{K}+(\bar{E}_{u},\nabla \cdot \pmb {\phi })_{K}-(\hat{\bar{E}}_{u},\pmb {\phi }\cdot \pmb {\nu })_{\partial K}=0. \end{aligned}$$
(2.32)

We choose the test function to be \(v=\bar{E}_{u}(t)\) in (2.31) and \(\pmb {\phi }=\Pi e_{\pmb {q}}\) in (2.32), we can achieve

$$\begin{aligned}&((Pe_{u})_{t},Pe_{u})_{K}+(\Pi e_{\pmb {q}} ,\nabla \bar{E}_{u})_ K-((\widehat{\Pi e_{\pmb {q}}})\cdot \pmb {\nu },\bar{E}_{u})_{\partial K}+\text{ i }\alpha ((u-u_h)_t,\bar{E}_{u})_K\nonumber \\&\quad =-((u-Pu)_{tt},\bar{E}_{u})_{K} -\frac{d}{dt}((Pe_{u})_{t},\bar{E}_{u})_{K},\end{aligned}$$
(2.33)
$$\begin{aligned}&(E_{\pmb {q}}^{\varepsilon },\Pi e_{\pmb {q}})_{K} +(E_{u}^{\varepsilon },\nabla \cdot (\Pi e_{\pmb {q}}))_{K} -(\hat{E}_{u}^{\varepsilon },(\Pi e_{\pmb {q}})\cdot \pmb {\nu })_{\partial K}\nonumber \\&\qquad +(\bar{E}_{\pmb {q}},\Pi e_{\pmb {q}})_{K} +(\bar{E}_{u},\nabla \cdot (\Pi e_{\pmb {q}}))_{K} -(\hat{\bar{E}}_{u},(\Pi e_{\pmb {q}})\cdot \pmb {\nu })_{\partial K}=0, \end{aligned}$$
(2.34)

and take the conjugate of (2.33) and (2.34), we can obtain

$$\begin{aligned}&(Pe_{u},(Pe_{u})_{t})_{K}+(\nabla \bar{E}_{u},\Pi e_{\pmb {q}})_ K-(\bar{E}_{u},(\widehat{\Pi e_{\pmb {q}}})\cdot \pmb {\nu })_{\partial K}-\text{ i }\alpha (\bar{E}_{u},(u-u_h)_t)_K\nonumber \\&\quad =-(\bar{E}_{u},(u-Pu)_{tt})_{K}-\frac{d}{dt}(\bar{E}_{u}, (Pe_{u})_{t})_{K},\end{aligned}$$
(2.35)
$$\begin{aligned}&(\Pi e_{\pmb {q}},E_{\pmb {q}}^{\varepsilon })_{K} +(\nabla \cdot (\Pi e_{\pmb {q}}),E_{u}^{\varepsilon })_{K} -((\Pi e_{\pmb {q}})\cdot \pmb {\nu },\hat{E}_{u}^{\varepsilon })_{\partial K}\nonumber \\&\qquad +(\Pi e_{\pmb {q}},\bar{E}_{\pmb {q}})_{K} +(\nabla \cdot (\Pi e_{\pmb {q}}),\bar{E}_{u})_{K} -((\Pi e_{\pmb {q}})\cdot \pmb {\nu },\hat{\bar{E}}_{u})_{\partial K}=0. \end{aligned}$$
(2.36)

Let

$$\begin{aligned}&\mathcal {I}=-\text{ i }\alpha [((u-u_h)_t,\bar{E}_{u})_\Omega -(\bar{E}_{u},(u-u_h)_t)_\Omega ],\\&\mathcal {II}=-\left[ ((u-Pu)_{tt},\bar{E}_{u})_{\Omega } +\frac{d}{dt}((Pe_{u})_{t},\bar{E}_{u})_{\Omega } +(\bar{E}_{u},(u-Pu)_{tt})_{\Omega }\right. \\&\qquad \left. +\frac{d}{dt}(\bar{E}_{u},(Pe_{u})_{t})_{\Omega }\right] -[(E_{\pmb {q}}^{\varepsilon },\Pi e_{\pmb {q}})_{\Omega } +(\Pi e_{\pmb {q}},E_{\pmb {q}}^{\varepsilon })_{\Omega }]\\&\quad =-[((u-Pu)_{t},Pe_{u})_{\Omega } +\frac{d}{dt}((u-u_{h})_{t},\bar{E}_{u})_{\Omega }+(E_{\pmb {q}}^{\varepsilon },\Pi e_{\pmb {q}})_{\Omega }\\&\qquad +(Pe_{u},(u-Pu)_{t})_{\Omega } +\frac{d}{dt}(\bar{E}_{u},(u-u_{h})_{t})_{\Omega }+(\Pi e_{\pmb {q}},E_{\pmb {q}}^{\varepsilon })_{\Omega }],\\&\mathcal {III}=-\sum _{K \in \mathcal {T}_{h}}[(E_{u}^{\varepsilon },\nabla \cdot (\Pi e_{\pmb {q}}))_{K}-(\hat{E}_{u}^{\varepsilon },(\Pi e_{\pmb {q}})\cdot \pmb {\nu })_{\partial K}+(\nabla \cdot (\Pi e_{\pmb {q}}),E_{u}^{\varepsilon })_{K}\\&\qquad -((\Pi e_{\pmb {q}})\cdot \pmb {\nu },\hat{E}_{u}^{\varepsilon })_{\partial K}],\\&\mathcal {IV}=\sum _{K \in \mathcal {T}_{h}}[H_{\partial K}(\bar{E}_u, \Pi e_{\pmb {q}}; \hat{\bar{E}}_u, \widehat{\Pi e_{\pmb {q}}}) +H_{\partial K}(\Pi e_{\pmb {q}},\bar{E}_u; \widehat{\Pi e_{\pmb {q}}}, \hat{\bar{E}}_u)]. \end{aligned}$$

By summing up Eq. (2.33)–(2.36) over all rectangular elements \(K\) and noticing the opposite fluxes in (2.3), using the periodic or homogenous Dirichlet boundary conditions and Lemma 1, we get

$$\begin{aligned} \frac{d}{dt}(\Vert Pe_{u}\Vert ^2-\Vert \bar{E}_{\pmb {q}}\Vert ^2) =\mathcal {I}+\mathcal {II}+\mathcal {III}+\mathcal {IV} =\mathcal {I}+\mathcal {II}+\mathcal {III}. \end{aligned}$$
(2.37)

By integrating Eq. (2.37) from 0 to \(\tau \) and using the fact \(\bar{E}_{\pmb {q}}(\tau )=0\) we have

$$\begin{aligned} \Vert Pe_{u}(\tau )\Vert ^2-\Vert Pe_{u}(0)\Vert ^2+\Vert \bar{E}_{\pmb {q}}(0)\Vert ^2 =\int _{0}^{\tau }(\mathcal {I}+\mathcal {II}+\mathcal {\mathcal {III}}) dt. \end{aligned}$$

Note that

$$\begin{aligned} E_{\pmb {q}}^{\varepsilon }(t)=\int _{t}^{\tau } (\pmb {q}-\Pi \pmb {q})(s)ds=\left( \int _{t}^{\tau } \pmb {q}(s)ds\right) -\Pi \left( \int _{t}^{\tau } \pmb {q}(s)ds\right) , \end{aligned}$$

and the definition of \(\bar{E}_u(t)\), we have \(\Vert E_{\pmb {q}}^{\varepsilon }\Vert \le Ch^{k+1}\) and \(\Vert \bar{E}_{u}\Vert \le C T\max \limits _{t\in [0,T]}\Vert Pe_{u}\Vert \).

Since we have \(\bar{E}_{u}(\tau )=0\) , the initial error estimate (2.18), the results in Lemma 3 and the inequality (2.29), we can obtain

$$\begin{aligned} \left| \int _{0}^{\tau } \mathcal {II} dt\right|&\le 2\int _{0}^{\tau } \Vert (u-Pu)_{t}\Vert \Vert Pe_{u}\Vert dt+2\int _{0}^{\tau } \Vert E_{\pmb {q}}^{\varepsilon }\Vert \Vert \Pi e_{\pmb {q}}\Vert dt\\&\le 2\tau \max \limits _{t\in [0,T]}\Vert (u-Pu)_{t}\Vert \max \limits _{t\in [0,T]}\Vert Pe_{u}\Vert +2\tau \max \limits _{t\in [0,T]}\Vert E_{\pmb {q}}^{\varepsilon }\Vert \max \limits _{t\in [0,T]}\Vert \Pi e_{\pmb {q}}\Vert \\&\le 2T(\max \limits _{t\in [0,T]}\Vert (u-Pu)_{t}\Vert \max \limits _{t\in [0,T]}\Vert Pe_{u}\Vert +\max \limits _{t\in [0,T]}\Vert E_{\pmb {q}}^{\varepsilon }\Vert \max \limits _{t\in [0,T]}\Vert \Pi e_{\pmb {q}}\Vert )\\&\le CT(h^{k+1}\max \limits _{t\in [0,T]}\Vert Pe_{u}\Vert +(T+1)h^{2k+2} );\\ \left| \int _{0}^{\tau } \mathcal {III} dt\right|&\le 2\int _{0}^{\tau } C h^{k+1} \Vert \Pi e_{\pmb {q}}\Vert dt\\&\le 2Ch^{k+1} \tau \max \limits _{t\in [0,T]}\Vert \Pi e_{\pmb {q}}\Vert \\&\le CT(T+1)h^{2k+2};\\ \left| \int _{0}^{\tau } \mathcal {I} dt\right|&\le 2\alpha \int _{0}^{\tau }\Vert (e_{u})_{t}\Vert \Vert \bar{E}_{u}\Vert dt\\&\le 2\alpha \int _{0}^{\tau } \Vert (e_{u})_{t}\Vert CT \max \limits _{t\in [0,T]}\Vert Pe_{u}\Vert dt\\&\le 2\alpha CT \tau \max \limits _{t\in [0,T]}\Vert (e_{u})_{t}\Vert \max \limits _{t\in [0,T]}\Vert Pe_{u}\Vert \\&\le CT^2(T+1)h^{k+1}\max \limits _{t\in [0,T]}\Vert Pe_{u}\Vert . \end{aligned}$$

Summing up all these three equations and noticing that the \(\Vert Pe_{u}(0)\Vert =0\) in the initial error estimates (2.17) and using the fact

$$\begin{aligned} ab\le \frac{a^2}{4}+b^2, \end{aligned}$$

we have

$$\begin{aligned}&\max \limits _{t\in [0,T]}\Vert Pe_{u}\Vert ^2+\Vert \bar{E}_{\pmb {q}}(0)\Vert ^2 \\&\quad \le CT(h^{k+1}\max \limits _{t\in [0,T]}\Vert Pe_{u}\Vert +2(T+1)h^{2k+2}+T(T+1)h^{k+1}\max \limits _{t\in [0,T]}\Vert Pe_{u}\Vert )\\&\quad \le C[(T^2+2T+2)h^{2k+2}+T^{2}(T+1)^2h^{2k+2}]+\frac{1}{2}\max \limits _{t\in [0,T]}\Vert Pe_{u}\Vert ^2\\&\quad \le C(T+1)^4 h^{2k+2}+\frac{1}{2}\max \limits _{t\in [0,T]}\Vert Pe_{u}\Vert ^2. \end{aligned}$$

From this equation we can conclude

$$\begin{aligned} \max \limits _{t\in [0,T]}\Vert Pe_{u}\Vert \le C(T+1)^2h^{k+1}, \end{aligned}$$

combining with the approximation error we have

$$\begin{aligned} \max \limits _{t\in [0,T]}\Vert e_{u}(t)\Vert \le C(T+1)^2h^{k+1}, \end{aligned}$$

where \(C\) is independent of \(h\). And the constant \(C\) may be different in different equations.\(\square \)

3 Time Discretization

In this section we extend the semi-discrete LDG method to the fully discrete method which can also conserve the energy. Here we consider the Crank–Nicholson scheme based on the LDG method for space discretization, which is well-known to conserve the energy.

3.1 Difference Operators

In this section, we introduce some difference operators about time which will be used throughout the next contents. Let \(0=t_0<t_1< \cdots <t_N=T\) be a partition of the interval \([0,T]\) with the time step \(\Delta t_n=t_{n+1}-t_{n}\). Here we use the uniform time step \(\Delta t\) and \(u^{n}\) is the numerical value at \(t=t_{n}\).

Forward difference operator

$$\begin{aligned} \Delta _{+}u^n=\frac{u^{n+1}-u^{n}}{\Delta t}. \end{aligned}$$

Backward difference operator

$$\begin{aligned} \Delta _{-}u^n=\frac{u^{n}-u^{n-1}}{\Delta t}. \end{aligned}$$

Central difference operator

$$\begin{aligned} \delta u^n=\frac{u^{n+1}-u^{n-1}}{2\Delta t}. \end{aligned}$$

Second-order central difference operator

$$\begin{aligned} \delta ^{2}u^n=\frac{\Delta _{+}u^n-\Delta _{-}u^n}{\Delta t}=\frac{u^{n+1}-2u^{n}+u^{n-1}}{\Delta t ^{2}}. \end{aligned}$$

Average value operator

$$\begin{aligned} \bar{\delta }u^n=\frac{u^{n+1}+u^{n-1}}{2}. \end{aligned}$$

3.2 Time Discretization

The fully discrete approximation \(u_{h}^{n}=u(\cdot ,t_n)\) of Eq. (1.1) are shown as follows

$$\begin{aligned}&(\delta ^{2} u_{h}, v)_{K}+(\bar{\delta }\pmb {q}_{h} ,\nabla v)_ K-(\bar{\delta }\hat{\pmb {q}}_{h}\cdot \pmb {\nu },v)_{\partial K}+\text{ i }\alpha (\delta u_h,v)_K+(G \bar{\delta } u_h,v)_K=0, \end{aligned}$$
(3.1)
$$\begin{aligned}&(\pmb {q}_{h}^{n+1},\pmb {\phi })_K+(u_{h}^{n+1},\nabla \cdot \pmb {\phi })_K -(\hat{u}_{h}^{n+1},\pmb {\phi }\cdot \pmb {\nu })_{\partial K}=0, \end{aligned}$$
(3.2)
$$\begin{aligned}&(\pmb {q}_{h}^{n-1},\pmb {\phi })_K+(u_{h}^{n-1},\nabla \cdot \pmb {\phi })_K -(\hat{u}_{h}^{n-1},\pmb {\phi }\cdot \pmb {\nu })_{\partial K}=0, \end{aligned}$$
(3.3)

for all test functions \(v \in {}_c{V_{h}}\) and \(\pmb {\phi } \in c^{\Sigma _{h}}\) and the numerical fluxes are defined in (2.3), where \(G=\beta (\pmb {x}) \frac{F(|u_{h}^{n+1}|^2)-F(|u_{h}^{n-1}|^2)}{|u_{h}^{n+1}|^2-|u_{h}^{n-1}|^2}\). We can see this scheme is implicit.

We have shown that the semi-discrete LDG method conserves the time continuous energy \(E_{h}(t)\) in Sect. 2.3. Similarly, we can show the energy conservation property for the fully time discrete method.

Proposition 9

The solutions to the fully discrete LDG method (3.1)–(3.3) conserves the discrete energy

$$\begin{aligned} E_{h}^{n+1}=\left\| \frac{u_{h}^{n+1}-u_{h}^{n}}{\Delta t}\right\| ^2\!+\!\frac{\left\| \pmb {q}_{h}^{n+1}\right\| ^2 \!+\!\left\| \pmb {q}_{h}^n\right\| ^2}{2}+\int _{\Omega } \beta (\pmb {x})\frac{F\left( |u_{h}^{n+1}|^2\right) +F\left( |u_{h}^n|^2\right) }{2}d\Omega =E_{h}^{n}, \end{aligned}$$
(3.4)

for all \(n\).

Proof

In Eq. (3.1), let the test function \(v=\delta u_h\), we can obtain

$$\begin{aligned}&(\delta ^{2} u_{h}, \delta u_h)_{K}+(\bar{\delta }\pmb {q}_{h} ,\nabla \delta u_h)_ K-(\bar{\delta }\hat{\pmb {q}}_{h}\cdot \pmb {\nu },\delta u_h)_{\partial K}+\text{ i }\alpha (\delta u_h,\delta u_h)_K\nonumber \\&\quad +(G \bar{\delta } u_h,\delta u_h)_K =0, \end{aligned}$$
(3.5)

and take the conjugate of (3.5) to get

$$\begin{aligned}&(\delta u_h,\delta ^{2} u_{h})_{K}+(\nabla \delta u_h,\bar{\delta }\pmb {q}_{h})_ K-(\delta u_h,\bar{\delta }\hat{\pmb {q}}_{h}\cdot \pmb {\nu })_{\partial K}-\text{ i }\alpha (\delta u_h,\delta u_h)_K\nonumber \\&\quad +(G\delta u_h, \bar{\delta } u_h)_K=0. \end{aligned}$$
(3.6)

In Eqs. (3.2) and (3.3), we choose the test function to be \(\pmb {\phi }=\bar{\delta } \pmb {q}_{h}/\Delta t\), we have

$$\begin{aligned} \left( \pmb {q}_{h}^{n+1},\bar{\delta } \pmb {q}_{h}/\Delta t\right) _K+\left( u_{h}^{n+1},\nabla \cdot \bar{\delta } \pmb {q}_{h}/\Delta t\right) _K-\left( \hat{u}_{h}^{n+1},\bar{\delta } \pmb {q}_{h}/\Delta t\cdot \pmb {\nu }\right) _{\partial K}=0, \end{aligned}$$
(3.7)
$$\begin{aligned} \left( \pmb {q}_{h}^{n-1},\bar{\delta } \pmb {q}_{h}/\Delta t\right) _K+\left( u_{h}^{n-1},\nabla \cdot \bar{\delta } \pmb {q}_{h}/\Delta t\right) _K-\left( \hat{u}_{h}^{n-1},\bar{\delta } \pmb {q}_{h}/\Delta t\cdot \pmb {\nu }\right) _{\partial K}=0, \end{aligned}$$
(3.8)

subtracting (3.7) and (3.8) yields

$$\begin{aligned} (\delta \pmb {q}_{h},\bar{\delta } \pmb {q}_{h})_K+(\delta u_{h},\nabla \cdot \bar{\delta } \pmb {q}_{h})_K-(\delta \hat{u}_{h},\bar{\delta } \pmb {q}_{h}\cdot \pmb {\nu })_{\partial K}=0, \end{aligned}$$
(3.9)

and its conjugate

$$\begin{aligned} (\bar{\delta } \pmb {q}_{h},\delta \pmb {q}_{h})_K+(\nabla \cdot \bar{\delta } \pmb {q}_{h},\delta u_{h})_K-(\bar{\delta } \pmb {q}_{h}\cdot \pmb {\nu },\delta \hat{u}_{h})_{\partial K}=0. \end{aligned}$$
(3.10)

We add Eqs. (3.5)–(3.6) and (3.9)–(3.10) to get

$$\begin{aligned}&(\delta ^{2} u_{h}, \delta u_h)_{K}+(\delta u_h,\delta ^{2} u_{h})_{K}+(\delta \pmb {q}_{h},\bar{\delta } \pmb {q}_{h})_K\nonumber \\&\qquad +(\bar{\delta } \pmb {q}_{h},\delta \pmb {q}_{h})_K+(G \bar{\delta } u_h,\delta u_h)_K+(G\delta u_h, \bar{\delta } u_h)_K\nonumber \\&\quad =-\{(\bar{\delta }\pmb {q}_{h} ,\nabla \delta u_h)_ K+(\nabla \delta u_h,\bar{\delta }\pmb {q}_{h})_ K+(\delta u_{h},\nabla \cdot \bar{\delta } \pmb {q}_{h})_K+(\nabla \cdot \bar{\delta } \pmb {q}_{h},\delta u_{h})_K\nonumber \\&\qquad -[(\bar{\delta }\hat{\pmb {q}}_{h}\cdot \pmb {\nu },\delta u_h)_{\partial K}+(\delta u_h,\bar{\delta }\hat{\pmb {q}}_{h}\cdot \pmb {\nu })_{\partial K}+(\delta \hat{u}_{h},\bar{\delta } \pmb {q}_{h}\cdot \pmb {\nu })_{\partial K}+(\bar{\delta } \pmb {q}_{h}\cdot \pmb {\nu },\delta \hat{u}_{h})_{\partial K}] \}, \end{aligned}$$
(3.11)

and with the integration by parts of (3.11), one can obtain

$$\begin{aligned}&(\delta ^{2} u_{h}, \delta u_h)_{K}+(\delta u_h,\delta ^{2} u_{h})_{K}+(\delta \pmb {q}_{h},\bar{\delta } \pmb {q}_{h})_K\nonumber \\&\qquad +(\bar{\delta } \pmb {q}_{h},\delta \pmb {q}_{h})_K+(G \bar{\delta } u_h,\delta u_h)_K+(G\delta u_h, \bar{\delta } u_h)_K\nonumber \\&\quad =H_{\partial K}(\delta u_h, \bar{\delta }\pmb {q}_{h};\delta \hat{u_h}, \bar{\delta }\hat{\pmb {q}}_{h})+H_{\partial K}(\bar{\delta }\pmb {q}_{h},\delta u_h ;\bar{\delta }\hat{\pmb {q}}_{h},\delta \hat{u_h}). \end{aligned}$$
(3.12)

Noticing Lemma 1 and summing up Eq. (3.12) over all elements \(K\), after some calculations we can obtain

$$\begin{aligned}&2\times \frac{1}{2 \Delta t}\left[ \left\| \frac{u_{h}^{n+1}-u_{h}^{n}}{\Delta t}\right\| ^2-\left\| \frac{u_{h}^{n}-u_{h}^{n-1}}{\Delta t}\right\| ^2\right] \nonumber \\&\qquad +2\times \frac{1}{2 \Delta t}\left[ \frac{\left\| \pmb {q}_{h}^{n+1}\right\| ^2+\left\| \pmb {q}_{h}^n\right\| ^2}{2} -\frac{\left\| \pmb {q}_{h}^{n}\right\| ^2+\left\| \pmb {q}_{h}^{n-1}\right\| ^2}{2}\right] \nonumber \\&\qquad +2\times \frac{1}{2 \Delta t} \left[ \int _{\Omega } \beta (\pmb {x})\frac{F(|u_{h}^{n+1}|^2)+F(|u_{h}^n|^2)}{2}d\Omega \right. \nonumber \\&\qquad \left. -\int _{\Omega } \beta (\pmb {x})\frac{F(|u_{h}^{n}|^2)+F(|u_{h}^{n-1}|^2)}{2}d\Omega \right] =0, \end{aligned}$$
(3.13)

from Eq. (3.13) and the definition of \(E_{h}^n\) in (3.4), we have \(E_{h}^{n+1}=E_{h}^{n}\) for all \(n\). This illustrates the discrete energy is conserved by using this fully discrete method.\(\square \)

This fully discrete scheme is unconditionally stable and since we use the Crank–Nicholson scheme on the time space the fully scheme has second order accuracy. From Proposition 9 we know this method can maintain the energy.

Remark

There are some conservative high order temporal discretization in [13] such as multi-stage Runge–Kutta methods and symmetric methods. However, they conserve linear first integrals [20] and it is difficult to prove the energy conversation of the fully discrete scheme if we use the high order ones on time space. Therefore, in this paper we only consider the Crank–Nichoson scheme and in the future we will study the high order schemes for the time discretization.

3.3 Implementation of the Fully Discrete Scheme

The fully discrete scheme (3.1)–(3.3) will result in the following nonlinear algebraic equation

$$\begin{aligned} \pmb {u}_h^{n+1} = \mathcal {L}(\pmb {u}_h^{n-1}, \pmb {u}_h^{n}, \pmb {u}_h^{n+1}) + \mathcal {N}(\pmb {u}_h^{n-1}, \pmb {u}_h^{n+1}), \end{aligned}$$
(3.14)

where \(\pmb {u}_h\) denotes the vector containing the degrees of freedom for \(u_h\), \(\mathcal {L}(\pmb {u}_h^{n-1}, \pmb {u}_h^{n}, \pmb {u}_h^{n+1})\) is a linear function of \(\pmb {u}_h^{n-1}, \pmb {u}_h^{n}, \pmb {u}_h^{n+1}\) and \(\mathcal {N}\) is a nonlinear function of \(\pmb {u}_h^{n-1}, \pmb {u}_h^{n+1}\).

For the nonlinear term \(\mathcal {N}(\pmb {u}_h^{n-1}, \pmb {u}_h^{n+1})\), we use Newton method to linearize the nonlinear system. In each Newton iteration, we will solve the linear equation system

$$\begin{aligned} A\pmb {u}_h^{n+1}=B\pmb {u}_h^{n}+C\pmb {u}_h^{n-1}, \end{aligned}$$
(3.15)

where \(A\), \(B\) and \(C\) are matrices depending on \(\pmb {u}_h^{n}\) and \(\pmb {u}_h^{n-1}\). Then we use iterative approach (\(GMRES\)) to solve the linear system (3.15).

4 Numerical Results

In this section, we give some numerical examples in multi-dimensional spaces to illustrate the validity and capability of the conservative method which we have developed above.

4.1 One-Dimensional Case

In this subsection, numerical experiments in the one-dimensional case are designed to show the performance of the conservative scheme. Since the second order central difference is used on time discretization and we mainly concern the effect of the spatial discretization, we use the time step \(\Delta t=cfl* h^2\). This relation guarantees that the error will be dominated by the spatial discretization.

Example 4.1

We consider the case of \(\alpha =\beta =1\) and let \(f(|u|^2)=1\) in Eq. (1.1) to obtain

$$\begin{aligned} u_{tt}-u_{xx}+\text{ i }u_t+u=0, \quad x \in [0,2\pi ], \end{aligned}$$

where the exact solution is \(u(x,t)=\text{ exp }(\text{ i }(x+t))\) and the boundary condition is periodic.

Example 4.1 aims to test the accuracy and the advantage of the conservative scheme. The result can be found in Table 1. We give the \(L^2\) and \(L^{\infty }\) error of the real part and the image part respectively to show the accuracy. From the table, we can observe that the conservative scheme mentioned above with the space of polynomials with degree \(k\) has \((k+1)\)th order of accuracy. The table demonstrates that numerical results are consistent with the theoretical result which we have proved in Sect. 2.4.3.

Table 1 Example 4.1, accuracy test at time \(T=\pi ^2\) with the conservative scheme

In Fig. 1, we give the numerical solutions with the conservative scheme and the LDG scheme with the explicit time discretization until time \(T=200\pi ^2\) with the uniform mesh \(N=40\) and the degree of polynomials is 2. From this figure, we can conclude the solution of conservative scheme almost overlaps the exact solution while the LDG scheme with explicit time discretization maintains the shape but has a phase shift. Moreover, in Fig. 2, we give the energy time evolution and we can see that the numerical energy is conserved by the conservative scheme. For the LDG scheme with explicit time discretization, the numerical energy is not conserved very well.

Example 4.2

Let us consider the case of \(\alpha =1\), \(\beta (x)=\text{ exp }(-x^2)\) and let \(f(|u|^2)=1\) in Eq. (1.1) with the initial condition

$$\begin{aligned} u_0(x)=\text{ exp }(\text{ i }x), \quad u_1(x)=\text{ i }\text{ exp }(\text{ i }x),\quad x \in [0,2\pi ]. \end{aligned}$$

We use periodic boundary condition in this example.

Fig. 1
figure 1

Example 4.1, left the exact solution and the numerical solution with the conservative scheme; right the exact solution and the numerical solution with the nonconservative scheme. \(T=200\pi ^2\)

Fig. 2
figure 2

Example 4.1, The energy time evolution for \(T=200\pi ^2\)

In Fig. 3, we give the time evolution of \(|u|\) of NLSW with the variable \(\beta (x)\) by using the conservative scheme with \(p^2\) polynomials and the uniform mesh \(N=160\). The difference between Examples 4.1 and 4.2 is the value of \(\beta (x)\). We can observe that the value of \(|u|\) is equal to 1 in Example 4.1 while in Example 4.2 it is not.

Fig. 3
figure 3

Example 4.2, the figure time evolution of \(|u|\) by the using conservative scheme with \(p^2\) polynomials and \(N=160\)

Example 4.3

We give an example with the parameters as

$$\begin{aligned} \alpha =\beta =1,\quad f(|u|^2)=|u|^2, \end{aligned}$$

with the initial condition

$$\begin{aligned} u_{0}(x)=(1+\text{ i })x e^{-10(1-x)^2},\quad u_{1}(x)=0, \end{aligned}$$

and the computational domain

$$\begin{aligned} x\in [-40,40], \end{aligned}$$

where we use the homogenous Dirichlet boundary conditions.

Fig. 4
figure 4

Example 4.3, the movement of soliton \(|u|\) by using the conservative scheme with the degree of polynomial \(k=2\) and the mesh size \(h=0.05\)

In Fig. 4, we give the movement of the soliton \(|u|\) of Example 4.3 with the space of polynomials with degree \(k=2\). Comparing with other schemes such as compact finite difference scheme in [14], conservative finite scheme in [31] and in [24] and so on, we use less meshes with higher order scheme and the scheme has higher resolution which can capture the oscillation precisely. Therefore, this scheme is stable and could not occur blow-up phenomenon which has been presented in Fig. 4. This example illustrates the validity and capability of the conservative scheme we presented.

Example 4.4

We consider the equation with the parameters as

$$\begin{aligned} \alpha =1, \quad \beta =-2, \quad f(|u|^2)=|u|^2, \end{aligned}$$

and the exact solution is

$$\begin{aligned} u(x,t)=A \text{ sech } (Jx)e^{i\Theta t}, \quad x\in [-50,50], \end{aligned}$$

where

$$\begin{aligned} A=|J|, \quad \Theta =\frac{1}{2}(-1\pm \sqrt{1-4J^2}). \end{aligned}$$

In the computations, we take \(J=\frac{1}{4}\) and \(\Theta =-\frac{1}{2}-\frac{\sqrt{3}}{4}\). More details can be found in [22].

We show the numerical results of Example 4.4 in Fig. 5 with polynomial spaces of different degrees. This example is designed to illustrate the advantages of high order schemes. We can see that these simulation solutions with polynomials of higher degree are better than that with polynomials of lower degree from Fig. 5. One can conclude that the LDG method can simulate some problems well since it can be designed as any order of accuracy.

Fig. 5
figure 5

Example 4.4, numerical solutions and exact solutions with different degree of polynomials by using the conservative scheme and the mesh size is \(h=0.25\) at time \(T=2\)

4.2 Two-Dimensional Case

In this subsection, some numerical experiments will be designed to show the validity and capability of the conservative scheme in the two-dimensional case.

Example 4.5

Here, we will consider the equation

$$\begin{aligned} u_{tt}-\frac{1}{2}(u_{xx}+u_{yy})+\text{ i }u_t+u=0, \end{aligned}$$

where the exact solution is \(u(x,y,t)=e^{\text{ i }(x+y+t)}\) and the domain is \([0,2\pi ]\times [0,2\pi ]\) to test the accuracy of the conservative scheme which has been designed above.

Since we use the second order scheme on time discretization, in order to obtain the accuracy which will be dominated by the spatial discretization, we take the time step \(\Delta t=cfl*h^2\). We give the \(L^2\) and \(L^{\infty }\) error of the real part and the image part respectively of Example 4.5 to test the accuracy of the conservative scheme in Table 2. we can see that the scheme with the space of polynomials with degree \(k\) has \((k+1)\)th order accuracy which is consistent with the theoretical result which we have proved in Sect. 2.4.3.

Table 2 Example 4.5, accuracy test at time \(T=\pi ^2\) by using the conservative scheme

Example 4.6

In this example, we give the parameters in Eq. (1.1) as

$$\begin{aligned} \alpha =\beta =1,\quad f(|u|^2)=|u|^2, \end{aligned}$$

with the initial condition

$$\begin{aligned} u_{0}(x,y)=(1+\text{ i })(x+y) e^{-10(1-x-y)^2},\quad u_{1}(x,y)=0, \end{aligned}$$

and the computational domain

$$\begin{aligned} (x,y)\in [-40,40]\times [-40,40]. \end{aligned}$$

The boundary condition is the homogenous Dirichlet boundary condition.

In Fig. 6, we use the conservative scheme which we have developed in this paper to simulate Example 4.6 and it can capture the soliton precisely. We give the movement contour figure of soliton \(|u|\) in the left side and the section views when \(x=y\) are given to show the effect of the scheme clearly in the right side of Fig. 6. Here we only give the figures in the domain [-3,4] in the right side figure to illustrate the stability of the scheme. From the right side figures, we can see that the numerical results are stable and do not blow up since we use high order energy conserving scheme which has high resolution. Moreover, these numerical results show that the conservative scheme can work well at solving the nonlinear Schrödinger equation with wave operator.

Fig. 6
figure 6

Example 4.6, the movement of soliton \(|u|\) by using the conservative scheme with the degree of polynomial \(k=2\). The left side figures are contour figures of \(u\); the right side figures are section views when \(x=y\)

4.3 Three-Dimensional Case

In this subsection, we only give a numerical experiment to test the accuracy in the three-dimensional case.

Example 4.7

We consider the equation

$$\begin{aligned} u_{tt}-\frac{1}{3}(u_{xx}+u_{yy}+u_{zz})+\text{ i }u_t+u=0, \end{aligned}$$

where the exact solution is \(u(x,y,z,t)=e^{\text{ i }(x+y+z+t)}\) and the domain is \([0,2\pi ]\times [0,2\pi ]\times [0,2\pi ]\). In addition, we use the periodic boundary condition.

Similarly, in order to obtain the accuracy which will be dominated by the spatial discretization, we take the time step \(\Delta t=cfl*h^2\). We present the \(L^2\) and \(L^{\infty }\) error of the real part and the image part respectively of Example 4.7 to test the accuracy of the conservative scheme in Table 3. We can achieve the theoretical result like one-dimensional and two-dimensional cases.

Table 3 Example 4.5, accuracy test at time \(T=\pi ^2/8\) by using the conservative scheme

5 Conclusion

In this paper, we have developed the LDG method for multi-dimensional Schrödinger equations with wave operator. The energy conservation is an important property of Schrödinger equations and hence we give the energy conservative scheme to simulate these equations. This scheme is designed by discretizing the space with the LDG scheme and the time with the Crank–Nicholson scheme. We also give the error estimates of the conservative scheme for the linear case and the fully discretization is conservative. Some numerical examples in multi-dimensional spaces are shown to illustrate the accuracy, validity and capability of the energy conservative scheme.