Optimal Finite-Difference Grids for Elliptic Problem
In many applications one observes rapid change of the solution in the boundary region. Accurate and numerically efficient resolution of the solution close to the moving boundaries is considered to be and important problem. We develop an approach to grid optimization for finite-difference scheme for elliptic problem. Using this approach we are able to achieve exponential convergence of the boundary Neumann-to-Dirichlet map when applied to the bounded domains. It increases the convergence order without increasing the stencil size of the finite-difference scheme and without losing stability.
5. Motivation answer
How about exponential
super-convergence and
spectrally accurate grids?!
6. Outline
✤ Model Problem
✤ Discretization techniques
✤ Optimal discretization grids
✤ Numerical results
7. What are we solving?
1 Model problem
Laplace equation on a semi-infinite strip
Consider the following boundary value problem: Laplace equation on a semi-
nfinite strip with the given Neumann data on the left boundary and Dirichlet
data elsewhere
∂ 2 w(x, y) ∂ 2 w(x, y)
− 2
− 2
= 0, (x, y) ∈ [0, ∞) × [0, 1], (1)
∂y ∂x
∂w
(0, y) = −ϕ(y), y ∈ [0, 1], (2)
∂x
w|x=∞ = 0, (3)
w(x, 0) = 0, w(x, 1) = 0, x ∈ [0, ∞). (4)
Assume
m
ϕ(y) = ai sin(iπy) (5)
i=1
8. The∂w (0, y) = −ϕ(y), ybe [0, 1], as a problem
is defined on span{sin (πy), . . . , sin (mπy)}, spA =
above problem can ∈ studied
e can obtain Dirichlet data on the left boundary using
2 w(x)
∂x w|x=∞ = 0, (2) (3)
t map. Equation (6) gives Aw(x) = d dx2 , therefore
w(x, 0) = 0,
nd now we can use given in (7) Neumann data to get at 2
w(x, 1) = 0, =d0,w(x) ∞). (3)
w|x=∞ x ∈ [0, (4)
Aw(x) − = 0, x ∈ [0, ∞)
Model Problem
w(0) = f (A)ϕ, w(x, 0) = 0, w(x, 1) = 0, x ∈ [0, ∞).
dx 2 (4)
Assume
mpedance function.
dw
m (x = 0) = −ϕ
Assume dx
ϕ(y) =
m ai sin(iπy) (5)
ϕ(y) = ai sin(iπy)
i=1 (5) x=∞ = 0,
w|
i=1
The above problem can bewhere Aas = problem is defined on span{sin (πy), . . . , s
studied a − ∂ 22
The above problem can be studied as a problem ∂y
{π 2d2 w(x) 2 }. We can obtain Dirichlet data on the
, . . . , (mπ)
2 w(x)
d −
Aw(x)Neumann-to-Dirichlet ∈ [0, ∞)Equation (6) gives Aw(x)
Aw(x) − = 0, = x ∈ [0, ∞)map.
2
0, x (6) (6)
dx2 dx
dw(x) 1
− dx dw A 2 dw and now we can use given in (7) Neum
= w(x)
x = 0 dx (x = 0) = −ϕ
(x = 0) = −ϕ (7) (7)
2
dx
w|x=∞ = 0, w(0) = f (A)ϕ,
w|x=∞ = 0, (8) (8)
1
∂2 −2
where A A = − ∂ 2 defined on (λ) onλ span{sin.(πy), . . . , sin (mπy)}, spA =
where = − is here f span{sin (πy), . . , sin (mπy)}, spA =
= is impedance function.
isNeumann-to-Dirichlet Map
∂y 2defined
∂y 2
{π 2 , .2 . , (mπ)2 }. 2 We can obtain Dirichlet data on the left boundary using
.
{π , . . . , (mπ) }. We can obtain Dirichlet data on d2 w(x)left boundary using
the
Neumann-to-Dirichlet map. Equation (6) gives Aw(x) = dx2 , therefore d2 w(x)
Neumann-to-Dirichlet map. Equation
dw(x) 1 (6) gives Aw(x) = dx2
, therefore
− dx = A 2 w(x) and now we can use given
dw(x) 1 in (7) Neumann data to get at
−
x = 0 dx = A 2 w(x) and now we can use given in (7) Neumann data to get at
x=0 w(0) = f (A)ϕ,
1
−2 w(0) = f (A)ϕ,
here f (λ) = λ is impedance function.
1
−2
here f (λ) = λ is impedance function.
9. Idea
✦ Continuum NtD maps are Stieltjes-Markov functions of A
✦ Finite Difference NtD maps are rational functions of A
✦ Grids can be computed by minimizing the rational
approximation error of NtD maps on the spectrum of A
10. Method outline
๏ Write down the Finite Difference Scheme
๏ Find the Neumann-to-Dirichlet map as f(A)
๏ Find the Rational Approximation of f(A) on the spectrum of A,
obtain the grid steps
๏ Solve the discrete system
11. 2.1 Explicit scheme xi . Denote hi = xi+1 − xi , hi = xi − xi−1 Then after
tives be defined at nodes ˆ ˆ ˆ
discretization in x we have the following semi-discrete problem
Let the finite difference solution be defined at nodes xi , the finite difference deriva-
1 wi+1 x . wi − w =
tives be defined at nodes −iwiDenote hi i−1 xi+1 0, xi , i == x. .−kxi−1 Then after
ˆ
Approximate NtD Map
Awi − ˆ − = − hi 2, ˆi , ˆ ,
. x (9)
ˆ hi hi−1
discretization in hi we have the following semi-discrete problem
x
1 w2 − w1 1
Aw −
1 wi+1 −1wi ˆ wi − wi−1 = ˆ ϕ, wk+1 = 0, (10)
Awi − −1
h h1 = 0, 1
h i = 2, . . . , kx , (9)
ˆ
hi hi hi−1
where wi = w(xi , y). 1 w2 − w1 1
Neumann-to-Dirichlet Map w
Aw −
The crucial fact is that we1 canˆobtain hNeumann-to-Dirichlet k+1 = 0,
= ϕ, map (10)
h1 1 ˆ
h1
m
where wi = w(xi , y).1 (y) = fk (A)ϕ(y) =
w ai fk (i2 π 2 ) sin(iπy), (11)
The crucial fact is that we can obtain Neumann-to-Dirichlet map
i=1
m
where approximate impedance function fk (λ) can 2 2written as a continued frac-
be
tion w1 (y) = fk (A)ϕ(y) = ai fk (i π ) sin(iπy), (11)
Approximate Impedance function can be written as a
i=1 1
fk (λ) = (12)
hcontinued fraction
ˆ 1λ + 1
where approximate impedance function fkλ+···+can be written as a continued frac-
h1 + ˆ (λ)
h2
1
1
hk−1 + 1
tion ˆ λ+ 1
hk
hk
1
fk (λ) = (12)
The L2 error of the semidiscreteλsolution at x = 0 can be estimated by
ˆ
h1 + h + 1
1
1 ˆ 1
h2 λ+···+ 1 1
hk−1 + −2
ek = ||w(0, y) − w1 (y)||L2 [0,1] ≤ ||ϕ|| maxhk λ+ 1
ˆ
h |fk (λ) − λ |. (13)
λ∈[π 2 ,(mπ)2 ] k
The L2 error of the semidiscrete solution at x = 0 can be estimated by
Thus the problem of grid optimization with respect to the Neumann-to-Dirichlet
12. ˆ
hi h
fk (λ)i = hi−1 (12)
ˆ 1λ +
h 1
1
h1 + ˆ− w
1 w2 h2 λ+···+ 1 1
1
1 h
Aw1 − k−1 + ˆ ϕ,1
= hk λ+ wk+1 = 0, (10)
ˆ
h1 h1 ˆ
h 1 hk
Approximation error
The L2 error of the semidiscrete solution at x = 0 can be estimated by
where w = w(x , y).
i i
1
−2
The crucial kfact is that− w1can L2 [0,1] ≤ Neumann-to-Dirichlet λ
e = ||w(0, y) we (y)|| obtain ||ϕ|| max |fk (λ) − map
|. (13)
2 2
λ∈[π ,(mπ) ]
m
Thus the problemw (y) = f (A)ϕ(y) = respect(i2 π 2 ) sin(iπy),
of grid optimization with a f to the Neumann-to-Dirichlet (11)
1 k i k
map error can be reduced to the uniformi=1 rational approximation of the inverse
Impedance function rational approximation error
square root.
wherelarge m the optimal approximation onfa (λ) can be written as λmax ] yields frac-
For approximate impedance function k spectral interval [λmin , a continued
tion
1
−2
1 π2k
maxk (λ) = − λ | = O exp 1
f |fk (λ) , (14) (12)
λ∈[π 2 ,(mπ)2 ] ˆ
h1 λ + h + 1
λmin
log λmax
ˆ 1 1
h2 λ+···+ 1
hk−1 +
Now if we perform standard finite difference discretization in y, our problem
hk λ+ 1
ˆ
hk
becomes
2 Boundary condition approximation error
The L error of the semidiscrete solution at x = 0 can be estimated by
j−1 j j+1 1
− 2wi + wi
wi ||w(0, y) − w1 (y)||1 2 [0,1]i+1 − wi wmax i−1 |fk (λ) −2
ek =
− − L w ≤ ||ϕ|| − i2− w 2 −λ |. (13)
2 ˆi λ∈[π ,(mπ) ] = 0, (15)
hy h hi hi−1
Thus the problem of grid optimization with respect jto the .Neumann-to-Dirichlet
i = 2, . . . , kx , = 2, . . , ky
j−1 j j+1 j j
map error can be reduced to the wi
wi − 2wi + uniform rationalwapproximation of the inverse
1 w2 − 1 1 j
− − = ϕ , (16)
square root. hy2 ˆ
h1 h1 ˆ
h1
13. Grids with Geometric Sequences
of Steps
For large condition number, the optimal
grids are close to geometric progressions
Grid for Nx = 10, Ny = 10
1
√ 0.9
α = eπ/ k
0.8
√
− kπ
h1 = e 0.7
√ 0.6
i−1 π(i−k−1)/ k
hi = h1 α =e
√ 0.5
ˆ
h1 = h1 /(1 + α) 0.4
ˆ i = h1 αi−1 =
ˆ hi 0.3
h √
1+ α 0.2
0.1
0
0 0.1 0.2 0.3 0.4 0.5 0.6 0.7
1
√
1+o(1)
max
√ |fk (λ) − λ− 2 | ≤ h1 = e[−π+o(1)] k
, h1 → +0
λ∈[e 2π ,∞]
14. 1
fk (λ) = (12)
ˆ
h1 λ + 1
1
h1 + ˆ 1
h2 λ+···+ 1
hk−1 +
ˆ λ+ 1
hk
hk
Discretization method
2 L2Discretization techniques= 0 can be estimated by
The error of the semidiscrete solution at x
2.1 Explicit scheme
ek = ||w(0, y) − w1 (y)|| ≤ ||ϕ|| max |fk (λ) − λ
1
−2
|. (13)
L2 [0,1]
λ∈[π 2 ,(mπ)2 ]
Let the finite difference solution be defined at nodes xi , the finite difference deriva-
ˆ ˆ
Thus the problem of grid optimization withi respect to the Neumann-to-Dirichlet after
tives be defined at nodes xi . Denote h = xi+1 − xi , hi = xi − xi−1 Then
ˆ ˆ
discretization in x we have Discretization in x
map error can be reduced to the uniform rational approximation of the inverse
the following semi-discrete problem
square root.
For large m the optimalwi+1 − wi
1 w − a spectral interval [λmin , λmax ] yields
approximationi on wi−1
Awi − − = 0, i = 2, . . . , k, (9)
ˆ
hi hi hi−1
1 π2k
max |fk (λ) − λ− 2w2 − w1
1 | = O exp 1 λm in , (14)
λ∈[π 2 ,(mπ)2 Aw1 −
] = logϕ, ax wk+1 = 0, (10)
ˆ1
h h1 ˆ
h 1 λm
Now if we perform standard finite difference discretization in y, our problem
where w = w(xi , y).
becomes i Discretization in y
The crucial fact is that we can obtain Neumann-to-Dirichlet map
j−1 j j+1 m
wi − 2wi + wi= f (A)ϕ(y) =− wi a f i(i2 π 2i−1
w1 (y) 1 wi+1 w − w ) sin(iπy), (11)
− −
k − k
i = 0, (15)
2
hy ˆi
h hi i=1 hi−1
i = 2, . . . , kx , j = 2, . . . , ky
where approximate impedance function fk (λ) jcan be written as a continued frac-
j−1 j j+1 j
tion wi − 2wi + wi 1 w2 − w1 1 j
− − = ϕ , (16)
2
hy
fk (λ) = h 1 1 h1
ˆ ˆ
h1 (12)
ˆ 1
h1 λ + h + w1 = 0, 1i = 2, . . . , kx , (17)
1 ˆ i
h λ+···+ 1
15. ˆ j−1 ˆ j ˆ j+1 j
−h1 h1 w1 + 2h1 h1 + h2 w1 − h1 h1 w1 − h1 h2 ϕj = h2 w2 , j = 2, . . . , ky (22)
y y y
1
wi = 0, i = 2, . . . , kx , (23)
Numerical Scheme j
ky
wi = 0, i = 2, . . . , kx , (24)
w1 = w(yj ), j = 1, . . . , ky (25)
j
k
wkx +1 = 0, j = 1, . . . , ky (26)
wi y = 0, i = 2, . . . , kx , (18)
j
So, starting from w1 (y) we consequentially obtain),the solutionkon the lines parallel
w1 = w(yj j = 1, . . . , y (19)
to y axis w2 (y), w3 (y), . . . wkx (y). j
wk +1 = 0, j = 1, . . . , ky (20)
x
After regrouping terms in the first two discrete equations, we have
ˆ
hi h2 h i h2 j
ˆ j−1 ˆ 2 y j ˆ j+1 y j
−hi hi wi + 2hi hi + hy + w i − hi hi w i − wi−1 = h2 wi+1 , (21)
y
hi−1 hi−1
i = 2, . . . , kx , j = 2, . . . , ky
ˆ j−1 ˆ j ˆ j+1 j
−h1 h1 w1 + 2h1 h1 + h2 w1 − h1 h1 w1 − h1 h2 ϕj = h2 w2 , j = 2, . . . , ky (22)
y y y
1
wi = 0, i = 2, . . . , kx , (23)
k
wi y = 0, i = 2, . . . , kx , (24)
j
w1 = w(yj ), j = 1, . . . , ky (25)
j
wkx +1 = 0, j = 1, . . . , ky (26)
So, starting from w1 (y) we consequentially obtain the solution on the lines parallel
to y axis w2 (y), w3 (y), . . . wkx (y).
16. Numerical scheme not using the
NtD map
Sparse discrete system matrix
0
Numerical scheme with the
2.2 Implicit scheme 5
sparse block-banded matrix
The discrete system (15) above can also be solved using only the knowledge of 10
given Neumann data on the left boundary. I.e. we proceed not using Neumann-
to-Dirichlet map described above. 15
We rewrite the system in the form
20
ˆ
h h2 h h2
ˆ j−1
−hi hi wi + ˆ i + h2 + i y
2hi h j ˆ i wj+1 − i y wj − h2 wj = 0, (27)
w i − hi h i
y y i+1
hi−1 hi−1 i−1 25
i = 2, . . . , kx , j = 2, . . . , ky
30
ˆ j−1 ˆ j ˆ j+1 j
−h1 h1 w1 + 2h1 h1 + h2 w1 − h1 h1 w1 − h2 w2 = h1 h2 ϕj , j = 2, . . . , ky (28)
y y y
1 35
wi = 0, i = 2, . . . , kx , (29)
k
wi y = 0, i = 2, . . . , kx , (30) 40
j
w1 = w(yj ), j = 1, . . . , ky (31)
j 45
wkx +1 = 0, j = 1, . . . , ky (32)
(33) 0 10 20 30 40
nz = 212
We can see that the system matrix is sparse and block-banded.
Sparse discrete system matrix
0
17. Numerical Results
Analytic Solution
4 Numerical results
Boundary Condition 0.35
We apply our method for the problem (1) with Neumann b
0.3
Analytic Solution
0.25 −πx s
ϕ(y) = sin(πy). Then the analytic solution is w(x, y) = e
0.2
0.15
Analytic solution 0.1
) with Neumann boundary condition
0.05
n is w(x, y) = e−πx sin(πy). 0
1
Analytic Solution
0.8 1.5
0.6
1
0.4
0.2 0.5
0 0
0.35
18. Error for the solution on the
boundary
−11 Abs. error in approximation of Dir BC
x 10
1.4
1.2
1
0.8
0.6
0.4
0.2
0
0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1
19. Error for the solution on the
boundary
−11 Abs. error in approximation of Dir BC
x 10
1.4
1.2
1
0.8
0.6
0.4
0.2
0
0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1
20. Error for the solution on the
boundary
−11 Abs. error in approximation of Dir BC
x 10
1.4
1.2
...with only 14
discretization
1 points!
0.8
0.6
0.4
0.2
0
0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1
21. Errors for the standard methods
Method with matrix inversion Equally spaced
and optimal grid Finite Difference method
and the one obtained with the implicit method.
−4 Abs. error in approximation of Dir BC Abs. error for node x2
x 10
0.5 0.035
0
0.03
−0.5
0.025
−1
−1.5 0.02
−2
0.015
−2.5
0.01
−3
0.005
−3.5
−4 0
0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1
22. Error depending on the # of pts
Table 1: Max and l2 error in approximation of the solution on the boundary given
by Neumann-to-Dirichlet map
of steps Max error l2 error
4 4.435465319653220e-04 0.001507654161160
6 2.516176484440580e-05 5.419957700473768e-05
8 2.071832056138589e-06 4.462819749004914e-06
10 8.695114162016182e-08 1.872966830920883e-07
12 2.251853870038900e-09 4.850594880461687e-09
14 1.253025461167567e-11 2.699071837316973e-11
16 2.361721929133864e-12 5.087230550790546e-12
23. Conclusion
1
∃! p(λ) : p(λ) = min √ − q(λ)
max (41)
q∈Pk λ∈[λmin ,λmax ] λ
We used Wolfram Mathematica intrinsic function MiniMaxApproximation to
obtain p(λ). The next figure shows the approximation error
11
10
12
10
➡ Rational approximant of the NtD map can be obtained.
13
10
14
Exponential convergence at prescribed surfaces
10
15
10
➡ Technique can be generalized to a variety of PDE problems
10 100 1000 104
To obtain grid steps we rewrite obtained approximation of the impedance
function in the form of continued fraction (12). We proceed with Euclidean type
➡ Method can be used in a multidomain framework
algorithm with 2k polynomial divisions, i.e.
ck−1 λk−1 + ck−2 λk−2 + · · · + c0
p(λ) = (42)
dk λk + dk−1 λk−1 + · · · + d0
1
= d λk +d λk−1 +···+d
k k−1 0
ck−1 λk−1 +ck−2 λk−2 +···+c0
1
= dk ck−2
,
d c0
dk−1 − ck−1
λk−1 +···+ d1 − c k λ+d0
dk k−1
ck−1 λ + ck−1 λk−1 +ck−2 λk−2 +···+c0