STAB47S:200 Midterm Name: Student Number: Tutorial Time: Tutor: Time: 2hours Aids: The exam is open book Students may use any notes, books and calculators in writing this exam Instructions: Show your reasoning when determining an answer 1 (a) (5 marks) Suppose that a symmetric die is rolled two independent times What is the probability that the sum of the number of pips that showed on the two rolls is less than 5? P ("sum of the number of pips that showed on the two rolls is less than 5") =P ({(1, 1), (1, 2), (2, 1), (1, ), (, 1), (2, 2)}) =6/6 2 =1/6 (b) (10 marks) If the outcome from the two rolls discussed in (a) is less than 5, then we flip a coin that has probability 1/ of H and, if the outcome of the two rolls is 5 or greater, then we flip a coin which has probability 1/4 of H What is the probability that a head is obtained? P ("H") =P ("H" "less than 5")P ("less than 5") P ("H" "greater than or equal to 5")P ("greater than or equal to 5") = 1 1 1 5 = 19 6 4 6 72 (c) (10 marks) For the situation described in (b), suppose that a head is observed What is the conditional probability that the sum of the two rolls waslessthan5? We use Bayes Theorem for this We have P ("sum of the two rolls was less than 5" "H") = P ("H " "less than 5")P ("less than 5") = 1 1 6 P ("H ") 1 1 6 1 5 4 6 1 = 4 19
2 (a) (5 marks) Suppose that P is a probability measure defined on the sample space S Prove that P (A c B c )=1 P (A) P (B)P (A B) P (A c B c )=P ((A B) c )=1 P (A B) =1 (P (A)P (B) P (A B)) (b) (5 marks) Prove that A c and B c are independent if and only if A and B are independent Suppose that A c and B c are independent Then P (A c B c )=P (A c ) P (B c )= (1 P (A)) (1 P (B)) = 1 P (A) P (B) P (A)P (B) Equating this to the expression obtained in (a)we see that P (A B) =P (A)P (B) and so A and B are independent If A and B are independent then by (a) P (A c B c )=1 P(A) P (B) P (A B) =1 P (A) P (B) P (A)P (B) =(1 P (A)) (1 P (B)) = P (A c ) P (B c ) and so A c and B c are independent (c) (10 marks) Suppose that X is random variable defined on S and A S Prove that X 1 A c =(X 1 A) c Suppose that s X 1 A c Then X(s) A c which implies that X (s) / A and so s/ X 1 A This implies s (X 1 A) c Therefore X 1 A c (X 1 A) c Now suppose s (X 1 A) c Then s/ X 1 A which implies X(s) / A and this implies X(s) A c So s X 1 A c and we have proved that (X 1 A) c X 1 A c Combining these we have that X 1 A c =(X 1 A) c (d) (5 marks) Suppose that X is a random variable and A and B are mutually disjoint subsets of R 1 Prove that P (X A B) =P (X A) P (X B) P (X A B) =P (X 1 (A B)) = P (X 1 A X 1 B)=P (X 1 A) P (X 1 B) since X 1 A X 1 B = φ Now P (X 1 A) = P (X A) and P (X 1 B)=P (X B) and the result is obtained (a) (10 marks) Suppose we pick two cards at random from an ordinary 52-card deck What is the probability that the sum of the values of the two cards (where we count Jacks, Queens, and Kings as ten, and count Aces as one) is at least four? P ("the sum of the values of the two cards is at least four") 2
=1 P ("thesumofthevaluesofthetwocardsislessthanfour") =1 P ({2 aces, 1 ace and 1 two}) =1 (4 2)( 4 1)( 4 1) ( 52 2 ) (b) (10 marks) A class of two hundred students is to be randomly divided into three subclasses of sizes 40, 60 and 100 respectively What is the probability that friends are all allocated to the same class? What is the probability that they are allocated to different classes? The number of divisions is ( 200 40 60 100) and they are equally likely The number of splits that contain the three friends is (sum of number of divisions where they are all in the class of 40, the class of 60 and the class of 100) ( ) 7 60 100 ( ) 40 57 100 ( ) 40 60 97 Therefore the probability of the three friends being in the same class is (( ) ( ) ( )) ( ) 200 / =015669 7 60 100 40 57 100 40 60 97 40 60 100 The probability that all are in different classes is ( ) ( ) 200! / 9 59 99 40 60 100 4 (a) (5 marks) Suppose that p (s) is defined on S = {1, 2,, 4, 5} by s 1 2 4 5 p 2 2 2 1 If X 1,X 2 are independent random variables, each with probability function p then calculate P (X 1 = X 2 ) P (X 1 = X 2 )=P (X 1 = X 2 =1)P (X 1 = X 2 =2)P (X 1 = X 2 =) P (X 1 = X 2 =4)P (X 1 = X 2 =4) =() 2 (2) 2 (2) 2 (2) 2 (1) 2 =022
(b) (5 marks) Suppose that a piece of software has probability 02 of crashing when a certain operation is performed If this operation is performed n independent times What is the distribution of the number of crashes? Indicate precisely how you would compute the probability of 10 crashes when n = 100 ThenumberofcrashesX is distributed Binomial(n, 02) so that ( ) 100 P (X = 10) = (02) 10 (98) 90 10 (c) (5 marks) (continuation of (b)) Suppose that n is very large, indicate how you would compute the probability of experiencing 10 crashes We use the Poisson approximation In this case we approximate the Binomial(n, 02) by the Poisson(2n/100) distribution so that P (X =10) (2n/100)10 exp { (2n/100)} 10! (d) (5 marks) A certain computer program contains a loop The test for exiting the loop is based on the generation of a random variable X inside the loop The test is passed when the the value of X is less than If X is uniformly distributed on {1, 2,, 4, 5} determine the probability that the test fails 4 times before the program exits the loop We have that the number of failures before exiting is distributed Geometric(2/5) Therefore ( ) 4 2 P ("4 failures") = 5 5 (e) (5 marks) Consider the function defined by { x2 / 0 <x<2 f(x) = 0 otherwise Is f a probability density function? Explain why or why not? Certainly f(x) 0 but 2 0 f(x) dx = x 2 0 = 8 0 = 8 1 4
and so f is not a probability density (f) (5 marks) Suppose that an urn contains 0 red balls and 70 white balls The urn is thoroughly mixed and a ball is drawn, its color is observed and then it is replaced in the urn We continue drawing from the urn in this fashion until 4 red balls have been observed What is the probability that there are 12 white balls drawn before the fourth red ball is observed? The number of white balls drawn until the fourth red ball is distributed Negative Binomial(4, /10) Therefore P ("12 white balls drawn") = ( )( ) 15 7 12 ( ) 4 12 10 10 5