Unit 1 Random Variables - MA241T
Unit 1 Random Variables - MA241T
Prerequisites:
If an experiment is repeated under essentially homogeneous and similar conditions one
generally comes across two types of situations:
(i) The result or what is usually known as the 'outcome' is unique or certain.
(ii) The result is not unique but may be one of the several possible outcomes.
The phenomena covered by (i) are known as 'deterministic' or 'predictable' phenomena. By a
deterministic phenomenon the result can be predicted with certainty.
For example:
(a) The velocity 'v' of a particle after time 't ' is given by v = u + at where ‘u’ is the initial velocity
and ‘a’ is the acceleration. This equation uniquely determines ‘v’ if the right-hand quantities
are known.
(b) Ohm’s Law , viz., C = E/R where C is the flow of current, E the potential difference between
the two ends of the conductor and R the resistance, uniquely determines the value C as soon
as E and R are given.
A deterministic model is defined as a model which stipulates that the conditions under which
an experiment is performed to determine the outcome of the experiment. For a number of
situations the deterministic model suffices. However, there are phenomena (as covered by (ii)
above) which do not lend themselves to deterministic approach and are known as
'unpredictable' or 'probabilistic' phenomena. For example:
(a) In tossing of a coin one is not sure if a head or tail will be obtained.
(b) If a light tube has lasted for t hours, nothing can be said about its further life. It may fail to
function any moment.
In such cases chance or probability comes into picture which is taken to be a quantitative
measure of uncertainty.
Since the number of cases favourable to the 'non-happening' of the event E are (𝑛 − 𝑚), the
probability '𝑞' that 𝐸 will not happen is given by
𝑛−𝑚 𝑚
𝑞= = 1 − = 1 − 𝑝 gives 𝑝 + 𝑞 = 1
𝑛 𝑛
Obviously p as well as q are non-negative and cannot exceed unity, i.e,
0 ≤ 𝑝 ≤ 1, 0 ≤ 𝑞 ≤ 1 .
Statistical or Empirical Probability: If a trial is repeated a number of times under
essentially homogeneous and identical conditions, then the limiting value of the ratio of the
number of times the event happens to the number of trials, as the number of trials become
indefinitely large, is called the probability of happening of the event. (It is assumed that the
limit is finite and unique).
Symbolically, if in n trials an event E happens m times, then the probability 'p' of the
𝑚
happening of E is given by 𝑝 = 𝑃(𝐸) = lim .
𝑛→∞ 𝑛
Axiomatic Probability: Let 𝐴 be any event in the sample space 𝑆, then 𝑃(𝐴) is called the
probability of event 𝐴, if the following axioms are satisfied.
Axiom 1: 𝑃(𝐴) ≥ 0
Axiom 2: 𝑃(𝑆) = 1, S being the sure event
Axiom 3: For two mutually exclusive events 𝐴 & 𝐵, 𝑃(𝐴 ∪ 𝐵) = 𝑃(𝐴) + 𝑃(𝐵)
Random variable
Random variable is a real number X connected with the outcome of a random experiment E.
For example, if E consists of three tosses of a coin, one can consider the random variable
which is the number of heads (0, 1, 2 or 3).
Let S denote the sample space of a random experiment. A random variable means it is a rule
which assigns a numerical value to each and every outcome of the experiment. Thus, random
variable is a function X (ω) with domain S and range (-∞, ∞) such that for every real number
a, the event [ω: X (ω) ≤ a ] ϵ B the field of subsets in S. It is denoted as f: S → R.
Note that all the outcomes of the experiment are associated with a unique number. Therefore,
f is an example of a random variable. Usually, a random variable is denoted by letters such as
X, Y, Z etc. The image set of the random variable may be written as f(S) = {0, 1, 2, 3}.
There are two types of random variables. They are;
1. Discrete Random Variable (DRV)
Fourth Semester 4 Probability theory and Linear Programming (MA241T)
2. Continuous Random Variable (CRV).
Discrete Random Variable: A discrete random variable is one which takes only a countable
number of distinct values such as 0, 1, 2, 3, … . Discrete random variables are usually (but
not necessarily) counts. If a random variable takes at most a countable number of values, it is
called a discrete random variable. In other words, a real valued function defined on a
discrete sample space is called a discrete random variable.
Examples of Discrete Random Variable:
(i) In the experiment of throwing a die, define X as the number that is obtained. Then X takes
any of the values 1 – 6. Thus, X(S) = {1, 2, 3…6} which is a finite set and hence X is a DRV.
(ii) If X be the random variable denoting the number of marks scored by a student in a subject of
an examination, then X(S) = {0, 1, 2, 3…100}. Then, X is a DRV.
(iii) The number of children in a family is a DRV.
(iv) The number of defective light bulbs in a box of ten is a DRV.
Probability Mass Function: Suppose X is a one-dimensional discrete random variable
taking at most a countably infinite number of values x1, x2, …. With each possible outcome
xi, one can associate a number pi = P(X = xi) = p(xi), called the probability of xi.
The numbers p(xi); i = 1, 2, … must satisfy the following conditions:
(i) 𝑝(𝑥𝑖 ) ≥ 0 ∀ 𝑖 ,
(ii) ∑∞
𝑖=1 𝑝(𝑥𝑖 ) = 1 .
This function 𝑝 is called the probability mass function of the random variable X and the
set {𝑥𝑖 , 𝑝(𝑥𝑖 )} is called the probability distribution of the random variable X.
Remarks:
1. The set of values which X takes is called the spectrum of the random variable.
2. For discrete random variable, knowledge of the probability mass function enables us to
compute probabilities of arbitrary events. In fact, if E is a set of real numbers, (𝑋 ∈ 𝐸) =
∑𝑥∈𝐸∩𝑆 𝑝(𝑥) , where S is the sample space.
Discrete Distribution Function: For the random variable 𝑋 = {𝑥1 , 𝑥2 , 𝑥3 , … }. The
cumulative distribution function is given by 𝐹(𝑥) = 𝑃(𝑋 ≤ 𝑥) = ∑𝑥𝑖 ≤𝑥 𝑝 (𝑥𝑖 ) .
Mean/Expected Value, Variance and Standard Deviation of DRV:
The mean or expected value of a DRV X is defined as
𝐸(𝑋) = 𝜇 = ∑ 𝑥𝑖 𝑃(𝑋 = 𝑥𝑖 ) = ∑ 𝑝(𝑥𝑖 )𝑥𝑖 .
The variance of a DRV X is defined as
𝑉𝑎𝑟 (𝑋) = 𝜎 2 = ∑ 𝑃(𝑋 = 𝑥𝑖 ) (𝑥𝑖 − 𝜇)2 = ∑ 𝑝𝑖 (𝑥𝑖 − 𝜇)2 = ∑ 𝑝𝑖 (𝑥𝑖2 − 𝜇 2 ) .
The standard deviation of DRV X is defined as
Probability Density Function: The probability density function (p.d.f) of a random variable
X usually denoted by 𝑓𝑥 (𝑥) or simply by 𝑓(𝑥) has the following obvious properties:
i) 𝑓(𝑥) ≥ 0, −∞ < 𝑥 < ∞
∞
ii) ∫−∞ 𝑓(𝑥)𝑑𝑥 = 1
iii) The probability 𝑃(𝐸) given by 𝑃(𝐸) = ∫ 𝑓(𝑥)𝑑𝑥 is well defined for any event E.
If f (x) is the p.d.f of x, then the probability that x belongs to A, where A is some interval (a,
b) is given by the integral of f (x) over that interval.
𝑏
i.e., 𝑃(𝑋 ∈ 𝐴) = ∫𝑎 𝑓(𝑥)𝑑𝑥
Cumulative Density Function: Cumulative density function of a continuous random
𝑥
variable is defined as 𝐹(𝑥) = ∫−∞ 𝑓(𝑡)𝑑𝑡 for − ∞ < 𝑥 < ∞ .
Mean/Expectation, Variance and Standard deviation of CRV:
∞
The mean or expected value of a CRV X is defined as 𝜇 = 𝐸(𝑋) = ∫−∞ 𝑥 𝑓(𝑥)𝑑𝑥
∞
The variance of a CRV X is defined as 𝑉𝑎𝑟(𝑋) = 𝜎 2 = ∫−∞ 𝑥 2 𝑓(𝑥)𝑑𝑥 − 𝜇 2
Examples:
1. The probability density function of a discrete random variable X is given below:
x 0 1 2 3 4 5 6
P(X = x) = f(x) K 3k 5k 7k 9k 11k 13k
Find (i) k; (ii) F (4); (iii) 𝑃(𝑋 ≥ 5); (iv) 𝑃(2 ≤ 𝑋 < 5); (v) E(X) and (vi) Var (X).
Solution: To find the value of k, consider the sum of all the probabilities which equals to
49k. Equating this to 1, k = 1/49. Therefore, distribution of X may now be written as
x 0 1 2 3 4 5 6
P(X = x) = f(x) 1/49 3/49 5/49 7/49 9/49 11/49 13/49
25
𝐹(4) = 𝑃[𝑋 ≤ 4] = 𝑃[𝑋 = 0] + 𝑃[𝑋 = 1] + 𝑃[𝑋 = 2] + 𝑃[𝑋 = 3] + 𝑃[𝑋 = 4] = 49 .
24
𝑃[𝑋 ≥ 5] = 𝑃[𝑋 = 5] + 𝑃[𝑋 = 6] = .
49
21
𝑃[2 ≤ 𝑋 < 5] = 𝑃[𝑋 = 2] + 𝑃[𝑋 = 3] + 𝑃[𝑋 = 4] = .
49
Next to find E(X), consider
203
𝐸(𝑋) = ∑ 𝑥𝑖 ∗ 𝑓( 𝑥𝑖 ) = .
49
𝑖
X -2 -1 0 1 2 3
f (xi) 0.1 0.1 0.2 0.2 0.3 0.1
(32)(17
0) 3
𝑓(2) = 𝑃(𝑋 = 2) = (20
= 190.
2)
4. If a car agency sells 50% of its inventory of a certain foreign car equipped with side
airbags, find a formula for the probability distribution of the number of cars with side airbags
among the next 4 cars sold by the agency.
Solution: Since the probability of selling an automobile with side airbags is 0.5, the 24 = 16
points in the sample space are equally likely to occur. Therefore, the denominator for all
probabilities, and also for our function, is 16. To obtain the number of ways of selling 3 cars
with side airbags, it is required to consider the number of ways of partitioning 4 outcomes
selling x models with side airbags and 4 - x models without side airbags can occur in (𝑥4)
ways, where x can be 0, 1, 2, 3, or 4. Thus, the probability distribution f(x) = P(X = x) is
1
𝑓(𝑥) = (16 ) (𝑥4) 𝑓𝑜𝑟 𝑥 = 0,1,2,3,4.
5. The diameter of an electric cable, say X, is assumed to be a continuous random variable
6𝑥(1 − 𝑥) 0≤𝑥≤1
with p.d.f 𝑓(𝑥) = {
0 otherwise
(i) Check that above is p.d.f.
2
(ii) Find 𝑃 (3 < 𝑥 < 1)
(iii) Determine a number b such that 𝑃(𝑋 < 𝑏) = 𝑃(𝑋 > 𝑏).
Solution: (i) 𝑓(𝑥) ≥ 0 in the given interval.
∞ 0 1 ∞
∫ 𝑓(𝑥)𝑑𝑥 = ∫ 𝑓(𝑥)𝑑𝑥 + ∫ 𝑓(𝑥)𝑑𝑥 + ∫ 𝑓(𝑥)𝑑𝑥
−∞ −∞ 0 1
1
= 0 + ∫0 6𝑥(1 − 𝑥) 𝑑𝑥 + 0
6𝑥 2 6𝑥 3
={ − } by putting limits x = 0 to 1
2 3
=1
2 1 1 7
(ii) 𝑃 (3 < 𝑥 < 1) = ∫2/3 𝑓(𝑥)𝑑𝑥 = ∫2/3(6𝑥 − 6𝑥 2 )𝑑𝑥 = 27 .
3𝑏 2 − 2𝑏 3 = [1 − 3𝑏 2 + 2𝑏 3 ]
4𝑏 3 − 6𝑏 2 + 1 = 0
(2𝑏 − 1)(2𝑏 2 − 2𝑏 − 1) = 0
From this b = ½ is the only real value lying between 0 and 1 and satisfying the given
condition.
6. Suppose that the error in the reaction temperature, in ◦C, for a controlled laboratory
experiment is a continuous random variable X having the probability density function
7. The length of time (in minutes) that a certain lady speaks on telephone is found to be a
−𝑥
8. Suppose X is a continuous random variable with the following probability density function
𝑓(𝑥) = 3𝑥 2 for 0 < 𝑥 < 1 . Find the mean and variance of X.
∞
Solution: Mean = 𝜇 = ∫−∞ 𝑥𝑓(𝑥)𝑑𝑥
0 1 ∞
= ∫−∞ 𝑥𝑓(𝑥)𝑑𝑥 + ∫0 𝑥𝑓(𝑥)𝑑𝑥 + ∫1 𝑥𝑓(𝑥)𝑑𝑥
1 1 3
= 0 + ∫0 𝑥 ∗ 3𝑥 2 𝑑𝑥 + 0 = ∫0 3𝑥 3 𝑑𝑥 = .
4
∞
Variance = 𝜎 2 = ∫−∞ 𝑥 2 𝑓(𝑥)𝑑𝑥 − 𝜇 2
1
= ∫0 𝑥 2 𝑓(𝑥)𝑑𝑥 − 𝜇 2
1 3 2
= ∫0 𝑥 2 ∗ 3𝑥 2 𝑑𝑥 − (4)
Exercise:
1. Two cards are drawn randomly, simultaneously from a well shuffled deck of 52 cards. Find
the variance for the number of aces.
1 2 𝑥
2. If X is a discrete random variable taking values 1,2,3,… with 𝑃(𝑥) = 2
(3) . Find P(X being
1
7. Find the mean and variance of the probability density function 𝑓(𝑥) = 2 𝑒 −|𝑥|
JOINT PROBABILITY
Y
𝑦1 𝑦1 … 𝑦𝑗 … 𝑦𝑚 ∑ 𝑦𝑖
X 𝑖
The functions 𝑓 and 𝑔 on the right side and the bottom side, respectively, of the joint
distribution table are defined by
𝑓(𝑥𝑖 ) = ∑𝑗 ℎ(𝑥𝑖 , 𝑦𝑗 ) and 𝑔(𝑦𝑗 ) = ∑𝑗 ℎ(𝑥𝑖 , 𝑦𝑗 ).
That is, 𝑓(𝑥𝑖 ) is the sum of the entries in the 𝑖 𝑡ℎ row and 𝑔(𝑦𝑗 ) is the sum of the entries in the
𝑗 𝑡ℎ column. They are called the marginal distributions of X and Y, respectively.
𝑐𝑜𝑣(𝑋, 𝑌) = ∑ 𝑥𝑖 𝑦𝑗 ℎ(𝑥𝑖 , 𝑦𝑗 ) − 𝜇𝑋 𝜇𝑌
𝑖,𝑗
where 𝐴 and 𝐵 are now the events defined by 𝑋 = 𝑥 and 𝑌 = 𝑦, respectively, then
𝑃(𝑋=𝑥,𝑌=𝑦) ℎ(𝑥,𝑦)
𝑃(𝑌 = 𝑦|𝑋 = 𝑥) = = , provided 𝑓(𝑥) > 0,
𝑃(𝑋=𝑥) 𝑓(𝑥)
Problem 1. A coin is tossed three times. Let 𝑋 be equal to 0 or 1 according as a head or a tail
occurs on the first toss. Let 𝑌 be equal to the total number of heads which occurs. Determine
(i) the marginal distributions of 𝑋 and 𝑌, and (ii) the joint distribution of 𝑋 and 𝑌, (iii)
expected values of 𝑋, 𝑌, 𝑋 + 𝑌 and 𝑋𝑌, (iv) 𝜎𝑋 and 𝜎𝑌 , (v) 𝐶𝑜𝑣(𝑋, 𝑌) and 𝜌(𝑋, 𝑌).
Solution: Here the sample space is given by
𝑆 = {𝐻𝐻𝐻, 𝐻𝐻𝑇, 𝐻𝑇𝐻, 𝐻𝑇𝑇, 𝑇𝐻𝐻, 𝑇𝐻𝑇, 𝑇𝑇𝐻, 𝑇𝑇𝑇}
(i) The distribution of the random variable 𝑋 is given by the following table
X 0 1
(First toss Head or Tail) (First toss Head) (First toss Tail)
P(X) 4 4
(Probability of random variable X) 8 8
(ii) The joint distribution of the random variables 𝑋and 𝑌 is given by the following table
Y 0 1 2 3
X (zero Heads) (one Head) (two Head) (three Head)
1 3 3 1 12
=0× +1× +2× +3× =
8 8 8 8 8
E[X + Y] = ∑ ∑ Pij (xi + yj )
= P11 (x1 + y1 ) + P12 (x1 + y2 ) + P13 (x1 + y3 ) + P14 (x1 + y4 ) + P21 (x2 + y1 )
+ P22 (x2 + y2 ) + P23 (x2 + y3 ) + P24 (x2 + y4 )
1 2 2 1 16
= 0(0 + 0) + (0 + 1) + (0 + 2) + (1 + 1) + (1 + 2) + 0(1 + 3) =
8 8 8 8 8
= 2.
= P11 (x1 y1 ) + P12 (x1 y2 ) + P13 (x1 y3 ) + P14 (x1 y4 ) + P21 (x2 y1 ) + P22 (x2 y2 )
+ P23 (x2 y3 ) + P24 (x2 y4 )
1 2 2 1
= 0(0 × 0) + (0 × 1) + (0 × 2) + (1 × 1) + (1 × 2) + 0(1 × 3) = 2.
8 8 8 8
4 4
(iv) σ2X = E[X 2 ] − μ2X = ∑ xi2 P(xi ) − [E(X)]2 = x12 P(x1 ) + x22 P(x2 ) = 02 × + 12 × −
8 8
4 2 1
(8) = 4
= ∑ yi2 P(yi ) − [E(Y)]2 = y12 P(y1 ) + y22 P(y2 ) + y32 P(y3 ) + +y42 P(y4 )
1 3 3 1 2 2 3
= 02 × + 12 × + 22 × +32 × − ( ) =
8 8 8 8 8 4
1 1 3 1
(v) Cov(X, Y) = E(XY) − μX μY = − × = −
2 2 2 4
Cov(X,Y) −1/4 1
ρ(X, Y) = = (1/2)( =− .
σX σY √3/2) √3
Problem 2: The joint distribution of two random variables X and Y is given by the following
table:
∑ ∑ ℎ𝑖𝑗= ∑ ∑ ℎ = 𝑘 ∑ ∑(𝑖 + 𝑗 )
𝑖 𝑗 𝑖=1 𝑗=1 𝑖=1 𝑗=1
4 4
𝑖+2
𝑓𝑖 = ∑𝑗 ℎ𝑖𝑗 = ∑3𝑗=1 ℎ𝑖𝑗 =𝑘 ∑3𝑗=1(𝑖 + 𝑗 ) =
18
2 𝑗 +5
𝑔𝑗 = ∑𝑖 ℎ𝑖𝑗 = ∑4𝑗=1 ℎ𝑖𝑗 =𝑘 ∑3𝑗=1(𝑖 + 𝑗 ) =
27
1 1 1
𝜇𝑌 = ∑ 𝑦 𝑗 𝑃(𝑦 𝑗 ) = (1 × ) + (3 × ) + (9 × ) = 3
2 3 6
E[𝑋𝑌] = ∑𝑖 ∑𝑗 ℎ𝑖𝑗 𝑥 𝑖 𝑥 𝑗
= (ℎ11 𝑥1 𝑦1 + ℎ12 𝑥1 𝑦2 + ℎ13 𝑥1 𝑦3 ) + (ℎ21 𝑥2 𝑦1 + ℎ22 𝑥2 𝑦2 + ℎ23 𝑥2 𝑦3 )
+(ℎ31 𝑥3 𝑦1 + ℎ32 𝑥3 𝑦2 + ℎ31 𝑥3 𝑦3 )
1 1 1 1 1 1
= (2 × 8) + (6 × 24) + (18 × 12) + (4 × 4) + (12 × 4) + 36 × 0 + (6 × 8) +
1 1
(18 × 24) + (54 × 12)
= 2 + 4 + 6 = 12
𝐶𝑜𝑣 (𝑋, 𝑌) = 𝐸[𝑋𝑌] − 𝜇𝑋 𝜇𝑌 = 12 − 12 = 0
𝜌(𝑋, 𝑌) = 0.
1
ℎ(4,3) ℎ22 4 3
𝑃(𝑋 = 4|𝑌 = 3) = = = 1 =
𝑔(3) 𝑔2 4
3
Problems to practice:
1) The joint probability distribution of two random variables X and Y is given by the
following table.
Y 5
-2 -1 4
X
1 0.1 0.2 0 0.3
2 0.2 0.1 0.1 0
(a) Find the marginal distribution of 𝑋 and 𝑌, and evaluate 𝑐𝑜𝑣(𝑋, 𝑌).
(b) Also determine whether 𝜇𝑋 and 𝜇𝑌 .
(c) Find 𝑃(𝑌 = −1|𝑋 = 1) and 𝑃(𝑋 = 2|𝑌 = 4)
2) Two textbooks are selected at random from a shelf containing three statistics texts,
two mathematics texts and three engineering texts. Denoting the number of books
selected in each subject by S, M and E respectively, find (a) the joint distribution of S
and M, (b) the marginal distributions of S, M and E, and (c) Find the correlation of the
random variables S and M.
3) Consider an experiment that consists of 2 throws of a fair die. Let 𝑋 be the number of
4s and 𝑌 be the number of 5s obtained in the two throws. Find the joint probability
distribution of 𝑋 and 𝑌. Also evaluate 𝑃(2𝑋 + 𝑌 < 3).
where ℎ(𝑥, 𝑦) is the joint density function of 𝑋 and 𝑌, ℎ1 (𝑥) is the marginal density
function of 𝑋.
𝑃(𝑎 < 𝑋 < 𝑏, 𝑐 < 𝑌 < 𝑑)
𝑃(𝑐 < 𝑌 < 𝑑|𝑎 < 𝑥 < 𝑏) =
𝑃(𝑎 < 𝑥 < 𝑏)
Next,
∞
ℎ2 (𝑦) = ∫ ℎ(𝑥, 𝑦) 𝑑𝑥, 𝑦 > 0
−∞
2 −𝑦 1 2 −𝑦 22 1
= 𝑒 ∫ (𝑥 + 1) 𝑑𝑥 = 𝑒 { − }
3 0 3 2 2
= 𝑒 −𝑦 , 𝑦 > 0.
Therefore, ℎ1 (𝑥)ℎ2 (𝑦) = ℎ(𝑥, 𝑦) and hence 𝑥 and 𝑦 are stochastically independent.
Problem 7: The life time 𝑥 and brightness 𝑦 of a light bulb are modeled as continuous
random variables with joint density function
ℎ(𝑥, 𝑦) = 𝛼𝛽𝑒 −(𝛼 𝑥+ 𝛽𝑦) , 0 < 𝑥 < ∞, 0 < 𝑦 < ∞.
Where 𝛼 and 𝛽 are appropriate constants. Find (i) the marginal density functions of 𝑥 and 𝑦,
and (ii) the compound cumulative distributive function.
Solution: For the given distribution, the marginal density function of 𝑥 is
∞ ∞
ℎ1 (𝑥) = ∫ ℎ(𝑥, 𝑦) 𝑑𝑦 = ℎ1 (𝑥) = ∫ 𝛼𝛽𝑒 −(𝛼 𝑥+ 𝛽𝑦) 𝑑𝑦
−∞ 0
∞
= 𝛼𝛽 𝑒 −𝛼𝑥 ∫0 𝑒 −𝛽𝑦 𝑑𝑦 = 𝛼 𝑒 −𝛼𝑥 , 0 < 𝑥 < ∞
1 1
= 𝛼𝛽 { (1 − 𝑒 −𝛼 𝑢 )} { (1 − 𝑒 −𝛽 𝑣 )}
𝛼 𝛽
= (1 − 𝑒 −𝛼 𝑢 )(1 − 𝑒 −𝛽 𝑣 ), 0 < 𝑢 < ∞, 0 < 𝑣 < ∞.
Problem 8: The joint probability density function of two random variables 𝑥 and 𝑦 is given
2, 0 < 𝑥 < 𝑦 < 1
by h(x, y) = {
0, 𝑒𝑙𝑠𝑒𝑤ℎ𝑒𝑟𝑒
(i) Find the covariance between 𝑥 and 𝑦.
Solution: The marginal density function of 𝑥 is
1
∞
ℎ1 (𝑥) = ∫ ℎ(𝑥, 𝑦) 𝑑𝑦 = {∫𝑥 2 𝑑𝑦 = 2(1 − 𝑥), 0 < 𝑥 < 1
−∞
0 𝑒𝑙𝑠𝑒𝑤ℎ𝑒𝑟𝑒
The marginal density function of 𝑦 is
𝑦
∞
∫ 2 𝑑𝑥 = 2𝑦, 0<𝑦<1
ℎ2 (𝑦) = ∫ ℎ(𝑥, 𝑦) 𝑑𝑥 = { 0
−∞
0 𝑒𝑙𝑠𝑒𝑤ℎ𝑒𝑟𝑒
∞ 1
E[x] = ∫ 𝑥 ℎ1 (𝑥)𝑑𝑥 = ∫ 𝑥{2 (1 − 𝑥)} 𝑑𝑥
−∞ 0
1
1 1 1
= 2 ∫ (𝑥 − 𝑥 2 ) 𝑑𝑥 = 2 ( − ) = ,
0 2 3 3
∞ 1
2
E[y] = ∫ 𝑦 ℎ2 (𝑦)𝑑𝑦 = ∫ 𝑦(2𝑦)𝑑𝑦 = ,
−∞ 0 3
∞ ∞ 1 𝑦 1 1
E[xy] = ∫−∞ ∫−∞ 𝑥𝑦 ℎ(𝑥, 𝑦) 𝑑𝑥 𝑑𝑦 = ∫0 2𝑦 {∫0 𝑥 𝑑𝑥} 𝑑𝑦 = ∫0 𝑦 3 dy = 4 .
Therefore,
1 1 2 1
𝐶𝑜𝑣 (𝑥, 𝑦) = 𝐸[𝑥𝑦] − 𝐸[𝑥]𝐸[𝑦] = − . = .
4 3 3 36
𝑒 −(𝑥+𝑦) , 𝑥 ≥ 0, 𝑦 ≥ 0
Problem 9: Verify that f (x, y) = { is a density function of a joint
0, 𝑒𝑙𝑠𝑒𝑤ℎ𝑒𝑟𝑒
probability distribution. Then evaluate the following:
∞ ∞ ∞ ∞ ∞ ∞
𝑓(𝑥, 𝑦) = ∫ ∫ 𝑓(𝑥, 𝑦)𝑑𝑥 𝑑𝑦 = ∫ ∫ 𝑒 −(𝑥+𝑦) 𝑑𝑥 𝑑𝑦 = ∫ 𝑒 −𝑥 𝑑𝑥 ∫ 𝑒 −𝑦 𝑑𝑦
−∞ −∞ −∞ −∞ −∞ 0
= (0 + 1)(0 + 1) = 1.
Therefore, 𝑓(𝑥, 𝑦) is a density function.
1 2 4 2 4
(i) 𝑃 ( < 𝑥 < 2, 0 < 𝑦 < 4) = ∫1/2 ∫0 𝑓(𝑥, 𝑦) 𝑑𝑦 𝑑𝑥 = ∫1/2 ∫0 𝑒 −(𝑥+𝑦) 𝑑𝑦 𝑑𝑥
2
2 4
= ∫1/2 𝑒 −𝑥 𝑑𝑥 ∫0 𝑒 −𝑦 𝑑𝑦 = (𝑒 −1/2 − 𝑒 −2 )(1 − 𝑒 −4 ).
∞ ∞ ∞
ℎ1 (𝑥) = ∫ 𝑓(𝑥, 𝑦) 𝑑𝑦 = ∫ 𝑒 −(𝑥+𝑦) 𝑑𝑦 = 𝑒 −𝑥 ∫ 𝑒 −𝑦 𝑑𝑦 = 𝑒 −𝑥
−∞ 0 0
1 1 1
Therefore, 𝑃(𝑥 < 1) = ∫0 ℎ1 (𝑥) 𝑑𝑥 = ∫0 𝑒 −𝑥 𝑑𝑥 = 1 − .
𝑒
∞ 𝑦 ∞ 𝑦
(iii) 𝑃(𝑥 ≤ 𝑦) = ∫0 {∫0 𝑓(𝑥, 𝑦) 𝑑𝑥} 𝑑𝑦 = ∫0 {∫0 𝑒 −(𝑥+𝑦) 𝑑𝑥} 𝑑𝑦
∞ 𝑦 ∞
= ∫ 𝑒 −𝑦 (∫ 𝑒 −𝑥 𝑑𝑥) 𝑑𝑦 = ∫ 𝑒 −𝑦 (1 − 𝑒 −𝑦 ) 𝑑𝑦
0 0 0
∞
1 1
= ∫ (𝑒 −𝑦 − 𝑒 −2𝑦 ) 𝑑𝑦 = 1 − =
0 2 2
1 1
Therefore, 𝑃(𝑥 > 𝑦) = 1 − 𝑃(𝑥 ≤ 𝑦) = 1 − = .
2 2
1 1−𝑥 1 1−𝑥
= ∫ ∫ 𝑓(𝑥, 𝑦) 𝑑𝑦 𝑑𝑥 = ∫ {∫ 𝑒 −(𝑥+𝑦) 𝑑𝑦} 𝑑𝑥
𝑥=0 𝑦= 0 0 0
1 1−𝑥 1
= ∫ 𝑒 −𝑥 {∫ 𝑒 −𝑦 𝑑𝑦} 𝑑𝑥 = ∫ 𝑒 −𝑥 {1 − 𝑒 − (1−𝑥) } 𝑑𝑥
0 0 0
1
2
= ∫ (𝑒 −𝑥 − 𝑒 −1 ) 𝑑𝑥 = 1 − .
0 𝑒
𝑃(0 < 𝑥 < 1|𝑦 = 2)
(v) 𝑃(0 < 𝑥 < 1|𝑦 = 2) = 𝑃(𝑦=2)
[putting 𝑦 = 2]
Problems to practice:
1) If the joint probability function for 𝑓(𝑥, 𝑦) is
𝑐(𝑥 2 + 𝑦 2 ), 0 ≤ 𝑥 ≤ 1, 0 ≤ 𝑦 ≤ 1, 𝑐 ≥ 0
f (x, y) = { is a density function of a
0, 𝑒𝑙𝑠𝑒𝑤ℎ𝑒𝑟𝑒
joint probability distribution. Then evaluate the following:
(i) the value of the constant 𝑐. (ii) the marginal density functions of 𝑥 and 𝑦.
1 1 1 3 1
(iii) 𝑃 (𝑥 < 2 , 𝑦 > 2) (iv) 𝑃 (4 < 𝑥 < 4) (v) 𝑃 (𝑦 < 2) .
1
(6
f (x, y) = {8 − 𝑥 − 𝑦), 0 < 𝑥 < 2, 0<𝑦<4
0, 𝑒𝑙𝑠𝑒𝑤ℎ𝑒𝑟𝑒
Evaluate (i) 𝑃(𝑥 < 1, 𝑦 < 3), (ii)𝑃(𝑥 + 𝑦 < 3), (iii) the covariance between 𝑥 and 𝑦
and (iv) 𝑃(𝑥 < 1|𝑦 < 3)
. Video Links:
https://www.youtube.com/watch?v=82Ad1orN-NA
https://www.youtube.com/watch?v=eYthpvmqcf0
https://www.youtube.com/watch?v=L0zWnBrjhng
https://www.youtube.com/watch?v=Om68Hkd7pfw
https://www.youtube.com/watch?v=RYIb1u3C13I