Professional Documents
Culture Documents
Solutions, Chapter 20
Solutions, Chapter 20
______________________________________________________________________
20.1 Example 20.1 shows the values for x = 0.25. The others are done on a
spreadsheet. For x = 0.1, the values of the function at x = 0.4 and 0.6 are 0.3744 and
0.4704. Thus we have
dy
y
0.4704 0.4375
= 0.329
forward =
dx at n x difference
0.60 0.50
dy
y
0.4375 0.3744
backward =
= 0.631
dx at n x difference
0.5 0.4
y
y
forward + backward
x difference x difference 0.329 + 0.631
dy
y
central =
=
= 0.480
dx at n x
2
2
difference
and
d 2 y
0.329 0.631
2 =
= 3.02
0.1
dx at n
For x = 0.01, the values of the function at x = 0.49 and 0.51 are 0.43235 and 0.44235.
Substituting those values in the above formulae produces the results shown in Table 20.1.
The spreadsheet carries more digits than are shown here, so if you check these
calculations you may get slightly different results, due to round off error.
______________________________________________________________________
20.2 This was done on the same spreadsheet used to prepare Ex. 20.1 and to solve Prob
20.1. At x = 1 and 0.75, the values of the function are 0.00 and 0.4335. Thus, for the
dy
y
0.00 0.4335
first value we have
=
= 1.734 Proceeding the
dx at n x forward
1.00 0.75
difference
same way we make up the equivalent of Table 20.1,
Revised Table 20.1 Comparison of Numerical Estimates of First and Second
Derivatives in Ex. 20.1 at x = 0.75.
(d
-0.6875
-6.75
y / dx
at x = 0.75
-6.875
Forward
-1.734
Backward
-0.0158
Solutions, Fluid Mechanics for Chemical Engineers, Third Edition, Chapter 20, page 1
Central
-0.875
-6.755
Forward
-0.864
Backward
-0.526
Central
-0.695
-36.7502
Forward
-0.7215
Backward
-0.6540
Central
-0.6878
______________________________________________________________________
20.3 At 40=0.698 radians, sin x = 0.6428, and at 50=0.8726 radians, sin x = 0.7660.
At 40=0.698 radians, dy / dx = cos x = 0.7660 and d 2 y / dx 2 = sin x = 0.6428 The
first entry in the table is
dy
y
0.8727 0.6981
forward =
= 0.7062
dx at n x difference 0.7660 0.6427
The rest of the table is shown below
Table 20.1 Comparison of Numerical Estimates of First and Second Derivatives in
for y = sin x, at 40
(dy / dx )at x = 40
(d
0.7660
-0.6428
y / dx 2 )at x = 40
-0.6411
Forward
0.7062
Backward
0.8181
Central
0.7621
-6428
Forward
0.7604
Backward
0.7716
Central
0.7760
______________________________________________________________________
Solutions, Fluid Mechanics for Chemical Engineers, Third Edition, Chapter 20, page 2
20.4 The i subscript is in the x direction and the j subscript is in the y direction, so that
2 z
2z
z(i +1, j) 2zi , j z(i1, j)
z
2zi, j z(i, j 1)
2
=
= (i, j+1)
and
2
2
2
x at i , j
y at i, j
(x (i , j ) x (i 1, j) )
(y(i, j) y(i, j 1) )
______________________________________________________________________
20.5 (a) The spreadsheet is as shown in the problem. (b) The results are as shown in
Table 20.2. (c) Switching the time interval makes the results closer to the analytical
solution. The table below shows compares the values at x = 0.01 for the two solutions
and also shows the analytical solution.
Time, s
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
For all times the numerical solution with 1 s intervals is a closer approximation of the
analytical solution than the solution with 2 s intervals. Using smaller intervals would
make the approximation better, at the cost of more computing. (Nowadays computing is
pretty cheap!).
______________________________________________________________________
0.01 ft
= 0.48179
2
2 t
5 ft
2 1.077 10
20 s
s
From the spreadsheet NORMSDIST (0.48179) = 0.68052
20.6
2 z = 2
= 2
Solutions, Fluid Mechanics for Chemical Engineers, Third Edition, Chapter 20, page 3
ft
ft
0.37005 = 3.1498
s
s
______________________________________________________________________
Vx = 5
20.7 The resulting spreadsheet is shown below. We see overshoot and oscillation at all
locations, with the magnitude of the oscillations increasing with time, and the values
swinging from positive to negative.
time,
s
y, ft, 0
0.01
0.02
0.03
0.04
0.05
0.06
0
0.01
0.02
0.03
0.04
0.05
0.06
0
5
0
0
0
0
0
0
0.01
5
5.39
0.
0.
0.
0.
0.
0.02
5
-0.83
5.80
0.
0.
0.
0.
0.03
5
12.59
-7.59
6.25
0.
0.
0.
0.04
5
-17.31
29.04
-15.38
6.73
0.
0.
0.05
5
56.64
-68.72
56.27
-24.33
7.25
0.
0.06
5 -133.98
200.90
-165.14
96.47
-34.56
7.80
0.07
5
376.37 -553.99
510.84 -326.41
152.19
-46.23
0.08
5 -1025.60 1594.83
-1537.70 1090.75 -576.95
217.25
0.09
5 2906.56 -4601.11
4666.88 -3536.21 2074.52 -872.08
0.1
5 -8304.18 13466.28 -14149.47 11341.27 -7141.72 3240.64
______________________________________________________________________
Solutions, Fluid Mechanics for Chemical Engineers, Third Edition, Chapter 20, page 4