Presentation is loading. Please wait.

Presentation is loading. Please wait.

Lecture Notes Dr. Rakhmad Arief Siregar Universiti Malaysia Perlis

Similar presentations


Presentation on theme: "Lecture Notes Dr. Rakhmad Arief Siregar Universiti Malaysia Perlis"— Presentation transcript:

1 Lecture Notes Dr. Rakhmad Arief Siregar Universiti Malaysia Perlis
Chapter 6 Open Methods Lecture Notes Dr. Rakhmad Arief Siregar Universiti Malaysia Perlis Applied Numerical Method for Engineers

2

3 Review of previous method
In the previous chapter, the root is located within an interval Lower bound Upper bound Repeated application if these methods always result in closer estimates of true value of the root These methods are said to be CONVERGENT because they move closer to the truth as computation progresses

4 Open Methods In contrast, the open methods are based on formulas that require only a single or two of x. Do not bracket the root. It is called as diverge or move away from the true root as the computation progresses. Fig (b) However, when it is converge (Fig. c), they do not so much more quickly than the bracketing method

5 Simple Fixed-Point Iteration
This method also called as, simple fixed-point iteration, or one point iteration or successive substitution method Open methods employ formula to predict the root. The formula can be developed by rearranging the function f(x) = 0 so that x is on the left-hand side of the equation: Example: can be rearranged to:

6 Simple Fixed-Point Iteration
The utility of is to provides a formula to predict a new value of x as function of an old value of x Thus given an initial guess at the root xi, it can be used to compute a new estimate xi+1 as expressed by the iterative formula: Thus the approximation error (as in the previous chapters) can be calculated as

7 Ex. 6.1 Simple Fixed-Point Iteration
Use simple fixed-point iteration to locate the root of Solution The function can be separated directly and expressed in the form of With an initial guess of x0 =0, then the iterative equation can be calculated as

8 Ex. 6.1 Simple Fixed-Point Iteration
an initial guess of x0 =0, true root:

9 Convergence Why this result can be called as convergence?
Reading assignment: Read section pp. 135

10 Ex. 6.2 Two-curve graphical method
Separate the equation into two parts and determine its root graphically Solution Reformulate the equation as: and

11 In graphical methods The intersection of the two curves indicates a root estimate of approximately x =0.57

12 Exercise Use simple fixed-point iteration to locate the root of
Use an initial guess of x0 = 0.5

13 Solution The first iteration is

14 Solution The remaining iterations are

15 The Newton-Raphson Methods
The most widely used of all root-locating formula is the Newton-Raphson equation. If the initial guess at the root is xi, a tangent can be extended from the point [xi, f(xi)] The point where this tangent crosses the x axis usually represents an improved estimate of the root.

16 The Newton-Raphson Methods
The Newton-Raphson method can be derived on the basis of this geometrical interpretation The first derivative at x is equivalent to the slope: which can be rearranged to yield

17 Ex. 6.3 Newton-Raphson Method
Use the Newton-Raphson method to estimate the root of Employing an initial guess of x0 = 0 Solution The first derivative of the function can be evaluated as Which can be substituted along with the original function

18 Ex. 6.3 Newton-Raphson Method
Starting with an initial guess of x0 = 0, this iterative equation can be applied to compute: The approach rapidly converges on the true root. Faster that by using simple fixed-point iteration

19 Termination Criteria and Error Estimates
The approximate percent relative error can also be used as a termination criterion. Other criteria can also be obtained such as discussed in Example 6.4

20 Pitfalls of the Newton-Raphson Method
Although the Newton-Raphson method is often very efficient, there are situations where it performs poorly. A special case – multiple roots – will be addressed later However, even when dealing with simple roots, difficulties can also arise, as in the following example

21 Ex. 6.5 Slowly Converging Function with Newton-Raphson
Determine the positive root of f(x) = using the Newton-Raphson method and an initial guess of x = 0.5 Solution The Newton-Raphson formula for this case is Which can be used to compute:

22 Iteration results

23 Pitfalls of the Newton-Raphson Method

24 Pitfalls of the Newton-Raphson Method

25 The Secant Method A potential problem in implementing the Newton-Raphson method is the evaluation of the derivative. For polynomials and many other function this is not convenient There are certain function the derivative may be extremely difficult or inconvenient to evaluate

26 The Secant Method For these cases, the derivative can be approximated by a backward finite divided difference The secant method can be formulated as:

27 Graphical depiction of the secant method

