MATH-GA 2011.004 / CSCI-GA 2945.004

Advanced Topics in Numerical Analysis:

Computational Fluid Dynamics

Warren Weaver Hall, room 1302, Tuesdays, 3:20-5:05pm
Courant Institute of Mathematical Sciences
New York University
Fall Semester, 2018

Lecture materials

I will post here some hand-written notes or presentation slides and links to relevant reading materials. Some of the links below may require being on the NYU network, which you can do from off-campus via a proxy server as well.

For background in fluid dynamics, you may consult the book by my colleague Stephen Childress.

There will be no final exam in this class, only a final project that you will present in class. The last class (presentations) will be 12/18, and the final project will be due the same day by class time and is to be submitted electronically.

There is no class on Tue Oct 9th as NYU will operate on the Monday academic schedule that day. We will have a class on Tue Nov 20th (before Thanksgiving).

1. (Sept 4th) Advection-Diffusion Equations

A nice book on the subject is available electronically at Courant: Hundsdorfer, W., & Verwer, J.G. (2003). Springer Series in Computational Mathematics [Series, Vol. 33]. Numerical Solution of Time-Dependent Advection-Diffusion-Reaction Equations. New York, NY: Springer-Verlag.

Here are lecture notes on the continuum advection-diffusion equation, and also notes on basic finite-difference/finite-volume spatial discretization in one dimension. If you need to freshen up on Fourier methods for linear PDEs including dispersion relations, see Appendix E in the book of Leveque.

Note that there is a homework! Everyone will need to do very well on the first two parts of this homework to pass this course -- you will be allowed to resubmit later if required.

2. (Sep 11th) Convergence of spatial discretizations

We will continue the discussion of advection-diffusion equations focusing on the analysis of convergence (stability+accuracy) of spatial discretizations. Here are some notes on spatial convergence that you will need to finish the first assignment.

Here is a symbolic algebra Maple worksheet (source code) that shows that for non-constant advection velocity the third-order upwind biased scheme is only third order if one uses a finite volume interpretation. For constant advection it is third-order either as a finite-volume or finite-difference scheme.

3. (Sept 18th) Pseudospectral and finite-element spatial discretizations

We will discuss series-expansion methods, focusing on the Galerkin approach, based on Ch. 4 in the book "Numerical Methods for Wave Equations" by Dale Durran. We will start with a brief discussion of finite-element methods and then discuss Fourier-based pseudo-spectral methods.

Regarding pseudospectral methods, there are some subtle issues with spectral differentiation (excellent and detailed technical notes by Steven G. Johnson, MIT) and aliasing (selected pages from notes on pseudospectral methods by Denys Dutykh).

Idea for final project: Learn how to use one of a number of excellent FEM programming frameworks (consult Prof. Georg Stadler or Prof. Charles Puelz for ideas) and use it to solve a problem of interest.

4. (Sept 18th) Exponential Time Integrators

This lecture is done a bit out of order because on Tuesday Sept 25th at 1:25-2:25pm in room 512 Nick Trefethen will give a lecture on "Exponential integrators for stiff PDEs" that you should try to attend; our class will follow and we can discuss some more aspects. This lecture will use some pseudospectral method for spatial discretization, but exponential integrators can be used with other discretizations also.

Basic background on exponential integrators can be found in section 11.6 in the basic book by LeVeque. Modern-day exponential integrators are based on the idea of using iterative Krylov methods to approximate the required actions of the matrix exponential on a vector. See this article on solving stiff large-scale MHD problems using exponential integrators.

As an example of what a real "state-of-the-art" pseudospectral code to solve a nonlinear PDE may look like, here is a pseudospectral code to solve the KdV equation (u_t+u*u_x+u_xxx=0) written by A. K. Kassam and L. N. Trefethen with some small changes by me. It illustrates soliton solutions but you can easily change the initial condition as shown. It uses a fancy 4th order exponential integrator method for time stepping a system of ODEs in time. Here is some explanation of the method used here and a simpler code (but less accurate!) that just uses Euler time stepping.

Idea for final project: Use pseudospectral methods to solve the Kuramoto–Sivashinsky equation in one and higher dimensions. Use Krylov methods to implement the exponential integrators for non-periodic domains.

5. (Sept 25th) Boundary Conditions

Handling boundary conditions in finite-volume methods is tricky, and the order of accuracy of the method can be higher than the truncation error order, as I explain here following the textbook of Hundsdorfer & Verwer.

Note that there is a new homework! Here are some notes to help you with part 2 of this homework, and codes that solve it.

6. (Oct 2nd) Basic Method of Lines Discretizations

We will continue discussing advection-diffusion equations but now consider how to discretize in time and not just in space (fully discrete). We will come back to space-time (non-MOL) schemes later. We will finish the discussion of temporal integrators by first starting with more classical schemes such as Runge Kutta and multistep, including implicit-explicit (IMEX) schemes, and then discussing more general splitting methods.

