Download as pdf
Download as pdf
You are on page 1of 101
Section 3.1 Definitions Discrete Random Variables In this chapter and for most of the remainder of this book, we examine probability models that assign numbers to the outcomes in the sample space. When we observe one of these numbers, we refer to the observation as a random variable. * In our notation, the name of a random variable is always a€apital letter) for example, xX 0. (b) Dresy Px(w) = 1. (c) For any event B C Sx, the probability that X is in the set B is P[B] = So Px(). reB Proof: Theorem 3.1 All three properties are consequences of the axioms of probability (Sec- tion 1.2). First, Px(x) > 0 since Py(x) = P[X =a]. Next, we observe that every outcome s € S is associated with a number « € Sy. There- fore, P[z € Sx] = Yresy Px(x) = Pls € S] = P[S] = 1. Since the events {X =a} and {X = y} are mutually exclusive when x £ y, B can be writ- ten as the union of mutually exclusive events B = Ureg{X =a}. Thus we can use Axiom 3 (if B is countably infinite) or Theorem 1.2 (if B is finite) to write P[B]) = So PLX =a] = ¥ Px(2). (3.9) 2e€B «eB aatlahuy 2 an o) Psy “eas Section 3.3 Families of Discrete Random Variables seriments hive similar prob- bles, the PMs obles have the same mathematical form, ciffer- {n applications of probability. many ability mass fanetions. [na family of random van of the randoni vit ing only in the values of one or two parameters. Eamilies of Random Variables In practical applications, certain families of random variables appear over and over again in many experiments. « In each family, the probability mass functions of all the random variables have the same mathematical form They differ only in the values of one or two parameters. Depending on the family, the PMF formula contains one or two parameters. * By assigning numerical values to the parameters, we obtain a specific random variable. ¢ Our nomenclature for a family consists of the family name followed by one or two parameters in parentheses. * For example, binomial (n,p) refers in general to the family of binomial random variables. '* Binomial (7,0.1) refers to the binomial random variable with parameters n = 7 and p=0.1. Example 3.6 Consider the following experiments: « Flip a coin and let it land on a table. Observe whether the side facing up is heads or tails. Let X be the number of heads observed « Select a student at random and find out her telephone number. Let X = 0 if the last digit is even, Otherwise, let X¥ = 1 * Observe one bit transmitted by a modem that is downloading a file from the Inter- net. Let X be the value of the bit (0 or 1) All three experiments lead to the probability mass function 1/2 #=0, 1/2 #=1, (3.11) 0 otherwise. w) Definition 3.4 Bernoulli (py) Random Variable X is a Bernoulli (p) random variable if the PMF of X has the form l-p «r=0, Px(v) = yp v=1, 0 otherwise, where the parameter p is in the rangeO 1. Whenever we have a sequence of n independent Bernoulli trials each with success probability p, the number of successes is a binomial random variable. Note that a Bernoulli random variable is a binomial random variable with n= 1. Example 3.10 Problem 2 0.00000 %0 coe? Example 3.10 Solution For large values of k, it is not practical to draw the tree. In this case, L = / if and only if there are k—1 successes in the first |—1 trials and there is a success on trial | so that P[L=I] =P |k—1 rejects in |—1 attempts. reject on attempt / (3.15) eee * % ‘The events A and B are independent since the outcome of attempt / is not affected by the previous /— 1 attempts. Note that P[4] is the binomial probability of k—1 successes (i.e., rejects) in /—1 trials so that t-1 A] = Aq — pyri) 1 PLal= (a -p) (3.16) Finally, since P[B] = I k 1 PLO = P[A]P [B] =( 1 Jha =p (3.17) L is an example of a Pascal random variable De n 3.7 Pascal (k,p) Random Variable X is a Pascal (k,p) random variable if the PMF of X has the form P(o) = (Fj) - pyr where 0 1. In general, the number of Bemoulli trials that take place until one of the two outcomes is observed & times is a Pascal random variable, For a Pascal (kp) random variable X, Py(z) is nonzero only for =k, k-+1,...- Example 3.11 In an experiment with equiprobable outcomes, the random variable N has the range Sy = {k,k+1,k+2,--- ,l}, where k and J are integers with k <1. The range contains /—k-+ 1 numbers, each with probability 1/(l—k+1). Therefore, the PMF of N is Pr = {ered n=kk+1,k+2,. (18) otherwise N is an example of a discrete uniform random variable. Discrete Uniform (k,/) Random Definition 3.8 Variable X is a discrete uniform (k,l) random variable if the PMF of X has the form Py(e) = (VCH RFD BH Bh Rt LEE. “elo otherwise where the parameters k and | are integers such that k < l. Example 3.12 Roll a fair die. The random variable N is the number of spots on the side facing up. Therefore, N is a discrete uniform (1,6) random variable with PMF 0.2 P(r) 1/6 n=1,2,3,4,5,6, 0 otherwise. Py(n) = { (3.19) Def jon 3.9 Poisson (a) Random Variable X is a Poisson (a) random variable if the PMF of X has the form games P _ foren/x! 2 =0,1,2,..., volte x (@) 0 otherwise, where the parameter a is in the rangea>0. % flee 3-8 The probability model of a Poisson random variable describes phenomena that occur randomly in time. While the time of each occurrence is completely random, there is a known average number of occurrences per unit time. The Poisson model is used widely in many fields. For example, the arrival of information requests at a World Wide Web server, the initiation of telephone calls, and the emission of particles from a radioactive source are often modeled as Poisson random variables. a Poisson random variable, we will call the occurrence of the phe- nomenon of interest an arrival. A Poisson model often specifies an average rate, ()) arrivals per second, and time interval, T seconds. In this time interval, the number of arrivals X has a Poisson PMF with «= XT. ° : oon ONE Aor eo obs Example 3.13 Problem The number of hits at a website in any time interval is a Poisson random variable. A particular site has on average(A)= 2 hits per second. What is the probability that there are no hits injan interval of 0.25 seconds? What is the probability that there are no more than two hits in an interval of one second? M : ly, Wak tele a Example 3.13 Solution In an interval of 0.25 seconds, the number of hits H is a Poisson random variable with T = (2 hits/s) x (0.25 s) =0.5 hits. The PMF of 1 is e-08 = Pu(h) {ose /h! h=0,1,2 otherwise. 0 | I = 0 2 The probability of no hits is P [H = 0] = Px(0) = (0.5)%°9/0! = 0.607. (3.20) In an interval of 1 second, a = \T = (2 hits/s) x (1 s) = 2 hits. Letting J) denote the number of hits in one second, the PMF of JJ is 4 h 0.2 P, x3) my! Qie-2/j1 7 =0,1,2,... 0.1 rOD= Vo otherwise 0 02468 4 [Continued] Example 3.13 Solution (Continued 2) To find the probability of no more than two hits, we note that {J <2} ={J=O0}U{J =1pu{sJ=2} (3.21) is the union of three mutually exclusive events. Therefore, P[J <2] =P[J=0]+P[J=1]+P[J =2] = P;(0) + Pj(1) + Pj(2) = e7? + 24¢77/1! + 2777/2! = 0.677. (3.22) Example 3.14 Calls arrive at random times at a telephone switching office with an average of \ = 0.25 calls/second. The PMF of the number of calls that arrive in a T = 2-second interval is the Poisson (0.5) random variable with PMF 1 PXG) 5 (0.5)%e~9-5/j! f= 0,1,..., PIG) = : oO otherwise. 0 2 4 j Note that we obtain the same PMF if we define the arrival rate as A = 60-0.25 = 15 calls per minute and derive the PMF of the number of calls that arrive in 2/60 = 1/30 minutes. Section 3.4 Cumulative Distribution Function (CDF) Cumulative Distribution ion 3.10 Function (CDF) Defi The cumulative distribution function (CDF) of random variable X is Fy (a) =P[X 2, Fy(2!) > Py(e). powiny Potion (c) For w; € Sx and e, an arbitrarily small positive number, fina Fx(ei) — Fei = Px). hee (d) Fx(#) = F(a) for all a such that a; a, Fx (6) — Fx(a) =P [a 1, the CDF is n n 4 /3\5-1 Fy(n) = > PyQG)= > = ) . (3.26) fa it Equation (3.26) is a geometric series. Familiarity with the geometric series is essential for calculating probabilities involving geometric random variables. Appendix B summarizes the most important facts. In partic- ular, Math Fact B.4 implies (1 — 2) Dp et = 1-2". Substituting «a = 3/4, we obtain 3\n (G) : (3.27) The complete expression for the CDF of Y must show F\(y) for all integer and noninteger values of y. [Continued] Fyn) = Example 3.16 Solution (Continued 2) For an integer-valued random variable Y, we can do this in a simple way using the floor function |y|, which is the largest integer less than or equal to y. In particular, if n ag? =? Peas. (3.41) 2=1 Vy=1 Theorem 3.6 The Poisson (a) random variable in Definition 3.9 has expected value Proof: Theorem 3.6 ERX] = Sr aPe(e = > (3.42) 2=0 2=0 We observe that «/a! = 1/(a—1)! and also that the « = 0 term in the sum is zero. In addition, we substitute a = a-a*-! to factor a from the sum to obtain (3.43) Next we substitute = x —1, with the result a! EX] = vt “ (3.44) oe We can conclude that the sum in this formula equals 1 either by referring to the identity © = DS, al/l!_or by applying Theorem 3.1(b) to the fact that the sum is the sum of the PMF of a Poisson random variable L over all values in S;, and P[Sr] Theorem 3.7 (a) For the binomial (n,p) random variable X of Definition 3.6, E[X] = np. (b) For the Pascal (k,p) random variable X of Definition 3.7, E[X]=k/p. (c) For the discrete uniform (k,l) random variable X of Definition 3.8, E[X] =(k+0/2. Theorem 3.8 Perform n Bernoulli trials. In each trial, let the probability of success be a/n, where a > O is a constant and n > a. Let the random variable Kn be the number of successes in the n trials. As n > co, Px,(k) converges to the PMF of a Poisson (a) random variable. Proof: Theorem 3.3 cd F We first note that Ky is the binomial (h, qj) random variable with PMF ot jevantl & Prtk) = ()(a/nyk (1S) (3.45) For k +m, we can write Pe (k) = MMA De = b+ Dol (- aye 3.46. nk Mm 46) Notice that in the first fraction, there are k terms in the numerator. The denominator is n’, also a product of k terms, all equal to n. Therefore, we can express this fraction as the product of k fractions, each of the form (nm —j)/n. As n— co, each of these fractions approaches 1. Hence, ic & =1 (3.47) n Furthermore, we have (3.48) [Continued] Proo : Theorem 3.8 (Continued 2) AS n grows without bound, the denominator approaches 1 and, in the numerator, we recognize the identity limn+0.(1—a/n)" = e~*. Putting these three limits together leads us to the result that for any integer k > 0, ken*/kl k= lim r= {8 ce“ /kl k=0,1,... 3.49 noe 0 otherwise, G9) which is the Poisson PMF. Section 3.6 \ Wal \V Y Functions of a Random Variable eM Definition 3.12 Derived Random Variable Each sample value y of a derived random variable Y is a mathematical function g() of a sample value x of another random variable X. We adopt the notation Y = g(X) to describe the relationship of the two random variables. A funetion Y = g(X) of randon able X js another random vatiable. The PMF P\(y) can be derived from Py(xr) and g(X). In many practical situations, we observe sample values of a random variable and use these sample values to compute other quantities. One example that occurs frequently is an experiment in which the procedure is to monitor the data activity of a cellular telephone subscriber for a month and observe x the total number of megabytes sent and received. The telephone company refers to the price plan of the subscriber and calculates y dollars, the amount to be paid by the subscriber. If x is a sample value of a random variable X, Definition 3.1 implies that y is a sample value of arandom variable Y. Because we obtain Y from another random. variable, we refer to Y asa derived random variable, Example 3.19 Problem A parcel shipping company offers a charging plan: $1.00 for the first pound, $0.90 for the second pound, etc., down to $0.60 for the fifth pound, with rounding up for a fraction of a pound. For all packages between 6 and 10 pounds, the shipper will charge $5.00 per package. (It will not accept shipments over 10 pounds.) Find a function Y = g(X) for the charge in cents for sending one package. &' (oo if a) (80 + (!00- 10x) ) % 4s 0 cee - 4. tp ifr > > Loo = vom YA 2 (90% 5 x Example 3.19 Solution When the package weight is an integer e€ {1,2,...,10} that specifies the number of pounds with rounding up for a fraction of a pound, the function Y=9(x)= 105X —5X2. X =1,2,3,4,5 g 500 X =6,7,8,9, 10. corresponds to the charging plan. (3.50) Theorem 3.9 For a discrete random variable X, the PMF of Y = g(X) is PY= Yo Px(2). wg(a=y To describe Y in terms of our basic model of probability, we specify an experiment, consisting of the following procedure and observation: Sample value of Y =9(X Perform an experiment and observe an outcome s. From s, find r, the correspading value of random variable X. Observe y by calculating y= g(x). Example 3.20 Problem In Example 3.19, suppose all packages weigh 1, 2, 3, or 4 pounds with equal probability. Find the PMF and expected value of Y, the shipping charge for a package. a A gewo Etat): erly ° _lootito ta pt34e _Qoo _ = md “e \te baw) : & % ° 2 aoe 2119 a3 ye 2 E 4 Ye BFP OE Figure 3.1 Y=100 Y=190 Y=270 Y=340 Y=400 Y=500 The derived random variable Y = g(X) for Example 3.21. Example 3.20 Solution From the problem statement, the weight X has PMF 1/4 &=1,2,3,4, P: = 3.52 x(@) {3 otherwise. > The charge for a shipment, Y, has range Sy = {100, 190,270,340} cor- responding to Sy = {1,...,4}. The experiment can be described by the following tree. Here each value of Y derives from a unique value of X. Hence, we can use Equation (3.51) to find Pyy). 1/4 y= 100,190, 270, 340, -X=10eY=100 = va ° yO {; otherwise. 1/4_-x=2ey=190 ~ The expected shipping bill is X=3eY=270 1 1/4 NX =4eY=340 Efy]= giioo +190 + 270 + 340) = 225 cents. Example 3.21 Problem Suppose the probability model for the weight in pounds X of a package in Example 3.19 is 02 Px(a) ol 0.15 2=1,2,3,4, . Px(@)=40.1 2 =5,6,7,8, 0 0 otherwise. 0 5 10 @& For the pricing plan given in Example 3.19, what is the PMF and expected value of Y, the cost of shipping a package? Pyuoo) = ats Plerjz0 EX) = (loot or mor3-40)!5 Pyar) = ols 0 (600) =05 fv *> | dxras) = OS x Sodx odd RY 3u8) = 015 325 Cent Example 3.21 Solution Now we have three values of X, specifically (6,7,8), transformed by g(-) into Y = 500. For this situation we need the more general view of the PMF of Y, given by Theorem 3.9. In particular, yg = 500, and we have to add the probabilities of the outcomes X = 6, X = 7, and X =8 to find Py({500). That is, Py(500) = Py (6) + Py(7) + Px (8) = 0.30. (3.53) The steps in the procedure are illustrated in the diagram of Figure 3.1. Applying Theorem 3.9, we have -L = 100, 190, 270,340, Pry) 0.2 ate ye ye 90, 270, 340. PyW)=4oa5 yon 0.30 y=500, 100 270 500 0 otherwise. y For this probability model, the expected cost of shipping a package is E [Y] = 0.15(100 + 190 + 270 + 340) + 0.10(400) + 0.30(500) = 325 cents Section 3.7 Expected Value of a Derived Random Variable IY =9(X), E/Y| ean be calculated from Py(2) and g(X) without deriving yy). Theorem 3.10 Given a random variable X with PMF Px(a) and the derived random variable Y = g(X), the expected value of Y is EM] Sey = Y g(@)Px(@)- reSx Proof: Theorem 3.10 From the definition of E[Y] and Theorem 3.9, we can write EY]=VLwAWwM= Vy VY Pe@M= LV DY ge)Px@), yesy yESy w:g(a)=y yeSy x:g@)=y (3.55) where the last double summation follows because g(x) = y for each 2 in the inner sum. Since g(a) transforms each possible outcome x € Sx toa value y € Sy, the preceding double summation can be written as a single sum over all possible values « € Sy. That is, EY]= ¥ g@)Px(e). (3.56) weSy Example 3.22 Problem In Example 3.20, 1/4 «© =1,2,3,4 P. = »2,3,4, x(@) {3 otherwise, 105X —5X2 1 2? Px(a)- Yo 2xePx(e)+ YO wR Px(x) eSy EeSy weSy = ELX?] — Quy So aPx(e)+u% YD Pye) weSy weSx = E[X?] — 2% + pw. (3.71) Definition 3.15 Moments For random variable X: (a) The nth moment is E[X”]. (b) The nth central moment is E[(X — py)". Example 3.25 Problem Continuing Examples 3.5, 3.18, and 3.23, we recall that X has PMF 0.5 Px(x) 1/4 x=0, 1/2 #=1, | | Px (a) = va —_ (3.72) 0 ; “1 004 2 3 2 0 otherwise, and expected value E[X] = 1. What is the variance of X? Example 3.25 Solution In order of increasing simplicity, we present three ways to compute Var[X] * From Definition 3.13, define W = (X~ px) = (X-1)7 (3.73) We observe that W = 0 if and only if X = 1; otherwise, if X = 0 or X = 2, then W=1. Thus P[W = 0] = Px(1) = 1/2 and P[W = 1] = Px(0) + Px(2) = 1/2. The PMF of W is 1/2 w=0,1, Fv (w) = {0 inerse. ad Then Var [X] = E [W] = (1/2)(0) + (1/2)(1) = 1/2. (3.75) * Recall that Theorem 3.10 produces the same result without requiring the derivation of Pw(w) Var[X] = E [(X — px)? (0 — 1)?Px(0) + (1 = 1)?Px (1) + (2 — 1)?Px(2) =1/2 (3.76) * To apply Theorem 3.14, we find that E [X7] = 07Px(0) + 17Px(1) + 2?Px(2) = 15 (3.77) Thus Theorem 3.14 yields Var [X] = E [X?] — p& = 15-1? =1/2. (3.78) Theorem 3.15 ue ec aa = 2 cyl EC Y Evan lax + 6] = a? Var [x]. Yor UX) + ela eter - Cc 3 Elan) s(ab i) 4b) = O60 + 254d 2 + 2 J Elec - Larter) i = CER) + wh + Y ot (20i\- wet | = aedatX) Proof: Theorem 3.15 We let Y = aX +6 and apply Theorem 3.14. We first expand the second moment to obtain E [y?| =E [a2x? + 2abX + | =0?E [x?] + 2abux + b?. (3.80) Expanding the right side of Theorem 3.12 yields Hy = a? WX + 2abpiz + b?. (3.81) Because Var[Y] = E[Y?] — By, Equations (3.80) and (3.81) imply that. Var [Y¥] = a E [X?] — au = a2(E [X?] - %) = a? Var[X]. (3.82) Example 3.26 Problem A printer automatically prints an initial cover page that precedes the regular printing of an X page document. Using this printer, the number of printed pages is Y = X +1. Express the expected value and variance of Y as functions of ELX] and Var[X]. Example 3.26 Solution The expected number of transmitted pages is E[Y] = E[X] +1. The variance of the number of pages sent is Var[Y] = Var[X]. Example 3.27 Problem The amplitude V (volts) of a sinusoidal signal is a random variable with PME 0.2 Pv) 1/7 v=-3,-2,...,3, Py) = vv) {3 otherwise. 0 -5 0 Sou A new voltmeter records the amplitude U in millivolts. Find the variance and standard deviation of U. Example 3.27 Solution Note that U = 1000V. To use Theorem 3.15, we first find the variance of V. The expected value of the amplitude is py =1/7[-3 + (-2) + (-1) +0414+243] =0 volts. (3.83) The second moment is E [V7] = 1/71(-3)? + (-2)? + (-1)? +0? + 1? +27 +39] = 4 volts’. (3.84) Therefore the variance is Var[V] = E[V?] — p?, = 4 volts?. By Theo- rem 3.15, Var [U] = 1000? Var[V] = 4,000,000 millivolts?, (3.85) and thus oy = 2000 millivolts. Theorem 3.16 (a) If X is Bernoulli (p), then Var[X] = p(1 — p). (b) If X is geometric (p), then Var[X] = (1 — p)/p?. (c) If X is binomial (n,p), then Var[X] = np(1 - p). (d) If X is Pascal (k,p), then Var[X] = &(1 — p)/p?. (e) If X is Poisson (a), then Var[X] =a. (f) If X is discrete uniform (k,l), Var[X] = (l= k)(U = k + 2)/12.

You might also like