Reading: Ch 4 - Shumway and Stoffer
Discrete Fourier Transform¶
We ended last lecture talking about the periodogram, which was defined as:
with and .
Today we will relate this to the Discrete Fourier Transform, which is defined as:
Recalling Euler’s formula .
for where the frequencies are the Fourier frequencies. We can then compute the squared modulus of the transform, which represents the total strength of a frequency component regardless of the phase. For example, two signals could have very different mixes of sines and cosines for a frequency , but if their moduli are the same, they have the same power at that frequency.
the scaled periodogram is then
Note also that for so we only have to calculate up to .
As we saw, the periodogram is a raw, noisy estimate computed from sample data. However, we’d also like to have a way to estimate the true underlying spectral structure, so we need learn about the theoretical quantity that the periodogram is estimating. This is the spectral density.
Spectral Density¶
Consider a periodic stationary process with fixed frequency :
with and as uncorrelated zero-mean random variables with equal variance . The frequency tells us what fraction of a complete cycle the process completes between consecutive time points. Equivalently, the process requires time periods to complete one full cycle. We can then calculate the covariance function as:
where is the spectral distribution function defined by:
For details of this integration, your book has a longer explanation and proof in Section C.4.1.
An important property of this spectral distribution function is that if is stationary with autocovariance , then there exists a unique monotonically increasing function such that the relationship described above in (7) applies.
We can think of here as being analogous to a cumulative distribition function (CDF), so the integral above is analogous to an expectation defined with respect to the distribution governing . The total mass is rather than 1. In the case where the autocovariance function is absolutely summable, we have , where we call the spectral density.
that is, we rewrite this as:
This is then the inverse transform of the spectral density function:
This is very cool because the spectral density is then the analog of the probability density function. The fact that is nonnegative ensures that we always have positive values for each frequency: for all . We also have , so typically we only plot for values less than 1/2. For we also have:
This quantity expresses the total variance as the integrated spectral density over all frequencies.
Autocovariance vs. spectral distribution functions¶
These contain similar information but expressed in different ways!
Autocovariance function expresses information in terms of lags
Spectral distribution expresses information in terms of cycles / frequencies
Some problems are easier in the time domain (lagged information), whereas some are easier in the spectral domain (if they contain periodic information).
Theoretical spectra of different processes¶
We have discussed a number of types of processes in this class, so let’s look at their theoretical power spectra.

White noise¶
Recall that a white noise process consists of uncorrelated random variables with variance . The autocovariance of a white noise process is for and 0 otherwise. Thus it follows that the spectral density function is:
for . This means that white noise contains equal power at all frequencies. In fact, we spoke before about how the term “white noise” is related to the analogy to white light, which contains all colors (frequencies). In fact, we can think of spectral analysis like separating our signals like a prism into different colors (spectra).
Linear filtering¶
An important tool in time series analysis is the concept of linear filtering, where we may want to amplify or attentuate different frequencies in our signal. In general, a linear filter uses a set of specified coefficients for , to transform an input series into an output :
Sometimes this is also written as a convolution:
Here the frequency behavior is hidden inside of the pattern of the weights - we can’t immediately see what these are doing because they’re time domain weights. However, we can look at the Fourier transform of these weights (the frequency response function):
After applying a filter like this, we can connect this to the output spectrum for our new signal , and we have:
For a proof, you can look at Chapter 4 of Shumway and Stoffer (Property 4.3).
One thing that’s very nice about this is that convolution in the time domain becomes multiplication in the frequency domain, which makes this representation much more convenient in many time series problems.
Note that this also looks like the property of variances where if , then assuming exists.
Moving Average¶
For the moving average, let’s consider a causal moving average (remember, this is the version where we only consider values from the past in our moving average):
The autocovariance function for this is:
The spectral density is therefore:
in the second line, we used from Euler’s formula .
What results here is that the MA process has a spectral density that decays from zero, with larger corresponding to a steeper decay from to .
Next week we will talk about how to deal with noisiness in the DFT and periodogram through a few different techniques, and we will extend our conversation to time-frequency analysis, where we care about how frequency coefficients change over time.