fem convergence for pdes with point sources in 2-d and 3-d · fem convergence for pdes with point...

6

Click here to load reader

Upload: phamngoc

Post on 23-Feb-2019

212 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: FEM Convergence for PDEs with Point Sources in 2-D and 3-D · FEM Convergence for PDEs with Point Sources in 2-D and 3-D ... point sources is given by the Dirac delta distribu-

FEM Convergence for PDEs with Point Sources in 2-D and 3-D

Kourosh M. Kalayeh1, Jonathan S. Graf2, and Matthias K. Gobbert2∗

1Department of Mechanical Engineering, University of Maryland, Baltimore County2Department of Mathematics and Statistics, University of Maryland, Baltimore County∗Corresponding author: 1000 Hilltop Circle, Baltimore, MD 21250, [email protected]

Abstract: Numerical theory provides the basisfor quantification of the accuracy and reliability ofa FEM solution by error estimates on the FEM er-ror vs. the mesh spacing of the FEM mesh. Thispaper presents techniques needed in COMSOL 5.1to perform computational studies for elliptic testproblems in two and three space dimensions thatdemonstrate this theory by computing the conver-gence order of the FEM error. In particular, weshow how to perform these techniques for a prob-lem involving a point source modeled by a Diracdelta distribution as forcing term. This demon-strates that PDE problems with a non-smoothsource term necessarily have degraded convergenceorder compared to problems with smooth right-hand sides and thus can be most efficiently solvedby low-order FEM such as linear Lagrange ele-ments.

Keywords: Poisson equation, point source,Dirac delta distribution, convergence study, meshrefinement.

1 Introduction

The finite element method (FEM) is widely used asa numerical method for the solution of partial dif-ferential equation (PDE) problems, especially forelliptic PDEs such as the Poisson equation withDirichlet boundary conditions

−∆u = f in Ω, (1)

u = r on ∂Ω, (2)

where f(x) and r(x) denote given functions on thedomain Ω and on its boundary ∂Ω, respectively.We assume the domain Ω ⊂ Rd to be a bounded,open, simply connected, convex set in d = 2 or 3space dimensions with a polygonal boundary ∂Ω.Concretely, we consider Ω = (−1, 1)d, since this do-main can be discretized by a FEM mesh consistingof triangles in 2-D or tetrahedra in 3-D withouterror.

The FEM solution uh will typically incur an er-ror against the PDE solution u of the problem (1)–(2). This can be quantified by bounding the normof the error u − uh in terms of the mesh spacingh of the finite element mesh. Such estimates havethe form, e.g., [1, Section II.7],

‖u− uh‖L2(Ω)≤ C hq, as h→ 0, (3)

where C is a problem-dependent constant indepen-dent of h and the constant q indicates the orderof convergence of the FEM as the mesh spacingh decreases. We see from this form of the errorestimate that we need q > 0 for convergence ash → 0. More realistically, we wish to have forinstance q = 1 for linear convergence, q = 2 forquadratic convergence, etc., where higher valuesyield faster convergence.

The norm ‖u− uh‖L2(Ω)in (3) is the L2-norm as-

sociated with the space L2(Ω) of square-integrablefunctions, that is, the space of all functions v(x)whose square v2(x) can be integrated over allx ∈ Ω without becoming infinite. The norm is de-fined concretely as the square root of that integral,

namely ‖v‖L2(Ω)

:=(∫v2(x) dx

)1/2.

The result stated in (3) necessitates require-ments on the finite elements used as well as onthe PDE problem (1)–(2):

• Lagrange finite elements, such as thosein COMSOL Multiphysics, approximate thePDE solution u at several points in each el-ement K of a mesh Th, such that the restric-tion of uh to each element K is a polyno-mial of degree up to p and uh(x) is continuousacross all boundaries between neighboring el-ements throughout Ω. For the case of linearLagrange elements with piecewise polynomialdegree p = 1, the convergence order is q = 2in (3), i.e., one higher than the polynomialdegree; it also holds under additional assump-tions on the PDE problem that for higher-order elements with degree p, the convergenceorder in (3) can reach q = p+ 1.

1

