Methods of Numerical Simulation in Fluids and Plasmas

Antonius Otto

Course Syllabus (pdf)

Physics F629:

REIC 204
Mo, We, Fr
11:45 - 12:45p

Scope and Contents of the Course:

Numerical simulation has become a frequently used and misused tool in Physics. Many areas in physics employ smaller and larger simulation codes. However, the traditional physics education provides no or little background in simulation techniques and their limitations. Often numerical simulation is used as a black box with little insight into the associated pitfalls and common errors. This course is intended to provide a systematic introduction into the methods and the limitations of computer simulation.

The course will introduce, analyze, and apply methods for the numerical solution of partial differential equations (pde's) which determine the dynamics of fluids and multi particle systems. The elements of this course include (a) classification and applications of partial differential equations, (b) methods for discrete representation of pde's, (c) stability and accuracy of the numerical solution, (d) boundary and initial conditions. The discrete representation of pde's includes finite differences, finite elements, finite volume, and spectral methods. The course address efficiency of various methods, and considers aspects of vector and parallel computer architectures. Applications address the dynamics of fluids, plasmas, and multi particle systems; and consider steady state configurations, convection problems, linear and nonlinear instabilities. Some specific applications can be chosen according to the interest of students enrolled in the course.

(Prerequisites: Undergrad Math; experience in programming; graduate standing or permission of instructor; 3 + 0 credits)

Conduct of the Course:

Grading Policy:

The course will consist of two parts, where the first part provides the methodology of the simulation of convection and diffusion equations which are common in atmospheric, ocean, ionospheric, space plasma, and many technical fluid dynamics applications. The second part will address more specific applications from various areas of physics and includes the generation of appropriate grids, boundary layer flow, shocks and flux corrected transport, and particle/plasma simulation.

The course will be held in a lecture format. The first part of the course will be based on the two volume text by Fletcher, Computational Techniques for Fluid Dynamics. No textbook currently available provides all information necessary for the second more specific part of the course.

Homework will be distributed weekly through the class website and problems are analytic and applied, i.e., students are be expected to program and test various algorithms. Program examples will be presented in FORTRAN which is common on supercomputers and the graphics language IDL. However, exercises may be programmed also in C, PASCAL, MATLAB or other languages provided their syntax is sufficiently obvious. Solutions to the homework are distributed through the website. In the second part of the course a portion of the exercises will consist of work on a specific project according to the interest of the student. Enrolled students are expected to obtain their own computer account, and to be/become familiar with a common graphics package for the presentation of results. Programming experience and some background on partial differential equations is recommended for the course.

There will be a midterm test (voluntary) and a final exam.

Homework: 50%

Project: 15%

Final exam: 35%
(date to be determined)


Fletcher: Computational Techniques for Fluid Dynamics, I and II, Springer (1988): A very good two volume text with very detailed coverage of basic and advanced fluid simulation techniques including finite differences, finite element, spectral and other methods. Many programming examples for illustration and as tutorials. The text addresses dynamic and steady state problems, explicit and implicit treatment, flux corrected transport, boundary conditions, and grid generation. It lacks all aspects of plasma simulation.

Potter: Computational Physics, John Wiley (1973, out of print but available in the GI library): A good text book on the simulation of fluids and plasmas which covers most of the basics of fluid simulation. It also addresses plasma simulation, however, because of its age it is slightly outdated, lacks some of the more recent developments and the overall coverage is significantly smaller than in Fletcher's text.

Tajima: Computational Plasma Physics, With Applications to Fusion and Astrophysics, Addison Wesley (1989): The text focuses on plasma simulation by particle simulation with coverage of explicit, implicit, full electromagnetic, and hybrid models. It also addresses the most important fluid aspects of plasma simulation including finite differences, spectral methods and flux corrected transport. The presentation of the latter is fairly brief and may preferably be used as an overview of these topics.

Birdsall and Langdon: Plasma Physics via Computer Simulation, IOP (1995, based on 1985 original): Good textbook on plasma simulation but entirely focused on particle simulation techniques. Very detailed presentation with many applications (comes with programs on floppy disk). Good coverage of electrostatic and electromagnetic simulation including theory and physics.

Hockney and Eastwood: Computer Simulation using Particles, IOP (1994, revised from 1980 edition): Good textbook covering the same range of topics as Birdsall and Langdon. A little less detailed regarding the plasma physics applications, however, with additional coverage of simulations of semiconductors and of astrophysical problems.

NRL Plasma Formulary by Dave Book and maintained by Joe Huba: The NRL Plasma Formulary has been the mini-Bible of plasma physicists for the past 20 years. It is an eclectic compilation of mathematical and scientific formulas, and contains physical parameters pertinent to a variety of plasma regimes, ranging from laboratory devices to astrophysical objects.

Methods of Numerical Simulation - List of Contents

  1. Introduction

    1. History

    2. Why numerical simulation

    3. The numerical experiment: limitations, accuracy, stability

    4. Vector and parallel computer performance

  2. Origin of Partial Differential Equations

    1. Individual particle potion

    2. Kinetic equations

    3. Fluid equations

  3. Properties of Partial Differential Equations

    1. Linear second order PDE's in two independent variables

    2. Well posed problems

    3. Boundary and initial conditions

    4. Classification through characteristics

    5. Classification Through Fourier Analysis

    6. Hyperbolic PDE's

    7. Parabolic PDE's

    8. Elliptic PDE's

    9. Traditional methods of solution

  4. Preliminary Computational Techniques

    1. Discretization

    2. Approximation to derivatives

    3. Accuracy

    4. Wave representation

    5. First example for a finite difference simulation

  5. Theory

    1. Convergence

    2. Consistency

    3. Stability

    4. Accuracy

    5. Efficiency

  6. Weighted Residual Methods

    1. General formulation

    2. Finite volume method

    3. Finite element method

    4. Spectral method

  1. Elliptic Equations and Steady State Problems

    1. Newtons method

    2. Direct methods

    3. Iterative methods

  2. Diffusion Equation

    1. Explicit methods

    2. Implicit methods

    3. Splitting schemes

    4. Boundary conditions

  3. Convection Equations

    1. Linear convection equations

    2. Numerical dispersion and dissipation

    3. One- and two-dimensional transport equations

    4. Burgers equation

  4. Fluid and Plasma Simulation*

    1. Explicit and implicit methods

    2. Supersonic flow, shocks, flux corrected transport

    3. Particle simulation

    4. Hybrid simulation

    5. Vlasov simulation

  5. Grid Generation*

  6. Applications and Projects

    1. Two-dimensional flow past an obstacle

    2. Three-dimensional diffusion equation

    3. Interchange instabilities (Kelvin Helmholtz)

    4. Magnetohydrodynamic waves

    5. Magnetohydrodynamic shocks

Homework and Exams

Sheet 1
Sheet 2
Sheet 3
Sheet 4
Sheet 5
Sheet 6
Sheet 7
Sheet 8
Sheet 9
Sheet 10
Sheet 11
Sheet 12
Final Exam

Solutions 1: IDL programs:,
Solutions 2:
Solutions 3:
Solutions 4:
Solutions 5: #16: sim12lev.f, simin, sim1.dat
Solutions 6:
Solutions 7: #23: fivol23.f, fivin, fivol.dat,
Solutions 8: #27: duct27.f, ductin, duct.dat,
Solutions 9:
#31: duct_jac.f, ductin, duct.dat
Solutions 10: #33: duct33.f, ductin, duct.dat,
#34: ductvnxbd.f, ductin, duct.dat,
Solutions 11: #37: sim1mul.f, sim1min, sim1m.dat,
Solutions 12:

Midterm Solutions
Final Exam Solutions


Simulation Programs

Visualization and Graphics

1D Diffusion (FTCS): sim1.f, simin, sim1.dat

Idl progr:

Execution time for selected operations: count.f, readme

Finite volume method for Laplace's equation: fivol2.f, fivin, fivol.dat

Sturm-Liouville equation: sturm.f, sturm.dat

Finite element and finite difference method for viscous flow: duct.f, ductin, duct.dat

Newton's method applied to two-dimensional steady Burger's equations: newburger.f, newbin, newb.dat

Implicit methods for the diffusion equation:
difim.f, difim.dat

Explicit (Upwind, Leapfrog, L-W) methods for the convection equation:
conv1.f, conv1.dat, convin

Methods to solve the transport equation (Upwind, Leapfrog, L-W, C-N):
readme_transport, trans.f, transin, trans1.dat,

Nonlinear transport equation (Upwind, Leapfrog, L-W, C-N):
trans.f, transin, trans1.dat

Two-dimensional MHD

Flux Corrected Transport:
sh1.f, shock.dat, shin

Antonius Otto 2011-01-21