Free-surface boundary conditions

Part 4 — Wave equations in PINN form

Learning objectives

  • State the free-surface BC as Dirichlet u = 0 (acoustic pressure release at z = 0)
  • Apply the §1.5 / §2.4 hard-constraint reparameterisation u = z·NN(x, z, t) to the free surface
  • Compare soft, hard-FS, and hard-both enforcement on a 1D wave problem
  • Recognise that hard constraints eliminate the BC term from the PINN loss entirely

The acoustic free-surface boundary condition models the air-rock interface where the pressure perturbation must vanish: u(x,z=0,t)=0u(x, z = 0, t) = 0. (The elastic version requires zero traction, σzz=σxz=0\sigma_{zz} = \sigma_{xz} = 0, which is more involved.) For the acoustic case it is a clean Dirichlet BC.

This section combines two threads we have already met:

  • The §3.2 loss-balance crisis: BC penalty terms with naive λ=1\lambda = 1 get drowned out by the PDE-residual gradient.
  • The §1.5 / §2.4 hard-constraint trick: reparameterise the network output so the BC is identically satisfied, eliminating the BC term from the loss entirely.

The reparameterisation

For the free-surface BC u(x,z=0,t)=0u(x, z = 0, t) = 0, write

uθ(x,z,t)=zNNθ(x,z,t).u_\theta(x, z, t) = z \cdot \textrm{NN}_\theta(x, z, t) .

At z=0z = 0 the wrap factor zz is zero, so uθ(x,0,t)=0u_\theta(x, 0, t) = 0 identically — the free-surface BC is satisfied by construction. The PDE residual involves derivatives of uθu_\theta; the chain rule gives

zuθ=NN+zzNN,z2uθ=2zNN+zz2NN.\partial_z u_\theta = \textrm{NN} + z \cdot \partial_z \textrm{NN} , \qquad \partial_z^2 u_\theta = 2 \partial_z \textrm{NN} + z \cdot \partial_z^2 \textrm{NN} .

For both BCs at z=0z = 0 AND z=1z = 1 we use uθ(x,z,t)=z(1z)NNu_\theta(x, z, t) = z(1 - z) \cdot \textrm{NN}. The z(1z)z(1 - z) wrap satisfies both Dirichlet BCs identically; the BC term drops out of the loss entirely.

Try it: 1D depth-only problem

For a clean comparison we use a 1D depth problem:

  • Domain z[0,1], t[0,1]z \in [0, 1],\ t \in [0, 1].
  • IC: u(z,0)=sin(πz), ut(z,0)=0u(z, 0) = \sin(\pi z),\ u_t(z, 0) = 0.
  • BC: u(0,t)=0u(0, t) = 0 (free surface), u(1,t)=0u(1, t) = 0 (closed bottom).
  • Analytic: u(z,t)=sin(πz)cos(πt)u(z, t) = \sin(\pi z) \cos(\pi t).

Three modes race: SOFT (both BCs in loss); HARD-FS (only free surface hard, bottom soft); HARD-BOTH (both hard).

Free SurfaceInteractive figure — enable JavaScript to interact.

What you should observe

  • SOFT often gets the IC and PDE right but leaves a small residual at the BC. The relative-L² is typically a few percent.
  • HARD-FS shows mild improvement — one less BC term to balance.
  • HARD-BOTH eliminates both BC terms from the loss entirely. The optimiser only sees PDE + IC, and the BC is satisfied by construction. Convergence is faster and final accuracy higher.

For 2D and 3D wave problems

The same idea extends. In 2D, the reparam uθ(x,z,t)=zNNu_\theta(x, z, t) = z \cdot \textrm{NN} enforces the free surface along the entire z=0z = 0 line. The other three boundaries (left, right, bottom) typically need ABC or PML (§4.6, §4.7), which are NOT Dirichlet and so cannot be hard-enforced. The hybrid — hard free surface, soft/PML elsewhere — is the de-facto standard in modern seismic-PINN papers.

References

  • Lu, L., Pestourie, R., Yao, W., Wang, Z., Verdugo, F., Johnson, S.G. (2021). Physics-informed neural networks with hard constraints for inverse design. SIAM J. Sci. Comput. 43(6).
  • Sukumar, N., Srivastava, A. (2022). Exact imposition of boundary conditions with distance functions in physics-informed deep neural networks. CMAME.

This page is prerendered for SEO and accessibility. The interactive widgets above hydrate on JavaScript load.