Question: Relative error We say that the relative error in a numerical algorithm f(x) that approximates f(x) is F(x) f(x) f(x) rel_error(x, k) = abs(myexp(x, k)

 Relative error We say that the relative error in a numerical

Relative error We say that the relative error in a numerical algorithm f(x) that approximates f(x) is \F(x) f(x) f(x) rel_error(x, k) = abs(myexp(x, k) - exp(x)) / exp(x) rel_error(1, 20) # Plot the relative error in myexp(1, k) as k increases plot (ks, k-> rel_error(1, k), xscaler: log10, yscaler: log10) # Plot the relative error in myexp(20, k) as k increases plot (ks, k -> rel_error(20, k), xscale= log10, yscale=: log10) Plot the relative error in myexp(-20, k) as k increases # YOUR CODE HERE error("No answer given.")

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!