Professional Documents
Culture Documents
(b) (i) Compute backward difference approximation and central difference approximation for the
first derivative of f ( x) 1/ ln( x) at x 5 using a value of x 1 .
(ii) Calculate the percentage relative errors for each approximation by comparing with the
exact solution and discuss your results. What would you suggest to decrease the error in
both approximations?
The exact solution is: f (5) 0.0772
(c) (i) Integrate the following function using the trapezoidal rule and Simpson's 1/3 rule with n =4
4
0
(1 e x ) dx
(ii) Compute the percentage relative errors with respect to the true value of 3.0183 and discuss
the differences you obtained in your results. What can be done to improve the accuracy of
your solution in the case of trapezoidal rule? Which order polynomials can be exactly
represented by trapezoidal rule and Simpson's 1/3 rule?
1
Question 2 (20 marks)
Answer in a separate book marked Question 2.
y t 2 y ; y (0) 1
at t=0.4
(ii) Compare the results with the exact solution y(t ) et t 2 2t 2 and find the percentage
errors for the results obtained in (i).
(iii) How could you improve your solution by using the same method? Which another method
can you suggest to improve your result and why?
(ii) Verify that the function x(t ) 4e3t 8te3t is the solution.
2
Question 3 (20 marks)
Answer in a separate book marked Question 3.
For a fin with a constant cross section, the governing equation for the heat transfer is given by
d 2
kA hP 0
dx 2
where T T .
(a) Divide the fin into N equal parts and write the finite difference form of the equation above that
relates the temperature inside of the fin at node i, Ti, to the temperatures at the neighboring
nodes using the central-difference formula.
(b) Using the boundary conditions 0 =10 and N=1 write the coefficients Ai, Bi, Ci and Di to
obtain the system of linear equations for all interior points
(c) Express the system of equations in matrix form and discuss which method you can use for
solving this system of equations without solving it.