Muutke küpsiste eelistusi

E-raamat: Numerical Methods in Physics with Python

(University of Guelph, Ontario)
  • Formaat: PDF+DRM
  • Ilmumisaeg: 27-Aug-2020
  • Kirjastus: Cambridge University Press
  • Keel: eng
  • ISBN-13: 9781108805889
  • Formaat - PDF+DRM
  • Hind: 51,86 €*
  • * hind on lõplik, st. muud allahindlused enam ei rakendu
  • Lisa ostukorvi
  • Lisa soovinimekirja
  • See e-raamat on mõeldud ainult isiklikuks kasutamiseks. E-raamatuid ei saa tagastada.
  • Formaat: PDF+DRM
  • Ilmumisaeg: 27-Aug-2020
  • Kirjastus: Cambridge University Press
  • Keel: eng
  • ISBN-13: 9781108805889

DRM piirangud

  • Kopeerimine (copy/paste):

    ei ole lubatud

  • Printimine:

    ei ole lubatud

  • Kasutamine:

    Digitaalõiguste kaitse (DRM)
    Kirjastus on väljastanud selle e-raamatu krüpteeritud kujul, mis tähendab, et selle lugemiseks peate installeerima spetsiaalse tarkvara. Samuti peate looma endale  Adobe ID Rohkem infot siin. E-raamatut saab lugeda 1 kasutaja ning alla laadida kuni 6'de seadmesse (kõik autoriseeritud sama Adobe ID-ga).

    Vajalik tarkvara
    Mobiilsetes seadmetes (telefon või tahvelarvuti) lugemiseks peate installeerima selle tasuta rakenduse: PocketBook Reader (iOS / Android)

    PC või Mac seadmes lugemiseks peate installima Adobe Digital Editionsi (Seeon tasuta rakendus spetsiaalselt e-raamatute lugemiseks. Seda ei tohi segamini ajada Adober Reader'iga, mis tõenäoliselt on juba teie arvutisse installeeritud )

    Seda e-raamatut ei saa lugeda Amazon Kindle's. 

Bringing together idiomatic Python programming, foundational numerical methods, and physics applications, this is an ideal standalone textbook for courses on computational physics. All the frequently used numerical methods in physics are explained, including foundational techniques and hidden gems on topics such as linear algebra, differential equations, root-finding, interpolation, and integration. Accompanying the mathematical derivations are full implementations of dozens of numerical methods in Python, as well as more than 250 end-of-chapter problems. Numerical methods and physics examples are clearly separated, allowing this introductory book to be later used as a reference; the penultimate section in each chapter is an in depth project, tackling physics problems which cannot be solved without the use of a computer. Written primarily for students studying computational physics, this textbook brings the non-specialist quickly up to speed with Python before looking in detail at the numerical methods often used in the subject.

Arvustused

'I enthusiastically recommend Numerical Methods in Physics with Python by Professor Gezerlis to any advanced undergraduate or graduate student who would like to acquire a solid understanding of the basic numerical methods used in physics. The methods are demonstrated with Python, a relatively compact, accessible computer language, allowing the reader to focus on understanding how the methods work rather than on how to program them. Each chapter offers a self-contained, clear, and engaging presentation of the relevant numerical methods, and captivates the reader with well-motivated physics examples and interesting physics projects. Written by a leading expert in computational physics, this outstanding textbook is unique in that it focuses on teaching basic numerical methods while also including a number of modern numerical techniques that are usually not covered in computational physics textbooks.' Yoram Alhassid, Yale University, Connecticut 'In Numerical Methods in Physics with Python by Gezerlis, one finds a resource that has been sorely missing! As the usage of Python has become widespread, it is too often the case that students take libraries, functions, and codes and apply them without a solid understanding of what is truly being done 'under the hood' and why. Gezerlis' book fills this gap with clarity and rigor by covering a broad number of topics relevant for physics, describing the underlying techniques and implementing them in detail. It should be an important resource for anyone applying numerical techniques to study physics.' Luis Lehner, Perimeter Institute, Ontario 'Gezerlis' text takes a venerable subject numerical techniques in physics and brings it up to date and makes it accessible to modern undergraduate curricula through a popular, open-source programming language. Although the focus remains squarely on numerical techniques, each new lesson is motivated by topics commonly encountered in physics and concludes with a practical hands-on project to help cement the students' understanding. The net result is a textbook which fills an important and unique niche in pedagogy and scope, as well as a valuable reference for advanced students and practicing scientists.' Brian Metzger, Columbia University, New York

Muu info

A standalone text for courses on computational physics combining idiomatic Python, foundational numerical methods, and physics applications.
Preface xiii
List of codes
xvii
1 Idiomatic Python
1(27)
1.1 Why Python?
2(1)
1.2 Code Quality
3(1)
1.3 Summary of Python Features
4(6)
1.3.1 Basics
4(1)
1.3.2 Control Flow
5(1)
1.3.3 Data Structures
6(2)
1.3.4 User-Defined Functions
8(2)
1.4 Core-Python Idioms
10(3)
1.4.1 List Comprehensions
10(1)
1.4.2 Iterating Idiomatically
11(2)
1.5 Basic Plotting with matplotlib
13(2)
1.6 NumPy Idioms
15(6)
1.7 Project: Visualizing Electric Fields
21(4)
1.7.1 Electric Field of a Distribution of Point Charges
21(1)
1.7.2 Plotting Field Lines
22(3)
1.8 Problems
25(3)
2 Numbers
28(57)
2.1 Motivation
28(1)
2.2 Errors
29(9)
2.2.1 Absolute and Relative Error
30(2)
2.2.2 Error Propagation
32(6)
2.3 Representing Real Numbers
38(7)
2.3.1 Basics
38(1)
2.3.2 Overflow
39(1)
2.3.3 Machine Precision
40(1)
2.3.4 Revisiting Subtraction
41(3)
2.3.5 Comparing Floats
44(1)
2.4 Rounding Errors in the Wild
45(15)
2.4.1 Are Roundoff Errors Random?
45(2)
2.4.2 Compensated Summation
47(2)
2.4.3 Naive vs Manipulated Expressions
49(1)
2.4.4 Computing the Exponential Function
50(5)
2.4.5 An Even Worse Case: Recursion
55(3)
2.4.6 When Rounding Errors Cancel
58(2)
2.5 Project: the Multipole Expansion in Electromagnetism
60(16)
2.5.1 Potential of a Distribution of Point Charges
60(5)
2.5.2 Expansion for One Point Charge
65(6)
2.5.3 Expansion for Many Point Charges
71(5)
2.6 Problems
76(9)
3 Derivatives
85(36)
3.1 Motivation
85(1)
3.1.1 Examples from Physics
85(1)
3.1.2 The Problem to Be Solved
86(1)
3.2 Analytical Differentiation
86(1)
3.3 Finite Differences
87(18)
3.3.1 Noncentral-Difference Approximations
87(4)
3.3.2 Central-Difference Approximation
91(2)
3.3.3 Implementation
93(2)
3.3.4 More Accurate Finite Differences
95(1)
3.3.5 Second Derivative
96(1)
3.3.6 Points on a Grid
97(4)
3.3.7 Richardson Extrapolation
101(4)
3.4 Automatic Differentiation
105(4)
3.4.1 Dual Numbers
105(1)
3.4.2 An Example
106(1)
3.4.3 Special Functions
107(2)
3.5 Project: Local Kinetic Energy in Quantum Mechanics
109(8)
3.5.1 Single-Particle Wave Functions in One Dimension
109(5)
3.5.2 Second Derivative
114(3)
3.6 Problems
117(4)
4 Matrices
121(122)
4.1 Motivation
121(4)
4.1.1 Examples from Physics
121(2)
4.1.2 The Problems to Be Solved
123(2)
4.2 Error Analysis
125(21)
4.2.1 From a posteriori to a priori Estimates
126(1)
4.2.2 Magnitude of Determinant?
127(2)
4.2.3 Norms for Matrices and Vectors
129(2)
4.2.4 Condition Number for Linear Systems
131(4)
4.2.5 Condition Number for Simple Eigenvalues
135(6)
4.2.6 Sensitivity of Eigenvectors
141(5)
4.3 Solving Systems of Linear Equations
146(29)
4.3.1 Triangular Matrices
147(5)
4.3.2 Gaussian Elimination
152(7)
4.3.3 LU Method
159(6)
4.3.4 Pivoting
165(6)
4.3.5 Jacobi Iterative Method
171(4)
4.4 Eigenproblems
175(31)
4.4.1 Power Method
177(4)
4.4.2 Inverse-Power Method with Shifting
181(6)
4.4.3 QR Method
187(17)
4.4.4 All Eigenvalues and Eigenvectors
204(2)
4.5 Project: the Schrodinger Eigenvalue Problem
206(27)
4.5.1 One Particle
206(5)
4.5.2 Two Particles
211(12)
4.5.3 Three Particles
223(3)
4.5.4 Implementation
226(7)
4.6 Problems
233(10)
5 Roots
243(68)
5.1 Motivation
243(3)
5.1.1 Examples from Physics
243(1)
5.1.2 The Problem(s) to Be Solved
244(2)
5.2 Nonlinear Equation in One Variable
246(26)
5.2.1 Conditioning
247(1)
5.2.2 Order of Convergence and Termination Criteria
248(2)
5.2.3 Fixed-Point Iteration
250(6)
5.2.4 Bisection Method
256(4)
5.2.5 Newton's Method
260(5)
5.2.6 Secant Method
265(4)
5.2.7 Ridders' Method
269(3)
5.2.8 Summary of One-Dimensional Methods
272(1)
5.3 Zeros of Polynomials
272(7)
5.3.1 Challenges
273(1)
5.3.2 One Root at a Time: Newton's Method
274(3)
5.3.3 All the Roots at Once: Eigenvalue Approach
277(2)
5.4 Systems of Nonlinear Equations
279(8)
5.4.1 Newton's Method
280(2)
5.4.2 Discretized Newton Method
282(1)
5.4.3 Broyden's Method
283(4)
5.5 Minimization
287(10)
5.5.1 One-Dimensional Minimization
287(2)
5.5.2 Multidimensional Minimization
289(3)
5.5.3 Gradient Descent
292(3)
5.5.4 Newton's Method
295(2)
5.6 Project: Extremizing the Action in Classical Mechanics
297(7)
5.6.1 Defining and Extremizing the Action
297(1)
5.6.2 Discretizing the Action
298(1)
5.6.3 Newton's Method for the Discrete Action
299(2)
5.6.4 Implementation
301(3)
5.7 Problems
304(7)
6 Approximation
311(82)
6.1 Motivation
311(6)
6.1.1 Examples from Physics
311(2)
6.1.2 The Problems to Be Solved
313(4)
6.2 Polynomial Interpolation
317(16)
6.2.1 Monomial Basis
319(3)
6.2.2 Lagrange Interpolation
322(7)
6.2.3 Error Formula
329(2)
6.2.4 Hermite Interpolation
331(2)
6.3 Cubic-Spline Interpolation
333(8)
6.3.1 Three Nodes
333(2)
6.3.2 General Case
335(3)
6.3.3 Implementation
338(3)
6.4 Trigonometric Interpolation
341(20)
6.4.1 Fourier Series
342(1)
6.4.2 Finite Series: Trigonometric Interpolation
343(5)
6.4.3 Discrete Fourier Transform
348(13)
6.5 Least-Squares Fitting
361(15)
6.5.1 Chi Squared
362(2)
6.5.2 Straight-Line Fit
364(4)
6.5.3 General Linear Fit: Normal Equations
368(8)
6.6 Project: Testing the Stefan-Boltzmann Law
376(11)
6.6.1 Beyond Linear Fitting
377(1)
6.6.2 Total Power Radiated by a Black Body
378(2)
6.6.3 Fitting to the Lummer and Pringsheim Data
380(7)
6.7 Problems
387(6)
7 Integrals
393(101)
7.1 Motivation
393(3)
7.1.1 Examples from Physics
393(1)
7.1.2 The Problem to Be Solved
394(2)
7.2 Newton-Cotes Methods
396(18)
7.2.1 Rectangle Rule
397(3)
7.2.2 Midpoint Rule
400(1)
7.2.3 Integration from Interpolation
401(1)
7.2.4 Trapezoid Rule
402(5)
7.2.5 Simpson's Rule
407(4)
7.2.6 Summary of Results
411(1)
7.2.7 Implementation
412(2)
7.3 Adaptive Integration
414(5)
7.3.1 Doubling the Number of Panels
415(1)
7.3.2 Thoughts before Implementing
416(1)
7.3.3 Implementation
417(2)
7.4 Romberg Integration
419(8)
7.4.1 Richardson Extrapolation
419(2)
7.4.2 Romberg Recipe
421(4)
7.4.3 Implementation
425(2)
7.5 Gaussian Quadrature
427(14)
7.5.1 Gauss-Legendre: n = 2 Case
428(1)
7.5.2 Gauss-Legendre: General Case
429(10)
7.5.3 Other Gaussian Quadratures
439(2)
7.6 Complicating the Narrative
441(7)
7.6.1 Periodic Functions
441(1)
7.6.2 Singularities
442(2)
7.6.3 Infinite Intervals
444(2)
7.6.4 Multidimensional Integrals
446(2)
7.6.5 Evaluating Different Integration Methods
448(1)
7.7 Monte Carlo
448(25)
7.7.1 Random Numbers
449(4)
7.7.2 Monte Carlo Quadrature
453(5)
7.7.3 Monte Carlo beyond the Uniform Distribution
458(5)
7.7.4 Implementation
463(2)
7.7.5 Monte Carlo in Many Dimensions
465(8)
7.8 Project: Variational Quantum Monte Carlo
473(13)
7.8.1 Hamiltonian and Wave Function
474(5)
7.8.2 Variational Method
479(7)
7.9 Problems
486(8)
8 Differential Equations
494(65)
8.1 Motivation
494(4)
8.1.1 Examples from Physics
494(2)
8.1.2 The Problems to Be Solved
496(2)
8.2 Initial-Value Problems
498(31)
8.2.1 Euler's Method
499(7)
8.2.2 Second-Order Runge-Kutta Methods
506(5)
8.2.3 Fourth-Order Runge-Kutta Method
511(11)
8.2.4 Simultaneous Differential Equations
522(7)
8.3 Boundary-Value Problems
529(7)
8.3.1 Shooting Method
530(2)
8.3.2 Matrix Approach
532(4)
8.4 Eigenvalue Problems
536(9)
8.4.1 Shooting Method
537(4)
8.4.2 Matrix Approach
541(4)
8.5 Project: Poisson's Equation in Two Dimensions
545(7)
8.5.1 Examples of PDEs
545(1)
8.5.2 Poisson's Equation via FFT
546(6)
8.6 Problems
552(7)
Appendix A Installation and Setup
559(1)
Appendix B Number Representations
560(6)
B.1 Integers
560(1)
B.2 Real Numbers
561(4)
B.2.1 Single-Precision Floating-Point Numbers
562(2)
B.2.2 Double-Precision Floating-Point Numbers
564(1)
B.3 Problems
565(1)
Appendix C Math Background
566(7)
C.1 Taylor Series
566(1)
C.2 Matrix Terminology
567(3)
C.3 Probability
570(3)
C.3.1 Discrete Random Variables
570(2)
C.3.2 Continuous Random Variables
572(1)
Bibliography 573(4)
Index 577
Alex Gezerlis is an Associate Professor of Physics at the University of Guelph. Before moving to Canada, he worked in Germany, the United States, and Greece. He has received several research awards, grants, and allocations on supercomputing facilities and is active in teaching at both undergraduate and graduate levels.