# Expected value of signals

If I have two signals $x$ and $y$ and this expression $E\{x[n]y[n-k]\}$, what is the expected value of the product?

I have a basic understanding of EV based on probability, such as $$E[X]=\sum_{i=1}^{\inf}x_ip_i$$ and I understand that EV of flipping coin is 0.5 if $x_1=0$ and $x_2=1$ and both probabilities are 0.5 or for rolling a dice is 3.5 etc.

However, when I see the expression like this the one above, I find it confusing. I don't know for instance where the probability term is.

• Evaluating a quantity like $E[XY]$ requires knowledge of the joint distribution of $X$ and $Y$. That is, you need to know not just $P(X=x_ii) = p_i$ as in your examples but $p_{i,j}$, the probability that $X$ equals $x_i$ and simultaneously $Y$ equals $y_j$, and no, $p_{i,j}$ doesn't necessarily equal $P(X=x_i)P(Y=y_j)$ or $P(X=i)+P(Y=j)$ or any such thing; you need to find it. That being said, what you need is a generalization of what you have: $$E[X]=\sum_i\sum_j x_iy_j p_{i,j}=\sum_i\sum_j x_iy_jP(\{X=x_i\}\cap\{Y=y_j\}).$$ Note that $$P(X=i)=\sum_jP(\{X=x_i\}\cap\{Y=y_j\}).$$ Jun 22 '15 at 11:05
• @DilipSarwate Thanks for you comment. I still don't understand how all this is related to $E\{x[n]y[n−k]\}$ or $E\{x[n]\}$ if I consider just one signal. Where is probability in $E\{x[n]\}$. Why would one calculate EV of $x$. Probably I am missing something really obvious. Jun 22 '15 at 11:20
• Ooops, I have a typo, now unfortunately uncorrectable in what I wrote above. That first displayed formula is for $E[XY]$, not $E[X]$ as I miswrote. Jun 22 '15 at 11:34
• @DilipSarwate The second formula you wrote, is it P(X=x_{i}) or P(X=i) as you have written Jun 22 '15 at 11:46
• More ooops. That second displayed formula should have $P(X=x_i)$ on the left, not $P(X=i)$. Thank God that comments do not get downvotes; else the first one would have garnered a -5 by now. Jun 22 '15 at 12:34

This is the cross-correlation function of the two discrete-time random processes $x[n]$ and $y[n]$. It measures the similarity of the processes for a given time lag between the two. If $x[n]$ and $y[n]$ are jointly wide-sense stationary, then the cross-correlation only depends on the lag $k$, and not on the absolute time index $n$.
In terms of probabilities (or rather probability density functions), the expectation $E\{x[n]y[n-k]\}$ is given by
$$E\{x[n]y[n-k]\}=\int_{-\infty}^{\infty}xyf_{XY}(x,y;n,n-k)dxdy$$
where $f_{XY}(x,y;n_1,n_2)$ is the joint probability density function of $x[n_1]$ and $y[n_2]$.