Sie sind auf Seite 1von 26

Probability and statistics

Chapter 2 Discrete random variable


and probability Distributions
Example :Consider the experiment of tossing a coin once.
The sample space is S={H, T}.
⎧ 0, e = T ,
X = X (e ) = ⎨
⎩ 1, e = H.
Such a rule of association is called a random variable
1) It is variable because different values are possible
2) It is random because the observed value depends on
which of the possible outcomes result.
Probability and statistics

§1. Random variables


1 .Random variables:

Definition: For a given sample space S of some


experiment a random variable is any rule that associates
a number with each outcome in S,denoted by the
abbreviation r.v X,Y,Z,…..

e X(e)
S
R
Probability and statistics
2.Two types of random variables

(1) A discrete variable is an r.v whose possible values either


constitute a finite set or else can be listed in an infinite
sequence in which there is a first element ,a second
element and so on.
(2)A continuous variable is an r.v if its set of possible
values consist of an entire interval on the number line.
Probability and statistics

§2. Probability distribution for discrete r.v


1.Definition: the probability distribution or probability
mass function (pmf) of discrete rv is defined every
number by p(x)=P(X=x) ,if for each outcome x,
(1) p( x ) ≥ 0 ( 2 ) ∑ p( x ) = 1
x

We can also give the pmf in a tabular form:

X x1 x 2 … xn …
pk p1 p2 … pn ...
Probability and statistics
Example 1: Suppose we go to a university bookstore during
the first week of class and observe whether the next person
buying a computer buys a laptop or a desktop model .
⎧1 if the customer purchases a laptop computer
X =⎨
⎩0 if the customer purchases a desktop computer
If 20% of all purchasers during that week select a laptop,
The pmf of X is
?
Probability and statistics

Example 2: A shipment of 8 similar microcomputer to


A retail outlet contains 3 that are defective. If a school
makes a random purchase of 2 of these computers,
find the probability mass function for the number of
defectives.
Probability and statistics
2.The Cumulative distribution
1). Definition:The cumulative distribution function (cdf)
of a discrete r.v. X with pmf p(x),x∈R1,is defined for every
number x by F(x)=P{ X≤x }.

Note By the definition ,we can know:


(a):For any number x ,F(x) is the probability that
the observed value of x will be at most x.
(b) P{ x1<X≤x2} =P{X ≤x2}-P{X ≤x1} =F(x2)-F(x1) .
Probability and statistics
Properties of pmf:
(1) a distribution function g(x) is nondecreasing,
∀x2>x1, F(x2)-F(x1)=P{x1<X≤x2} ≥0.

(2) 0≤F(x)≤1, F(-∞)=0, F(+ ∞)=1.

(3)a distribution function g(x) is right-continuous


Probability and statistics
Ex ample 1. The pmf of rv X is .
X -1 2 3
pk 1/4 1/2 1/4

1)What is the cdf of X?


2)Calculate the following probabilities:
P{1<X≤3} =? P{1 ≤ X<3} =?
P{1 ≤ X≤3} =? P{1 < X<3} =?
Probability and statistics

§3. Expected Values of Discrete Random variables


Example : We consider a university having 15000 students
and let X be the number of courses for which a randomly
selected student is registered .The pmf of the X follows:
X 1 2 3 4 5 6 7
P(x) 0.01 0.03 0.13 0.25 0.39 0.17 0.02
Number 150 450 1950 3750 5850 2550 300
Please calculate the average number of courses per student
registered.
Probability and statistics
1.The expected value of X
(1)Definition: Let X be a discrete rv with set of possible
values D and pmf p(x) .The expected value or mean
value of X , denoted by E(X) is
E( X ) = ∑ x ⋅ p( x )
x∈ D
Probability and statistics

Example 1: Suppose X be the number of children born


Up to and including the first boy.
(1) Find the pmf of X.
(2) What is the expected value of X?
k
Example 2 : Let X have pmf : p( x ) = 2 , x = 1,2, L
x
What is the exp ected value of X ?
Probability and statistics
(2).Rules of Expected Value:

(a) E(c)=c; (where c is a constant)


