Tutorials › Stochastic Processes › Spectral Densities and Fourier Inversion

Weak Stationarity and Spectral Representation · Tutorial 897 of 994

Spectral Densities and Fourier Inversion

Learn when a spectral density exists, how its normalization determines the covariance integral, and how to recover covariances from several densities.

Advanced 12 min read

What You'll Learn

  • Define spectral density as the derivative of an absolutely continuous spectral measure
  • Use the angular-frequency convention to recover each covariance by Fourier integration
  • Check the density’s total mass against the variance
  • Distinguish a full spectral density from a density that represents only part of a measure
  • Compute covariance sequences from constant, trigonometric, and interval-supported densities
  • Avoid normalization errors between angular-frequency conventions

From Spectral Measure to Spectral Density

A spectral measure distributes the variance of a weakly stationary process across frequencies. When that measure has a density, integration against the density recovers each covariance. The normalization matters: with angular frequency on \([-\pi,\pi)\) and ordinary Lebesgue measure \(d\lambda\), white noise of variance \(\sigma^2\) has constant density \(\sigma^2/(2\pi)\), not \(\sigma^2\).

Let \((X_n)_{n\in\mathbb Z}\) be a real-valued process on a probability space \((\Omega,\mathcal F,\mathbb P)\), with state space \(S=\mathbb R\) and \(\mathbb E[X_n^2]<\infty\). Assume it is weakly stationary: its mean is constant, and its covariance depends only on the lag. Write \(\gamma(h)=\operatorname{Cov}(X_{n+h},X_n)\), for \(h\in\mathbb Z\). Its spectral measure \(F\) is a finite positive measure on the frequency circle, represented by \([-\pi,\pi)\) with the endpoints identified, under the convention

$$ \gamma(h)=\int_{[-\pi,\pi)} e^{ih\lambda}\,F(d\lambda), \qquad h\in\mathbb Z. $$

This is the angular-frequency convention for the spectral measure. In particular, \(F([-\pi,\pi))=\gamma(0)=\operatorname{Var}(X_n)\). The existence of such a finite positive measure for a weakly stationary covariance sequence is the standard Herglotz theorem from the earlier material on spectral measures.

Definition: The spectral measure \(F\) is absolutely continuous with respect to Lebesgue measure if every Lebesgue-null set has \(F\)-measure zero. In that case its spectral density is a nonnegative integrable function \(f\) satisfying \(F(B)=\int_B f(\lambda)\,d\lambda\) for every measurable set \(B\subseteq[-\pi,\pi)\). The density is determined only up to changes on a Lebesgue-null set.

The phrase “has a spectral density” means that the entire spectral measure is represented by this integral. If a spectral measure has a part that is not absolutely continuous, a density for its absolutely continuous part alone does not recover the entire covariance sequence. No continuity or boundedness of \(f\) is required: integrability and nonnegativity almost everywhere are enough.

Fourier Inversion for Covariances

Theorem (Covariance inversion from a density): Suppose a weakly stationary process has spectral measure \(F\) under the convention above, and \(F\) is absolutely continuous with spectral density \(f\). Then \(f\geq 0\) almost everywhere, \(\int_{-\pi}^{\pi} f(\lambda)\,d\lambda=\gamma(0)\), and for every integer \(h\), $$ \gamma(h)=\int_{-\pi}^{\pi} e^{ih\lambda}f(\lambda)\,d\lambda. $$ For a real-valued process, \(\gamma(-h)=\gamma(h)\); correspondingly, its spectral measure is symmetric, and its density can be chosen even almost everywhere.

Proof. Absolute continuity means, by the definition of the density, that \(F(d\lambda)=f(\lambda)\,d\lambda\). Since \(F\) is a positive measure, its density is nonnegative almost everywhere. Taking \(h=0\) in the spectral-measure representation gives \(\gamma(0)=F([-\pi,\pi))\). The density definition then gives \(\gamma(0)=\int_{-\pi}^{\pi}f(\lambda)\,d\lambda\); changing the value at the single identified endpoint does not affect this Lebesgue integral. For any integer \(h\), substitute \(F(d\lambda)=f(\lambda)\,d\lambda\) into the representation of \(\gamma(h)\) to obtain \(\gamma(h)=\int_{-\pi}^{\pi}e^{ih\lambda}f(\lambda)\,d\lambda\). Finally, for a real process, covariance symmetry gives \(\gamma(-h)=\gamma(h)\). The uniqueness of the spectral measure in the Herglotz representation implies that reflecting its frequencies leaves the measure unchanged; its density is therefore equal to its reflection almost everywhere. \(\square\)

