# Numerical Analysis of Linear and Nonlinear Time-Fractional Subdiffusion Equations

• Yubo Yang
• Fanhai Zeng
Original Paper

## Abstract

In this paper, a new type of the discrete fractional Grönwall inequality is developed, which is applied to analyze the stability and convergence of a Galerkin spectral method for a linear time-fractional subdiffusion equation. Based on the temporal–spatial error splitting argument technique, the discrete fractional Grönwall inequality is also applied to prove the unconditional convergence of a semi-implicit Galerkin spectral method for a nonlinear time-fractional subdiffusion equation.

## Keywords

Time-fractional subdiffusion equation Convolution quadrature Fractional linear multistep methods Discrete fractional Grönwall inequality Unconditional stability

## Mathematics Subject Classification

26A33 65M06 65M12 65M15 35R11

## 1 Introduction

Consider the following nonlinear time-fractional subdiffusion equation:
\begin{aligned} \left\{ \begin{array}{lll} {_{0}^{\text{C}}{\mathcal {D}}}^{\beta }_t u = \mu \partial ^{2}_x u + f(x,t,u), \quad (x,t)\in I\times (0,T), \quad I=(-1,1), \quad T>0,\\ u=0,\quad (x,t)\in \partial I\times (0,T),\\ u(x,0)=u_0(x), \quad x\in I, \end{array}\right. \end{aligned}
(1)
where $${_{0}^{\text{C}}{{\mathcal {D}}}}^{\beta }_t u$$ denotes the Caputo time-fractional derivative of order $$0<\beta <1$$ defined by (cf. [9])
\begin{aligned} {_{0}^{\text{C}}{{\mathcal {D}}}}^{\beta }_t u(x,t) = \frac{1}{\Gamma (1-\beta )} \int _{0}^{t} (t-s)^{-\beta }\partial _s u(x,s) {\mathrm{d}}s, \end{aligned}
(2)
in which $$\Gamma (z)=\int _{0}^{\infty } s^{z-1}{\text{e}}^{-s} {\mathrm{d}}s$$ is the Gamma function.

Various time-stepping schemes have been developed for discretizing (1). The time discretization technique for the time-fractional operator in (1) mainly falls into two categories: the interpolation and the fractional linear multistep methods (FLMM, which is also called the convolution quadrature (CQ)) based on generating functions that can be derived from the linear multistep method for the initial value problem. For example, the piecewise linear interpolation yields the widely applied L1 method [19, 22]. The high-order interpolation can also be applied; see [3, 12, 30]. The FLMM [23, 24, 25] provides another general framework for constructing high-order methods to discretize the fractional integral and derivative operators. The FLMM inherits the stability properties of linear multistep methods for the initial value problem, which greatly facilitates the analysis of the resulting numerical scheme, in a way often strikingly opposed to standard quadrature formulas [25]. Up to now, the FLMM has been widely applied to discretize the model (1) and its variants.

It is well known that the classical discrete Grönwall inequality plays an important role in the analysis of the numerical methods for time-dependent partial differential equations (PDEs). Due to the lack of a generalized discrete Grönwall-type inequality for the time-stepping methods of the time-dependent fractional differential equations (FDEs), the analysis of the numerical methods for time-dependent FDEs is more complicated. Recently, a discrete fractional Grönwall inequality has been established by Li et al. [13] and Liao et al. [19, 20, 21] for interpolation methods to solve linear and nonlinear time-dependent FDEs. Jin et al. [8] proposed a criterion for showing the fractional discrete Grönwall inequality and verified it for the L1 scheme and convolution quadrature generated by backward difference formulas.

Till now, there have been some works on the numerical analysis of nonlinear time-dependent FDEs. The stability and convergence of L1 finite difference methods were obtained for a time-fractional nonlinear predator–prey model under the restriction $$LT^{\beta } < 1/\Gamma (1-\beta )$$ in [27], where L is the Lipschitz constant of the nonlinear function, depending upon an upper bound of numerical solutions [17]. Such a condition implied that the numerical results just held locally in time and a certain time step restriction condition (see, e.g., [2, 7]) was also required. Similar restrictions also appeared in the numerical analysis for the other fractional nonlinear equations (see, e.g. [15, 16]). To avoid such a restriction, the temporal–spatial error splitting argument (see, e.g., [10]) was extended to the numerical analysis of the nonlinear time-dependent FDEs (see, e.g., [14, 17]). Li et al. proposed unconditionally convergent L1-Galerkin finite element methods (FEMs) for nonlinear time-fractional Schrödinger equations [14] and nonlinear time-fractional subdiffusion equations [17], respectively.

In this paper, we follow the idea in [19] and develop a discrete fractional Grönwall inequality for analyzing the FLMM that arises from the generalized Newton–Gregory formula (GNGF) of order up to two; see [28]. Compared with the approach based on interpolation in [19], the discrete kernel $$P_{k-j}$$ (see Lemmas 2.2 and 2.3 below) originates from the generating function that can be obtained exactly, which is much simpler than that in [19]. Based on the discrete fractional Grönwall inequality, the numerical analysis of the semi-implicit Galerkin spectral method for the time-fractional nonlinear subdiffusion problem (1) is advanced. The temporal–spatial error splitting argument is used to prove the unconditional stability and convergence of the semi-implicit method.

The main task of this work is to establish the discrete fractional Grönwall-type inequality for the stability and convergence analysis of the numerical methods for time-fractional PDEs; the regularity and singularity of the solution at $$t=0$$ are not considered in detail here; readers can refer to [26, 29] for the graded mesh method and correction method for resolving the singularity of the solution of the time-fractional PDEs.

The paper is organized as follows. In Sect. 2, the discrete fractional Grönwall inequality for the CQ is developed, which is applied to the numerical analysis for the linear time-fractional PDE. In Sect. 3, the unconditional convergence of the semi-implicit Galerkin spectral method is proved by combining the discrete fractional Grönwall inequality and the temporal–spatial error splitting argument. Some conclusion remarks are given in Sect. 4.

## 2 Numerical Analysis for the Linear Equation

In this section, two numerical schemes are proposed for the linear equation (1), i.e., $$f(x,t,u)=f(x,t)$$, in which the time direction is approximated by the fractional linear multistep methods (FLMMs) and the space direction is approximated by the Galerkin spectral method.

Let $$\{t_k=k\tau \}_{k=0}^{n_T}$$ be a uniform partition of the interval [0, T] with a time step size $$\tau =T/n_T$$, where $$n_T$$ is a positive integer. For simplicity, the solution of (1) is denoted by $$u(t)=u(x,t)$$ if no confusion is caused. For function $$u(x,t) \in C(0,T;L^2(I))$$, denote $$u^k=u^k(\cdot )=u(\cdot ,t_k)$$ and $$u^{k-\theta }=(1-\theta ) u^k+ \theta u^{k-1}, \theta \in [0,1].$$

Let $${\mathbb {P}}_N(I)$$ be the set of all algebraic polynomials of degree at most N on I. Define the approximation space as follows:
\begin{aligned} V_N^0=\{v:v \in {\mathbb {P}}_N(I),v(-1)=v(1)=0\}. \end{aligned}
As in [28], we present the time discretization for (1) as follows:
\begin{aligned} {D}^{(\beta )}_{\tau } u^k=\mu L_p^{(\beta )} \partial ^2_x u^k+L_p^{(\beta )} f^k+R^k, \end{aligned}
(3)
where $$f^k=f(x,t_k)$$, $$R^k$$ is the discretization error in time that will be specified later, and $$L_p^{(\beta )}$$ and $${D}^{(\beta )}_{\tau }$$ are defined by
\begin{aligned} L_p^{(\beta )}u^k=\left\{ \begin{array}{ll} \!\!u^k, \quad p=1,\\ \!\!u^{k-\beta /2}, \quad p=2, \end{array}\right. \end{aligned}
(4)
and
\begin{aligned} {D}^{(\beta )}_{\tau } u^k=\frac{1}{{\tau }^{\beta }}\sum _{j=0}^k {\varpi }_{k-j}\left( u^j-u^0\right) , \end{aligned}
(5)
respectively, in which $${\varpi }_{k}$$ satisfies the generating function $${\varpi }(z)=(1-z)^{\beta } =\sum \limits _{k=0}^{\infty }{\varpi }_{k}z^k$$.
The fully discrete schemes for (1) are given as follows: find $$u_N^k\in V_N^0$$ such that
\begin{aligned} \left\{ \begin{array}{ll} \!\!\left( {D}^{(\beta )}_{\tau } u_N^k,v\right) + \mu \left( L_p^{(\beta )}\partial _x u_N^{k},\partial _x v\right) = \left( F_p^k,v\right) ,\quad k=1,2,\dots ,n_T, \forall v \in V_N^0,\\ \!\!u^0=I_N u_0, \end{array}\right. \end{aligned}
(6)
where $$F_p^k=I_N\left( L_p^{(\beta )} f^k\right)$$ and $$I_N$$ is the Legendre–Gauss–Lobatto (LGL) interpolation operator.

### 2.1 Discrete Fractional Grönwall Inequality

In this subsection, we introduce some useful lemmas and present a discrete fractional Grönwall inequality that is used in the stability and convergence analysis for (6).

### Lemma 2.1

(see e.g., [28]) For$$0<\beta <1$$, let$${\varpi }_{j}$$be given by$${\varpi }(z)=(1-z)^{\beta }=\sum \limits _{k=0}^{\infty }{\varpi }_{k}z^k$$. Then, one has
\begin{aligned} \left\{ \begin{array}{llllll} {\varpi }_{j}=(-1)^j {\beta \atopwithdelims ()j}=\frac{\Gamma (j-\beta )}{\Gamma (-\beta )\Gamma (j+1)},\\ {\varpi }_{0}=1, {\varpi }_{j}<{\varpi }_{j+1}<0,\quad j \ge 1,\\ \sum \limits _{j=0}^{\infty } {\varpi }_{j}=0,\\ {\varpi }_{0}=-\sum \limits _{j=1}^{\infty } {\varpi }_{j}>-\sum \limits _{j=1}^{k} {\varpi }_{j}>0,\\ b_{k-1}=\sum \limits _{j=0}^{k-1} {\varpi }_{j}>0, \quad k \ge 1,\\ b_{k-1}=\frac{\Gamma (k-\beta )}{\Gamma (1-\beta )\Gamma (k)}=\frac{k^{-\beta }}{\Gamma (1-\beta )}+O(k^{-1-\beta }),\quad k=1,2,\dots . \end{array}\right. \end{aligned}
(7)
Furthermore, $$b_{k}-b_{k-1}={\varpi }_{k}<0$$for$$k>0$$, i.e., $$b_{k}<b_{k-1}$$.

### Lemma 2.2

For$$0<\beta <1$$, let$${\varpi }_{j}$$be given by$${\varpi }(z)=(1-z)^{\beta }=\sum \limits _{k=0}^{\infty }{\varpi }_{k}z^k$$, $${\varrho }_{j}$$be given by$$\varrho (z)=(1-z)^{-\beta }=\sum \limits _{k=0}^{\infty }{\varrho }_{k}z^k$$, and
\begin{aligned} {\vartheta }_m:=\sum _{j=0}^{m}{\varpi }_{j}{\varrho }_{m-j},\quad m=0,1,2,\dots . \end{aligned}
Then, one has
\begin{aligned} \left\{ \begin{array}{llll} {\varrho }_{j}=(-1)^j{-\beta \atopwithdelims ()j}=\frac{(-1)^j\Gamma (j+\beta )}{\Gamma (\beta )\Gamma (j+1)},\quad j \ge 0,\\ {\varrho }_{0}=1,\quad {\varrho }_{j}>{\varrho }_{j+1}>0,\quad j \ge 1,\\ {\varrho }_{j} \le (j+1)^{\beta -1},\quad j \ge 0,\\ {\varrho }_{j} \le j^{\beta -1},\quad j \ge 1,\\ \sum \limits _{j=0}^{k-1} {\varrho }_{j}=\frac{\Gamma (k+\beta )}{\Gamma (1+\beta )\Gamma (k)} \le \frac{k^{\beta }}{\beta },\quad k=1,2,\dots ,\\ {\vartheta }_0=1,\quad {\vartheta }_m=0, \quad m \ge 1. \end{array}\right. \end{aligned}
(8)

### Proof

By the binomial theorem, we can easily get the first two lines in (8). The middle three lines in (8) can be derived by the technique in [8, p.6]. The last line in (8) can be deduced from the following relation:
\begin{aligned} 1={\varpi }(z)\varrho (z)=\left( \sum _{j=0}^{\infty }{\varrho }_jz^j\right) \left( \sum _{j=0}^{\infty }{\varpi }_{j}z^j\right) =\sum _{j=0}^{\infty }{\vartheta }_{j}z^j. \end{aligned}
The proof is completed.

### Lemma 2.3

Let$$P_{k-j}:={\tau }^{\beta }{\varrho }_{k-j}$$. For$$0<\beta <1$$and any real$$\mu >0$$, one has
\begin{aligned} \mu \sum _{j=0}^{k-1} P_{k-j} E_{\beta }(\mu t_j^{\beta }) \le E_{\beta }(\mu t_k^{\beta })-1, \quad 1\le k \le n_T, \end{aligned}
(9)
where$$E_{\beta }$$denotes the Mittag–Leffler function that is defined by
\begin{aligned} E_{\beta }(z)=\sum _{l=0}^{\infty } \frac{z^l}{\Gamma (1+l\beta )}. \end{aligned}
(10)

### Proof

Denote $$v_l(t)=\frac{t^{l\beta }}{\Gamma (1+l\beta )}$$. It is easy to obtain
\begin{aligned} \sum _{j=0}^{k-1} P_{k-j} \left( {_{0}^{\text{C}}{{\mathcal {D}}}}^{\beta }_t v_l\right) (t_j)=\sum _{j=0}^{k-1} P_{k-j} v_{l-1}(t_j). \end{aligned}
By the fourth inequality in Lemma 2.2 and Lemma 3.2 in [11], we obtain
\begin{aligned} \sum _{j=0}^{k-1} P_{k-j} v_{l-1}(t_j)= & {} \sum _{j=0}^{k-1} {\varrho }_{k-j} \left[ \frac{j^{(l-1)\beta }{\tau }^{l\beta }}{\Gamma ((l-1)\beta +1)}\right] \\= & {} \sum _{j=0}^{k-1}\left[ \frac{{\varrho }_{k-j}j^{(l-1)\beta }}{\Gamma ((l-1)\beta +1)}\cdot \frac{\Gamma (l\beta +1)}{k^{l\beta }}\right] v_l(t_k) \\\le\, & {} v_l(t_k)\sum _{j=0}^{k-1}\left[ \frac{{(k-j)}^{\beta -1}j^{(l-1)\beta }}{\Gamma ((l-1)\beta +1)}\cdot \frac{\Gamma (l\beta +1)}{k^{l\beta }}\right] \\\le\, & {} v_l(t_k). \end{aligned}
Therefore, one has
\begin{aligned} \sum _{l=1}^{m} {\mu }^l \sum _{j=0}^{k-1} P_{k-j} v_{l-1}(t_j) \le \sum _{l=1}^{m} {\mu }^l v_l(t_k). \end{aligned}
Interchanging the sums on the left-hand side of the above inequality and letting $$m\rightarrow \infty$$ yield the desired result. The proof is completed.

We now present the discrete fractional Grönwall inequality in the next theorem.

### Theorem 2.1

(discrete fractional Grönwall inequality) Let$$P_{k-j}:={\tau }^{\beta }{\varrho }_{k-j}$$, $$0\le \theta \le 1$$, and$$\{g^k\}_{k=0}^{n_T}$$and$$\{\lambda _l\}_{l=0}^{n_T-1}$$be given non-negative sequences. Assume that there exists a constant$$\lambda$$ (independent of the time step size) such that$$\lambda \ge \sum \limits _{l=0}^{k-1} \lambda _l$$, and that the maximum time step size$$\tau$$satisfies
\begin{aligned} \tau \le \frac{1}{\root \beta \of {2\lambda (1+\beta )}}. \end{aligned}
(11)
Then, for any non-negative sequence$$\{v^k\}_{k=0}^N$$satisfying
\begin{aligned} {D}^{(\beta )}_{\tau } (v^k)^2 \le \sum _{l=1}^k \lambda _{k-l} (v^l)^2+v^{k-\theta }g^{k-\theta }, \quad 1 \le k \le n_T, \end{aligned}
(12)
it holds that
\begin{aligned} v^k \le 2E_{\beta }(2\lambda t_k^{\beta })\left( v^0+\max _{1\le m \le k} \sum _{j=0}^m P_{m-j}g^{j-\theta }\right) , \quad 1 \le k \le n_T. \end{aligned}
(13)

### Proof

By (5) and the last line in Lemma 2.2, one has
\begin{aligned} \sum _{m=0}^{k}P_{k-m}{D}^{(\beta )}_{\tau } (v^m)^2= & {} \sum _{m=0}^{k}{\varrho }_{k-m}\sum _{j=0}^{m}{\varpi }_{m-j}\left[ (v^j)^2-(v^0)^2\right] \nonumber \\= & {} \sum _{j=0}^{k}\left[ (v^j)^2-(v^0)^2\right] \sum _{m=j}^{k}{\varrho }_{k-m}{\varpi }_{m-j} \nonumber \\= & {} \sum _{j=0}^{k}{\vartheta }_{k-j}\left[ (v^j)^2-(v^0)^2\right] =(v^k)^2-(v^0)^2, \end{aligned}
(14)
where we exchanged the order of summation and rearranged the coefficient $$\sum \limits _{m=j}^{k}{\varrho }_{k-m}{\varpi }_{m-j}$$ to $${\vartheta }_{k-j}$$.

By Lemma 2.3 and the technique for the proof of Theorem 3.1 in [20], we derive the desired result, which completes the proof.

We also have an alternative version of the above theorem.

### Corollary 2.1

Theorem 2.1remains valid if the condition (12) is replaced by
\begin{aligned} {D}^{(\beta )}_{\tau } v^k \le \sum _{l=1}^k \lambda _{k-l} v^l+g^{k} \quad for \quad 1 \le k \le n_T. \end{aligned}
(15)

### Proof

Similar to the proof of Theorem 3.4 in [20], and by the proof of Theorem 2.1, we can complete our proof.

### Remark 2.1

If $$\lambda _0, \lambda _1,\dots , \lambda _{k-1}$$ are non-positive, a simple deduction will show that both Theorem 2.1 and Corollary 2.1 hold for any $$\tau >0$$.

### 2.2 Stability and Convergence

We present the stability and convergence result for the scheme (6).

### Theorem 2.2

Suppose that$$u_N^k\,(k=1,2,\dots ,n_T)$$ are solutions of (6), $$f \in C(0,T;C({\bar{I}}))$$. Then, for any$$\tau >0$$, it holds that
\begin{aligned} \Vert u_N^k\Vert \le C\left( \Vert u^0\Vert +\max _{1\le m \le k} \sum _{j=0}^m P_{m-j}\Vert L_p^{(\beta )}f^{j}\Vert \right) , \quad 1 \le k \le n_T, \end{aligned}
(16)
whereC is a positive constant independent of$$\tau$$ andN.

### Proof

(i) For $$p=1$$, letting $$v=2u_N^k$$ in (6), one has
\begin{aligned} \left( {D}^{(\beta )}_{\tau } u_N^k,2u_N^k\right) + 2\mu \left( \partial _x u_N^{k},\partial _x u_N^k\right) =\left( I_N f^{k},2u_N^k\right) , \quad 1 \le k \le n_T. \end{aligned}
(17)
By (5), Lemma 2.1, and the Young’s inequality, we have
\begin{aligned} \left( {D}^{(\beta )}_{\tau } u_N^k,2u_N^k\right)= & {} \frac{2}{{\tau }^{\beta }}\left[ \sum _{j=0}^k {\varpi }_{k-j}\left( u_N^j,u_N^k\right) -\sum _{j=0}^k {\varpi }_{k-j}\left( u^0,u_N^k\right) \right] \nonumber \\= & {} \frac{1}{{\tau }^{\beta }}\left[ 2{\varpi }_{0}\left( u_N^k,u_N^k\right) +2\sum _{j=1}^k {\varpi }_{k-j}\left( u_N^j,u_N^k\right) -2b_k\left( u^0,u_N^k\right) \right] \nonumber \\\ge & {} \frac{1}{{\tau }^{\beta }}\left[ 2{\varpi }_{0}\Vert u_N^k\Vert ^2\right. \nonumber \\& \left. +\sum _{j=1}^k {\varpi }_{k-j}\Vert u_N^j\Vert ^2+\sum _{j=1}^k {\varpi }_{k-j}\Vert u_N^k\Vert ^2-b_k\Vert u_N^k\Vert ^2-b_k\Vert u^0\Vert ^2\right] \nonumber \\= & {} \frac{1}{{\tau }^{\beta }}\left[ \sum _{j=0}^k {\varpi }_{k-j}\Vert u_N^j\Vert ^2-b_n\Vert u^0\Vert ^2\right] ={D}^{(\beta )}_{\tau } \left( \Vert u_N^k\Vert ^2\right) . \end{aligned}
(18)
Using (18), the positive-definiteness of $$\left( \partial _x u_N^{k},\partial _x u_N^k\right)$$, and $$\Vert I_N f^k\Vert \le C\Vert f^k\Vert$$, one has
\begin{aligned} {D}^{(\beta )}_{\tau } \left( \Vert u_N^k\Vert ^2\right) \le C\Vert u_N^k\Vert \,\Vert f^k\Vert \quad \mathrm{for} \quad 1 \le k \le n_T. \end{aligned}
(19)
Finally, applying the discrete Grönwall inequality (see Theorem 2.1) and introducing the following notations:
\begin{aligned} v^k:=\Vert u_N^k\Vert , \quad v^0:=u^0, \quad g^{k-\theta }:=C\Vert f^{k}\Vert \,(\mathrm{with}\, \theta =0),\quad \lambda _j:=0\quad { \mathrm{for}} \quad 0 \le j \le n_T-1, \end{aligned}
we immediately get the stability result (16) for $$p=1$$.
(ii) For $$p=2$$, letting $$v=2u_N^{k-\beta /2}$$ in (6), one has
\begin{aligned} \left( {D}^{(\beta )}_{\tau } u_N^k,2u_N^{k-\beta /2}\right) + 2\mu \left( \partial _x u_N^{k-\beta /2},\partial _x u_N^{k-\beta /2}\right) =\left( I_N f^{k-\beta /2},2u_N^{k-\beta /2}\right) . \end{aligned}
(20)
Rearranging the coefficients in (5), we have
\begin{aligned} \left( {D}^{(\beta )}_{\tau } u_N^k,2u_N^{k-\beta /2}\right) = \frac{1}{{\tau }^{\beta }}\sum _{j=1}^k {b}_{k-j}\left( u_N^j-u_N^{j-1},2u_N^{k-\beta /2}\right) . \end{aligned}
(21)
Similar to the proof of Lemma 4.1 in [20] and by Lemma 2.1, we get
\begin{aligned} \left( {D}^{(\beta )}_{\tau } u_N^k,2u_N^{k-\beta /2}\right) \ge {D}^{(\beta )}_{\tau } \left( \Vert u_N^k\Vert ^2\right) . \end{aligned}
(22)
The remaining of the proof is similar to that shown in (i), which is omitted here. The proof is completed.

To obtain the convergence results, we introduce the following two lemmas.

### Lemma 2.4

([4, Theorem 6.2, p. 262]) Letsandrbe arbitrary real numbers satisfying$$0 \le s \le r$$. There exist a projector$$\Pi _N^{1,0}$$and a positive constantCdepending only on r such that, for any function$$u \in H_0^{s}(I) \cap H^r(I)$$, the following estimate holds:
\begin{aligned} \Vert u-\Pi _N^{1,0}u\Vert _{H^{s}(I)} \le C N^{s-r} \Vert u\Vert _{H^r(I)}, \end{aligned}
where the orthogonal projection operator$$\Pi _N^{1,0}: H_0^{1}(I)\rightarrow V_N^0$$is defined as
\begin{aligned} \left( \partial _x \left( \Pi _N^{1,0}u-u\right) ,\partial _x v\right) =0, \quad \forall v \in V_N^0. \end{aligned}

### Lemma 2.5

([4, Theorem 13.4, p. 303]) Let r be arbitrary real numbers satisfying$$r > 1/2$$and$$I_N$$be the usual LGL interpolation operator. There exists a positive constantCdepending only onrsuch that, for any function$$u \in H^r(I)$$, the following estimate holds:
\begin{aligned} \Vert u-I_Nu\Vert \le C N^{-r} \Vert u\Vert _{H^r(I)}. \end{aligned}
Next, we consider the convergence analysis for the scheme (6). We also assume that the solution u(t) satisfies (see, e.g., [6, 29])
\begin{aligned} u(t)=u_0+c_0t^{\sigma }+\sum _{j=1}^{\infty }c_kt^{\sigma _j}, {\quad }\beta<\sigma<\sigma _j<\sigma _{j+1}. \end{aligned}
(23)
The singularity index $$\sigma$$ determines the accuracy of the numerical solution if $$t^{\sigma }$$ is not treated properly. We do not investigate how to deal with the singularity of the solution in this work, the interesting readers can refer to [23, 26, 29]. For the time discretization in (6), the global convergence rate is $$\min \{\sigma -\beta ,p\}$$, that is $$q=\min \{\sigma -\beta ,p\}$$.
Denote $$u_*^k=\Pi _N^{1,0}u^k, e^k=u_*^k-u_N^k$$ and $$\eta ^k=u^k-u_*^k$$. Noticing that $$\left( \partial _x \eta ^k,\partial _x v\right) =0$$ from Lemma 2.4, we get the error equation for (6) as follows:
\begin{aligned} \left( {D}^{(\beta )}_{\tau } e^k,v\right) +\mu \left( \partial _x e^k,\partial _x v\right) =\left( G^k,v\right) , \end{aligned}
(24)
where $$G^k=\sum \limits _{i=1}^3 G_i^k$$ and
\begin{aligned} G_1^k=f^k-F_p^k,\quad G_2^k=R^k =O(\tau ^{\sigma -\beta }k^{\sigma -\beta -p}),\quad G_3^k=-{D}^{(\beta )}_{\tau } \eta ^k. \end{aligned}
(25)
By Theorem 2.2, Lemmas 2.4 and  2.5, we obtain the convergence result for the scheme (6).

### Theorem 2.3

Suppose that$$r \ge 1$$, uand$$u_N^k\,(k=1,2,\dots ,n_T)$$are solutions of (1) and (6), respectively. If$$m \ge r+1, u\in C(0,T; H^m(I)\cap H^1_0(I)), f \in C(0,T;H^m(I))$$and$$u_0 \in H^m(I)$$. Then, for any$$\tau > 0$$, it holds that
\begin{aligned} \Vert u^k-u_N^k\Vert \le C(\tau ^q+N^{-r}), \end{aligned}
(26)
whereCis a positive constant, independent of$$\tau , N$$, $$q=\min \{\sigma -\beta ,p\}$$.

### Proof

We consider $$p=1$$, the case for $$p=2$$ is similarly proved. By Theorem 2.2 and the fifth line of Lemma 2.2, we need only to evaluate
\begin{aligned} \Vert e^0\Vert +2C\max _{1\le k \le n_T} \left\{ \Vert G_1^k\Vert +\Vert G_2^k\Vert +\Vert G_3^k\Vert \right\} \end{aligned}
to get an error bound. By (25), Lemmas 2.2, 2.4, and 2.5, we get the error bounds as follows:
\begin{aligned} \Vert G_1^k\Vert\le\, & {} CN^{-r},\quad \Vert G_2^k\Vert \le C\tau ^q,\quad \Vert G_3^k\Vert =\frac{1}{{\tau }^{\beta }}\left\| \sum _{j=0}^k {\varpi }_{k-j}\left( \eta ^j-\eta ^0\right) \right\| \le CN^{-r},\\ \Vert e^0\Vert= & {} \Vert u_*^0-I_N u_0\Vert \le \Vert u_0-I_Nu_0\Vert +\Vert u_0-u_*^0\Vert \le CN^{-r}. \end{aligned}
The above bounds yield
\begin{aligned} \Vert e^k\Vert \le C(\tau ^q+N^{-r}). \end{aligned}
Using Lemma 2.4 again, one has
\begin{aligned} \Vert u^k-u_N^k\Vert = \Vert u^k-u_*^k+u_*^k-u_N^k\Vert \le \Vert \eta ^k\Vert +\Vert e^k\Vert \le C(\tau ^q+N^{-r}). \end{aligned}
The proof is completed.

## 3 Numerical Analysis for the Nonlinear Equation

In this section, we develop the semi-implicit time-stepping Legendre–Galerkin spectral method for the nonlinear problem (1), i.e., $$f(x,t,u)=f(u)$$. We then combine the discrete fractional Grönwall inequality and the temporal–spatial error splitting argument (see, e.g., [10, 14]) to prove the stability and convergence of the numerical scheme. We assume that the solution of problem (1) satisfies the following condition:
\begin{aligned} \Vert u_0\Vert _{H^{r+1}}+\Vert u\Vert _{L^{\infty }(0,T;H^{r+1})} \le K, \end{aligned}
(27)
where K is a positive constant independent of N and $$\tau$$.

Throughout this section, C denotes a generic positive constant, which may vary at different occurrences, but is independent of N and time step size $$\tau$$. Denote $$C_i\,(i=1,2,\dots )$$ as positive constants independent of N and $$\tau$$.

The following inverse inequalities (see, e.g., [1, 5, 18]) will be used in the numerical analysis:
\begin{aligned}&\Vert v\Vert _{L^{\infty }} \le \frac{N+1}{\sqrt{2}} \Vert v\Vert , \quad \forall \, v \in V_N^0, \end{aligned}
(28)
\begin{aligned}&\Vert v\Vert _{L^{\infty }} \le C_I \Vert v\Vert _{H^2}, \quad \forall \, v \in H^1_0(I)\cap H^2(I), \end{aligned}
(29)
where $$C_I$$ is a positive constant depending only on the interval I.
We extend the method (6) with $$p=1$$ to the nonlinear Eq. (1), while the nonlinear term $$f(u_N^k)$$ is approximated by $$f(u_N^{k-1})$$. We obtain the following semi-implicit Galerkin spectral method: find $$u_N^k\in V_N^0$$ such that
\begin{aligned} \left\{ \begin{array}{ll} \left( {D}^{(\beta )}_{\tau } u_N^k,v\right) + \mu \left( \partial _x u_N^{k},\partial _x v\right) = \left( f(u_N^{k-1}),v\right) ,\quad \forall v \in V_N^0, \quad k=1,2,\dots ,n_T,\\ u^0=I_N u_0, \end{array}\right. \end{aligned}
(30)
where $$I_N$$ is the LGL interpolation operator.
We also assume that the nonlinear term f(u) satisfies the local Lipschitz condition:
\begin{aligned} \Vert f(u^{k})-f(u^{k-1})\Vert \le \Vert f'(\xi )\Vert \,\Vert u^{k}-u^{k-1}\Vert \le C \Vert u^{k}-u^{k-1}\Vert , {\quad } |\xi |\le K_1, \end{aligned}
where $$K_1$$ is a positive constant that is suitably large.

### 3.1 An Error Estimate of the Time-Discrete System

To obtain the unconditional stability of (30), we now introduce a time-discrete system:
\begin{aligned} \left\{ \begin{array}{lll} {D}^{(\beta )}_{\tau } U^k=\mu \partial ^2_x U^{k}+f(U^{k-1}),\quad k=1,2,\dots ,n_T,\\ U^k(x)=0 \quad \mathrm{for} \quad x \in \partial I, \quad k=1,2,\dots ,n_T,\\ U^0(x)=u_0(x) \quad \mathrm{for} \quad x \in I. \end{array}\right. \end{aligned}
(31)
Let $$R_1^k$$ be the time discretization error of (30). Then, we can obtain
\begin{aligned} {D}^{(\beta )}_{\tau } u^k=\mu \partial ^2_x u^{k}+f(u^{k-1})+R_1^k,\quad k=1,2,\dots ,n_T, \end{aligned}
(32)
where
\begin{aligned} R_1^k = {D}^{(\beta )}_{\tau } u^k-{_{0}^{C}{\mathcal {D}}}^{\beta }_t u^k+f(u^{k})-f(u^{k-1}) =O(\tau ^{\tilde{q}}), \end{aligned}
(33)
in which $$\tilde{q}=\min \{\sigma -\beta ,1\}$$ when the first-order extrapolation is applied.
Letting $${\varepsilon }^k=u^k-U^k$$ and subtracting (31) from (32) gives
\begin{aligned} {D}^{(\beta )}_{\tau } {\varepsilon }^k=\mu \partial ^2_x {\varepsilon }^{k}+f(u^{k-1})-f(U^{k-1})+R_1^k,\quad k=1,2,\dots ,n_T. \end{aligned}
(34)
Define
\begin{aligned} K_1=\max _{1\le k \le n_T} \Vert u^k\Vert _{L^{\infty }}+\max _{1\le k \le n_T} \Vert u^k\Vert _{H^2}+\max _{1\le k \le n_T} \Vert {D}^{(\beta )}_{\tau }u^k\Vert _{H^2}+1. \end{aligned}
We now present an error bound of $${\varepsilon }^k=u^k-U^k$$ as follows.

### Theorem 3.1

Suppose that$$r \ge 1$$, uand$$U^k\,(k=1,2,\dots ,n_T)$$are solutions of (1) and (31), respectively. If$$u\in C(0,T; H^2(I)\cap H^1_0(I))$$, $$|f'(z)|$$is bounded for$$|z|\le K_1$$, $$f\in H^1(I)$$, and$$u_0 \in H^m(I)$$. Then, there exists a suitable constant$$\tau _0^*>0$$such that when$$\tau \le \tau _0^*$$, it holds
\begin{aligned} \Vert {\varepsilon }^k\Vert _{H^2}\le\, & {} C_*\tau ^{\tilde{q}}, \end{aligned}
(35)
\begin{aligned} \Vert U^k\Vert _{L^{\infty }}+\Vert {D}^{(\beta )}_{\tau }U^k\Vert _{H^2}\le\, & {} 2K_1, \end{aligned}
(36)
where$$C_*$$is a constant independent ofNand$$\tau$$, and$$\tilde{q}=\min \{\sigma -\beta ,1\}$$.

### Proof

We use the mathematical induction method to prove (35). Obviously, (35) holds for $$k=0$$. Assume (35) holds for $$k \le n-1$$. Then, by (28) and (35), one has
\begin{aligned} \Vert U^k\Vert _{\infty } \le \Vert u^k\Vert _{L^{\infty }}+C_I\Vert {\varepsilon }^k\Vert _{H^2} \le \Vert u^k\Vert _{L^{\infty }}+C_IC_*\tau ^{\tilde{q}} \le K_1,\quad k \le n-1, \end{aligned}
(37)
provided $$\tau \le (C_IC_*)^{-1/\tilde{q}}$$. Moreover, for $$\tau \le (C_*)^{-1/\tilde{q}}$$, we have
\begin{aligned} \Vert U^k\Vert _{H^2} \le \Vert u^k\Vert _{H^2}+\Vert {\varepsilon }^k\Vert _{H^2} \le \Vert u^k\Vert _{H^2}+C_*\tau ^{\tilde{q}} \le K_1.\end{aligned}
(38)
The following estimates are easily obtained:
\begin{aligned} \Vert f(u^{k-1})-f(U^{k-1})\Vert\le\, & {} C\Vert {\varepsilon }^{k-1}\Vert , \end{aligned}
(39)
\begin{aligned} \left\| \partial _x \left( f(u^{k-1})-f(U^{k-1})\right) \right\|\le\, & {} C\Vert {\varepsilon }^{k-1}\Vert _{H^1}. \end{aligned}
(40)
Next, we prove that (35) holds for $$k\le n$$ in (34). Multiplying both sides of (34) by $$2{\varepsilon }^{n}$$ and integrating the result over I yields
\begin{aligned} {D}^{(\beta )}_{\tau } \left( \Vert {\varepsilon }^n\Vert ^2\right)\le\, & {} 2\left( f(u^{k-1})-f(U^{k-1}),{\varepsilon }^{n}\right) +2\left( R_1^n,{\varepsilon }^{n}\right) \nonumber \\\le\, & {} C\Vert {\varepsilon }^{n}\Vert ^2+C\Vert {\varepsilon }^{n-1}\Vert ^2 +2\Vert {\varepsilon }^{n}\Vert \,\Vert R_1^n\Vert , \end{aligned}
(41)
where (39) is used.
Applying (33) and Theorem 2.1 with
\begin{aligned} v^n:=\Vert {\varepsilon }^{n}\Vert ,\quad v^0:=0,\quad g^{n-\theta }:=2\Vert R_1^n\Vert \,(\mathrm{with}\, \theta =0), \\ \lambda _0=\lambda _1:=C,\quad \lambda _j:=0\quad \mathrm{for}\quad 2 \le j \le n_T-1, \end{aligned}
one has
\begin{aligned} \Vert {\varepsilon }^{n}\Vert \le C_1 \tau ^{\tilde{q}},{\quad } \text {if} \quad \tau \le \frac{1}{\root \beta \of {C(1+\beta )}}. \end{aligned}
(42)
To derive an estimate of $$\Vert \partial _x {\varepsilon }^{n}\Vert$$, we multiply (34) by $$2{D}^{(\beta )}_{\tau }{\varepsilon }^{n}$$ and integrate the result over I to obtain
\begin{aligned}&2\Vert {D}^{(\beta )}_{\tau } {\varepsilon }^n\Vert ^2+\mu {D}^{(\beta )}_{\tau } \left( \Vert \partial _x{\varepsilon }^n\Vert ^2\right) =2\left( f(u^{n-1})-f(U^{n-1}),{D}^{(\beta )}_{\tau }{\varepsilon }^{n}\right) +2\left( R_1^n,{D}^{(\beta )}_{\tau }{\varepsilon }^{n}\right) . \end{aligned}
(43)
By Young’s inequality, (33), (39), and (42), we can derive
\begin{aligned} \left| \left( f(u^{n-1})-f(U^{n-1}),{D}^{(\beta )}_{\tau }{\varepsilon }^{n}\right) \right|\le\, & {} \frac{3}{2}\left\| f(u^{n-1})-f(U^{n-1})\right\| ^2\\& +\frac{2}{3}\Vert {D}^{(\beta )}_{\tau } {\varepsilon }^n\Vert ^2 \le \frac{2}{3}\Vert {D}^{(\beta )}_{\tau } {\varepsilon }^n\Vert ^2 +C{\tau }^{2\tilde{q}},\\ \left| \left( R_1^n,{D}^{(\beta )}_{\tau }{\varepsilon }^{n}\right) \right|\le\, & {} \frac{3}{2}\left\| R_1^n\right\| ^2+\frac{2}{3}\Vert {D}^{(\beta )}_{\tau } {\varepsilon }^n\Vert ^2 \le \frac{2}{3}\Vert {D}^{(\beta )}_{\tau } {\varepsilon }^n\Vert ^2 +C{\tau }^{2\tilde{q}}. \end{aligned}
Substituting the above estimates into (43), we have
\begin{aligned} {D}^{(\beta )}_{\tau } \left( \Vert \partial _x{\varepsilon }^n\Vert ^2\right) \le C {\tau }^{2\tilde{q}}. \end{aligned}
(44)
Applying Corollary 2.1 with
\begin{aligned} v^n:=\Vert \partial _x {\varepsilon }^{n}\Vert ^2,\quad v^0:=0,\quad g^{n}:=C {\tau }^{2\tilde{q}}, \quad \lambda _j:=0\quad \mathrm{for}\quad 0 \le j \le n_T-1, \end{aligned}
one has
\begin{aligned} \Vert \partial _x{\varepsilon }^{n}\Vert \le C_2 \tau ^{\tilde{q}}. \end{aligned}
(45)
We can similarly derive an estimate of $$\Vert \partial ^2_x{\varepsilon }^{n}\Vert$$ by multiplying (34) by $$-2{D}^{(\beta )}_{\tau }\left( \partial _x^2{\varepsilon }^{n}\right)$$ and integrating the result over I. Similar to (45), by Young’s inequality, (33), (39), (40), (42) and (45), we can get
\begin{aligned} \Vert \partial ^2_x{\varepsilon }^{n}\Vert \le C_3 \tau ^{\tilde{q}}. \end{aligned}
(46)
Combing (42), (45) and (46), we obtain
\begin{aligned} \Vert {\varepsilon }^{n}\Vert _{H^2} \le C_*\tau ^{\tilde{q}}, \end{aligned}
(47)
where $$C_*=\sqrt{C_1^2+C_2^2+C_3^2}$$ is a constant independent of N and $$\tau$$.
Moreover, we can derive that
\begin{aligned} \Vert U^{n}\Vert _{L^{\infty }}\le\, & {} \Vert u^{n}\Vert _{L^{\infty }}+C_I\Vert \varepsilon ^{n}\Vert _{H^2} \le \Vert u^{n}\Vert _{L^{\infty }}+C_*C_I\tau \le K_1,\\ \Vert {D}^{(\beta )}_{\tau } U^{n}\Vert _{H^2}\le\, & {} \Vert {D}^{(\beta )}_{\tau } u^{n}\Vert _{H^2}+\Vert {D}^{(\beta )}_{\tau } \varepsilon ^{n}\Vert _{H^2} \le \Vert {D}^{(\beta )}_{\tau } u^{n}\Vert _{H^2}+C_*{\tau }^{\tilde{q}-\beta }\le K_1, \end{aligned}
where $$\tau \le \tau _0= \min \left\{ (C_*C_I)^{-1},C_*^{\frac{1}{1-\beta }}\right\}$$, and (5) is used. Thus, the proof is completed.

### 3.2 An Error Estimate of the Space Discrete System

The weak form of time-discrete system (31) satisfies
\begin{aligned} \left( {D}^{(\beta )}_{\tau } U^k,v\right) =\mu \left( \partial ^2_x U^{k},v\right) +\left( f(U^{k-1}),v\right) ,\quad v \in H^2(I). \end{aligned}
(48)
Let
\begin{aligned} U^k_*=\Pi _N^{1,0}U^k, \quad {{\bar{e}}}^k=U^k_*-u_N^k, \quad k=1,2,\dots ,n_T. \end{aligned}
Subtracting (30) from (48), we have
\begin{aligned} \left( {D}^{(\beta )}_{\tau } {{\bar{e}}}^k,v\right) +\mu \left( \partial _x {{\bar{e}}}^{k},\partial _x v\right) =\left( f(U^{k-1})-f(u_N^{k-1}),v\right) +\left( R_2^k,v\right) , \end{aligned}
(49)
where
\begin{aligned} R_2^k={D}^{(\beta )}_{\tau } (U_*^k-U^k). \end{aligned}
It is easy to obtain $$\left\| \Pi _N^{1,0}v\right\| _{L^{\infty }}\le C\Vert v\Vert _{H^2}$$ for any $$v \in H^2(I)$$. By Theorem 3.1, one has
\begin{aligned} \Vert U_*^k\Vert _{L^{\infty }}\le C\Vert U^k\Vert _{H^2} \le C,\quad k=1,2,\dots ,n_T. \end{aligned}
Then, we define
\begin{aligned} K_2=\max _{1\le k \le n_T}\Vert U_*^k\Vert _{L^{\infty }}+1. \end{aligned}
Now, we are ready to give an error estimate of $$\Vert U^k-u_N^k\Vert$$.

### Theorem 3.2

Suppose that$$r \ge 1$$, $$u_N^k$$and$$U^k\,(k=1,2,\dots ,n_T)$$are solutions of (30) and (31), respectively. Assume that$$U^k\in H^2(I)\cap H^1_0(I)$$, $$|f'(z)|$$is bounded for$$|z|\le K_1$$, $$f\in H^1(I)$$, and$$U^0 \in H^2(I)$$. Then, there exists a positive constant$$N_0^*$$such that when$$N \ge N_0^*$$, it holds
\begin{aligned} \Vert U^k-u_N^k\Vert\le\, & {} N^{-\frac{3}{2}}, \end{aligned}
(50)
\begin{aligned} \Vert u_N^k\Vert _{L^{\infty }}\le\, & {} K_2. \end{aligned}
(51)

### Proof

We prove (50) using the mathematic induction method. From Lemma 2.5, one has
\begin{aligned} \Vert U^0-u_N^0\Vert =\Vert u_0-I_Nu_0\Vert \le C_4N^{-2} \le N^{-\frac{3}{2}} \end{aligned}
when $$N\ge (C_4)^2$$. Assume that (50) holds for $$k \le n-1$$. By the inverse inequality (28), we have
\begin{aligned} \Vert u_N^k\Vert _{L^{\infty }}\le \Vert U_*^k\Vert _{L^{\infty }}+\Vert U_*^k-u_N^k\Vert _{L^{\infty }} \le \Vert U_*^k\Vert _{L^{\infty }}+\frac{N+1}{\sqrt{2}}\Vert {{\bar{e}}}^k\Vert \le \Vert U_*^k\Vert _{L^{\infty }}+C_5N^{-\frac{1}{2}} \le K_2, \end{aligned}
when $$N\ge (C_5)^2$$.
By (36) and the assumption, $$\Vert U^{k}\Vert _{L^{\infty }}$$ and $$\Vert u_N^{k}\Vert _{L^{\infty }}$$ are bounded for $$k\le n-1$$. Therefore, $$f'(\xi )$$ is bounded when $$|\xi |\le \max \{2K_1,K_2\}$$. Combining Lemma 2.4 and the boundedess of $$f'(\xi )$$ yields
\begin{aligned} \left\| f(U^{k-1})-f(u_N^{k-1})\right\|= & {} \Vert f'(\xi )(u_N^{k-1}-U^{k-1})\Vert \nonumber \\\le\, & {} C\left\| U^{k-1}-u_N^{k-1}\right\| \le C\Vert {{\bar{e}}}^{k-1}\Vert +CN^{-2}. \end{aligned}
(52)
By Lemma 2.4 and Theorem 3.1, we obtain
\begin{aligned} \Vert R_2^n\Vert ^2 \le CN^{-4}\left\| {D}^{(\beta )}_{\tau }U^k \right\| _{H^2} \le CN^{-4}. \end{aligned}
(53)
Letting $$k\le n$$ and $$v=2{{\bar{e}}}^{k}$$ in (49), we have
\begin{aligned} \left( {D}^{(\beta )}_{\tau } {{\bar{e}}}^k,2{{\bar{e}}}^k\right) +2\mu \left( \partial _x {{\bar{e}}}^{k},\partial _x {{\bar{e}}}^k\right) =2\left( f(U^{k-1})-f(u_N^{k-1}), {\bar{e}}^k\right) +2\left( R_2^k,{{\bar{e}}}^k\right) . \end{aligned}
Combing (52), (53), and the above inequality yields
\begin{aligned} {D}^{(\beta )}_{\tau } \left( \Vert {{\bar{e}}}^k\Vert ^2\right)\le\, & {} 2\left( f(U^{k-1})-f(u_N^{k-1}), {{\bar{e}}}^k\right) +2\left( R_2^k,{{\bar{e}}}^k\right) \nonumber \\\le\, & {} \left( \|\, f(U^{k-1})-f(u_N^{k-1})\| ^2 +\Vert {{\bar{e}}}^k\Vert ^2\right) +\left( \Vert R_2^k\Vert ^2+\Vert {{\bar{e}}}^k\Vert ^2\right) \nonumber \\\le\, & {} 2\Vert {{\bar{e}}}^k\Vert ^2+C\Vert {{\bar{e}}}^{k-1}\Vert ^2+CN^{-4},{\quad } k\le n. \end{aligned}
(54)
Applying Theorem 2.1 yields $$\Vert {{\bar{e}}}^k\Vert \le CN^{-2}(k\le n)$$, which leads to
\begin{aligned} \Vert U^n-u_N^n\Vert \le \Vert U^n-U_*^n\Vert +\Vert {{\bar{e}}}^n\Vert \le C_6N^{-2} \le N^{-\frac{3}{2}}, \end{aligned}
(55)
when $$N \ge (C_6)^2$$. That is to say, (50) holds for $$k=n$$. Furthermore, we have
\begin{aligned} \Vert u_N^n\Vert _{L^{\infty }}\le\, & {} \Vert U_*^n\Vert _{L^{\infty }}+\Vert {{\bar{e}}}^n\Vert _{L^{\infty }} \nonumber \\\le\, & {} \Vert U_*^k\Vert _{L^{\infty }}+\frac{N+1}{\sqrt{2}}\Vert {{\bar{e}}}^n\Vert \le \Vert U_*^k\Vert _{L^{\infty }}+C_5N^{-\frac{1}{2}}\le K_2, \end{aligned}
(56)
when $$N \ge (C_5)^2$$. Letting $$N_0^*=\left\lceil \max \left\{ (C_4)^2,(C_5)^2,(C_6)^2\right\} \right\rceil$$ completes the proof.

### 3.3 Error Estimate of the Fully Discrete System

By the boundedness of $$u_N^k$$ and Theorem 2.2, we immediately obtain the following result.

### Theorem 3.3

Suppose that$$r \ge 1$$, uand$$u_N^k\,(k=1,2,\dots ,n_T)$$are solutions of (1) and (30), respectively. If$$m \ge r+1, u\in C(0,T; H^m(I)\cap H^1_0(I))$$and satisfies (23), $$|f'(z)|$$is bounded for$$|z|\le K_1$$, $$f\in H^1(I)$$, and$$u_0 \in H^m(I)$$. Then, there exist two positive constants$$\tau ^*_0$$ and $$N^*_0$$such that when$$\tau \le \tau ^*_0$$and$$N \ge N^*_0$$, it holds
\begin{aligned} \Vert u^k-u_N^k\Vert \le C\left( \tau ^{\min \{\sigma -\beta ,1\}}+N^{-r}\right) . \end{aligned}
(57)

### Remark 3.1

We can also extend the method (6) with $$p=2$$ to the nonlinear equation (1), and the nonlinear term $$f(u_N^k)$$ is approximated by a second-order extrapolation $$f(2u_N^{k-1}-u_N^{k-2})$$. The numerical method is given by: find $$u_N^k\in V_N^0$$ for $$k\ge 2$$ such that
\begin{aligned} \left\{ \begin{array}{ll} \left( {D}^{(\beta )}_{\tau } u_N^k,v\right) + \mu \left( \partial _x u_N^{k-\beta /2},\partial _x v\right) =\left( \left(1-\frac{\beta }{2}\right)f(2u_N^{k-1}-u_N^{k-2})+\frac{\beta }{2}f(u_N^{k-1}),v\right) ,\quad \forall v \in V_N^0,\\ u^0=I_N u_0, \end{array}\right. \end{aligned}
(58)
where $$u_N^1$$ can be derived by the fully implicit method or (30) with a smaller step size.

The stability and convergence analysis of the method (58) is similar to that of (6).

### Theorem 3.4

Suppose that$$r \ge 1$$, uand$$u_N^k\,(k=1,2,\dots ,n_T)$$are solutions of (1) and (58), respectively. Assume that$$m \ge r+1, u\in C(0,T; H^m(I)\cap H^1_0(I))$$and satisfies (23), $$|f'(z)|$$and$$|f''(z)|$$are bounded for$$|z|\le K_1$$, $$f\in H^1(I)$$, and$$u_0 \in H^m(I)$$. Then, there exist two positive constants$$\tau _1^*, N^*_1$$such that when$$\tau \le \tau ^*_1$$and$$N \ge N^*_1$$, it holds
\begin{aligned} \Vert u^k-u_N^k\Vert \le C\left( \tau ^{\min \{\sigma -\beta ,2\}}+N^{-r}\right) . \end{aligned}
(59)

## 4 Numerical Results

In this section, a numerical example is presented to illustrate the proposed method.

Consider the model problem (1) with $$\mu =1$$ and $$f(x,t,u)=u+u^2$$. The initial condition is chosen as
\begin{aligned} u_0(x)=\sin (2\pi x). \end{aligned}
Since the exact solution of the problem is unknown, the reference solutions are derived by setting $$N=2^9, \tau =1/2^{12}$$. In Table 1, we list the $$L^2$$-errors and convergence rates of the method (30) in temporal direction with $$N=2^9$$ and different $$\beta$$. From Table 1, we can observe the first-order accuracy in time at $$t=1$$ for $$\beta =0.2$$ and $$\beta =0.9$$. In Table 2, we show the $$L^2$$-errors and convergence rates of the method (58) in temporal direction for $$N=2^9$$. From Table 2, a second convergence order is obtained for $$\beta =0.9$$ due to relatively good regularity of the solution. However, we do not observe second-order accuracy for $$\beta =0.2$$ due to slightly stronger singularity of the solution, but second-order convergence can be recovered by adding the correction terms, which is not investigated here; see [23, 29].
Table 1

The $$L^2$$-errors and convergence rate of the method (30) in time

$$\tau$$

$$\beta =0.2$$

Order

$$\beta =0.9$$

Order

$$2^{-5}$$

$$3.674\,7{\text{E}}-3$$

$$1.855\,44{\text{E}}-2$$

$$2^{-6}$$

$$1.790\,4{\text{E}}-3$$

1.03

$$9.222\,70{\text{E}}-3$$

1.00

$$2^{-7}$$

$$8.744\,0{\text{E}}-4$$

1.03

$$4.541\,97{\text{E}}-3$$

1.02

$$2^{-8}$$

$$4.218\,7{\text{E}}-4$$

1.05

$$2.198\,54{\text{E}}-3$$

1.04

$$2^{-9}$$

$$1.967\,0{\text{E}}-4$$

1.10

$$1.026\,10{\text{E}}-3$$

1.09

Table 2

The $$L^2$$-errors and convergence rate of the method (58) in time

$$\tau$$

$$\beta =0.2$$

Order

$$\beta =0.9$$

Order

$$2^{-5}$$

$$7.976\,5{\text{E}}-4$$

$$4.960\,1{\text{E}}-03$$

$$2^{-6}$$

$$3.695\,1{\text{E}}-4$$

1.11

$$1.285\,4{\text{E}}-03$$

1.94

$$2^{-7}$$

$$1.726\,4{\text{E}}-4$$

1.09

$$3.308\,8{\text{E}}-04$$

1.95

$$2^{-8}$$

$$7.998\,1{\text{E}}-5$$

1.11

$$8.430\,0{\text{E}}-05$$

1.97

$$2^{-9}$$

$$3.591\,4{\text{E}}-5$$

1.15

$$2.118\,1{\text{E}}-05$$

1.99

## 5 Conclusion

A discrete fractional Grönwall inequality for convolution quadrature with the convolution coefficients generated by the generating function is developed. We illustrate its use through the stability and convergence analysis of the Galerkin spectral method for the linear time-fractional subdiffusion equations. We then combined the discrete fractional Grönwall inequality and the temporal–spatial error splitting argument [10] to prove the unconditional convergence of the Galerkin spectral method for the nonlinear time-fractional subdiffusion equation.

We only developed a discrete fractional Grönwall inequality for the convolution quadrature with the coefficients generated by the generalized Newton–Gregory formula of order up to order two [28]. How to construct a discrete fractional Grönwall inequality for other convolution quadratures (see, e.g., [23]) of high-order accuracy will be considered in our future work. It will be interesting to consider the discrete fractional Grönwall inequality for analyzing the numerical methods for multi-term nonlinear time-fractional differential equations [29].

## Notes

### Acknowledgements

The authors wish to thank the referees for their constructive comments and suggestions, which greatly improved the quality of this paper.

## References

1. 1.
Adams, R.A., Fournier, J.J.F.: Sobolev Spaces. Pure and Applied Mathematics, vol. 140, 2nd edn. Elsevier, Amsterdam (2003)
2. 2.
Akrivis, G., Crouzeix, M., Makridakis, C.: Implicit-explicit multistep methods for quasilinear parabolic equations. Numer. Math. 82(4), 521–541 (1999)
3. 3.
Alikhanov, A.A.: A new difference scheme for the time fractional diffusion equation. J. Comput. Phys. 280, 424–438 (2015)
4. 4.
Bernardi, C., Maday, Y.: Spectral methods. Handb. Numer. Anal. 5, 209–485 (1997)
5. 5.
Brenner, S., Scott, R.: The Mathematical Theory of Finite Element Methods, vol. 15. Springer, New York (2007)Google Scholar
6. 6.
Diethelm, K.: The Analysis of Fractional Differential Equations. Springer, Berlin (2010)
7. 7.
Ford, N., Rodrigues, M.M., Vieira, N.: A numerical method for the fractional Schrödinger type equation of spatial dimension two. Frac. Calc. Appl. Anal. 16(2), 454–468 (2013)
8. 8.
Jin, B., Li, B., Zhou, Z.: Numerical analysis of nonlinear subdiffusion equations. SIAM J. Numer. Anal. 56(1), 1–23 (2018)
9. 9.
Kilbas, A.A.A., Srivastava, H.M., Trujillo, J.J.: Theory and Applications of Fractional Differential Equations, vol. 204. Elsevier, Amsterdam (2006)
10. 10.
Li, B.: Mathematical modeling, analysis and computation for some complex and nonlinear flow problems. Ph.D. thesis, City University of Hong Kong (2012)Google Scholar
11. 11.
Li, C., Zeng, F.: The finite difference methods for fractional ordinary differential equations. Numer. Funct. Anal. Opt. 34(2), 149–179 (2013)
12. 12.
Li, C., Zeng, F.: Numerical Methods for Fractional Calculus. CRC Press, Boca Raton (2015)
13. 13.
Li, D., Liao, H.-L., Sun, W., Wang, J., Zhang, J.: Analysis of L1-Galerkin FEMs for time-fractional nonlinear parabolic problems. Commun. Comput. Phys. 24(1), 86–103 (2018)
14. 14.
Li, D., Wang, J., Zhang, J.: Unconditionally convergent L1-Galerkin FEMs for nonlinear time-fractional Schrödinger equations. SIAM J. Sci. Comput. 39(6), A3067–A3088 (2017)
15. 15.
Li, D., Zhang, C., Ran, M.: A linear finite difference scheme for generalized time fractional Burgers equation. Appl. Math. Model. 40(11/12), 6069–6081 (2016)
16. 16.
Li, D., Zhang, J.: Efficient implementation to numerically solve the nonlinear time fractional parabolic problems on unbounded spatial domain. J. Comput. Phys. 322, 415–428 (2016)
17. 17.
Li, D., Zhang, J., Zhang, Z.: Unconditionally optimal error estimates of a linearized Galerkin method for nonlinear time fractional reaction–subdiffusion equations. J. Sci. Comput. 76(2), 848–866 (2018)
18. 18.
Li, H., Wu, H., Ma, H.: The Legendre Galerkin–Chebyshev collocation method for Burgers-like equations. IMA J. Numer. Anal. 23(1), 109–124 (2003)
19. 19.
Liao, H.-L., Li, D., Zhang, J.: Sharp error estimate of the nonuniform L1 formula for linear reaction–subdiffusion equations. SIAM J. Numer. Anal. 56(2), 1112–1133 (2018)
20. 20.
Liao, H.-L., McLean, W., Zhang, J.: A discrete Grönwall inequality with application to numerical schemes for subdiffusion problems. SIAM J. Numer. Anal. 57(1), 218–237 (2019)
21. 21.
Liao, H.-l., McLean, W., Zhang, J.: A second-order scheme with nonuniform time steps for a linear reaction–sudiffusion problem. arXiv:1803.09873
22. 22.
Lin, Y., Xu, C.: Finite difference/spectral approximations for the time-fractional diffusion equation. J. Comput. Phys. 225(2), 1533–1552 (2007)
23. 23.
Lubich, C.: Discretized fractional calculus. SIAM J. Math. Anal. 17(3), 704–719 (1986)
24. 24.
Lubich, C.: Convolution quadrature and discretized operational calculus. I. Numer. Math. 52(2), 129–145 (1988)
25. 25.
Lubich, C.: Convolution quadrature revisited. BIT 44(3), 503–514 (2004)
26. 26.
Stynes, M., O’Riordan, E., Gracia, J.L.: Error analysis of a finite difference method on graded meshes for a time-fractional diffusion equation. SIAM J. Numer. Anal. 55(2), 1057–1079 (2017)
27. 27.
Yu, Y., Deng, W., Wu, Y.: Positivity and boundedness preserving schemes for space-time fractional predator-prey reaction–diffusion model. Comput. Math. Appl. 69(8), 743–759 (2015)
28. 28.
Zeng, F., Li, C., Liu, F., Turner, I.: The use of finite difference/element approaches for solving the time-fractional subdiffusion equation. SIAM J. Sci. Comput. 35(6), A2976–A3000 (2013)
29. 29.
Zeng, F., Zhang, Z., Karniadakis, G.E.: Second-order numerical methods for multi-term fractional differential equations: smooth and non-smooth solutions. Comput. Methods Appl. Mech. Eng. 327, 478–502 (2017)
30. 30.
Zhao, X., Sun, Z.-Z., Karniadakis, G.E.: Second-order approximations for variable order fractional derivatives: algorithms and applications. J. Comput. Phys. 293, 184–200 (2015)