03pmn_2014

September 21, 2017 | Author: IGede Tirta Nata | Category: Computer Programming, Applied Mathematics, Algorithms And Data Structures, Mathematical Analysis, Mathematics
Share Embed Donate


Short Description

Download 03pmn_2014...

Description

Pemodelan dan Metode Numerik (Modeling and Numerical Methods) http://www.unhas.ac.id/amil/S2TE/pmn_2014/

L #3 Open Methods Amil Ahmad Ilham

Open Method • Bracketing methods: – The root is located within an interval prescribed by a lower and an upper bound. – Repeated application of these methods always results in closer estimates of the true value of the root. Such methods are said to be convergent because they move closer to the truth as the computation progresses .

• Open methods: – are based on formulas that require only a single starting value of x or two starting values that do not necessarily bracket the root. – they sometimes diverge or move away from the true root as the computation progresses. – When the open methods converge, they usually do so much more quickly than the bracketing methods. 2

Bracketing vs. Open Method •





The fundamental difference between the (a) bracketing and (b) and (c) open methods for root location. In (a), which is the bisection method, the root is constrained within the interval prescribed by xl and xu. The open method depicted in (b) and (c), a formula is used to project from xi to xi+1 in an iterative fashion. • The method can either (b) diverge or (c) converge rapidly, depending on the value of the initial guess.

3

SIMPLE FIXED-POINT ITERATION • A simple fixed-point iteration (one-point iteration or successive substitution): – rearranging the function f (x) = 0 so that x is on the left-hand side of the equation:

• Given an initial guess at the root xi, a new estimate xi+1 is expressed by the iterative formula: 4

SIMPLE FIXED-POINT ITERATION • f (x) = 0 => x = g(x) • Example: =>

• xi+1 = g(xi) 2

xi + 3 xi +1 = 2 5

SIMPLE FIXED-POINT ITERATION • Use simple fixed-point iteration to locate the root of f(x) = e−x − x. Starting with an initial guess of x0 = 0.

x=e

−x

x i +1 = e − xi

6

THE NEWTON-RAPHSON METHOD • The most widely used of all root-locating formulas is the NewtonRaphson 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.

=> 7

THE NEWTON-RAPHSON METHOD • Use the Newton-Raphson method to estimate the root of f(x) = e−x − x, employing an initial guess of x0 = 0.

8

THE SECANT METHOD • A potential problem in implementing the Newton-Raphson method is the evaluation of the derivative. • There are certain functions whose derivatives may be extremely difficult or inconvenient to evaluate.

9

THE SECANT METHOD • Use the secant method to estimate the root of f(x) = e−x − x . Start with initial estimates of x−1 = 0 and x0 = 1.0.

10

THE SECANT METHOD • Use the secant method to estimate the root of f(x) = e−x − x . Start with initial estimates of x−1 = 0 and x0 = 1.0.

11

Algorithm for Fixed-Point Iteration

12

Group Assignment #2 1. Determine the highest real root of

f(x) = 2x3 − 11.7x2 + 17.7x − 5 a. Fixed-point iteration method (three iterations, x0 = 3). b. Newton-Raphson method (three iterations, x0 = 3). c. Secant method (three iterations, x−1 = 3, x0 = 4).

13

Group Assignment #2 2. Determine the root of the following function,

f(x) = 5 − 5x − e0.5x Perform iterations until εa < 2%. a. Use a bracketing method (Bisection), use initial guesses of xl = 0 and xu = 2. b. Use the Newton-Raphson, use an initial guess of xi = 0.7. c. Use the secant method, use initial guesses of xi−1 = 0 and xi = 2. 14

Group Assignment #2 • Solve problem no. 1 manually. • Develop a user-friendly program to solve problem no. 1 and no. 2. • Prepare for demo! • Work in pairs (1 group = 2 members)

15

View more...

Comments

Copyright ©2017 KUPDF Inc.
SUPPORT KUPDF