# Find the probability that a person is healthy given Covid 19?

A test is (covid-19)

$$(1)95 \% \text{ reliable on infected patients.}\\(2)99 \% \text{ reliable on healthy people.}\\(3) 4\% \text{ of population has virus.}\\ \text{define event: V: patient has virus}\\\qquad \qquad S: \text{Test indicates a positive result.} \\ \Rightarrow{\text{We know: }}P(S|V) =.95, P(S^c|V^c) =.99,P(V)=.04\\\text{This test is given to a person with positive result. What is the probability }\\\text{ that this person is infected?}\\P(V|S)=\frac{P(V\cap{S})}{P(s)}=\frac{P(V)P(S|V)}{P(V)P(S|V)+P(V^c)P(S|V^c)}\\=\frac{P(V)P(S|V)}{P(V)P(S|V)+(1-P(V)(1-P(S^c|V^c)}=\frac{.04\star.95}{.04\star.95+(1-.04)(1-.99)}=.8636$$

Find the probability that a person is healthy given the test says this person has a negative result. How do I solve this part any tips?

Recheck your calculation. I get $$\Pr[V \mid S] = \frac{(0.04)(0.95)}{(0.04)(0.95) + (0.96)(0.01)} = \frac{95}{119} \approx 0.798319.$$

As for your other question, you want $$\Pr[V^c \mid S^c].$$ This is solved in an analogous fashion to what you already computed:

$$\Pr[V^c \mid S^c] = \frac{\Pr[S^c \mid V^c]\Pr[V^c]}{\Pr[S^c \mid V^c]\Pr[V^c] + \Pr[S^c \mid V]\Pr[V]}.$$ I leave the computation to you.

Another way to do these calculations is to construct a frequency table based on the given probabilities for a hypothetical cohort. Suppose the population contains $$10000$$ people. Of these, $$(0.04)(10000) = 400$$ are infected with the virus. The remaining $$9600$$ are healthy. Of the $$400$$ infected people, the test is $$95\%$$ reliable, so $$(0.95)(400) = 380$$ of these will test positive and $$20$$ will test negative. Of the $$9600$$ healthy people, the test is $$99\%$$ reliable, so $$(0.99)(9600) = 9504$$ of these will test negative, and $$9600-9504 = 96$$ will test positive. In summary

$$\begin{array}{|c|c|c|c|} \hline & V & V^c & \text{Total} \\ \hline S & 380 & 96 & 476 \\ \hline S^c & 20 & 9504 & 9524 \\ \hline \text{Total} & 400 & 9600 & 10000 \\ \hline \end{array}$$

We simply populated the corresponding joint events with the number of people we expect to meet the criteria, and the row totals $$476$$ and $$9524$$ were just the sums of the corresponding rows.

Now that we have constructed such a table, it is immediately obvious that $$\Pr[V \mid S] = \frac{380}{476} \approx 0.798319,$$ and the computation of $$\Pr[V^c \mid S^c]$$ is similarly performed by reading the appropriate cells in the table.

In a slightly simplified notation,

$$P(V^c|S^c)=\frac{P(V^c\cap S^c)}{P(S^c)}$$

$$=\frac{P(V^c\cap S^c)}{P(V^c\cap S^c+P(V\cap S^c)}$$

$$=\frac{.96\star.99}{(.96\star.99+.04*.05)} =\frac{9504}{9524}$$

## Note

Actually, the simplest way for such problems which have a tendency to confuse learners, is to use a contingency table. But this may be frowned upon by teachers who expect mathematical notation.

A good compromise is to use a simpler notation as I have done rather than expand it into its fullest form. This should be acceptable to teachers , in general, and less confusing to learners