1、 1H 0T)(XX TH 01 THS,2.1 Random VariablesExample 1 Toss coin:1SHT)(eXR10R)(XSExample 2 Test the life in years of light bulbs:S 0 tt)(tXX t)(St Definition 2.1Let S be the sample space associated with a particular experiment.A single-valued function X assigning toS every element a real number,X(),is c
2、alled a random variable.Denoted by X.2In general,Definition 2.1S Let S be the sample space associated with a particular experiment.A single-valued function X assigning to every element a real number,X(),is called a random variable.Denoted by X.and x,y,zrepresent a real number.we use X,Y,Z.represent
3、a random variableNotice that RX is always a set of real numbers.Definition 2.2 The set of all possible values of X is called the rangespace of X and is denoted by RX.3,Rx S ),(baX xX aX )(aX S xX )(),()(baX Definition 2.2 The set of all possible values of X is called the rangespace of X and is denot
4、ed by RX.Notice that RX is always a set of real numbers.For above example,1 X 1 XP ,H 21 S 421 1 X 0 X 1 XP ,T TH,S 1 SP 0 XPFor above example,1 X 1 XP ,H 21 5Random variable could take different values depending on different random experiments.Because the experiment results show up randomly the ran
5、dom variable could take values depending on certain kind of probability.(2)The way to take the values for random variable obeys kind of probability rule.Random variable is kind of function,but it is essentially different to the other general functions.The later kind of functions are defined on real
6、number set while random variables are defined on the sample space whose elements would not all be real numbers.2.NotesNotes(1)Random variable is different to the common function6The concept of random event is contained within the concept of random variable,which is more extended.From another point o
7、f view we can say random event is to search the random phenomena by a static method while random variable is to do so by a dynamic way.(3)The relationship between random event&variable7Categories of random variableCategories of random variableDiscrete Observe the number displayed on a rolling dice.P
8、ossible values for a random variable X:Random VariableContinuouse.g.11,2,3,4,5,6.Non-discreteOthers(1)Discrete if the number of values a random variable could take is finite or countable infinite then this variable is called discrete random variable.89e.g.2 Let X be a random variable representing“Th
9、e number of shootings as one shoots continuously until the target is shot.”.Then the possible values X could take:.,3,2,1e.g.3 If the probability for one shooter to shoot the target is 0.8,now he has shot 30 times and let X be the random variable to represent“The number of shootings that are shot on
10、 the target”,Then the possible values X could take:.30,3,2,1,010e.g.2 Random variable X represents“The measuring errors for some machine parts”.Then the values X could take is (a,b).e.g.1 Random variable X represents“The length of life for a lamp”.).,0 (2)Continuous If all possible values a random v
11、ariable could take will fully fill in an interval on the axis,this variable will be call a continuous random variable.Then the values X could take is11Summary2.Two ways to classify random variable:discrete、continuous.1.Probability theory quantitatively examines the inherent pattern of random phenome
12、na,thus in order to effectively search into random phenomena,we must quantify random events.When representing some non-numerical random event with numbers,the concept of random variable is established.Therefore,random variable is defined as a special function in the sample space.,21 nXxxxR.0)(iallfo
13、rxpi 1.1)(iixp2.2 Discrete random variables Definition 2.3XiRx With each possible outcome,we associate a)()(iixXPxp Numbercalled the probability of xi,2,1),(ixpiThe numbersmust satisfy(i)(ii)A random variable X is said to be a discrete randomvariable if its range space is either finite or countablyi
14、nfinite,i.e.12,2,1)(,(ixpxii.0)(iallforxpi 1.1)(iixp,2,1),(ixpiThe numbersmust satisfy(i)(ii)Definition 2.4 The function p is called the probability mass functioncalled the probability distribution of X.(pmf)and the collection of pairsix)(ixp1x2xix)(1xp)(2xp)(ixp13ix)(ixp1x2xix)(1xp)(2xp)(ixpExample
15、 2.1Solution:Let X be a random variable whose values xare the possible numbers of defectivecomputers Purchased by the school.Then x can be any of the numbers 0,1,and 2.A shipment of 8 similar microcomputers to a retailoutlet contains 3 that are defective.a random purchase of 2 of these computers,fin
16、d theprobability distribution for the number of defectives.If a school makes1428C,2810,2815)1(XP28C 2503CC1513CCSolution:Let X be a random variable whose values xare the possible numbers of defectivecomputers Purchased by the school.Then x can be any of the numbers 0,1,and 2.283 280523CCC)2(XPThus t
17、he probability distribution of X is x 0 1 2p(x)2810)0(XP2815283152.3 Some Important Discrete Probability Distributionsnxxx,21ninxpxXPii,2,1,1)()()1;(nxfXiUniformWe have a finite set of outcomeswhich has the same probability of occurring(equally likely outcomes).X is said to have a Uniform distributi
18、on and weeach ofWriteSo16)1;(nxfiX is said to have a Uniform distribution and weWrite)1;(nxfibulb,Example 2.2When a light bulb is selected at random from a boxthat contains a 40-watt bulb,a 60-watt bulb,a 75-wattand a 100-watt bulb.FindSolution:100,75,60,40 Seach element of the sample space occurs w
19、ithprobability 1/4.Therefore,we have a uniform distribution:17,41)4;(xfSolution:100,75,60,40 Seach element of the sample space occurs withprobability 1/4.Therefore,we have a uniform distribution:.100,75,60,40 x.6,5,4,3,2,1,61)6;(xxfExample 2.3When a die is tossed,S=1,2,3,4,5,6.P(each element of the
20、sample space)=1/6.Therefore,we have a uniform distribution,with 18.6,5,4,3,2,1,61)6;(xxfExample 2.3When a die is tossed,S=1,2,3,4,5,6.P(each element of the sample space)=1/6.Therefore,we have a uniform distribution,with Bernoulli trialA Bernoulli trial is an experiment which has twoLet p=P(success),
21、q=P(failure)(q=1-p).success and failure.possible outcomes:0)(1)(failureXandsuccessX19 0,11,)()(xpqxpxpxXPThe pmf of X is Bernoulli trialA Bernoulli trial is an experiment which has twoLet p=P(success),q=P(failure)(q=1-p).success and failure.possible outcomes:0)(1)(failureXandsuccessXXkp0p 11por 20Be
22、rnoulli material.,1,0nRX Binomialeach of which must result in either a success with Consider a sequence of n independent Bernoulli trialsprobability of p or a failure with probability q=1-p.Let X=the total number of successes in these n trialso that nxppCxXPxnxxn,1,0,)1()(X is said to have a Binomia
23、l distribution with parametersP(the total number of x successes)=n and p and we write XBin(n,p)or Xb(x;n,p)Special case,211,0)1()(xppxXPxnx),1(pbX is said to have a Binomial distribution with parametersn and p and we write XBin(n,p)or Xb(x;n,p)Special case,when n=1,we have We write B(n,p)1 nb(1,p)22
24、Binomial Distribution23 43,4;2b2224)431()43(C4243!2!2!4 12827 The probability that a certain kind of component will survive a given shock test is 3/4.Find the probability that exactly 2 of the next 4 components tested survive.Example 2.4 Assuming that the tests are independent andSolution:p=3/4 for
25、each of the 4 tests,we obtainExample 2.5The probability that a patient recovers from a rare blooddisease is 0.4.this disease,survive,If 15 people are known to have contractedwhat is the probability that(a)at least 10(b)from 3 to 8 survive,and(c)exactly 5 survive?24)10(XP9662.01 )83(XP 90)4.0,15;(1xx
26、b)10(1 XP0338.0 0.0271-0.9050 83)4.0,15;(xxb 8020)4.0,15;()4.0,15;(xxxbxb8779.0 The probability that a patient recovers from a rare blood disease is 0.4.If 15 people are known to have contracted this disease,what is the probability that(a)at least 10 survive,(b)from 3 to 8 survive,and(c)exactly 5 su
27、rvive?Example 2.5Solution:Let X=the number of people that survive.(a)(b)25)5(XP.-.2173040320)4.0,15;5(b 5040)4.0,15;()4.0,15;(xxxbxb18590.(c)83(XP 0.0271-0.9050 83)4.0,15;(xxb 8020)4.0,15;()4.0,15;(xxxbxb8779.0 (b)Example 2.6(a)The inspector of the retailer randomly picks 20 itemsA large chain retai
28、ler purchases a certain kind ofelectronic device from a manufacturer.indicates that the defective rate of the device is 3%.The manufacturer26from a shipment.(b)Suppose that the retailer receives 10 shipments in aA large chain retailer purchases a certain kind of electronic device from a manufacturer
29、.The manufacturer indicates that the defective rate of the device is 3%.Example 2.6(a)The inspector of the retailer randomly picks 20 items Solution:(a)Denote by X the number of defectiveDevices among the 20.Then this X follows a b(x;20,0.03).will be at least one defective item among these 20?What i
30、s the probability that thereshipments containing at least one defective device?shipment.month and the inspector randomly tests 20 devices perWhat is the probability that there will be 3Hence270200)03.01(03.01 )1(XP4562.0)03.0,20;0(1b )0(1 XP Solution:(a)Denote by X the number of defectiveDevices amo
31、ng the 20.Then this X follows a b(x;20,0.03).Hence(b)Assuming the independence from shipment to.1602.0 3103310)4562.01(4562.0 C)3(YPTherefore,shipment and denoting by Y.Y=the number of shipments containing at least onedefective.Then Yb(y;10,0.4562).28(b)Assuming the independence from shipment to.160
32、2.0 3103310)4562.01(4562.0 C)3(YPTherefore,shipment and denoting by Y.Y=the number of shipments containing at least onedefective.Then Yb(y;10,0.4562).,2,1,0,!)(xxexXPx PoissonThe pmf of a random variable X which has a Poisson0 distribution with parameter is given by 29 ,2,1,0,!)(xxexXPx ).;(xpXPoiss
33、onThe pmf of a random variable X which has a Poissonand we write0 distribution with parameter is given by 30Poisson material31Number of telephone ringsNumber of traffic accidentNumber of customers at receptionEarthquakeVolcanic EruptionMass floodingPoisson distribution32单击图形播放单击图形播放/暂停暂停ESCESC键退出键退出
34、Binomial distribution Poisson distribution)(nnp 33)4;6(p4 .1042.0 7851.08893.0 !6464 e 6050)4;()4;(xxxpxpDuring a laboratory experiment the average number of radioactive particles passing through a counter in 1 millisecond is 4.What is the probability that 6 articles enter the counter in a given mil
35、lisecond?Example 2.7Solution:Using the Poisson distribution with x=6 and,We find from Table 1 thatExample 2.8Ten is the average number of oil tankers arriving eachday a certain port city.The facilities at the port can34handle at most 15 tankers per day.Example 2.8Ten is the average number of oil tan
36、kers arriving each day a certain port city.The facilities at the port canSolution:Let X be the number of tankers arriving eachday.Then,)15(XP0487.0 9513.01 150)10;(1xxp)15(1 XPWhat is the probability that on a given day tankershave to be turned away?using Table,we have 352.4 Cumulative Distribution
37、Functions).()(bFaFthenba ),()()(xxXPxF)()(,xforxXPDefinition 2.5 The cumulative distribution function(cdf)of the random variable X is defined to beand is denoted by F(x).Properties of F(x):(i)F is non-decreasing.(ii),1)(0 xF1)(lim)(xFFxi.e.i.e.if0)(lim)(xFFandx36)0)()0()(0 hforhxFLimxFxFh).()(bFaFth
38、enba Properties of F(x):(i)F is non-decreasing.i.e.if(ii)0)(lim)(,1)(0 xFFandxFx1)(lim)(xFFx(iii)F is right continuous.(iv)F(x)is defined for all real numbers x.The cdf of a discrete random variable X is a step ixfunction with jumps at the)()(xXPxF )(xxiixXP xxiixP).(i.e.37The cdf of a discrete rand
39、om variable X is a step ixfunction with jumps at the)()(xXPxF )(xxiixXP xxiixP).(21xXxP )(12xXxXP 12xXPxXP xo)(xF 1x 2x 1p 2p 138 )()(1221xFxFxXxPThen 21xXxP )(12xXxXP 12xXPxXP aXP aXxaPx 0lim )(lim0 xaXPaxPx )(lim)(0 xaFaFx )0()(aFaFaXP 33221113/23/10)(xxxxxxxxxxxFe.g.39 33221113/23/10)(xxxxxxxxxxx
40、Fe.g.)(21xXxP )(1xP)(3xP32)()(12xFxF 3132 31 31)0()(11 xFxF)0()()(222 xFxFxP)(lim)(101xxFxFx 321 031 31 31 31 Example 2.9The pmf of X is40,21 XP,2523 XP ,32 XPThe pmf of X isFind:1)The Cumulative distribution function of X.2)kPX -1 2 3412141Solution:1)xXP2141 x x3412141322141 x 313243214111xxxx)(xF-
41、1 2 3x10 xExample 2.941Solution:1)xXP2141 x x3412141322141 x 313243214111xxxx)(xF-1 2 3x10 x 21F 21XP41 32 XP 322 XPXP 2523XP 2325FF4143 21 2)4243 4314143 )2()3()02()2(FFFF 21F 21XP41 32 XP 322 XPXP 2523XP 2325FF4143 21 2)x-1 0 1 2 3)(xF143 BdxxfBXP)()(2.5 Continuous Random VariablesDefinition 2.6 X
42、 is a continuous random variable if there exists aThe function f is called the probability density function with the property that for every subset of real),(nonnegative function f defined for all real xnumbers B(pdf)of X.xduufxF)()(Properties of the pdf(i)44),(x xduufxF)()(Properties of the pdf(i)T
43、his follows by setting B=,1)(dxxf(ii)xo)(xf1451)(lim)(xFFxThis follows from badxxf)(badxxfbXaPSBXP)()()(1 badxxfdxxf)()()(bXaP )()(aFbF (iii)If we let B=a,b thenThis follows from)()(xfxF(iv)xaxfduufdxd)()(This follows from46xo)(xf11Sa b xduuf)()()(xfxF(iv)xaxFduufdxd)()(This follows fromNotes(a)If X
44、 is continuous then F(x)is continuous.Also,(b)P(aXb)represents thebetween x=a and x=b.area under the graph of f f(x)=F(x)at all point where F is continuous.47xxFxxFx )()(lim0 xxxXxPx )(lim0)()()()(xXxPxFxxFxxf f(x)=F(x)(c)The meaning of density function:xxx ,i.e.The probability that X is in a small
45、intervalis approximately equal to f(x)times the width of theinterval(d)For any specified value of X,say x0,we have.(b)P(aXb)represents thebetween x=a and x=b.area under the graph of f 48)0()()(000 xFxFxXP0)()()(00000 xxxxdxxfdxxfdxxf xxx ,i.e.The probability that X is in a small intervalis approxima
46、tely equal to f(x)times the width of theinterval(d)For any specified value of X,say x0,we have.Hence,thenif X is continuous then the probabilitiesbXaP bXaP bXaP .bXaP 49),3(XP otherwiesxexfx.00,2)(2 xxRX0:,0 ,)(0 dxxf),1(XP)1/2(XXPExample 2.10 Let X be a continuous r.v.with.pdf FindSolution:0332 xe)
47、1(XP )1()12(XPXXP)1()2(XPXP.1002 eex 022dxex 0)(dxxf 3322dxex)3(XP212 eex 122dxex)1/2(XXP224 eee50 otherwisebxaabxf,0,1)(2.6 Some Continuous Probability DistributionsUniform(or rectangular)DistributionA uniform random variable X on the interval(a,b)hasprobability density function(pdf)We write XU(a,b
48、).xo)(xf a b51 .,1,0)(bxbxaabaxaxxFCdf:xo)(xF a b 152Example 2.11 Suppose that a large conference room for a certain company can be reserved for no more than 4 hours,However,the use of the conference room is such thatNormal DistributionThe pdf of a Normal random variable,X,with0 andis given byparame
49、tersboth long and short conferences occur quite often.In fact,it can be assumed that length X of a conference has a uniform distribution on the interval 0,4.(a)What is the probability density function?(b)What is the probability that any given conferencelasts at least 3 hours?53),(2 NX 221exp21)(xxfN
50、ormal DistributionThe pdf of a Normal random variable,X,with0 andis given byparametersWe write54Geometric Characteristics of the density for Normal Distribution;over lsymmetrica is Curve)1(x;21 of valuemaximum the takes)(,when)2(xfx;0)(,As)3(xfxoccurs;point inflection,At)4(x55only.axis-x thealong sh