Errors
Friedemann Kemm IAG Universit¨at Stuttgart kemm@iag.uni-stuttgart.de
Claus-Dieter Munz IAG Universit¨at Stuttgart munz@iag.uni-stuttgart.de
What I want to tell you about
• Correction in a simple example
? The problem
? Modelling errors
∗ Transport methods
∗ Generalised Lagrange multiplier methods
? The behaviour of the resulting error equations
What I want to tell you about
• Correction in a simple example
? The problem
? Modelling errors
∗ Transport methods
∗ Generalised Lagrange multiplier methods
? The behaviour of the resulting error equations
• What about Maxwell- and MHD-equations?
? Corrections in Maxwell equations
? How they come into MHD equations
? The Powell correction
Motivation
MHD equations:
ρt + ∇ · [ρ~v] = 0 , (ρ~v)t + ∇ ·
ρ~v ·~vT + (p + 1
2B2)I − B · BT
= 0 , Bt + ∇ ·
~v · BT − B ·~vT
= 0 , et + ∇ · h
(e + p + 1
2B2)~v − B(~v · B)i
= 0
Motivation
MHD equations:
ρt + ∇ · [ρ~v] = 0 , (ρ~v)t + ∇ ·
ρ~v ·~vT + (p + 1
2B2)I − B · BT
= 0 , Bt + ∇ ·
~v · BT − B ·~vT
= 0 , et + ∇ · h
(e + p + 1
2B2)~v − B(~v · B)i
= 0
with divergence constraint
∇ · B = 0 .
A simple test Problem
A simple conservation law:
Bt = 0
A simple test Problem
A simple conservation law:
Bt = 0 A simple divergence constraint:
∇ · B = 0
A simple test Problem
A simple conservation law:
Bt = 0 A simple divergence constraint:
∇ · B = 0 Writing error terms into the equations:
Bt + err1 = 0 err2 + ∇ · B = 0
A simple test Problem
A simple conservation law:
Bt = 0 A simple divergence constraint:
∇ · B = 0 Writing error terms into the equations:
Bt + err1 = 0 err2 + ∇ · B = 0 Resulting error equation:
err2t − ∇ · err1 = 0
Modelling errors
What a reasonable error model has to fulfill:
• Simple form of error equations .
Modelling errors
What a reasonable error model has to fulfill:
• Simple form of error equations .
• Only one new scalar variable. (Otherwise under-determined.)
Modelling errors
What a reasonable error model has to fulfill:
• Simple form of error equations .
• Only one new scalar variable. (Otherwise under-determined.)
• Diminishing of errors locally and in L1 norm.
Modelling errors
What a reasonable error model has to fulfill:
• Simple form of error equations .
• Only one new scalar variable. (Otherwise under-determined.)
• Diminishing of errors locally and in L1 norm.
• Easy implementation of the resulting correction.
Modelling errors(2)
Possible forms of the error equation:
• transport equation
• wave equation
• heat equation
• Poisson equation
• telegraph equation
Transport methods
Model:
err1 = −ψv˜ (˜v ∈ Rn) , err2 = ψ .
Error equation:
ψt + ∇ · (ψv) = 0˜
Implementation:
Bt = −(∇ · B)˜v
Characteristic solution of error equation
Quasi-linear form:
ψt + ˜v∇ψ = −(∇ · v)ψ˜
Characteristics:
˙
x(t) = ˜v(x(t), t)
Solution along characteristics:
ψ(x(t), t) = ψ0e−R0t∇·v(x(s),s)˜ ds
How to choose v ˜
• Should point to the outward on the boundary. (Diminish L1-norm.)
How to choose v ˜
• Should point to the outward on the boundary. (Diminish L1-norm.)
• Should have positive (at least nonnegative) Divergence. (Diminish locally.)
How to choose v ˜
• Should point to the outward on the boundary. (Diminish L1-norm.)
• Should have positive (at least nonnegative) Divergence. (Diminish locally.) Examples:
Star-region with respect to the origin:
˜
v(x) = v0 x
How to choose v ˜
• Should point to the outward on the boundary. (Diminish L1-norm.)
• Should have positive (at least nonnegative) Divergence. (Diminish locally.) Examples:
Star-region with respect to the origin:
˜
v(x) = v0 x
Higher dimensional analogue of an annulus ({x ∈ Rn : 0 < r < kxk2 < R}):
˜
v(x) =
v0 x
1 − kxr˜k2
if kxk2 ≥ r˜ v0kxxk
2
1
˜
rk − kx1kk 2
if kxk2 < r˜ (r < r < R, k˜ ≥ n − 1)
One dimensional example
For v˜ = v0x the solution for ψ is:
ψ(x, t) = ψ0(x · e−v0t)e−v0t Special cases:
ψ0(x) = x ⇒ ψ(x, t) = x · e−2v0t . ψ0(x) =
N
X
j=0
αjxj ⇒ ψ(x, t) =
N
X
j=0
αjxj e−(j+1)v0t .
ψ0(x) = 1
x ⇒ ψ(x, t) = 1
x .
Generalised Lagrange multiplier methods (GLM)
Model:
err1 = ∇ψ ,
err2 = g(ψ, ψt) . Error equation:
g(ψ, ψt)t − ∆ψ = 0 .
Generalised Lagrange multiplier methods (GLM)
Model:
err1 = ∇ψ ,
err2 = g(ψ, ψt) . Error equation:
g(ψ, ψt)t − ∆ψ = 0 . Evolution of the errors:
g(err1,err1t) − ∇(∇ · err1) = 0 , g(err2,err2t) − ∆ err2 = 0 .
Different forms of GLM-Correction
Hyperbolic correction: g(ψ, ψt) = 1
c2ψt → wave equation.
Different forms of GLM-Correction
Hyperbolic correction: g(ψ, ψt) = 1
c2ψt → wave equation.
Parabolic correction: g(ψ, ψt) = 1
κψ → heat equation.
Different forms of GLM-Correction
Hyperbolic correction: g(ψ, ψt) = 1
c2ψt → wave equation.
Parabolic correction: g(ψ, ψt) = 1
κψ → heat equation.
Elliptic correction: g(ψ, ψt) ≡ 0 → Poisson equation.
∇ψ as Lagrange multiplier.
Leads to projection method.
Different forms of GLM-Correction
Hyperbolic correction: g(ψ, ψt) = 1
c2ψt → wave equation.
Parabolic correction: g(ψ, ψt) = 1
κψ → heat equation.
Elliptic correction: g(ψ, ψt) ≡ 0 → Poisson equation.
∇ψ as Lagrange multiplier.
Leads to projection method.
Mixed type correction: g(ψ, ψt) = 1
c2ψt + 1
κψ → telegraph equation.
Properties of the different forms
Hyperbolic correction: Cheap in Computation. Conservation of errors (→ absor- bing boundary conditions).
Properties of the different forms
Hyperbolic correction: Cheap in Computation. Conservation of errors (→ absor- bing boundary conditions).
Parabolic correction: Restrictive time step condition for explicit computation.
High cost for implicit computation.
Properties of the different forms
Hyperbolic correction: Cheap in Computation. Conservation of errors (→ absor- bing boundary conditions).
Parabolic correction: Restrictive time step condition for explicit computation.
High cost for implicit computation.
Elliptic correction: Expensive in computation.
Properties of the different forms
Hyperbolic correction: Cheap in Computation. Conservation of errors (→ absor- bing boundary conditions).
Parabolic correction: Restrictive time step condition for explicit computation.
High cost for implicit computation.
Elliptic correction: Expensive in computation.
Mixed type correction: Cheap in computation. Errors not conserved (→ almost no care to be taken on boundary conditions). Our favourite!
Convergence results
Sonja Gutmann (2000):
For the GLM-corrected system of the hyperbolic, parabolic or mixed type with initial values
B0 ∈ L2(Ω) , ψ0 ≡ 0 and boundary values
• Homogeneous Dirichlet (parabolic correction).
• ψ − B · ~n = 0 (hyperbolic and mixed type correction).
the (weak) solution B converges to the divergence free part of B0.
Travelling wave solutions
Ansatz:
err2(x, t) = ei(~kx−ωt) · eαt , (α, ω ∈ R, ~k ∈ Rn) Hyperbolic correction:
err2 = ei(~kx±ck~kk2t) . Parabolic correction:
err2 = ei~kx · e−κ~k2t . Mixed type correction:
err2 =
ei(
~kx±c r
~k2− c2
4κ2 t)
· e−c
2
2κt if ~k2 ≥ 4κc22 , ei~kx · e−
c2 2κt±c
r
c2
4κ2−~k2 t
if ~k2 ≤ 4κc22 .
Corrections in the Maxwell equations
Et − c2(∇ × B) + fehl1 = − j ε0 , Bt + (∇ × E) + err1 = 0 ,
∇ · E + fehl2 = q ε0 ,
∇ · B + err2 = 0 . Error equations:
fehl2t − ∇ · fehl1= 1
ε0(qt + ∇ · j) , err2t − ∇ · err1= 0 .
MHD equations deduced with corrected Maxwell equations
ρt + ∇ · [ρ~v] = 0 , (ρ~v)t + ∇ ·
ρ~v ·~vT + (p + 1
2B2)I − B · BT
= fehl1×B − (∇ · B)B , Bt + ∇ ·
~v · BT − B ·~vT
= −err1 , et + ∇ · h
(e + p + 1
2B2)~v − B(~v · B)i
= −~v ·
fehl1×B
−(~v · B)(∇ · B) − B·err1 , fehl2 − ∇ · [~v × B] = 0 ,
err2 + ∇ · B = 0 .
MHD equations corrected directly
ρt + ∇ · [ρ~v] = 0 , (ρ~v)t + ∇ ·
ρ~v · ~vT + (p + 1
2B2)I − B · BT
= −fehl1 , Bt + ∇ ·
~v · BT − B ·~vT
= −err1 , et + ∇ · h
(e + p + 1
2B2)~v − B(~v · B)i
= 0 , fehl2 − ∇ · [~v × B] = 0 , err2 + ∇ · B = 0 . Error equation for fehl involves most state variables.
Error equation for err same as for Maxwell and simple problem.
The Powell correction
ρt + ∇ · [ρ~v] = 0 , (ρ~v)t + ∇ ·
ρ~v ·~vT + (p + 1
2B2)I − B · BT
= −(∇ · B)B , Bt + ∇ ·
~v · BT − B ·~vT
= −err1 , et + ∇ · h
(e + p + 1
2B2)~v − B(~v · B)i
= 0 , err2 + ∇ · B = 0 With transport method for err and
˜
v = ~v .
Numerical Results for MHD
Divergence errors:
a) without correction, b) Powell correction, c) GLM correction
Numerical Results for MHD
Grid adaption:
a) without correction, b) Powell correction, c) GLM correction
Numerical Results for MHD
B-Field:
B1-component: a) Powell, b) GLM B2-component: a) Powell, b) GLM
Numerical Results for MHD
Norm of divergence error:
0 2 4 6 8 10 12
0 0.05 0.1 0.15 0.2 0.25
L1(|divBjmp|)
time cp = 2.0
cp = 10.0 Powell no correction
0 200 400 600 800 1000 1200 1400 1600 1800
0 0.05 0.1 0.15 0.2 0.25
max(|divBjmp|)
time cp = 2.0
cp = 10.0 Powell no correction
L1 norm, sup norm.
Conclusions
• Error modelling gives insight in the known correction methods.
Conclusions
• Error modelling gives insight in the known correction methods.
• Error modelling is a platform for the development of better correction schemes.
Conclusions
• Error modelling gives insight in the known correction methods.
• Error modelling is a platform for the development of better correction schemes.
• The mixed type is the preferable GLM method.
Conclusions
• Error modelling gives insight in the known correction methods.
• Error modelling is a platform for the development of better correction schemes.
• The mixed type is the preferable GLM method.
• Divergence correction makes the scheme more stable.
Conclusions
• Error modelling gives insight in the known correction methods.
• Error modelling is a platform for the development of better correction schemes.
• The mixed type is the preferable GLM method.
• Divergence correction makes the scheme more stable.
• A good Divergence correction scheme saves computation time on adapted grids.
Conclusions
• Error modelling gives insight in the known correction methods.
• Error modelling is a platform for the development of better correction schemes.
• The mixed type is the preferable GLM method.
• Divergence correction makes the scheme more stable.
• A good Divergence correction scheme saves computation time on adapted grids.
• Good choice of parameters in GLM-methods?