Vous êtes sur la page 1sur 120

Part III

20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Part III
20401
Tony Shardlow
1 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Outline
1
Uniqueness for reaction diusion model
2
Stability for diusion model
3
Finite dierences
4
Numerical analysis
5
Finite dierences for convection diusion model
2 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Outline
1
Uniqueness for reaction diusion model
2
Stability for diusion model
3
Finite dierences
4
Numerical analysis
5
Finite dierences for convection diusion model
3 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
A model reaction diusion
problem
Model reaction diusion problem
For a constant r 0,
u

+ r u = f for 0 < x < 1


u(0) = , u(1) = .
_
This is a two point Boundary Value Problem (BVP).
It is a simple model of a system with reaction and diusion in
equilibrium.
4 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Example soln 1
u

= 1 for 0 < x < 1, (1.1)


u(0) = 0; u(1) = 0.
The solution is u(x) =
1
2
(x x
2
) .
0 0.5 1
0
1/8
x
t
e
m
p
e
r
a
t
u
r
e
Problem 1.1
0 0.5 1
0
1/(w^2)
Problem 1.2
d
e
f
l
e
c
t
i
o
n
x
5 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Example soln 2
u

+ w
2
u = 1 for 0 < x < 1 (1.2)
u(0) = 0; u(1) = 0.
The solution is
u(x) =
1
w
2

(exp(wx) + exp(w(1 x)))
w
2
(1 + exp(w))
.
0 0.5 1
0
1/8
x
t
e
m
p
e
r
a
t
u
r
e
Problem 1.1
0 0.5 1
0
1/(w^2)
Problem 1.2
d
e
f
l
e
c
t
i
o
n
x
6 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Uniqueness for reaction diusion
model
u

+ r u = f for 0 < x < 1


u(0) = , u(1) = .
_
Denition (well posed)
A boundary value problem is well posed if
existence a solution exists
uniqueness the solution is unique
stability the solution depends continuously on the data.
We know solutions exists (using SoV) .
We now look at uniqueness .
HOMEWORK
You can now try Problem 1
7 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Uniqueness for reaction diusion
model
u

+ r u = f for 0 < x < 1


u(0) = , u(1) = .
_
Denition (well posed)
A boundary value problem is well posed if
existence a solution exists
uniqueness the solution is unique
stability the solution depends continuously on the data.
We know solutions exists (using SoV) .
We now look at uniqueness .
HOMEWORK
You can now try Problem 1
8 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Theorem (uniqueness of soln)
There is at most one solution u to
u

+ r u = f , u(0) = , u(1) = ,
where r 0.
Proof.
Suppose that u, v are solns.
As the PDE is linear,
the dierence w(x) = u(x) v(x) satises
w

+ r w = 0, w(0) = 0, w(1) = 0.
9 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Proof ctd.
From w

+ r w = 0,multiply by w and integrate over (0, 1),

_
1
0
ww

dx + r
_
1
0
w
2
dx = 0.
Integrate the rst term by parts:

_
ww

_
1
0
+
_
1
0
(w

)
2
dx + r
_
1
0
w
2
dx = 0.
The rst term is zero because of the boundary conditions
w(0) = 0 and w(1) = 0.
10 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Proof ctd.
_
1
0
(w

)
2
dx
. .
0
+r
_
1
0
w
2
dx
. .
0
= 0,
with r 0.
The rst term implies that w

(x) = 0 for x (0, 1).


Hence w is constant in (0, 1).
As w(0) = 0 and is constant, we conclude that w 0.
As w = u v, we see u v and the two solutions are the
same.
We have proved uniqueness of solutions.
HOMEWORK
You can now try Problem 2 and 3
11 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Proof ctd.
_
1
0
(w

)
2
dx
. .
0
+r
_
1
0
w
2
dx
. .
0
= 0,
with r 0.
The rst term implies that w

(x) = 0 for x (0, 1).


Hence w is constant in (0, 1).
As w(0) = 0 and is constant, we conclude that w 0.
As w = u v, we see u v and the two solutions are the
same.
We have proved uniqueness of solutions.
HOMEWORK
You can now try Problem 2 and 3
12 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Proof ctd.
_
1
0
(w

)
2
dx
. .
0
+r
_
1
0
w
2
dx
. .
0
= 0,
with r 0.
The rst term implies that w

(x) = 0 for x (0, 1).


Hence w is constant in (0, 1).
As w(0) = 0 and is constant, we conclude that w 0.
As w = u v, we see u v and the two solutions are the
same.
We have proved uniqueness of solutions.
HOMEWORK
You can now try Problem 2 and 3
13 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Proof ctd.
_
1
0
(w

)
2
dx
. .
0
+r
_
1
0
w
2
dx
. .
0
= 0,
with r 0.
The rst term implies that w

(x) = 0 for x (0, 1).


Hence w is constant in (0, 1).
As w(0) = 0 and is constant, we conclude that w 0.
As w = u v, we see u v and the two solutions are the
same.
We have proved uniqueness of solutions.
HOMEWORK
You can now try Problem 2 and 3
14 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Proof ctd.
_
1
0
(w

)
2
dx
. .
0
+r
_
1
0
w
2
dx
. .
0
= 0,
with r 0.
The rst term implies that w

(x) = 0 for x (0, 1).


Hence w is constant in (0, 1).
As w(0) = 0 and is constant, we conclude that w 0.
As w = u v, we see u v and the two solutions are the
same.
We have proved uniqueness of solutions.
HOMEWORK
You can now try Problem 2 and 3
15 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Outline
1
Uniqueness for reaction diusion model
2
Stability for diusion model
3
Finite dierences
4
Numerical analysis
5
Finite dierences for convection diusion model
16 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Diusion problem
The third condition for a well posed problem is stability or
continuous dependence on the problem data.
For simplicity, we investigate stability for the diusion problem
(case r = 0 of the reaction diusion model).
Model diusion problem
u

= f for 0 < x < 1


u(0) = ; u(1) = .
_
To establish stability, we show that u(x)
depends continuously on boundary data ( and ).
17 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Diusion problem
The third condition for a well posed problem is stability or
continuous dependence on the problem data.
For simplicity, we investigate stability for the diusion problem
(case r = 0 of the reaction diusion model).
Model diusion problem
u

= f for 0 < x < 1


u(0) = ; u(1) = .
_
To establish stability, we show that u(x)
depends continuously on boundary data ( and ).
18 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Diusion problem
The third condition for a well posed problem is stability or
continuous dependence on the problem data.
For simplicity, we investigate stability for the diusion problem
(case r = 0 of the reaction diusion model).
Model diusion problem
u

= f for 0 < x < 1


u(0) = ; u(1) = .
_
To establish stability, we show that u(x)
depends continuously on boundary data ( and ).
19 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Maximum principle
Our main tool is the maximum principle.
Lemma (maximum principle)
Suppose that f (x) < 0 for all x (0, 1).
If u

