EXAM Exam # Math 3342 Summer II, 2 July 2, 2 ANSWERS
i
pts. Problem. Consider the following data: 7, 8, 9, 2,, 7, 2, 3. Find the first quartile, the median, and the third quartile. Make a box and whisker plot. We have x () 7, x (2) 8, x (3) 9, x (4) 2, x (), x (6) 7, x (7) 2, x (8) 3. The index for the quantile of order p is i np +.. Thus the index for the first quartile is i 8(.2) +. 2., so the first quartile is x (2.) x (2) + x (3) 2 (8 + 9)/2 8.. The index for the median is 8(.) +. 4., so the median is x (4.) (x (4) + x () )/2 (2 + )/2 3.. The index for the third quartile is 8(.7) +. 6., so the third quartile is x (6.) (x (6) + x (7) )/2 (7 + 2)/2 2. The corresponding box and whisker plot is this: 7 8. 3. 2 3 2 3 6 pts. Problem 2. A hand of cards is drawn randomly from an ordinary deck of 2 cards.. Find the probability that the hand contains exactly 3 hearts. The probability of getting exactly 3 hearts would be (the number of ways of choosing 3 hearts) times (the number of ways of choosing 2 non-hearts),
divided by the number of ways of choosing a card hand. Thus ( )( ) 3 39 P (3 hearts) 3 2 ( ).84 2 2. Find the probability that the hand contains no hearts. ( ) 39 P (no hearts) ( ).22 2 3. Find the probability that the hand contains at least one heart. ( ) 39 P (at least one heart) P (no hearts) ( ).778 2 pts. Problem 3. A hand of cards is drawn randomly from an ordinary deck of 2 cards. Find the conditional probability that the hand consists of all hearts, given that it contains at least one heart. Let A be the event that the hand consists of all hearts (i.e., the subset of the sample space consisting of hands that are all hearts) and let B be the event that the hand contains at least one heart (i.e., the subset of the sample space consisting of hands that contain at least one heart). By definition P (A B) P (A B). () P (B) We have A B A, since A B. We can compute P (A) ( ) 3 P (A) ( ). 2 2
As in the previous problem, Plugging into () yields ( ) 39 P (B) ( ). 2 ( ) 3 P (A B) P (A) P (B) ( ) 2 ( ) 39 ( ) 2.636. pts. Problem 4. A fair coin is flipped until the first head appears.. Find the probability that the first head occurs on the fourth flip. In order to get the first head on flip x, the first x flips would have to be tails, which has probability (/2) x, and the xth flip would have to be heads, which has probability /2, thus the probability of getting the first head on the xth flip is /2 x. Thus, the probability of getting the first head on the fourth flip is 2 4 6.62 2. Find the probability that the first head occurs on or before the fourth flip. P (st H on or before 4th flip) P (st H on st flip) + P (st H on 2nd flip) + P (st H on 3rd flip) + P (st H on 4th flip) 2 + 2 2 + 2 3 + 2 4 6.937 3
6 pts. Problem. Let X be a random variable that can assume the values,, 2, 3 and 4. The probability density function f(x) of this random variable is as follows:. Find P ( X 3). x 2 3 4 f(x)..2.4..2 P ( X 3) P (X ) + P (X 2) + P (X 3) f() + f(2) + f(3).2 +.4 +..7 2. Find the mean µ E[X]. µ E[X] xf(x) x R (.) + (.2) + 2(.4) + 3(.) + 4(.2) 2. 3. Find the variance of X, Var(X) Recall that Var(X) E[(X µ) 2 ] E[X 2 ] µ 2. In the present case, E[X 2 ] x 2 f(x) x R Thus, 2 (.) + 2 (.2) + 2 2 (.4) + 3 2 (.) + 4 2 (.2).9 Var(X) E[X 2 ] µ 2.9 (2.) 2.49. 4
7 pts. Problem 6. A machine produces defective parts with a probability of p.3. Assume that 6 parts are made and that the trials are independent.. Find the probability that exactly 3 defective parts are produced. The number Y of defective parts produced follows the binomial distribution b(6,.3). Thus, ( ) 6 P (Y y) (.3) y (.7) 6 y. y The probability of exactly 3 defective parts being produced is P (Y 3) ( ) 6 (.3) 3 (.7) 3.82. 3 2. Find the probability that at least defective parts are produced. At least defective parts would mean either or 6 defective parts. Thus, P (X ) P (X ) + P (X 6) ( ) ( ) 6 6 (.3) (.7) + (.3) 6 (.7) 6 6(.3) (.7) + (.3) 6.93. 3. Find the expected number of defective parts. The mean of the binomial distribution b(n, p) is np. Thus, in this case, the expected number of defective parts is 6(.3).8. 4. What is the variance of this probability distribution? The variance of b(n, p) is npq np( p). distribution is 6(.3)(.7).26. Thus the variance of this
pts. Problem 7. Consider a continuous random variable X whose probability distribution function is given by f(x) 2x, x <. Find P (/2 X ). P (/2 X ) /2 /2 f(x) dx 2x dx x 2 /2 /4 3 4. 2. Find the mean µ E[X]. By definition, the mean is µ E[X] xf(x) dx. In this case, the probability density f(x) is zero outside the interval between and, so we have µ 2 3 x3 xf(x) dx xf(x) dx x(2x) dx 2x 2 dx 2 3 ()3 2 3 ()3 2 3. 6
3. Find the variance of X, Var(X). Use the formula Var(X) E[X 2 ] µ 2. In this case, Thus, E[X 2 ] 2 4 x4 2. x 2 f(x) dx x 2 f(x) dx x 2 (2x) dx 2x 2 dx Var(X) E[X 2 ] µ 2 2 ( 2 3 ) 2 8.6. 4. Sketch the graph of the cumulative distribution function F (x) of X. The cumulative distribution function F is defined by F (x). For x, the p.d.f. f(x) is zero on the interval (, x], so F (x). For x between and, we have F (x) + 2t dt t 2 tx t x 2. 7
For x >, we use the fact that the p.d.f. f(x) is zero on the intervals (, ] and [, x]. Thus, F (x) + 2t dt t 2. + Thus, we have calculated that, < x F (x) x 2, x, x < Here is a sketch of the function.. y. y F(x).... 2 x. Find the median of X, i.e., the th-percentile. 8
The median, or th-percentile, or quantile of order., is the point x. so that F (x. ).. Since <. <, the solution of this equation is the same as the solution of Thus, x 2. /2. x. /2 2/2.77. 9