Excerpt from the Proceedings of the 2015 COMSOL Conference in Boston

Page 2: FEM Convergence for PDEs with Point Sources in 2-D and 3-D · FEM Convergence for PDEs with Point Sources in 2-D and 3-D ... point sources is given by the Dirac delta distribu-

• One necessary assumption on the PDE is thatthe problem has a solution u(x) that is suf-ficiently regular, as expressed by the num-ber of derivatives it has. In the context ofthe FEM, it is appropriate to consider weakderivatives [1]. Based on these, we define theSobolev function spaces Hk(Ω) of order k ofall functions on Ω that have weak derivativesup to order k that are square-integrable in thesense of L2(Ω) above. The convergence orderq in (3) of the FEM with Lagrange elementswith degree p is then limited by the regularityorder k of the PDE solution as q ≤ k.

These two facts above can be combined into theformula q = mink, p + 1 in (3). Thus, forlinear Lagrange elements for instance, we needu ∈ Hk(Ω) with k = 2 to reach the optimal con-vergence order of q = p+ 1 = 2.

The purpose of this paper is to show how onecan demonstrate computationally the convergenceorder q = p + 1 = 2 for linear Lagrange FEM el-ements, if the PDE solution u is smooth enough(i.e., k ≥ 2). Moreover, we demonstrate that theconvergence order is indeed limited by q ≤ k, ifthe solution is not smooth enough (i.e., k < 2).This latter situation arises concretely when con-sidering a PDE with one (or more) point sourcesin the forcing term f(x) on the right-hand side of(1). The reason is that the mathematical model forpoint sources is given by the Dirac delta distribu-tion δ(x). This function is not square-integrable,and thus the PDE solution u is not in H2(Ω).

In Section 2, we explain the numerical methodapplied to both smooth and a non-smooth prob-lems in the following Sections 3 and 4, respectively.Specifically, Section 2 specifies how to initializeconvergence studies with the coarsest meshes pos-sible in two and three space dimensions and how todevelop a computable estimate q(est) of the conver-gence order q in (3) by regular mesh refinements.Section 3 shows the results for the convergencestudies with smooth PDE solutions, which demon-strate that q = 2 in both two and three space di-mensions of the PDE domain Ω ⊂ Rd. By contrast,Section 4 shows that for (1) with f = δ as forcingterm, the convergence is limited in a dimension-dependent way, namely to q = 1.0 in two andq = 0.5 in three dimensions. In [2], we provide de-tailed instructions for obtaining the results of thisreport in COMSOL 5.1.

2 Numerical Method

One well-known, practical test for reliability of aFEM solution is to refine the FEM mesh, computethe solution again on the finer mesh, and comparethe solutions on the two meshes qualitatively. TheFEM theory provides a quantification of this ap-proach by comparing FEM errors u− uh involvingthe PDE solution u compared to FEM solutionson meshes, whose mesh spacings h are related byregular mesh refinement. We use this theory herefor linear Lagrange elements as provided in COM-SOL Multiphysics. Since the domains Ω = (−1, 1)d

have polygonal boundaries, they can be discretizedby triangular meshes in d = 2 and by tetrahedralmeshes in d = 3 dimensions without error. Theconvergence studies performed rely on a sequenceof meshes with mesh spacings h that are halvedin each step. This is accomplished by uniformlyrefining an initial mesh repeatedly, starting froma minimal initial mesh to allow as many refine-ments as possible. For the initial mesh, we takeadvantage of the shape of Ω that admits a verycoarse, uniform mesh that still includes the originx = 0 as a mesh point, which is needed later forthe non-smooth problems in Section 4. In d = 2dimensions, the initial mesh consists of 4 triangleswith 5 vertices given by the 4 corners of Ω plusthe center point. In d = 3 dimensions, the ini-tial mesh has 28 tetrahedra with 15 vertices. Fig-ures 1 (a) and (b) show the initial meshes for thetwo- and three-dimensional domains, respectively.Figures 2 (a) and (b) show the exploded view of theinitial mesh in three-dimensional domain. WhileFigure 2 (a) shows the exploded view of initialmesh for whole domain, Figure 2 (b) shows the ex-ploded view with some elements removed so thatwe can view the inside elements of the domain andconfirm that the origin is indeed a point in the dis-cretization. Instructions for generating these meshviews are included in [2].

