PINN · Architecture Specification

Physics-Informed Neural PDE Solver

Direct unsupervised integration of the 1D parabolic heat diffusion equation using PyTorch automatic differentiation and composite boundary-residual loss.

PINN Heat Equation Solver Architecture Architecture showing domain collocation sampling, deep surrogate MLP with automatic differentiation, composite physics loss formulation, and Fourier analytical verification. 1. SPATIO-TEMPORAL SAMPLING 2. SURROGATE & AUTODIFF 3. COMPOSITE LOSS & PARITY u(x, t) field Residuals Collocation Interior (x_f, t_f) Uniform random in (0, 1) × (0, 1) Initial State (x_i, t=0) u(x, 0) = sin(π x) Dirichlet Boundaries (x=0, 1) u(0, t) = 0, u(1, t) = 0 Deep Surrogate Network (MLP) Input: [x, t] → 3 hidden layers × 32 units (Tanh) Output: Scalar prediction u_pred(x, t) Automatic Differentiation Engine torch.autograd.grad() ∂u/∂t via single backward graph ∂²u/∂x² via second-order Hessian trace Exact continuous derivatives without discretization error Physical Residual Evaluation Residual = ∂u/∂t - α · ∂²u/∂x² Diffusivity parameter α = 0.01 Composite Loss Function L_total = L_pde + L_ic + L_bc L_pde = mean(Residual²) L_bc = mean(u_left²) + mean(u_right²) Adam Gradient Optimization 5,000 Epochs · Learning rate 1e-3 Unsupervised convergence Analytical Fourier Parity ✓ Rel. L2 Error: 1.6e-3 Max pointwise error: ~4e-3 Exact mode decay verified

Formulation

Zero Training Data

Trained purely on governing physical laws and boundary conditions. The neural network infers the full continuous solution space without any ground-truth field observations.

Mathematics

Exact Differential Operators

Uses PyTorch's computational graph to obtain analytical-grade spatial and temporal partial derivatives (∂u/∂t and ∂²u/∂x²), entirely eliminating mesh truncation errors.

Validation

Analytical Benchmark

Benchmarked on an 80×80 space-time grid against the Fourier analytical solution u(x, t) = exp(-α π² t) sin(π x), achieving relative L2 error of 1.6e-3.