0
$\begingroup$

I want to verify my answer to the following question: The number of visitors in a store in one hour distributes $X\sim Poi(\lambda=3)$ each visitor purchase one item with a probability of 0.5 and two items with the same probability. What is the prob. that exactly K items were purchased in two hours?

This is my solution:

first we define some variables which will assist us:

1) $X$ - number of customers entered the store in two hours.

2) $Y$ - number of customers who purchased 2 items.

3) $Z$ - number of items purchased in 2 hours.

Basically, we want to find $Pr(Z=k)$

$\displaystyle Pr(Z=k) = \sum_{j=\lceil k/2 \rceil}^kP(X=j)\cdot P(Y=k-j) = \sum_{j=\lceil k/2 \rceil}^k \frac{Exp(-3 \cdot 2)\cdot 3^j}{j!} \cdot \binom{j}{k-j}\cdot 0.5^j$

Explanation:

we know that if we want $k$ items we must have a least $\lceil k/2 \rceil$ visitors in the store (lower bound) and $k$ visitors (each of them purchasing one item) as upper bound, cause each customer buys at least one item.

Next, we have a deterministic number of customers purchasing 2 items in order to end up with $k$ items, but we have multiple combinations for that hence using the Binomial formula. We define "success" as a customer buying 2 items.

Is this solution correct? Is there a more intuitive solution to this problem?

Please share your thoughts :)

$\endgroup$
3
  • $\begingroup$ you should add conditionals to your solution to make it clearer. You are conditioning on the number of visitors, right? so, you should write $Pr(Z=k) = \sum Pr(Z=k|X=j) P(X=j)$ $\endgroup$
    – Daniel S.
    Apr 16, 2020 at 10:08
  • $\begingroup$ Agree! thank you. Besides that is the solution ok? $\endgroup$
    – AvivSham
    Apr 16, 2020 at 10:22
  • $\begingroup$ please, fix first! $\endgroup$
    – Daniel S.
    Apr 16, 2020 at 11:05

1 Answer 1

1
$\begingroup$

If $X$ denotes the number of customers entering the store in $2$ hours then $X\sim\mathsf{Poisson}(\lambda=6)$.

Splitting up $X=X_1+X_2$ where $X_i$ stands for the number of customers that buy $i$ items it can be noticed that $X_1,X_2$ are iid and $\sim\mathsf{Poisson}(\lambda=3)$.

In this situation to be found is expression for:$$P(X_1+2X_2=k)$$

So something like: $$\sum_{j=0}^{\lfloor k/2\rfloor} P(X_2=j)P(X_1=k-2j)=e^{-6}\sum_{j=0}^{\lfloor k/2\rfloor}\frac{3^{k-j}}{j!\left(k-2j\right)!}$$

$\endgroup$
9
  • $\begingroup$ where do you take into account that there are multiple combinations? let's say k=5 and 3 people entered the store in total, there are three possible outcomes. the first customer will buy 1 item, the second customer will buy 1 item etc. can you please provide a more detailed explanation? $\endgroup$
    – AvivSham
    Apr 16, 2020 at 14:20
  • 1
    $\begingroup$ Taking that into account would be necessary by conditioning on the number of persons entering the store. But I have avoided that and observed only two things: 1) $X_1$ and $X_2$ as defined in my answer both have Poisson distribution with $\lambda=3$. 2) $X_1$ and $X_2$ are independent. This is enough to find an expression for $P(Z:=X_1+2X_2=k)$. Do you agree with both observations? $\endgroup$
    – drhab
    Apr 16, 2020 at 16:45
  • 1
    $\begingroup$ From that it follows that $X_1$ and $X_2$ both are Poisson with $\lambda =3$. If for instance the probability on buying 1 item would have been 1/3 then $X_1$ would be Poisson with $\lambda =2$ and $X_2$ with $\lambda =4$. $\endgroup$
    – drhab
    Apr 16, 2020 at 17:43
  • 1
    $\begingroup$ Suppose that the probability on a visitor purchasing $1$ item is $p$ and consequently the probability on a visitor purchasing $2$ items is $1-p$. For $i=1,2$ let $\lambda_{i}$ denote the parameter for $X_{i}$. The expectation of the number of purchases made by exactly $1$ customer is $p\times1+\left(1-p\right)\times2=2-p$. Then the expectation of the number of purchases made in $2$ hours is $\left(2-p\right)\times6=12-6p$.... $\endgroup$
    – drhab
    Apr 17, 2020 at 8:20
  • 1
    $\begingroup$ (Continues former comment) Also this expectation is $\mathbb{E}\left(X_{1}+2X_{2}\right)=\lambda_{1}+2\lambda_{2}$. So we have $\lambda_{1}+2\lambda_{2}=12-6p$ and next to that we also have $\lambda_{1}+\lambda_{2}=\mathbb{E}X_{1}+\mathbb{E}X_{2}=\mathbb{E}X=6.$ This together leads to $\lambda_{2}=6\left(1-p\right)$ and $\lambda_{1}=6p$. This illustrates that $\lambda_1:\lambda_2=p:(1-p)$. $\endgroup$
    – drhab
    Apr 17, 2020 at 8:20

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .