Partial Differential Equation Toolbox

Key Features

  • PDE app for pre-processing and post-processing 2D PDEs
  • Automatic and adaptive meshing
  • Geometry creation using constructive solid geometry (CSG) paradigm
  • Boundary condition specification: Dirichlet, generalized Neumann, and mixed
  • Flexible coefficient and PDE problem specification using MATLAB syntax
  • Fully automated mesh generation and refinement
  • Nonlinear and adaptive solvers that handle systems with multiple dependent variables
  • Simultaneous visualization of multiple solution properties, FEM-mesh overlays, and animation

Working with the Partial Differential Equation Toolbox

The Partial Differential Equation Toolbox lets you work in six modes from the PDE app or the command line. Each mode corresponds to a step in the process of solving PDEs using the Finite Element Method.

  • Draw mode lets you create Ω, the geometry, using the constructive solid geometry (CSG) model paradigm. The graphical interface provides a set of solid building blocks (square, rectangle, circle, ellipse, and polygon) that can be combined to define complex geometries.
  • Boundary mode lets you specify conditions on different boundaries or remove subdomain borders.
  • PDE mode lets you select the type of PDE problem and the coefficients c, a, f, and d. By specifying the coefficients for each subdomain independently, you can represent different material properties.
  • Mesh mode lets you control the fully automated mesh generation and refinement process.
  • Solve mode lets you invoke and control the nonlinear and adaptive solver for elliptic problems. For parabolic and hyperbolic PDE problems, you can specify the initial values and obtain solutions at specific times. For the eigenvalue solver, you can define the interval over which to search for eigenvalues.
  • Plot mode lets you select from different plot types, including surface, mesh, and contour. You can simultaneously visualize multiple solution properties using color, height, and vector fields. The FEM mesh can be overlaid on all plots and shown in the displaced position. For parabolic and hyperbolic equations, you can animate the solution as it changes with time.
PD Wrenches Image
Partial Differential Equation Toolbox Wrench Image

Using the PDE app to define the complex geometry of a wrench, generate a mesh, and analyze it for a given load configuration.

Defining and Solving PDEs

With the Partial Differential Equation Toolbox, you can define and numerically solve different types of PDEs, including elliptic, parabolic, hyperbolic, eigenvalue, nonlinear elliptic, and systems of PDEs with multiple variables.

Elliptic PDE

The basic scalar equation of the toolbox is the elliptic PDE

PD - Elliptic Equation image

where PD Gradient Symbolis the vector PD Vector image, and c is a 2-by-2 matrix function on PD Equation Omega Image 5571, the bounded planar domain of interest. c, a, and f can be complex valued functions of x and y.

Parabolic, Hyperbolic, and Eigenvalue PDEs

The toolbox can also handle the parabolic PDE

PD Equation Parabolic Image

the hyperbolic PDE

PD Equation Hyperbolic Image

and the eigenvalue PDE

PD Equation Eigen Value Image

where d is a complex valued function on PD Equation Omega Image 5571and PD Lambda Symbolis the eigenvalue. For parabolic and hyperbolic PDEs, c, a, f, and d can be complex valued functions of x, y, and t.

Nonlinear Elliptic PDE

A nonlinear Newton solver is available for the nonlinear elliptic PDE

PD Equation Newton Image

where the coefficients defining c, a, and f can be functions of x, y, and the unknown solution u. All solvers can handle the PDE system with multiple dependent variables

PD Equations Dependent Variables Image

You can handle systems of dimension two from the PDE app. An arbitrary number of dimensions can be handled from the command line. The toolbox also provides an adaptive mesh refinement algorithm for elliptic and nonlinear elliptic PDE problems.

Handling Boundary Conditions

The following boundary conditions can be handled for scalar u:

  • Dirichlet:
PD Equation Dirichlet Image
on the boundary
PD Equation dOmega Image
  • Generalized Neumann:
PD Equation Neumann Image
PD Equation dOmega Image
PD Equation N Image
is the outward unit normal and g, q, h, and r can be complex valued functions of x and y defined on
PD Equation dOmega Image
. For the nonlinear PDE, the coefficients may depend on u. For time-dependent problems, the coefficients may also depend on t. For PDE systems, Dirichlet, generalized Neumann, and mixed boundary conditions are supported.
Partial Differential Equation Toolbox Visualizations Tools Image

Visualization tools provide multiple ways to plot results. A contour plot with gradient arrows shows the temperature and heat flux. The temperature gradient is displayed using 3-D plotting tools.

Toolbox Application Modes

The Partial Differential Equation Toolbox includes a set of application modes for common engineering and science problems. When you select a mode, PDE coefficients are replaced with application-specific parameters, such as Young’s modulus for problems in structural mechanics. Available modes include:

  • Structural Mechanics - Plane Stress
  • Structural Mechanics - Plane Strain
  • Electrostatics
  • Magnetostatics
  • AC Power Electromagnetics
  • Conductive Media DC
  • Heat Transfer
  • Diffusion

The boundary conditions are altered to reflect the physical meaning of the different boundary condition coefficients. The plotting tools let you visualize the relevant physical variables for the selected application.

See how MATLAB and Simulink products fit within your application

Learn more