0% found this document useful (0 votes)
150 views8 pages

Rainfall Probability Analysis

The document contains solutions to various problems related to continuous random variables and their probability distributions. It includes calculations for medians, probabilities, and cumulative distribution functions for different scenarios, such as waiting times and lifespan of components. Key results include specific probability values and methods for deriving them using integration and properties of probability distributions.

Uploaded by

Shobhraj Meena
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
150 views8 pages

Rainfall Probability Analysis

The document contains solutions to various problems related to continuous random variables and their probability distributions. It includes calculations for medians, probabilities, and cumulative distribution functions for different scenarios, such as waiting times and lifespan of components. Key results include specific probability values and methods for deriving them using integration and properties of probability distributions.

Uploaded by

Shobhraj Meena
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

Statistics for Data Science - 2

Week 4 Graded Assignment solution


Continuous random variable

1. Let X be a continuous random variable with PDF


(
kx2 , 0 ≤ x ≤ 1
fX (x) =
0, otherwise.

Find the median of X. Enter the answer correct to four decimal places.
Hint: The median m is the value such that P (X ≤ m) = P (X > m) = 0.5
Answer : 0.7937 : Range : 0.7933 to 0.7940
Solution:
First, we need to calculate the value of k as follows:
Z 1
fX (x)dx = 1
0
Z 1
=⇒ kx2 dx = 1
0
1
x3

=⇒ k =1
3 0
 
1 0
=⇒ k − = 1 =⇒ k = 3
3 3
Thus, PDF will be: (
3x2 , 0 ≤ x ≤ 1
fX (x) =
0, otherwise.
Now, the median m is the value such that P (X ≤ m) = P (X > m) = 0.5. Therefore,

P (X ≤ m) = 0.5
Z m
fX (x)dx = 0.5
0
Z m
=⇒ fX (x)dx = 0.5
0
Z m
=⇒ 3x2 dx = 0.5
0
Z m
=⇒ 3 x2 dx = 0.5
0

1
m
x3

=⇒ 3 = 0.5
3 0

=⇒ m3 − 0 = 0.5 =⇒ m = 0.5(1/3) = 0.7937

2. Suppose that the time (in minutes) that a person has to wait at a certain bus stop for a
bus is found to be a random phenomenon, with a distribution specified by the following
cumulative distribution function:

0,

 x<0
x


8, 0 ≤ x < 2



F (x) =
x2
, 2≤x<4






 16
x≥4

1,

Let A be the event that a person has to wait for more than 2 minutes and B be the
event that he has to wait for more than 1 minute.
(i). Find the value of P (A ∩ B). Enter the answer correct to two decimal places.
Answer : 0.75 ; Range : 0.72 to 0.78
Solution:
A is the event that the waiting time is more than 2 minutes, so A = {X > 2}
B is the event that the waiting time is more than 1 minute, so B = {X > 1}
Thus,
P (A ∩ B) = P (X > 2, X > 1) = P (X > 2)
1 3
=⇒ P (X > 2) = 1 − P (X ≤ 2) = 1 − F (2) = 1 − = = 0.75
4 4
(ii). Calculate the value of P (A | B). Enter the answer correct to two decimal places.
Answer : 0.86 ; Range : 0.83 to 0.89
Solution:

P (A ∩ B)
P (A|B) =
P (B)
P (X > 2, X > 1) P (X > 2)
=⇒ P (X > 2 | X > 1) = =
P (X > 1) 1 − P (X ≤ 1)
0.75 0.75
=⇒ P (X > 2 | X > 1) = 1
= = 0.857 ≈ 0.86
1− 8 1 − 0.125
3. The CDF of a random variable X is
(
1 − e−3x x≥0
FX (x) =
0 otherwise

2
i) Find P (X > 4).

a) e−3 − e−4
b) e−12
c) e−7
d) e−3 e−4

Solution:

P (X > 4) = 1 − P (X ≤ 4) = 1 − FX (4)
= 1 − (1 − e−3×4 )
= e−12

4. Find the value of P (−5 < X ≤ 6).

a) 1 − e−18
b) e−5 − e−18
c) e−18
d) e−9

Solution:

P (−5 < X ≤ 6) = FX (6) − FX (−5)


= (1 − e−3×6 ) − 0
= 1 − e−18

5. Let X be a continuous random variable with the following PDF:


(
ke−x x ≥ 0
fX (x) =
0 otherwise

i) Find the value of k.

Solution:

3
We know that for PDF of the random variable
Z ∞
fX (x) = 1
−∞
Z ∞
⇒ ke−x dx = 1
0

e−x
 
⇒k =1
−1
0

⇒ k(0 + 1) = 1 (As x approaches to ∞, e−x approaches to 0)


⇒k=1

6. Find P (3 < X < 4).

a) e−1
b) e−3 e−4
c) e−3 − e−4
d) e−4 − e−3
Rb
Hint: Use a e−x dx = e−a − e−b
Solution:
Z 4
P (3 < X < 4) = ke−x dx
3
4
e−x
 
