1

Consider an $N$-sided die. I roll it twice. I want to find the expectation of the first dice roll given that it is greater than the second dice roll.

So if we let $X$ and $Y$ denote the random variable value for the first and second rolls, respectively. We want to find $E[X | X > Y]$. Conditioning on $X > Y$ means we only consider the following ordered pairs $(2,1), (3,1), (3,2), (4,1), (4,2), (4,3)$ and so on. For an $N$-sided die there are $1 + 2 + \ldots + N-1 = \frac{N(N-1)}{2}$ of these ordered pairs.

So

$$ E[X | X > Y] = \frac{2}{N(N-1)} (1 * 2 + 2 * 3 + 3 * 4 + \ldots + (N-1)*N) $$

So this leads in to a series. I am wondering if there's an easier way to solve this without having to solve this series? I feel like there should be based on the nice structure of this problem

RobPratt
  • 45,619
  • The series you have here is not too difficult to solve because you can write $$1\cdot 2+2\cdot 3+\cdots (N-1)\cdot N \ = \sum_{i=1}^{N-1} i\cdot (i+1) = \sum_{i=1}^{N-1} (i^2+i) \ =\sum_{i=1}^{N-1} i^2 + \sum_{i=1}^{N-1} i$$ whence you can use the formula $$\sum_{i=1}^N i^2 = \dfrac{N(N+1)(2N+1)}{6}$$ for the sum of squares. – Fawkes4494d3 Aug 07 '20 at 21:16
  • @Fawkes4494d3 Right; however, in most of the contexts where I solve these problems, I don't have access to Google, and I wouldn't have remembered that formula. Hence, why I am seeing if there's an easier approach. – user5965026 Aug 07 '20 at 22:21
  • 1
    Summing of series is really a regular task that comes up almost everywhere in computations and there's no easy way around it everytime. Instead of remembering formulas, it is possible to derive them. You can find the general method for finding sum of $k^{th}$ powers following this proof, which shows it for squares using only the binomial theorem. Finally, in @Math1000's answer, the transition from the second last line to the last involves this computation anyway (sum indices shifted by $1$ from my comment above). Never be afraid of computing – Fawkes4494d3 Aug 08 '20 at 03:55
  • @Fawkes4494d3 Yeah, I've thought about deriving formulas too, but I feel like sometimes approaches also require memorization. Do you have any general advice for this? – user5965026 Aug 08 '20 at 05:08
  • 1
    you must try to understand the motivation behind a particular approach, usually remembering the motivation suffices. That said, there's no denying that there's a fair bit of memorization involved and the only general advice can be solve more problems, along the way you will just see the need of several approaches crop up just like that (especially if you've seen it in a previous solution). – Fawkes4494d3 Aug 08 '20 at 05:17

1 Answers1

2

For $2\leqslant i\leqslant N$ we have by definition of conditional probability: $$ \mathbb P(X=i\mid X>Y) = \frac{\mathbb P(X=i,X>Y)}{\mathbb P(X>Y)}.$$ Since $$ \{X=i,X>Y\} = \bigcup_{j=1}^{i-1}\left(\{X=i\}\cap\{Y=j\}\right), $$ it follows that \begin{align} \mathbb P(X=i,X>Y) &= \mathbb P\left(\bigcup_{j=1}^{i-1}\left(\{X=i\}\cap\{Y=j\}\right)\right)\\ &= \sum_{j=1}^{i-1}\mathbb P(X=i)\mathbb P(Y=j)\\ &= \sum_{j=1}^{i-1}\frac1{N^2}\\ &= \frac{i-1}{N^2}.\tag1 \end{align} Now, $\mathbb P(X=Y)=\frac1N$, and since $$ \Omega = \{X=Y\}\cup\{X<Y\}\cup\{X>Y\}, $$ by symmetry we have $$ \mathbb P(X>Y) = \frac12(1-\mathbb P(X=Y)) =\frac{N-1}{2N}.\tag2 $$ Combining $(1)$ and $(2)$, we find that $$ \mathbb P(X=i\mid X>Y) = \frac{\frac{i-1}{N^2}}{\frac{N-1}{2N}} = \frac{2 (i-1)}{N(N-1)}. $$ We can then compute the conditional expectation directly: \begin{align} \mathbb E[X\mid X>Y] &= \sum_{i=2}^N i\cdot\mathbb P(X=i\mid X>Y)\\ &= \sum_{i=2}^N i\cdot\frac{2 (i-1)}{N(N-1)}\\ &= \frac23(N+1). \end{align}

Math1000
  • 36,983