Computational Methods in Physics ASU Physics PHY 494

17 Solving PDEs with time stepping

Partial differential equations (PDEs) may depend on both space and time derivatives such as the parabolic heat equation

which describes how temperature changes over time in a material with thermal conductivity , heat capacity , and density . Importantly, in order to solve such PDEs, we need to know both the initial values at all positions in space at and the boundary conditions at all later times .

Leap frog algorithm for solving the heat equation

We can then transform the PDE into a finite difference equation on a lattice. The difference equation can be solved with a time stepping scheme where we start from the initial values and solve the spatial component for increasing times using either an explicit method such as the Leapfrog algorithm or an implicit method such as the Crank-Nicholson method.

Von Neumann stability analysis

Not all combinations of and lead to stable solutions. Using von Neumann stability analysis one can determine analytically the relationship between the discretizations in space and time that lead to stable solutions. The analysis is based on determining the stable eigenmodes of the finite difference equation, i.e., we determine the conditions under which no modes grow in time. This then implies that solutions, which can be written as linear superpositions of these eigenmodes, will also not grow in time and are therefore stable.

Class material

Additional resources

  • Computational Physics, Ch 20
  • Numerical Recipes in C, WH Press, SA Teukolsky, WT Vetterling, BP Flannery. 2nd ed, 2002. Cambridge University Press. Chapter 19.

Footnotes

  1. As usual, git pull the resources repository to get a local copy of the notebook. Then copy the notebook into your work directory in order to complete the exercises. 

  2. Notebook will be posted after class; in the mean time look at the student notebook.