Documente Academic
Documente Profesional
Documente Cultură
for
P ro ba bility a nd S ta tistic s
AAOC ZC1 1 1
Course Developed by
M.S.Radhakrishnan
Contents
Page No.
INTRODUCTION, SAMPLE SPACES & EVENTS
Probability
Events
AXIOMS OF PROBABILITY
Finite Sample Space (in which all outcomes are equally likely)
CONDITIONAL PROBABILITY
11
Independent events
11
14
BAYES THEOREM
16
22
RANDOM VARIABLES
26
27
Binomial Distribution
28
29
31
31
32
34
36
37
Digression
37
Chebychevs theorem
39
41
Poisson Distribution
42
42
43
Poisson Process
43
46
Multinomial Distribution
52
Simulation
54
56
57
Normal Distribution
64
69
70
71
71
Gamma Function
73
74
74
Exponential Distribution
74
Beta Distribution
78
79
83
Conditional Distribution
86
Independence
87
88
90
Independence
91
93
Properties of Expectation
100
Sample Mean
101
Sample Variance
102
SAMPLING DISTRIBUTION
115
Statistical Inference
115
Statistics
116
117
128
Point Estimation
128
Estimation of n
130
143
Large Samples
143
148
Notation
149
164
Regression
164
Correlation
167
167
S=
(6,1) , (6,6)
If however, we are interested only in the sum of the two numbers on the top, the
sample space could be S = { 2, 3, , 12}.
Example 3:
Let E be the random experiment:
Count the number of machines produced by a factory until a defective machine is
produced. A sample space for this experiment could be S = {1, 2, 3, }.
1
Example 4:
Let E be the random experiment:
Count the life length of a bulb produced by a factory.
Here S will be {t | t 0} = [0, ).
Events
An event is a subset of the sample space.
Example 5:
Suppose a balanced die is rolled and we observe the number on the top. Let A be the
event: an even number occurs.
Thus in symbols,
A = {2,4,6} S = {1,2,3,4,5,6}
Two events are said to be mutually exclusive if they cannot occur together; that is there
is no element common between them.
In the above example if B is the event: an odd number occurs, i.e. B = {1,3,5} , then A and
B are mutually exclusive.
Solved Examples
Example 1:
A manufacturer of small motors is concerned with three major types of defects. If A is
the event that the shaft size is too large, B is the event that the windings are improper and
C is the event that the electrical connections are unsatisfactory, express in words what
events are represented by the following regions of the Venn diagram given below:
(a) region 2 (b) regions 1 and 3 together (c) regions 3, 5, 6 and 8 together.
4
C
2
1
6
8
Solution:
(a) Since this region is contained in A and B but not in C, it represents the event that
the shaft is too large and the windings improper but the electrical connections are
satisfactory.
(b) Since this region is common to B and C, it represents the event that the windings
are improper and the electrical connections are unsatisfactory. (c) Since this is the
entire region outside A, it represents the event that the shaft size is not too large.
Example 2:
A carton of 12 rechargeable batteries contain one that is defective. In how many ways can
the inspector choose three of the batteries and
(a) get the one that is defective
(b) not get the one that is defective.
Solution:
(a) one defective can be chosen in one way and two good ones can be chosen in
11
= 55 ways. Hence one defective and two good can be chosen in 1 x 55 = 55
2
ways.
(b) Three good ones can be chosen in
11
3
3
= 165 ways
AXIOMS OF PROBABILITY
Let E be a random experiment. Suppose to each event A, we associate a real number
P(A) satisfying the following axioms:
0 P ( A) 1
(i)
(ii)
P (S ) = 1
(iii)
(iv)
two
mutually
exclusive
events,
then
P( ) = 0
Proof: S= S .. Now S and are disjoint.
Hence P ( S ) = P ( S ) + P ( )
2.
P ( ) = 0.
Q.E.D.
P ( A1 A2 ... An ) =
n
i =1
P ( Ai ) .
Proof: By induction on n.
Def.: If A is an event
A the complementary event = S-A (It is the shaded portion in the figure below)
A
4
3.
P ( A) = 1 P ( A)
Proof: S = A A
Now P ( S ) = P ( A) + P ( A) as A and A are disjoint or 1 = P ( A) + P ( A) .
Thus P ( A) = 1 P ( A) . Q.E.D.
4.
5.
Probability is a
subtractive set function; i.e.
If A B , then
P ( B A) = P ( B ) P ( A) .
B
A
6.
Proof:
( A B) ) = A ( A B )
where A and A B are disjoint
Hence P( A B ) = P( A) + P( A B )
A B
But B = ( A B ) ( A B ),
P( A B ) = P( A) + P ( B) P( A B ) . Q.E.D.
7.
Proof:
P(A B C) = P(A B) + P(C) P((A B) C )
n
i =1
P( A I )
P(A i A j ) +
i 1< j n
P(A i A j A k ) ...
1 i < j k < n
+ (1) n 1 P(A1 A 2 A n )
Finite Sample Space (in which all outcomes are equally likely)
Let E be a random experiment having only a finite number of outcomes.
Let all the (finite no. of) outcomes be equally likely.
If S = {a1 , a 2 ,..., a n } ( a1 , a 2 ,..., a n are equally likely outcomes), S = {a 1 } {a 2 }.......{a n }.a
union of m.e. events.
Hence P ( S ) = P ({a1 }) + P{a 2 } P ({a n })
But P({a1})=P({a2})= = P({an}) = p (say)
Hence 1 = p+ p+ . . . +p (n terms) or p = 1/n
Hence if A is a subset consisting of k of these outcomes,
A ={a1, a2ak}, then P ( A) =
Example 1:
If a card is drawn from a well-shuffled pack of 52 cards find the probability of drawing
2
(a)
a red king
Ans:
52
16
(b)
a 3, 4, 5 or 6
Ans:
52
1
(c)
a black card
Ans:
2
4
(d)
a red ace or a black queen
Ans:
52
Example 2:
When a pair of balanced die is thrown, find probability of getting a sum equal to
(a)
7.
Ans:
6 1
= (Total number of equally likely outcomes is
36 6
36 & the favourable number of outcomes = 6, namely
(1,6), (2,5),, (6,1).)
(b)
11
Ans:
2
36
(c)
7 or 11
Ans:
8
36
(d)
2, 3 or 12
Ans: =
1
2
1
4
+
+
=
.
36 36 36 36
Example 3:
10 persons in a room are wearing badges marked 1 through 10. 3 persons are chosen at
random and asked to leave the room simultaneously and their badge nos are noted. Find
the probability that
(a) the smallest badge number is 5.
(b) the largest badge number is 5.
7
Solution:
3 persons can be chosen in 10C3 equally likely ways. If the smallest badge
number is to be 5, the badge numbers should be 5 and any two of the 5
numbers 6, 7, 8, 9,10. Now 2 numbers out of 5 can be chosen in 5C2 ways.
Hence the probability that the smallest badge number is 5 is 5C2 /10C3 .
(b) Ans. 4C2 /10C3 .
(a)
Example 4:
A lot consists of 10 good articles, 4 articles with minor defects and 2 with major defects.
Two articles are chosen at random. Find the probability that
10
Ans:
16
16
C2
C2
C2
C2
6c1
16c 2
Ans:
10c1 . 6c1
16c 2
6c 2 10c1 . 6c1
+
16c 2
16c 2
(f) Neither has major defects Ans:
14c 2
16c 2
6c 2
16c 2
Ans:
Example 5:
From 6 positive and 8 negative integers, 4 integers are chosen at random and multiplied.
Find the probability that their product is positive.
Solution:
The product is positive if all the 4 integers are positive or all of them are negative or two
of them are positive and the other two are negative. Hence the probability is
6
6 8
4
2 2
4
+
+
14
14
14
4
Example 6:
If, A, B are mutually exclusive events and if P(A) = 0.29, P(B) = 0.43, then
(a) P(A ) = 1 0.29 = 0.71
(b) P(AB) = 0.29 + 0.43 = 0.72
(c) P ( A B ) = P(A) = 0.29 [ (as A is a subset of B , since A and B are m.e.)
(d) P(A B) = 1 P(A B) = 1 0.72 = 0.28
Example 7:
P(A) = 0.35, P(B) = 0.73, P (A B) = 0.14 . Find
(a) P (A B) = P(A) + P(B) - P( A B) = 0.94.
(b) P (A B) = P(B) P(A B) = 0.59
(c) P (A B) = P(A) P(A B) = 0.21
(d) P(A B) = 1 P(A B) = 1 0.14 = 0.86
Example 8:
A, B, C are 3 mutually exclusive events. Is this assignment of probabilities possible?
P(A) = 0.3, P(B) = 0.4, P(C) = 0.5
9
Ans.
NOT POSSIBLE
Example 9:
Three newspapers are published in a city. A recent survey of readers indicated the
following:
20% read A
16% read B
14% read C
8% read A and B
5% read A and C
4% read B and C
2% read all
20 + 16 + 14 + 8 5 4 + 2
= 0.65
100
B
9
9+6+7
= 0.22
100
6
3 2
6
2
C
(c) reads at least A and B given he reads at least one of the papers.
P (At least reading A and B given he reads at least one of the papers)
=
P(A B)
8
=
P(A B C) 35
10
CONDITIONAL PROBABILITY
Let, A, B be two events. Suppose P(B) 0. The conditional probability of A occurring
given that B has occurred is defined as
P(A | B) = probability of A given B =
P(A B)
.
P(B)
P(A B)
if P(A) 0.
P(A)
Example 10
A bag contains 4 red balls and 6 black balls. 2 balls are chosen at random one by one
without replacement. Find the probability that both are red.
Solution
Let A be the event that the first ball drawn is red, B the event the second ball drawn is
red. Hence the probability that both balls drawn are red =
4 3 2
P(A B) = P(A) P(B | A) = =
10 9 15
Independent events:
Definition: We say two events A, B are independent if P(A B) = P(A). P(B)
Equivalently A and B are independent if P(B | A) = P(B) or P(A | B) = P(A)
Theorem If, A, B are independent, then
(a) A , B are independent
(b) A, B are independent
(c) A , B are independent
11
Proof B = (A B) (A B)
AB
A B
Mutually
exclusive
P(B) = P(A B) + P(A B)
P(A B) = P(B) - P(A B)
= P(B) P(A) (P/B)
= P(B) [1-P(A)]
= P(B) P( A )
A, B are also independent.
By the same reasoning, A and B are independent.
So again A and B are independent.
Example 11
Find the probability of getting 8 heads in a row in 8 tosses of a fair coin.
Solution
If Ai is the event of getting a head in the ith toss, A1, A2, , A8 are independent and
1
P(Ai) = for all i. Hence P(getting all heads) =
2
P(A1) P(A2)P(An) =
1
2
Example 12
It is found that in manufacturing a certain article, defects of one type occur with
probability 0.1 and defects of other type occur with probability 0.05. Assume
independence between the two types of defects. Find the probability that an article chosen
at random has exactly one type of defect given that it is defective.
12
Let A be the event that article has exactly one type of defect.
Let B be the event that the article is defective.
Required P(A | B) =
P(A B)
P(B)
0.14
0.145
[Note: If A and B are two events, probability that exactly only one of them occurs
is P(A) + P(B) 2P(A B)]
Example 13
An electronic system has 2 subsystems A and B. It is known that
P (A fails) = 0.2
P (B fails alone) = 0.15
P (A and B fail) = 0.15
Find (a) P (A fails | B has failed)
(b) P (A fails alone)
13
Solution
P(A and B failed) 0.15 1
=
=
P(B failed)
0.30 2
(a)
(b)
Example 14
A binary number is a number having digits 0 and 1. Suppose a binary number is made up
of n digits. Suppose the probability of forming an incorrect binary digit is p. Assume
independence between errors. What is the probability of forming an incorrect binary
number?
1- P (forming a correct no.) = 1 (1-p)n .
Ans
Example 15
A question paper consists of 5 Multiple choice questions each of which has 4 choices (of
which only one is correct). If a student answers all the five questions randomly, find the
probability that he answers all questions correctly.
1
4
Ans
n
i=1
P(Bi ) P(A | Bi )
Example 16
There are 2 urns. The first one has 4 red balls and 6 black balls. The second has 5 red
balls and 4 black balls. A ball is chosen at random from the 1st and put in the 2nd. Now a
ball is drawn at random from the 2nd urn. Find the probability it is red.
14
Solution:
Let B1 be the event that the first ball drawn is red and B2 be the event that the first ball
drawn is black. Let A be the event that the second ball drawn is red. By the theorem on
total probability,
4 6
6 5
54
+ =
=0.54.
P(A) = P(B1) P(A | B1) + P(B2) P(A | B2) =
10 10 10 10 100
Example 17:
A consulting firm rents cars from three agencies D, E, F. 20% of the cars are rented from
D, 20% from E and the remaining 60% from F. If 10% of cars rented from D, 12% of
cars rented from E, 4% of cars rented from F have bad tires, find the probability that a
car rented from the consulting firm will have bad tires.
Ans.
Example 18:
A bolt factory has three divisions B1, B2, B3 that manufacture bolts. 25% of output is
from B1, 35% from B2 and 40% from B3. 5% of the bolts manufactured by B1 are
defective, 4% of the bolts manufactured by B2 are defective and 2% of the bolts
manufactured by B3 are defective. Find the probability that a bolt chosen at random from
the factory is defective.
Ans.
25
5
35
4
40
2
15
BAYES THEOREM
Let B1, B2, .Bn be n mutually exclusive events of which one of them must occur.
If A is any event, then
P(B k | A) =
P(A B k )
P(B )P(A | B k )
= n k
P(A)
P(B i )P(A | B i )
i =1
Example 19
Miss X is fond of seeing films. The probability that she sees a film on the day before
the test is 0.7. Miss X is any way good at studies. The probability that she maxes the test
is 0.3 if she sees the film on the day before the test and the corresponding probability is
0.8 if she does not see the film. If Miss X maxed the test, find the probability that she
saw the film on the day before the test.
Solution
Let B1 be the event that Miss X saw the film before the test and let B2 be the
complementary event. Let A be the event that she maxed the test.
Required. P(B1 | A)
P(B1 )P(A | B1 )
P(B1 ) P(A | B1 ) + P(B) P(A | B 2 )
0 .7 0 .3
0 . 7 0 . 3 + 0 . 3 0 .8
Example 20
At an electronics firm, it is known from past experience that the probability a new worker
who attended the companys training program meets the production quota is 0.86. The
corresponding probability for a new worker who did not attend the training program is
0.35. It is also known that 80% of all new workers attend the companys training
16
program. Find probability that a new worker who met the production quota would have
attended the companys training programme.
Solution
Let B1 be the event that a new worker attended the companys training programme. Let
B2 be the complementary event, namely a new worker did not attend the training
programme. Let A be the event that a new worker met the production quota. Then we
0 .8 0 .8
want P(B1 | A) =
.
0.8 0.86 + 0.2 0.35
Example 21
A printing machine can print any one of n letters L1, L2,.Ln. It is operated by
electrical impulses, each letter being produced by a different impulse. Assume that there
is a constant probability p that any impulse prints the letter it is meant to print. Also
assume independence. One of the impulses is chosen at random and fed into the machine
twice. Both times, the letter L1 was printed. Find the probability that the impulse chosen
was meant to print the letter L1.
Solution:
Let B1 be the event that the impulse chosen was meant to print the letter L1. Let B2 be the
complementary event. Let A be the event that both the times the letter L1 was printed.
1
P(B1) = . P(A|B1) = p2. Now the probability that an impulse prints a wrong letter is (1n
1 p
p). Since there are n-1 ways of printing a wrong letter, P(A|B2) =
. Hence P(B1|A)
n 1
P(B1 ) P(A | B1 )
=
P(B1 ) P(A | B1 ) + P(B 2 ) P(A | B 2 )
1 2
p
n
1 2
1
p + 1
n
n
1 p
n 1
17
Miscellaneous problems
1 (a). Suppose the digits 1,2,3 are written in a random order. Find probability that at
least one digit occupies its proper place.
Solution
There are 3! = 6 ways of arranging 3 digits (See the figure), out of which in 4
arrangements , at least one digit occupies its proper place. Hence the probability is
4 4
= .
123
213
312
3! 6
132
231
321
(Remark. An arrangement like 231, where no digit occupies its proper place is
called a derangement.)
(b)
Solution
Ans.
15
(Try proving this.)
24
3!
2!
1!
0!
4c 2 + 4c 3 4c 4
4!
4!
4!
4!
18
= 1
(c)
1 1 1
+
2 6 24
24 12 + 4 1 15
=
24
24
Solution
2.
Ans
3.
1 1 1
1
+ ..........(1) n 1
1 e ! (for n large).
2! 3! 4!
n!
1-( 1
1 1 1
1
+ ..........(1) n 1 ).
2! 3! 4!
n!
A and B play the following game. They throw alternatively a pair of dice.
Whosoever gets sum of the two numbers on the top as seven wins the game
and the game stops. Suppose A starts the game. Find the probability (a) A
wins the game (b) B wins the game.
19
Solution
A wins the game if he gets seven in the 1st throw or in the 3rd throw or in the
1 5 5 1 5 5 5 5 1
5th throw or . Hence P(A wins) = + + +
6 6 6 6 6 6 6 6 6
1
6
=
5
1
6
4.
1
6
5
6
=
= . P(B wins) = complementary probability = .
36 25 11
11
36
Birthday Problem
There are n persons in a room. Assume that nobody is born on 29th Feb.
Assume that any one birthday is as likely as any other birth day. Find the
probability that no two persons will have same birthday.
Solution
If n > 365, at least two will have the same birthday and hence the probability
that no two will have the same birthday is 0.
If n 365, the desired probability is =
5.
6!
66
20
6.
g
g+r
(b) Find the probability that the 2nd ball drawn is green.
Ans.
g
g+c
r
g
g
+
=
g +r g +r+c g +r g+r+c g+r
(c) Find the probability that the nth ball drawn is green.
The surprising answer is
7.
g
.
g+r
There are n urns and each urn contains a white and b red balls. A ball is
chosen from Urn 1 and put into Urn 2. Now a ball is chosen at random from
urn 2 and put into urn 3 and this is continued. Finally a ball drawn from Urn n.
Find the probability that it is white.
Solution
Let pr = Probability that the ball drawn from Urn r is white.
p r = p r 1
a +1
a
+ (1 p r 1 )
; r = 1, 2, , n.
a + b +1
a + a +1
21
a
, we can find pn.
a+b
Definition
Let E be a random experiment with n outcomes a1, a2 .an. Suppose P({a1})=p1,
P({a2})=p2, , P({an})=pn. Then we define the mathematical expectation as
a 1 p1 + a 2 p 2 ......... + a n p n
22
Problems
1.
If a service club sells 4000 raffle tickets for a cash prize of $800, what is the
mathematical expectation of a person who buys one of these tickets?
Solution.
2.
5000
1
1
+ 100
+ 0 ( )
2000
2000
A game between 2 players is called fair if each player has the same mathematical
expectation. If some one gives us $5 whenever we roll a 1 or a 2 with a balanced
die, what we must pay him when we roll a 3, 4, 5 or 6 to make the game fair?
Solution.
4.
1
1
+ 0 ( ) = = 0 .2
4000
5
A charitable organization raises funds by selling 2000 raffle tickets for a 1st prize
worth $5000 and a second prize $100. What is mathematical expectation of a
person who buys one of the tickets?
Solution.
3.
800
Gamblers Ruin
A and B are betting on repeated flips of a balanced coin. At the beginning, A has
m dollars and B has n dollars. After each flip the loser pays the winner 1 dollar
and the game stops when one of them is ruined. Find probability that A will win
Bs n dollars before he loses his m dollars.
Solution.
Let p be the probability that A wins (so that 1-p is the probability that B wins).
Since the game is fair, As math exp = Bs math exp.
Thus n p + 0 (1 p ) = m(1 p) + 0.p or p =
23
m
m+n
5.
Solution.
Expected profit
= 40,000 0.32 + 30,000 0.55 + 10,000 0.13
=$30,600
6.
The manufacturer of a new battery additive has to decide whether to sell her
product for $80 a can and for $1.2 a can with a double your money back if not
satisfied guarantee. How does she feel about the chances that a person will ask
for double his/her money back if
(a) she decides to sell the product for $0.80
(b) she decides to sell the product for $1.20
(c) she can not make up her mind?
Solution.
24
7.
A manufacturer buys an item for $1.20 and sells it for $4.50. The probabilities for
a demand of 0, 1, 2, 3, 4, 5 or more items are 0.05, 0.15, 0.30, 0.25, 0.15, 0.10
respectively. How many items he must stock to maximize his expected profit?
0
1
Exp. profit
0
1
0.05
0.95
0
1
2
0.05
0.15
0.80
0
1
2
3
0.05
0.15
0.30
0.50
0
0 0.05 + 4.5
0.95 2.1
= 2.175
0 0.05 + 4.5 0.15
+ 9 0.80 4.2
= 3.675
0 0.05 + 4.5 0.15
+ 9 0.30 + 13.5
0.15 6.3
=
2.85
0.525
0.45
A contractor has to choose between 2 jobs. The 1st job promises a profit of
$240,000 with probability 0.75 and a loss of $60,000 with probability 0.25. The
2nd job promises a profit of $360,000 with probability 0.5 and a loss of $90,000
with probability 0.5.
(a)
Which job should the contractor choose to maximize his expected profit?
3
1
i. Exp. profit for job1 = 240,000 60,000 = 155,000
4
4
1
1
ii. Exp. profit for job2 = 36,000 90,000 = 135,000
2
2
Go in for job1.
(b)
What job would the contractor probably choose if her business is in bad
shape and she goes broke unless, she makes a profit of $300,000 on her
next job.
Ans:- She takes the job2 as it gives her higher profit.
25
RANDOM VARIABLES
Let E be a random experiment. A random variable (r.v) X is a function that associates to
each outcome s, a unique real number X (s).
Example 1
Let E be the random experiment of tossing a fair coin 3 times. We see that there are
2 3 = 8 outcomes TTT, HTT, THT, TTH, HHT, HTH, THH, HHH all of which are
equally likely. Let X be the random variable that counts the number of heads obtained.
Thus
X
can
take
only
4
values
0,1,2,3.
We
note
that
1
3
3
1
P ( X = 0 ) = , P ( X = 1) = , P ( X = 2 ) = , P ( X = 3) = . This is called the
8
8
8
8
probability distribution of the rv X. Thus the probability distribution of a rv X is the
listing of the probabilities with which X takes all its values.
Example 2
Let E be the random experiment of rolling a pair of balanced die. There are 36 possible
equally likely outcomes, namely (1,1), (1,2) (6,6). Let X be the rv that gives the sum
of the two nos on the top. Hence X take 11 values namely 2,312. We note that the
probability distribution of X is
1
2
P(X = 2 ) = P(X = 12 ) = , P(X = 3) = P(X = 11) =
,
36
36
3
P(X = 4 ) = P(X = 10 ) = ,
36
4
P(X = 5) = P(X = 9 ) =
.
36
5
6 1
P(X = 6 ) = P(X = 8) = , P(X = 7 ) =
= .
36
36 6
Example 3
Let E be the random experiment of rolling a die till a 6 appears on the top. Let X be the
no of rolls needed to get the first six. Thus X can take values 1,2,3 Here X takes
an infinite number of values. So it is not possible to list all the probabilities with which X
takes its values. But we can give a formula.
26
P( X = x ) =
5
6
x 1
1
6
(x = 1,2.....)
(Justification: X = x means the first (x-1) rolls gave a number (other than 6) and
5 5
5 1 5
the xth roll gave the first 6. Hence P ( X = x ) = ... =
6 6
6 6 6
x 1
1
6
x 1 times
(ii)
i
The first condition follows from the fact that the probability is always 0. The second
condition follows from the fact that the probability of the certain event = 1.
27
Example 4
Determine whether the following can be the probability distribution of a rv which can
take only 4 values 1,2,3 and 4.
(a)
(b)
(c)
Binomial Distribution
Let E be a random experiment having only 2 outcomes, say success and failure.
Suppose that P(success) = p and so P(failure) = q (=1-p). Consider n independent
repetitions of E (This means the outcome in any one repetition is not dependent upon the
outcome in any other repetition). We also make the important assumption that P(success)
= p remains the same for all such independent repetitions of E. Let X be the rv that
counts the number of successes obtained in n such independent repetitions of E. Clearly
X is a discrete rv that can take n+1 values namely 0,1,2,.n. We note that there are
2 n outcomes each of which is a string of n letters each of which is an S or F (if n =3, it
will be FFF, SFF, FSF, FFS, SSF, SFS, FSS, SSS).
X = x means in any such outcome there are
x successes and (n-x) failures in some order. One such will be SSS ..S FFF ..F . Since all
x
n x
the repetitions are independent prob of this outcome will be p x q n x . Exactly the same
prob would be associated with any other outcome for which X = x. But x successes can
n
occur out of n repetitions in
mutually exclusive ways. Hence
x
P(X = x ) =
n
x
p x q n x (x = 0,1, ...n ).
28
The independent repetitions are usually referred to as the Bernoulli trials. We note that
b(x; n, p ) = b(n x; n, q )
(LHS = Prob of getting x successes in n Bernoulli trials = prob of getting n-x failures in
n Bernoulli trials = R.H.S.)
x
k =0
b(k; n , p )
Solution
Among 15 chips, let X be the number of chips that will have thick enough coatings.
Hence X is a rv having Binomial distribution with parameters n =15 and p = 0.70.
(a) P(X 12) = 1 P(X 11)
= 1 B (11;15,0.70 )
= 1 0.7031 = 0.3969
(b) 10%
Solution:
Let X be the number of jars that contain less coffee (than printed on the label) (among the
16 jars randomly chosen. Thus X is a random variable having a Binomial distribution
30
with parameters n = 16 and p (the prob of success = The prob that a jar chosen at
random will have less coffee)
(a) Here p = 5% = 0.05
Hence P (claim is accepted) = P(X 2) = B(2;16,0.05) = 0.9571.
(b) Here p = 10% = 0.10
Hence P (claim is accepted) = B(2;16,0.01) = 0.7892
(c) Here p = 15% = 0.15.
Hence P (claim is accepted) = B (2;16,0.15) = 0.5614
(d) Here p = 20% = 0.20
Hence P(claims accepted) = B(2,16,0.29) = 0.3518
4
(remember
10
4
10
4
10
P ( X = x0 ) is the greatest. From the binomial tables given in the book we can easily see
that
31
When n = 10, p =
1
, P ( X = 5) is the greatest or 5 is the mod e.
2
Fact
b( x + 1; n, p ) n x
p
=
<1if n > n p (1 p )
Thus so long as x <np (1-p) the binomial probabilities increase and if x> np-(1-p) they
decrease. Hence if np-(1-p) = x0 is an integer, then the mode is x0 and x0 + 1. If n (1-p)
6
5 x
x = 0,1,2,3,4.
10
5
32
P( X = a ) =
N a
nx
x = 0,1,2.... n
N
n
(Note x must be less than or equal to a and n-x must be less than or equal to N-a)
We say the rv X has a hypergeometric distribution with parameters n,a and N. We denote
P(X=x) by h (x;n,a,N).
Ans
h (3; 4, 9,12 ) =
3 1
12
4
Ans
h(1; 4, 6, 18) =
4
18
4
(b) One of the new buildings that violate the building code
33
Ans
h(1; 4, 6,18) =
12
3
18
4
(c) Two of the new buildings that violate the building code
Ans
h(2; 4, 6, 18) =
12
2
18
4
(d) At least three of the new buildings that violate the building code
Ans
a
= " prob of a success" ) . Hence if N is large the hypergeometric
N
h (x; n, a , N ) can be approximated by the binomial probability
b(x; n, p ) where p =
a
.
N
Solution
Here N = 120 (Large!) a = 5 n = 3 x =1
(a) Reqd prob = h(1; 3, 5,120)
5
=
115
2
120
5 6555
= 0.1167
280840
3
(b) h(1; 3, 5, 120 ) b 1; 3,
3
=
1
5
120
5
120
5
1
120
= 0.1148
Solution
Here N = 300, a = 240, n = 8 x = 5
(a) h (5; 8, 240, 300)
(b) b 5; 8,
240
300
35
f (x 1 ), f (x 2 )...., its
mathematical
x1 f ( x1 ) + x 2 f ( x 2 ) + ...... =
expectation
xi x P ( x = xi ) =
or
expected
value Pr obability
Example 11
Suppose X is a rv having the probability distribution
X
Prob
1
2
1
3
1
6
=1
1
1
1 5
+ 2 + 3 =
2
3
6 3
Example 12
Let X be the rv having the distribution
X
Prob
36
value
is
where q = 1 p. Thus = 0 q + 1 p = p.
The mean of a Binomial Distribution
Suppose X is a rv having Binomial distribution with parameters n and p. Then
Mean of X = = np.
(Read the proof on pages 107-108 of your text book)
The mean of a hypergeometric Distribution
If X is a rv having hypergeometric distribution with parameters N , n, a, then = n
a
.
N
Digression
The mean of a rv x give the average of the values taken by the rv. X. Thus the
average marks in a test is 40 means the students would have got marks less than 40
and greater than 40 but it averages out to be 40. But we do not get an idea about the
spread ( deviation from the mean) of the marks. This spread is measured by the
variance. Informally speaking by the average of the squares of deviation from the
mean.
Variance of a Probability Distribution of X is defined as the expected value of
(X )2
Variance of X = 2
=
(x i )2 P(X = x i )
xi R X
Note that R.H.S is always 0 (as it is the sum of non-ve numbers)
The positive square root of 2 is called the standard deviation of X and has the
same units as X and .
37
Example 13
For the rv X having the prob distribution given in example 11, the variance is
5
1
3
=
1
5
+ 2
2
3
1
5
+ 3
3
3
1
6
4 1 1 1 16 1 5
x + + =
9 2 9 3 9 6 9
( )
2 = E (X ) = E X 2 2
2
( )
1
1
1 1 4 9 60 10
+ 2 2 + 32 = + + = =
2
3
6 2 3 6 18 3
10
25
5
2 =
= .
3
9 9
Here E X 2 = 12
Example 14
For the probability distribution of example 12,
( )
E X 2 = o 2 q + 12 p = p
2 = p p 2 = p(1 p ) = pq
Variance of the Binomial Distribution
2 = npq
Variance of the Hypergeometric Distribution
2 =n
a
a N n
1
.
.
N
N N 1
38
CHEBYCHEVS THEOREM
Suppose X is a rv with mean and variance 2 . Chebychevs theorem states that: If k
is a constant > 0,
P(| X | k )
1
k2
In words the prob of getting a value which deviates from its mean by at least k is at
1
.
k2
Note: Chebyshevs Theorem gives us an upper bound of the prob of an event. Mostly it is
of theoretical interest.
most
2 = n p q = 405
15
2
Let X = no of cases out of 405 that do not meet puncture standards
Reqd P(X 30 or X 105)
=
Now X 30
X 105
75
2
75
2
Thus X 30 or X 105
| X |
75
= 5
2
39
1 1
= = 0.04
5 2 25
Solution:
Suppose we flip the coin n times and suppose X is the no of tails obtained. Thus the
proportion of tails =
No of tails
X
. We must find n so that
=
n
Total No of flips
X
0.50 0.04 0.01
n
(as p = q = 0.50)
= n p q = n 0.50
Now
X
0.50 0.04 is equivalent to X n 0.50 0.04n.
n
We know P( X k )
1
k2
Here k = 0.04n
k =
0.04n
0.50 n
= 0.08 n
40
X
0.50 0.04
n
= P(| X | k )
1
0.01
k2
1
2
= 100 or if (.08) n 100.
0.01
100
or n
=15625
(.08)2
if k 2
X
p
n
= P( X np n ) = P( x k ) (where k = n )
1
2
npq pq
(
by
Chebyshev
'
s
theorem
)
=
= 2 2 = 2 0 as n .
2
2 2
k
n
n
n
Thus we can say that the prob that the proportion of defective items differs from the
actual prob. p by any + ve no 0 as n . (This is called the Law of Large
numbers)
This means most of the times the proportion of defectives will be close to the actual
X
(unknown) prob p that an item is defective for large n. So we can estimate p by , the
n
(Sample) proportion of defectives.
41
POISSON DISTRIBUTION
A random variable X is said to have a Poisson distribution with parameter > 0 if its
probability distribution is given by
P ( X = x ) = f ( x; ) = e
x
x!
x = 0,1,2......
.
Hence for n large, p small, the binomial prob b( x; n, p ) can be approximated by the
Poisson prob f ( x; ) where = np.
Example 17
b(3;100, 0.03)
f (3;3) =
e 3 3 3
3!
Solution
If X is the number of defectives in a sample of 400, X has the binomial distribution with
parameters n = 400 and p = 0.8% = 0.008.
42
3.2
(3.2)4
4!
= 0.781 0.603
(from table 2 at the end of the text)
= 0.178
x
k =0
P(X = k ) =
x
k =0
f (k; )
For various and x, F(x; ) has been tabulated in table 2 (of your text book on page 581
to 585) .We use the table 2 as follows.
f (x; ) = P(X = x ) = P(X x ) P(X x 1)
= F(x; ) F(x 1; )
Poisson Process
There are many situations in which events occur randomly in regular intervals of time.
For example in a time period t, let X t be the number of accidents at a busy road junction
in New Delhi; X t be the number of calls received at a telephone exchange; X t be the
number of radio active particles emitted by a radioactive source etc. In all such examples
we find X t is a discrete rv which can take non-ve integral values 0,1,2,.. The important
thing to note is that all such random variables have same distribution except that the
parameter(s) depend on time t.
The collection of random variables (X t ) t > 0 is said to constitute a random process. If
the rvs (X t ) which counts the number of occurrences of a random phenomena in a time
43
2.
3.
The prob of a success during any time period does not depend on what
happened prior to that period.
Divide the time period t into n small time periods each of length t . Hence by
assumptions above, we note that Xt = no of successes in time period t is a rv having
Binomial distribution with parameters n and p = t . Hence
P(X t = x ) = b(x; n , t )
f (x;
) as n
where
= n.
Solution
Xt= no of calls in a t-minute interval is a rv having Poisson distribution with parameter
t = 0.6t
(a) P(X1 1) = 1 P(X 1 = 0 ) = 1 e 0.6 = 1 0.549 = 0.451.
Example 20
Suppose that Xt, the number of particles emitted in t hours from a radio active source
has a Poisson distribution with parameter 20t. What is the probability that exactly 5
particles are emitted during a 15 minute period?
Solution
15 minutes =
1
hour
4
P X 14 = 5 = e
14 20
1
20
4
5!
1
hour
4
= e 5
55
5!
45
x 1
p = q x 1 p
(x = 1,2......)
We say X has a geometric distribution with parameter p (as the respective probabilities
form a geometric progression with common ratio q).
We can show the mean of this distribution is
q
1
and the variance is 2 = 2
p
p
(For example suppose a die is rolled till a 6 is got. It is reasonable to expect on an average
1
we will need 1 = 6 rolls as there are 6 nos!)
6
Solution
Here Success means the expert misses the target. Hence p = P(Success ) = 5% = 0.05 . If
X is the rv that counts the no. of shots needed to get a success, we want
P ( X = 15) = q 14 p = (0.95) 0.05.
14
46
Example 22
The probability of a successful rocket launching is 0.8. Launching attempts are made till
a successful launching has occurred. Find the probability that exactly 6 attempts will be
necessary.
Solution
(0.2)5 0.8
Example 23
X has a geometric distribution with parameter p. show
(a)
(b)
P ( X r ) = q r 1
r = 1,2,.........
P(x s + t | x > s ) = P( X t )
Solution
(a)
(b)
P(X r ) =
X > s )=
P ( X s + t ) q s +t 1
=
= q t 1 = P ( X t ).
s
P( X > s )
q
x =r
P(X s + t
q r 1 p
= q r 1 .
1 q
q x 1 .p
There is a service facility. Customers arrive in a random fashion and get service if the
server is idle. Else they stand in a Queue and wait to get service.
Examples of Queuing systems
1. Cars arriving at a petrol pump to get petrol
2. Men arriving at a Barbers shop to get hair cut.
3. Ships arriving at a port to deliver goods.
47
o =1
n = 1
(n = 0, 1, 2, . . .)
Thus L = Mean number of customers in the system getting service and waiting to get
service)
48
n =0
n. n =
n =1
(n 1) n =
=L
( )
L
1
=
Lq
1
=
=W .
( )
49
Solution
Here = arrival rate = 2 per hour
= departure rate = 3 per hour.
Thus
L=
(b)
2
22
4
Lq =
=
=
( ) 3(1) 3
(c)
Wq =
(d)
2
=2
32
(a)
2
= hr
( ) 3
= 0 + 1 = 1
=
(e)
+ 1
2
2 2
= 1 + 1
3
3 3
1 2 5
+ =
3 9 9
Example 25
With reference to example 24, suppose that the cost of keeping a truck in the system is
Rs. 15/hour. If it were possible to increase the mean loading rate to 3.5 trucks per hour at
a cost of Rs. 12 per hour, would this be worth while?
50
Solution
In the old scheme, = 2, = 3, L = 2
Mean cost per hour to the dock = 2 x 15 = 30/hr.
In the new scheme = 2, = 3, L =
4
verify!
3
4
15 + 12 = 32 / hr.
3
51
MULTINOMIAL DISTRIBUTION
Consider a random experiment E and suppose it has k possible outcomes A1 , A2 ,.... Ak .
Suppose P ( Ai ) = pi for all i and that pi remains the same for all independent repetitions
of E. Consider n independent repetitions of E. Suppose A1 occurs X1 times, A2 occurs X2
times, , Ak occurs Xk times. Then P ( X 1 = x1 , X 2 = x 2 ,.... X k = x k )
n!
p1x1 p 2x 2 ..... p kxk
x1 ! x 2 !......x k !
A1 occurs x1 times in
From
the
n
n!
=
ways.
x1
x1 ! (n x1 )!
remaining
n x1 repetitions
A2
can
occur
x2
times
in
n x1
(n x1 )!
=
ways and so on.
x2
x 2 ! (n x1 x 2 )!
Hence the total number of ways of getting A1 x1 times, A2 x 2 times, . Ak x k times will
be
(n x1 x 2 .....x k 1 )!
(n x1 )!
n!
...
x1 ! (n x1 )! x 2 ! (n x1 x 2 )!
x k ! (n x1 x 2 ....x k 1 x k )!
=
n!
as x1 + x 2 + .....x k = n and 0! = 1
x1 ! x 2 !......x k !
Hence P ( X 1 = x1 , X 2 = x 2 ,..... X k = x k ) =
n!
p1x1 p 2x2 .... p kxk
x1 ! x 2 !....x k !
52
Example 26
A die is rolled 30 times. Find the probability of getting 1 2 times, 2 3 times, 3 4 times,
4 6 times, 5 7 times and 6 8 times.
Ans
30!
1
2! 3! 4! 6! 7! 8! 6
1
6
1
6
1
6
1
6
1
6
Solution
12!
(.40)4 (.40)6 (.20)2 .
4! 6! 2!
Remark
1.
Note that the different probabilities are the various terms in the expansion of the
multinomial
( p1 + p 2 + ...... p k )n .
Hence the name multinomial distribution.
2.
3.
53
SIMULATION
Nowadays simulation techniques are being applied to many problems in Science and
Engineering. If the processes being simulated involve an element of chance, these
techniques are referred to as Monte Carlo methods. For example to study the distribution
of number of calls arriving at a telephone exchange, we can use simulation techniques.
Random Numbers : In simulation problems one uses the tables of random numbers to
generate random deviates (values assumed by a random variable). Table of random
numbers consists of many pages on which the digits 0,1,2.. 9 are distributed in such a
1
was that the probability of any one digit appearing is the same, namely 0.1 = .
10
Use of random numbers to generate heads and tails. For example choose the 4th
column of the four page of table 7, start at the top and go down the page. Thus we get
6,2,7,5,5,0,1,8,6,3.. Now we can interpret this as H,H,T, T,T, H, T, H, H,T, because the
prob of getting an odd no. = the propagating an even number = 0.5 Thus we associate
head to the occurrence of an even number and tail to that of an odd no. We can also
associate a head if we get 5,6,7,8, or 9 and tail otherwise. The use can say we got
H,T,H,H,H,T,T,H,H,T.. In problems on simulation we shall adopt the second scheme
as it is easy to use and is easily extendable for more than two outcomes. Suppose for
example, we have an experiment having 4 outcomes with prob. 0.1, 0.2, 0.3 and 0.4
respectively.
Thus to simulate the above experiment, we have to allot one of the 10 digits 0,1.9 to
the first outcome, two of them to the second outcome, three of them to the third outcome
and the remaining four to the fourth outcome. Though this can be done in a variety of
ways, we choose the simplest way as follows:
Associate the first digit 0 to the 1st outcome 01
Associate the next 2 digits 1,2 to the 2nd outcome 0 2
Associate the next 3 digits 3,4,5 to the 3rd outcome 0 3 .
And associate the last 4 digits 6,7,8,9 to the 4th outcome 0 4 .
Hence the above sequence 6,2,7,5,5,0,1,8,6,3 of random numbers would correspond to
the sequence of outcomes O 4 , O 2 , O 4 , O3 , O3 , O1 , O 2 , O 4 , O 4 , O3 ..............
Using two and higher digit Random numbers in Simulation
54
Suppose we have a random experiment with three outcomes with probabilities 0.80, 0.15
and 0.05 respective. How can we now use the table of random numbers to simulate this
experiment? We now read 2 numbers at a time : say (starting from page 593 room 12,
1
column 4) 84,71,14,24,20,31,78, 03.. Since P (anyone digit) =
, P (any two
10
1 1
= 0.01 . Thus each 2 digit random number occurs with prob 0.01.
digits) =
10 10
Now that there will be 100 2 digit random numbers : 00, 01, , 10, 11, , 20, 21, ,
98, 99. Thus we associate the first 80 numbers 00,0179 to the first out come, the next
15 numbers (80, 81, 94) to the second outcome and the last 5 numbers (95, 96, , 99)
to the 3rd outcome. Thus the above sequence of 2 digit random numbers would simulate
the outcomes:
O 2 , O1 , O1 , O1 , O1 , O1 , O1 , O1 .......
We describe the above scheme in a diagram as follows:
*
**
Outcome
Probability
Cumulative Probability*
Random Numbers**
O1
0.80
0.80
00-79
O2
0.15
0.95
80-94
O3
0.05
1.00
95-99
Cumulative prob is got by adding all the probabilities at that position and above thus cumulative
prob at O2 = Prob of O1 + Prob O2 = 0.80 + 0.15 = 0.95.
You observe the beginning random number is 00 for the 1st outcome; and for the remaining
outcomes, it is one more than the ending random numbers of the immediately preceding outcome.
Also the ending random number for each outcome is one less than the cumulative probability.
Similarly three digit random numbers are used if the prob of an outcome has 3 decimal
places. Read the example on page 133 of your text book.
55
Probability
Cumulative
Probability
Random Numbers
0.2466
0.2466
0000-2465
0.3452
0.5918
2466-5917
0.2417
0.8335
5918-8334
0.1128
0.9463
8335-9462
0.0395
0.9858
9463-9857
0.0111
0.9969
9858-9968
0.0026
0.9995
9969-9994
0.0005
1.0000
9995-9999
Starting with page 592, Row 14, Column 7, we read of the 4 digit random nos as :
R No.
Polluting spics
R.No.
Polluting spics
5095
2631
0150
3033
8043
9167
9079
4998
6440
7036
Example
(1)
(2)
life length X of a bulb is a continuous random variable that can take all non-ve
real values.
The time between two consecutive arrivals in a queuing system is a random
variable that can take all non-ve real values.
56
(3)
The distance R of the point (where a dart hits) (from the centre) is a
continuous random variable that can take all values in the interval (0,a) where
a is the radius of the board.
It is clear that in all such cases, the probability that the random variable takes any one
particular value is meaningless. For example, when you buy a bulb, you ask the question?
What are the chances that it will work for at least 500 hours?
Def Let X be a continuous rv. A real function f(x) is called the prob density function of X
if
(1)
(2)
(3)
f ( x ) 0 for all x
f ( x )dx = 1
P (a X b ) =
b
a
f ( x ) dx.
P( X = a ) = P(a X a ) =
2.
3.
a
a
f ( x )dx = 0
57
P( X x ) = P( < X x ) =
f (t )dt
We denote the above by F(x) and call it the cumulative distribution function (cdf) of X.
Properties of cdf
1.
0 F ( x ) 1 for all x.
2.
x1 < x 2
3.
F ( ) = lim f ( x ) = 0; f (+ ) =
4.
d
d
F (x ) =
dx
dx
lim F (x ) = 1.
x
f (t ) dt = f ( x )
(Thus we can get density function f(x) by differentiating the distribution function F(x)).
(a) Between
Find the distribution function F(x) and hence answer the above questions.
58
Solution
f ( x )dx = 1
gives
1
0
i.e.
kx 2 dx = 1 or k
Thus
1
= 1 or k = 3.
3
f ( x ) = 3 x 2 0 x 1 and 0 otherwise.
1
3
P <X <
=
4
4
P X >
= 13
1
4
3
3 x dx =
4
2
2
2
= P < X <1 =
3
3
2
3
1
2
26 13
=
64 32
3 x 2 dx
19
27
Distribution function F (x ) =
f (t )dt
Case (i)
Case (ii)
F (x ) =
Case (iii)
f (t )dt =
3t 2 dt = x 3 .
x>1
Now f (t ) = 0 for t > 1
59
F (x ) =
f (t )dt =
F (x ) = x 3
1
Now P
0< x 1
x>
0
1
3
3
1
<X < =P X <
P X
4
4
4
4
= P X
= F
3
1
P X
4
4
3
1
3
F
=
4
4
4
P X >
1
4
13
32
2
2
= 1 P X
3
3
2
2
= 1 F
=1
3
3
19
27
0 < x <1
f (x ) = 2 x 1 x < 2
0
elsewhere
Find the prob that the rv takes a value
(a) between 0.2 and 0.8
(b) between 0.6 and 1.2
Find the distribution function and answer the same questions.
60
Solution
(a)
0.8
0.2
=
=
1
0.6
1
0.6
f ( x )dx +
x dx +
= 0.32 +
0.2
0 .8
x dx =
2
(b)
0.8
f ( x )dx
0 .2
1.2
0.6
1.2
4
= 0 .3
f ( x )dx
f (x )dx
(why ?)
2
(2 x ) dx = 1 0.6
2
2
1.2
1
2 x
+
2
f (t )dt
f (t )dt = 0.
=0+
Case (iii)
F (x ) =
Case (ii)
1.2
1 (.8)
=
= 0.32 + 0.18 = 0.5
2
2
t dt =
f (t )dt =
f (t )dt + 1
x2
2
t0
t 0< t 1
2t 1< t x
61
f (t )dt
F (x ) =
=
f (t )dt
f (t )dt +
x
1`
1
(by case ii ) +
2
f (t )dt
(2 t )dt
x
1
(2 x )
1 1 (2 x )
= 1
= +
2 2
2
2
2
Case (iv)
F (x ) =
=
f (t )dt
f (t )dt +
x
2
f (t )dt
x
0 dt = 1
Thus
0
x2
2
F (x ) =
2
(
2 x)
1
2
1
0< x 1
1<
x
x 2
>
(0.6 )2
2
= 0 .5
62
P ( X > 1 .8 ) = 1 P ( X 1 .8 )
= 1 F (1.8) = 1
2
(
.2 )
1
= 0.02
= E(X ) =
x f ( x )dx
( )
(x )2 f (x )dx
= E X 2 2
( )
Here E X 2 =
x 2 f ( x )dx
Its mean = E ( X ) =
( )
E X2 =
1
0
x f ( x )dx =
1
0
3
x.3 x 2 dx = .
4
x 2 f ( x )dx
x 2 . 3 x 2 dx =
3
5
3 3
Hence 2 =
5 4
= 0.0375
63
= E(X ) =
x f ( x )dx =
x.
1 x / 20
e
dx
20
[(
= x. e x / 20 20e x / 20
= 20.
( )
E X2 =
x2
x 2 f ( x )dx
1 x / 20
e
dx
20
[x ( e
2
x / 20
= 800
) (2 x ) (20 e
x / 20
) + 2.( 400 e
x / 20
)]
( )
NORMAL DISTRIBUTION
A random variable X is said to have the normal distribution (or Gaussian Distribution) if
its density is
f x; , 2 =
1
2
( x )2
2 2
< x <
Hence , are fixed (called parameters) and > 0. The graph of the normal density is
a bell shaped curve:
64
Figure
It is symmetrical about the line x = and has points of inflection at x = .
One can use integration and show that
variance of X = E ( X ) = 2 .
1
2
e t
dt
and represents the area under the density upto z. It is the shaded portion in the figure.
Figure
We at once see from the symmetry of the graph that F (0 ) =
F ( z ) = 1 F ( z )
65
1
= 0 .5
2
F(z) for various positive z has been tabulated at in table 3 (at the end of your book).
We thus see from Table 3 that
Important
If X is normal with mean and variance 2 , it can be shown that the standardized r.v.
X
Z=
has standard normal distribution. Thus questions about the prob that X
assumes a value between say a and b can be translated into the prob that Z assumes
values in a corresponding range. Specifically :
66
=P
=F
<
<
=P
<Z<
> 16.8
< 14.9
between 13.6 and 18.8
between 16.5 and 16.7
>
16.8 16.2
1.25
.6
= P (Z > 0.48)
1.25
= 1 P (z 0.48) = 1 F (0.48)
=P Z>
= 1 0.6844 = 0.3156
(b)
P ( X < 14.9 ) = P
<
14.9 16.2
1.25
1 .3
= P (Z < 1.04 )
1.25
= F ( 1.04 ) = 1 F (1.04 ) = 1 0.8508 = .1492
=P Z <
1.25
67
2 .6
2 .6
<Z <
= P ( 2.08 < Z < 2.08)
1.25
1.25
= F (2.08) F ( 2.08) = F (2.08) (1 F (2.08))
=P
1.25
.3
.5
<Z <
1.25
1.25
= P (0.24 < z < 0.4 ) = F (0.4 ) F (0.24 )
=P
Example 2
A rv X has a normal distribution with = 10. If the prob is 0.8212 that it will take on a
value < 82.5, what is the prob that it will take on a value > 58.3?
Solution
Let the mean (unknown) be .
Given P( X < 82.5) = 0.8212
Thus P
<
82.5
= 0.8212
10
Or P Z <
82.5
= 0.8212
10
82.5
= 0.8212
10
From table 3,
82.5
= 0.92
10
=P
>
58.3 73.3
= P (Z > 1 / 5 )
10
Solution
That is find a number c so that
P( X > c ) = 0.95
i.e P
i.e. P Z >
>
c 16.28
= 0.95
1 .2
Hence P Z
c 16.28
= 0.95
1 .2
c 16.28
= 0.05
1 .2
c 16.28
= 1.645
1 .2
shown that P
69
Thus when n is large, the binomial probabilities can be approximated using normal
distribution function.
Solution
Let X = No. of toasters (among 1200) that require repairs within the first 90 days after
they are sold. Hence X is a rv having Binomial Distribution with parameters n = 1200
2
= .02.
and p =
100
Required P ( X 30 ) = P
X np
npq
30 24
4.85
=P
X np
npq
29.5 24
4.85
5 .5
= P(Z 1.13)
4.85
= 1 P (Z 1.13) = 1 F (1.13) = 1 0.878
P Z
= .1292
Solution
Let X = no. of accidents (among 84) due to failure of employees to follow instructions.
Thus X is a rv having Binomial distribution with parameters n = 84 and p = 0.3.
Thus np = 25.2 and npq = 4.2
Required P(20 X 30)
4 .2
4 .2
npq
P ( 1.36 Z 1.26 )
= F (1.26 ) F ( 1.36 ) = F (1.26 ) + F (1.36 ) 1
= 0.8962 + 0.9131 1 = 0.8093
<x<
elsewhere
71
<c<d <
P (c < X < d ) =
d
c
1
d c
dx =
The variance of X =
0
x
f (x ) =
1
+
2
(
)2
=
12
<x
x>
Solution
(a)
(b)
0.015 0.010
0.025 ( 0.025)
0.005
= 0 .1
0.050
0.012 ( 0.012 )
0.025 ( 0.025)
12
= 0.48
25
72
2C
< x < 2C
3
elsewhere
where C is his own estimate of the cost of the job. What percentage should Mr. Harris
add to his cost estimate when submitting bids to maximize his expected profit?
Solution
Suppose Mr. Harris adds k% of C when submitting his bid. Thus Mr. Harris gets a profit
kC
kC
if he gets the contract which happens if the lowest bid (by others) C +
and
100
100
kC
. Thus the prob that he gets the bid
gets no profit if the lowest bid < C +
100
kC
3
kC
3
k
=P C+
< X < 2C =
2C C +
= 1
100
4C
100
4
100
Thus the expected profit of Mr. Harris is
kC 3
k
1
+ 0 (....)
100 4
100
3C
k2
k
=
400
100
which is maximum (by using calculus) when k =50.
Thus Mr. Harriss expected profit is a maximum when he adds 50% of C to C, when
submitting bids.
Gamma Function
This is one of the most useful functions in Mathematics. If x > 0, it is shown that the
improper integral
( x ) =
e t t x 1 dt.
73
( x + 1) = x( x ) , x > 0
2.
(1) = 1
3.
4.
5.
( x ) decreases in the interval (0,1) and increases in the interval (2, ) and has a
minimum somewhere between 1 and 2.
Exponential Distribution
If = 1, we say X has exponential distribution. Thus X has an exponential distribution
(with parameter > 0 ) if its density is
f (x ) =
x>0
elsewhere
74
F (x ) =
1 e
x>0
elsewhere
= 1 F (s ) = e
(by (3))
P( X > s + t | X > s ) =
P (( X > s + t ) ( X > s ))
P( X > s )
P( X > s + t ) e ( s + t ) /
t
=
=
=
e
= P( x > t ).QED
s
P( X > s )
e
Solution
The power supply will be inadequate if demand exceeds the daily capacity.
Hence the prob that the power supply is inadequate
= P ( X > 12 ) =
f ( x )dx
12
75
1
e 2 x 31
Now as = 3, = 2, f ( x ) = 3
2 (3)
x
1 2 2
=
x e
16
1 2 2
Hence P ( X > 12 ) =
x e dx
12 10
Integrating by parts, we get
x
1 2
=
x 2e 2 2 x 4e 2 + 2 8e 2
10
1
2 12 2 e 6 + 8 12 e 6 + 16e 6
16
400 6
e = 25e 6 = 0.062
10
12
Solution
The density of X is
f (x ) =
(a)
1 50
e
50
76
20
20
1 50
= P ( X < 20 ) =
e dx = e 50
50
0
= 1 e
(b)
20
50
=1 e
2
5
= 0.3297
= P ( X > 60 ) =
= e
x
50
1 50
e dx
60 50
=e
6
5
= 0.3012
60
Solution
Let T be the time between two consecutive arrivals. Thus clearly T is a continuous r.v.
No arrival in time period t.
with values > 0. Now T > t
Thus P (T > t ) = P ( X t = 0)
( X t = Number of arrivals in time period t)
= e t (as X t has a Poisson distribution with parameter = t )
Hence the distribution function of T
= F (t ) = P (T t ) = 1 P (t > t ) = 1 e t t > 0
(F (t ) = 0 clearly
for all t 0)
77
e t
d
F (t )
dt
if t > 0
elsewhere
Hence we would say the IAT is a continuous rv. with exponential density with parameter
1
.
B ( x, y ) = t x 1 (1 t )
y 1
dt
It is well-known that B ( x, y ) =
( x )( y )
, x , y > 0.
( x + y )
BETA DISTRIBUTION
A r.v. X is said to have a Beta distribution with parameter , > 0 if its density is
1
1
f (x ) =
, x 1 (1 x )
0 < x <1
B ( , )
0
elsewhere
It is easily shown that
(1)
E(X ) = =
(2)
V (X ) = 2 =
( + ) ( + + 1)
2
78
Solution
Let X = annual proportion of erroneous income tax returns. Thus X has a Gamma density
with = 2, = 9.
P( X < 0.1) =
0.1
0.1
1
9 1
x 2 1 (1 x ) dx
B (2,9 )
B (2,9 ) =
0.1
(2 )(9 ) 1 8!
1
1
=
=
=
(11)
11! 9 10 11 990
x. (1 x ) dx =
8
[(1 x )
0.1
(1 x ) dx
9
(1 x )9
10
= (.9 )
10
(
1 x)
0.1
9
(
.9 )
=
1 (.9 )
1
+ +
9 9
10
10
10
.9 1
1 1
1
19
9
+
= (.9 )
10 9
9 10 90
900
= 0.00293
f (x ) =
1
2
0
x 1 e (ln x )
/ 2 2
x > 0, > 0
elsewhere
79
ln a
<Z <
ln b
ln b
=F
ln a
P( X c ) = 2 P( X c )
Solution
P ( X c ) = 2 P (x c )
Implies P( X c ) = 2 (1 P( X < c ))
Let P( X c ) = p
Thus 3 p = 2 or p =
Now P ( X c ) = P
Implies
2
3
=F
c = + 0.43
80
2
= .6667
3
Example 13
Solution
P 1< X 2 < 4
= P (1 < X < 2 )
=P
1
2
2
1
< Z <
=P Z <
P Z <
5
5
5
5
=2 F
2
5
1 2 F
2
1
1
1 = 2 F
F
5
5
5
Solution
That is we have to find a number C such that
P ( X > C ) = 0.05
i.e P
Hence
>
C 29.5
= 0.05
2 .5
C 29.5
= z 0.05 = 1.645
2 .5
Example 15
A rocket fuel is to contain a certain percent (say X) of a particular compound. The
specification calls for X to lie between 30 and 35. The manufacturer will make a net
profit on the fuel per gallon which is the following function of X.
T (X ) =
If X has a normal distribution with mean 33and s.d. 3, find the prob distribution of T and
hence the expected profit per gallon.
Solution
T = 0.10 if 30 < X < 35
P (T = 0.10 ) = P(30 < X < 35)
=P
30 33 X 35 33
<
<
3
= P 1< Z <
2
3
2
2
F ( 1) = F
+ F (1) 1
3
3
= 0.7486 + 0.8413 1 = 0.5899
=F
35 33 X 40 33
25 33 X 30 33
<
+P
<
<
3
3
=P
2
7
8
+P
< Z 1
Z <
3
3
3
=F
7
2
8
F
+ F ( 1) F
3
3
3
=F
7
2
8
F
+F
F (1)
3
3
3
82
Example 16
Two cards are drawn at random from a pack of 52 cards. Let X be the number of aces
drawn and Y be the number of Queens drawn.
Find the joint prob distribution of X and Y.
Solution
Clearly X can take any one of the three values 0,1,2 and Y one of the three values, 0,1,2.
The joint prob distribution of X, and Y is depicted in the following 3 x 3 table
x
4
1
44
2
52
4
1
44
1
44
2
52
4
2
52
4
1
4
1
52
52
4
2
2
52
2
83
Justification
P ( x = 0, y = 0 )
= P (no aces and no queens in t he 2 cards)
44
2
52
2
44
44
1
52
2
etc.
Can we write down the distribution of X? X can take any one of the 3 values 0,1,2
What is P( X = 0) ?
X = 0 means no ace is drawn but we might draw 2 queens, or 1 queen and one non queen
or 2 cards which are neither aces nor queens.
Thus
P ( X = 0 ) = P ( X = 0, Y = 0 ) + P ( X = 0, Y = 1) + P ( X = 0, Y = 1)
= Sum of the 3 prob in col. 1
44
2
52
2
4
1
44
1
52
2
4
2
52
2
48
2
52
2
(Verify!)
Similarly P( X = 1) = P( X = 1, Y = 0) + P( X = 1, Y = 1) + P( X = 1, Y = 2)
84
44
52
1
52
+0=
48
1
52
(Verify!)
P ( X = 2 ) = P( X = 2, Y = 0 ) + P ( X = 2, Y = 1) + P( X = 2, Y = 2 )
= Sum of the 3 probabilities in 3rd col
4
4
2
2
=
+0+0=
52
52
2
The distribution of X derived from the joint distribution of X and Y is referred to as the
marginal distribution of X..
Similarly the marginal distribution of Y are the 3 row totals.
Example 17
The joint prob distribution of X and Y is given by
-1
y
0
1
Marginal Distribution of X
-1
1
8
1
8
1
8
3
8
0
1
8
0
1
8
2
8
1
1
8
1
8
1
8
3
8
3
8
2
8
3
8
Write the marginal distribution of X and Y. To get the marginal distribution of X, we find
the column totals and write them in the (bottom) margin. Thus the (marginal) distribution
of X is
X
-1
0
1
Prob
3
2
3
8
8
8
85
Y
-1
Prob
3
8
2
8
3
8
0
1
And
h( y ) = P(Y = y ) =
1
1
P ( X = x, Y = y ) =
all x
1
1
f ( x, y )
all x
Conditional Distribution
The conditional prob distribution of Y for a given X = x is defined as
P ( X = x, Y = y ) f ( x , y )
=
P( X = x )
g (x )
h(0 | 1) = P (Y = 0 | X = 1) =
P( X = 1, Y = 0 )
=
P( X = 1)
1
8
3
1
3
86
g ( x | y ) = P( X = x | Y = y ) =
P ( X = x, Y = y ) f ( x, y )
=
P(Y = y )
h( y )
g (0 | 0 ) = P ( X = 0 | Y = 0 ) =
P (Y = 0, y = 0 ) 0
= =0
2
P (Y = 0 )
8
Independence
We say X,Y are independent if
Example 18
The joint prob distribution of X and Y is given by
(a)
2
0
1
2
0.1
0.05
0.1
X
0
0.2
0.1
0.1
1
0.1
0.15
0.1
X
Prob
2
0.25
0
0.4
87
1
0.35
(b)
Y
2
0
1
(c)
Prob
0.4
0.3
0.3
Find P( X + Y = 2)
Ans X + Y = 2 if ( X = 2, Y = 0) or ( X = 1, Y = 1) or ( X = 0, Y = 2)
Thus P( X + Y = 2 ) = 0.05 + 0.1 + 0.2 = 0.35
(d)
Find P( X Y = 0)
Ans : X Y = 0 if ( X = 2, Y = 2) or ( X = 0, Y = 0) or ( X = 1, Y = 1)
Find P( X 0) Ans. 1
0 .3
= 0 .3
1
0 .2 1
Find P ( X Y = 0 X 1) Ans.
=
0 .6 3
Are X,Y independent?
Find P ( X Y = 0 X 0 ) Ans.
f ( x, y ) 0 for all x, y
88
(ii)
f (x, y )dy dx = 1
(iii)
P(a X b, c Y d ) =
b d
f ( x, y )dy dx.
a c
Example 19(a)
Let the joint prob density of (X,Y) be
f ( x, y ) =
1
4
0
0 x 2, 0 y 2
elsewhere
Find P( X + Y 1)
Ans : The region x + y 1 is given by the shaded portion.
P (x + y 1)
1 x
x = 0 y =0
1
dy dx
4
1
(1 x ) dx = 1 (1 x )2
=
8
0 4
1
= .
8
Example 19(b)
The joint prob density of (X,Y) is
f ( x, y ) =
1
(6 x y ) 0 < x < 2, 0 < y < 4
8
Solution
1
f (x, y )dy dx
x =0 y = 2
89
x=0 y =2
2
1
(6 x ) y y
8
2
x =0
1
(6 x y )dy dx
8
x=0
dx
2
1
(6 x ) 5 dx
8
2
1 (6 x )
5
=
8
2
2
2
=
0
1 25 5
3
+ 18 =
8
2 2
8
f ( x, y )dy
f ( x, y )dx
f ( x, y )
(Defined only for those x for which g(x) 0)
g (x )
g (x | y ) =
f ( x, y )
(defined only for those y for which h( y ) 0)
h( y )
90
Independence
We say X,Y are independent if and only if f ( x, y ) = g ( x )h( y )
which is the same as saying g ( x | y ) = g ( x ) or h( y | x ) = h( y ).
Example 20
Consider the density of (X,Y) as given in example 19.
The marginal density of x
= g (x ) =
1
(6 x y )dy
8
y =2
1
y2
(6 x ) y
8
2
1
[2(6 x ) 6] 0 < x < 2
8
and = 0
elsewhere
=
1
g ( x )dx =
8
Secondly
0
1
(6 2 x ) 0 for 0 < x < 2
8
1
6x x 2
8
(6 2 x )dx
1
[12 4] = 1
8
h( y )
x =0
1
(6 x y )dx
8
1
x2
= (6 y )x
8
2
=
x =0
1
[2(6 y ) 2]
8
91
1
(10 2 y ) or < y < 4
8
0
elsewhere
Again h( y ) 0 and
h( y )dy
1
=
(10 2 y )dy = 1 10 y y 2
82
8
4
2
1
[20 12] = 1
8
1
(6 1y ) 1
f ( x, y ) 8
is h( y | 1) =
=
= (5 y ), 2 < y < 4
1
g (1)
(6 2) 4
8
And 0 elsewhere
Again this is a valid density as h( y | 1) 0
4
And
2
1
h( y | 1)dy =
4
(5 y )dy
1 (5 y )
=
4
2
P ( x < 1 | Y < 3) =
Now Nr =
=
2
1 9 1
=1
4 2 2
P( X < 1, Y < 3)
P (Y < 3)
3
8
Dr = P(Y < 3) =
h( y )dy =
1
=
(5 y )dy = 1 (5 y )
42
4
2
3
1
(10 2 y )dy
82
2
=
2
1 9 4
5
=
4 2 2
8
92
1
(6 1y ) 1
f (1, y ) 8
Is h( y | 1) =
=
= (5 y ) 2 < y < 4
1
g (1)
(6 2) 4
8
And 0 elsewhere
Again this is a valid density as h( y | 1) 0 and
h( y | 1)dy =
1 (5 y )
=
4
2
=
2
P ( X < 1 | Y < 3) =
Now Numerator =
3
8
3
1
h( y )dy =
8
(5 y )dy = 1 (5 y )
4
2
(5 y )dy
P ( x < 1, y < 3)
P (Y < 3)
1 9 1
=1
4 2 2
Denominator = P (Y < 3) =
1
=
4
1
4
=
2
(10 2 y )dy
1 9 4
5
=
4 2 2
8
3
Hence P ( X < 1, Y < 3) = 8 =
5
5
8
f (u , v )dvdu.
93
f ( x, y ) =
6
5
(x + y )
Solution
Case (i)
x<0
x
F ( x, y ) =
f (u , v )dvdu
= 0 as f (u , v ) = 0 for
any u , v < 0
Case (ii)
y < 0.
Again F ( x, y ) = 0 whatever be x.
Case (iii)
F ( x, y ) =
f (u , v )dvdu
6
5
u =0 v = 0
6
v3
=
uv +
5 u =0
3
du
0
6
y3
6 x 2 y xy 3
=
uy +
du =
+
.
5 u =0
3
5 2
3
94
Case (iv)
0 < x < 1, y 1
y
F ( x, y ) =
f (u , v ) dv du
u =0 v = 0
6
u + v 2 dv du
5
6
1
6 x2 x
u + du =
=
+
5 u =0
3
5 2 3
Case (v)
x 1, 0 < y < 1
as in case (iii) we can show
F ( x, y ) =
Case (v)
6 y y3
+
5 2 3
x 1, y 1
x
F ( x, y ) =
f (u , v )dv du =
u =0 v = 0
6
1
6 1 1
u + du =
+ =1
5 u 0
3
5 2 3
95
6
u + v 2 dvdu
5
5
2
3
2
3
3
2
3
2
3
(
0.5) (0.4 ) (0.5)(0.4 ) (0.2 ) (0.4 ) (0.2 )(0.4 )
+
+
6
(0.5)2 1 + (0.5) (0.6)3 (0.4)3 (0.2)2 .1 (0.2) (0.6) (0.4)
5
3
3
6
(0.5 )2 (0.2 )2 0.1 + (0.1) (0 .6 )3 (0.4 )3
5
6
2
2
3
3
0 .1 (0 .5 ) (0 .2 ) + (0 .6 ) (0 .4 )
5
6
0 .1 [0 .362 ]
5
[[
]]
= 0 .04344
Example 22
The joint density of X and Y is
f ( x, y ) =
6
5
(x + y )
2
g (x | y ) =
f ( x, y )
where h( y ) is the marginal density of y.
h( y )
96
1
2
Thus
1
h( y ) =
f ( x, y )dx =
x =0
1
6
5
(x + y )dx
2
x =0
6 1
+ y 2 0 < y < 1.
5 2
Hence
g (x | y ) =
(and
6
5
6
5
(x + y ) = x + y
( +y ) +y
2
1
2
1
2
2
2
, 0 < x < 1.
0 elsewhere )
g x |
x+ 1 4
1
1
= 1 14 =
x+ ,
2
+4 3
4
2
0 < x <1
Hence
E x| y=
1
2
x g x|
0
=
0
1
dx
2
4
1
x + dx
3
4
4 x3 x2
=
+
3 3 8
=
0
4 1 1
11
+
=
3 3 8
8
97
Example 23
(X,Y) has a joint density which is uniform on the rhombus find
(a) Marginal density of X.
(b) Marginal density of Y
(c) The conditional density of Y given X =
1
2
Solution
(X,Y) has uniform density on the rhombus means
f (x , y ) =
1
Area of the r hom bus
1
over the r hom bus
2
and 0 elsewhere
(a) Marginal Density of X
Case (i)
0<x<1
f (x ) =
1 x
y = x 1
Case (ii)
1
dy = (1 x )
2
1<x<0
f (x ) =
1+ x
1
dy = 1 + x
2
y = 1 x
Thus
1 + x 1 < x < 0
g (x ) = 1 x
0
0 < x <1
elsewhere
1+ y
1 < y < 0
h( y ) = 1 y
0
(c)
for x =
0 < y <1
elsewhere
1
1 1
, y ranges from to
2
2 2
h (y | 12 ) =
for x =
h (y |
f (x , 12 )
f ( 12 )
1 12 < y < 12
0 elsewhere
1
2 2
Y rangs from to
3
3 3
1
3
)=
1
2
2
3
=
0
3
4
2
2
<y<
3
3
elsewhere
99
1
is
2
PROPERTIES OF EXPECTATIONS
Let X be a r.v. a,b be constants
Then
(a)
E (aX + b ) = a E ( x ) + b
(b)
100
Sample Mean
Let X 1 , X 2 .....X n be n indep rvs each having the same mean and same variance 2 .
We define
X=
X 1 + X 2 + ... + X n
n
X is called the mean of the rvs X 1 .....X n . Please note that X is also a rv.
Theorem
()
1.
E X =
2.
Var X =
()
2
.
n
Proof
(i)
()
EX =
1
[E(X 1 ) + E(X 2 ) + .... + E(X n )]
n
(2)
()
Var X =
1 + + ..... +
=
n
n times
1
[Var (X 1 ) + Var(X 2 ) + .... + Var(X n )]
n2
1 2 + 2 + .. + 2
n 2 2
=
=
n times
n
n2
n2
101
Sample variance
Let X 1 ...X n be n indep rvs each having the same mean and same variance 2 . Let
X=
X1 + X 2 + X n
be their sample mean. We define the sample variance as
n
S2 =
1
n 1
n
i =1
(X
( )
E S2 = 2
Simulation
To simulate the values taken by a continuous r.v. X, we have to use the following
theorem.
Theorem
Let X be a continuous r.v. with density f(x) and cumulative distribution function F(x). Let
U = F ( X ) . Then U is a r.v. having uniform distribution on (0,1).
In other words, U is a random number. Thus to simulate the value taken by X, we take a
random no U from the table 7 (Now you must put a decimal point before the no) And
solve for X, the equation
F (X ) = U
102
Example 24
Let X have uniform density on ( , ) . Simulate the values of X using the 3-digit random
numbers.
937, 133, 753, 503, ..
Solution
Since X has uniform density on ( , ) its density is
f (x ) =
<n<
elsewhere
F (x ) =
<x
x>
1
F(X ) =
means
X
=
_ _
X = + ( )
Hence if
= .937, X = + ( ).937
= .133, X = + ( ).133
etc.
Let x have exponential density (with parameter )
f (x ) =
x>0
elsewhere
103
0
1 e
xp
x0
x>0
= U for X, we get
1
1 U
X = ln
Since U is a random number implies 1-U is also a random number, we can as well use the
formula
X = ln
1
U
= ln U.
Example 25
X has exponential density with parameter 2. Simulate a few values of X.
Solution
The defining equation for X is
X = 2 ln
Taking 3 digit random numbers form table 7 page 595 row 21 col. 3, we get the random
numbers : 913, 516, 692, 007 etc.
The corresponding X values are :
104
Example 26
The density of a rv X is given by
f (x ) = x 1 < x < 1
= 0 elsewhere
Simulate a few values of X.
Solution
First let us find the cumulative distribution function F(x).
Case (i)
Case (ii)
1 < x 0.
F (x ) =
f (t )dt =
Case (iii)
t dt
1
t dt =
1 x2
2
0 < x 1
In this case F ( x ) =
f (t )dt
0 dt +
= 0+
t dt +
tdt
0
1 x2 1+ x2
+
=
2 2
2
105
Case (iv)
x 1
F(x ) =
1 < x 0
0 < x 1
x >1
1 x
2
1+ x 2
2
Case (i)
1
2
1 x 2
F(x ) =
= U(why ?)
2
X = 1 2 U (why ?)
1
U <1
2
Case (ii)
1+ X 2
=U
2
X = + 2U 1
Thus the defining conditions are :
If 0 U <
1
, X = 1 2U
2
and
1
If U < 1,
2
x = + 2U 1
106
Let us consider the 3 digit random numbers on page 594 Row 17 Col. 5
726, 282, 272, 022,.
U = .726
1
Thus X = + 2 .726 1 = 0.672
2
U = .281 <
1
Thus X = 21 2 .281 = 0.662
2
Note : Most of the computers have built in programs which generate random deviates
from important distributions. Especially, we can invoke the random deviates from a
standard normal distribution. You may also want to study how to simulate values from a
standard normal distribution by Box-Muller-Marsaglia method given on page 190 of the
text book.
Example 27
Suppose the no of hours it takes a person to learn how to operate a certain machine is a
random variable having normal distribution with = 5.8 and = 1.2. Suppose it takes
two person to operate the machine. Simulate the time it takes four pairs of persons to
learn how to operate the machine. That is, for each pair, calculate the maximum of the
two learning times.
Solution
We use Box-Muller-Marsaglia Method to generate pairs of values z1 , z 2 taken by a
standard normal distribution. Then we use the formula
x1 = + z1
x 2 = + z 2
to simulate the time taken by a pair of persons.
(where = 5.8, = 1.2 )
We start with the random numbers from Table 7
107
z 2 = 2 ln u 2
U2
.016
Z1
-0.378
Z2
-0.991
etc.
Review Exercises
5.108. If the probability density of a r.v. X is given by
k 1 x 2
f (x ) =
0
0 < x <1
elsewhere
(b)
Solution
f ( x )dx = 1 gives w s
k 1 x 2 dx = 1
or k 1
k =
1
=1
3
3
2
108
X1
5.346
X2
4.611
x 0 F (x ) = 0
Case (ii)
0 < x 1 , F(x ) =
k 1 t 2 dt
x3
3
x
=
.
2
3
Case (iii)
x > 1. F(x ) = 1
P(0.1 < X < 0.2 ) = F(0.2) F(0.1)
3
(0.2)2 (0.2)
2
3
3
(0.1) (0.1)
2
3
3
(0.5) (0.5)
2
3
5.113: The burning time X of an experimental rocket is a r.v. having the normal
distribution with = 4.76 sec and = 0.04 sec . What is the prob that this kind of rocket
will burn
(a)
(b)
(c)
<4.66 Sec
> 4.80 se
anywhere from 4.70 to 4.82 sec?
Solution
(a)
X 4.66 4.76
<
0.04
(b)
X 4.80 4.76
>
0.04
(c)
=P
0.04
5.11 The prob density of the time (in milliseconds) between the emission of beta particles
is a r.v. X having the exponential density
0.25e 0.25
f (x ) =
0
x>0
elsewhere
(a)
(b)
Solution
(a)
20010
= e 5010
20010 3
110
(b)
1010 3
1010 3
0
= 1 e 2.510
5.120: If n sales people are employed in a door-to-door selling campaign, the gross sales
volume in thousands of dollars may be regarded as a r.v. having the Gamma distribution
1
with = 100 n and = . If the sales costs are $5,000 per salesperson, how many
2
sales persons should be employed to maximize the profit.
Solution
For a Gamma distribution = = 50 n . Thus (in thousands of dollars) the average
profit when n persons are employed.
= T = 50 n 5n (5 x 1000 per person is the cost per person)
This is a maximum (using calculus) when n = 25.
5.122: Let the times to breakdown for the processors of a parallel processing machine
have joint density
f ( x, y ) =
x > 0, y > 0
elsewhere
where X is the time for the first processor and Y is the time for the 2nd processor. Find
(a)
(b)
(c)
111
Solution
(a)
Marginal density of X
= g (x ) =
f (x , y )dy =
y =
= 0 .2 e
0.2 x
y =0
y=0
(and
= 0 if x 0 )
0.2e 0.2 y
h( y ) =
0
y>0
elsewhere
E(X + Y ) =
(x + y ) f (x, y )dydx
x =0 y = 0
x =0 y = 0
112
1
= 5 ) E(X)
0 .2
x =0 y =0
= 5 + 5 = 10 (verify!)
= E(X ) + E(Y )
5.123: Two random variable are independent and each has binomial distribution with
success prob 0.7 and 2 trials.
(a)
(b)
Solution
Let X,Y be independent and have Binomial distribution with parameters n = 2, and
p = 0.7 Thus
P(X = k ) =
2
(0.7 )k (0.3)2 k k = 0,1,2
k
P(Y = r ) =
2
(0.7 )r (0.3)2 r r = 0,1,2
r
2
k
2
r
(0.7 )k + r (.3)4(k + r )
0 k, r 2
113
(b)
P(Y > X )
= P(Y = 2, X = 0 or1) + P(Y = 1, X = 0 )
2
2
2
1
(0.7 )2 (.3)0
(0.7 )1 (0.3)1
(0.7 )0 (0.3)2 +
0
2
0
2
1
(0.7 )1 (0.3)1
(0.7 )0 (0.3)2
5.124 If X1 has mean 5, variance 3 while X2 has mean 1 and variance 4, and the two are
independent, find
(a)
E(3X 1 + 5X 2 + 2)
(b)
Var (3X 1 + 5X 2 + 2)
Ans:
(a)
3 ( 5) + 5(1) + 2 = 8
(b)
9 3 + 25 4 = 127
114
Sampling Distribution
Statistical Inference
Suppose we want to know the average height of an Indian or the average life length of a
bulb manufactured by a company, etc. obviously we cannot burn out every bulb and find
the mean life length. One chooses at random, say n bulbs, find their lifelengths
X + X 2 + .... + X n
X 1 , X 2 ..... X n and take the mean life length X = 1
as an approximation
n
to the actual (unknown) mean life length. Thus we make a statement about the
population (of all life lengths) by looking at a sample of it. This is the basis behind
statistical inference. The whole theory of statistical inference tells us how close we are to
the true (unknown) characteristic of the population.
Random Sample of size n
In the above example, let X be the lifelength of a bulb manufactured by the company.
Thus X is a rv which can assume values > 0. It will have a certain distribution and a
certain mean etc. When we make n independent observations, we get n values
Definition
Let X be a random variable. A random sample of size n from x is a finite ordered
sequence {X 1 , X 2 ...., X n }of n independent rv3 such that each Xi has the same
distributions that of X.
115
Statistics
Whenever we sample, we use a characteristic of the sample to make a statement about the
population. For example suppose the true mean height of an Indian is (cms). To make a
statement about , we randomly select n Indians, Find their heights {X 1 , X 2 ...., X n }and
then their mean namely
X=
X 1 + X 2 + ..... + X n
n
We use then
parameter, a constant that is unchanged. But the sample mean X is a r.v. It may assume
different values depending on the sample of n Indians chosen.
Definition : Let X be a r.v. Let {X1 , X 2 .....X n } be a sample of size n from X. A statistic
X 1 + X 2 + ..... + X n
n
1 n
Xi X
n 1 i =1
Definition
X 1 + X 2 + ........ + X n
be the sample mean. Then
n
( )
(a)
E X = .
(b)
VX =
(c)
( )
2
.
n
( )
Var X =
2 N n
.
n N 1
(d)
(e)
X
has approximately the
n
standard normal distribution. (This result is known as the central limit theorem.)
Explanation
(a)
(b)
(c)
X
has a standard normal
distribution.
(d)
Solution
( )
( )
P | T E (T ) | k Var(T ) 1
1
k2
( )
( )
var(T ) = var X =
P X < k.
2 (2.4 )
=
, we find
n
25
2
2 .4
1
1 2 .
5
k
k.
2 .4
5
=1.2 gives k =
5
2
P X < 1 .2 1
1
25
4
21
= 0.84
25
118
2
n
=P
2.4
5
)
<
1 .2
2.4
5
5
5
= 2F
1
2
2
P Z <
Solution
We use central limit theorem namely
=P
75 76
16
10
<
<
78 76
16
10
10
20
5
5
<Z<
=P <Z<
16
16
8
4
5
5
5
5
F
=F
+F
1
4
8
4
8
= 0.8944 + 0.7340 1 = 0.8284
=F
119
Solution
Let X be the weight of a man traveling by air between D and E. It is given that X is a rv
with mean E(X ) = = 163 lbs and sd = 18 lbs.
Let X 1 , X 2 .....X 36 be the weights of 36 men traveling on a plane between these two cities.
Thus we can regard {X 1 , X 2 ....., X 36 }as a random sample of size 36 from X.
=P
6000
36
P Z>
>
1000
6
163
18
6
22
18
= 1 P Z
22
= 1 F (1.22 )
18
= 1 0.8888 = 0.1112
120
X
S
n
Remark
(1)
The shape of the density curve of t-distribution (with parameter -greek nu)
is like that of standard normal distribution and is symmetrical about the yaxis.
t , is that
unique number such that
P(t > t v, ) =
( the parameter)
By symmetry t ,1 = 1 t ,
The values of t , for various and are tabulated in Table 4.
For large, t , Z .
121
Solution:
t=
x
s
n
Or P
s
n
8 .4
= 0.005
5
X > 46.78 . Thus we will have to refute the claim = 42.1 (in favour of > 42.1)
Example 5 (See exercise 6.21 on page 213)
The following are the times between six calls for an ambulance (in a certain city) and the
patients arrival at the hospital : 27, 15,20, 32, 18 and 26 minutes. Use these figures to
judge the reasonableness of the ambulance services claim that it takes on the average 20
minutes between the call for an ambulance and the patients arrival at the hospital.
Solution
Let X = time (in minutes) between the call for an ambulance and the patients arrival at
the hospital. We assume X has a normal distribution. (When nothing is given, we assume
normality). We want to judge the reasonableness of the claim that E(X ) = = 20 minutes.
For this we recorded the times for 6 calls. So we have a random sample of size 6 from X
with
122
138
= 23.
6
S2 =
1
(27 23)2 + (15 23)2 + (20 23)2 + (32 23)2 + (18 23)2 + (26 23)2
6 1
1
[16 + 64 + 9 + 81 + 25 + 9] = 204
5
5
Hence S =
204
5
We calculate
t=
x
s
n
23 20
204
5
/ 6
= 1.150
Example 6
A process for making certain bearings is under control if the diameters of the bearings
have a mean of 0.5000 cm. What can we say about this process if a sample of 10 of these
bearings has a mean diameter of 0.5060 cm and sd 0.0040 cm?
X 0 .5
.004
10
2 = (n 1)
S2
1
= 2
2
n
i =1
(X
Remark
Since S2 > 0, the rv has +ve density only to right of the origin. 2 , is that unique
number such that P 2 > 2 , = and is tabulated for some s and s in table 5.
Solution
Required P(3.14 < S < 8.94)
42.5
9
2
(8.94 )
42.5
) (
124
Solution
The prob that the claim is rejected
= P S 2 > 29.74
=P
(n 1) S 2 >
14
39.74 = P 2 > 21.12
21.3
2
= 0.025 As from table 5, 14
, 0.025 = 21.12
Theorem
If S12 , S 22 are the variances of two independent random samples of sizes n1 , n2
respectively taken from two normal populations having the same variance, then
S12
F= 2
S2
is a rv having the (Snedecors) F distribution with parameters 1 = n1 1 and 2 = n2 1
Remark
1. n1 1 is called the numerator degrees of freedom and n2 1 is called the
denominator degrees of freedom.
2. If F is a rv having ( 1 , 2 ) degrees of freedom, then F1 , 2 , is that unique number
such that
125
P F > F 1 2 , = and is tabulated for = 0.05 in table 6(a) and for = 0.01 in table
6(b).
We also note the fact : F 2 , 2 , =
1
F20,10, 0.05
1
F1 , 2 ,1
1
= 0.36
2.77
Example 9
(a) F12,15, 0.95 =
1
F15,12,0.05
1
F20, 6, 0.01
1
= 0.38
2.62
1
= 0.135
7.40
Solution
Let S12 , S 22 be the sample variances of the two samples.
=P
S12
S 22
>
7
or
>7
S 22
S12
= 2 P (F > 7 )
where F is a rv having F distribution with (7,7) degrees of freedom
= 2 x 0.01 = 0.02 (from table 6(b)).
126
S12
> 4 = P(F > 4 )
S 22
6 F (1 + F )
F >0
F 0
If random samples of size 5 are taken from two normal populations having the same
variance, find the prob that the ratio of the larger to the smaller sample variance will
exceed 3?
Solution
Let S12 , S 22 be the sample variance of the two random samples.
S12
= 2 P 2 > 3 = 2 P ( F > 3)
S2
where F is a rv having (4,4) degrees of freedom
127
=2
6F
(1 + F)
= 12
= 12
dF = 12
(1 + F)
2(1 + F)
(1 + F)4
dF
3(1 + F)
1
1
5 12 5
=
=
32 192
192
16
Point Estimation
Here we use a statistic to estimate the parameter of a distribution representing a
population. For example if we can assume that the lifelength of a transistor is a r.v.
having exponential distribution with (unknown) parameter , can be estimated by
some statistic, say X the mean of a random sample. Or we may say the sample mean is
an estimate of the parameter .
Definition
Example
( )
Let X be a rv; the mean of X. If X is the sample mean then we know E X = . Thus
we may say the sample mean X is an unbiased estimate of
statistic,
X=
X 1 + X 2 + ..... + X n
n
a
128
function
of
(Note X is a rv, a
the
random
sample
(X1 , X 2 ....., X n ). If
1 , 2 .... n are
any
non-ve
numbers
such
that
Hence the question arises : If 1 , 2 are both unbiased estimates of , which one do we
prefer? The answer is given by the following definition.
Definition
Let 1 , 2 be both unbiased estimates of the parameter . We say is more efficient than
2 if Var 1 Var 2 .
Remark
That is the above definition says prefer that unbiased estimate which is more closer to
is a r.v. having (approximately) the standard normal distribution. And we can say
P Z <
2
< Z = 1
2
129
Thus we can say with prob (1 ) that the max absolute error X in estimating by
X is atmost Z
.
2
We also say that we can say with 100(1 ) percent confidence that the max. abs error is
atmost Z
Estimation of n
Thus to find the size n of the sample so that we may say with 100(1 ) percent
confidence, the max. abs. error is a given quantity E, we solve for n, the equation
Z
or n =
= E.
Example 1
What is the maximum error one can expect to make with prob 0.90 when using the mean
of a random sample of size n = 64 to estimate the mean of a population with 2 = 2.56 ?
Solution
Substituting n = 64, = 1.6 and Z = Z 0.05 = 1.645 (Note 1 = 0.90 implies
2
E = 1.645
1 .6
= 1.445
we get
1 .6
= 1.645 0.2 = 0.3290
8
64
Thus the maximum error one can expect to make with prob 0.90 is 0.3290.
130
= 0.05 )
Example 2
If we want to determine the average mechanical aptitude of a large group of workers,
how large a random sample will we need to be able to assert with prob 0.95 that the
sample mean will not differ from the population mean by more than 3.0. points? Assume
that it is known from past experience that = 200.
Solution
Here 1 = 0.95 so that
Thus we want n so that we can assert with prob 0.95 that the max error E = 3.0
n =
Z
2
1.96 20
=
3
= 170.74
Small Samples
If the population is normal and we take a random sample of size n (n small) from it, we
note
t=
s
n
131
Example 3
20 fuses were subjected to a 20% overload, and the times it took them to blow had a
mean x = 10.63 minutes and a s.d. S = 2.48 minutes. If we use x = 10.63 minutes as a
point estimate of the true average it takes for such fuses to blow with a 20% overload,
what can we assert with 95% confidence about the maximum error?
Solution
Here n = 20 (fuses) x = 10.63, S = 2.478
95
1 =
Hence we can assert with 95% confidence (ie with prob 0.95) that the max error will be
S
E = t n 1,
= 2.093
2.48
20
= 1.16
Interval Estimation
If X is the mean of a random sample of size n from a population with known sd , then
we know by central limit theorem,
Z=
Z <
2
< Z .
2
Z < <X +
2
Z
2
132
(1 ) that
Thus we can assert with Prob (1 ) ( ie. with (1 ) 100% confidence ) that lies in
the interval X
Z , X +
Z .
2
We refer to the above interval as a (1 )100% confidence interval for . The end
points X
Example 4
Suppose the mean of a random sample of size 25 from a normal population (with = 2 )
is x = 78.3. Obtain a 99% confidence interval for , the population mean.
Solution
Here n = 25, = 2, (1 ) =
79
= 0.99
100
= 78.3
x Z
, x + Z
= 78.3 2.575
2
25
n
, 78.3 + 2.575
2
25
unknown
Suppose X is the sample mean and S is the sample sd of a random sample of size n taken
from a normal population with (unknown) mean . Then we know the r.v.
t=
X
s
n
has a t-distribution with (n-1) degrees of freedom. Thus we can say with prob 1 that
t n 1, < t < t n1,
2
or t n 1, <
2
X
<t
n 1,
S
2
n
or X t
n 1,
2
< < X + t
n 1,
2
Xt
n 1,
2
,X + t
n 1,
2
Note :
(1)
If n is large, t has approx the standard normal distribution. In which case the
(1 )100% confidence interval for will be
x Z
2
(2)
S
n
, x + Z
2
S
n
Example 5
Material manufactured continuously before being cut and wound into large rolls must be
monitored for thickness (caliper). A sample of ten measurements on paper, in mm,
yielded
32.2, 32.0, 30.4, 31.0, 31.2, 31.2, 30.3, 29.6, 30.5, 30.7
Obtain a 95% confidence interval for the mean thickness.
Solution
Here n = 10
x = 30.41 S = 0.7880
1 = 0.95 or
t
n 1,
= 0.025
= t 9, 0.0025 = 2.262
0.7880
10
, 30.9 + 2.262
0.7880
10
= (30.34, 31.46 )
Example 6:
Ten bearings made by a certain process have a mean diameter of 0.5060 cm with a sd of
0.0040 cm. Assuming that the data may be looked upon as a random sample from a
normal population, construct a 99% confidence interval for the actual average diameter of
bearings made by this process.
135
Solution
Here n = 10, x = 0.5060, S = 0.0040
(1 ) =
t
n 1,
99
= 0.99. Hence = 0.005
100
= t 9, 0.005 = 3.250
= x t
n 1,
S
n
, x+t
= 0.5060 3.250
n 1,
0.0040
10
s
n
, 0.5060 + 3.250
0.0040
10
= (0.5019, 0.5101)
Example 7
In a random sample of 100 batteries the lifetimes have a mean of 148.2 hours with a s.d.
of 24.9 hours. Construct a 76.60% confidence interval for the mean life of the batteries.
Solution
Here n = 100, x = 148.2, S = 24.9
76.60
1 =
n 1,
24.9
100
,148.2 + 1.19
24.9
100
136
Example 8
A random sample of 100 teachers in a large metropolitan area revealed a mean weekly
salary of $487 with a sd of $48. With what degree of confidence can we assert that the
average weekly salary of all teachers in the metropolitan area is between $472 and $502?
Solution
Suppose the degree of confidence is (1 ) 100%
Thus x + t
n 1,
S
n
= $502
99 ,
Or Z =
2
48
= 502
10
15
= 3.125
4 .8
= 0.0009 or 1 = 0.9982
We can assert with 99.82% confidence that the true mean salaries will be between
$472 and $502.
random sample of size n from X. Then the likelihood function based on the random
sample is defined as
137
Example 8
Let X be a rv having Poisson distribution with parameter .
Thus f (x , ) = P(X = x ) = e
x
; x = 0,1,2.......
x!
L( ) = e
x1!
x2 !
....e
xn !
e n x1 + x 2 +....+ x n
=
; x i = 0,1,2.......
x 1! x 2 !.....x n !
natural logarithm)
ln L( ) = n + (x 1 + ..... + x n ) ln ln (x 1!....x n !)
Differentiating w.r.t. (noting x1 .....x n are not be varied)
We get
(x + ....xn )
1 L
= n + 1
L( )
= 0 gives =
x 1 + .... + x n
n
138
2L
We can easily verify
is <0 for this .
2
x1 + ....x n
= x (The sample mean)
n
Prob
1-p
f ( x; p )(of X ) is given by
f (x; p ) = p x (1 p )
1 x
; x = 0,1
L(p ) = f (x 1 ; p )f (x 2 , p ).....f (x n ; p )
= p x1T ...+ x n (1 p )
= p (1 p )
s
n s
n ( x1 + x 2 +...+ x n )
(s = x 1 .... + x n )
1 L s (n s )
=
L p p 1 p
for maximum,
(i.e) p =
L
s n s
= 0 or =
p
p 1 p
s x 1 + x 2 + ..... + x n
=
n
n
Example 10
Let X be a rv having exponential distribution with parameter (unknown). Hence the
density of X is f ( x; ) =
(x > 0)
140
Let {X1 , X 2 ....., X n } be a random sample of size n. Hence the likelihood function is
L( ) = f ( x1 ; ) f ( x 2 ; ).... f ( x n ; )
( x1 + x2 +....+ xn )
( xi
> 0)
2
gives =
x1 + x 2 + .... + x n
=x
n
Example 11
A r.v. X has density
f (x; ) = ( + 1)x ;0 < x < 1
Obtain the ML estimate of based on a random sample {X1 , X 2 .....X n } of size n from
x.
Solution
The likelihood function is
L( ) = ( + 1) (x 1 x 2 ...x n ) ; 0 < x i < 1
n
141
1 L
n
=
+ ln (x 1 .......x n )
L + 1
= 0 (for L to be max imum )
gives = 1
ln (x 1 .....x n )
Example 12
A rv X has uniform density over [0, ]
(ie) The density of X is f (x; ) =
1
; 0 x (and 0 elsewhere)
1
; 0 x 1 , 0 x 2 , ....,0 x n
n
142
Large Samples
Suppose we have a dichotomous universe; that is a population whose members are
either haves on have nots; that is a member has a property or not.
For example we can think of a population of all bulbs produced by a factory. Any bulb is
either a have (ie defective) or is a have-not (ie it is good) and p = proportion of haves
= Prob that a randomly chosen member is a have.
As another example, we can think of a population of all females in USA. A member is a
have ( = 0) is a blond or is a have-not
(=is not a blond). As a last example, consider the population of all voters in India. A
member is a have if he follows BJP and is a have-not otherwise.
To estimate p, we choose n members at random and count the number X of haves. Thus
X is a rv having binomial distribution with parameters n and p!
P(X = x ) = f (x; p ) =
n
x
p x (1 p )
n x
; x = 0,1,2.....n
X np
np(1 p )
standard normal
prob (1 ) that
143
z <
2
x np
np (1 p )
x
z
n
2
x
p
n
z
p (1 p ) 2
n
or z <
or
< z
p (1 p )
x
< p < + z
n
n
2
p (1 p )
n
X
(=sample proportion)
n
x
z
n
2
x
x
1
n
n
n
x
< p< + z
n
2
x
x
1
n
n
n
x
z
n
2
x
x
1
n
n
n
X
+ z
n
2
x
x
1
n
n
n
E = Z
2
p (1 p )
n
We can replace p by
X
and say the
n
144
X
p in approximating p by
n
Max error = Z
2
X
X
1
n
n
n
1
1
(which is obtained when p = )
4
2
Thus we can also say with prob (1 ) that the max error.
1
4n
= Z
2
This last equation tell us that to assert with prob (1 ) that the max error is E, n must be
1
4
Example 13
In a random sample of 400 industrial accidents, it was found that 231 were due at least
partially to unsafe working conditions. Construct a 99% confidence interval for the
corresponding true proportion p.
Solution
Here n = 400 , x = 231, (1 ) = 0.99
so that
x
Z
n
2
x
x
1
n
n
n
x
+ Z
n
2
x
x
1
n
n
n
145
231
231
1
231
400
400
=
2.575
400
400
231
231
1
231
400
400
+ 2.575
400
400
= (0.5139,0.6411)
Example 14
In a sample survey of the safety explosives used in certain mining operations,
explosives containing potassium mitrate were found to be used in 95 out of 250 cases. If
95
= 0.38 is used as an estimate of the corresponding true proportion, what can we say
250
with 95% confidence about the maximum error?
Solution
Here n = 250, X = 95, 1 = 0.95
so that
Hence we can say with 95% confidence that the max. error is E = Z
2
= 1.96
x
x
1
n
n
n
0.38 0.62
250
= 0.0602
Example 15:
Among 100 fish caught in a large lake, 18 were inedible due to the pollution of the
.18
environment. If we use
= 0.18 as an estimate of the corresponding true proportion,
100
with what confidence can we assert that the error of this estimate is atmost 0.065?
146
Solution
Here n = 100, X = 18 max error = E = 0.065
We note E = Z
2
X
X
1
n
n
n
= Z
2
.18 .82
100
= Z 0.03842
2
Z =
2
Hence
0.065
= 1.69
0.03842
= 1 0.9545 = 0.0455
= 0.0910 or 1 = 0.9190
So we can assert with (1 ) 100% = 91.9% confidence that the error is at most 0.065.
Example 16
What is the size of the smallest sample required to estimate an unknown proportion to
within a max. error of 0.06 with at least 95% confidence?
Solution
Here E = 0.06 ;1 = 0.95 or
= 0.025
2
Z = Z 0.025 = 1.96
2
147
1
n=
4
Z
2
1 1.96
=
4 0.06
= 266.77
Since n must be an integer, we take the size to be 267.
Remark
Read the relevant material in your text on pages 279-281 of finding the confidence
interval for the proportion in case of small samples.
Example
Suppose we wish to test the null hypothesis H0 = The mean life length of a bulb is 500
hours against the alternative H1 = The mean life length is > 500 hours. Suppose we take a
random sample of 50 bulbs and found that the sample mean is 520 hours. Should we
accept H0 or reject H0 ? We have to note that even though the population mean is 500
hours the sample mean could be more or less. Similarly even though the population mean
is > 500 hours, say 550 hours, even then the sample mean could be less than 550 hours.
Thus whatever decision we may make, there is a possibility of making an error. That is
148
falsely rejecting H0 (when it should have been accepted) and falsely accepting H0 (when
it should have been rejected). We put this in a tabular form as follows:
Accept H0
Reject H0
H0 is true
Correct Decision
Type I error
H0 is false
Type II Error
Correct Decision
Thus the type I error is the error of falsely rejecting H0 and the type II error is the error of
falsely accepting H0. A good decision ( test) is one where the prob of making the errors
is small.
Notation
The prob of committing a type I error is denoted by . It is also referred to as the size of
the test or the level of significance of the test. The prob of committing Type II error is
denoted by .
Example 1
Suppose we want to test the null hypothesis = 80 against the alternative hyp = 83 on
the basis of a random sample of size n = 100 (assume that the population s.d. = 8.4 )
The null hyp. is rejected if the sample mean x > 82 ; otherwise is is accepted. What is the
prob of typeI error; the prob of type II error?
Solution
We know that when = 80 (and = 8.4 ) the r.v.
X
has a standard normal
distribution. Thus,
P (Type I error)
=P (Rejecting the null hyp when it is true)
149
= P X > 82 given = 80
X 82 80
>
8 .4
10
n
=P
= P X 82 given = 83
=P
X 82 83
8 .4
10
n
= P(Z 1.19 )
= 1 P( Z 1.19) = 1 0.8830 = 0.1170
Thus roughly in 12% of the cases we will be falsely accepting H0.
C = x > 82 and remember we reject H0 when the (test) statistic X lies in the critical
150
region (ie takes a value > 82). So the size of the critical region ( prob that X lies in C)
is the size of the test or level or significance.
The shaded portion is the critical region. The portion
acceptance of H0.
...
Z=
x 0
n
Alternative Hypothesis
H1
Reject H0 if
= 1 (< 0 )
Z < Z
1 F
0 1
Z
< 0
Z < Z
= 1 > 0
Z > Z
0 1
+ Z
> 0
Z > Z
Z < Z
or Z > Z
2
151
Remark:
The prob of Type II error is blank in case H1 (the alternative hypothesis) is one of the
following three things = < 0 , > 0 , 0 . This is because the Type II error can
happen in various ways and so we cannot determine the prob of its occurrence.
Example 2:
According to norms established for a mechanical aptitude test, persons who are 18 years
old should average 73.2 with a standard deviation of 8.6. If 45 randomly selected persons
averaged 76.7 test the null hypothesis = 73.2 against the alternative > 73.2 at the
0.01 level of significance.
Solution
Step I Null hypothesis H 0 : = 73.2
Alternative hypothesis H 1 : > 73.2
(Thus here 0 = 73.2 )
x 0
76.7 73.2
= 2.73
8 .6
45
Example 3
It is desired to test the null hypothesis = 100 against the alternative hypothesis
< 100 on the basis of a random sample of size n = 40 from a population with = 12.
For what values of x must the null hypothesis be rejected if the prob of Type I error is to
be = 0.01?
Solution
Z = Z 0.01 = 2.33 . Hence from the table we reject H0 if Z < Z =-2.33 where
Z=
x 0
x 100
< 2.33 gives
12
n
x < 100 2.33
40
12
40
= 95.58
Example 4
To test a paint manufacturers claim that the average drying time of his new fast-drying
paint is 20 minutes, a random sample of 36 boards is painted with his new paint and his
claim is rejected if the mean drying time x is > 20.50 minutes. Find
(a)
(b)
Solution
Here null hypothesis H 0 : = 20
Alt hypothesis H 1 : > 20
P (Type I error) = P (Rejecting H0 when it is true)
Now when H0 is true, = 20 and hence
153
X X 20
6
=
=
X 20 is standard normal.
2 .4
2 .4
n
36
Thus P (Type I error)
= P ( X > 20.50 given that = 20 )
X 20.50 20
>
2 .4
=P
n
36
= P(Z > 1.25) = 1 P(Z 1.25) = 1 F(1.25)
= 1 0.8944 = 0.1056
(b)
= P X 20.50 when = 21
=P
X 20.50 21
2 .4
n
36
= 0.1056
154
Example 5
It is desired to test the null hypothesis = 100 pounds against the alternative hypothesis
< 100 pounds on the basis of a random sample of size n=40 from a population with
= 12. For what values of x must the null hypothesis be rejected if the prob of type I
error is to be = 0.01?
Solutions
We want to test the null hypothesis H 0 : = 100 against the alt hypothesis H 1 : < 100
given = 12, n = 50.
Suppose we reject H0 when x < C.
Thus P (Type I error)
= P (Rejecting H0 when it is true)
=P
X C 100
C 100
<
=P Z<
12
12
n
=F
50
50
C 100
= 0.01
12
50
implies
C 100
= 2.33
12
50
Or C = 100
12
50
2.33 = 96.05
155
Example 6
Suppose that for a given population with = 8.4 in 2 , we want to test the null hypothesis
= 80.0 in 2 against the alternative hypothesis < 80.0 in 2 on the basis of a random
sample of size n = 100.
(a)
If the null hypothesis is rejected for x < 78.0 in 2 and otherwise it is accepted,
what is the probability of type I error?
(b)
= 80.0 in 2
Solution
(a)
null hypothesis H 0 : = 80
Alt hypothesis H 1 : < 80
Given = 8.4, n = 100
P (Type I error) = P (Rejecting H0 when it is true)
=P
X 78.0 80.0
10
<
= P Z < 1
8 .4
4 .2
n
= 1 P Z <
100
10
= 1 F (2.38)
4 .2
=1-0.9913 =.0087
(b)
In this case we define the type I error as the max prob of rejecting H0 when it is
156
=P
<
78.0
10
(78 )
=P Z<
8 .4
8 .4
100
= F (1.19(78 ))
We note that cdf of Z, viz F(z) is an increasing function of Z. Thus when
80, F (1.19(78 )) is largest when is smallest i.e. = 80. Hence P (Type I
error)
= Max F (1.19(78 )) = F (1.19 (78 80 ))
80
= 0.0087
Example 7
If the null hypothesis = 0 is to be tested against the one-sided alternative hypothesis
< 0 (or > 0 ) and if the prob of Type I error is to be and the prob of Type II
error is to be when = 1 , it can be shown that this is possible when the required
sample size is
2 (Z + Z )
n=
(1 0 )2
157
sample must we take if is to be 0.05 and is to be 0.01 for = 61? Also for
what values of x will the null hypothesis have to be rejected?
Solution
(a) Hence = 0.05 , = 0.12 0 = 40, 1 = 38, = 4
Z = Z 0.05 = 1.645, Z = Z 0.12 = 1.175
16(1.645 + 1.175)
(38 40)2
= 31.89 n 32.
= 91.01 n 92
We reject H 0 if Z < Z ie
X 64
< 1.645 or X < 62.76
7 .2
92
X 0
has a tS
n
distribution with (n-1) degrees of freedom. Thus to test the null hypothesis H 0 : = 0
against the alternative hypothesis H 1 : > 0 , we note that when H 0 is true, (ie) when
= 0 , P(t > t n 1, ) =
Thus if we reject the null hypothesis when t > t n 1, (ie) when X > 0 + t n 1,
shall be committing a type I error with prob .
158
S
n
we
The corresponding tests when the alternative hypothesis is < 0 (& 0 ) are
described below.
< 0
t < t n 1,
> 0
t > t n 1,
t=
t < t n 1, or
2
t > t n 1,
X 0
(n sample size)
s
n
Example 8
A random sample of six steel beams has a mean compressive strength of 58,392 psi
(pounds per square inch) with a s.d. of 648 psi. Use this information and the level of
significance = 0.05 to test whether the true average compressive strength of the steel
from which this sample came is 58,000 psi. Assume normality.
Solution
1. Null Hypothesis = 0 = 58,000
Alt hypothesis > 58,000 (why!)
X 0 58,392 58,000
=
S
648
n
.6
= 1.48
5. Decision
= 1.48 2.015
t=
Since
t observed
we cannot reject the null hypothesis. That is we can say the true average compressive
strength is 58,000 psi.
Example 9
Test runs with six models of an experimental engine showed that they operated for
24,28,21,23,32 and 22 minutes with a gallon of a certain kind of fuel. If the prob of type I
error is to be at most 0.01, is this evidence against a hypothesis that on the average this
kind of engine will operate for at least 29 minutes per gallon with this kind of fuel?
Assume normality.
Solution
1. Null hypothesis H 0 : 0 = 29
Alt hypothesis: H 1 : < 0
2. Level of significance = 0.01
3. Criterion : Reject the null hypothesis if t < t n 1, = t 5, 0.01 = 3.365 (Note n = 6 )
X 0
S
n
4. Calculations
24 + 28 + 21 + 23 + 32 + 22
X=
= 25
6
where t =
160
S2 =
1
(24 25)2 + (28 25)2 + (21 25)2 + (23 25)2 + (32 25)2 + (22 25)2
6 1
= 17.6
t =
25 29
17.6
= 2.34
5. Decision
Since t obs = 2.34 3.365 , we cannot reject the null hypothesis. That is we can
say that this kind of engine will operate for at least 29 minute per gallon with this
kind of fuel.
Example 10
A random sample from a companys very extensive files shows that orders for a certain
piece of machinery were filled, respectively in 10,12,19,14,15,18,11 and 13 days. Use the
level of significance = 0.01 to test the claim that on the average such orders are filled
in 10.5 days. Choose the alternative hypothesis so that rejection of the null hypothesis.
= 10.5 indicates that it takes longer than indicated. Assume normality.
Solution
1.
X=
10 + 12 + 19 + 14 + 15 + 18 + 11 + 13
=14
8
161
S2 =
= 10.29
14 10.5
t =
= 3.09
10.29
8
5. Decision
Since t observed = 3.09 > 2.998 , we have to reject the null hypothesis .That is we can
say on the average, such orders are filled in more than 10.5 days.
Example 11
Tests performed with a random sample of 40 diesel engines produced by a large
manufacturer show that they have a mean thermal efficiency of 31.4% with a sd of 1.6%.
At the 0.01 level of significance, test the null hypothesis = 32.3% against the
alternative hypothesis
32.3%
Solution
1. Null hypothesis = 0 = 32.3
Alt hypothesis 32.3
2. Level of significance = 0.01
3. Criterion : Reject H 0 if < t n 1, or t n 1, (ie) if t < t 39, 0.005 or t 39, 0.005 .
2
Example 12
In 64 randomly selected hours of production, the mean and the s.d. of the number of
acceptable pieces produced by an automatic stamping machine are
X = 1,038 and S = 146. At the 0.05 level of significance, does this enable us to reject the
null hypothesis = 1000 against the alt hypothesis > 1000 ?
Solution
1. The null hypothesis H 0 : = 0 = 1000
Alt hypothesis H 1 : > 1000
2. Level of significance = 0.05
3. Criterion : Reject H 0 if t > t n 1, = t 641, 0.05
Now t 63, 0.05 Z 0.05 = 1.645
Thus we reject H 0 if t > 1.645
4. Calculations: t =
X 0 1,038 1,000
=
= 2.082
S
146
n
64
163
Var (X ) = 1,
12
, we can show:
1 2
Theorem: (a) If the regression of Y on X is linear, then
E(Y|x) = 2 +
2
(x -1)
1
1
(y -2)
2
squares. The method of least squares says that choose constants a and b for which the
sum of the squares of the vertical deviations of the sample points (xi, yi) from the line y
= a+bx is a minimum. I.e. find a, b so that T =
n
i =1
i =1
i =1
n
i =1
n
i =1
xi )b =
xi )a + (
n
i =1
n
i =1
yi
xi2 )b = (
n(
Solving we get
b=
n
i =1
n
i =1
xi y i )
xi y i ) (
n(
n
i =1
n
i =1
x )(
2
i
xi ) (
n
i =1
n
i =1
xi )
yi )
(
; a=
i =1
yi ) (
n
n
i =1
xi ) b
.
These constants a and b are used to estimate the unknown regression coefficients , .
Now if x = xg, we predict y as yg = a + bxg.
Problem 1.
Various doses of a poisonous substance were given to groups of 25 mice and the
following results were observed:
Dose (mg)
x
4
6
8
10
12
14
16
Number of deaths
y
1
3
6
8
14
16
20
165
(a) Find the equation of the least squares line fit to these data
(b) Estimate the number of deaths in a group of 25 mice who receive a 7 mg dose of
this poison.
Solution:
(a)
yi = 68
xi2 = 812,
xi yi = 862
Problem 2:
The following are the scores that 12 students obtained in the midterm and final
examinations in a course in Statistics:
Final Examination
y
83
62
76
77
89
74
48
78
76
51
73
89
166
Solution:
(a) n = number of sample pairs (xi, yi) = 12
xi = 854,
yi = 876
xi2 = 64222,
xi yi = 64346
Correlation
If X, Y are two random variables, the correlation coefficient, , between X and Y is
defined as
=
cov ( X , Y )
Var ( X ) Var (Y )
r=
i =1
n
i =1
( xi x ) ( y i y )
( xi x )
n
i =1
.
( yi y )
where S xx =
S xy =
n
i =1
n
i =1
( xi x ) 2 =
( xi x ) ( y i y ) =
n
i =1
n
i =1
(
xi2
(
xi y i
n
i =1
xi ) 2
n
n
i =1
xi ) (
, S xx =
n
i =1
S xx S yy
n
i =1
( yi y ) 2 =
n
i =1
(
y i2
yi )
Problem 3.
Calculate r for the data { (8, 3), (1, 4), (5, 0), (4, 2), (7, 1) }.
Solution
x = 25/5 = 5. y = 10/5 = 2.
n
i =1
n
i =1
n
i =1
Hence r =
7
(30) (10)
= - 0.404.
168
n
i =1
yi ) 2
n
Problem 4.
The following are the measurements of the air velocity and evaporation coefficient of
burning fuel droplets in an impulse engine:
Air velocity
x
20
60
100
140
180
220
260
300
340
380
Evaporation Coefficient
y
0.18
0.37
0.35
0.78
0.56
0.75
1.18
1.30
1.17
1.65
Solution. S xx =
S xx =
S xy =
( xi x ) 2 =
i =1
n
i =1
( yi y ) 2 =
n
i =1
n
i =1
xi2
i =1
i =1
y i2
( xi x ) ( y i y ) =
xi ) 2
n
n
i =1
n
i =1
yi ) 2
n
(
xi y i
n
i =1
xi ) (
n
i =1
yi )
= 505.4
Hence r =
S xy
S xx S yy
505.4
(132000) (2.13745)
= 0.9515.
**************
169
= 2175.4
(2000) (8.35)
10