= f , then u(x) attains its maximum value at one of the


two end points x = 0, 1.
Proof.
Suppose for a contradiction that (0, 1) is a local maximum.
From calculus, u

() 0 and u

() = 0.
Hence u

() 0.
But we assumed u

= f < 0 for all x (0, 1).


Proved by contradiction.
20 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Maximum principle
Our main tool is the maximum principle.
Lemma (maximum principle)
Suppose that f (x) < 0 for all x (0, 1).
If u

= f , then u(x) attains its maximum value at one of the


two end points x = 0, 1.
Proof.
Suppose for a contradiction that (0, 1) is a local maximum.
From calculus, u

() 0 and u

() = 0.
Hence u

() 0.
But we assumed u

= f < 0 for all x (0, 1).


Proved by contradiction.
21 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Upper bound on soln u(x)
Lemma
If u

(x) = 0 for all x (0, 1),


then u(x) M for x [0, 1] and M = maxu(0), u(1).
Proof.
For > 0, let
v

(x) = u(x) + x
2
.
Then v

= u

2 = 2 < 0 for x (0, 1).


By the maximum principle, v

(x) maxv

(0), v

(1) .
Now u(x) = v

(x) x
2
v

(x). Hence,
u(x) v

(x) maxv

(0), v

(1) = maxu(0), u(1) + .


As this holds for any > 0, we are done
22 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Upper bound on soln u(x)
Lemma
If u

(x) = 0 for all x (0, 1),


then u(x) M for x [0, 1] and M = maxu(0), u(1).
Proof.
For > 0, let
v

(x) = u(x) + x
2
.
Then v

= u

2 = 2 < 0 for x (0, 1).


By the maximum principle, v

(x) maxv

(0), v

(1) .
Now u(x) = v

(x) x
2
v

(x). Hence,
u(x) v

(x) maxv

(0), v

(1) = maxu(0), u(1) + .


As this holds for any > 0, we are done
23 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Upper bound on soln u(x)
Lemma
If u

(x) = 0 for all x (0, 1),


then u(x) M for x [0, 1] and M = maxu(0), u(1).
Proof.
For > 0, let
v

(x) = u(x) + x
2
.
Then v

= u

2 = 2 < 0 for x (0, 1).


By the maximum principle, v

(x) maxv

(0), v

(1) .
Now u(x) = v

(x) x
2
v

(x). Hence,
u(x) v

(x) maxv

(0), v

(1) = maxu(0), u(1) + .


As this holds for any > 0, we are done
24 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Upper bound on soln u(x)
Lemma
If u

(x) = 0 for all x (0, 1),


then u(x) M for x [0, 1] and M = maxu(0), u(1).
Proof.
For > 0, let
v

(x) = u(x) + x
2
.
Then v

= u

2 = 2 < 0 for x (0, 1).


By the maximum principle, v

(x) maxv

(0), v

(1) .
Now u(x) = v

(x) x
2
v

(x). Hence,
u(x) v

(x) maxv

(0), v

(1) = maxu(0), u(1) + .


As this holds for any > 0, we are done
25 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Lower bound on soln u(x)
Lemma
If u

(x) = 0 for all x (0, 1)


then m u(x) for x [0, 1] and m = minu(0), u(1).
Proof.
Dene w(x) = u(x).
Then w

(x) = 0 for x (0, 1).


By previous lemma,
w(x) maxw(0), w(1).
and using w = u
u(x) maxu(0), u(1) = minu(0), u(1)
and so u(x) minu(0), u(1)
26 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Lower bound on soln u(x)
Lemma
If u

(x) = 0 for all x (0, 1)


then m u(x) for x [0, 1] and m = minu(0), u(1).
Proof.
Dene w(x) = u(x).
Then w

(x) = 0 for x (0, 1).


By previous lemma,
w(x) maxw(0), w(1).
and using w = u
u(x) maxu(0), u(1) = minu(0), u(1)
and so u(x) minu(0), u(1)
27 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Summary
Theorem
Let u be a smooth solution of
u

= 0 for 0 < x < 1


u(0) = ; u(1) = ;
_
For all x (0, 1),
min, u(x) max, .
HOMEWORK
You can now try Problem 4
We now use this to show stability with respect to changes in
the boundary data , .
28 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Summary
Theorem
Let u be a smooth solution of
u

= 0 for 0 < x < 1


u(0) = ; u(1) = ;
_
For all x (0, 1),
min, u(x) max, .
HOMEWORK
You can now try Problem 4
We now use this to show stability with respect to changes in
the boundary data , .
29 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Continuity with respect to
boundary data
Theorem
Suppose that
u

= f for 0 < x < 1


u(0) = ; u(1) = .
_
(D)
u

= f for 0 < x < 1


u

(0) = +
0
; u

