Information Technology Reference
In-Depth Information
FIGURE 8.2
Notation for derivation of difference expressions.
determined such that
u
=
u
k
−
1
for
x
=
x
k
−
h
u
=
u
k
for
x
=
x
k
u
=
u
k
+
1
for
x
=
x
k
+
h
Apply these conditions to the polynomial and obtain
u
k
+
(
u
k
+
1
−
u
k
−
1
)
x
k
)
+
(
u
k
−
1
−
2
u
k
+
u
k
+
1
)
2
u
=
(
x
−
(
x
−
x
k
)
(8.3a)
2
h
2
h
2
with derivatives
u
=
(
u
k
+
1
−
u
k
−
1
)
+
(
u
k
−
1
−
2
u
k
+
u
k
+
1
)
(
x
−
x
k
)
(8.3b)
2
h
h
2
u
=
(
u
k
−
1
−
2
u
k
+
u
k
+
1
)
(8.3c)
h
2
By prescribing a value for
x,
Eqs. (8.3b and c) provide the first and second derivatives at
any point along the polynomial.
As an example, let
x
=
x
k
to obtain
1
2
h
(
−
u
k
=
u
k
−
1
+
u
k
+
1
)
(8.4)
1
h
2
(
u
k
=
u
k
−
1
−
2
u
k
+
u
k
+
1
)
These are the
central difference approximations
for
u
and
u
. These are referred to as second
order because of the use of the second order polynomial and also because of the truncation
error present. A measure of the errors associated with the finite difference technique is
considered in the following section.
To establish
forward difference formulas,
set
x
=
x
k
−
1
in Eqs. (8.3b and c)
1
2
h
(
−
u
k
−
1
=
+
−
)
3
u
k
−
1
4
u
k
u
k
+
1
1
h
2
(
u
k
−
1
=
u
k
−
1
−
2
u
k
+
u
k
+
1
)
Or if
k
−
1 is shifted to
k,
these become
1
2
h
(
−
u
k
=
3
u
k
+
4
u
k
+
1
−
u
k
+
2
)
(8.5)
1
h
2
(
u
k
=
u
k
−
2
u
k
+
1
+
u
k
+
2
)
These are the usual second order forward difference formulas.
Search WWH ::
Custom Search