A spectral method for the numerical solution of hyperbolic partial dif
ferential equations is presented. Any discontinuous solutions which ma
y occur are assumed to be the sum of a step function and a smooth func
tion. A series approximation is then applied to the smooth function in
order to eliminate the Gibbs phenomenon. By adding the step function
onto the series we then have an accurate approximation to the solution
at any given time. When discretising in time, a modification is added
to the numerical flux to account for the advection of sharp discontin
uities across cells. We evaluate the method by its application to thre
e standard test problems involving the scalar wave equation, the invis
cid Burgers equation and the Euler equations of gas dynamics. For all
experiments we observe an absence of the Gibbs phenomenon with discont
inuities captured to within a single mesh interval and high accuracy i
s observed in smooth regions.