CE 5143 Homework 7 Due 11/8/07

David Wagner 2007/11/08 16:35

Problem 1

Forward Differences

Δx 0.05 Forward Differences Error from exact value
i xi f(xi) f'(x) f`'(x) f'(x)-ex f`'(x)-ex
1 2.00 7.3891 7.5760 7.8000 0.1869 0.4109
2 2.05 7.7679 7.9660 8.1600 0.1981 0.3921
3 2.10 8.1662 8.3740 8.5600 0.2078 0.3938
4 2.15 8.5849 8.8020 9.0400 0.2171 0.4551
5 2.20 9.0250 9.2540 9.5200 0.2290 0.4950
6 2.25 9.4877 9.7300 10.1200 0.2423 0.6323
7 2.30 9.9742 10.2360 0.2618
8 2.35 10.4860

Backward Differences

Δx 0.05 Backward Differences Error from exact value
i xi f(xi) f'(x) f`'(x) f'(x)-ex f`'(x)-ex
1 2.00 7.3891
2 2.05 7.7679 7.5760 -0.1919
3 2.10 8.1662 7.9660 7.8000 -0.2002 -0.3662
4 2.15 8.5849 8.3740 8.1600 -0.2109 -0.4249
5 2.20 9.0250 8.8020 8.5600 -0.2230 -0.4650
6 2.25 9.4877 9.2540 9.0400 -0.2337 -0.4477
7 2.30 9.9742 9.7300 9.5200 -0.2442 -0.4542
8 2.35 10.4860 10.2360 10.1200 -0.2496 -0.3656

Central Differences

Δx 0.05 Central Differences Error from exact value
i xi f(xi) f'(x) f`'(x) f'(x)-ex f`'(x)-ex
1 2.00 7.3891
2 2.05 7.7679 7.7710 7.8000 0.0031 0.0321
3 2.10 8.1662 8.1700 8.1600 0.0038 -0.0062
4 2.15 8.5849 8.5880 8.5600 0.0031 -0.0249
5 2.20 9.0250 9.0280 9.0400 0.0030 0.0150
6 2.25 9.4877 9.4920 9.5200 0.0043 0.0323
7 2.30 9.9742 9.9830 10.1200 0.0088 0.1458
8 2.35 10.4860

Problem 2

Text problem 7.9

i t Δt h(t) h'(x)={h_{i+1}-h_{i-1}}/{Delta t_{i}+Delta t_{i+1}}
1 0.20 445.98
2 0.30 0.10 471.85 273.7143
3 0.41 0.11 503.46

Problem 3

  • y'(i)={3y_{i}-4y_{i-1}+y_{i-2}}/{2 Delta x}
  • y'`'(i)={2y_{i}-5y_{i-1}+4y_{i-2}-y_{i-3}}/{ Delta x^2}
  • y'`'`(i)={5y_{i}-18y_{i-1}+24y_{i-2}-14y_{i-3}+3y_{i-4}}/{2*( Delta x)^3}
Δi 0.05Displacement Velocity Accleration Jerk
i ti yi y'(i) y'`'(i) y'`'`(i)
1 0.05 0.144
2 0.10 0.172
3 0.15 0.213 0.95
4 0.20 0.296 2.08 28.4
5 0.25 0.070 -7.61 -264.0 -9096
6 0.30 0.085 2.71 316.4 13148
7 0.35 0.525 13.05 243.6 -5476
8 0.40 0.110 -16.85 -854.0 -31360
9 0.45 0.062 2.71 635.6 38960

Problem 4

Text problem 7.21 Evaluate the following partial derivatives of the function f(x,y)=2x^4y^3 using cetnral differences at x=1 and y=1 with the step size Δx=Δy=0.1:

f(x,y)
0.9 1.0 1.1
0.9 0.9566 1.4580 2.1347
1.0 1.3122 2.0000 2.9282
1.1 1.7465 2.6620 3.8974

(a){partial^2 f}/{partial x^2} approx {f(x_i +Delta x,y_j)-2f(x_i,y_i)+f(x_i -Delta x,y_j)}/{(Delta x)^2} = {2.9282-2*2.0000+1.3122}/{0.1^2} =24.04

(b){partial^2 f}/{partial y^2} approx {2.6620-2*2.0000+1.4580}/{0.1^2} =12

©{partial^2 f}/{partial x partial y} approx {3.8974 -2.1347 -1.7465 + 0.9566}/{4*0.1*0.1} =24.32


Personal Tools