University of California - Berkeley Department of Electrical Engineering & Computer Sciences EE126 Probability and Random Processes (Spring 2012) Discussion 9 Notes March 15, 2012 1. Midterm 2, Question 4 A retired professor comes to his office at any time beween 9 AM and 1 PM, with all times in that interval being equally likely, and performs a single task. The duration X of the task is exponentially distributed with parameter λ(Y ) = 1/(5 − Y ) where Y is the length of the time between 9 AM and his arrival, measured in hours. (a) What is the expected time that the professor devotes to his task? (b) What is the expected time that the professor leaves his office? The professor has a PhD student who, on any given day, comes to see the professor at a time that is uniformly distributed between 9 AM and 5 PM. If the student does not find the professor, he leaves and does not return. If he finds the professor, he spends an amount of time with the professor that is uniformly distributed between 0 and 1 hour, interrupting the time the professor spends on his task. The professor will spend the same amount of total time on the task regardless of whether he is interrupted by the student. (c) What is the probability the student arrives before the professor arrives? (d) What is the probability the student arrives after the professor leaves? (e) What is the probability the student finds the professor? (f) What is the expected time the professor spends with the student? (g) What is the expected time the professor leaves? 2. You are visiting the rainforest, but unfortunately your insect repellent has run out. As a result, at each second, a mosquito lands on your neck with probability 0.5. If one lands, with probability 0.2 it bites you, and with probability 0.8 it never bothers you, independently of other mosquitoes. (a) What is the expected time between successive mosquito bites? What is the variance of the time between successive mosquito bites? (b) In addition, a tick lands on your neck with probability 0.1. If one lands, with probability 0.7 it bites you, and with probability 0.3, it never bothers you, independently of other ticks and mosquitoes. Now, what is expected time between successive bug bites? What is the variance of the time between successive bug bites? 3. Problem 6.14 (a)-(c),(h)-(j), page 330 in text. Beginning at time t = 0, we begin using bulbs, one at a time, to illuminate a room. Bulbs are replaced immediately upon failure. Each new bulb is selected independently by an equally likely choice between a type-A bulb and a type-B bulb. The lifetime, 1 X, of any particular bulb of a particular type is a random variable, independent of everything else, with the following PDF: ( e−x , x ≥ 0, 0, otherwise; ( −3x 3e , x ≥ 0, for type-B bulbs: fX (x) = 0, otherwise. for type-A bulbs: fX (x) = (a) Find the expected time until the first failure. (b) Find the probability that there are no bulb failures before time t. (c) Given that there are no failures until time t, determine the conditional probability that the first bulb used is a type-A bulb. (h) Determine the probability that the total period of illumination provided by the first two type-B bulbs is longer than that provided by the first type-A bulb. (i) Suppose the process terminates as soon as a total of exactly 12 bulb failures have occurred. Determine the expected value and variance of the total period of illumination provided by typeB bulbs while the process is in operation. (j) Given that there are no failures until time t, find the expected value of the time until the first failure. Solutions: 1. (a) E[X] = E[E[X|Y ]] = E[5 − Y ] = 5 − E[Y ] Since Y is uniform on [0, 4], E[Y ] = 2, and therefore E[X] = 3 (b) The professor leaves at time 9 + Y + X. Then E[9 + Y + X] = 9 + E[Y ] + E[X] = 9 + 2 + 3 = 14. So the expected time the professor leave is 2pm. (c) Denote the length of time between 9am and the time the student arrives as W , which is uniform 1 on [0, 8] and independent of Y . Thus fW,Y (w, y) = 32 for 0 ≤ y ≤ 4, 0 ≤ w ≤ 8. This gives Z 4Z y fW,Y (w, y)dwdy P (W < Y ) = 0 = 0 Z 4Z y 1 0 32 0 dwdy = 1 4 (d) P (W > Y + X) = P (X < W − Y ) = Z 4Z 8 0 = Z 4Z 8 1 0 = = = 2 P (X < w − y)fW,Y (w, y)dwdy y y 32 Z 4 − w−y 5−y 1−e dwdy 1 − w−y w + (5 − y)e 5−y 32 0 Z 1 4 − 8−y 5−y 3+e dy 32 0 Z 4 3 1 − 8−y + e 5−y dy 8 32 0 8 dy w=y (e) Denote the event the student finds the professor as F . 1 3 1 P (F ) = 1 − P (W < Y ) − P (W > Y + X) = 1 − − + 4 8 32 Z 4 − 8−y 5−y e 3 1 − 8 32 dy = 0 Z 4 e − 8−y 5−y dy 0 (f) Denote the time spent with the student as T . Given F , T is uniform over [0, 1], and given F C , T = 0. E[T ] = E[T |F ]P (F ) + E[T |F C ]P (F C ) 1 = P (F ) + 0(1 − P (F )) 2 Z 3 1 4 − 8−y = e 5−y dy − 16 64 0 (g) The expected time the professor leaves is E[9 + Y + X + T ] = 9 + E[Y ] + E[X] + E[T ] = 14 + 3 1 − 16 64 Z 4 e − 8−y 5−y dy, 0 which is about 2:09:36 pm. 2. (a) Let X = (time between successive mosquito bites) = (time until the next mosquito bite). The mosquito bites occur according to a Bernoulli process with parameter p = (0.5)(0.2) = 0.1. X is a geometric random variable, so E[X] = 1/p = 10 and var(X) = (1 − p)/p2 = 90. (b) Mosquito bites occur according to a Bernoulli process with parameter p = 0.1. Tick bites occur according to another independent Bernoulli process with parameter q = (0.1)(0.7) = 0.07. Bug bites (mosquito or tick) occur according to a merged Bernoulli process from the mosquito and tick processes. Therefore, the probability of success at any time point for the merged Bernoulli process is r = p + q − pq = 0.1 + 0.07 − (0.1)(0.07) = 0.163. Let Y be the time between successive bug bites. As before, Y is a geometric random variable, so E[Y ] = 1/r = 1/0.163 ≈ 6.135 and var(Y ) = (1 − r)/r2 = (1 − 0.163)/0.1632 ≈ 31.503. 3. (a) Let X be the time until the first bulb failure. Let A (respectively, B) be the event that the frist bulb is of type A (respectively, B). Since the two bulb types are equally likely, the total expectation theorem yields 1 2 E[X] = E[X|A]P (A) + E[X|B]P (B) = 1 + 11 2 = . 32 3 (b) Let D be the event of no bulb failures before time t. Using the total probability theorem, and the exponential distributions for bulbs of the two types, we obtain 1 1 P (D) = P (D|A)P (A) + P (D|B)P (B) = e−t + e−3t . 2 2 3 (c) We have P (A|D) = 1 −t e P (A ∩ D) 1 . = 1 −t2 1 −3t = P (D) 1 + e−2t + 2e 2e (d) The lifetime of the first type-A bulb is XA , with CDF given by: FXA (x) = 1 − e−x for x ≥ 0. Let Y be the total lifetime of two type-B bulbs. Because the lifetime of each type-B bulb is exponential with λ = 3, the sum Y has an Erlang distribution of order 2 with λ = 3. Its PDF is: ( 9ye−3y y ≥ 0 fY (y) = 0 otherwise Since they are independent, we have P (G) = P (Y > XA ) = P (XA ≤ Y ) Z ∞ = Z0∞ = FXA (y)fY (y)dy 1 − e−y 9ye−3y dy 0 Z ∞ = 9 Z0∞ = 3 ye−3y − ye−4y dy 3ye−3y dy − 0 9 4 Z ∞ 4ye−4y dy 0 We can recognize the integrals as expectations of exponential random variables with means 7 and 41 , respectively, which gives us P (G) = 3 31 − 94 14 = 16 . 1 3 (e) Let V be the total period of illumination provided by type-B bulbs while the process is in operation. Let N be the number of light bulbs, out of the first 12, that are of type-B. Let Xi be the period of illumination from the ith type-B bulb. We then have V = X1 + XN . Note that N is a binomial random variable, with parameters n = 12 and p = 1/2, so that E[N ] = 6 and var(N ) = 3. Furthermore, E[Xi ] = 31 and var(Xi ) = 19 . Using the formulas for the mean and variance of the sum of a random number of random variables, we obtain E[V ] = E[N ]E[Xi ] = 2 and 1 var(V ) = var(Xi )E[N ] + (E[Xi ])2 var(N ) = 6 + 9 2 1 3 3 = 1. (f) Using the notation in parts (a)-(c), and the result of part (c), we have E[T |D] = t + E[T − t|D ∩ A]P (A|D) + E[T − t|D ∩ B]P (B|D) 1 1 1 = t+1 + 1 − 1 + e−2t 3 1 + e−2t 1 2 1 = t+ + . 3 3 1 + e−2t 4
© Copyright 2026 Paperzz