PDE Calculator

Solve partial differential equations using numerical methods with detailed step-by-step solutions and visualization.

PDE Solver Configuration

Select PDE type, method, and input parameters

Heat Equation
Wave Equation
Laplace Equation
Custom PDE 1D
∂u/∂t = α ∂²u/∂x²
∂²u/∂t² = c² ∂²u/∂x²
∂²u/∂x² + ∂²u/∂y² = 0
Explicit
Implicit
Crank-Nicolson

PDE Solution

PNG
SVG
CSV
-
Status
-
Iterations
-
Max Error
-
Time Step

Recent Calculations

What are Partial Differential Equations?

Partial Differential Equations (PDEs) are equations that involve rates of change with respect to continuous variables. They describe how quantities change in space and time.

Unlike ordinary differential equations (ODEs) which involve derivatives with respect to a single variable, PDEs involve partial derivatives with respect to multiple independent variables.

General form of a second-order PDE:

A ∂²u/∂x² + B ∂²u/∂x∂y + C ∂²u/∂y² + D ∂u/∂x + E ∂u/∂y + F u = G

PDEs are classified based on the discriminant B² - 4AC:

  • Elliptic (B² - 4AC < 0): Laplace equation, Poisson equation
  • Parabolic (B² - 4AC = 0): Heat equation, diffusion equation
  • Hyperbolic (B² - 4AC > 0): Wave equation, transport equation

This PDE calculator helps solve these equations numerically with high precision, providing visualization and step-by-step solutions.

Types of Partial Differential Equations

PDEs are categorized based on their mathematical properties and physical interpretations:

Heat Equation (Parabolic)

Models heat diffusion and other diffusion processes

∂u/∂t = α ∇²u
Applications: Heat transfer, Brownian motion

Wave Equation (Hyperbolic)

Describes wave propagation and vibrations

∂²u/∂t² = c² ∇²u
Applications: Sound waves, light waves

Laplace Equation (Elliptic)

Models steady-state phenomena

∇²u = 0
Applications: Electrostatics, fluid flow

Poisson Equation (Elliptic)

Laplace equation with source term

∇²u = f(x,y)
Applications: Gravity, electrostatics

Burgers' Equation

Models shock waves and turbulence

∂u/∂t + u ∂u/∂x = ν ∂²u/∂x²
Applications: Fluid dynamics, traffic flow

Schrödinger Equation

Quantum mechanics wave equation

iħ ∂ψ/∂t = -ħ²/2m ∇²ψ + Vψ
Applications: Quantum physics

Numerical Methods for PDEs

Our calculator implements several numerical methods for solving PDEs:

1

Finite Difference Method

Approximates derivatives using difference quotients on a grid. Simple implementation but stability constraints.

2

Finite Element Method

Divides domain into elements, approximates solution as piecewise polynomials. Good for complex geometries.

3

Finite Volume Method

Conserves quantities exactly over control volumes. Excellent for conservation laws.

4

Spectral Methods

Uses global basis functions (Fourier, Chebyshev). High accuracy for smooth solutions.

5

Method of Lines

Discretizes space first, then solves resulting ODE system in time using ODE solvers.

6

Separation of Variables

Assumes solution is product of functions of single variables. Works for linear PDEs with simple boundaries.

For time-dependent PDEs, we implement:

  • Explicit methods: Forward Euler (simple but conditionally stable)
  • Implicit methods: Backward Euler (unconditionally stable but requires solving linear systems)
  • Crank-Nicolson method: Second-order accurate in time, unconditionally stable

Applications of PDEs

Partial differential equations are fundamental to modeling physical phenomena across science and engineering:

Physics

PDEs model fundamental physical processes:

  • Maxwell's equations (electromagnetism)
  • Schrödinger equation (quantum mechanics)
  • Navier-Stokes equations (fluid dynamics)
  • Einstein field equations (general relativity)

Engineering

Engineering design and analysis relies on PDEs:

  • Heat transfer in engines and electronics
  • Structural analysis and stress distribution
  • Electromagnetic field computation
  • Acoustics and vibration analysis

Finance

Financial mathematics uses PDEs for pricing:

  • Black-Scholes equation (option pricing)
  • Interest rate models
  • Risk management and portfolio optimization
  • Stochastic volatility models

Biology & Medicine

Biological systems modeled with PDEs:

  • Reaction-diffusion systems (pattern formation)
  • Tumor growth models
  • Neural activity propagation
  • Drug diffusion in tissues