There is a new homework relating to implicit time stepping schemes.

(Oct 9th) No class  (Monday schedule)

7. (Oct 16th and 23rd) Space-Time Schemes

We will begin by exploring some basic space-time methods for advection focusing on the Lax-Wendroff method as a prototypical example. We will also discuss how to combine advection with diffusion in space-time methods for advection-diffusion equations. This is an alternative to the MOL schemes that is more efficient and preferred in state-of-the-art finite volume methods.

There is a homework that asks you to look at Lax-Wendroff/Fromm for advection-diffusion, similar to the first homework but now it is harder to use FFT-based schemes due to spatial inhomogeneity. Here are codes for advection-diffusion using Fromm+Crank-Nicolson. The stability analysis of these types of schemes in two dimensions can be found in the very readable and instructive paper "On the Stability of Godunov-Projection Methods for Incompressible Flow" by Michael Minion.

8. (Oct 23rd and 30th)  High-Resolution Advection

We will first discuss monotone MOL schemes and introduce limiters that prevent the appearance of oscillations for advection, based on an algebraic flux-limiting construction, based on the book of Hundsdorfer & Verwer.

We will then discuss how to generalize this to space-time high-resolution methods via the idea of reconstruction and slope-limiting. My notes use a number of sources but the best source is chapters 6 and 10 in the book "Finite Volume Methods for Hyperbolic Problems" by Randall J. Leveque, which is also summarized nicely in these lecture notes from V. Springel and C.P. Dullemond (see their full set of lectures). Here are codes for advection-diffusion that also show how to include slope limiters in Fromm's method.

I only cover 1D basics in class - if you really want to understand how to do this in 2D and 3D choose it as a final project, either based on the book by Leveque or perhaps this article describing (and extending) the BDS2D algorithm by May, Nonaka, Almgren, and Bell for 2D, and this paper on a BDS3D algorithm for 3D. Here are some Fortran codes for BDS.

Idea for final project: Implement a high-resolution space-time method in two dimensions for the advection-diffusion equation (focusing on advection-dominated problems) and test in model problems.

9. (Nov 6th)  Conservation laws

We will briefly discuss how to generalize the methods we discussed in detail for advection to more general nonlinear hyperbolic equations coming from conservation laws. I only give some basic methods and ideas here, and a serious study warrants a more detailed source like "Finite Volume Methods for Hyperbolic Problems" by Randall J. Leveque.

10. (Nov 6th) Pseudospectral methods for incompressible flow in 2D

After formulating the vorticity-stream formulation of the incompressible NS equations, we will go through a simple pseudo-spectral method for two-dimensional periodic flow. Also take a look at mit18336_spectral_ns2d.m (2D Navier-Stokes pseudo-spectral solver on the torus) and note that there is a new homework, see also this Wikipedia article on the Taylor vortex.

Idea for final project: Implement a pseudospectral solver for the NS equations in 3D for periodic domains, and explore anti-aliasing strategies; see for example this article on computing nearly-singular solutions.

9. (Nov 13th and 20th) Incompressible NS equations

First we will discuss the mathematical and physical formulation of the NS equations. Then we will learn about using projection-type methods with a staggered or MAC spatial discretization, see also the Documentation for the code mit18086_navierstokes.m (finite differences for the incompressible Navier-Stokes equations in a box).

Here is a very brief discussion on comparison with FEM methods. The article "Divergence-free discontinuous Galerkin schemes for the Stokes equations and the MAC scheme" by Guido Kanschat shows that in fact the MAC scheme is a peculiar DG scheme.

For temporal integration of the incompressible NS equations, we will discuss projection methods, based on a seminal paper by Brown, Minion and Cortez.

Thanksgiving Break: It is important that you start thinking about and working on your final projects. You should discuss your project with me and get it approved first.

10. (Nov 27th) Multigrid

We will discuss how to solve the types of linear systems that arise from implicit discretizations of diffusion, notably, Poisson and Helmholtz-type equations. Here are some lecture notes on iterative methods for solving linear systems. For multigrid I will rely on these multigrid lecture notes by William L. Briggs.

12. (Dec 4th) Adaptive Mesh Refinement

We will then discuss Adaptive Mesh Refinement (AMR), including hyperbolic, elliptic and parabolic equations, based on lecture notes by my colleague John Bell, and software used to actually implement these algorithms in real life, particularly BoxLib, OpenFOAM, PETSc, IBAMR, and GPUs.

11. (Dec 11th) Immersed-Boundary Methods

The best source for learning the foundations of the IB method is this review article by Charlie Peskin. For a more detailed computational paper, see the paper "Immersed boundary model of aortic heart valve dynamics with physiological driving and loading conditions" by Boyce Griffith and check out the IBAMR library.

7. (Dec 18th) FINAL PROJECT PRESENTATIONS