MAT 1062H: Introductory Numerical Methods for PDE

Professor: Mary Pugh
Contact information: mpugh@math. utoronto.ca
Office hours: by appointment
Office location: Bahen 6268

Meeting time and place: The class meets on Mondays 12:10am-1:30pm and Wednesdays 2:30am-3:50pm in BA 2179. The first lecture will be on on Monday January 11 and the last on Wednesday April 6.

Auditing vs Enrolling You're welcome to audit the course; if the course is on the verge of being cancelled due to low enrolment then I'll ask some of you to consider enrolling.

Syllabus

Goal: We'll study numerical methods for solving partial differential equations that commonly arise in physics and engineering. We will pay special attention to how numerical methods should be designed in a way that respects the mathematical structure of the equation.
  • Parabolic PDE: boundary conditions, explicit and implicit discretizations, consistency, stability, and convergence,
  • Elliptic PDE: variational formulations and finite element methods
  • Hyperbolic PDE: CFL stabilty condition, finite volume method, nonlinear conservation laws, shock capturing
  • Special topics (as time permits): spectral methods, pseudospectral methods, Chebyshev polynomials

    Why we care: Here are some disasters which could have been averted if only someone had been paying closer attention to their numerical analysis. :-)

    Prerequisites: You should be familiar with the material that would be taught in a serious undergraduate PDE course. Sample programs will be provided in matlab. If you know matlab, great! If you don't, you're expected to be sufficiently comfortable with computers that you can learn matlab on the fly. Which isn't actually hard at all, unless you hate computers.

    Recommended Reading: Two nice books which provide background reading on numerical analysis, including numerical linear algebra, ODEs, finite difference methods, accuracy, and the like are "An introduction to numerical analysis" by Kendall E. Atkinson (grad level) and "Elementary numerical analysis" by Kendall Atkinson and Weimin Han (undergrad level). Five numerical PDE books that are especially useful are "Numerical methods for evolutionary differential equations" by Uri M. Ascher, "Finite difference schemes and partial differential equations" by John C. Strikwerda, "Numerical solution of partial differential equations, with exercises and worked solutions" by Gordon D. Smith, "Numerical analysis of spectral methods : theory and applications" by David Gottlieb and Steven A. Orszag, and "Numerical methods for conservation laws". I have a request in to put all seven books on 24-hour reserve.

    Programming: I will be using matlab in class and will provide matlab code for you to study and modify. You can program in whatever language you want. For your homeworks and exams, you will be asked for graphs and other output; I usually won't want to see your code.
    Matlab is proprietary. You can buy a student version of it for much less than I have to pay for it; around $120. If you're in the math department, you have access to matlab on the computer "sphere". Log in to coxeter and from there log in to sphere. If you aren't in the math department then you have to hope that matlab's installed on the machine you have access to.
    There are various free matlab clones that you can install on your computer if you wish.

    Crash courses on matlab Kermit Sigmon wrote a very nice Matlab Primer. Here's a pdf file of the Matlab Primer which you can view but will come out gibberish if you print it.
    That primer is short and sweet. Matworks now has a free primer too --- here's the link to it. It's the more modern one and so give it a try. Here's Christina C. Christara and Winky Wai's matlab guide.
    Here's Cleve Moler's "Introduction to MATLAB" chapter from his book Numerical Computing with MATLAB. Note that you can get the book as free pdf files on a chapter-by-chapter basis.

    How about some python? An open-source software that's well worth looking into is SciPy. It's a python-based scientific computing environment. Our physics department has a lovely python wiki which includes lessons on how to use python as well as an easy-to-install python package.

    Getting Started: If you're really new to computing then I encourage you to get started very soon. To get started, have a look at an old webpage of mine. You would like to look at the matlab primer as well as the links "how to write up your homework" and "how to save and execute a file". Read "flash stick" wherever I refer to a floppy disk in the second page.

    Here is your first homework assignment. Due by 4pm on Friday January 29.

    Here are the files that I used to approximate the Laplacian with various different boundary conditions.

    Here are the two scripts I used towards the end of class on January 27 demonstrating numerical instability for Forward Euler time-stepping: FE_unstable_demo.m and FE_unstable_power_spectrum_demo.m. They refer to the heat equation codes you can find here. Also, to compute the power spectrum, you'll need find_spec.m.

    Here is your second homework assignment. Due by 5pm on Monday February 22.

    Here are the two scripts I used in class on February 10 demonstrating numerical convergence for Forward Euler and Crank-Nicolson time-stepping: and test_heat_cn_dirichlet.m . They refer to the heat equation codes you can find here. If the Forward Euler script takes too long to run, comment out the one or two most highly resolved runs and comment out subsequent references to those solutions and errors in the script..

    Here are the two scripts I used in class on February 22 demonstrating four schemes for the advection equation: class_Feb_22.m and class_Feb_22a.m. They require the scripts f.m, explicit_upwind.m, lax_friedrichs.m, lax_wendroff.m, beam_warming.m, g.m, explicit_upwind_periodic.m, lax_friedrichs_periodic.m, lax_wendroff_periodic.m, and beam_warming_periodic.m.

    Here are the three scripts I used in class on March 23 demonstrating aliasing error, power spectra, and spectral differentiation class_Mar23_fft.m, class_Mar23_decay.m, and class_Mar23_diff.m. They require the scripts find_spec.m, f.m, d_mid.m, and fdiff.m.

    Here is your final homework assignment. Due by 5pm on Friday April 15.