=1×
−1
3
e−4 e−3
 
= −
−1 −1
−3 −4
=e −e

7. Let X be a continuous random variable with PDF


(
5x4 0 < x ≤ 1
fX (x) =
0 otherwise
3
Find P (X ≤ 4
| X > 41 ).
3
a)
16
17
b)
86

4
22
c)
93
9
d)
22
Rb
Hint: Use a
5x4 dx = b5 − a5

Solution:

3 1 P (X ≤ 43 and X > 14 )
P (X ≤ | X > ) =
4 4 P (X > 14 )
R 3/4 4
1/4
5x dx
= R1
1/4
5x4 dx
3/4
5x5
5
1/4
= 1
5x5
5
1/4
3/4

x5
3 1 1/4
⇒ P (X ≤ |X> )= 1
4 4
x5
1/4
3 5
(4) − ( 14 )5
=
1 − ( 14 )5
22
=
93

8. The lifespan (in hours) of an electronic component used in an electric car has the density
function ( x
1 − 500
500
e x≥0
fX (x) =
0 otherwise
Determine the probability that the component lasts more than 200 hours before it needs
to be replaced.

a) e−0.4
b) e200
c) 0.5

5
d) e−2.5

Solution:
Let X denote the lifespan (in hours) of the electronic component. We have to find the
probability that the component lasts more than 200 hours before it needs to be replaced
i.e.
P (X > 200) = 1 − P (X ≤ 200)
1
Also, we can relate the given density with the exponential distribution with λ = 500 .

⇒ P (X > 200) = 1 − P (X ≤ 200)


= 1 − FX (200)
200
= 1 − (1 − e− 500 )
= e−0.4

9. A firm produces machines with a lifespan, whose distribution has a mean of 200 months
and standard deviation of 50 months. The firm wishes to introduce a warranty scheme
in which it would like to replace all the dysfunctional machines with new ones within
warranty period. But they do not wish to do so for more than 11.9% of the machines
they produce. If the lifespan of the machine is assumed to follow a normal distribution,
how long a guarantee period should be offered? (Answer is expected in months)
Hint: Use P (Z < −1.18) = 0.119, where Z represents the standard normal distribution.

Solution:
Let X denote the lifespan of the machines in months. Given that µ = 200 and σ = 50.
The firm did not wish to replace more than 11.9% of the machines they produce.
If m be the guarantee period (in months), then

P (X ≤ m) = 0.119
 
X − 200 m − 200
⇒P ≤ = 0.119
50 50

Comparing this equation with the given value of standard normal distribution we will get

m − 200
= −1.18
50
⇒ m = 141

Use the following information to answer questions (8), (9) and (10).

6
Let the CDF of a random variable X be given by


 0 x<0

1/3 0≤x<1
FX (x) =


 1/2 1≤x<2
x≥2

1

10. Find P (X = 0). Write your answer correct to two decimal places.
Solution:
1 1
P (X = 0) = , as there is a jump of at x = 0
3 3

11. Find P (X = 1). Write your answer correct to two decimal places.
Solution:
1 1 1 1
P (X = 1) = − = , as there is a jump of at x = 1
2 3 6 6

12. Find P (X = 2). Write your answer correct to two decimal places.
Solution:
1 1 1
P (X = 2) = 1 − = , as there is a jump of at x = 2
2 2 2

13. A meteorologist is studying rainfall patterns in a region. The CDF of the daily rainfall
(X) in millimetres (mm) is modeled as F (x) = 1 − e−0.5x for x ≥ 0. What is the
probability that on a randomly chosen day, the rainfall exceeds 10 mm? Enter the
answer correct to four decimal places.
Solution:
Given that the CDF of the daily rainfall X in millimeters is modeled as:
F (x) = 1 − e−0.5x for x ≥ 0

We have to find the probability that on a randomly chosen day, the rainfall exceeds 10
mm i.e. P (X > 10).

7
P (X > 10) = 1 − P (X ≤ 10) {By complement rule for the CDF}
= 1 − FX (10)
= 1 − (1 − e−0.5(10) )
= 1 − 1 + e−0.5(10)
= e−5
= 0.0067

14. The level of a certain toxin in a water sample is uniformly distributed between 0 and 50
ppm. If a reading shows less than 20 ppm, what is the probability that the actual level
is less than 10 ppm? Enter the answer correct to one decimal place.
Solution:
Let X denote the level of toxin in water.
Given X ∼ Unif(0, 50), the PDF is:
1
fX (x) = for 0 ≤ x ≤ 50
50

And the CDF is:


x
FX (x) = for 0 < x < 50
50
We need to find P (X < 10 | X < 20):

P (X < 10 ∩ X < 20)


P (X < 10|X < 20) =
P (X < 20)
P (X < 10)
=
P (X < 20)
P (X ≤ 10)
= {As P (X < x) = P (X ≤ x) for continuous random variable}
P (X ≤ 20)
 
10 − 0
50 − 0
= 
20 − 0
50 − 0
10
=
20
= 0.5

You might also like