Electrical – Autocorrelation of heaviside functions

signal processing

I'm trying to find the expression that describes the auto-correlation of two heaviside functions u(t). I was told that the result must be 1/2, which makes total sense, as the power spectral density of the heaviside function must be a Dirac's delta centered in 0 with 1/2 area (which can be seen using the Fourier Transform).

This is how I thought it:

$$
r_{xx}(\tau) = <u(t+\tau) \cdot u(t)> = \lim_{T\to\infty} \frac{1}{2T} \int\limits_{-T}^{T} u(t+\tau) \cdot u(t) dt = \lim_{T\to\infty} \frac{1}{2T} \left( \int\limits_{0}^{T}dt + \int\limits_{\tau}^{T}dt \right) = \lim_{T\to\infty} \frac{1}{2T}(T+T-\tau) = \lim_{T\to\infty} \frac{1}{2T} (2T – \tau) = 1 – \lim_{T\to\infty} \frac{\tau}{2T} = 1
$$

What am I missing?

Thanks in advanced.

Best Answer

@JRE has a good point - a better match for DSP. But in any case,

$$\int_{-T}^Tu(t+\tau)\cdot u(t)dt=\int_{-T}^{0}0dt+\int_{0}^T1dt=T$$ $$\lim_{T\to\infty}\frac{1}{2T}\int_{-T}^Tu(t+\tau)\cdot u(t)dt=\lim_{T \to \infty}\frac{T}{2T}=\frac{1}{2}$$