The integral is a Fourier coefficient of \(f\), with the sign fixed by the stated convention. It directly recovers each covariance; it does not assert that a density can be recovered pointwise from an arbitrary covariance sequence by summing a Fourier series. Pointwise Fourier-series inversion needs additional hypotheses and is a different question.

A useful converse check is that a proposed density cannot generate negative variances or an invalid covariance sequence. For an even density, this follows from positivity of the measure it defines.

Proposition: Let \(f\) be a nonnegative, integrable, even function on \([-\pi,\pi)\), with the endpoints identified. Define \(\gamma(h)=\int_{-\pi}^{\pi}e^{ih\lambda}f(\lambda)\,d\lambda\). Then \(\gamma(0)=\int f\), \(\gamma(h)\) is real and satisfies \(\gamma(-h)=\gamma(h)\), and \(\gamma\) is positive definite: for every integer \(m\geq 1\), every \(n_1,\ldots,n_m\in\mathbb Z\), and every \(c_1,\ldots,c_m\in\mathbb C\), $$ \sum_{r=1}^{m}\sum_{s=1}^{m}c_r\overline{c_s}\,\gamma(n_r-n_s)\geq 0. $$

Proof. At lag zero, the exponential is \(1\), so \(\gamma(0)=\int f\). Since \(f\) is real and even, the sine part of \(\int e^{ih\lambda}f(\lambda)\,d\lambda\) integrates to zero, while the cosine part is real and unchanged when \(h\) is replaced by \(-h\). For positive definiteness, use the defining integral and finite-sum linearity to write \(\sum_{r,s}c_r\overline{c_s}\gamma(n_r-n_s)=\int f(\lambda)\sum_{r,s}c_r\overline{c_s}e^{i(n_r-n_s)\lambda}\,d\lambda\). The inner sum equals \(\left|\sum_r c_r e^{in_r\lambda}\right|^2\). Thus the expression is \(\int f(\lambda)\left|\sum_r c_r e^{in_r\lambda}\right|^2\,d\lambda\), which is nonnegative because \(f\geq0\) almost everywhere. This proves all the claims. By the standard Herglotz theorem, this positive-definite sequence is a valid covariance sequence. \(\square\)

Worked Covariance Integrals

Worked Example: Constant Density and White Noise

Suppose a weakly stationary real process has spectral density \(f(\lambda)=\tfrac{3}{2\pi}\) on \([-\pi,\pi)\). Recover its covariance at every integer lag.

First check the total mass: \(\int_{-\pi}^{\pi}\tfrac{3}{2\pi}\,d\lambda=\tfrac{3}{2\pi}(2\pi)=3\), so the variance is \(3\). At lag zero, \(\gamma(0)=3\). For a nonzero integer \(h\), direct integration gives

$$ \gamma(h)=\frac{3}{2\pi}\int_{-\pi}^{\pi}e^{ih\lambda}\,d\lambda =\frac{3}{2\pi}\left[\frac{e^{ih\lambda}}{ih}\right]_{-\pi}^{\pi} =\frac{3}{2\pi}\frac{e^{ih\pi}-e^{-ih\pi}}{ih} =\frac{3\sin(h\pi)}{\pi h}=0. $$

Here \(\sin(h\pi)=0\) because \(h\) is an integer. Therefore the covariance is \(3\) at lag zero and \(0\) at every nonzero lag, as for white noise with variance \(3\).

Check: the lag-zero integral gives variance \(3\), and the nonzero-lag integral vanishes. Thus the total mass and the full covariance sequence agree with the stated density.

Worked Example: A Trigonometric Density

Let \(f(\lambda)=\tfrac{1}{2\pi}(2+\cos\lambda)\) on \([-\pi,\pi)\). This is nonnegative because \(2+\cos\lambda\geq1\), and it is even. Compute all the covariances.

The total mass is \(\tfrac{1}{2\pi}\int_{-\pi}^{\pi}2\,d\lambda+\tfrac{1}{2\pi}\int_{-\pi}^{\pi}\cos\lambda\,d\lambda=2+0=2\), so \(\gamma(0)=2\). For an integer \(h\), use \(\cos\lambda=\tfrac12(e^{i\lambda}+e^{-i\lambda})\):

