Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

I ONLY NEED PART B AND C FOR THIS PROBLEM!! Need help!! Please provide a step-by-step solution through the use of MALAB code along with

I ONLY NEED PART B AND C FOR THIS PROBLEM!!

image text in transcribed

Need help!! Please provide a step-by-step solution through the use of MALAB code along with a detailed explanation!!!! It is alright if you handwrite the step-by-step solution but I would prefer the solution to be shown in MATLAB code. This is very URGENT!!! PLEASE reply as soon as possible!! Thank you!!

Problem 4. In this problem you will study the effects of computer roundoff on finite differences. A floating-point number fl(x) in the computer satisfies where e is known as machine precision. In MATLAB its value is assigned to eps by default. It is well known that subtraction of nearby values causes cancellation error and is numerically il conditioned (a) Suppose f is twice differentiable. Show that the error f(r + h) - f(x) fl(f(x +h)) - fl(f(z) in forward difference is proportional to c/h in the worst case as h 0. b) Find big-O relationship (such as h = 0(e)) that minimizes the sum of the floating point error and the leading order truncation error for the first-order forward difference. Use this to predict the minimal error (again as a power of e) achievable by the method in floating point. (c) Generalize (a)-(b) for equispaced FD methods of order p. Do higher order methods improve the minimal error? (d) Do a MATLAB experiment using f(x) = tan(x), computing FD approximations to f(+/3) for orders 1, 2, 4. and 6. Choose about a hundred logarithmically spaced values of h from 10-1 to 10-14, and show the errors on a log-log graph. Extract the minima of these curves numerically or graphically and confirm the result of (c). Problem 4. In this problem you will study the effects of computer roundoff on finite differences. A floating-point number fl(x) in the computer satisfies where e is known as machine precision. In MATLAB its value is assigned to eps by default. It is well known that subtraction of nearby values causes cancellation error and is numerically il conditioned (a) Suppose f is twice differentiable. Show that the error f(r + h) - f(x) fl(f(x +h)) - fl(f(z) in forward difference is proportional to c/h in the worst case as h 0. b) Find big-O relationship (such as h = 0(e)) that minimizes the sum of the floating point error and the leading order truncation error for the first-order forward difference. Use this to predict the minimal error (again as a power of e) achievable by the method in floating point. (c) Generalize (a)-(b) for equispaced FD methods of order p. Do higher order methods improve the minimal error? (d) Do a MATLAB experiment using f(x) = tan(x), computing FD approximations to f(+/3) for orders 1, 2, 4. and 6. Choose about a hundred logarithmically spaced values of h from 10-1 to 10-14, and show the errors on a log-log graph. Extract the minima of these curves numerically or graphically and confirm the result of (c)

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Machine Learning And Knowledge Discovery In Databases European Conference Ecml Pkdd 2018 Dublin Ireland September 10 14 2018 Proceedings Part 1 Lnai 11051

Authors: Michele Berlingerio ,Francesco Bonchi ,Thomas Gartner ,Neil Hurley ,Georgiana Ifrim

1st Edition

3030109240, 978-3030109240

More Books

Students also viewed these Databases questions

Question

What are the stages of project management? Write it in items.

Answered: 1 week ago

Question

why do consumers often fail to seek out higher yields on deposits ?

Answered: 1 week ago

Question

Develop skills for building positive relationships.

Answered: 1 week ago

Question

Describe techniques for resolving conflicts.

Answered: 1 week ago

Question

Give feedback effectively and receive it appropriately.

Answered: 1 week ago