Two random numbers from different intervals: compute $P(b \leq a)$

50 Views Asked by At

You are given two random natural numbers $a$ and $b$:

  • $a$ is chosen from $[1, m]$ interval
  • $b$ is chosen from $[3, m+3]$ interval

I need to compute probability of $b \leq a$ case.

Assume $m > 1$.


There are $m$ different numbers in the interval $a$ is chosen from, and there are $m + 1$ numbers in the second interval that $b$ is chosen from.

The solution from my notes from half a year ago:

$$P(b \leq a) = \underbrace{\sum_{i = 1}^{m - 2} \frac{1}{m+2}\frac{i}{m}}_{\text{confusing part}} = \frac{1}{m(m+2)}\sum_{i=1}^{m-2} i = \frac{(m-1)(m-2)}{2m(m+2)}$$

I don't understand presented solution. Not sure where the 'confusing part' came from.

Would anyone be able to show me how the thinking process looks like in solving such a task?

1

There are 1 best solutions below

2
On BEST ANSWER

My result does not match the official solution.

Consider each of the possible values for $b$ which are $≤m$. We have $\{3,4,\cdots, m\}$ so there are $m-2$ of them. Each of these has probability $\frac 1{m+1}$ of being chosen (since there are $m+1$ possible values of $b$ with no restrictions). For each choice of $b≤m$ there are $m-b+1$ choices of $a$ that are $≥b$. Each of those can be chosen with probability $\frac 1m$. Thus the answer is $$\sum_{b=3}^{m}\frac 1{m+1}\times \frac 1m\times (m-b+1)=\frac {(m-2)(m-1)}{2m(m+1)}$$

To check, consider the case $m=3$. For that case we have $$a\in \{1,2,3\}\quad \&\quad b\in \{3,4,5,6\}$$

The only winning case is $a=b=3$ which has probability $\frac 1{12}$. The formula I wrote gives that value, the official solution does not.