  This paper presents a spectral scheme for the numerical solution of nonlinear
conservation laws in non-periodic domains under arbitrary boundary conditions.
The approach relies on the use of the Fourier Continuation (FC) method for
spectral representation of non-periodic functions in conjunction with smooth
localized artificial viscosity assignments produced by means of a
Shock-Detecting Neural Network (SDNN). Like previous shock capturing schemes
and artificial viscosity techniques, the combined FC-SDNN strategy effectively
controls spurious oscillations in the proximity of discontinuities. Thanks to
its use of a localized but smooth artificial viscosity term, whose support is
restricted to a vicinity of flow-discontinuity points, the algorithm enjoys
spectral accuracy and low dissipation away from flow discontinuities, and, in
such regions, it produces smooth numerical solutions -- as evidenced by an
essential absence of spurious oscillations in level set lines. The FC-SDNN
viscosity assignment, which does not require use of problem-dependent
algorithmic parameters, induces a significantly lower overall dissipation than
other methods, including the Fourier-spectral versions of the previous entropy
viscosity method. The character of the proposed algorithm is illustrated with a
variety of numerical results for the linear advection, Burgers and Euler
equations in one and two-dimensional non-periodic spatial domains.
