A Comparison of Two Matrix Operator Formulations for Mimetic Divergence and Gradient Discretizations Jose E. Castillo
Abstract
Mark Yasuda
Computational Science Research Center
Raytheon Company
San Diego State University
8680 Balboa Avenue
San Diego, CA 92182-1245
San Diego, CA 92123
[email protected]
[email protected]
Recent investigations by Castillo
and Grone have led to a new method for constructing mimetic discretizations of the divergence and gradient operators. Their technique, which employs a matrix formulation to incorporate mimetic constraints, is capable or producing approximations whose order at an interval's boundary is comparable to that seen along the interval's interior.
to produce results with a meaningful physical interpretation. Standard examples of conservation identities satis ed by discrete versions of such dierential operators as the gradient, divergence, and curl include special cases of the general Stokes Theorem Z Z (1) d! = !; M
This improvement over other methods was achieved, in part, by the introduction of a particular weighted inner product in the matrix formulation. In this paper, we compare two second-order mimetic discretizations { one using the Support Operators method and one using Castillo and Grone's weighted inner product { applied to a one dimensional
@M
where M is a compact oriented n-manifold with boundary @M , ! is a (n 1)-form on M , and d! is its exterior derivative. Application of (1) to submanifolds of R2 and R3 , for example, yield the classical Stokes theorem as well as the divergence theorem and Green's theorem.
elliptic boundary value problem on a uniform staggered grid.
Our results provide
support for the use of a weighted inner product in mimetic discretizations.
Keywords: 1
mimetic, gradient, divergence
Introduction
Mimetic discretizations of dierential operators are constructed to satisfy discrete analogs of physically important conservation identities. In this way, mimetic discretizations replicate much of the desired behavior found in their continuous counterparts. As a result, models of boundary value problems that are built using mimetic operators can often be expected
2
Preliminaries
Consider the uniform staggered grid Figure (1) with h = 1=n, nodes at xi = i h, 0 i n, and cells [xi ; xi+1 ] with centers xi+ 12 = 12 (xi + xi+1 ). Let f and v denote two real-valued scalar functions de ned on some closed subinterval of the real line. We de ne the vectors c
f
(
f (x 1
2
); f (x 3 ); : : : f (xn 1 )) 2
2
T
(the subscript c signifying that f 's components are evaluated at the cell centers) and cb
f
(
f (x0 ); f (x 1
2
T
); f (x 3 ); : : : f (xn 1 ); f (xn )) 2
2
(the subscript cb signifying that f 's components are evaluated at the cell centers and
Gf fv
Dv f
Gf v
Dv f
Gf v
Dv f
0
1/2
1
3/2
2
5/2
Figure 1: The Grid
Z 0
1
dv f dx + dx
Z
1
0
v
0
(5)
boundary). D will denote a dierence approximation for the divergence operator acting on functions evaluated at the nodes, and G will denote a dierence approximation for the gradient operator acting on the fcb-values. The domain of these operators are illustrated in Figure 1 above. If ! = v(t)f (t) on the interval M = [0; 1], then equation (1) is just a manifestation of the Fundamental Theorem of Calculus
(2)
then we nd that B 2 Rn+2n+1 set to
df dx = v (1) f (1) dx
v (0) f (0) :
Let x and y be two n-vectors, and let A 2 Rnn be positive de nite. Notationally, we de ne the weighted inner product hx; yiA =: yT Ax. In [1], Castillo and Grone express the
B B B B B B B @
1
0
0 0 .. . . . . .. . 0
... ...
0 .. . . . . .. .
0 0
...
1
C C C C C C C 0A 1
combined with equation (3) yields the same operators D and G as those produced by the Support Operators method [4]. By employing dierent matrices P and Q, however, Castillo and Grone were able to generate higher order approximations at the boundary than the Support Operators method for the gradient and divergence discretizations on a uniform staggered grid. In the second-order case, which we illustrate below, the only one of the operators D and G that diers between the Support Operators method and Castillo and Grone's technique is the discretized gradient. Castillo and Grone's second-order gradient approximation can easily be shown to be second-order accurate at the boundary as well as the interior.
discretized version of (2) for a uniform staggered grid as (3)
hD^ v; fciQ + hGT v; fcbiP = hBv; fcbi
where the matrices P and Q are positive def^ is the matrix D inite matrices, and where D augmented with two rows of zeros (at the top and bottom). If we set Q 2 R( n+2)(n+2) equal to the identity matrix and let P 2 Rn+1n+1 equal
3
The Model Problem
x e 1 Let F (x) = ee 1 , = e , = ( ) , and = 1. In the following sections, we illustrate certain aspects of the second-order mimetic method (on both the boundary and interior) by applying it to the elliptic partial dierential equation
r f (x) = F (x) 2
0
(4)
B B B B B B B @
1=2
0
0 1 .. . . . . .. . 0
... ... ...
0 .. . .. .
1
C C C C; ... C C C 1 0A 0 1=2
on [0; 1]
subject to Robin boundary conditions
f (0) f 0(0) = 1 f (1) + f 0 (1) = 0
4
value problem, expressed compactly as the linear system of equations
The Mimetic Operators
Let the matrix P 2 Rn+1n+1 equal 0 1 3=8 0 0 B .. C B 0 9=8 . . . . C B C B .. C . . . . . . B . . 1 . . C B C B .. C . . . . . . . . B . . . . . C B C B .. .. C ... ... B . 1 . C B C B .. C ... @ . 9=8 0 A 0 0 3=8 and let Q 2 Rn+2n+2 be the identity matrix. Then equation (3) is satis ed by the secondorder divergence operator hD 2 Rnn+1 equal to 0 1 1 1 0 0 B .. C . B 0 1 1 .. .C B C B .. . . . . . . . . .. C ; B . . . . . .C B C B .. C ... @ . 1 1 0A 0 0 1 1 the second-order gradient operator hG Rn+1n+2 equal to 0 1 8=3 3 1=3 0 0 B .. C B 0 1 1 0 .C B C B .. C ... ... ... ... ; B 0 .C B C B C .. . . @ . . 0 1 1 0A 0 0 1=3 3 8=3
2
and the matrix B~ 2 R( n+2)(n+1) equal to (6)
0 B B B B B B B B B B B B B B B B @
1
0
0
1=8
1=8
0
0 . . .
0 . . .
0 . . .
1=8
1=8
0
0
0
0
0
0
0
0
0
0
0
0
0
.. ..
. .
0 0
0
0
0 0 . . . 0
..
.
0 . . .
..
.
0
0
0
1=8
0
1=8
0
0
~ + L)f = b (A + BG
(7)
1 0 C C 0 C C C C 0 C . C . C . C: C C 0 C C 1=8 C C 1=8 A 0
1
This produces a second-order mimetic method that we use to solve the boundary
where A 2 Rn+2n+2 equals 0 1 0 B . B 0 0 .. B B .. . . . . . . B . . . . B B .. . .. @ . 0 0 0
0 .. . .. .
1
C C C C; C C C 0A 1
the discrete Laplacian is given by 0 1 0 0 L = @ DG A 2 R( n+2)(n+2) 1 ; 0 0 and
b=
1; F (x 1 ); F (x 3 ); : : : ; F (xn 2
2
1 2
); 0
T
:
The solution vector f is the method's approximation to the vector fcb . We are also interested in solving the related linear system (A + BG + L)f~ = b
(8)
in which the matrix B~ in equation (6) is replaced with the simpler matrix B in equation (5). One of our goals will be to quantify the disruption to the approximation of fcb caused by this violation the mimetic constraint (3). Let M = A+ BG+L and E = (B~ B )G. Then we can rewrite the system (8) as
M f~ = b
(9) and system (7) as
(M + E )f = b:
(10) 1
Although
D and G are second-order at all points in
their domain, a straightforward calculation shows this not true of
L.
5
Numerical Results for the Model Problem
In the table below, column (1) corresponds to the second-order Support Operators Method, and columns (2) and (3) correspond to the linear systems of equations (9) and (10) respectively. We obtained the following numerical results, where the table entries are the average component-wise absolute deviations of the Model Problem's solution vector and the true solution: h (1) (2) (3) 0.20 0.0053750 0.0013814 0.0010364 . 0.10 0.0014693 0.0003246 0.0002596 0.05 0.0003870 0.0000774 0.0000675 This implies that the weighted inner product solution f is more accurate than that of the support operators. Both Castillo and Grone's mimetic method and the non-mimetic modi cation given by (9) yield second-order accurate solutions. We note that convergence has been proven for the Support Operator methods using techniques that also apply to the other schemes discussed in this paper [3]. 6
Perturbation Analysis
By combining equations (9) and (10), we can relate the estimates f~ and f by the standard matrix perturbation error bound
f~ f
(11) 6 M 1 E ;
kf k
where we have assumed the use of a subordinate (induced) matrix norm. The evaluation of this bound requires a somewhat involved and careful analysis, but is facilitated by the matrix formulation of the operators involved. In [2], we show that the relative dierence between the papproximations ~ f and f ) is no worse than O h when measured in the spectral norm. In addition to bounding the relative dierence between the solutions to (9) and (10), is
possible to write down the precise relationship concerning the discretization errors inherent in these two linear systems. Let e = f fcb and e~ = f~ fcb. Rewriting (9) and (10) in terms of e and e~, and performing some simple manipulation results in the revealing expression
e~ = (I + M 1 E )e + M 1 Efcb :
(12)
Given our analysis of M 1 E above, this alternative expression (like (11) ) shows that e converges to zero as n increases if and only if e~ also does. Unlike (11), however, equation (12) reveals the full role that M 1 E plays in the numerical discrepancy between the two approaches in this study, and expresses e~ as an in ated perturbation of e. Last, we note the presence of the matrixvector product Efcb in (12). A short investigation of this product shows that Efcb
=
h 8
0;
L 21 ; L 12 ; 0; : : : 0; L n
2
1;
Ln
2
1;0
T
where L 1 = f 00 (x 1 ) + h6 f 000 (x 1 ) + O(h2 ) and 2 2 2 L n 2 1 = f 00 (x n 2 1 )+ h6 f 000 (x n 2 1 )+ O(h2 ) are linearly convergent approximations to the Laplacian at the outermost cell centers on the interval [0; 1]. 7
Numerical Perturbation Results
Numerically, it was determined that
1
M E n 2 16 0.07767104365797 64 0.03918532794468 . 256 0.01959918609644 1024 0.00979951662454 p This is consistent with the O h behavior predicted in the previous section. References
[1]
A Matrix Analysis to Higher-Order Approximations for Divergence and Gradients Satsifying a J.E. Castillo and R. Grone,
Global Conservation Law, SIAM J. Matrix Anal. Appl., In Press
[2]
Linear Systems arising for Mimetic Divergence and Gradients Discretizations, In Prepara-
J.E. Castillo and Mark Yasuda,
tion.
[3]
James M. Hyman and Stanly Stein-
Convergence of Mimetic Discretization for Rough Grids, Submitted for publiberg,
cation. www.math.unm.edu/ stanly [4]
Shashkov, Conservative FiniteDierence Methods on General Grids,
M.
CRC Press 1995.