28 Ex. 6.6 Use the secant method to estimate the root of f(x) = e-x – x. Start with the estimates of xi-1 = 0 and x0 = 1.0. Solution (true root = …) First iteration Xi-1 = f(xi-1)=1.0 X0 = f(x0) = Calculate t = 8.0%

29 Ex. 6.6 Solution (true root = 0.56714329…) Second iteration
X0 = f(x0)= X1 = f(x1) =

30 Ex. 6.6 Solution (true root = 0.56714329…) Third iteration
X0 = f(x1)= X1 = f(x1) =

31 Ex. 6.6x Use the secant method to estimate the root of f(x) = e-x – 2x. Start with the estimates of xi-1 = 0 and x0 = 1.0. Solution (true root = xxxx) First iteration Xi-1 = f(xi-1)=xx X0 = f(x0) = xxxx Calculate t = 8.0%

32 Next week Reading assignment: Read pp. 146 – 157 Read pp. 160 – 174

33 Quiz (60 Minutes) What do you know about mathematical model in solving engineering problem? (10 marks) Use zero through third order Taylor series expansions to predict f(2.5) for f(x) = ln x using a base point at x = 1. Compute the true percent relative error for each approximation. (15 marks) Determine the real root of f(x)= 5x3-5x2+6x-2 using bisection method. Employ initial guesses of xl = 0 and xu = 1. iterate until the estimated error a falls below a level of s = 15% (20 marks)

34 The difference between the Secant and False-Position Methods
Similarity of Secant and False-Position Methods The approximate root equation are identical on a term by term basis Both of them use two initial estimates to compute an approximation of the slope. Critical difference: How in both methods the new estimate replaces the initial value False Position Method Secant Method

35

36 The false-position method
Ex. 6.7 Use the false-position and secant methods to estimate the root of f(x) = ln x. Start the computation with value of xl = xi-1 = 0.5 xu = xi = 5.0 Solution The false-position method The secant method

37

38 Modified Secant Method
Original Secant Method Modified Secant Method

39 Ex. 6.8 Use the secant method to estimate the root of f(x) = e-x – x. Use a value of 0.01 for  and start with x0 = 1.0. Solution (true root = …) First iteration x0 = f(x0) = x1+ x0 = f(x1+ x0) = Calculate t = 5.3%

40 Ex. 6.8 Solution (true root = 0.56714329…) Second iteration
x0 = f(x0) = x1+ x0 = f(x1+ x0) = Calculate t = %

41 Ex. 6.8 Solution (true root = 0.56714329…) Third iteration
x0 = f(x0) = x1+ x0 = f(x1+ x0) = Calculate t = 2.365x10-5 %

42 Multiple Roots

43 Multiple Roots

44 Modified Newton-Raphson
A modifications have been proposed by Ralston and Rabinowitz (1978) Original Newton-Raphson Modified Newton-Raphson

45 Ex. 6.9 Original Newton-Raphson Use both the standard ad modified Newton-Raphson methods to evaluate the multiple root of f(x) = (x-3)(x-1)(x-1) with initial guess of x0 = 0. Solution (true value: 1.0) First derivative: f’(x) = 3x2 - 10x + 7 Second derivative f’’(x) = 6x - 10 Modified Newton-Raphson

46 Original Newton-Raphson Method

47 Modified Newton-Raphson Method

48 Ex. 6.9 For both methods to search for single root at x = 3 using initial guess of x0 = 4 Both methods converge quickly, with the standard method being somewhat more efficient

49 Modified secant method
For multiple root secant method can be modified as:

50 System of Nonlinear Equations
We have discussed on the determination of roots of single equation How about locating roots of a set of simultaneous equations Nonlinear equations is algebraic and transcendental equations that do not fit following format

51 By Fixed-Point Iteration
Non linear equations: Two simultaneous nonlinear equation with two unknown, x and y.

52 6.10 Use fixed-point iteration to determine the root of Eq. (6.16). Note that a correct pair of roots is x = 2 and y = 3. Initiate the computation with guesses of the x = 1.5 and y = 3.5. Solution

53 6.10 Solution On the basis of the initial value x = 1.5 and y = 3.5

54 6.10 Solution On the basis of the initial value x = 1.5 and y = 3.5

55 6.10 Solution On the basis of the initial value x = 1.5 and y = 3.5

56 6.10

57 By Newton-Raphson

58 Assignment Solve problem 6.2


Download ppt "Lecture Notes Dr. Rakhmad Arief Siregar Universiti Malaysia Perlis"

Similar presentations


Ads by Google