Computer Graphics

PDEs create realistic simulations:

  • Fluid animation (smoke, water)
  • Cloth and hair simulation
  • Image processing and computer vision
  • Geometric modeling

Earth Sciences

Geophysical phenomena described by PDEs:

  • Weather prediction models
  • Ocean circulation patterns
  • Seismic wave propagation
  • Groundwater flow

Common PDEs and Their Solutions

Explore solutions to frequently encountered partial differential equations:

Heat Equation

∂u/∂t = α ∂²u/∂x²
Models heat diffusion in one dimension. With initial condition u(x,0)=f(x) and boundary conditions u(0,t)=u(L,t)=0.

Wave Equation

∂²u/∂t² = c² ∂²u/∂x²
Describes wave propagation. With initial displacement u(x,0)=f(x) and velocity ∂u/∂t(x,0)=g(x).

Laplace Equation

∂²u/∂x² + ∂²u/∂y² = 0
Models steady-state temperature distribution. With boundary conditions specified on a rectangular domain.

Poisson Equation

∇²u = f(x,y)
Laplace equation with source term. Models gravitational or electrostatic potential with mass/charge distribution.

Burgers' Equation

∂u/∂t + u ∂u/∂x = ν ∂²u/∂x²
Models shock waves and turbulence. Combines nonlinear convection with diffusion.

Advection Equation

∂u/∂t + c ∂u/∂x = 0
Models transport of a quantity without diffusion. Solution propagates with speed c.

Solved PDE Examples

Step-by-step solutions to common PDE problems:

Heat Equation: Rod Cooling
Solve: ∂u/∂t = 0.1 ∂²u/∂x² for 0 ≤ x ≤ 1, t ≥ 0
Initial: u(x,0) = sin(πx)
Boundary: u(0,t) = u(1,t) = 0
Solution: u(x,t) = e^(-0.1π²t) sin(πx)
1. Assume separation of variables: u(x,t) = X(x)T(t)
2. Substitute into PDE: XT' = 0.1 X''T
3. Separate variables: T'/0.1T = X''/X = -λ
4. Solve ODEs with boundary conditions
5. Apply initial condition using Fourier series
Wave Equation: Vibrating String
Solve: ∂²u/∂t² = 4 ∂²u/∂x² for 0 ≤ x ≤ π, t ≥ 0
Initial: u(x,0) = sin(x), ∂u/∂t(x,0) = 0
Boundary: u(0,t) = u(π,t) = 0
Solution: u(x,t) = sin(x) cos(2t)
1. Assume separation: u(x,t) = X(x)T(t)
2. Get: X''/X = T''/4T = -λ
3. Solve spatial ODE: X'' + λX = 0
4. Solve temporal ODE: T'' + 4λT = 0
5. Apply initial conditions
Laplace Equation: Steady Temperature
Solve: ∂²u/∂x² + ∂²u/∂y² = 0 for 0 ≤ x,y ≤ 1
Boundary: u(0,y)=0, u(1,y)=sin(πy), u(x,0)=0, u(x,1)=0
Solution: u(x,y) = sinh(πx) sin(πy)/sinh(π)
1. Assume separation: u(x,y) = X(x)Y(y)
2. Get: X''/X = -Y''/Y = λ
3. Solve ODEs with boundary conditions
4. Apply non-homogeneous boundary condition
5. Construct solution using eigenfunction expansion

PDE Practice Problems

Test your understanding with these practice problems:

Problem 1: Solve the heat equation ∂u/∂t = ∂²u/∂x² with u(x,0)=x(1-x) and u(0,t)=u(1,t)=0.

Solution: Use separation of variables. The solution is:

u(x,t) = Σ (8/(nπ)³)[1 - (-1)^n] e^(-n²π²t) sin(nπx)

For n = 1,3,5,...

Problem 2: Solve the wave equation ∂²u/∂t² = 9∂²u/∂x² with u(x,0)=sin(πx), ∂u/∂t(x,0)=0, and u(0,t)=u(1,t)=0.

Solution: Using d'Alembert's formula:

u(x,t) = sin(πx) cos(3πt)
Problem 3: Solve Laplace equation on unit square with u(0,y)=0, u(1,y)=y(1-y), u(x,0)=0, u(x,1)=0.

Solution: Separation of variables gives:

u(x,y) = Σ [4(1-(-1)^n)/(nπ)³] sinh(nπx) sin(nπy)/sinh(nπ)
Problem 4: Solve ∂u/∂t + 2∂u/∂x = 0 with u(x,0)=exp(-x²).

Solution: This is a transport equation. The solution is:

u(x,t) = exp(-(x-2t)²)

The initial profile moves to the right with speed 2.

How to Solve PDEs Step-by-Step

Understanding the mathematical process behind PDE solutions:

1

Problem Setup

Identify the PDE type, domain, initial conditions, and boundary conditions.

Example: Heat equation on [0,1]
∂u/∂t = α ∂²u/∂x²
u(x,0) = f(x)
u(0,t) = u(1,t) = 0
2

Discretization

Create grid in space and time. For finite differences:

xᵢ = iΔx, i=0,...,N
tⁿ = nΔt, n=0,...,M
uᵢⁿ ≈ u(xᵢ, tⁿ)
3

Approximate Derivatives

Replace derivatives with finite differences:

∂u/∂t ≈ (uᵢⁿ⁺¹ - uᵢⁿ)/Δt
∂²u/∂x² ≈ (uᵢ₊₁ⁿ - 2uᵢⁿ + uᵢ₋₁ⁿ)/Δx²
4

Construct Scheme

Substitute approximations into PDE to get numerical scheme.

Explicit: uᵢⁿ⁺¹ = uᵢⁿ + αΔt/Δx² (uᵢ₊₁ⁿ - 2uᵢⁿ + uᵢ₋₁ⁿ)
Implicit: Solve linear system at each time step
5

Implement Algorithm

Write code to iterate scheme forward in time, applying boundary conditions at each step.

for n = 0 to M-1:
  for i = 1 to N-1:
    Update uᵢⁿ⁺¹
  Apply boundary conditions
6

Analyze Results

Check stability, convergence, and accuracy. Visualize solution.

Stability condition: αΔt/Δx² ≤ 0.5
Error analysis: |u_exact - u_numeric|

Our PDE Calculator automates these steps, providing accurate numerical solutions with visualization for educational and professional use.

Frequently Asked Questions

Common questions about PDEs and our calculator.

What is a PDE calculator?
A PDE calculator solves partial differential equations using numerical and analytical methods. It helps compute solutions for equations involving multiple variables and their partial derivatives, including real-world physical systems.
What types of PDEs can this calculator solve?
This calculator solves linear PDEs such as parabolic (heat equation), hyperbolic (wave equation), and elliptic (Laplace and Poisson equations). It supports both time-dependent and steady-state problems.
What numerical methods are used in this PDE calculator?
The calculator uses finite difference methods including explicit, implicit, and Crank-Nicolson schemes. It may also use iterative solvers like Gauss-Seidel and Successive Over-Relaxation (SOR) for higher accuracy.
Can I visualize PDE solutions?
Yes, the calculator provides 2D and 3D visualizations such as surface plots, contour maps, and time-based animations to help understand how solutions evolve.
How accurate are the results?
Accuracy depends on grid size and time steps. The calculator uses high-precision numerical techniques and allows refinement of parameters to improve solution accuracy.
What are boundary conditions in PDEs?
Boundary conditions define how the solution behaves at the edges of the domain. Common types include Dirichlet (fixed value), Neumann (fixed gradient), and Robin (mixed conditions).
What is the heat equation?
The heat equation models the distribution of temperature over time. It is a parabolic PDE widely used in physics and engineering for heat transfer analysis.
What is the wave equation?
The wave equation describes how waves propagate through a medium, such as sound waves, light waves, or vibrations in strings.
What is Laplace’s equation?
Laplace’s equation is an elliptic PDE used to describe steady-state systems like electric potential, fluid flow, and gravitational fields.
Can this calculator solve nonlinear PDEs?
Most online PDE calculators primarily focus on linear PDEs. However, some advanced cases of nonlinear PDEs may be approximated using numerical techniques.
What industries use PDEs?
PDEs are used in engineering, physics, finance, machine learning, fluid dynamics, and heat transfer to model complex systems and real-world phenomena.
Can I solve time-dependent PDEs?
Yes, the calculator supports time-dependent PDEs like the heat and wave equations, allowing you to observe how solutions evolve over time.
Is this PDE calculator free to use?
Yes, this PDE calculator is completely free and accessible online with no registration required.