The initial meshes are refined uniformly m =1, 2, . . . times. For each mesh, we track the num-ber of mesh elements Ne, the degrees of freedom(DOF) N of the linear Lagrange elements for thatmesh (i.e., the number of vertices), and the meshspacing h for each refinement level m from the ini-tial mesh for m = 0 to the finest mesh explored, assummarized in Tables 1 (a) and (b). The solutionplots in the following sections use the mesh withrefinement level m = 3.

2

Excerpt from the Proceedings of the 2015 COMSOL Conference in Boston

Page 3: FEM Convergence for PDEs with Point Sources in 2-D and 3-D · FEM Convergence for PDEs with Point Sources in 2-D and 3-D ... point sources is given by the Dirac delta distribu-

All test problems are designed to have a knowntrue PDE solution u(x) = utrue(x) to allow for adirect computation of the error u− uh against theFEM solution and its norm in (3). The conver-gence order q is then estimated from these com-putational results by the following steps: Startingfrom the initial mesh, we refine it uniformly repeat-edly. If the mesh spacing h is defined as the maxi-mum side length of all elements, i.e., h := maxe he,this procedure halves the value of h in each re-finement. In two dimensions, regular mesh refine-ment sub-divides every triangle into 4 triangles.In three dimensions, the same halving of h occurs,however the regular mesh refinement sub-divideseach tetrahedral element into 8 smaller tetrahe-dra. The number of elements Ne as well as theobserved mesh spacing h in Tables 1 (a) and (b)

(a) d = 2

(b) d = 3

Figure 1: Initial mesh in (a) two dimensions,(b) three dimensions.

exhibit the expected behavior associated with reg-ular mesh refinement. Let m denote the numberof refinement levels from the initial mesh and de-fine Em := ‖u− uh‖L2(Ω)

as the error norm onrefinement level m = 0, 1, 2, . . .. Then assum-ing that Em = C hq according to (3), the errorfor the next coarser mesh with mesh spacing 2his Em−1 = C (2h)q = 2q C hq. Their ratio isthen Rm = Em−1/Em = 2q and Qm = log2(Rm)provides us with a computable estimate q(est) =limr→∞Qm for q in (3) as h→ 0.

(a)

(b)

Figure 2: Exploded view of the initial mesh in threedimensions (a) for whole domain, (b) elements onone side removed to show interior elements of thedomain.

3

Excerpt from the Proceedings of the 2015 COMSOL Conference in Boston

Page 4: FEM Convergence for PDEs with Point Sources in 2-D and 3-D · FEM Convergence for PDEs with Point Sources in 2-D and 3-D ... point sources is given by the Dirac delta distribu-

Table 1: Finite element data for all meshes in di-mensions d = 2 and 3 for all refinement levels m.

m Ne N = DOF h0 4 5 2.00001 16 13 1.00002 64 41 0.50003 256 145 0.25004 1,024 545 0.12505 4,096 2,113 0.0625

(a) d = 2

m Ne N = DOF maxe he0 28 15 2.00001 224 69 1.00002 1,792 409 0.50003 14,336 2,801 0.25004 114,688 20,705 0.12505 917,504 159,169 0.0625

(b) d = 3

3 Smooth Test Problems

For the smooth test problems, the right-hand sideof Poisson equation f(x) in (1) is chosen as

f(x) =

π2

(1ρ sin πρ

2 + π2 cos πρ2

)for d = 2,

π2

(2ρ sin πρ

2 + π2 cos πρ2

)for d = 3,

where the norm ρ =√x2 + y2 in 2-D and ρ =√

x2 + y2 + z2 in 3-D. This function satisfies thestandard assumption of f ∈ L2(Ω) using in classi-cal FEM theory [1, Chapter II]. This classical the-ory provides that u is two orders smoother, that is,u ∈ H2(Ω), since L2(Ω) ≡ H0(Ω) formally. Theproblems are chosen such that we know the PDEsolutions

utrue(x) =

cosπ√x2+y2

2 for d = 2,

