# How to compute $P(T\ge 3)$, when $T=Y_1+\dots+Y_{200}$ with $Y_i$'s Bernoulli?

Suppose we have a piece-wise function as the following: $$Y_i = \begin{cases} 1, & {\rm if }\; X_i > 0.9\\ 0, & {\rm if }\; X_i \le 0.9\\ \end{cases}$$ where $X_1,\dots,X_{200}$ are independent continuous random variables with pdf $$f_X(x) = \begin{cases} 2(1-x), & 0 < x < 1\\ 0, & \rm{otherwise}\\ \end{cases}$$ Let $T = Y_1+\dots+Y_{200}$. I want to compute $P(T\ge 3)$.

Here's my intuition after looking at this question for some time. I realized or at least think that $Y_i$ is a Bernoulli random of variable, and so this would imply that $T$ is a binomial random variable. This seems reasonable to think, and seems that I am thinking about this in the right direction, but I still don't see how exactly can this aid in solving $P(T\ge 3)$? Am I thinking about this in the wrong way? Any ideas?

• $f(x), X_i$?${}$ – Em. Mar 28 '16 at 6:56
• I suspect that here $Y_i=f(X_i)$. If $T$ has indeed binomial distribution and the parameters are known then what prevents you to calculate $P(T\geq3)=1-P(T=0)-P(T=1)-P(T=2)$? Another thing: the $X_i$ must be independent for that. – drhab Mar 28 '16 at 7:14
• What is the distribution of the $X_i$? $p=P(Y_i=1)=P(X\ge 0.9)$ so, you need to give this information in your question. As it is, one cannot help you – Jimmy R. Mar 28 '16 at 9:32
• @JimmyR. Added missing information, my apologies. – Teodorico Levoff Mar 28 '16 at 17:48
• @probablyme Added missing information, my apologies – Teodorico Levoff Mar 28 '16 at 17:49

Indeed you are thinking this the right way. The random variable $T$ is binomially distributed with parameters $n=200$ and $p=P(Y_i=1)$ where \begin{align}p&=P(Y_i=1)=P(X_i>0.9)=\int_{0.9}^1f_X(x)dx=\int_{0.9}^12(1-x)dx=0.01\end{align} So, in symbols $T\sim {\rm Bin}(n=200, p=0.01)$. Hence \begin{align}P(T\ge 3)&=1-P(T<3)=1-\left[P(T=0)+P(T=1)+P(T=2)\right]\\[0.2cm]&=1-\left[\dbinom{200}{0}0.01^{0}0.99^{200-0}+\dbinom{200}{1}0.01^{1}0.99^{200-1}+\dbinom{200}{2}0.01^{2}0.99^{200-2}\right]\end{align} This is not very difficult to calculate, but to avoid it you can approximate $T$ with a Poisson random variable $W$ with parameter $$λ=np=200\cdot0.01=2$$ (note that $np=2<5$, so we are allowed to use this approximation). In symbols $W\sim {\rm Poisson}(λ=2)$. With this approximation $$P(T\ge 3)\approx P(W\ge 3)=1-P(W<3)=1-\left[e^{-2}\frac{2^0}{0!}+e^{-2}\frac{2^1}{1!}+e^{-2}\frac{2^2}{2!}\right]$$ The first calculation (with the binomial) gives $P(T\ge 3)=0.676679$ and the second (with the Poisson approximation) gives $P(T\ge 3)\approx 0.676676$.
• Once I have $p$ how do I compute $P(T≥3)$? How do I use $p$? – Teodorico Levoff Mar 28 '16 at 18:16
• Very clear, and I am understanding this now. Is approximating $T$ with a Poisson random variable the only way? – Teodorico Levoff Mar 28 '16 at 18:32
• @TeodoricoLevoff This is the only way (that I know) here, but not in general. If $p\approx 1/2$ and $n>30$ (very roughly) then you should approach the binomial with the normal distribution instead of the Poisson. If $np<5$ with $n$ big and $p$ small (as here) then Poisson is correct. Each time, only one approximation will be appropriate, there is no overlap. – Jimmy R. Mar 28 '16 at 20:33