# Correlation between Bernoulli Variables

Say I have two infinite collections of $0/1$ random strings of length $n$ , where each digit is an independent Bernoulli RV, with parameter $p_i$ in the first collection and $q_i$ in the second, $i$:1...$n$.

1. Define $X_i$ to be a Bernoulli RV representing the absolute difference between the digits at location $i$ of a random sample of two strings, each string from a different collection.

2. Define $Y_i$ to be a Bernoulli RV representing the absolute difference between the digits at location $i$ of a random sample of two strings from the combined collection (with prior probability 0.5 for sampling each string from collection 1 and 0.5 from collection 2).

3. Define $Z_i$ to be a Bernoulli RV representing the absolute difference between the digits at location $i$ of a random sample of two strings from the same collection (with prior probability 0.5 for sampling a pair from collection 1 and 0.5 from collection 2).

Are the $X_i$ independent? [I think Yes]

Are the $Y_i$ independent? [I think No]

Are the $Z_i$ independent? [I think No]

If there is dependency in each case, what is the correlation?

-
Please define how the collection is combined? –  Sasha Jun 1 '12 at 20:04
The collections are not explicitly combined, but simply the sampling (in case 2) of each of the two strings is with 0.5 probability from the 1st collection and 0.5 probability from the 2nd collection. –  Omri Jun 1 '12 at 20:19