Download as pdf or txt
Download as pdf or txt
You are on page 1of 1

Cairo University Faculty of Engineering

Mechanical Engineering Spring 2021


MTH 2134 Part II Numerical Analysis

Assignment 1
Errors

1. a) Evaluate the polynomial 𝒚 = 𝒙𝟑 − 𝟕𝒙𝟐 + 𝟖𝒙 − 𝟎. 𝟑𝟓 at = 𝟏. 𝟑𝟕 . Use 3-digits


arithmetic with chopping, evaluate the percentage of true error.

b) Repeat by expressing y as: 𝒚 = ((𝒙 − 𝟕)𝒙 + 𝟖)𝒙 − 𝟎. 𝟑𝟓. Evaluate the error and
compare with part (a)
1
2. Use the following series f ( x )   1  x  x 2  x 3  x 4  ..... to
1 x
evaluate (0.9) with  S  0.5 x102% .
1

3. Use zero-through fourth order Taylor series expansions to predict 𝒇(𝟐. 𝟓) for:
𝒇(𝒙) = 𝐥𝐧 𝒙 , using a base point at 𝒙 = 𝟏. Compute the true percentage of relative
error for each approximation. Discuss the meaning of your results.

4. Use the finite difference formula


f ( x i  1 )  2 f ( x i )  f ( x i 1 )
f ( x )   O( h 2 )
h2
to evaluate f (1.6) by the following table with
(a) h = 0.2 (b) h = 0.4 Compare the results.

x 1.2 1.4 1.6 1.8 2


f(x) 2.572 5.798 -34.233 -4.286 -2.185

5. Use the finite difference formula


f ( x i  2 )  2 f ( x i 1 )  f ( x i ) 
f ( x i )  2
 O( h 2 ) to evaluate f ( ) for
h 3
f ( x )  sin x with: (a) h = 0.4 Calculate  t
2
(b) h = 0.2 (c) h = 0.1.

𝒇(𝒙 )−𝟐𝒇(𝒙 )+𝟐𝒇(𝒙 )−𝒇(𝒙 )


6. Use 𝒇′′′ (𝒙𝒊 ) = 𝒊+𝟐 𝒊+𝟏 𝒊−𝟏 𝒊−𝟐
+ 𝑶(𝒉𝟐 ) , to find 𝒇′′′ (𝟎. 𝟓) with 𝒉𝒎𝒊𝒏 =
𝟐𝒉𝟑
𝟎. 𝟎𝟓 for 𝒇(𝒙) = 𝐬𝐢𝐧(𝐜𝐨𝐬 𝒙). Find the percentage of true error

You might also like