(b) E(cX)=cE(X);
(c) E(X+Y)=E(X)+E(Y);
Probability and statistics
(3).The expected value of function
Proposition: If the rv X has possible values D and pmf
p(x),then the expected value of any function h(x),
denoted by E[h(X)] is computed by

E[h( X )] = ∑ h( x ) ⋅ p( x )
x∈ D

Example 1: Let X have pmf X 0 1 2


And Y=2X+1 P(x) 0.3 0.5 0.2

Then what is the expected value of Y?


Probability and statistics
2.The Variance of X
(1) Definition : Let X have pmf p( x ) and exp ected
value EX , then the var iance of X , denoted by V ( X )
or σ X2 or just σ 2 , is : V ( X ) = E[ X − EX ]2

(2)A shortcut formula for σ 2


Remember!
V ( X ) = E ( X 2 ) − ( EX ) 2
Probability and statistics
(3). Rules for variance:
10 ∀ r .v . X , V ( X ) ≥ 0
20 If C is a constant ,then V(C)=0;
30 V(CX)=C2V(X);
Probability and statistics

§2 Several Important discrete random variables


I. Bernoulli random variable
Definition: Any random variable whose only
possible values are 0 and 1 is called a Bernoulli
random variable.
⎧1 if event A occurs
X =⎨
⎩0 if event A doesn' t occurs
Then X has pmf: X 0 1
p(x) 1-p p
or P ( X = x ) = p x (1 − p )1− x , for x = 0, 1
Probability and statistics

E(X)= p V(X)= P(1-P)


The cdf of rv X is F(x)=
Probability and statistics
II. The binomial probability distribution
There are many experiments that conform either exactly
or approximately to the following list of requirements:
(1) The experiment consists of a sequence of n trials,
where n is fixed in advance of the experiment.
(2) The trials are identical and each trial can result
in one of the same two possible outcomes, which
we denote by success(S) or failure(F).
(3) The trials are independent, so that the outcome in any
particular trial does not influence the outcome on any
other trial.
(4) The probability of success is constant from
trial to trial; We denote this probability by p.
Probability and statistics

Definition: An experiment for which conditions (1)~(4)


are satisfied is called a binomial experiment.
Notation: Because the pmf of a binomial rvX depends on
the two parameters n and p, we denote the pmf by b(x,n,p).

To gain insight into 公式 for a general n, consider the case


that n=4 for which each outcome, its probability and
corresponding x value are listed in Table (1).
Probability and statistics
2. Using binomial tables.
Even for a relatively small value of n, the computation
of binomial probability can be tedious.
Probability and statistics
Example 1. Suppose that 20% of all copies of a
particular textbook fail a certain binding strength test.
Let X denote the number among15 randomly selected
copies that fail the test. Then X has a binomial
distribution with n = 15, and p = 0.2, .
(1)What is the probability that at most 8 fail the test?
(2)What is the probability that exactly 8 fail the test?
(3)What is the probability that at least 8 fail the test?
(4)What is the probability that between 4 and 7,
inclusive, fail the test?
Probability and statistics

III. Hypergeometric distribution


The hypergeometric is closely related to the binomial
distribution. Whereas the binomial distribution is the
approximate probability model for sampling without
replacement from a finite dichotomous (S-F) population,
the hypergeometric distribution is the exact probability
model for the number of S’s in the sample.
Probability and statistics
The assumptions leading to the hypergeometric
distribution are as follows:
1. The population or set to be sampled consists of N
individuals, objects or elements (a finite population).
2.Each individual can be characterized as a success(S) or
failure(F) and there are M successes in the population.
3.A sample of n individuals is selected without
replacement in such away that each subset of size n is
equally likely to be chosen.

The rv X= the number of S’s in the sample.


Probability and statistics

Example: Suppose a box contains N components, where


M is defective and the others are nondefective.
Now, n components are drawn from the box, what is
the probability that x out of those selected are defective
Under the following conditions:
(1) With replacement;
(2) Without replacement.
Probability and statistics
Ⅳ.The Poisson Probability Distribution
1.Definition:A rv X is said to have a Poisson Distribution
if the pmf of X is
λxe − x
P{ X = x} = , x = 0, 1, 2, ... , λ > 0
x!

Das könnte Ihnen auch gefallen