Top Banner
Other examples, figures, tables and equations mentioned in the main example, are included for reference in this and following pages
4

Other examples, figures, tables and equations mentioned in ...

Apr 14, 2022

Download

Documents

dariahiddleston
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: Other examples, figures, tables and equations mentioned in ...

Other examples, figures, tables and equations mentioned in the main example, are included for referencein this and following pages

Page 2: Other examples, figures, tables and equations mentioned in ...
Page 3: Other examples, figures, tables and equations mentioned in ...

Modified Statement for Example 6.2 (as it may appear in exams)

Consider the following function:

where is the independent variable

As you learned in class, the Newton-Raphson method for computing the root of a function, , allows to estimate the next ‘guess’ value for the root, , based on the previous ‘guess’ value, , with the following equation:

For the function given above, and the derivative of the function that you are required to compute, perform 3 iterations of the Newton-Raphson method to estimate the root. Assume an initial guess value = 0. For each of the 3 iterations, compute the true relative error (assume that the exact value of the root is 0.5671433) and the approximate relative error .

Note: -You are expected to know how to compute the derivative ′ of the given function to implement the Newton-Raphson method, so the derivative will not be given in exams. -No equations to compute the errors and will be provided in exams. You are expected to remember the equations to compute these errors.

Page 4: Other examples, figures, tables and equations mentioned in ...

Solution of Example 6.2 (with modified statement as it may appear in exams)

Given function

f x( ) ex

x

First derivative of given function

der_f x( ) ex

1

x_new x_old( ) x_oldf x_old( )

der_f x_old( ) <-- this is equation (6.6) in the textbook

x_sol 0.5671433 <-- root solution (given in problem statement)

x_0 0 <-- initial guess value (given in problem statement)

εt_0x_sol x_0

x_sol

εt_0 100 %

Iteration #1

x_1 x_new x_0( ) 0.5 Note that in the software MATCHAD used to type this document,

x_new x_0( ) 0.5

gives the same result as

x_0e

x_0x_0

ex_0

1 0.5

εt_1x_sol x_1

x_sol

εa_1x_1 x_0

x_1

εt_1 11.8389 % εa_1 100 %

Iteration #2

x_2 x_new x_1( ) 0.5663

εt_2x_sol x_2

x_sol εa_2

x_2 x_1

x_2

εa_2 11.7093 %εt_2 0.1468 %

Iteration #3

x_3 x_new x_2( ) 0.5671

εt_3x_sol x_3

x_sol εa_3

x_3 x_2

x_3

εa_3 0.1467 %εt_3 2.3797 10

5 %