Question: Taylor series The sinh function can be evaluated by the following infinite X3 X5 sinhx = x + 3! 5! (a) Write a function

Taylor series The sinh function can be evaluated by the following infinite

Taylor series The sinh function can be evaluated by the following infinite X3 X5 sinhx = x + 3! 5! (a) Write a function that needs as an input the value of x and the acceptable true percent error from the user and then it calculates sinh(x) using the above series until the acceptable error is satisfied. Make sure that the function does the following: i. ii. stores the true percent relative error for each number of terms taken from the series in an array. plots the true percent relative error as a function of the number terms. Make sure to label the x- axis, the y-axis and to add a legend. The plot has to be logarithmic on both x and y axes (i.c. log- log plot which can be done by using loglog instead of plot) iii. times itself using tic; toc: (b) Run the function for the case x = 1 and with acceptable error of 10-13 %. Report the final plot, and the time of the calculation (using tic toc). (c) From your log-log plot in part (b), how many terms are enough to reach percent relative error less than 10% %.

Step by Step Solution

3.51 Rating (174 Votes )

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

Answer Matlab function file function sinhxsinehypxet tic ... View full answer

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 Accounting Questions!