# Zero-mean preprocessing before calculating the autocorrelation

I am aware that if we do not subtract the mean value from the white noise at the beginning (if the mean is not equal to 0), that its autocorrelation function will be triangle shaped and not a delta function. I wonder why that is? I'm also wondering why the signal mean is so often removed at the beginning of each processing?

White noise by definition has zero mean, so the premise of your question is somewhat erroneous in a theoretical sense. To see why that is, consider the defining property of white noise: that its power spectral density is a constant: $$S_x(f) = K$$ The autocorrelation function is then $$R_x(\tau) = K\delta(\tau)$$ If white noise was non-zero-mean, then $$S_x(f)$$ would have a Dirac delta at $$f=0$$, which contradicts the flatness property of white noise.

As a side note, rectangular functions have a triangular auto-correlation function.

As far as the second part of your question, why pre-processing often involves removing the mean, two reasons come to mind:

### Spectral analysis:

For spectral analysis, a non-zero mean adds a spike at 0 Hz in the Fourier Transform of the signal (often called the DC component). Removing the mean can provide a clearer spectral representation, making it easier to analyze and interpret the frequency content of the signal.

### Normalizing/Standardizing

In machine learning and data analysis, normalization of data, which often includes mean subtraction, is a common step to ensure that different features contribute equally to the analysis.

• So why does white noise has to be zero mean? Commented Dec 28, 2023 at 10:49
• See my edited answer ;) Also this
– Jdip
Commented Dec 28, 2023 at 10:56