c4-0 (779477)
Текст из файла
Integration of Functions4.0 IntroductionNumerical integration, which is also called quadrature, has a history extendingback to the invention of calculus and before. The fact that integrals of elementaryfunctions could not, in general, be computed analytically, while derivatives couldbe, served to give the field a certain panache, and to set it a cut above the arithmeticdrudgery of numerical analysis during the whole of the 18th and 19th centuries.With the invention of automatic computing, quadrature became just one numerical task among many, and not a very interesting one at that. Automatic computing,even the most primitive sort involving desk calculators and rooms full of “computers”(that were, until the 1950s, people rather than machines), opened to feasibility themuch richer field of numerical integration of differential equations.
Quadrature ismerely the simplest special case: The evaluation of the integralZbf(x)dxI=(4.0.1)ais precisely equivalent to solving for the value I ≡ y(b) the differential equationdy= f(x)dx(4.0.2)y(a) = 0(4.0.3)with the boundary conditionChapter 16 of this book deals with the numerical integration of differentialequations. In that chapter, much emphasis is given to the concept of “variable” or“adaptive” choices of stepsize. We will not, therefore, develop that material here.If the function that you propose to integrate is sharply concentrated in one or morepeaks, or if its shape is not readily characterized by a single length-scale, then itis likely that you should cast the problem in the form of (4.0.2)–(4.0.3) and usethe methods of Chapter 16.The quadrature methods in this chapter are based, in one way or another, on theobvious device of adding up the value of the integrand at a sequence of abscissaswithin the range of integration.
The game is to obtain the integral as accuratelyas possible with the smallest number of function evaluations of the integrand. Justas in the case of interpolation (Chapter 3), one has the freedom to choose methods129Sample 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).Chapter 4.130Chapter 4.Integration of FunctionsCITED REFERENCES AND FURTHER READING:Carnahan, B., Luther, H.A., and Wilkes, J.O.
1969, Applied Numerical Methods (New York:Wiley), Chapter 2.Isaacson, E., and Keller, H.B. 1966, Analysis of Numerical Methods (New York: Wiley), Chapter 7.Acton, F.S. 1970, Numerical Methods That Work; 1990, corrected edition (Washington: Mathematical Association of America), Chapter 4.Stoer, J., and Bulirsch, R. 1980, Introduction to Numerical Analysis (New York: Springer-Verlag),Chapter 3.Ralston, A., and Rabinowitz, P. 1978, A First Course in Numerical Analysis, 2nd ed. (New York:McGraw-Hill), Chapter 4.Dahlquist, G., and Bjorck, A. 1974, Numerical Methods (Englewood Cliffs, NJ: Prentice-Hall),§7.4.Kahaner, D., Moler, C., and Nash, S. 1989, Numerical Methods and Software (Englewood Cliffs,NJ: Prentice Hall), Chapter 5.Forsythe, G.E., Malcolm, M.A., and Moler, C.B. 1977, Computer Methods for MathematicalComputations (Englewood Cliffs, NJ: Prentice-Hall), §5.2, p.
89. [1]Davis, P., and Rabinowitz, P. 1984, Methods of Numerical Integration, 2nd ed. (Orlando, FL:Academic Press).4.1 Classical Formulas for Equally SpacedAbscissasWhere would any book on numerical analysis be without Mr. Simpson and his“rule”? The classical formulas for integrating a function whose value is known atequally spaced steps have a certain elegance about them, and they are redolent withhistorical association. Through them, the modern numerical analyst communes withthe spirits of his or her predecessors back across the centuries, as far as the timeof Newton, if not farther. Alas, times do change; with the exception of two of themost modest formulas (“extended trapezoidal rule,” equation 4.1.11, and “extendedSample 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).of various orders, with higher order sometimes, but not always, giving higheraccuracy.
“Romberg integration,” which is discussed in §4.3, is a general formalismfor making use of integration methods of a variety of different orders, and werecommend it highly.Apart from the methods of this chapter and of Chapter 16, there are yetother methods for obtaining integrals. One important class is based on functionapproximation. We discuss explicitly the integration of functions by Chebyshevapproximation (“Clenshaw-Curtis” quadrature) in §5.9. Although not explicitlydiscussed here, you ought to be able to figure out how to do cubic spline quadratureusing the output of the routine spline in §3.3. (Hint: Integrate equation 3.3.3over x analytically.
See [1].)Some integrals related to Fourier transforms can be calculated using the fastFourier transform (FFT) algorithm. This is discussed in §13.9.Multidimensional integrals are another whole multidimensional bag of worms.Section 4.6 is an introductory discussion in this chapter; the important technique ofMonte-Carlo integration is treated in Chapter 7..
Характеристики
Тип файла PDF
PDF-формат наиболее широко используется для просмотра любого типа файлов на любом устройстве. В него можно сохранить документ, таблицы, презентацию, текст, чертежи, вычисления, графики и всё остальное, что можно показать на экране любого устройства. Именно его лучше всего использовать для печати.
Например, если Вам нужно распечатать чертёж из автокада, Вы сохраните чертёж на флешку, но будет ли автокад в пункте печати? А если будет, то нужная версия с нужными библиотеками? Именно для этого и нужен формат PDF - в нём точно будет показано верно вне зависимости от того, в какой программе создали PDF-файл и есть ли нужная программа для его просмотра.