Example: Using pdesolve with Units
Use the pdesolve function to solve the heat equation.
1. Create the following input parameters: nTime and nX are the number of grid points.τMax is the upper boundary of the trange, and a is a coefficient.
2. Set up the PDE solve block. Use the heat equation and add a set of initial conditions. Use units (m) inside the solve block.
3. To visualize the solution in a 3D plot, use the
CreateMesh function.
4. Plot the solution using a 3D plot.
5. Plot the solution using a contour plot.