Heat Equation

The attached spreadsheet contains a program to solve the 1-dimensional, heat equation, which is a classic equation of mathematical physics of the form:

The program allows user defined functions for the initial and boundary conditions as follows:

u(x,0) = F(x)     'initial condition

u(x1,t) = P(t)    'left boundary

u(x2,t) = Q(t)   'right boundary

The introduction to the spreadsheet gives examples of how this equation is used in heat transfer, mass transfer and flow through porous media, but it is applicable to a wide variety of fields.

The spreadsheet VBA program uses a finite difference method to solve the equation, specifically an explicit forward difference method is used.  This method is not stable in all situation, but the spreadsheet provides guidance and error handling to allow the user to select appropriate time and distance step sizes.

Here is some sample output:

One Dimensional Heat Equation Spreadsheet

heat eq 1-D V2.xls heat eq 1-D V2.xls
Size : 0.101 Kb
Type : xls
Make a Free Website with Yola.