(1) = +
1
.
_
(D

)
Then
sup
x(0,1)
[u(x) u

(x)[ max[
0
[, [
1
[.
Small changes (
0
,
1
) to boundary data
cause small changes to the solution u
30 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Proof
Let e = u

u. Subtracting (D

) from (D) gives


e

= 0 for 0 < x < 1


e(0) =
0
; e(1) =
1
.
As homogeneous, previous theorem implies the stability bound:
min
0
,
1
e(x) max
0
,
1

This implies
[e(x)[ max[
0
[, [
1
[.
HOMEWORK
You can now try Problem 5
31 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Proof
Let e = u

u. Subtracting (D

) from (D) gives


e

= 0 for 0 < x < 1


e(0) =
0
; e(1) =
1
.
As homogeneous, previous theorem implies the stability bound:
min
0
,
1
e(x) max
0
,
1

This implies
[e(x)[ max[
0
[, [
1
[.
HOMEWORK
You can now try Problem 5
32 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Proof
Let e = u

u. Subtracting (D

) from (D) gives


e

= 0 for 0 < x < 1


e(0) =
0
; e(1) =
1
.
As homogeneous, previous theorem implies the stability bound:
min
0
,
1
e(x) max
0
,
1

This implies
[e(x)[ max[
0
[, [
1
[.
HOMEWORK
You can now try Problem 5
33 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Outline
1
Uniqueness for reaction diusion model
2
Stability for diusion model
3
Finite dierences
4
Numerical analysis
5
Finite dierences for convection diusion model
34 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Scientic computing
Scientic computing involves constructing numerical
solution techniques for mathematical models and using
computers to analyse and solve models that arise in
science and engineering.
Without computing, we could not nd or even approximate
solutions to most mathematical models and PDEs.
Numerical analysis is the mathematical theory
underpinning the techniques used in computational
science. It aims to show existing algorithms are ecient
and accurate and develop better algorithms.
We introduce one numerical solution technique for PDEs,
known as nite dierences.
35 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Scientic computing
Scientic computing involves constructing numerical
solution techniques for mathematical models and using
computers to analyse and solve models that arise in
science and engineering.
Without computing, we could not nd or even approximate
solutions to most mathematical models and PDEs.
Numerical analysis is the mathematical theory
underpinning the techniques used in computational
science. It aims to show existing algorithms are ecient
and accurate and develop better algorithms.
We introduce one numerical solution technique for PDEs,
known as nite dierences.
36 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Scientic computing
Scientic computing involves constructing numerical
solution techniques for mathematical models and using
computers to analyse and solve models that arise in
science and engineering.
Without computing, we could not nd or even approximate
solutions to most mathematical models and PDEs.
Numerical analysis is the mathematical theory
underpinning the techniques used in computational
science. It aims to show existing algorithms are ecient
and accurate and develop better algorithms.
We introduce one numerical solution technique for PDEs,
known as nite dierences.
37 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Scientic computing
Scientic computing involves constructing numerical
solution techniques for mathematical models and using
computers to analyse and solve models that arise in
science and engineering.
Without computing, we could not nd or even approximate
solutions to most mathematical models and PDEs.
Numerical analysis is the mathematical theory
underpinning the techniques used in computational
science. It aims to show existing algorithms are ecient
and accurate and develop better algorithms.
We introduce one numerical solution technique for PDEs,
known as nite dierences.
38 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Finite dierence approximation
The idea of the nite dierence method is to approximate
u(x) by u
j
at x = x
j
for x
j
on a grid
Denition (grid)
A uniform grid on [0, 1] is dened by
x
j
= jh, j = 0, . . . , n, h = 1/n.

0 = x
0
x
1
x
2
x
3
x
n
= 1
h =
1
n
h h
39 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Approximating derivatives on a
grid
Denition (centered dierencing)
To approximate derivatives u

(x
j
) at a grid point x = x
j
, write
u

(x
j
)
1
h
u(x
j
) ,
where u(x) = u(x + h/2) u(x h/2).
x
j

h
2
x
j
+
h
2
u(x
j
h)
u(x
j
)
u(x
j
+h)
40 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Error
Theorem (Taylors theorem)
u(x + h) = u(x) + hu

(x) +
1
2
h
2
u

(x) + +
1
n!
h
n
u
(n)
()
for some (x, x + h).
Then
u(x + h) u(x) = hu

(x) +
1
2
h
2
u

()
= hu

(x) +O(h
2
) ,
where we use the notation O(h
2
) for short. It means any
quantity bounded by Kh
2
for some constant K.
HOMEWORK
You can now try Problem 7 and 8
41 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Error
Theorem (Taylors theorem)
u(x + h) = u(x) + hu

(x) +
1
2
h
2
u

(x) + +
1
n!
h
n
u
(n)
()
for some (x, x + h).
Then
u(x + h) u(x) = hu

(x) +
1
2
h
2
u

()
= hu

(x) +O(h
2
) ,
where we use the notation O(h
2
) for short. It means any
quantity bounded by Kh
2
for some constant K.
HOMEWORK
You can now try Problem 7 and 8
42 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Error
Theorem (Taylors theorem)
u(x + h) = u(x) + hu

(x) +
1
2
h
2
u

(x) + +
1
n!
h
n
u
(n)
()
for some (x, x + h).
Then
u(x + h) u(x) = hu

(x) +
1
2
h
2
u

()
= hu

(x) +O(h
2
) ,
where we use the notation O(h
2
) for short. It means any
quantity bounded by Kh
2
for some constant K.
HOMEWORK
You can now try Problem 7 and 8
43 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Error
Theorem (Taylors theorem)
u(x + h) = u(x) + hu

(x) +
1
2
h
2
u

(x) + +
1
n!
h
n
u
(n)
()
for some (x, x + h).
Then
u(x + h) u(x) = hu

(x) +
1
2
h
2
u

()
= hu

(x) +O(h
2
) ,
where we use the notation O(h
2
) for short. It means any
quantity bounded by Kh
2
for some constant K.
HOMEWORK
You can now try Problem 7 and 8
44 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Lemma
The error in approximating u

(x
j
) by u(x
j
)/h is
e
j
= u

(x
j
)
1
h
u(x
j
) = O(h
2
).
Proof.
By Taylors theorem,
u(x + h/2) =u(x) +
h
2
u

(x) +
h
2
8
u

(x) +O(h
3
)
u(x h/2) =u(x)
h
2
u

(x) +
h
2
8
u

(x) +O(h
3
)
so
u(x
j
)
h
=
(u(x
j
+ h/2) u(x
j
h/2))
h
=
hu

(x
j
) +O(h
3
)
h
= u

(x
j
) +O(h
2
).
45 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Lemma
The error in approximating u

(x
j
) by u(x
j
)/h is
e
j
= u

(x
j
)
1
h
u(x
j
) = O(h
2
).
Proof.
By Taylors theorem,
u(x + h/2) =u(x) +
h
2
u

(x) +
h
2
8
u

(x) +O(h
3
)
u(x h/2) =u(x)
h
2
u

(x) +
h
2
8
u

(x) +O(h
3
)
so
u(x
j
)
h
=
(u(x
j
+ h/2) u(x
j
h/2))
h
=
hu

(x
j
) +O(h
3
)
h
= u

(x
j
) +O(h
2
).
46 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Lemma
The error in approximating u

(x
j
) by u(x
j
)/h is
e
j
= u

(x
j
)
1
h
u(x
j
) = O(h
2
).
Proof.
By Taylors theorem,
u(x + h/2) =u(x) +
h
2
u

(x) +
h
2
8
u

(x) +O(h
3
)
u(x h/2) =u(x)
h
2
u

(x) +
h
2
8
u

(x) +O(h
3
)
so
u(x
j
)
h
=
(u(x
j
+ h/2) u(x
j
h/2))
h
=
hu

(x
j
) +O(h
3
)
h
= u

(x
j
) +O(h
2
).
47 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Approximate u
//
(x
j
)
Denition (second centered dierence)
To approximate the second derivative, write
1
h
2

2
u(x
j
) u

(x
j
)
where

2
u(x
j
) =[u(x
j
)]
=u(x
j
+
h
2
) u(x
j

h
2
)
= u(x
j
+ h) u(x
j
) (u(x
j
) u(x
j
h))
= u(x
j
+ h) 2u(x
j
) + u(x
j
h) .
48 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Approximate u
//
(x
j
)
Denition (second centered dierence)
To approximate the second derivative, write
1
h
2

2
u(x
j
) u

(x
j
)
where

2
u(x
j
) =[u(x
j
)]
=u(x
j
+
h
2
) u(x
j

h
2
)
= u(x
j
+ h) u(x
j
) (u(x
j
) u(x
j
h))
= u(x
j
+ h) 2u(x
j
) + u(x
j
h) .
49 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Finite dierences for model
reaction diusion PDE
Consider the reaction diusion equation
u

+ ru = f , u(0) = u(1) = 0.
At the grid points x
j
= jh where h = 1/n, the PDE is
u

(x
j
) + ru(x
j
) = f (x
j
) j = 1, 2, . . . , n 1.
Let f
j
= f (x
j
) and make approximations
u(x
j
) u
j
, u

(x
j
)
2
u
j
/h
2
.
Finite dierence approximation u
j
is soln of

1
h
2

2
u
j
+ ru
j
= f
j
j = 1, 2, . . . , n 1.
with boundary conditions u
0
= u
n
= 0
50 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Finite dierences for model
reaction diusion PDE
Consider the reaction diusion equation
u

+ ru = f , u(0) = u(1) = 0.
At the grid points x
j
= jh where h = 1/n, the PDE is
u

(x
j
) + ru(x
j
) = f (x
j
) j = 1, 2, . . . , n 1.
Let f
j
= f (x
j
) and make approximations
u(x
j
) u
j
, u

(x
j
)
2
u
j
/h
2
.
Finite dierence approximation u
j
is soln of

1
h
2

2
u
j
+ ru
j
= f
j
j = 1, 2, . . . , n 1.
with boundary conditions u
0
= u
n
= 0
51 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Finite dierences for model
reaction diusion PDE
Consider the reaction diusion equation
u

+ ru = f , u(0) = u(1) = 0.
At the grid points x
j
= jh where h = 1/n, the PDE is
u

(x
j
) + ru(x
j
) = f (x
j
) j = 1, 2, . . . , n 1.
Let f
j
= f (x
j
) and make approximations
u(x
j
) u
j
, u

(x
j
)
2
u
j
/h
2
.
Finite dierence approximation u
j
is soln of

1
h
2

2
u
j
+ ru
j
= f
j
j = 1, 2, . . . , n 1.
with boundary conditions u
0
= u
n
= 0
52 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Finite dierences for model
reaction diusion problem
Denition (nite dierence method)
The nite dierence method is to nd u
j
u(x
j
) such that

1
h
2

2
u
j
+ ru
j
= f
j
j = 1, 2, . . . , n 1, ()
and u
0
= u
n
= 0.
As

2
u
j
= u
j 1
2u
j
+ u
j +1
,
the nite dierence method is

1
h
2
(u
j 1
2u
j
+ u
j +1
) + r u
j
= f
j
j = 1, 2, . . . , n 1.
53 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Finite dierences for model
reaction diusion problem
Denition (nite dierence method)
The nite dierence method is to nd u
j
u(x
j
) such that

1
h
2

2
u
j
+ ru
j
= f
j
j = 1, 2, . . . , n 1, ()
and u
0
= u
n
= 0.
As

2
u
j
= u
j 1
2u
j
+ u
j +1
,
the nite dierence method is

1
h
2
(u
j 1
2u
j
+ u
j +1
) + r u
j
= f
j
j = 1, 2, . . . , n 1.
54 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Linear system of eqns

1
h
2
(u
j 1
2u
j
+ u
j +1
) + r u
j
= f
j
j = 1, 2, . . . , n 1.
and rearranging

1
h
2
u
j 1
+ (
2
h
2
+ r )u
j

1
h
2
u
j +1
= f
j
.
The BCs u(0) = u(1) = 0 give u
0
= 0 and u
n
= 0 . Write
as a system of linear equations:
_

_
(
2
h
2
+ r )
1
h
2
0
.
.
.
.
.
.

1
h
2
(
2
h
2
+ r )
1
h
2
.
.
.
.
.
.
0
1
h
2
(
2
h
2
+ r )
_

_
_

_
u
1
.
.
.
u
j
.
.
.
u
n1
_

_
=
_

_
f
1
.
.
.
f
j
.
.
.
f
n1
_

_
55 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Example (r = 0, f (x) = 1)
Take n = 6, i.e. h = 1/6. The system is
_

_
72 36 0 0 0
36 72 36 0 0
0 36 72 36 0
0 0 36 72 36
0 0 0 36 72
_

_
_

_
u
1
u
2
u
3
u
4
u
5
_

_
=
_

_
1
1
1
1
1
_

_
Solve the system of equations (e.g., with MATLAB):
u
1
= u
5
= 5/72;
u
2
= u
4
= 1/9 = 8/72;
u
3
= 1/8 = 9/72.
Note that u
j
= u(x
j
) =
1
2
(x
j
x
2
j
). That is, the nite
dierence solution is exact in this example.
56 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Example (r = 0, f (x) = 1)
Take n = 6, i.e. h = 1/6. The system is
_

_
72 36 0 0 0
36 72 36 0 0
0 36 72 36 0
0 0 36 72 36
0 0 0 36 72
_

_
_

_
u
1
u
2
u
3
u
4
u
5
_

_
=
_

_
1
1
1
1
1
_

_
Solve the system of equations (e.g., with MATLAB):
u
1
= u
5
= 5/72;
u
2
= u
4
= 1/9 = 8/72;
u
3
= 1/8 = 9/72.
Note that u
j
= u(x
j
) =
1
2
(x
j
x
2
j
). That is, the nite
dierence solution is exact in this example.
57 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Example
u

+ 16u = 1 for 0 < x < 1


u(0) = 0; u(1) = 0.
_
(RD)
Take n = 5, i.e. h = 1/5. Thus,

0 = x
0
x
1
x
2
x
3
x
4
x
5
= 1
h =
1
5
h h
Since 1/h
2
= 25 the tridiagonal system is
_

_
66 25 0 0
25 66 25 0
0 25 66 25
0 0 25 66
_

_
_

_
u
1
u
2
u
3
u
4
_

_
=
_

_
1
1
1
1
_

_
.
58 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Example solution

0 = x
0
x
1
x
2
x
3
x
4
x
5
= 1
h =
1
5
u
1
u
2
u
3
u
4
_

_
66 25 0 0
25 66 25 0
0 25 66 25
0 0 25 66
_

_
_

_
u
1
u
2
u
3
u
4
_

_
=
_

_
1
1
1
1
_

_
.
The nite dierence solution is
u
1
= u
4
= 0.03171..
u
2
= u
3
= 0.04372..
Note that u
j
,= u(x
j
) since
u(x
1
) = u(x
4
) = 0.03242..
u(x
2
) = u(x
3
) = 0.04454..
59 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Compare numerical and exact
soln
Comparing u(x
j
) (x) with u
j
( o) ...
0.2 0.4 0.6 0.8
0.02
0.025
0.03
0.035
0.04
0.045
0.05
e
1
e
2
e
3
e
4
u(x)
global error components
60 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Outline
1
Uniqueness for reaction diusion model
2
Stability for diusion model
3
Finite dierences
4
Numerical analysis
5
Finite dierences for convection diusion model
61 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Numerical analysis
We have derived a numerical method for the PDE.
The method produces errors and we must show the errors are
small.
Denition (global error)
The global error is dened by
e
j
= u(x
j
) u
j
, j = 0, 1, 2, . . . , n.
This is the error that matters to the applied scientist: it
measures how close the computed soln is to true soln.
Denition (convergent)
The nite dierence method is said to be convergent if and
only if
max
0j n
[e
j
[ 0 as n .
62 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Numerical analysis
We have derived a numerical method for the PDE.
The method produces errors and we must show the errors are
small.
Denition (global error)
The global error is dened by
e
j
= u(x
j
) u
j
, j = 0, 1, 2, . . . , n.
This is the error that matters to the applied scientist: it
measures how close the computed soln is to true soln.
Denition (convergent)
The nite dierence method is said to be convergent if and
only if
max
0j n
[e
j
[ 0 as n .
63 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Numerical analysis
We have derived a numerical method for the PDE.
The method produces errors and we must show the errors are
small.
Denition (global error)
The global error is dened by
e
j
= u(x
j
) u
j
, j = 0, 1, 2, . . . , n.
This is the error that matters to the applied scientist: it
measures how close the computed soln is to true soln.
Denition (convergent)
The nite dierence method is said to be convergent if and
only if
max
0j n
[e
j
[ 0 as n .
64 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Numerical analysis
We have derived a numerical method for the PDE.
The method produces errors and we must show the errors are
small.
Denition (global error)
The global error is dened by
e
j
= u(x
j
) u
j
, j = 0, 1, 2, . . . , n.
This is the error that matters to the applied scientist: it
measures how close the computed soln is to true soln.
Denition (convergent)
The nite dierence method is said to be convergent if and
only if
max
0j n
[e
j
[ 0 as n .
65 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Truncation error
Denition (local truncation error)
The local truncation error T
j
at the grid point x
j
is the
remainder when u(x
j
) is substituted in place of u
j
in

1
h
2

2
u
j
+ r u
j
= f
j
j = 1, 2, . . . , n 1,
i.e.,
T
j
=
1
h
2

2
u(x
j
) + ru(x
j
) f
j
j = 1, 2, . . . , n 1.
From the PDE,
0 = u

(x
j
) + ru(x
j
) f
j
j = 1, 2, . . . , n 1
so subtracting equations gives
T
j
= u

(x
j
)
1
h
2

2
u(x
j
).
66 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Denition (kth order consistent)
A nite dierence scheme is said to be kth order consistent for
k > 0 if the local error satises
[T
j
[ = O(h
k
) j = 1, 2, . . . , n 1.
Theorem (2nd order consistent)
The method is 2nd order consistent if the local truncation error
satises
[T
j
[ = O(h
2
), j = 1, 2, . . . , n 1.
67 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Denition (kth order consistent)
A nite dierence scheme is said to be kth order consistent for
k > 0 if the local error satises
[T
j
[ = O(h
k
) j = 1, 2, . . . , n 1.
Theorem (2nd order consistent)
The method is 2nd order consistent if the local truncation error
satises
[T
j
[ = O(h
2
), j = 1, 2, . . . , n 1.
68 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Proof.
By Taylors theorem,
u(x h)=u(x) hu

(x) +
h
2
2
u

(x)
h
3
6
u

(x) +O(h
4
)
u(x + h)=u(x) + hu

(x) +
h
2
2
u

(x) +
h
3
6
u

(x) +O(h
4
).
and
T
j
= u

(x
j
)
1
h
2
(u(x
j
h) 2u(x
j
) + u(x
j
+ h)).
We can add the expansions for u(x h) and u(x + h), to nd
u(x
j
h) + u(x
j
+ h) = 2u(x
j
) + h
2
u

(x
j
) +O(h
4
).
Rearranging gives
T
j
= O(h
2
).
69 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Global error
HOMEWORK
You can now try Problem 9 and 10
We relate the global error e
j
at the grid point x
j
to the local
truncation error T
j
T
j
=
1
h
2

2
u(x
j
) + ru(x
j
) f
j
j = 1, 2, . . . , n 1,
0 =
1
h
2

2
u
j
+ r u
j
f
j
j = 1, 2, . . . , n 1.
Subtracting these equations and letting e
j
= u(x
j
) u
j
gives
T
j
=
1
h
2

2
e
j
+ r e
j
j = 1, 2, . . . , n 1.
We have a linear system of eqns for e
j
.
70 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Global error
HOMEWORK
You can now try Problem 9 and 10
We relate the global error e
j
at the grid point x
j
to the local
truncation error T
j
T
j
=
1
h
2

2
u(x
j
) + ru(x
j
) f
j
j = 1, 2, . . . , n 1,
0 =
1
h
2

2
u
j
+ r u
j
f
j
j = 1, 2, . . . , n 1.
Subtracting these equations and letting e
j
= u(x
j
) u
j
gives
T
j
=
1
h
2

2
e
j
+ r e
j
j = 1, 2, . . . , n 1.
We have a linear system of eqns for e
j
.
71 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Global error
HOMEWORK
You can now try Problem 9 and 10
We relate the global error e
j
at the grid point x
j
to the local
truncation error T
j
T
j
=
1
h
2

2
u(x
j
) + ru(x
j
) f
j
j = 1, 2, . . . , n 1,
0 =
1
h
2

2
u
j
+ r u
j
f
j
j = 1, 2, . . . , n 1.
Subtracting these equations and letting e
j
= u(x
j
) u
j
gives
T
j
=
1
h
2

2
e
j
+ r e
j
j = 1, 2, . . . , n 1.
We have a linear system of eqns for e
j
.
72 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Global error
HOMEWORK
You can now try Problem 9 and 10
We relate the global error e
j
at the grid point x
j
to the local
truncation error T
j
T
j
=
1
h
2

2
u(x
j
) + ru(x
j
) f
j
j = 1, 2, . . . , n 1,
0 =
1
h
2

2
u
j
+ r u
j
f
j
j = 1, 2, . . . , n 1.
Subtracting these equations and letting e
j
= u(x
j
) u
j
gives
T
j
=
1
h
2

2
e
j
+ r e
j
j = 1, 2, . . . , n 1.
We have a linear system of eqns for e
j
.
73 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Stability theorem for nite
dierences
Theorem (Stability theorem)
Suppose that u
j

n
j =0
satisfy the tridiagonal system of
equations
au
j 1
+ bu
j
cu
j +1
0 j = 1, 2, . . . , n 1.
Let a, b, c denote real coecients with
a 0
c 0
b a + c > 0
_
_
_
(S)
then
u
j
max0, u
0
, u
n
for all j = 0, 1, 2, . . . , n.
74 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Proof.
Suppose for a contradiction, there exists u
k
0 for
k = 1, . . . , n 1 such that
u
k
=maxu
0
, u
1
, u
2
, . . . , u
n

minu
k1
, u
k+1
<u
k
.
As au
j 1
+ bu
j
cu
j +1
0,
bu
k
au
k1
+ cu
k+1
< au
k
+ cu
k
as a, c 0 and defn of u
k
= (a + c)u
k
= bu
k
using a + c b
As b > 0, this is a contradiction.
75 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Proof.
Suppose for a contradiction, there exists u
k
0 for
k = 1, . . . , n 1 such that
u
k
=maxu
0
, u
1
, u
2
, . . . , u
n

minu
k1
, u
k+1
<u
k
.
As au
j 1
+ bu
j
cu
j +1
0,
bu
k
au
k1
+ cu
k+1
< au
k
+ cu
k
as a, c 0 and defn of u
k
= (a + c)u
k
= bu
k
using a + c b
As b > 0, this is a contradiction.
76 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Proof ctd.
We conclude that either
1
there is a maximum, which is negative (u
k
0) or
2
there is a maximum at the boundary u
k
maxu
0
, u
n
.
.
HOMEWORK
You can now try Problem 11
77 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Proof ctd.
We conclude that either
1
there is a maximum, which is negative (u
k
0) or
2
there is a maximum at the boundary u
k
maxu
0
, u
n
.
.
HOMEWORK
You can now try Problem 11
78 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Stability+consisitency
convergence
1
For PDE, the maximum principle gave us continuous
dependence on data and hence well posedness.
2
For numerical method, the discrete maximum principle
gives us continuous dependence of global error on
truncation error.
3
This type of result for numerical methods is usually
referred to as stability and
Stability+consistency convergence
Recall, consistency means local truncation error T
j
is
O(h
k
), some k > 1.
convergence means global error u(x
j
) u
j
is small.
4
No proofs given, but Theorem given next.
79 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Stability+consisitency
convergence
1
For PDE, the maximum principle gave us continuous
dependence on data and hence well posedness.
2
For numerical method, the discrete maximum principle
gives us continuous dependence of global error on
truncation error.
3
This type of result for numerical methods is usually
referred to as stability and
Stability+consistency convergence
Recall, consistency means local truncation error T
j
is
O(h
k
), some k > 1.
convergence means global error u(x
j
) u
j
is small.
4
No proofs given, but Theorem given next.
80 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Stability+consisitency
convergence
1
For PDE, the maximum principle gave us continuous
dependence on data and hence well posedness.
2
For numerical method, the discrete maximum principle
gives us continuous dependence of global error on
truncation error.
3
This type of result for numerical methods is usually
referred to as stability and
Stability+consistency convergence
Recall, consistency means local truncation error T
j
is
O(h
k
), some k > 1.
convergence means global error u(x
j
) u
j
is small.
4
No proofs given, but Theorem given next.
81 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Stability+consisitency
convergence
1
For PDE, the maximum principle gave us continuous
dependence on data and hence well posedness.
2
For numerical method, the discrete maximum principle
gives us continuous dependence of global error on
truncation error.
3
This type of result for numerical methods is usually
referred to as stability and
Stability+consistency convergence
Recall, consistency means local truncation error T
j
is
O(h
k
), some k > 1.
convergence means global error u(x
j
) u
j
is small.
4
No proofs given, but Theorem given next.
82 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Theorem (Stability+constistency=convergence)
Suppose that
consistent: the nite dierence method is kth order consistent.
stable the method has the form
au
j 1
+ bu
j
cu
j +1
= f
j
with a, c 0 and b a + c > 0.
Then, the numerical approximation converges to the exact
solution,
e
j
= [u
j
u(x
j
)[ = O(h
k
) as h 0.
83 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Stability of nite dierence
approx
Recall the nite dierence approximation

1
h
2
u
j 1
+ (
2
h
2
+ r )u
j

1
h
2
u
j +1
= f
j
j = 1, 2, . . . , n 1,
To show that the approximation is stable,
we apply the Stability Theorem and look at condition (S).
a 0
1
h
2
0
c 0
1
h
2
0
b a + c
2
h
2
+ r
2
h
2
The centred approximation method is stable as r 0.
84 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Stability of nite dierence
approx
Recall the nite dierence approximation

1
h
2
u
j 1
+ (
2
h
2
+ r )u
j

1
h
2
u
j +1
= f
j
j = 1, 2, . . . , n 1,
To show that the approximation is stable,
we apply the Stability Theorem and look at condition (S).
a 0
1
h
2
0
c 0
1
h
2
0
b a + c
2
h
2
+ r
2
h
2
The centred approximation method is stable as r 0.
85 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Stability of nite dierence
approx
Recall the nite dierence approximation

1
h
2
u
j 1
+ (
2
h
2
+ r )u
j

1
h
2
u
j +1
= f
j
j = 1, 2, . . . , n 1,
To show that the approximation is stable,
we apply the Stability Theorem and look at condition (S).
a 0
1
h
2
0
c 0
1
h
2
0
b a + c
2
h
2
+ r
2
h
2
The centred approximation method is stable as r 0.
86 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Stability of nite dierence
approx
Recall the nite dierence approximation

1
h
2
u
j 1
+ (
2
h
2
+ r )u
j

1
h
2
u
j +1
= f
j
j = 1, 2, . . . , n 1,
To show that the approximation is stable,
we apply the Stability Theorem and look at condition (S).
a 0
1
h
2
0
c 0
1
h
2
0
b a + c
2
h
2
+ r
2
h
2
The centred approximation method is stable as r 0.
87 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
1
Proof of theorem not given. See written notes.
2
It is similar to the proof of stability for the diusion
problem.
3
We conclude that the global error for the centered
dierence approximation of the diusion problem satises
global error = [u
j
u(x
j
)[ = O(h
2
).
88 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Outline
1
Uniqueness for reaction diusion model
2
Stability for diusion model
3
Finite dierences
4
Numerical analysis
5
Finite dierences for convection diusion model
89 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Convection diusion problem
The problem
u

+ ru = f
is known as a reaction diusion equation, as the term u

models diusion and the term u

models reaction.
We now look at a convection diusion equation, replacing u
with u

.
Convection-diusion
u

+ wu

= f for 0 < x < 1


u(0) = ; u(1) =
_
for some f : (0, 1) R, a scalar w R, and boundary values
, R.
The scalar w is known as the wind.
It controls the strength and direction of the convection.
90 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Problem 1.3
u

+ wu

= 0 for 0 < x < 1 (1.3)


u(0) = 1; u(1) = 0.
The solution is
u(x) =
exp(w) exp(wx)
exp(w) 1
0 0.5
0
1
x
t
e
m
p
e
r
a
t
u
r
e
Problem 1.3
w=0
w=5
w=20
0 0.5 1
0
1/8
Problem 1.4
w=20
w=5
w=0
91 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Problem
u

+ wu

= 1 for 0 < x < 1 (1.4)


u(0) = 0; u(1) = 0.
The solution is
u(x) =
x
w

1 exp(wx)
w(exp(w) 1)
0 0.5
0
1
x
t
e
m
p
e
r
a
t
u
r
e
Problem 1.3
w=0
w=5
w=20
0 0.5 1
0
1/8
Problem 1.4
w=20
w=5
w=0
92 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Centered nite dierences
There are two derivatives to approximate.
u

(x
j
)
u

(x
j
)

2
u(x
j
)
h
2
=
u(x
j
+ h) 2u(x
j
) + u(x
j
h)
h
2
.
u

(x
j
)
We cannot use u(x
j
) = u(x
j
+ h/2) u(x
j
h/2) as we can
only take values on the grid.
We use the averaged centered dierence:
u

(x
j
)

u(x
j
)
h
=
1
2h
_
u(x
j
+
h
2
) + u(x
j

h
2
)
_
=
1
2h
(u(x
j
+ h) u(x
j
h)) .
93 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Numerical approximation
The exact solution at the grid points u(x
j
) satises
u

(x
j
) + wu

(x
j
) = f
j
j = 1, 2, . . . , n 1.
Replace derivatives by centered nite dierences
Centered nite dierence method
Find u
j
such that

1
h
2

2
u
j
+
w
h

u
j
= f
j
j = 1, 2, . . . , n 1.
That is,

1
h
2
(u
j +1
2u
j
+ u
j 1
) +
w
2h
(u
j +1
u
j 1
) = f
j
.
94 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Linear system of equations
For j = 1, . . . , n 1,

1
h
2
(u
j +1
2u
j
+ u
j 1
) +
w
2h
(u
j +1
u
j 1
) = f
j
_

1
h
2

w
2h
_
. .
a
u
j 1
+
_
2
h
2
_
. .
b
u
j
+
_

1
h
2
+
w
2h
_
. .
c
u
j +1
= f
j
To take care of the boundary conditions The BC u(0) =
gives u
0
= and
a + bu
1
cu
2
= f
0
bu
1
cu
2
= f
0
+ a.
The BC u(1) = gives u
n
= and
au
n2
+ bu
n1
= f
n1
+ c.
95 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Linear system of equations
For j = 1, . . . , n 1,

1
h
2
(u
j +1
2u
j
+ u
j 1
) +
w
2h
(u
j +1
u
j 1
) = f
j
_

1
h
2

w
2h
_
. .
a
u
j 1
+
_
2
h
2
_
. .
b
u
j
+
_

1
h
2
+
w
2h
_
. .
c
u
j +1
= f
j
To take care of the boundary conditions The BC u(0) =
gives u
0
= and
a + bu
1
cu
2
= f
0
bu
1
cu
2
= f
0
+ a.
The BC u(1) = gives u
n
= and
au
n2
+ bu
n1
= f
n1
+ c.
96 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Linear system of equations
For j = 1, . . . , n 1,

1
h
2
(u
j +1
2u
j
+ u
j 1
) +
w
2h
(u
j +1
u
j 1
) = f
j
_

1
h
2

w
2h
_
. .
a
u
j 1
+
_
2
h
2
_
. .
b
u
j
+
_

1
h
2
+
w
2h
_
. .
c
u
j +1
= f
j
To take care of the boundary conditions The BC u(0) =
gives u
0
= and
a + bu
1
cu
2
= f
0
bu
1
cu
2
= f
0
+ a.
The BC u(1) = gives u
n
= and
au
n2
+ bu
n1
= f
n1
+ c.
97 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Linear system of equations
Collect all the equations as a linear system.
_

_
b c 0
.
.
.
.
.
.
a b c
.
.
.
.
.
.
0 a b
_

_
_

_
u
1
.
.
.
u
j
.
.
.
u
n1
_

_
=
_

_
f
1
+ a
.
.
.
f
j
.
.
.
f
n1
+ c
_

_
.
Top row comes from left hand boundary condition and the
bottom rows comes from the right boundary condition.
Also note the boundary condition aects the right hand side
vector in top/bottom entry.
In contrast to reaction diusion equation,
the matrix is non-symmetric as a ,= c.
98 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Numerical analysis
HOMEWORK
You can now try Problem 12
1
Is the approximation consistent? If u is smooth,
[T
j
[ Ch
2
, j = 1, 2, . . . , n 1.
In other words, T
j
= O(h
2
).
Proof by Taylors theorem.
2
Is the approximation stable?
99 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Numerical analysis
HOMEWORK
You can now try Problem 12
1
Is the approximation consistent? If u is smooth,
[T
j
[ Ch
2
, j = 1, 2, . . . , n 1.
In other words, T
j
= O(h
2
).
Proof by Taylors theorem.
2
Is the approximation stable?
100 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Numerical analysis
HOMEWORK
You can now try Problem 12
1
Is the approximation consistent? If u is smooth,
[T
j
[ Ch
2
, j = 1, 2, . . . , n 1.
In other words, T
j
= O(h
2
).
Proof by Taylors theorem.
2
Is the approximation stable?
101 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Apply stability theorem
Recall the tridiagonal matrix entries ..
_

1
h
2

w
2h
_
. .
a
u
j 1
+
_
2
h
2
_
. .
b
u
j
+
_

1
h
2
+
w
2h
_
. .
c
u
j +1
= f
j
To show that the approximation is stable we simply need to
check that the tridiagonal coecients satisfy (S).
a 0
1
h
2
+
w
2h
0 (?)
c 0
1
h
2

w
2h
0
b a + c
2
h
2

2
h
2
()
102 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Apply stability theorem
Recall the tridiagonal matrix entries ..
_

1
h
2

w
2h
_
. .
a
u
j 1
+
_
2
h
2
_
. .
b
u
j
+
_

1
h
2
+
w
2h
_
. .
c
u
j +1
= f
j
To show that the approximation is stable we simply need to
check that the tridiagonal coecients satisfy (S).
a 0
1
h
2
+
w
2h
0 (?)
c 0
1
h
2

w
2h
0
b a + c
2
h
2

2
h
2
()
103 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Apply stability theorem
Recall the tridiagonal matrix entries ..
_

1
h
2

w
2h
_
. .
a
u
j 1
+
_
2
h
2
_
. .
b
u
j
+
_

1
h
2
+
w
2h
_
. .
c
u
j +1
= f
j
To show that the approximation is stable we simply need to
check that the tridiagonal coecients satisfy (S).
a 0
1
h
2
+
w
2h
0 (?)
c 0
1
h
2

w
2h
0
b a + c
2
h
2

2
h
2
()
104 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Apply stability theorem
Recall the tridiagonal matrix entries ..
_

1
h
2

w
2h
_
. .
a
u
j 1
+
_
2
h
2
_
. .
b
u
j
+
_

1
h
2
+
w
2h
_
. .
c
u
j +1
= f
j
To show that the approximation is stable we simply need to
check that the tridiagonal coecients satisfy (S).
a 0
1
h
2
+
w
2h
0 (?)
c 0
1
h
2

w
2h
0
b a + c
2
h
2

2
h
2
()
105 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Apply stability theorem
Recall the tridiagonal matrix entries ..
_

1
h
2

w
2h
_
. .
a
u
j 1
+
_
2
h
2
_
. .
b
u
j
+
_

1
h
2
+
w
2h
_
. .
c
u
j +1
= f
j
To show that the approximation is stable we simply need to
check that the tridiagonal coecients satisfy (S).
a 0
1
h
2
+
w
2h
0 (?)
c 0
1
h
2

w
2h
0
b a + c
2
h
2

2
h
2
()
106 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Apply stability theorem
Recall the tridiagonal matrix entries ..
_

1
h
2

w
2h
_
. .
a
u
j 1
+
_
2
h
2
_
. .
b
u
j
+
_

1
h
2
+
w
2h
_
. .
c
u
j +1
= f
j
To show that the approximation is stable we simply need to
check that the tridiagonal coecients satisfy (S).
a 0
1
h
2
+
w
2h
0 (?)
c 0
1
h
2

w
2h
0
b a + c
2
h
2

2
h
2
()
107 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Condition for stability
Assume that w > 0 then
a 0
1
h
2
+
w
2h
0 ()
c 0
1
h
2

w
2h
0 (?)
_

_
The centred approximation method is stable when
1
h
2

w
2h
0

wh
2
1 h
2
w
.
108 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Stability
Assume that w < 0 then
a 0
1
h
2
+
w
2h
0 (?)
c 0
1
h
2

w
2h
0 ()
_

_
Thus, the centred approximation method is stable whenever
1
h
2
+
w
2h
0
wh
2
1 h
2
w
.
We deduce that a sucient condition for stability is that
[w[h
2
1.
The ratio
|w|h
2
is called the mesh Peclet number.
Computationally, if
wh
2
> 1 the centred dierence solution
shows oscillations of period h instability.
109 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Stability
Assume that w < 0 then
a 0
1
h
2
+
w
2h
0 (?)
c 0
1
h
2

w
2h
0 ()
_

_
Thus, the centred approximation method is stable whenever
1
h
2
+
w
2h
0
wh
2
1 h
2
w
.
We deduce that a sucient condition for stability is that
[w[h
2
1.
The ratio
|w|h
2
is called the mesh Peclet number.
Computationally, if
wh
2
> 1 the centred dierence solution
shows oscillations of period h instability.
110 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Stability
Assume that w < 0 then
a 0
1
h
2
+
w
2h
0 (?)
c 0
1
h
2

w
2h
0 ()
_

_
Thus, the centred approximation method is stable whenever
1
h
2
+
w
2h
0
wh
2
1 h
2
w
.
We deduce that a sucient condition for stability is that
[w[h
2
1.
The ratio
|w|h
2
is called the mesh Peclet number.
Computationally, if
wh
2
> 1 the centred dierence solution
shows oscillations of period h instability.
111 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Solution of convection diusion
model with w = 100;
Central dierencing h = 1/n with n = 20
0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1
0
2
4
6
8
10
12
14
16
x
u
Note the oscillation: the exact solution has no oscillation
112 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Alternative method: upwind
nite dierence
Solution of convection with w = 100; h = 1/n with n = 20
0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1
0
2
4
6
8
10
12
x
u
There is no oscillation.
The truncation error for this upwind nite dierecing is O(h)
(rst order) compared to the second order central dierencing
method.
Even though truncation error bigger, the solution is better.
113 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Alternative method: Upwind
nite dierence method
One sided nite dierence approximation:
x
j
h x
j x
j
+h
u(x
j
h)
u(x
j
)
u(x
j
+h)

u(x
j
)
+
u(x
j
)
1
h

u(x
j
) u

(x
j
),
1
h

+
u(x
j
) u

(x
j
),
where

u(x
j
) =u(x
j
) u(x
j
h)

+
u(x
j
) =u(x
j
+ h) u(x
j
).
114 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Upwind method
1
For u

, use the centered dierence: u

(x
j
)
1
h
2

2
u(x
j
)

2
u(x
j
) =[u(x
j
)]
=u(x
j
+ h) 2u(x
j
) + u(x
j
h)
2
For u

, if w > 0, approximate u

(x
j
)
1
h

u(x
j
)
where

u(x
j
) = u(x
j
) u(x
j
h).
or, if w < 0, approximate u

(x
j
)
1
h

+
u(x
j
) where

+
u(x
j
) = u(x
j
+ h) u(x
j
).
Called the upwind dierence approximation to u

(x).
115 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Upwind method
1
For u

, use the centered dierence: u

(x
j
)
1
h
2

2
u(x
j
)

2
u(x
j
) =[u(x
j
)]
=u(x
j
+ h) 2u(x
j
) + u(x
j
h)
2
For u

, if w > 0, approximate u

(x
j
)
1
h

u(x
j
)
where

u(x
j
) = u(x
j
) u(x
j
h).
or, if w < 0, approximate u

(x
j
)
1
h

+
u(x
j
) where

+
u(x
j
) = u(x
j
+ h) u(x
j
).
Called the upwind dierence approximation to u

(x).
116 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Upwind method
1
For u

, use the centered dierence: u

(x
j
)
1
h
2

2
u(x
j
)

2
u(x
j
) =[u(x
j
)]
=u(x
j
+ h) 2u(x
j
) + u(x
j
h)
2
For u

, if w > 0, approximate u

(x
j
)
1
h

u(x
j
)
where

u(x
j
) = u(x
j
) u(x
j
h).
or, if w < 0, approximate u

(x
j
)
1
h

+
u(x
j
) where

+
u(x
j
) = u(x
j
+ h) u(x
j
).
Called the upwind dierence approximation to u

(x).
117 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Linear system of eqns
When w > 0 we obtain

1
h
2
(u
j +1
2u
j
+ u
j 1
) +
w
h
(u
j
u
j 1
) = f
j
_

1
h
2

w
h
_
. .
a
u
j 1
+
_
2
h
2
+
w
h
_
. .
b
u
j
+
_

1
h
2
_
. .
c
u
j +1
= f
j
Apply BCs u(0) = and u(1) = , this the following linear
system
_

_
b c 0
.
.
.
.
.
.
a b c
.
.
.
.
.
.
0 a b
_

_
_

_
u
1
.
.
.
u
j
.
.
.
u
n1
_

_
=
_

_
f
1
+ a
.
.
.
f
j
.
.
.
f
n1
+ c
_

_
.
118 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Consistency and Stability for
upwind
HOMEWORK
You can now try Problem 13
1
You show upwind method is 1st order consistentTaylor
expansions.
2
And the method is stable independent of h.
We know
consistent + stable convergent
Hence the global error
or the error in approximating true solution u(x) is
[u(x
j
) u
j
[ = O(h).
119 / 120
Part III
20401
Uniqueness
for reaction
diusion
model
Stability for
diusion
model
Finite
dierences
Numerical
analysis
Finite
dierences for
convection
diusion
model
Consistency and Stability for
upwind
HOMEWORK
You can now try Problem 13
1
You show upwind method is 1st order consistentTaylor
expansions.
2
And the method is stable independent of h.
We know
consistent + stable convergent
Hence the global error
or the error in approximating true solution u(x) is
[u(x
j
) u
j
[ = O(h).
120 / 120

Vous aimerez peut-être aussi