Motivated by the numerical computation of the Mean Escape Time (MET)
τ:Ω→R of a stochastic process from a bounded domain
Ω⊆Rd, we study elliptic Dirichlet boundary value problems (BVPs) using boundary-enforced Physics-Informed Neural Networks (PINNs), in which the Dirichlet condition is imposed exactly by multiplying the network output with a predefined distance-to-boundary approximation
ρ. Combining approximation-theoretic and statistical-learning arguments for Rectified Quadratic Unit (ReQU) and hyperbolic tangent (tanh) networks, we derive a priori error bounds that make explicit the dependence on
ρ. In particular, we show that exact boundary enforcement alone is not enough for
H2(Ω) error bounds, and that a sufficient and essentially necessary condition is for
ρ to be a smooth distance approximation
normalized to first order, of the kind constructed in arXiv:2104.08426 [math.NA]. We thereby identify this subclass of
boundary-adapted PINNs as the appropriate neural network ansatz for solving Dirichlet BVPs. Numerical experiments support the theory, showing that appropriate choices of
ρ improve accuracy and convergence, while poorly chosen distance functions can substantially degrade the solution. Our proof also yields new VC-dimension bounds for hypothesis spaces of higher-order derivatives of ReQU and tanh networks, together with new approximation bounds for shallow ReQU networks in higher-order Sobolev norms, all of which are of important independent interest.