c9-3 (779533), страница 2
Текст из файла (страница 2)
This method is distinguishedfrom the methods of previous sections by the fact that it requires the evaluationof both the function f(x), and the derivative f 0 (x), at arbitrary points x. TheNewton-Raphson formula consists geometrically of extending the tangent line at acurrent point xi until it crosses zero, then setting the next guess xi+1 to the abscissaof that zero-crossing (see Figure 9.4.1).
Algebraically, the method derives from thefamiliar Taylor series expansion of a function in the neighborhood of a point,f(x + δ) ≈ f(x) + f 0 (x)δ +f 00 (x) 2δ + ....2(9.4.1)For small enough values of δ, and for well-behaved functions, the terms beyondlinear are unimportant, hence f(x + δ) = 0 impliesδ=−f(x).f 0 (x)(9.4.2)Newton-Raphson is not restricted to one dimension.
The method readilygeneralizes to multiple dimensions, as we shall see in §9.6 and §9.7, below.Far from a root, where the higher-order terms in the series are important, theNewton-Raphson formula can give grossly inaccurate, meaningless corrections. Forinstance, the initial guess for the root might be so far from the true root as to letthe search interval include a local maximum or minimum of the function. This canbe death to the method (see Figure 9.4.2). If an iteration places a trial guess nearsuch a local extremum, so that the first derivative nearly vanishes, then NewtonRaphson sends its solution off to limbo, with vanishingly small hope of recovery.Sample page from NUMERICAL RECIPES IN C: THE ART OF SCIENTIFIC COMPUTING (ISBN 0-521-43108-5)Copyright (C) 1988-1992 by Cambridge University Press.Programs Copyright (C) 1988-1992 by Numerical Recipes Software.Permission is granted for internet users to make one paper copy for their own personal use.
Further reproduction, or any copying of machinereadable files (including this one) to any servercomputer, is strictly prohibited. To order Numerical Recipes books,diskettes, or CDROMsvisit website http://www.nr.com or call 1-800-872-7423 (North America only),or send email to trade@cup.cam.ac.uk (outside North America).}nrerror("Maximum number of iterations exceeded in zbrent");return 0.0;Never get here..















