Example
1. Consider the heat equation
where
. The
length of the rod is
. Assume
that the ends of the rod are held at the
temperature
. Assume
that the initial temperature distribution is
.
Apply the forward difference method with
and obtain
temperature distributions for
.
We will use
. This forces
.
Solution 1.
Now set up the table of solutions.
Next, solve it.
![[Graphics:../Images/CrankNicolsonMod_gr_30.gif]](../Images/CrankNicolsonMod_gr_30.gif)
To see the numerical values enter the command:
![[Graphics:../Images/CrankNicolsonMod_gr_42.gif]](../Images/CrankNicolsonMod_gr_42.gif)
(c) John H. Mathews 2004