Verifying answer of bayes rule

82 Views Asked by At

Suppose that we announce two job positions in D1 department. We categorize the applicants into two groups: D1 and D2. The probability that an D1 graduate qualifies in the interview is $0.6$. The probability that a D2 graduate qualifies in the interview is $0.7$. We choose one of the two groups randomly. Next, we invite two applicants from the selected group for the interview.

What is the probability that both applicants qualify for the positions.Given that both of the selected students clear the interview, what is the probability that they belonged to the D2 group?

This is how I solved this question

Solution for question 1:

$P(D1) = 0.5$ (probability of first department)

$P(D2)= 0.5$ (probability of second department)

$P(Q \text{ and } D1) = 0.5\cdot 0.7$ (probability that candidate belongs to D1 and got qualified)

$P(Q \text{ and } D2) = 0.5\cdot0.6$ (probability that candidate belongs to D2 and got qualified)

Solution for question 2:

using Bayes theorm

$P(D2|Q) = \frac{P(Q|D2)P(D2)}{ P(D2)*P(Q|D2) + P(D1)*P(Q|D1)} = 0.53$

(probability that D2 was the cause / probabilities of all outcomes)

1

There are 1 best solutions below

2
On BEST ANSWER

We have: $$P(D_1)=P(D_2)=.5$$ $$P(Q_1)=.6, \, P(Q_2)=.7$$

Note, that $P(Q_i)$ describes the probability, that one candidate will qualify. If we want two applicants from $D_i$ qualify, we have to perform two successes, ie. : $$P(Q_i)^2$$ See, tat the above describes the conditional probability of qualification of both candidates, when they're both from $D_i$, ie: $$P(Q|D_i)=P(Q_i)^2$$

For the first question - both candidates are from one group, therefore probability that they'll both qualify for this position is $$P(Q)=P(D_1)P(Q|D_1)+P(D_2)P(Q|D_2)$$ For the second:

$$P(D_2|Q)=\frac{P(Q|D_2)P(D_2)}{P(Q)}$$