Expected value of size of randomly choosen subset

380 Views Asked by At

Given a set S such that |S|=n. Let X - numbers of items in randomly choosen (but non-empty) subset of S. Each subset have the same probability to be choosen. Find E(X).

1

There are 1 best solutions below

2
On BEST ANSWER

Since $|S| = n$, then there are $2^n$ subsets of $S$. Since we don't want to include the empty set, we have $2^n-1$ subsets.

Since each subset has the same probability of being chosen, then each one has probability $\dfrac{1}{2^n-1}$ of being chosen.

Note that in the above I assumed that the empty set $\varnothing$ is not in the sample space. If it in fact is the case that $\varnothing$ is in the sample space then the probability will be $\dfrac{1}{2^n}$ instead.

Let $P(S)$ denote the power set (i.e., set of all subsets) of $S$. Then \begin{align} E(X) &= \sum_{A \in P(S)} |A| \cdot \frac{1}{2^n-1}\\[0.3cm] &= \frac{1}{2^n-1} \sum_{A \in P(S)} |A| \end{align}

So the problem essentially comes down to computing $\sum_{A\in P(S)} |A|$, which is the sum of the sizes of all the subsets of $S$. Can you take it from here? Note that we don't need to explicitly exclude $\varnothing$ in the sum because $|\varnothing| = 0$ anyway.