# A Time-Space Collocation Spectral Approximation for a Class of Time Fractional Differential Equations

Authors: Fenghui Huang
Journal: International Journal of Differential Equations
 (2012)

---

## Abstract

A numerical scheme is presented for a class of time fractional differential equations with Dirichlet's and Neumann's boundary conditions. The model solution is discretized in time and space with a spectral expansion of Lagrange interpolation polynomial. Numerical results demonstrate the spectral accuracy and efficiency of the collocation spectral method. The technique not only is easy to implement but also can be easily applied to multidimensional problems.


---

## Body

## 1. Introduction

Fractional differential equations have attracted in recent years considerable interest because of their ability to model complex phenomena. For example, fractional derivatives have been used successfully to model frequency-dependent damping behavior of many viscoelastic materials. They are also used in modeling of many chemical processes, mathematical biology, and many other problems in engineering. Related equations of importance are fractional diffusion equations, the fractional advection-diffusion equation for anomalous diffusion with sources and sinks, and the fractional Fokker-Planck equation for anomalous diffusion in an external field, and so forth.In this paper, we consider the following time fractional differential equation (TFDE)(1.1)Dtμu(x,t)=-λ2u(x,t)-ν∂u(x,t)∂x+D∂2u(x,t)∂x2+f(x,t)=ℒu(x,t)+f(x,t),a<x<b,t>0,
where ℒu(x,t)=-λ2u(x,t)-(ν(∂u(x,t)/∂x))+(D(∂2u(x,t)/∂x2)) is a linear differential operator. λ,ν≥0, D>0 are given constants, 0<μ≤1, f(x,t) is a given continuous function, Dtμu(x,t) is a time fractional derivative which is defined in the Caputo sense
(1.2)Dtαf(t)={∂mf(t)∂tm,α=m∈ℕ,1Γ(m-α)∫0t(t-τ)m-α-1∂mf(τ)dτmdτ,m-1<α<m.
The use of Caputo derivative in the above equation is partly because of the convenience to specify the initial conditions [1].The TFDE (1.1) includes a few special cases: time fractional diffusion equation, time fractional reaction-diffusion equation, time fractional advection-diffusion equations, and their respective corresponding integer-order partial differential equations.There are many analytical techniques for dealing with the TFDE, such as integral transformation method (including Laplace’s transform, Fourier’s transform, and Mellin’s transform) [1–5], operational calculus method [6], Adomian decomposition method [7], iteration method and series method [8], and the method of separating variables [9].One of the key issues with numerical solution of the TFDE (1.1) is design of efficient numerical schemes for time fractional derivative. Until now, most numerical algorithms have relied on the finite difference (FD) methods to discretize the fractional derivatives, and the numerical accuracy always dependent on the order of the fractional derivatives. On the other hand, those FD methods have been generally limited to simple cases (low dimension or small integration) and are very difficult to improve the numerical accuracy [10–14]. Some numerical schemes using low-order finite elements (FE) have also been proposed [15–17]. The fractional derivatives are defined using integrals, so they are nonlocal operators. This nonlocal property means that the next state of a system not only depends on its current state but also on its historical states starting from the initial time. This nonlocal property is good for modeling reality, but they require a large number of operations and a large memory storage capacity when discretized with low-order FD and FE schemes. From this point, the “global method”—the nonlocal methods, like the spectral method—is well suited to discretize the nonlocal operators like fractional-order derivatives. These methods naturally take the global behavior of the solution into account and thus do not result in an extra computational cost when moving from an integer order to a fractional-order model. For example, Hanert has proposed a pseudospectral method based on Chebyshev basis functions in space and Mittag-Leffler basis functions in time to discretize the time-space fractional diffusion equation [18, 19]. Li and Xu have proposed a Galerkin spectral method based on Lagrangian basis functions in space and Jacobi basis functions in time for time fractional diffusion equation [20].In this paper, we propose a time-space collocation spectral method to discretize the TFDEs (1.1), which is easier to implement and apply to multidimensional problems than the existing Galerkin spectral. Another advantage of the present scheme is that the method can easily handle all kinds of boundary conditions.


## 2. Analytical Solution of the TFDE in a Bounded Domain

In this section, we present some analytical solutions of the TFDE which will be found helpful in the comprehension of the nature of such a problem.We consider the TFED (1.1) with initial condition
(2.1)u(x,0)=ϕ(x),x∈(a,b),
and Dirichlet boundary conditions
(2.2)u(a,t)=φ1(t),u(b,t)=φ2(t),t∈(0,T),
or Neumann boundary conditions
(2.3)ux(a,t)=φ1(t),ux(b,t)=φ2(t),t∈(0,T).For the case thatf≡0 and a=0,φ1(t)=φ2(t)=0, by applying the finite sine (cosine) and Laplace transforms to (1.1) with initial condition (2.1), the analytical solutions for the problem can be obtained [5] as
(2.4)u(x,t)=2eνx/2DbD∑n=1∞Eμ(-[ν24D+λ2+(nπb)2]tμ)sin(nπxbD)×∫0bDϕ(y)sin(nπybD)eνy/2Ddy,
for homogeneous Dirichlet boundary conditions, and
(2.5)u(x,t)=2eνx/2DbD∑n=1∞Eμ(-[ν24D+λ2+(nπb)2]tμ)cos(nπxbD)×∫0bDϕ(y)cos(nπybD)eνy/2Ddy,
for homogeneous Neumann boundary conditions. Where Eα(z) denotes a one-parameter Mittag-Leffler function which is defined by the series expansion
(2.6)Eα(z)∶=∑k=0∞zkΓ(αk+1),z∈ℂ,(α>0).Obviously, if we fix the variablex=x*, that is, u(·,t) is a function of the variable t, we can see the solution u(·,t) is not smooth on [0,T]. According to (2.4) and (2.5), its first derivative behaves like u'(·,t)~tμ-1 and the high-order derivative behaves like u(m)(·,t)~tμ-m near t=0+.


## 3. Collocation Spectral Method

First, we give the properties of the Caputo fractional derivative [1] as
(3.1)Jβ(Dβg(t))=g(t)-∑k=0n-1g(0)tkk!,0≤n-1<β<n,
where Jβ is the Riemann-Liouville fractional integral of order β which is defined by
(3.2)Jβg(t)∶=1Γ(β)∫0t(t-τ)β-1g(τ)dτ.By the above properties, we can transform the initial value problem (1.1) into the following Volterra integral equation equivalently:
(3.3)u(x,t)-u(x,0)=1Γ(μ)∫0tℒu(x,τ)(t-τ)1-μdτ+1Γ(μ)∫0tf(x,τ)(t-τ)1-μdτ.For the singular behavior of the exact solution neart=0+ which we have mentioned in the special case (the exact solution (2.4) or (2.5) behaves u'(·,t)~tμ-1 near t=0+), the direct application of the spectral methods is difficult. To overcome this difficulty, we use the technique in [21], that is, applying the transformation
(3.4)u-(x,t)=t1-μ[u(x,t)-u(x,0)],
to make the solution smooth. Then (3.3) is transformed to the equation
(3.5)u-(x,t)=f-(x,t)+t1-μΓ(μ)∫0tℒu-(x,τ)(t-τ)1-μτ1-μdτ,
where
(3.6)f-(x,t)=t1-μΓ(μ)∫0tf(x,τ)dτ(t-τ)1-μ+ℒu(x,0)Γ(1+μ)t.To apply the theory of orthogonal polynomials, we set(3.7)t=T2(1+y),y∈[-1,1];τ=T2(1+s),s∈[-1,y],
then the singular problems (3.5) can be rewritten as
(3.8)v(x,y)=g(x,y)+(T(1+y)/2)1-μΓ(μ)(T2)2μ-1∫-1yℒv(x,s)(y-s)1-μ(1+s)1-μds,
where y∈[-1,1], and
(3.9)v(x,y)=u-(x,T2(1+y)),g(x,y)=f-(x,T2(1+y)).For the collocation methods, (3.8) holds at the Gauss-Lobatto collocation points {xi}i=0N and Jacobi collocation points {yj}j=0N with Jacobi weight functions ω(y)=(1-y2)μ-1 on [-1,1], namely,
(3.10)v(xi,yj)=g(xi,yj)+(T(1+yj)/2)1-μΓ(μ)(T2)2μ-1∫-1yjℒv(xi,s)ds(yj-s)1-μ(1+s)1-μ.By using the following variable change:(3.11)s=sj(θ)=1+yj2θ+yj-12,θ∈[-1,1],
we can rewrite (3.10) as follows:
(3.12)v(xi,yj)=g(xi,yj)+[T(1+yj)/2]1-μΓ(μ)(T(1+yj)/22)2μ-1∫-11ℒv(xi,sj(θ))(1-θ2)1-μdθ=g(xi,yj)+[T(1+yj)/2]μ22μ-1Γ(μ)(ℒv(xi,sj(·)),1)ω.We first usevij, 0≤i≤N; 0≤j≤M to indicate the approximate value for v(xi,yj), then we can use
(3.13)vNM(x,y)=∑n=0N∑m=0Mvnmhn(x)Fm(y),
to approximate the function v(x,y), where hn(x) is the nth Lagrange interpolation polynomial associated with the collocation points {xi}i=0N and Fm(y) is the mth Lagrange interpolation polynomial associated with the collocation points {yi}i=0M.Using a(M+1)-point Gauss quadrature formula relative to the Jacobi weights {ωj}j=0M, (3.12) can be approximated by
(3.14)vij=g(xi,yj)+[T(1+yj)/2]μ22μ-1Γ(μ)(ℒvNM(xi,sj(·)),1)M=g(xi,yj)+[T(1+yj)/2]μ22μ-1Γ(μ)×∑k=0M(∑n=0N∑m=0M‍vnm(-λ2hn(xi)-νhn′(xi)+Dhn′′(xi))Fm(sj(θk)))ωk,∀i=1,…,N-1;j=0,1,…,M,
where the set {θk}k=0M coincides with the collocation points {yj}j=0M on [-1,1].Then the collocation spectral method is to seekvNM(x,y) of the form (3.13) such that vij satisfies the above collocation equations (3.14) for 1≤i≤N-1,0≤j≤M.


## 4. Numerical Results with a Collocation Spectral Approximation

In order to demonstrate the effectiveness of the proposed time-space collocation spectral method, some examples are now presented with Dirichlet boundary conditions, Neumann boundary conditions, and mixed boundary conditions.For completeness sake, the implementation is briefly described here. To simplify the computation, we rewrite the above collocation equations (3.14) into the following:
(4.1)vij=gij+∑n=0N∑m=0Mvnm(-λ2hn(xi)-νhn′(xi)+Dhn′′(xi))(bj∑k=0MFm(sj(θk))ωk)=gij+∑n=0N∑m=0Mdinajmvnm=gij+∑n=1N-1∑m=0Mdinajmvnm+∑m=0M(di0v0m+diNvNm)ajm,∀i=1,…,N-1;j=0,1,…,M,
where
(4.2)bj=[T(1+yj)/2]μ22μ-1Γ(μ),ajm=bj∑k=0MFm(sj(θk))ωk,gij=g(xi,yj),din=-λ2hn(xi)-νhn′(xi)+Dhn′′(xi).In our numerical tests, we use the Chebyshev Gauss-Lobatto collocation points(4.3)xi=a+12(1-cosiπN)(b-a),i=0,1,…,N,
with the associated weights
(4.4)ω-0=ω-N=(b-a)π4N,ω-i=(b-a)iπ2N,i=1,…,N-1,
in the space. The other kinds Gauss-Lobatto collocation points (such as Legendre Gauss-Lobatto collocation points) also can be used. The advantage of Gauss-Lobatto points is that they include the boundary points, which means we can apply boundary conditions there. For the time, the Jacobi Gauss collocation points are used for {yj}j=0M with the associated weights {ωj}j=0M and other kinds of the Jacobi collocation points also suit to be used.Let us set(4.5)VNM=[v10,v20,…,vN-10,v11,…,vN-11,…,vN-1M]T;GNM=[g10,g20,…,gN-10,g11,…,gN-11,…,gN-1M]T;
let A=(aij) be a matrix of (M+1) by (M+1), and D=(dij) is a matrix of (N-1) by (N-1).


### 4.1. Implementation of Dirichlet Boundary Conditions

The Dirichlet boundary conditions are directly applied in (4.1) and give numerical solutions on boundary in the following way:
(4.6)v0m=(T(1+ym)2)1-μ[φ1(T(1+ym)2)-ϕ(a)],vNm=(T(1+ym)2)1-μ[φ2(T(1+ym)2)-ϕ(b)].We set(4.7)G-NM=[g-10,g-20,…,g-N-10,g-11,…,g-N-11,…,g-N-1M]T,
where
(4.8)g-ij=∑m=0M(di0v0m+diNvNm)ajm.Thus, the numerical scheme (4.1) leads to a system of equation of the form
(4.9)VNM=FNM+CVNM,
where FNM=GNM+G-NM, C=[aijD] is a matrix of (N-1)×(M+1) by (N-1)×(M+1).


### 4.2. Implementation of Neumann Boundary Conditions

The Neumann boundary conditions (2.3) at x=a and x=b can be approximated as
(4.10)∂xvNM(x0,ym)=∑n=0Nvnmhn′(x0)=(T(1+ym)2)1-μ[φ1(T(1+ym)2)-ϕ′(x0)]≐rm(1),∂xvNM(xN,ym)=∑n=0Nvnmhn′(xN)=(T(1+ym)2)1-μ[φ2(T(1+ym)2)-ϕ′(xN)]≐rm(2).
Equation (4.10) can be written as follows:
(4.11)h0′(x0)v0m+hN′(x0)vNm=rm(1)-∑n=1N-1vnmhn′(xn),h0′(xN)v0m+hN′(xN)vNm=rm(2)-∑n=1N-1vnmhn′(xn).
Solving (4.11) for v0m and vNm, we get
(4.12)v0m=hN′(x0)(rm(2)-∑n=1N-1‍vnmhn′(xN))-hN′(xN)(rm(1)-∑n=1N-1‍vnmhn′(x0))hN′(x0)h0′(xN)-h0′(x0)hN′(xN),vNm=h0′(xN)(rm(1)-∑n=1N-1‍vnmhn′(x0))-h0′(x0)(rm(2)-∑n=1N-1‍vnmhn′(xN))hN′(x0)h0′(xN)-h0′(x0)hN′(xN).Then the last right term of (4.1) can be written as follows:
(4.13)∑m=0M‍(di0v0m+diNvNm)ajm=∑m=0M‍(ci(1)rm(1)-ci(2)rm(2))ajm+∑m=0M‍(ci(2)∑n=1N-1‍vnmhn′(xN)-ci(1)∑n=1N-1‍vnmhn′(x0))ajm=∑m=0M‍(ci(1)rm(1)-ci(2)rm(2))ajm+∑m=0M‍∑n=1N-1‍vnm(ci(2)hn′(xN)-ci(1)hn′(x0))ajm,
where
(4.14)ci(1)=h0′(xN)diN-hN′(xN)di0hN′(x0)h0′(xN)-h0′(x0)hN′(xN),ci(2)=h0′(x0)diN-hN′(x0)di0hN′(x0)h0′(xN)-h0′(x0)hN′(xN).Let(4.15)G~NM=[g~10,g~20,…,g~N-10,g~11,…,g~N-11,…,g~N-1M]T,
where
(4.16)g~ij=∑m=0M(ci(1)rm(1)-ci(2)rm(2))ajm,(4.17)d~in=din+ci(2)hn′(xN)-ci(1)hn′(x0)=-λ2hn(xi)-νhn′(xi)+Dhn′′(xi)+ci(2)hn′(xN)-ci(1)hn′(x0),D~=(d~ij)isamatrixof(N-1)by(N-1).Then the numerical scheme (4.1) leads to a system of equation of the form
(4.18)VNM=FNM+CVNM,
where FNM=GNM+G~NM, C=[aijD~] is a matrix of (N-1)×(M+1) by (N-1)×(M+1).Remark 4.1.
The implementation for the mixed boundary conditions also can be derived by (4.6) and (4.12).


### 4.3. Numerical Experiments

In this subsection, the proposed numerical scheme is applied to several test problems to show the efficiency and spectral accuracy.In each example, we have calculatedL2 errors and L∞ errors given by the following formulas:
(4.19)L2error=∑i=0N∑j=0M[uij-u(xi,tj)]2wiw-j;L∞error=maxi,j|uij-u(xi,tj)|,
where uij is the numerical approximation solutions of the exact solutions u(xi,tj).Example 4.2 (Dirichlet Boundary Conditions).
In this example, we consider the following time fractional diffusion equations:(4.20)Dtμu(x,t)=∂2u(x,t)∂x2+f(x,t),x∈(-1,1),t∈(0,T)u(x,0)=0,x∈(a,b)u(-1,t)=u(1,t)=0,t∈(0,T),
where
(4.21)f(x,t)=Γ(1+β)Γ(1+β-μ)tβ-μsin(2πx)+4π2tβsin(2πx).
The exact solution is given by
(4.22)u(x,t)=tβsin(2πx),β>-1.In Figure1, we plot the exact and numerical solutions, and, in Figure 2, we represent the associated errors field. Here we set N=M=22, μ=0.8, and β=-0.2. The results in Figures 1 and 2 denote that the numerical solution using the proposed collocation spectral method is excellent in agreement with the exact solution at the whole domain. The efficiency of this collocation spectral method can be further confirmed by Figures 3–4, which are the comparison of the exact solution and numerical solution when the space variable x or time variable t is fixed for various μ and β; here N=M=22.Exact and numerical solution with,μ=0.8,β=-0.2.
(a)
(b)Figure 2
Error filed forμ=0.8,β=-0.2.(a) The comparison of the exact solution and numerical solution whent=3. (b) The comparison of the exact solution and numerical solution when x=0.7557.
(a)
(b)(a) The comparison of the exact solution and numerical solution whent=3. (b) The compare of the exact solution and numerical solution when x=0.7557.
(a)
(b)The main purpose of the numerical test is to check the convergence behavior of numerical solutions with respect to the polynomial degreesM and N for several μ, especially the convergence in time because of the fractional derivative in time. In order to investigate the spatial accuracy when N increases, we take M larger enough so that the time discretization errors are negligible compared with the spatial discretization errors. Similary, for the temporal accuracy, we must keep N large enough to preclude spatial errors. L2 errors and L∞ errors in semilog scale varying with the polynomial degree N (see (a)) or M (see (b)) are shown in Figures 5 and 6 for μ=0.05,0.75 with β=2.2, and Figure 7 for μ=1 with β=1.2. It is clear that the spectral convergence is achieved both of spatial and temporal errors. This indicates that the convergence in space and time of the time-space collocation spectral method is exponential, even though for the classical diffusion equation (μ=1).y-axis is log scale. (a) Errors versus N with M=16,μ=0.05. (b) Errors versus M with N=16,μ=0.05.
(a)
(b)y-axis is log scale. (a) Errors versus N with M=16,μ=0.75. (b) Errors versus M with N=16,μ=0.75.
(a)
(b)y-axis is log scale. (a) Errors versus N with M=16,μ=1. (b) Errors versus M with N=16,μ=1.
(a)
(b)Example 4.3 (Neumann Boundary Conditions).
Consider the time fractional advection-diffusion equation with Neumann boundary conditions(4.23)Dtμu(x,t)=-ν∂u(x,t)∂x+D∂2u(x,t)∂x2+f(x,t),x∈(3,5),t>0,u(x,0)=0,x∈(3,5),∂xu(3,t)=πt22,∂xu(5,t)=-πt22,t>0.
We choose the suitable source term f(x,t) to obtain the exact solution
(4.24)u(x,t)=t2cos(πx2).In Table1, L2 errors and L∞ errors varying with (N,M) and μ are given, and it indicates the efficiency of the present technique.Table 1
L
2 errors and L∞ errors varying with (N, M) and μ.
(N,M)
μ
=
0.1
μ
=
0.6
μ
=
0.99
L
2 error
L
∞ error
L
2 error
L
∞ error
L
2 error
L
∞ error
(6, 22)
8.3822
e
-
004
2.7393
e
-
004
1.8302
e
-
004
1.7793
e
-
004
8.4539
e
-
005
1.2560
e
-
004
(8, 22)
8.8873
e
-
006
2.3883
e
-
006
1.6207
e
-
006
1.5843
e
-
006
7.6277
e
-
007
1.1439
e
-
006
(10, 22)
5.1229
e
-
006
1.8179
e
-
006
4.4081
e
-
008
1.2032
e
-
007
4.3509
e
-
009
6.6034
e
-
009
(22, 6)
0.0013
3.8771
e
-
004
5.0251
e
-
005
5.6230
e
-
005
2.3470
e
-
007
2.9261
e
-
007
(22, 8)
3.7516
e
-
004
1.1631
e
-
004
1.0916
e
-
005
1.4832
e
-
005
4.5707
e
-
008
6.9221
e
-
008
(22, 10)
1.4591
e
-
004
4.6309
e
-
005
3.2976
e
-
006
5.2297
e
-
006
1.2453
e
-
008
2.1838
e
-
008In Figure8, we plot L2 errors and L∞ errors in semilog scale. Figures 8(a) and 8(b) are concerned with the spatial errors with M=16 and the temporal errors with N=16, respectively. As expected, the spatial and temporal spectral convergence is achieved. Our greatest interest is to check the convergence in time because of the fractional derivative in time. So we plot the L2 errors and L∞ errors as functions of M for several more values μ in Figure 9, where N=16. This graph shows that the spectral convergence in time can be reached, and that the time-space collocation spectral method also works well for the classical advection-diffusion equation.y-axis is log scale. (a) Errors versus N with M=16,μ=0.9. (b) Errors versus M with N=16,μ=0.9.
(a)
(b)y-axis is log scale. Errors versus M with N=16 for several μ.
(a)
(b)
(c)
(d)Example 4.4 (Mixed Boundary Conditions).
Consider the time fractional reaction-subdiffusion equation(4.25)Dtμu(x,t)=-34u(x,t)+∂2u(x,t)∂x2,x∈(0,2π),t>0,u(x,0)=sin(x2),x∈(0,2π);u(0,t)=0,∂xu(2π,t)=-12Eμ(-tμ).
The exact solution is given by
(4.26)u(x,t)=Eμ(-tμ)sin(x2).In Figure10, we plot the visual fields of the exact and numerical solutions. Comparing Figures 10(a) and 10(c), and Figures 10(b) and 10(d), we see that the numerical solution is in good agreement with the exact solution; the shapes on the space variable are similar to Sine function. In addition, we can see that the solutions decay over time from the initial state. Comparing Figures 10(a) and 10(b) with Figures 10(c) and 10(d), (a) and (b) decay faster in the beginning and the trend is the opposite of (c) and (d). This is consistent with the behavior of the function Eα(z). For 0<t<0.77, E1/2(-t1/2) decays faster than E1(-t), whereas for t>0.77, the trend is just the opposite.Exact and numerical solutions.
(a)
(b)
(c)
(d)We plot in Figure11 the L2 errors and L∞ errors versus N with M=16 in 11(a) and versus M with N=16 in 11(b). As can be seen in Figure 11, the proposed method provides spatial and temporal spectral convergence for L2 errors and L∞ errors.y-axis is log scale. (a) Error varying with the polynomial degree N. (b) Error varying with the polynomial degree M.
(a)
(b)


## 4.1. Implementation of Dirichlet Boundary Conditions

The Dirichlet boundary conditions are directly applied in (4.1) and give numerical solutions on boundary in the following way:
(4.6)v0m=(T(1+ym)2)1-μ[φ1(T(1+ym)2)-ϕ(a)],vNm=(T(1+ym)2)1-μ[φ2(T(1+ym)2)-ϕ(b)].We set(4.7)G-NM=[g-10,g-20,…,g-N-10,g-11,…,g-N-11,…,g-N-1M]T,
where
(4.8)g-ij=∑m=0M(di0v0m+diNvNm)ajm.Thus, the numerical scheme (4.1) leads to a system of equation of the form
(4.9)VNM=FNM+CVNM,
where FNM=GNM+G-NM, C=[aijD] is a matrix of (N-1)×(M+1) by (N-1)×(M+1).


## 4.2. Implementation of Neumann Boundary Conditions

The Neumann boundary conditions (2.3) at x=a and x=b can be approximated as
(4.10)∂xvNM(x0,ym)=∑n=0Nvnmhn′(x0)=(T(1+ym)2)1-μ[φ1(T(1+ym)2)-ϕ′(x0)]≐rm(1),∂xvNM(xN,ym)=∑n=0Nvnmhn′(xN)=(T(1+ym)2)1-μ[φ2(T(1+ym)2)-ϕ′(xN)]≐rm(2).
Equation (4.10) can be written as follows:
(4.11)h0′(x0)v0m+hN′(x0)vNm=rm(1)-∑n=1N-1vnmhn′(xn),h0′(xN)v0m+hN′(xN)vNm=rm(2)-∑n=1N-1vnmhn′(xn).
Solving (4.11) for v0m and vNm, we get
(4.12)v0m=hN′(x0)(rm(2)-∑n=1N-1‍vnmhn′(xN))-hN′(xN)(rm(1)-∑n=1N-1‍vnmhn′(x0))hN′(x0)h0′(xN)-h0′(x0)hN′(xN),vNm=h0′(xN)(rm(1)-∑n=1N-1‍vnmhn′(x0))-h0′(x0)(rm(2)-∑n=1N-1‍vnmhn′(xN))hN′(x0)h0′(xN)-h0′(x0)hN′(xN).Then the last right term of (4.1) can be written as follows:
(4.13)∑m=0M‍(di0v0m+diNvNm)ajm=∑m=0M‍(ci(1)rm(1)-ci(2)rm(2))ajm+∑m=0M‍(ci(2)∑n=1N-1‍vnmhn′(xN)-ci(1)∑n=1N-1‍vnmhn′(x0))ajm=∑m=0M‍(ci(1)rm(1)-ci(2)rm(2))ajm+∑m=0M‍∑n=1N-1‍vnm(ci(2)hn′(xN)-ci(1)hn′(x0))ajm,
where
(4.14)ci(1)=h0′(xN)diN-hN′(xN)di0hN′(x0)h0′(xN)-h0′(x0)hN′(xN),ci(2)=h0′(x0)diN-hN′(x0)di0hN′(x0)h0′(xN)-h0′(x0)hN′(xN).Let(4.15)G~NM=[g~10,g~20,…,g~N-10,g~11,…,g~N-11,…,g~N-1M]T,
where
(4.16)g~ij=∑m=0M(ci(1)rm(1)-ci(2)rm(2))ajm,(4.17)d~in=din+ci(2)hn′(xN)-ci(1)hn′(x0)=-λ2hn(xi)-νhn′(xi)+Dhn′′(xi)+ci(2)hn′(xN)-ci(1)hn′(x0),D~=(d~ij)isamatrixof(N-1)by(N-1).Then the numerical scheme (4.1) leads to a system of equation of the form
(4.18)VNM=FNM+CVNM,
where FNM=GNM+G~NM, C=[aijD~] is a matrix of (N-1)×(M+1) by (N-1)×(M+1).Remark 4.1.
The implementation for the mixed boundary conditions also can be derived by (4.6) and (4.12).


## 4.3. Numerical Experiments

In this subsection, the proposed numerical scheme is applied to several test problems to show the efficiency and spectral accuracy.In each example, we have calculatedL2 errors and L∞ errors given by the following formulas:
(4.19)L2error=∑i=0N∑j=0M[uij-u(xi,tj)]2wiw-j;L∞error=maxi,j|uij-u(xi,tj)|,
where uij is the numerical approximation solutions of the exact solutions u(xi,tj).Example 4.2 (Dirichlet Boundary Conditions).
In this example, we consider the following time fractional diffusion equations:(4.20)Dtμu(x,t)=∂2u(x,t)∂x2+f(x,t),x∈(-1,1),t∈(0,T)u(x,0)=0,x∈(a,b)u(-1,t)=u(1,t)=0,t∈(0,T),
where
(4.21)f(x,t)=Γ(1+β)Γ(1+β-μ)tβ-μsin(2πx)+4π2tβsin(2πx).
The exact solution is given by
(4.22)u(x,t)=tβsin(2πx),β>-1.In Figure1, we plot the exact and numerical solutions, and, in Figure 2, we represent the associated errors field. Here we set N=M=22, μ=0.8, and β=-0.2. The results in Figures 1 and 2 denote that the numerical solution using the proposed collocation spectral method is excellent in agreement with the exact solution at the whole domain. The efficiency of this collocation spectral method can be further confirmed by Figures 3–4, which are the comparison of the exact solution and numerical solution when the space variable x or time variable t is fixed for various μ and β; here N=M=22.Exact and numerical solution with,μ=0.8,β=-0.2.
(a)
(b)Figure 2
Error filed forμ=0.8,β=-0.2.(a) The comparison of the exact solution and numerical solution whent=3. (b) The comparison of the exact solution and numerical solution when x=0.7557.
(a)
(b)(a) The comparison of the exact solution and numerical solution whent=3. (b) The compare of the exact solution and numerical solution when x=0.7557.
(a)
(b)The main purpose of the numerical test is to check the convergence behavior of numerical solutions with respect to the polynomial degreesM and N for several μ, especially the convergence in time because of the fractional derivative in time. In order to investigate the spatial accuracy when N increases, we take M larger enough so that the time discretization errors are negligible compared with the spatial discretization errors. Similary, for the temporal accuracy, we must keep N large enough to preclude spatial errors. L2 errors and L∞ errors in semilog scale varying with the polynomial degree N (see (a)) or M (see (b)) are shown in Figures 5 and 6 for μ=0.05,0.75 with β=2.2, and Figure 7 for μ=1 with β=1.2. It is clear that the spectral convergence is achieved both of spatial and temporal errors. This indicates that the convergence in space and time of the time-space collocation spectral method is exponential, even though for the classical diffusion equation (μ=1).y-axis is log scale. (a) Errors versus N with M=16,μ=0.05. (b) Errors versus M with N=16,μ=0.05.
(a)
(b)y-axis is log scale. (a) Errors versus N with M=16,μ=0.75. (b) Errors versus M with N=16,μ=0.75.
(a)
(b)y-axis is log scale. (a) Errors versus N with M=16,μ=1. (b) Errors versus M with N=16,μ=1.
(a)
(b)Example 4.3 (Neumann Boundary Conditions).
Consider the time fractional advection-diffusion equation with Neumann boundary conditions(4.23)Dtμu(x,t)=-ν∂u(x,t)∂x+D∂2u(x,t)∂x2+f(x,t),x∈(3,5),t>0,u(x,0)=0,x∈(3,5),∂xu(3,t)=πt22,∂xu(5,t)=-πt22,t>0.
We choose the suitable source term f(x,t) to obtain the exact solution
(4.24)u(x,t)=t2cos(πx2).In Table1, L2 errors and L∞ errors varying with (N,M) and μ are given, and it indicates the efficiency of the present technique.Table 1
L
2 errors and L∞ errors varying with (N, M) and μ.
(N,M)
μ
=
0.1
μ
=
0.6
μ
=
0.99
L
2 error
L
∞ error
L
2 error
L
∞ error
L
2 error
L
∞ error
(6, 22)
8.3822
e
-
004
2.7393
e
-
004
1.8302
e
-
004
1.7793
e
-
004
8.4539
e
-
005
1.2560
e
-
004
(8, 22)
8.8873
e
-
006
2.3883
e
-
006
1.6207
e
-
006
1.5843
e
-
006
7.6277
e
-
007
1.1439
e
-
006
(10, 22)
5.1229
e
-
006
1.8179
e
-
006
4.4081
e
-
008
1.2032
e
-
007
4.3509
e
-
009
6.6034
e
-
009
(22, 6)
0.0013
3.8771
e
-
004
5.0251
e
-
005
5.6230
e
-
005
2.3470
e
-
007
2.9261
e
-
007
(22, 8)
3.7516
e
-
004
1.1631
e
-
004
1.0916
e
-
005
1.4832
e
-
005
4.5707
e
-
008
6.9221
e
-
008
(22, 10)
1.4591
e
-
004
4.6309
e
-
005
3.2976
e
-
006
5.2297
e
-
006
1.2453
e
-
008
2.1838
e
-
008In Figure8, we plot L2 errors and L∞ errors in semilog scale. Figures 8(a) and 8(b) are concerned with the spatial errors with M=16 and the temporal errors with N=16, respectively. As expected, the spatial and temporal spectral convergence is achieved. Our greatest interest is to check the convergence in time because of the fractional derivative in time. So we plot the L2 errors and L∞ errors as functions of M for several more values μ in Figure 9, where N=16. This graph shows that the spectral convergence in time can be reached, and that the time-space collocation spectral method also works well for the classical advection-diffusion equation.y-axis is log scale. (a) Errors versus N with M=16,μ=0.9. (b) Errors versus M with N=16,μ=0.9.
(a)
(b)y-axis is log scale. Errors versus M with N=16 for several μ.
(a)
(b)
(c)
(d)Example 4.4 (Mixed Boundary Conditions).
Consider the time fractional reaction-subdiffusion equation(4.25)Dtμu(x,t)=-34u(x,t)+∂2u(x,t)∂x2,x∈(0,2π),t>0,u(x,0)=sin(x2),x∈(0,2π);u(0,t)=0,∂xu(2π,t)=-12Eμ(-tμ).
The exact solution is given by
(4.26)u(x,t)=Eμ(-tμ)sin(x2).In Figure10, we plot the visual fields of the exact and numerical solutions. Comparing Figures 10(a) and 10(c), and Figures 10(b) and 10(d), we see that the numerical solution is in good agreement with the exact solution; the shapes on the space variable are similar to Sine function. In addition, we can see that the solutions decay over time from the initial state. Comparing Figures 10(a) and 10(b) with Figures 10(c) and 10(d), (a) and (b) decay faster in the beginning and the trend is the opposite of (c) and (d). This is consistent with the behavior of the function Eα(z). For 0<t<0.77, E1/2(-t1/2) decays faster than E1(-t), whereas for t>0.77, the trend is just the opposite.Exact and numerical solutions.
(a)
(b)
(c)
(d)We plot in Figure11 the L2 errors and L∞ errors versus N with M=16 in 11(a) and versus M with N=16 in 11(b). As can be seen in Figure 11, the proposed method provides spatial and temporal spectral convergence for L2 errors and L∞ errors.y-axis is log scale. (a) Error varying with the polynomial degree N. (b) Error varying with the polynomial degree M.
(a)
(b)


## 5. Conclusion

This paper proposes a time-space collocation spectral method for a class of time fractional differential equations with Caputo derivatives. The proposed method also works well for the corresponding classical integer-order partial differential equations (μ=1), and it differs from (and is simpler than) the existing time-space spectral methods which are based on the Petrov-Galerkin or Dual-Petrov-Galerkin formulation. The main advantage of the present scheme is that it gives very accurate convergency by choosing less number of grid points and the problem can be solved up to big time, and the storage requirement due to the time memory effect can be considerably reduced. At the same time, the technique is also simpler and easier to apply to multidimensional problems than the existing Galerkin spectral method such as the methods in [19, 20].



---

*Source: 495202-2012-09-09.xml*