Autocorrelation function
Autocorrelation function: For a signal x(t), the autocorrelation is defined as Rxx(Ī) = E[x(t)x(t+Ī)] for a random process, or Rxx(Ī) = ∫ x(t)x(t+Ī) dt for an energy signal.
The auto-correlation of a periodic signal preserves the periodicity. For example, we are transmitting a signal x(t) through the wireless medium, and we receive the signal y(t) at the receiver.
y(t) = x(t) + n(t)
where n(t) is the additive white Gaussian noise (AWGN).
You can find that the periodicity of the autocorrelation of y(t) will be the same as the periodicity of x(t).
In other words, we can say that the autocorrelation of the noisy signal is equal to the autocorrelation of the original periodic signal, except at zero lag (Ī = 0), where the noise contributes.
To find the spectral density (also known as the power spectral density, or PSD) from the autocorrelation function mathematically, you can use the Wiener–Khinchin theorem. This theorem states that the power spectral density of a wide-sense stationary (WSS) random process is the Fourier transform of its autocorrelation function.
Why WSS is assumed: The WSS assumption ensures that the autocorrelation function depends only on the time difference Ī (i.e., Rxx(t₁,t₂) = Rxx(Ī)) and not on absolute time. This time-invariance is necessary for the Fourier transform to exist in a consistent way and to define a meaningful power spectral density. Without stationarity, the statistical properties of the signal change with time, and a single PSD cannot fully describe the signal.
Wiener-Khinchin Theorem
Given a wide-sense stationary process X(t), let RX(Ī) be its autocorrelation function. The power spectral density SX(f) is given by:
\( S_X(f) = \mathcal{F}\{R_X(\tau)\} = \int_{-\infty}^{\infty} R_X(\tau) e^{-j2\pi f \tau} \, d\tau \)
Where F denotes the Fourier transform, j is the imaginary unit, f is the frequency, and Ī is the lag.
Steps to Compute PSD from Autocorrelation Function
Steps to Compute PSD from Autocorrelation Function
Compute the Autocorrelation Function RX(Ī):
The autocorrelation function RX(Ī) is defined as:
RX(Ī)=E[X(t)X(t+Ī)]
For a discrete-time signal x[n], the autocorrelation function RX[k] can be computed as:
RX[k]=∑(n=−∞,∞) x[n]x[n+k]
Apply the Fourier Transform:
To find the PSD, take the Fourier transform of the autocorrelation function RX(Ī) (or RX[k] in the discrete case):
For continuous signals:
SX(f)=∫(−∞,∞) RX(Ī)exp(−j2ĪfĪ dĪ)
For discrete signals:
SX(exp(jĪ))=∑(k=−∞,∞) RX[k]exp(−jĪk)
MATLAB Code to find the periodicity from auto-correlation of a periodic signal
Output
Another MATLAB Code to find the periodicity from autocorrelation of a noisy periodic signal

