Proba
Proba
3-0-0,CRD- 3)
BUDDHANANDA BANERJEE
Contents
1. Preliminary 2
2. Probability : Definition & laws 4
3. Random variable 15
4. Modeling with Random Variables 24
4.1. Examples of discrete random variables: 24
4.2. Examples of continuous random variables: 26
5. Joint and conditional distributions 55
5.1. Laws of expectation 55
6. Law of Large Numbers 64
7. Estimation 71
8. Testing of Hypothesis 80
1. Preliminary
Definition 1. A set Ω is said to be finite if there exists an n ∈ N and
a bijection from Ω onto {1, 2, . . . , n} . An infinite set Ω is said to be
countable if there is a bijection from N onto Ω.
If Ω is an infinite countable set, then using any bijection f : Ω → N,
we can list the elements of Ω as a sequence f (1), f (2), f (3), ... so that
each element of Ω occurs exactly once in the sequence. Conversely, if
you can write the elements of Ω as a sequence, it defines an injective
function from natural numbers onto Ω (send 1 to the first element of
the sequence, 2 to the second element, etc.).
Example 2. The set of integers Z is countable. Define f : N → Z by
!
n/2, if n is even
f (n) =
−(n − 1)/2, if n is odd
It is clear that f maps N into Z. Thus, we have found a bijection
from N onto Z.which shows that Z. is countable. This function is a
formal way of saying the we can list the elements of Z as
(1, 1), (1, 2), (2, 1), (1, 3), (2, 2), (3, 1), (1, 4), (2, 3), (3, 2), (4, 1), ...
Exercise 4. Define a bijection from N onto N × N, and hence show
that N × N is countable.
Example 5. Z × Z is countable.
Example 6. The set of rational numbers Q is countable.
Theorem 7. The set of real numbers R is not countable.
Proof. The extraordinary proof of this fact is due to Cantor, and the
core idea, called the ‘diagonalization argument’ is one that can be used
in many other contexts. !
Consider any function f : N → [0, 1]. We show that it is not onto,
and hence not a bijection. Indeed, use the decimal expansion to write
a number x ∈ [0, 1] as 0.x1 x2 x3 . . . where xi ∈ {0, 1, . . . , 9}. Write
PROBABILITY & STATISTICS(MA20205, LTP- 3-0-0,CRD- 3) 3
the decimal expansion for each of the numbers f (1), f (2), f (3), . . . . as
follows:
f (1) = 0.X1,1 X1,2 X1,3 . . .
f (2) = 0.X2,1 X2,2 X2,3 . . .
f (3) = 0.X3,1 X3,2 X3,3 . . .
······ ··· ···
Let Y1 , Y2 , Y3 , . . . be any numbers in {0, 1, . . . , 9} with the only condi-
tion that Yi ̸= Xi,i . Clearly, it is possible to choose Yi like this. Now,
consider the number y = 0.Y1 Y2 Y3 . . . which is a number in [0, 1]. How-
ever, it does not occur in the above list. Indeed, y disagrees withf (1)
in the first decimal place, disagrees with f (2) in the second decimal
place, etc. Thus, y ̸= f (i) for any i ∈ N which means that f is not
onto [0, 1].
Theorem 8. Thus, no function f : N → [0, 1] is onto, and hence there
is no bijection from N onto [0, 1] and hence [0, 1] is not countable.
Obviously, if there is no onto function onto [0, 1], there cannot be an
onto function onto R. Thus, R is also uncountable.
Example 9. Let A1 , A2 , ... be subsets of a set Ω. Suppose each Ai is
countable (finite is allowed). Then, ∪i Ai is also countable.
PROBABILITY & STATISTICS(MA20205, LTP- 3-0-0,CRD- 3) 4
Exercise 39. There are three drawers in a table. The first drawer
contains two gold coins. The second drawer contains a gold and a
silver coin. The third one contains two silver coins. Now a drawer is
chosen at random and a coin is also chose randomly. It is found that
the a gold coin has been selected then what is the probability that the
second drawer was chosen?
Exercise 40. Let X and Y be the face values of a fair die when rolled
twice independently. Find the probabiliry that X + Y + XY is odd.
√
Exercise 41. Consider the quadratic equation u2 − Y u + X = 0,
where (X, Y ) is a random point chosen uniformly from a unit square.
What is the probability that the equation will have a real root?
Exercise 42. Six distinct balls are placed randomly into three boxes
A, B, C. For each ball the probability of going into a specific box is
1/3. Find the probability that box A will contain at least two balls.
Exercise 43. A circular target of unit radius is divided into four an-
1 1 2
nular zones with radii , , and 1 respectively. If 6 shots are fired
6 2 3
1
and hit inside the disc of radius , find the probability that at least
2
1
one of these hits inside the disc of radius .
6
PROBABILITY & STATISTICS(MA20205, LTP- 3-0-0,CRD- 3) 8
for(i in 1 : itrn){
count [i]<- (x[i]ˆ2+y[i]ˆ2<1) # (X,Y) in circle or not
pi_hat[i]<-4*(sum(count)/i) # How many in cirecle amonge i trials
}
# Plot
plot(pi_hat, type = l)
lines(pi_true, col=2)
4.0
3.8
3.6
pi_hat
3.4
3.2
3.0
2.8
Index
PROBABILITY & STATISTICS(MA20205, LTP- 3-0-0,CRD- 3) 11
1.0
0.8
0.6
Y
0.4
0.2
X
PROBABILITY & STATISTICS(MA20205, LTP- 3-0-0,CRD- 3) 12
# e estimation
# # Date:26 July 2019
a1<-1
b1<-2
a2<-0
b2<-1
itrn<- 10000
x<-runif(itrn,a1,b1)
y<-runif(itrn,a2,b2)
e_true<-rep(exp(1),itrn)
e_hat<-array(0,dim=c(itrn))
count<-array(0,dim=c(itrn))
xx<-seq(a1,b1,by=0.01)
for(i in 1 : itrn){
count [i]<- (x[i]*y[i]<1)
area<-(sum(count)/i)
e_hat[i]<- 2ˆ(1/area)
}
plot(e_hat, type = l)
lines(e_true, col=2)
s0<- which (count==0)
s1<- which (count==1)
plot(y[s1]˜x[s1], col=2, pch = 20, cex = 0.5, xlab="X", ylab = "Y")
lines (y[s0]˜x[s0], type=p, pch = 20, cex = 0.5)
lines((1/(xx))˜xx , col=3, lwd=4)
PROBABILITY & STATISTICS(MA20205, LTP- 3-0-0,CRD- 3) 13
4.0
3.5
e_hat
3.0
2.5
2.0
Index
PROBABILITY & STATISTICS(MA20205, LTP- 3-0-0,CRD- 3) 14
1.0
0.8
0.6
Y
0.4
0.2
0.0
X
PROBABILITY & STATISTICS(MA20205, LTP- 3-0-0,CRD- 3) 15
3. Random variable
• Primary data : Primary data is a type of data that is collected
by researchers directly from main sources through interviews,
surveys, experiments, etc.
• Secondary data: Using existing data generated/collected by
large government Institutions, healthcare facilities, research group
etc. as part of organizational record keeping. The data is then
extracted from more varied datafiles.
Categorical Data
Nominal: : Categories with names only, without ordering
Ordinal: : Categories with names and ordering
Numerical Data
Countable/discrte: : Values from integers (Z) or a function of
it
Continuous[uninterrupted]: : Values from intervals (a, b), (a, b], [a, b), [a, b], (−∞, a], [b, ∞
etc .
:
PROBABILITY & STATISTICS(MA20205, LTP- 3-0-0,CRD- 3) 16
$ x
d d
f (x) = F (x) = f (t)dt.
dx dx −∞
Exercise 63. Find the expectation of the random variables with the
following densities
(a) f (x) = π(1+x
1
2 ) when x ∈ R
"
• Mean of random variable X is µ1 = E(X) = x xf (x)" = µx .
′
∞ k
# t E(X k )
MX (t) = E(etx ) =
k=0
k!
Then one can obtain the kth order raw moment from m.g.f. by
∂k ′
k
MX (t)|t=0 = µk
∂t
Exercise 71. Prove the following inequalities:
E(X)
P (X > t) ≤ ∀t > 0
t
Bound in variance
6
5
4
pi_hat
3
2
1
0
Index
1 1
(X ≤ m) ≥ and (X ≥ m) ≥
2 2
and for a continuous probability distribution,
1
(X ≤ m) = = (X ≥ m) .
2
"
Exercise 73. Graphically show that g(a) = n1 ni=1 |xi −a| is minimum
if a = median of {x1 , · · · , xn }. Observe that median need not be
unique.
PROBABILITY & STATISTICS(MA20205, LTP- 3-0-0,CRD- 3) 22