Contents lists available atScienceDirect
Journal of Computational Physics
www.elsevier.com/locate/jcp
Analyses on the finite difference method by Gibou et al. for Poisson equation
Gangjoon Yoon
a, Chohong Min
b,∗
aInstituteofMathematicalSciences,EwhaWomansUniversity,Seoul,120-750,RepublicofKorea bMathematicsDepartment,EwhaWomansUniversity,Seoul,120-750,RepublicofKorea
a r t i c l e i n f o a b s t r a c t
Articlehistory:
Received5June2014
Receivedinrevisedform11September 2014
Accepted12September2014 Availableonline22September2014
Keywords:
Poissonequation Finitedifferencemethod Preconditioning Convergenceanalysis
Gibouetal.in[4]introducedafinitedifferencemethodforsolvingthePoissonequationin irregulardomainswiththeDirichletboundarycondition.Contrarytoitsgreatimportance, its properties have not been mathematically analyzed, but have just been numerically observed.In thisarticle, we present two analysesfor the method. One proves that its solution issecond orderaccurate, and the other estimatesthe condition number ofits linearsystem.Accordingtoourestimation,theconditionnumberoftheunpreconditioned linearsystemisofsize O(1/(h·hmin)),andeachofJacobi,SGS, and ILUpreconditioned systemsisofsizeO(h−2).Furthermore,ouranalysisshowsthattheconditionnumberof MILUisofsizeO(h−1),themostsuccessfulone.
©2014ElsevierInc.All rights reserved.
1. Introduction
TheShortley–Weller method[13] isabasicfinitedifferencemethodforsolvingthePoissonequation withtheDirichlet boundary condition. It is a simplesum ofthe central finitedifferences inthe Cartesian directions.Thoughimplemented in uniformgrid, the methodcan handlearbitrarily shaped domains. Its solution issecond order accurate to theanalytic solution.Usuallythegradientofasecondorderaccuratesolutionisonlyfirstorderaccurate,howeverthesolutionexhibits asupra-convergencebehavior.Itsgradientisalsosecondorderaccurate[10].
Thoughitsexcellenceinefficiencyandaccuracy,theShortley–Wellermethodconstitutesanon-symmetriclinearsystem.
Only in one dimension, the linear system can be castin a symmetric form [14]. Since the Laplacian is self-adjoint, the methodthat approximatestheoperator isexpectedtobesymmetric.Gibouetal.[4]introduceda simplemodificationof theShortley–Wellermethodthatresultsinasymmetriclinearsystem.Numericaltests[10]suggestthatthesolutionisstill secondorderaccurate.
ComparedtotheShortley–Wellermethod,themethodbyGibouetal.hasanadvantagetosolvesymmetriclinearsystem.
Thegain,however,turnsouttohavenotcomefree.Thesupra-convergenceoftheShortley–Wellermethodislostwiththe gain.Thesolutiongradientisonlyfirstorderaccurate.Bothmethodshavetheirownprosandconsasdescribedabove,anda choicebetweenthemdependsonthecharacteristicofthegivenproblem.Forexample,inapplicationtoincompressiblefluid flowsthesolutiongradientisaphysicalvariableandtheShortley–Wellermethodwouldbepreferred,andinapplicationto heatflowsthemethodbyGibouetal.wouldbedesired.
*
Correspondingauthor.E-mailaddress:chohong@ewha.ac.kr(C. Min).
http://dx.doi.org/10.1016/j.jcp.2014.09.009 0021-9991/©2014ElsevierInc.All rights reserved.
Fig. 1. Grid nodes inΩhare marked by◦and nodes inΓhby•. A grid node(xi,yj)∈ Ωhhas four neighboring nodes inΩh∪ Γh.
Contrarytotheirgreatimportance,theconvergencepropertiesoftheShortley–WellermethodandthemethodbyGibou etal. havejust beennumerically observed.The numerical tests, which are merely finite howevermany, are not enough toascertaintheproperties.ThoughtheShortley–Wellermethod[13]wasintroducedin1938,itisveryrecenttoseesome mathematicalanalysesonthegradientofitssolution.In2003,Lietal.[7,9]showedthesecondorderaccuracyinrectangular domains,andLietal.[8]the1
.
5 orderaccuracyinpolygonaldomains.In2014,wein[16]showedthesecondorderaccuracy ingeneraldomains.AnimportantaspectofaPoissonsolveristhesizeoftheconditionnumberofitsassociatedlinearsystem.Alarge-sized condition number not onlydelays theconvergence to solve butalsodrops many significant digits inthe approximation.
The seminal work of Gustafsson [6] shows that only the modified incomplete-LU (MILU) preconditioner among many incomplete-LU (ILU)type preconditioners enhancesthe condition numberofthe standard finitedifference Poissonsolver with differentorder of magnitude. His work can deal onlywith rectangular domains. It is also very recent to see such estimationsinirregulardomains.Wein[15]arrivedatthesameconclusionfortheShortley–Wellermethod.OnlytheMILU enhancestheconditionnumberwithdifferentorderofgrowthwithrespecttogridstepsizeh.
In thisarticle, we introduce two analyses forthe method by Gibou etal. Oneproves that the solutionis second or- der accurate to the analytic solution. The other estimates the condition number of its linear systemwith and without preconditioners.The estimationshowsthat theunpreconditionedlinearsystemhasaverylarge conditionnumberofsize O
(
1/(
h·
hmin))
,whereh isthedefaultstepsize ofuniformgridandhmin istheminimumstepsize thatis usuallymuch smaller than h. We then show that Jacobi, symmetric Gauss–Seidel (SGS),and ILU preconditioners on the linear system reducetheconditionnumberfromO(
1/(
h·
hmin))
to O(
h−2)
.Finally,weshowthat MILUpreconditionerexcels theothers bygainingO(
h−1)
size.2. Convergenceanalysis
Considerauniformgridh
Z
2withstepsizeh.LetΩ
hbethesetofnodesofthegridbelongingtoΩ
,andΓ
h betheset ofintersectionpointsbetweenΓ
andgridlines.Agridnode(
xi,
yi) ∈ Ω
hhasfourneighboringnodesinΩ
h∪ Γ
h,(
xi±1,
yj)
and(
xi,
yj±1)
inΩ
h∪Γ
h,asillustratedinFig. 1.Lethi+12,jdenotethedistancefrom
(
xi,
yj)
toitsneighbor(
xi+1,
yj)
.Other distanceshi−12,j
,
hi,j+1 2,
hi,j−12 aresimilarlydefined.TheworkofGibouetal.[4]solvesthePoissonequationwithDirichlet boundarycondition
−
u=
f inΩ
u
=
g onΓ,
(1)bysolvingthediscreteequation
−
huh(
xi,
yj) =
f(
xi,
yj), (
xi,
yj) ∈ Ω
huh
(
xi,
yj) =
g(
xi,
yj), (
xi,
yj) ∈ Γ
h.
(2)HerethediscreteLaplacianoperator
hu
: Ω
h→ R
isdefinedas−(
hu)
i j:=
ui j−
ui+1,jhi+1 2,j
+
ui j−
ui−1,jhi−1 2,j
1 h+
ui j−
ui,j+1hi,j+1 2
+
ui j−
ui,j−1hi,j−1 2
1h
.
(3)The equationsforeach node point
(
xi,
yj)
constitutea symmetriclinear systemwhosematrixis an M-matrix.It was numericallyobservedin[10]thatthenumericalsolutionissecondorderaccurateandthegradientofthesolutionisonly firstorderaccurate.Inthissection,we analyzetheconsistencyandconvergenceaccuracyoftheGibouetal.method,whichshowsthatthe discretesolutionapproximatesthecontinuoussolutionwiththesecondorderaccuracy.Thoughtheconsistencyorderofthe discretizationrangesfromthezerotothesecond,itsconvergenceorderisthesecondordereverywhere.
Definition2.1.
Ω
h∗⊂ Ω
hdenotesthesetofgridnodesadjacenttoΓ
h,andΩ
h◦= Ω
h\ Ω
h∗.In Definition 2.1,we divides thenodes in
Ω
h intotwo sets.Every node(
xi,
yj) ∈ Ω
h◦ hasthe fourneighboringpoints insideΩ
h sothat hi±12,j
=
hi,j±12
=
h.Ontheother hand,if(
xi,
yj) ∈ Ω
h∗,thenatleastoneofits fourneighboringpoints belongstoΓ
h.Lemma2.2(Consistencyerror).Forasmoothfunctionu
: Ω → R
,|
hu−
u| ≤
C1h2,
inΩ
h◦C2
+
C3h,
inΩ
h∗,
(4)whereC1
,
C2,andC3areconstantsindependentofh.Proof. AsimpleTaylorseriesexpansiononu showstheconsistencyerror(4)withconstantsC1
,
C2,andC3dependentonly onu andΩ
.2
The discrete equation (2)for each
(
xi,
yj) ∈ Ω
h formsa symmetric linear systemwhose matrixis an M-matrix [12].An importantpropertyofan M-matrixisthatitsinverseisnon-negativeineveryentry,fromwhichthediscretemaximum principlefollows.
Lemma2.3 (Discretemaximumprinciple). If
−
hν ≥
0,thentheminimumvalueofν
shouldbe achievedonΓ
h.Similarly,if−
hν ≤
0,thenthemaximumvalueofν
shouldbeachievedonΓ
h.Likewise,if−
hν
1≥ −
hν
2inΩ
handν
1≥ ν
2onΓ
h,thenν
1≥ ν
2onΩ
h∪ Γ
h.Lemma2.4.Letwhbethesolutionof
−
hwh=
0 inΩ
h◦1 in
Ω
h∗ and wh=
0 onΓ
h.
Then0
≤
wh≤
h2inΩ
h.Proof. Since
−
hwh≥
0 inΩ
h and wh=
0 onΓ
h, the maximum principle implies that wh≥
0 inΩ
h. Furthermore, the maximum of wh is attainedat some point(
xi∗,
yj∗) ∈ Ω
h∗.Belonging toΩ
h∗,at least one of the four neighborhood points of(
xi∗,
yj∗)
, say(
xi∗−1,
yj∗)
, is a boundary point. Since all the terms in−
hwh(
xi∗,
yj∗)
are non-negative and wh(
xi∗−1,
yj∗) =
0,wehavewh
(
xi∗,
yj∗)
hhi∗−12,j∗
≤ −
hwh(
xi∗,
yj∗) =
1,
or wh(
xi∗,
yj∗) ≤
hhi∗−12,j∗≤
h2,
whichprovesthelemma.
2
Lemma2.5.Letvhbethesolutionof−
hvh=
1 inΩ
h◦0 in
Ω
h∗ and vh=
0 onΓ
h.
Then0
≤
vh≤
CvinΩ
hforsufficientlysmallh,whereCvisindependentofh.Proof. Since
−
hvh≥
0 inΩ
h andvh=
0 onΓ
h,themaximumprincipleimpliesthat vh≥
0 inΩ
h.Considerananalytic solution v: Ω → R
satisfying−
v=
2 inΩ
andv=
0 onΓ
.Lemma 2.2impliesthatforsufficientlysmallh,wehave−
h(
v−
vh) =
−
hv−
1≥
0,
inΩ
h◦−
hv≥ −
C,
inΩ
h∗,
withsomeconstant
C>
0.Usingthediscretefunction wh giveninLemma 2.4,wehaveaninequality−
h(
v−
vh+
C wh) ≥
0 inΩ
h.
Sincev
−
vh+
C wh=
0 onΓ
h,wehavev−
vh+
C wh≥
0.ThisinequalityandLemma 2.4implythat0
≤
vh≤
v+
Ch2.
TakingCv
=
max|
v| +
C givestheestimate0≤
vh≤
Cv forsomeconstantC independentofh.2
Theorem2.6.Letu beacontinuoussolutiontotheproblem(1)anduhadiscretesolutiontotheproblem(2).Thenwehave
|
u−
uh| =
O h2in
Ω
h.
Proof. UsingLemmas 2.4 and2.5,theconsistencylemmareads
|
hu−
u| ≤
C1h2(−
hvh) + (
C2+
C3h)(−
hwh).
Ontheotherhand,since
u
=
huh=
f inΩ
h,wehave−
h C1h2vh+ (
C2+
C3h)
wh− (
u−
uh)
≥
0−
h C1h2vh+ (
C2+
C3h)
wh+ (
u−
uh)
≥
0.
Sincevh
=
wh=
u−
uh=
0 onΓ
h,themaximumprincipleimpliesthat|
u−
uh| ≤
C1h2vh+ (
C2+
C3h)
wh≤
C1Cvh2+ (
C2+
C3h)
h2=
h2(
C1Cv+
C2+
C3h),
whichshowstheconvergenceestimate
|
u−
uh| =
O(
h2)
inΩ
h.2
3. ConditionnumberofthepreconditionedmatricesInthissection, weconsider theapplicationofbasicpreconditioningtechniques tothelinear systemthat isassociated withtheGibouetal.method.Beforeweproceedtothediscussionofthepreconditioners,weprovidetheestimationofthe conditionnumberofthelinearsystemassociatedwiththeGibouetal.method.
We mayassume that the domain
Ω
is a subset of{(
x,
y) R
2:
0≤
x≤
a,
0≤
y≤
b}
.LetΩ
h:= {(
ih,
jh) ∈ Ω :
1≤
i≤
N,
1≤
j≤
M}
withthelexicographicalorderonΩ
h [3].LetK:= |Ω
h|
andxk:= (
ikh,
jkh) ∈ Ω
h fork=
1, . . . ,
K according totheorder.Throughoutthissection,let A betheK×
K matrixcorrespondingtothediscretePoissonequation(2),which issymmetricandpositivedefinite.Theentryar,sof A withxr= (
irh,
jrh)
andxs= (
ish,
jsh)
aregivenasar,s
=
⎧ ⎪
⎪ ⎪
⎪ ⎪
⎨
⎪ ⎪
⎪ ⎪
⎪ ⎩
−
h12 if is=
ir±
1 and jr=
js1 h
(
h 1ir+12,jr
+
h 1ir−12,jr
+
h 1ir,jr+12
+
h 1ir,jr−12
)
if s=
r−
h12 if is=
irand js=
jr±
10 otherwise
(5)
wherehi
r±12,jr andhi
r,jr±12 aregivenas hi
r+12,jr
=
h,
if ir+1=
ir+
1|
irh−
xΓ|,
if∃
xΓ= (
xΓ,
yΓ) ∈ Γ
such that irh<
xΓ< (
ir+
1)
h (6) andtheothersaregiveninthesamefashion.Theorem3.1.Let
λ
beaneigenvalueofA,then0<
C≤ λ ≤
h·h8min forsomeC>
0 independentofh andhmin=
min(ih,jh)∈Ωh{
hi±12,j
,
hi,j±12
}
.Proof. Let
λ
beaneigenvalueof A.Thenλ
isapositiverealnumberbecause A issymmetricpositivedefinite.Inorderto findanupperboundofλ
,weapplytheGerschgorinCircleTheorem.Since A isdiagonallydominant,theGerschgorinCircle Theoremimpliesthatλ ≤
ak,k+
j=k
|
ak,j| ≤
2ak,kforsomek
=
1, . . . ,
K .From (5),we obtainthatak,k≤
h·h4min forallk=
1, . . . ,
K ,whichgivesanupperbound h·h8min for
λ
. Ontheotherhand,applyingthePerron–FrobeniusTheoremtotheM-matrix A−1 showsthatthesmallesteigenvalueλ
min of A issimpleandhasapositiveeigenvectoru∈ R
K.Wemayassumemaxi=1,...,Kui=
1.Regardingu asadiscretefunction definedonΩ
h∪ Γ
h withu=
0 onΓ
h,wecanseethatwiththehelpofwh andvn giveninLemmas 2.4 and2.5,wehave−
hu= λ
minu≤ λ
min−
h(
vh+
wh)
inΩ
h.
Andthemaximumprincipleimpliestheinequalityu
≤ λ
min(
vh+
wh)
inΩ
h.ApplyingLemmas 2.4 and2.5,wefinallyobtain 1=
maxΩh
u
≤ λ
minmax Ωh(
vh+
wh) ≤ λ
min Cv+
h2.
Since we may assume h
<
1, we conclude thatλ
min≥
C>
0 for a constant C independent of h, which completes the proof.2
Wehaveshownthattheconditionnumberofthematrix A stemmedfromthelinearsystem(2)isboundedby O
(
1/(
h·
hmin))
.Table 1suggeststhattheboundistight.Sothesmallerhminbecomes,theworsetheconditionnumberof A grows.Indeed,thefollowingtheoremprovesthatthelowerandupperboundsaretight.
Theorem3.2.Let
λ
minandλ
maxbethesmallestandlargesteigenvaluesof A inmagnitude,respectively.Thenλ
min<
D forsome D>
0 independentofh andλ
max>
h·h1min.Thereforewehave
κ (
A) =
O(
h·h1min
)
. Proof. Atfirst,weshallshowthatλ
max>
h·h1max.Let P
= (
xi,
yj)
be thegridnode nearesttotheboundarysothathmin=
min{
hi±12,j
,
hi,j±12
}
.ThentakeavectoreP∈ R
|Ωh|ofwhichtheelementcorrespondingto P isoneandtheotherelements areallzero.TakingaRaleighquotient,wehaveλ
max=
max0=v∈R|Ωh|
A v,
vv
,
v≥
AeP,
ePeP
,
eP=
1h
1hi−1 2,j
+
1hi+1 2,j
+
1hi,j−1 2
+
1hi,j+1 2
>
1 h·
hmin.
In ordertoshow theestimate for
λ
min,wechoose arectangle R⊂ Ω
whoseboundary isalignedwiththe gridlines.Let Rh=
R∩ Ω
h.Anyvector v∈ R
|Rh| canbe extendedto v˜ ∈ R
|Ωh| bytakingzerovaluesoutsideRh.Let B betheassociated matrixofthefive-pointfinitedifferencemethod.Then Av˜ |
Rh=
B v and Av˜ |
Ωh\Rh=
0,whichimpliesAv˜ ,
v˜ =
B v,
vand
λ
min=
min0=u∈R|Ωh|
Au,
uu
,
u≤
min0=v∈R|Rh|
Av˜ ,
v˜
˜
v,
v˜ =
min0=v∈R|Rh|
B v,
vv
,
v.
In [5],
λ
min(
B) =
min0=v∈R|Rh|B v,vv,v isexactlygivenas4
(
sin2(πah)
h2
+
sin2h(2πbh))
whichislessthanπ
2(
a12+
b12)
,wherea×
b is thedimensionofthe rectangle.CombiningtheresultsofTheorem 3.1,wehaveκ (
A) =
O(
h·h1min
)
,whichcompletes the proof.2
3.1. Jacobipreconditioning
Wedecompose A as A
=
L+
D+
Uwhere L
,
D,andU=
LT arethediagonal,thestrictlowertriangular,andtheuppertriangularpartsof A,respectively.The JacobipreconditioneristhediagonalmatrixD whosediagonalentriesarethesameasA.TheJacobipreconditioningonthe linearsystemresultsin D−1Au=
D−1b.Thepreconditioningis,inotherwords,toscaleeachequationsothatits diagonal entrybecomesone.ApplyingtheJacobipreconditioningtoitslinearequation,theGibouetal.methodnowreadsui j
−
1 hi+1 2,j 1
hi+1 2,j
+
h 1i−12,j
+
h 1i,j+12
+
h 1i,j−12
ui+1,j
−
1 hi−12,j 1
hi+12,j
+
h 1i−12,j
+
h 1i,j+12
+
h 1i,j−12
ui−1,j
−
1 hi,j+12 1
hi+12,j
+
h 1i−12,j
+
h 1i,j+12
+
h 1i,j−12
ui,j+1
−
1 hi,j−12 1
hi+12,j
+
h 1i−12,j
+
h 1i,j+12
+
h 1i,j−12
ui,j−1
=
1 hfi,jhi+12,j
+
h 1i−12,j
+
h 1i,j+12
+
h 1i,j−12
.
(7)ItcanbeobservedfromEq.(7)thattheeigenvalueestimationfortheJacobi-preconditionedmatrixisalmostindependent ofhmin
=
min(ih,jh)∈Ωh{
hi±12,j
,
hi,j±12
}
,whilethatfortheoriginalmatrixisdependent.Thus,thepresenceofgridnodestooneartheboundary isnot problematic intheJacobi-preconditionedmatrix.Precisely, leta gridnode
(
xi,
yj)
bevery near theboundarytotheleft.Asitgetsnearerandnearer,hi−12,j
→
0 andthediscretizationbecomes ui j−
0·
ui+1,j−
1·
g(
xi−1,
yj) −
0·
ui,j−1−
0·
ui,j+1=
0·
fi j,
or ui j=
g(
xi−1,
yj).
Sothe equationmakes a diagonalblock splitfromthematrixandthe eigenvalueofthediagonalblock isone. Hence, thepresenceofgridnodesveryneartheboundaryactuallymakesratherabenigneffectonJacobi-preconditionedmatrix, contrarytoitsbadeffectontheoriginalmatrix.Now,weprovetheobservationasfollows.
Theorem3.3.Foranyeigenvalue
λ
oftheJacobi-preconditionedmatrix,wehave 0<
h2
4Cv
+
h4h3min
≤ λ ≤
2.
(8)Furthermore,ifhmin
≥
h3,thenwehave0<
Ch2≤ λ ≤
2 forsomeconstantC=
C(Ω)
.Proof. Let
λ
bean eigenvalueof D−1A andu∈ C
K itscorresponding eigenvector.SinceallthediagonalelementsofD are positive,let D12 denotethe square rootmatrixof D. Thenwe can seethat D−1Au= λ
u ifandonly if D−12A D−12D12u= λ
D12u.Thus,thepositivedefinitenessofD−12A D−12 verifiesthatλ >
0 andu∈ R
K.SinceD−1A isdiagonallydominantand Kj=1
|
a−ii1ai j| ≤
2,theGerschgorinCircleTheoremimpliesλ ≤
2.Ontheotherhand,wemayassumethatmaxi=1,...,Kui
=
1.From(5),wehave Au= λ
Du≤
λ
4h2
,
inΩ
h◦λ
hh4min
,
inΩ
h∗ (9)Regardingu asadiscretefunctionon
Ω
hwithu=
0 onΓ
h,wehave−
hu=
Au inΩ
h,andusingwhandvhinLemmas 2.4 and2.5,weobtain−
hu≤ λ
4h2
(−
hvh) + λ
4hhmin
(−
hwh)
inΩ
h= −
hλ
4h2vh
+ λ
4 hhminwh inΩ
h.
ApplyingthemaximumprincipleinLemma 2.3tothisinequalityaboveandusingLemmas 2.4 and2.5,weinducethat u
≤ λ
4h2vh
+ λ
4hhminwh
≤ λ
h24Cv
+
4h3 hmin.
Consequently,we obtainu
≤ λ
h−2(
4Cv+
h4hmin3)
inΩ
h sothat 1≤ λ
h−2(
4Cv+
h4hmin3)
becausemaxi=1,...,Kui=
1.Combiningλ ≤
2,weobtainthebounds(8)forλ
.Ifhmin≥
h3,furthermore,then C−1:=
4Cv+
h4hmin3≤
4Cv+
4.Inthiscase,λ ≥
Ch2, whichcompletestheproof.2
Remark3.4.In[15],weshowedthatmostdomains withsmooth boundaryaswellasrectangulardomains satisfyhmin
=
O(
h3)
.ThedomainΩ
iscalledtohavethegeneralintersectionpropertyifthecumulativedistributionfunction p( ν )
defined byp
( ν ) := (
xi,
yj) ∈ Ω
h:
dist(
xi,
yj), Γ
h≤ ν
(10)isalmost linear,i.e., p
( ν ) =
O(
h−2ν )
.Mostdomains havethegeneralintersection property(see Table 1 forexampleand [15]fordetails).Notethatwhenthecumulativedistributionfunctionp( ν )
isalmostlinear,thenforα >
2,p(
hα) =
O(
hα−2)
anditmeanshmin≥
hα forsufficientlysmallh.Corollary3.5.Ifhmin
≥
h3,theconditionnumberoftheJacobipreconditionedmatrixisboundedbyO(
h−2)
.TheJacobicaseonTable 2showsthattheboundistight.WeobservethattheJacobi-preconditioningdiscretization(7) is preferredthan the original discretization(2) intwo senses.Its associated matrixhas much smallercondition number
(
O(
h−2))
thanthatoftheoriginalone(
O(
h·h1min