$$ \gamma(h)=\frac{1}{2\pi}\int_{-\pi}^{\pi}2e^{ih\lambda}\,d\lambda +\frac{1}{4\pi}\int_{-\pi}^{\pi} \left(e^{i(h+1)\lambda}+e^{i(h-1)\lambda}\right)\,d\lambda. $$

For any integer \(k\), \(\int_{-\pi}^{\pi}e^{ik\lambda}\,d\lambda=2\pi\) when \(k=0\), and is \(0\) when \(k\ne0\). The first integral therefore contributes \(2\) if \(h=0\) and \(0\) otherwise. The second contributes \(\tfrac12\) if \(h=-1\) or \(h=1\), and \(0\) for all other integer lags. At \(h=0\), both exponents in the second integral have nonzero frequency, so that term contributes zero. Hence \(\gamma(0)=2\), \(\gamma(1)=\gamma(-1)=\tfrac12\), and \(\gamma(h)=0\) for \(|h|>1\).

Check: the sequence has total variance \(2\) at lag zero, and the density is nonnegative and even. The proposition therefore confirms that the computed sequence is a valid real covariance sequence.

Worked Example: Density Supported on a Frequency Interval

Consider the even density \(f(\lambda)=\tfrac1\pi\) for \(-\tfrac\pi2\leq\lambda\leq\tfrac\pi2\) and \(f(\lambda)=0\) elsewhere in \([-\pi,\pi)\). The endpoints of the interval are included; their inclusion does not change any integral. Find \(\gamma(h)\).

The total mass is \(\int_{-\pi/2}^{\pi/2}\tfrac1\pi\,d\lambda=\tfrac1\pi\cdot\pi=1\), so \(\gamma(0)=1\). For a nonzero integer \(h\),

$$ \gamma(h)=\frac1\pi\int_{-\pi/2}^{\pi/2}e^{ih\lambda}\,d\lambda =\frac{1}{\pi ih}\left(e^{ih\pi/2}-e^{-ih\pi/2}\right) =\frac{2\sin(h\pi/2)}{\pi h}. $$

In particular, \(\gamma(1)=\tfrac2\pi\), \(\gamma(2)=0\), and \(\gamma(3)=-\tfrac{2}{3\pi}\), since \(\sin(\pi/2)=1\), \(\sin(\pi)=0\), and \(\sin(3\pi/2)=-1\). The general formula also gives \(\gamma(-h)=\gamma(h)\): both the numerator and denominator change sign when \(h\) changes sign.

Check: the direct lag-zero integral is \(1\), matching the variance. For \(h=2\), the integral formula gives \(2\sin(\pi)/ (2\pi)=0\), confirming the stated zero at that lag.

Normalization and Interpretation

The most common error is to switch conventions halfway through a calculation. Under the convention used here, \(F(d\lambda)=f(\lambda)\,d\lambda\), so the density integrates to the variance. For white noise with variance \(3\), using the incorrect constant \(f(\lambda)=3\) would give \(\gamma(0)=\int_{-\pi}^{\pi}3\,d\lambda=6\pi\), not \(3\). The correct density is \(3/(2\pi)\). Some references instead use normalized measure \(d\lambda/(2\pi)\); their density values differ by a factor of \(2\pi\). A formula from that convention cannot be combined with the ordinary-\(d\lambda\) integral without converting the density.

The integral also gives a practical validity check: any proposed density must be nonnegative almost everywhere, and its integral must equal the process variance. For a real process, an even density produces real, symmetric covariances. These checks do not require the density to be smooth; the interval-supported example has jumps and still yields the covariance integral at every integer lag.

Check Your Understanding

Use the convention \(F(d\lambda)=f(\lambda)\,d\lambda\) throughout.

  1. If \(f(\lambda)=\tfrac{5}{2\pi}\) on \([-\pi,\pi)\), what are \(\gamma(0)\) and \(\gamma(h)\) for nonzero integer \(h\)?
  2. For \(f(\lambda)=\tfrac{1}{2\pi}(1+\cos(2\lambda))\), compute \(\gamma(0)\), \(\gamma(2)\), and \(\gamma(-2)\).
  3. Why does a nonnegative even integrable density produce a positive-definite covariance sequence?
  4. A proposed density integrates to \(4\). What must the variance be under this convention?
  5. Does a density for only the absolutely continuous part of a spectral measure necessarily recover the entire covariance sequence? Explain.