Question: I need help with this question please, I am taking numerical methods course. Problem 4 (25 points) The hyperbolic cosine of the argument x given

I need help with this question please, I am taking numerical methods course.

Problem 4 (25 points) The hyperbolic cosine of the argument x given

Problem 4 (25 points) The hyperbolic cosine of the argument x given in radians can be calculated by the series - n=1 cosh(x) = 1 + x2n (2n)! x 7:6 = 1+ + + 2! 4! 6! (1) a) Write a Matlab function myCosh that takes as input x and the number of terms N to use to estimate cosh (x), i.e., N +.... 2n (2n)! n=1 and outputs the estimate for cosh(x) together with the corresponding true relative error. You may use the Matlab function factorial () to calculate the factorial in the formula. For the true value of cosh(x) use Matlab's build-in function cosh(x). cosh(x) 1+ " b) Use the function to calculate the estimate for cosh (20) and the true relative error for i) N = 5, ii) N = 20, iii) N = 30. c) In a semilogarithmic plot (use semilogy()), plot the absolute of the relative error vs. N for N = 1... 40. d) Explain why the absolute of the relative error does not decrease for N > 32. Problem 4 required submission: Softcopy printout of well commented function you included in your Gradescope submission Softcopy printout of the results of calling your function for b) i)- iii) using format long Annotated semilogarithmic plot of absolute relative error us. N for N = 1... 40. Explanation why the absolute of the relative error does not decrease for N > 32. Upload of your Matlab functions and scripts to the Homework 1 link on Canvas (2)

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!