Using Bayes' Theorem to solve probabilities

650 Views Asked by At

A manufacturing process produces computer chips of which 10 percent are defective. This percent is actually found using a thorough (and expensive test) on a small random sample of chips. The plant engineers develop a less expensive testing procedure, T, which they perform on all chips. Chips that fail the test, whether they are functional chips or defective chips, are rejected. On the other hand, chips that pass the test, whether they are functional chips or defective chips, are accepted. Clearly we would like only functional chips to pass the test, and only defective chips to fail the test. However, this less expensive test, not being a thorough test, will allow some defective chips to pass the test, which we don't like, and will reject some functional chips, which we also don't like.

When applied to functional chips, T indicates "good" 99.9% of the time, and "bad" the remaining 0.1% of the time (thus condemning a functional chip to rejection). When the testing procedure, T, is applied to defective chips, T indicates "bad" 99.99% of the time, and the remaining 0.01% of the time, is a failure of the test to detect a defective chip.

Let T denote the test result, and C the chip quality. Abbreviating good, bad, functional and defective with g, b, f, d we rewrite the data above:

Pr(T=g|C=f) = 0.999
Pr(T=b|C=f) = 0.001

Pr(T=g|C=d) = 0.0001
Pr(T=b|C=d) = 0.9999

Suppose we now apply the testing procedure, T, to a chip of unknown quality. Using Bayes' Theorem, computer the following probabilities.

1) Pr(C=f|T=g) =
2) Pr(C=f|T=b) =

3) Pr(C=d|T=g) =
4) Pr(C=d|T=b) =

1

There are 1 best solutions below

0
On BEST ANSWER

The easiest way to solve this problem is to list the probabilities and subsequently plug them into Bayes' Theorem. We know that:

$P(f) = 0.9$

$P(d) = 0.1$

$P(g|f) = 0.999$

$P(b|f) = 0.001$

$P(g|d) = 0.0001$

$P(b|d) = 0.9999$

Then, we use Bayes' Theorem, which states that:

$P(B_j|A) = \frac{P(A|B_j)P(B_j)}{\sum_{i=1}^kP(A|B_i)P(B_i)}$

Therefore,

1) $P(f|g) = \frac{P(g| f)P(f)}{P(g|f)+P(g|d)} = \frac{(.999)(.9)}{(.999)+(.0001)}≈.8999099189$

2) $P(f|b) =\frac{P(b| f)P(f)}{P(b|f)+P(b|d)} = \frac{(.001)(.9)}{(.001)+(.9999)}≈.0008991907283$

3) $P(d|g) = \frac{P(g| d)P(d)}{P(g|d)+P(g|f)}=\frac{(.0001)(.1)}{(.0001)+(.999)}≈.00001000900811$

4) $P(d|b) =\frac{P(b| d)P(d)}{P(b|d)+P(b|f)}=\frac{(.9999)(.1)}{(.9999)+(.001)}≈.0999000899$

Hopefully that helps.