Neural Network Surrogate Modeling for 2D Heat Diffusion
Accuracy, Rollout Stability, and Physics-Informed Training
A CNN surrogate replacing a finite-difference solver for the 2D heat equation (∂T/∂t = α∇²T) on a 64×64 grid with Dirichlet boundaries and α = 0.01. Trained on 10,000 solver-generated pairs (8k / 1k / 1k split), each mapping the field at time t to the field 10 solver steps later. 74,433 parameters — evaluated on single-step accuracy, speed, long-horizon rollout, out-of-distribution generalization, ablations, and physics-informed training.

Median relative L2 error (mean 2.11%) on 1,000 test samples
Faster than the solver (5.70 ms vs 127.39 ms). Crossover near N ≈ 200–256; ~18× slower at N=64
Error growth from 1.82% to 30.06%
Boundary violations, down from 16/21, at only +0.093 pp accuracy cost
Severe failure at α = 0.05; mild degradation near boundaries (5.58%) and low amplitude (8.75%)
Best at 5,000 samples. 64 filters overfit (4.15%); resolution barely matters
Decay-rate sign reversal
Accurate at one step, yet during rollout the CNN's mean temperature grows while the solver's decays. Exponential fits give λ = −0.198 (CNN) vs +0.115 (solver) — a ~1.45% per-step heat-retention bias, invisible at single-step level, compounds over 20 steps.
Metric normalization artifact
OOD cases with more or wider blobs look better under relative L2 (1.29% vs 2.19%) because their larger ‖T‖₂ inflates the denominator — not because predictions improve. Absolute MAE should be reported alongside relative error.
Over-dissipation in physics-informed training
The ReLU energy penalty fixes decay direction but has no lower bound, so the model cools too fast: at λ = 0.1 the step-20 mean temperature is 34% of the solver's instead of ~82%. A symmetric loss is proposed as the fix (untested).
Homogeneous domain, a single α, Dirichlet boundaries only, synthetic data, and a plain CNN without skip connections. MSE loss is dominated by background pixels; the symmetric energy loss and α-conditioning remain untested.































