Bayes' Theorem Help?

2k Views Asked by At

Problem 2.10 from Introduction to Probability by Blitzstein and Hwang asks the following:

Fred is working on a major project. In planning the project, two milestones are set up, with dates by which they should be accomplished. This serves as a way to track Fred’s progress.

Let $A_1$ be the event that Fred completes the first milestone on time, $A_2$ be the event that he completes the second milestone on time, and $A_3$ be the event that he completes the project on time.

Suppose that $\mathsf P(A_{j+1}\mid A_j) = 0.8$ but $\mathsf P(A_{j+1}\mid A_j^\complement) = 0.3$ for $j \in\{ 1, 2\}$, since if Fred falls behind on his schedule it will be hard for him to get caught up.

Also, assume that the second milestone supersedes the first, in the sense that once we know whether he is on time in completing the second milestone, it no longer matters what happened with the first milestone. We can express this by saying that $A_1$ and $A_3$ are conditionally independent given $A_2$ and they’re also conditionally independent given $A_2^\complement$.

(a) Find the probability that Fred will finish the project on time, given that he completes the first milestone on time. Also find the probability that Fred will finish the project on time, given that he is late for the first milestone.

(b) Suppose that $\mathsf P(A_1) = 0.75$. Find the probability that Fred will finish the project on time.

My thinking is that you can obviously start with $\mathsf P(A_3 \mid A_1)$, but then you can try conditioning on $A_2$ as well. This leads me to a roadblock. Thoughts?

3

There are 3 best solutions below

4
On

Yes, you do seek $\mathsf P(A_3\mid A_1)$, as well as $\mathsf P(A_3\mid A_1^\complement)$ and the next step is to use partitioning on $A_2$, with the Law of Total Probability.

$$\mathsf P(A_3\mid A_1) ~=~ \mathsf P(A_3\mid A_1,A_2)\;\mathsf P(A_2\mid A_1)+\mathsf P(A_3\mid A_1,A_2^\complement)\;\mathsf P(A_2^\complement\mid A_1)$$

$$\mathsf P(A_3\mid A_1^\complement) ~=~ \mathsf P(A_3\mid A_1^\complement,A_2)\;\mathsf P(A_2\mid A_1^\complement)+\mathsf P(A_3\mid A_1^\complement,A_2^\complement)\;\mathsf P(A_2^\complement\mid A_1^\complement)$$

So, moving onwards.   The assumption of conditional independence, between $A_1,A_3$ when given $A_2$, would mean that:

$$\mathsf P(A_3\mid A_1,A_2)=\mathsf P(A_3\mid A_2)\\\mathsf P(A_3\mid A_1,A_2^\complement)=\mathsf P(A_3\mid A_2^\complement)\\\mathsf P(A_3\mid A_1^\complement,A_2)=\mathsf P(A_3\mid A_2)\\\mathsf P(A_3\mid A_1^\complement,A_2^\complement)=\mathsf P(A_3\mid A_2^\complement)$$

Put it together.


Of course, for the second part we likewise use that: $$\mathsf P(A_3)~=~\mathsf P(A_3\mid A_1)\;\mathsf P(A_1)+\mathsf P(A_3\mid A_1^\complement)\;\mathsf P(A_1^\complement)$$

2
On

Solution of (a)

enter image description here

Solution of (b)

enter image description here

2
On

Let $A_1$ be the event that Fred completes first milestone on time. Let $A_2$ be the event that Fred completes the second milestone on time. Let $A_3$ be the event that Fred completes the project on time. Assumption event $A_2$ supersedes $A_1$.If I know Fred completes second milestone on time, then it does not matter if Fred completes first milestone on time, the project will be completed on time. So event $A_3$ and $A_1$ becomes conditionally independent given Fred completes second milestone on time. If the second milestone is not completed on time then the project will not be completed on time. Anyway,

We are interested in $P(A_3|A_1)$ :Probability of finding that Fred completes project on time given that he completes the first milestone on time. We can extra-condition on $A_2$ that is if Fred completes the second milestone on time. So we can partition on $A_2$ whether Fred completed second milestone on time.

Using Law of Total Probability and extra-conditioning on $A_2$

$P(A_3|A_1)$=$P(A_3|A_2,A_1)$$P(A_2/A_1)$+$P(A_3|A_2',A_1')$$P(A_2'/A_1)$

$A_2'$:Event that is complement of $A_2$

It is conditional probability. So think in this way:

$P(A_3|A_2,A_1)$:Probability that Fred completed the project on time given that he completed second and first milestone on time. This is certainly is going to be 1 as anyway he competes the second milestone on time.

$P(A_3|A_2',A_1)$:Probability that Fred completed the project on time given that he did not complete second milestone on time and completed first milestone on time. This is certainly is going to be 0 as anyway he did not completed the second milestone on time.

Henceforth:

$P(A_3|A_1)$=$1.P(A_2|A_1)$+$0.P(A_2'|A_1)$ =$P(A_2/A_1)$ =$0.8$ as already given in the question

On similar arguments,

$P(A_3|A_1')$=$P(A_3|A_2,A_1')$$P(A_2|A_1')$+$P(A_3|A_2',A_1')$$P(A_2'|A_1')$=$P(A_2|A_1')$=$0.3$ as already given in the question. $P(A_3|A_2,A_1')=1$.The reason is simple that Fred completes second milestone on time and it does not matter if he completed second milestone on time.

$P(A_3|A_2',A_1')=0$.Why?Fred did not complete second milestone on time. That is your solution to the first part of the question.

Now coming to answer b.

$P(A_1)=0.75$ $P(A_1')=0.25$ $P(A_3)$=Probability that Fred Finishes the project on time.

Let us condition on $A_1$.

$P(A_3)=P(A_3|A_1)*P(A_1)+P(A_3|A_1')*P(A_1')$

As from question a.

$P(A_3|A_1)=0.8$ $P(A_3|A_1')=0.3$ $P(A_3)=0.8*0.75+0.3*0.25=0.675$

There is also another way to solve the same problem:

$P(A_2)$=Find the probability that Fred finishes the second milestone on time. Wishful thinking: If we knew Fred finishes the first milestone on time. So, condition on $A_1$ and use Bayes Theorem and and Law of Total Probability:

$P(A_2)=P(A_2|A_1)*P(A_1)+P(A_2|A_1')*P(A_1') =0.8*0.75+0.3*0.25 =0.675$
$P(A_3)$=Find the probability that Fred finishes the project on time.
Wishful thinking: If we knew Fred finishes second milestone on time would be enough as it does not matter if he completes the second milestone on time. So condition on $A_2$ and use Bayes theorem and LOTP:

$P(A_3)=P(A_3|A_2).P(A_2)+P(A_3|A_2')*P(A_2')$
$=1.P(A_2)+0.P(A_2')$
$=P(A_2)$
$=0.675$ as already computed.

Now explanation: $P(A_3|A_2)$=Find the probability that Fred completes the project on time given that he completes the second milestone on time$=1$.Why?Because second milestone has already been completed.

$P(A_3|A_2')=$Find the probability that Fred completes the project on time given that he does not complete the second milestone on time$=0$.Why?Because second milestone has not been completed.