Chebyshev and Fourier Spectral Methods (Second Revised Edition)