cosπ√x2+y2+z2

2 for d = 3,(4)

provided we choose the boundary condition func-tion in (2) consistently as r(x) = utrue(x). Fig-ures 3 (a) and (b) show two views of the FEMsolution for mesh refinement m = 3.

The true PDE solutions utrue(x) in (4) are in-finitely often differentiable in the classical sense,and hence the regularity order k = ∞ does

not limit the predicted convergence order q =mink, p+ 1 for any degree p of the Lagrange el-ements. Specifically for linear Lagrange elementswith degree p = 1, we expect to see q = 2 as con-vergence order for all spatial dimensions d = 2, 3.Table 2 lists for each refinement level m the errorEm = ‖uh(·, t)− u(·, t)‖

L2(Ω)of (3) and in paren-

theses the estimate Qm according to Section 2. Weobserve that Qm approaches the value q(est) = 2,which is expected for a smooth source term in anyspatial dimension d = 2, 3.

(a)

(b)

Figure 3: (a) Two-dimensional and (b) three-dimensional view of the FEM solution for thesmooth test problem with m = 3.

4

Excerpt from the Proceedings of the 2015 COMSOL Conference in Boston

Page 5: FEM Convergence for PDEs with Point Sources in 2-D and 3-D · FEM Convergence for PDEs with Point Sources in 2-D and 3-D ... point sources is given by the Dirac delta distribu-

Table 2: Convergence studies for the smooth testproblem in two and three dimensions.

m Em (Qm)0 1.1051 3.049e–01 (1.86)2 8.387e–02 (1.86)3 2.177e–02 (1.95)4 5.511e–03 (1.98)5 1.383e–03 (1.99)

(a) d = 2

m Em (Qm)0 1.1321 3.481e–01 (1.70)2 9.007e–02 (1.95)3 2.273e–02 (1.99)4 5.690e–03 (2.00)5 1.422e–03 (2.00)

(b) d = 3

4 Non-Smooth Test Problems

For the non-smooth test problems, the forcing termf(x) in (1) is chosen to model a point source. Thisis mathematically modeled by setting the forcingterm as the Dirac delta distribution f(x) = δ(x).The Dirac delta distribution models a point sourceat x ∈ Ω mathematically by requiring δ(x− x) = 0for all x 6= x, while simultaneously satisfying∫ϕ(x) δ(x− x) dx = ϕ(x) for any continuous func-

tion ϕ(x). Based on the weak formulation of theproblem, the finite element method is able to han-dle the source at x = 0 modeled by f(x) = δ(x)in (1). That is, when the PDE is integrated in thederivation of the FEM with respect to a continu-ous test function v(x), the right-hand side becomes∫

Ωv(x) δ(x) dx = v(0). If the point x = 0 is cho-

sen as a mesh point of the FEM mesh, then thetest function of the FEM with Lagrange elementsevaluated at 0 in turn will equal 1 for the FEM ba-sis function v(x) centered at this mesh point and0 for all others. This is the background behindthe instructions in the COMSOL documentationto implement a point source modeled by the Diracdelta distribution by entering 1 as source functionvalue at that mesh point. These instructions canbe located by searching for “point source” in theCOMSOL documentation.

Also for these problems exist closed-form PDE

solutions utrue(x), namely

utrue(x) =

− ln√x2+y2

2π for d = 2,1

4π√x2+y2+z2

for d = 3,(5)

provided we again choose the boundary conditionfunction in (2) consistently as r(x) = utrue(x). Fig-ures 4 (a) and (b) show two views of the FEMsolution for mesh refinement m = 3. The FEMsolution in the plots approaches the true solution,but the linear patches of the Lagrange elementswith p = 1 are still clearly visible here. No-tice that the true PDE solutions have a singular-ity at the origin 0, where they tend to infinity.Thus, the solutions are not differentiable every-where in Ω and thus not in any space of continu-ous or continuously differentiable functions. How-ever, recall the Sobolev Embedding Theorem [3].Since

∫ϕ(x) δ(x) dx = ϕ(0) for any continuous

