Scientific Machine Learning (SciML)

PINNs Lab

Interactive and rigorous exploration of Physics-Informed Neural Networks (PINNs). Uniting conservation laws, differential operators, and deep learning to solve forward and inverse problems in fluid dynamics and dynamical systems.

Interactive Simulation

1D Burgers Equation with PINN Solution

Live Interactive Mode

The nonlinear viscous Burgers equation $\partial_t u + u \, \partial_x u = \nu \, \partial_{xx} u$ models shock discontinuities and incipient turbulence. Adjust kinematic viscosity $\nu$ and evolution time $t$ to observe how the neural network captures sharp shock fronts without spurious numerical oscillations.

PINN Prediction $u_\theta(x, t)$ Exact Reference Solution
Kinematic Viscosity ($\nu$):0.020
0.005 (Sharp shock)0.080 (Diffusive)
Evolution Time ($t$):0.45 s
0.00 s (Initial)1.40 s (Dissipation)
Max Gradient $|\partial_x u|$14.82
Residual Loss $\mathcal{L}_{\text{pde}}$< 3.2 × 10⁻⁴
Theoretical & Computational Framework

Formal Definition of a PINN (Physics-Informed Neural Network)

A PINN (Raissi, Perdikaris & Karniadakis, 2019) does not merely fit passive empirical patterns over big data; it acts as a continuous functional approximator rigorously constrained by partial differential equations (PDEs).

Pillar 1: Continuum Physics

General Differential Formulation

$$\mathcal{N}[u](x, t) = f(x, t), \quad (x, t) \in \Omega \times [0, T]$$
$$\mathcal{B}[u](x, t) = g(x, t), \quad x \in \partial\Omega; \quad u(x, 0) = h(x), \quad x \in \Omega$$

Where $\mathcal{N}$ denotes a nonlinear differential operator (e.g. advection-diffusion or Navier-Stokes), $\mathcal{B}$ specifies boundary conditions (Dirichlet, Neumann, or Robin), and $u(x, t)$ is the unknown state field (velocity, pressure, or temperature).

Pillar 2: Exact Differentiation

Autograd Graph vs. Classical Meshes

$$\partial_t u_\theta = \frac{\partial u_\theta}{\partial t}, \quad \nabla u_\theta = \left(\frac{\partial u_\theta}{\partial x_1}, \dots, \frac{\partial u_\theta}{\partial x_d}\right)$$
$$\Delta u_\theta = \sum_{i=1}^d \frac{\partial^2 u_\theta}{\partial x_i^2}$$

A deep neural network $u_\theta(x, t)$ parameterizes the continuous field. Through reverse-mode automatic differentiation (PyTorch torch.autograd), derivatives are evaluated via the exact analytic chain rule—completely mesh-free and exempt from discretization truncation error $\mathcal{O}(\Delta x^2)$.

Pillar 3: Multi-Objective Optimization

Composite Loss on Collocation Points

$$\mathcal{L}(\theta) = w_{\text{data}} \mathcal{L}_{\text{data}} + w_{\text{pde}} \mathcal{L}_{\text{pde}} + w_{\text{bc}} \mathcal{L}_{\text{bc}} + w_{\text{ic}} \mathcal{L}_{\text{ic}}$$
$$\mathcal{L}_{\text{pde}} = \frac{1}{N_f} \sum_{j=1}^{N_f} \left| \mathcal{N}[u_\theta](x_j^f, t_j^f) - f(x_j^f, t_j^f) \right|^2$$

Training simultaneously minimizes sparse empirical observation error ($\mathcal{L}_{\text{data}}$), interior physical PDE residuals across $N_f$ collocation points ($\mathcal{L}_{\text{pde}}$), and initial/boundary constraints ($\mathcal{L}_{\text{bc}}, \mathcal{L}_{\text{ic}}$). Dynamic weighting coefficients $w_k$ balance gradient stiffness.

Rigorous Mathematical Foundations

The Universal Approximation Theorem for Derivatives

Why does a neural network provably solve differential equations? The formal answer lies in extending Cybenko and Hornik's classical theorems into Sobolev spaces $W^{m, p}(K)$.

Classical Theorem (1989 · 1991)

Continuous Function Approximation

$$\sup_{x \in K} |u_\theta(x) - f(x)| \lt \epsilon, \quad \forall f \in C(K)$$

George Cybenko (1989) and Kurt Hornik (1991) established that single-hidden-layer feedforward networks with non-polynomial or sigmoidal activations are dense in the continuous space $C(K)$ over compact domains $K \subset \mathbb{R}^d$.

Extension to Derivatives (Pinkus, 1999 · Lu et al., 2021)

Density in Sobolev Spaces $C^m(K)$

$$\|u_\theta - f\|_{C^m(K)} = \sum_{|\alpha| \le m} \sup_{x \in K} \left| \partial^\alpha u_\theta(x) - \partial^\alpha f(x) \right| \lt \epsilon$$

When activation function $\sigma$ is smooth ($\sigma \in C^m(\mathbb{R})$, such as $\tanh$, $\text{sin}$, or GELU), network $u_\theta$ not only approximates $f$, but its automatic derivatives $\partial^\alpha u_\theta$ simultaneously approximate true partial derivatives $\partial^\alpha f$ up to order $m$.

Core Implication for PINNs

Because neural network spaces are dense under Sobolev norms, minimizing the differential equation residual $\|\mathcal{N}[u_\theta] - f\|_{L^2(K)} \to 0$ mathematically guarantees that the network converges toward the true analytical solution, establishing theoretical validity beyond empirical heuristic.

AWS Community Day Ecuador 2026SciML & Cloud Architecture

PINNs at AWS Community Day Ecuador 2026: Scaling SciML in the Cloud

Keynote technical lecture and hands-on laboratory conducted by Jefferson Conza on designing, distributedly accelerating, and deploying Physics-Informed Neural Networks for real-time digital twins in production.

⚡

Distributed GPU Compute

High-throughput training across Amazon EC2 (NVIDIA A10G / G5) and Amazon SageMaker instances. Parallelized 2nd-order autograd computational graphs using PyTorch DDP and DeepXDE.

🎯

Adaptive RAR Collocation

Algorithmic implementation of Residual-based Adaptive Refinement (RAR), dynamically sensing shock discontinuities and injecting interior collocation points on-the-fly.

💾

S3 Data Lake & Checkpoints

Resilient persistence in Amazon S3 featuring tensor state versioning, CloudWatch loss telemetry, and least-privilege IAM access policies.

🚀

Microservice Inferencia APIs

Dockerized microservice deployment with FastAPI on AWS App Runner, serving millisecond velocity and pressure state inferences for real-time digital twins.

Related Case Studies & Technical Essays

SciML Foundations

PINNs: When the Laws of Physics Guide Neural Networks

Rigorous introduction to automated differentiation graphs, interior collocation loss formulations, and engineering applications.

Read Essay →
Fluid Dynamics

OpenAI and the Navier-Stokes Mathematical Problem

In-depth analysis of Lean 4 computer-assisted formal verification, the layer cascade strategy, and finite-time blowup scenarios.

Explore Article →