**Buy in print**at the SIAM bookstore. Members of SIAM, including student members, get a 30% discount.**Buy an e-book**at the Google Play store. A rental option is also available.

This textbook is designed to introduce undergraduates in math, computer science, engineering, and related fields to the principles and practice of numerical computation. Our approach emphasizes linear algebra and approximation. The text presents mathematical underpinnings and analysis, complemented with 45 functions and over 160 examples coded in MATLAB, all available for download. Previous experience in MATLAB is not required. The functions and examples have also been implemented in Julia and Python.

The text is organized to be useful for either a one-semester introduction or two-semester sequence, with the most advanced techniques and concepts held back for the second half of the book.

Please note the known errata.

### Resources

The book’s functions and example scripts can be downloaded as a MATLAB toolbox and installed by double-clicking the file. Alternatively, you can visit the Github page that has the needed files, as well as suggested in-class labs and projects, slides for instructors, and links to some (slightly outdated) videos linked to the text.

There are also Julia versions and Python versions of the function and example files.

### Contents

- Numbers, problems, and algorithms
- Floating point numbers
- Problems and conditioning
- Stability of algorithms

- Square linear systems
- Polynomial interpolation
- Computing with matrices
- Linear systems
- LU factorization
- Efficiency of matrix computations
- Row pivoting
- Vector and matrix norms
- Conditioning of linear systems
- Exploiting matrix structure

- Overdetermined linear systems
- Fitting functions to data
- The normal equations
- The QR factorization
- Computing QR factorizations

- Roots of nonlinear equations
- The rootfinding problem
- Fixed point iteration
- Newton’s method in one variable
- Interpolation-based methods
- Newton for nonlinear systems
- Quasi-Newton methods
- Nonlinear least squares

- Piecewise interpolation and calculus
- The interpolation problem
- Piecewise linear interpolation
- Cubic splines
- Finite differences
- Convergence of finite differences
- Numerical integration
- Adaptive integration

- Initial-value problems for ODEs
- Basics of IVPs
- Euler’s method
- Systems of differential equations
- Runge-Kutta methods
- Adaptive Runge-Kutta
- Multistep methods
- Implementation of multistep methods
- Zero-stability of multistep methods

- Matrix analysis
- From matrix to insight
- Eigenvalue decomposition
- Singular value decomposition
- Symmetry and definiteness
- Dimension reduction

- Krylov methods in linear algebra
- Sparsity and structure
- Power iteration
- Inverse iteration
- Krylov subspaces
- GMRES
- MINRES and conjugate gradients
- Matrix-free iterations
- Preconditioning

- Global function approximation
- Polynomial interpolation
- The barycentric formula
- Stability of polynomial interpolation
- Orthogonal polynomials
- Trigonometric interpolation
- Spectrally accurate integration
- Improper integrals

- Boundary-value problems
- Shooting
- Differentiation matrices
- Collocation for linear problems
- Nonlinearity and boundary conditions
- The Galerkin method

- Diffusion equations
- Black-Scholes equation
- The method of lines
- Absolute stability
- Stiffness
- Method of lines for parabolic PDEs

- Advection equations
- Traffic flow
- Upwinding and stability
- Absolute stability for advection
- The wave equation

- Two-dimensional problems
- Tensor-product discretizations
- Two-dimensional diffusion and advection
- Laplace and Poisson equations
- Nonlinear elliptic PDEs