# Autocovariance

In probability and statistics, given a stochastic process $X=(X_t)$, the autocovariance is a function that gives the covariance of the process with itself at pairs of time points. With the usual notation E  for the expectation operator, if the process has the mean function $\mu_t = E[X_t]$, then the autocovariance is given by

$C_{XX}(t,s) = cov(X_t, X_s) = E[(X_t - \mu_t)(X_s - \mu_s)] = E[X_t X_s] - \mu_t \mu_s.\,$

Autocovariance is related to the more commonly used autocorrelation of the process in question.

In the case of a random vector $X=(X_1, X_2, ... , X_n)$, the autocovariance would be a square n by n matrix $C_{XX}$ with entries $C_{XX}(j,k) = cov(X_j, X_k).\,$ This is commonly known as the covariance matrix or matrix of covariances of the given random vector.

## Stationarity

If X(t) is stationary process, then the following are true:

$\mu_t = \mu_s = \mu \,$ for all t, s

and

$C_{XX}(t,s) = C_{XX}(s-t) = C_{XX}(\tau)\,$

where

$\tau = s - t\,$

is the lag time, or the amount of time by which the signal has been shifted.

As a result, the autocovariance becomes

$C_{XX}(\tau) = E[(X(t) - \mu)(X(t+\tau) - \mu)]\,$
$= E[X(t) X(t+\tau)] - \mu^2\,$
$= \sigma^2 R_{XX}(\tau) - \mu^2,\,$

where $\sigma^2$ is the variance and $R_{XX}(\tau)$ is the autocorrelation of the signal.

## Normalization

When normalized by dividing by the variance σ2, the autocovariance C becomes the autocorrelation coefficient function c,[1]

$c_{XX}(\tau) = \frac{C_{XX}(\tau)}{\sigma^2}.\,$

However, often the autocovariance is called autocorrelation even if this normalization has not been performed.

The autocovariance can be thought of as a measure of how similar a signal is to a time-shifted version of itself with an autocovariance of σ2 indicating perfect correlation at that lag. The normalization with the variance will put this into the range [−1, 1].

## Properties

The autocovariance of a linearly filtered process $Y_t$

$Y_t = \sum_{k=-\infty}^\infty a_k X_{t+k}\,$
is $C_{YY}(\tau) = \sum_{k,l=-\infty}^\infty a_k a^*_l C_{XX}(\tau+k-l).\,$