function ϕ(x), and the Sobolev space Hd/2+ε iscontinuously embedded in the space of continuousfunction C0(Ω) in d = 1, 2, 3 dimensions for anyε > 0, one can argue that δ is in the dual spaceof ϕ ∈ Hd/2+ε(Ω), that is, δ ∈ H−d/2−ε(Ω). Sincethe solution u of this second-order elliptic PDEis two orders smoother, we obtain the regularityu ∈ H2−d/2−ε(Ω) or k ≈ 2−d/2 in (3), which sug-gests to expect a dimension-dependent convergenceorder q = 2− d/2 for d = 2, 3 dimensions [4, 5].

Table 3 presents the error norm Em as well asthe observed Qm in parentheses. For d = 2 dimen-sions in Table 3 (a), we see that Qm approachesthe value q(est) = 1.0, while for d = 3 dimensionsin Table 3 (b), it approaches the value 0.5, whichindeed agrees with the expected order q = 2−d/2.

5 Conclusions

In this paper, the test problems are Poisson equa-tions with smooth or non-smooth solutions. Withtrue PDE solution available, we can calculate er-rors with the FEM solution against the PDE so-lution. For the smooth test problems, the conver-gence order is 2 in all dimensions d = 2, 3. In thenon-smooth test problems, the results agree withthe theoretical expectation that convergence orderis reduced in a dimension-dependent way to q = 1.0in two and q = 0.5 in three dimensions. Therefore,linear Lagrange elements, which require less com-putational effor than higher-order elements, are op-

5

Excerpt from the Proceedings of the 2015 COMSOL Conference in Boston

Page 6: FEM Convergence for PDEs with Point Sources in 2-D and 3-D · FEM Convergence for PDEs with Point Sources in 2-D and 3-D ... point sources is given by the Dirac delta distribu-

(a)

(b)

Figure 4: (a) Two-dimensional and (b) three-dimensional view of the FEM solution for the non-smooth test problem with m = 3.

timal for problems involving point sources modeledby Dirac delta distributions.

Acknowledgments

The hardware used in the computational stud-ies is part of the UMBC High Performance Com-puting Facility (HPCF). The facility is supportedby the U.S. National Science Foundation throughthe MRI program (grant nos. CNS–0821258 andCNS–1228778) and the SCREMS program (grantno. DMS–0821311), with additional substantialsupport from the University of Maryland, Bal-timore County (UMBC). See hpcf.umbc.edu formore information on HPCF and the projects using

Table 3: Convergence studies for the non-smoothtest problem in two and three dimensions.

m Em (Qm)0 9.332e–021 4.589e–02 (1.02)2 2.468e–02 (0.89)3 1.256e–02 (0.97)4 6.311e–03 (0.99)5 3.160e–03 (1.00)

(a) d = 2

m Em (Qm)0 1.026e–011 6.990e–02 (0.55)2 4.842e–02 (0.53)3 3.410e–02 (0.51)4 2.410e–02 (0.50)5 1.704e–02 (0.50)

(b) d = 3

its resources. Co-author Graf acknowledges finan-cial support as HPCF RA.

References

[1] Dietrich Braess. Finite Elements. CambridgeUniversity Press, third edition, 2007.

[2] Kourosh M. Kalayeh, Jonathan S. Graf, andMatthias K. Gobbert. FEM convergence stud-ies for 2-D and 3-D elliptic PDEs with smoothand non-smooth source terms in COMSOL 5.1.Technical Report HPCF–2015–19, UMBC HighPerformance Computing Facility, University ofMaryland, Baltimore County, 2015.

[3] Michael Renardy and Robert C. Rogers. AnIntroduction to Partial Differential Equations,vol. 13 of Texts in Applied Mathematics.Springer-Verlag, second edition, 2004.

[4] Ridgway Scott. Finite element convergence forsingular data. Numer. Math., vol. 21, pp. 317–327, 1973.

[5] Thomas I. Seidman, Matthias K. Gobbert,David W. Trott, and Martin Kruzık. Finiteelement approximation for time-dependent dif-fusion with measure-valued source. Numer.Math., vol. 122, no. 4, pp. 709–723, 2012.

6

Excerpt from the Proceedings of the 2015 COMSOL Conference in Boston