Sunteți pe pagina 1din 2

# DEPARTMENT OF SOFTWARE ENGINEERING

## COURSE CODE: MAT-03114PR TOTAL MARKS: 20

ASSIGNMENT 4 (Solution)

1. Given that P (A) + P (B) = 0.9, P (A|B) = 0.5, and P (B|A) = 0.4, find P (A).
Solution:
P (A ∩ B) = P (A|B) P (B) = P (B|A) P (A) ↔ 0.5 * P (B) = 0.4 * P (A)
P (A) = 0.9 - P (B) = 0.9 – 0.8 * P (A)
P (A) = 0.9/1.8 = 0.5

2. The probability that a vehicle entering USA has Canadian license plates is 0.12; the
probability that it is a camper is 0.28; and the probability that it is a camper with Canadian
license plates is 0.09. What is the probability that
(b) a vehicle with Canadian license plates entering USA is a camper?
(c) a vehicle entering USA does not have Canadian plates or is not a camper?
Solution:
A = the vehicle is a camper B = the vehicle has Canadian license plates
(a) P (B | A) = P (A ∩ B) / P (A) = 0.09/0.28 = 0.32
(b) P (A | B) = P (A ∩ B) / P (B) = 0.09/0.12 = 0.75
(c) P (B′ ∪ A′) = 1 – P (A ∩ B) = 1 − 0.09 = 0.91

3. On her way to work, Sylvia drives through three sets of traffic lights. The probability of
each set of lights being green is 0.3. What is the probability that they are all green?
Solution:
P (all are green) = 0.3*0.3*0.3 = 0.027

4. A garage mechanic keeps a box of good springs to use as replacements on customers cars.
The box contains 5 springs. A colleague, thinking that the springs are for scrap, tosses three
faulty springs into the box. The mechanic picks two springs, one at a time, out of the box

Ayesha Kermani
while servicing a car. Find the probability that: (a) the first spring drawn is faulty; (b) the
second spring drawn is faulty given that the first was faulty.
Solution:
A = first spring chosen is faulty B = second spring chosen is faulty
P (A) = 3C1/8C1 = 3/8
P (B | A) = 2/7

5. Suppose we have two bags: one has 4 red balls and 6 green balls, the other has 6 red and 4
green. We toss a fair coin, if heads, pick a random ball from the first bag, if tails from the
second. What is the probability of getting a red ball?
Solution:
H = head appears T = tail appears R = red ball is drawn
P (R) = P (H ∩ R) + P (T ∩ R) = P (R|H) P (H) + P (R|T) P (T)
= 4/10 * 1/2 + 6/10 * 1/2 = ½

6. A company that manufactures video cameras produces a basic model and a deluxe model.
Over the past year, 40% of the cameras sold have been of the basic model. Of those buying
the basic model, 30% purchase an extended warranty, whereas 50% of all deluxe purchasers
do so. If you learn that a randomly selected purchaser has an extended warranty, how likely
is it that he or she has a basic model?
Solution:
B = basic, D = deluxe, W = warranty purchase, W′ = no warranty
P (B | W) = P (W | B) P (B) / P (W | B) P (B) + P (W | D) P (D)
= 0.3 * 0.4 / 0.3 * 0.4 + 0.5 * 0.6 = 0.2857

Ayesha Kermani